X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fvalue.h;h=fec6516a4c8c4014427afeeb3cf22d6b9941d865;hb=0973cc2ef63060294f790803e0525b66ee91dfee;hp=d54f81961174472cc7d8fde5b624ef18d3b9abde;hpb=3f14f9a4782227107c4ced035da205b768839cbe;p=stockfish diff --git a/src/value.h b/src/value.h index d54f8196..fec6516a 100644 --- a/src/value.h +++ b/src/value.h @@ -56,7 +56,7 @@ enum Value { /// integer (enum), first LSB 16 bits are used to store endgame /// value, while upper bits are used for midgame value. -enum Score {}; +enum Score { ENSURE_32_BIT_SIZE = 1 << 31 }; inline Value eg_value(Score s) { return Value(int16_t(s & 0xffff)); } inline Value mg_value(Score s) { return Value((int(s) + 32768) >> 16); }