]> git.sesse.net Git - stockfish/commitdiff
Fix a typo in ReducedStateInfo
authorMarco Costalba <mcostalba@gmail.com>
Sat, 26 Dec 2009 17:12:59 +0000 (18:12 +0100)
committerMarco Costalba <mcostalba@gmail.com>
Sat, 26 Dec 2009 18:38:53 +0000 (19:38 +0100)
It happened to work by accident because Score and
Value are both integer.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
src/position.cpp

index 7de4ae826c246c0705019f2ccab936ff1afd33d6..ab8f2473af84d40126dc232b096b551d11157dbb 100644 (file)
@@ -671,7 +671,7 @@ void Position::do_move(Move m, StateInfo& newSt, const CheckInfo& ci, bool moveI
     Key pawnKey, materialKey;
     int castleRights, rule50, pliesFromNull;
     Square epSquare;
-    Value value;
+    Score value;
     Value npMaterial[2];
   };
 
@@ -969,7 +969,7 @@ void Position::do_castle_move(Move m) {
   set_bit(&(byColorBB[us]), rto);
   set_bit(&(byTypeBB[ROOK]), rto);
   set_bit(&(byTypeBB[0]), rto); // HACK: byTypeBB[0] == occupied squares
-  
+
   // Update board array
   Piece king = piece_of_color_and_type(us, KING);
   Piece rook = piece_of_color_and_type(us, ROOK);
@@ -1154,7 +1154,7 @@ void Position::undo_castle_move(Move m) {
 
   assert(piece_on(kto) == piece_of_color_and_type(us, KING));
   assert(piece_on(rto) == piece_of_color_and_type(us, ROOK));
-  
+
   // Remove pieces from destination squares:
   clear_bit(&(byColorBB[us]), kto);
   clear_bit(&(byTypeBB[KING]), kto);
@@ -1162,7 +1162,7 @@ void Position::undo_castle_move(Move m) {
   clear_bit(&(byColorBB[us]), rto);
   clear_bit(&(byTypeBB[ROOK]), rto);
   clear_bit(&(byTypeBB[0]), rto); // HACK: byTypeBB[0] == occupied squares
+
   // Put pieces on source squares:
   set_bit(&(byColorBB[us]), kfrom);
   set_bit(&(byTypeBB[KING]), kfrom);