mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-21 01:27:16 +08:00
Use operator~ to flip colors and squares
More natural and nicer. Idea from Critter. No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -392,7 +392,7 @@ inline Bitboard Position::pinned_pieces() const {
|
||||
}
|
||||
|
||||
inline bool Position::pawn_is_passed(Color c, Square s) const {
|
||||
return !(pieces(PAWN, flip(c)) & passed_pawn_mask(c, s));
|
||||
return !(pieces(PAWN, ~c) & passed_pawn_mask(c, s));
|
||||
}
|
||||
|
||||
inline Key Position::key() const {
|
||||
|
||||
Reference in New Issue
Block a user