]> git.sesse.net Git - stockfish/blobdiff - src/position.cpp
Rename squares_aligned()
[stockfish] / src / position.cpp
index 52e6dd0fc5b520d1696b2987ff907e512b009526..c40b1199bd823f0f6f9268bff8ba70e42304fd21 100644 (file)
@@ -515,7 +515,7 @@ bool Position::legal(Move m, Bitboard pinned) const {
   // is moving along the ray towards or away from the king.
   return   !pinned
         || !(pinned & from)
-        ||  squares_aligned(from, to_sq(m), king_square(us));
+        ||  aligned(from, to_sq(m), king_square(us));
 }
 
 
@@ -658,7 +658,7 @@ bool Position::gives_check(Move m, const CheckInfo& ci) const {
   {
       // For pawn and king moves we need to verify also direction
       if (   (pt != PAWN && pt != KING)
-          || !squares_aligned(from, to, king_square(~sideToMove)))
+          || !aligned(from, to, king_square(~sideToMove)))
           return true;
   }