mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 07:27:46 +00:00
c6f497f09d
We test if the piece moved in 'to' attacks the square 's' with: bit_is_set(attacks_from(piece, to), s)) But we should instead consider the new occupancy, changed after the piece is moved, and so test with: bit_is_set(attacks_from(piece, to, occ), s)) Otherwise we can miss some cases, for instance a queen in b1 that moves in c1 is not detected to attack a1 while instead she does. Signed-off-by: Marco Costalba <mcostalba@gmail.com>