]> git.sesse.net Git - stockfish/blobdiff - src/position.cpp
san.cpp pass position as constant reference
[stockfish] / src / position.cpp
index 47e1af2704e3eb21e08026d09d2a3c0bbe5dd461..abac6efc1ef56e4b57a22734558c5d1c3564348a 100644 (file)
@@ -275,9 +275,8 @@ void Position::print(Move m) const {
   std::cout << std::endl;
   if (m != MOVE_NONE)
   {
-      Position p(*this);
       std::string col = (color_of_piece_on(move_from(m)) == BLACK ? ".." : "");
-      std::cout << "Move is: " << col << move_to_san(p, m) << std::endl;
+      std::cout << "Move is: " << col << move_to_san(*this, m) << std::endl;
   }
   for (Rank rank = RANK_8; rank >= RANK_1; rank--)
   {