Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Ryan's formating improvement project #53

Closed
wants to merge 3 commits into
from

Conversation

Projects
None yet
3 participants
Contributor

RyanTaker commented Mar 18, 2013

A broad but non-intensive formatting change that does not yield any functional changes.

Changes Are As Follows:

  • Use a more consistent style with regards to brackets. The rules that my change uses two schemes.
    • The bracket on the line following the upper block level
    • A bracket on the same line as the upper block with code on the next line
  • Removed unused imports from the code base
  • Rewrote the material table guides
  • Rewrote the critical move table in sets of 10x and wrote a move number guide
  • Documented different areas and requested users to use the getters instead of directly grabbing the Bitboard arrays directly in order to lower amount of type problems in active development.

No rush or need to push this, I am just putting through some changes I have made on my personal branches.
Tell me if only some of the changes are helpful.

Owner

mcostalba commented Mar 18, 2013

Thanks Ryan,

I will cherry-pick from it.

But please don't expect a lot: at the moment I'm not very inclined to
change code style braces conventions, also I will add comments only
when is really needed. Stockfish, as you know, is already one of the
most commented engines, usual convention is to comment much less and I
also agree that over commenting is not a good thing for a number of
reasons: it is the code that shall be clear, not the comment that
explains it.

Marco

Contributor

RyanTaker commented Mar 18, 2013

No problem Marco, I was just feel that the bracket formatting is inconsistent right now as it seems the format changes between each file.

Yery commented Mar 18, 2013

Ryan to save you time, you might want to have a look at http://astyle.sourceforge.net/

Contributor

RyanTaker commented Mar 18, 2013

@Yery I am reverting the style changes and keeping it at the documentation changes

Owner

mcostalba commented Mar 18, 2013

On Mon, Mar 18, 2013 at 4:56 PM, RyanTaker notifications@github.com wrote:

No problem Marco, I was just feel that the bracket formatting is
inconsistent right now as it seems the format changes between each file.

Can you please point me at an example where bracket formatting of the
same kind of entity
(functions, statements, namespaces, etc..) is
different between 2 files ?

Thanks.

P.S: Why did you removed includes? Like this one

#include

from book.cpp where we have:

assert(low <= high);

Please consider that the relying on the fact that the needed include
are indirectly included by another file is not considered good
practice and is not endorsed.

Contributor

RyanTaker commented Mar 18, 2013

@mcostalba

For example compare the methods in bitcount against other methods. In these, the code either includes or doesn't have a newline after the parameters and name. By inconsistent I was mostly talking about the idea of keeping a bracket on the same line as the parameters and at the same time giving a newline for clean reading.

On removing imports, sorry about that, I used the comment out and check method. I will check through the imports and see how it is inheriting the import.

Owner

mcostalba commented Mar 19, 2013

On Mon, Mar 18, 2013 at 10:40 PM, RyanTaker notifications@github.com wrote:

For example compare the methods in bitcount against other methods. In
these, the code either includes or doesn't have a newline after the
parameters and name.

Please forgive me but this morning I am not able to see it. Could you
please do write me a specific example ?

Thanks

Contributor

RyanTaker commented Mar 19, 2013

@mcostalba I am reverting the changes to brackets as there is little need to change the style in that regard. I am going through it again and fixing up some of the things that I did incorrectly.

@RyanTaker RyanTaker closed this Mar 30, 2013

@glinscott glinscott added a commit to glinscott/Stockfish that referenced this pull request Sep 25, 2014

@uriblass @glinscott uriblass + glinscott Change history reduction in LMR to be a full ply.
STC:
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 9829 W: 2142 L: 1998 D: 5689

LTC:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 27162 W: 4802 L: 4692 D: 17668

Bench: 7284120

Resolves #53
d6613b7

@nmrugg nmrugg referenced this pull request in nmrugg/stockfish.js Mar 15, 2015

@uriblass @nmrugg uriblass + nmrugg Change history reduction in LMR to be a full ply.
STC:
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 9829 W: 2142 L: 1998 D: 5689

LTC:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 27162 W: 4802 L: 4692 D: 17668

Bench: 7284120

Resolves #53

(cherry picked from commit d6613b7)
834cd83

@alwey alwey pushed a commit to alwey/Stockfish that referenced this pull request Nov 23, 2016

@ddugovic ddugovic Merge pull request #53 from ianfab/master
Adjust SEE for Antichess
e37d960

@alwey alwey pushed a commit to alwey/Stockfish that referenced this pull request Nov 23, 2016

@ddugovic ddugovic Use antichess piece values for antichess SEE #53 a3ed661
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment