]> git.sesse.net Git - stockfish/commitdiff
Fix a bug in pawns eval tracing
authorMarco Costalba <mcostalba@gmail.com>
Wed, 26 Mar 2014 06:06:29 +0000 (07:06 +0100)
committerMarco Costalba <mcostalba@gmail.com>
Wed, 26 Mar 2014 06:06:29 +0000 (07:06 +0100)
Instead of totals we were showing white and
black values.

Spotted by Sven Schüle

No functional change.

src/evaluate.cpp

index 57bbfe09d87f6d97a4a940a3be85930d0f9641fb..99e9f0475281111fff761ad0f4f0b0f33e7e3968 100644 (file)
@@ -961,8 +961,8 @@ Value do_evaluate(const Position& pos) {
     switch (idx) {
     case PST: case IMBALANCE: case PAWN: case TOTAL:
         ss << std::setw(20) << name << " |   ---   --- |   ---   --- | "
-           << std::setw(6)  << to_cp(mg_value(wScore)) << " "
-           << std::setw(6)  << to_cp(eg_value(wScore)) << " \n";
+           << std::setw(6)  << to_cp(mg_value(wScore - bScore)) << " "
+           << std::setw(6)  << to_cp(eg_value(wScore - bScore)) << " \n";
         break;
     default:
         ss << std::setw(20) << name << " | " << std::noshowpos