]> git.sesse.net Git - stockfish/blobdiff - src/position.cpp
MovePicker: use EvalInfo to skip generating captures
[stockfish] / src / position.cpp
index 8390facc5b501a040333c820285bd28e15573a29..0c7d62ce10e63839356214778211a93662137e75 100644 (file)
@@ -243,7 +243,7 @@ const std::string Position::to_fen() const {
 
       fen += (rank > RANK_1 ? '/' : ' ');
   }
-  fen += (sideToMove == WHITE ? 'w' : 'b') + ' ';
+  fen += (sideToMove == WHITE ? "w " : "b ");
   if (castleRights != NO_CASTLES)
   {
     if (can_castle_kingside(WHITE))  fen += 'K';
@@ -274,7 +274,8 @@ void Position::print(Move m) const {
   if (m != MOVE_NONE)
   {
       Position p(*this);
-      std::cout << "Move is: " << move_to_san(p, m) << std::endl;
+      std::string col = (color_of_piece_on(move_from(m)) == BLACK ? ".." : "");
+      std::cout << "Move is: " << col << move_to_san(p, m) << std::endl;
   }
   for (Rank rank = RANK_8; rank >= RANK_1; rank--)
   {
@@ -291,9 +292,9 @@ void Position::print(Move m) const {
       }
       std::cout << '|' << std::endl;
   }
-  std::cout << "+---+---+---+---+---+---+---+---+" << std::endl;
-  std::cout << "Fen is: " << to_fen() << std::endl;
-  std::cout << key << std::endl;
+  std::cout << "+---+---+---+---+---+---+---+---+" << std::endl
+            << "Fen is: " << to_fen() << std::endl
+            << "Key is: " << key << std::endl;
 }