X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmovegen.cpp;h=33da450ec8e0452eb90daafed75df7cd91740ec1;hb=ad4eac376fdc7a5ccc794416d0295a38a31ddcc2;hp=7558c89d63d6847261f6d3a62b3c63263d2d7ff4;hpb=8bec65029d6ac3b22b956cfd820ec754420052df;p=stockfish diff --git a/src/movegen.cpp b/src/movegen.cpp index 7558c89d..33da450e 100644 --- a/src/movegen.cpp +++ b/src/movegen.cpp @@ -506,7 +506,7 @@ bool move_is_legal(const Position& pos, const Move m, Bitboard pinned) { // be a promotion. if ( ( (square_rank(to) == RANK_8 && us == WHITE) ||(square_rank(to) == RANK_1 && us != WHITE)) - && !move_promotion(m)) + && !move_is_promotion(m)) return false; // Proceed according to the square delta between the source and @@ -560,7 +560,7 @@ bool move_is_legal(const Position& pos, const Move m, Bitboard pinned) { // Luckly we can handle all the other pieces in one go return ( pos.piece_attacks_square(pos.piece_on(from), from, to) && pos.pl_move_is_legal(m, pinned) - && !move_promotion(m)); + && !move_is_promotion(m)); }