mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 16:53:09 +00:00
Don't need to expose namespace Zobrist
It can be local to position.cpp No functional change.
This commit is contained in:
parent
a6e0f62a4f
commit
de1dc4f2de
3 changed files with 10 additions and 18 deletions
|
@ -46,11 +46,16 @@ Value PieceValue[PHASE_NB][PIECE_NB] = {
|
|||
{ VALUE_ZERO, PawnValueMg, KnightValueMg, BishopValueMg, RookValueMg, QueenValueMg },
|
||||
{ VALUE_ZERO, PawnValueEg, KnightValueEg, BishopValueEg, RookValueEg, QueenValueEg } };
|
||||
|
||||
Key Zobrist::psq[COLOR_NB][PIECE_TYPE_NB][SQUARE_NB];
|
||||
Key Zobrist::enpassant[FILE_NB];
|
||||
Key Zobrist::castle[CASTLE_RIGHT_NB];
|
||||
Key Zobrist::side;
|
||||
Key Zobrist::exclusion;
|
||||
namespace Zobrist {
|
||||
|
||||
Key psq[COLOR_NB][PIECE_TYPE_NB][SQUARE_NB];
|
||||
Key enpassant[FILE_NB];
|
||||
Key castle[CASTLE_RIGHT_NB];
|
||||
Key side;
|
||||
Key exclusion;
|
||||
}
|
||||
|
||||
Key Position::exclusion_key() const { return st->key ^ Zobrist::exclusion;}
|
||||
|
||||
namespace {
|
||||
|
||||
|
|
|
@ -346,10 +346,6 @@ inline Key Position::key() const {
|
|||
return st->key;
|
||||
}
|
||||
|
||||
inline Key Position::exclusion_key() const {
|
||||
return st->key ^ Zobrist::exclusion;
|
||||
}
|
||||
|
||||
inline Key Position::pawn_key() const {
|
||||
return st->pawnKey;
|
||||
}
|
||||
|
|
|
@ -328,15 +328,6 @@ inline Score operator/(Score s, int i) {
|
|||
#undef ENABLE_OPERATORS_ON
|
||||
#undef ENABLE_SAFE_OPERATORS_ON
|
||||
|
||||
namespace Zobrist {
|
||||
|
||||
extern Key psq[COLOR_NB][PIECE_TYPE_NB][SQUARE_NB];
|
||||
extern Key enpassant[FILE_NB];
|
||||
extern Key castle[CASTLE_RIGHT_NB];
|
||||
extern Key side;
|
||||
extern Key exclusion;
|
||||
}
|
||||
|
||||
extern Value PieceValue[PHASE_NB][PIECE_NB];
|
||||
extern int SquareDistance[SQUARE_NB][SQUARE_NB];
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue