]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Cache pinned and discovery check bitboards
[stockfish] / src / search.cpp
index b00c270bbd94bd034dcfe96fcd2bd6d979c0ccbc..c93780b37db7d8f4288f65e73372251b43ad746c 100644 (file)
@@ -2113,7 +2113,7 @@ namespace {
 
     // Case 4: The destination square for m2 is attacked by the moving piece
     // in m1:
-    if(pos.piece_attacks_square(t1, t2))
+    if(pos.piece_attacks_square(pos.piece_on(t1), t1, t2))
       return true;
 
     // Case 5: Discovered check, checking piece is the piece moved in m1: