]> git.sesse.net Git - stockfish/blobdiff - src/position.h
Retire useless piece_value_midgame() overloads
[stockfish] / src / position.h
index e921b350cd7270f2fed7b632f0cc64821caf59fc..b006cff248fef882e4c4901ced0911b722009bcf 100644 (file)
@@ -264,8 +264,8 @@ public:
   bool is_mate() const;
   bool is_draw() const;
 
-  // Check if one side threatens a mate in one
-  bool has_mate_threat(Color c);
+  // Check if side to move could be mated in one
+  bool has_mate_threat();
 
   // Number of plies since the last non-reversible move
   int rule_50_counter() const;
@@ -377,11 +377,11 @@ inline bool Position::square_is_occupied(Square s) const {
 }
 
 inline Value Position::midgame_value_of_piece_on(Square s) const {
-  return piece_value_midgame(piece_on(s));
+  return PieceValueMidgame[piece_on(s)];
 }
 
 inline Value Position::endgame_value_of_piece_on(Square s) const {
-  return piece_value_endgame(piece_on(s));
+  return PieceValueEndgame[piece_on(s)];
 }
 
 inline Color Position::side_to_move() const {