]> git.sesse.net Git - stockfish/blobdiff - src/movepick.h
Update various comments
[stockfish] / src / movepick.h
index ae61be7f61549067395b84c91565856cc462082a..666cca362ed277493279dcefb265a2146eb952ad 100644 (file)
@@ -47,8 +47,8 @@ public:
   operator TT() const { return entry; }
 
   void operator<<(int bonus) {
-    assert(abs(bonus) <= D);                   // Ensure range is [-D, D]
-    assert(D < std::numeric_limits<T>::max()); // Ensure we don't overflow
+    assert(abs(bonus) <= D);   // Ensure range is [-D, D]
+    static_assert(D <= std::numeric_limits<T>::max(), "D overflows T");
 
     entry += bonus - entry * abs(bonus) / D;