mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 13:17:44 +00:00
Rename CASTLE to CASTLING
It is call 'castling move', not 'castle move' Noticed while reading DiscoCheck sources. No functional change.
This commit is contained in:
+8
-8
@@ -97,7 +97,7 @@ const int MAX_PLY_PLUS_6 = MAX_PLY + 6;
|
||||
/// bit 0- 5: destination square (from 0 to 63)
|
||||
/// bit 6-11: origin square (from 0 to 63)
|
||||
/// bit 12-13: promotion piece type - 2 (from KNIGHT-2 to QUEEN-2)
|
||||
/// bit 14-15: special move flag: promotion (1), en passant (2), castle (3)
|
||||
/// bit 14-15: special move flag: promotion (1), en passant (2), castling (3)
|
||||
///
|
||||
/// Special cases are MOVE_NONE and MOVE_NULL. We can sneak these in because in
|
||||
/// any normal move destination square is always different from origin square
|
||||
@@ -112,17 +112,17 @@ enum MoveType {
|
||||
NORMAL,
|
||||
PROMOTION = 1 << 14,
|
||||
ENPASSANT = 2 << 14,
|
||||
CASTLE = 3 << 14
|
||||
CASTLING = 3 << 14
|
||||
};
|
||||
|
||||
enum CastleRight { // Defined as in PolyGlot book hash key
|
||||
CASTLES_NONE,
|
||||
enum CastlingFlag { // Defined as in PolyGlot book hash key
|
||||
NO_CASTLING,
|
||||
WHITE_OO,
|
||||
WHITE_OOO = WHITE_OO << 1,
|
||||
BLACK_OO = WHITE_OO << 2,
|
||||
BLACK_OOO = WHITE_OO << 3,
|
||||
ALL_CASTLES = WHITE_OO | WHITE_OOO | BLACK_OO | BLACK_OOO,
|
||||
CASTLE_RIGHT_NB = 16
|
||||
ANY_CASTLING = WHITE_OO | WHITE_OOO | BLACK_OO | BLACK_OOO,
|
||||
CASTLING_FLAG_NB = 16
|
||||
};
|
||||
|
||||
enum CastlingSide {
|
||||
@@ -346,8 +346,8 @@ inline Piece make_piece(Color c, PieceType pt) {
|
||||
return Piece((c << 3) | pt);
|
||||
}
|
||||
|
||||
inline CastleRight make_castle_right(Color c, CastlingSide s) {
|
||||
return CastleRight(WHITE_OO << ((s == QUEEN_SIDE) + 2 * c));
|
||||
inline CastlingFlag make_castling_flag(Color c, CastlingSide s) {
|
||||
return CastlingFlag(WHITE_OO << ((s == QUEEN_SIDE) + 2 * c));
|
||||
}
|
||||
|
||||
inline PieceType type_of(Piece p) {
|
||||
|
||||
Reference in New Issue
Block a user