X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fposition.cpp;h=632a40b5d617658dbb6bb188a4d6e12ca4b96449;hb=7077fbdd1481829a0a20b6975c4245609118b938;hp=cfd98f686e03ac21ef013437d91cb7d636fd24ef;hpb=e9e7a7b83f78b5c7d29f69083589b449d9b52390;p=stockfish diff --git a/src/position.cpp b/src/position.cpp index cfd98f68..632a40b5 100644 --- a/src/position.cpp +++ b/src/position.cpp @@ -97,7 +97,7 @@ std::ostream& operator<<(std::ostream& os, const Position& pos) { // Marcel van Kervinck's cuckoo algorithm for fast detection of "upcoming repetition" // situations. Description of the algorithm in the following paper: -// https://marcelk.net/2013-04-06/paper/upcoming-rep-v2.pdf +// http://web.archive.org/web/20201107002606/https://marcelk.net/2013-04-06/paper/upcoming-rep-v2.pdf // First and second hash functions for indexing the cuckoo tables inline int H1(Key h) { return h & 0x1fff; } @@ -569,8 +569,7 @@ bool Position::pseudo_legal(const Move m) const { : MoveList(*this).contains(m); // Is not a promotion, so promotion piece must be empty - if (promotion_type(m) - KNIGHT != NO_PIECE_TYPE) - return false; + assert(promotion_type(m) - KNIGHT == NO_PIECE_TYPE); // If the 'from' square is not occupied by a piece belonging to the side to // move, the move is obviously not legal.