mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 09:47:46 +00:00
SEE: simplify stm variable initialization
Pull #3458 removed the only usage of pos.see_ge() moving pieces that don't belong to the side to move, so we can simplify this, adding an assert. closes https://github.com/official-stockfish/Stockfish/pull/3607 No functional change
This commit is contained in:
committed by
Joost VandeVondele
parent
09b6d28391
commit
f4986f4596
+2
-1
@@ -1080,8 +1080,9 @@ bool Position::see_ge(Move m, Value threshold) const {
|
||||
if (swap <= 0)
|
||||
return true;
|
||||
|
||||
assert(color_of(piece_on(from)) == sideToMove);
|
||||
Bitboard occupied = pieces() ^ from ^ to;
|
||||
Color stm = color_of(piece_on(from));
|
||||
Color stm = sideToMove;
|
||||
Bitboard attackers = attackers_to(to, occupied);
|
||||
Bitboard stmAttackers, bb;
|
||||
int res = 1;
|
||||
|
||||
Reference in New Issue
Block a user