int score;
};
+// Note that operator< is set up such that std::sort() will sort in descending order
+inline bool operator<(const MoveStack& f, const MoveStack& s) { return s.score < f.score; }
+
////
//// Inline functions
return PieceType((int(m) >> 12) & 7);
}
-inline bool move_is_ep(Move m) {
- return bool((int(m) >> 15) & 1);
+inline int move_is_ep(Move m) {
+ return m & (1 << 15);
}
-inline bool move_is_castle(Move m) {
- return bool((int(m) >> 16) & 1);
+inline int move_is_castle(Move m) {
+ return m & (1 << 16);
}
inline bool move_is_short_castle(Move m) {