X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fposition.cpp;h=7ee67e4ca9ef4efae68b87629d6cc8a70eb1993f;hp=d14f04169b95b1a2751711756dea4e730fc7f098;hb=8300ab149cec54c2124898285bdc9308f78de4cd;hpb=ad4739a6d45d9d37afe2414f432a07190fae9b83 diff --git a/src/position.cpp b/src/position.cpp index d14f0416..7ee67e4c 100644 --- a/src/position.cpp +++ b/src/position.cpp @@ -1,7 +1,7 @@ /* Stockfish, a UCI chess playing engine derived from Glaurung 2.1 Copyright (C) 2004-2008 Tord Romstad (Glaurung author) - Copyright (C) 2008-2010 Marco Costalba, Joona Kiiski, Tord Romstad + Copyright (C) 2008-2012 Marco Costalba, Joona Kiiski, Tord Romstad Stockfish is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -1691,7 +1691,7 @@ bool Position::pos_is_ok(int* failedStep) const { // Is there more than 2 checkers? if (failedStep) (*failedStep)++; - if (debugCheckerCount && count_1s(st->checkersBB) > 2) + if (debugCheckerCount && popcount(st->checkersBB) > 2) return false; // Bitboards OK? @@ -1760,7 +1760,7 @@ bool Position::pos_is_ok(int* failedStep) const { if (debugPieceCounts) for (Color c = WHITE; c <= BLACK; c++) for (PieceType pt = PAWN; pt <= KING; pt++) - if (pieceCount[c][pt] != count_1s(pieces(pt, c))) + if (pieceCount[c][pt] != popcount(pieces(pt, c))) return false; if (failedStep) (*failedStep)++;