diff --git a/src/Standard/Standard_HashUtils.hxx b/src/Standard/Standard_HashUtils.hxx index 40b613fcab..cee0703710 100644 --- a/src/Standard/Standard_HashUtils.hxx +++ b/src/Standard/Standard_HashUtils.hxx @@ -46,15 +46,9 @@ namespace opencascade } template - constexpr typename std::enable_if::type optimalSeed() + constexpr T optimalSeed() { - return 0xA329F1D3A586ULL; - } - - template - constexpr typename std::enable_if::type optimalSeed() - { - return static_cast(0xc70f6907U); + return sizeof(T) == 8 ? static_cast(0xA329F1D3A586ULL) : static_cast(0xc70f6907U); } }; @@ -84,15 +78,9 @@ namespace opencascade } template - constexpr typename std::enable_if::type optimalSeed() + constexpr T optimalSeed() { - return 14695981039346656037ULL; - } - - template - constexpr typename std::enable_if::type optimalSeed() - { - return static_cast(2166136261U); + return sizeof(T) == 8 ? static_cast(14695981039346656037ULL) : static_cast(2166136261U); } }; diff --git a/src/TopLoc/TopLoc_Location.lxx b/src/TopLoc/TopLoc_Location.lxx index f228dea024..833632b439 100644 --- a/src/TopLoc/TopLoc_Location.lxx +++ b/src/TopLoc/TopLoc_Location.lxx @@ -14,6 +14,7 @@ // Alternatively, this file may be used under the terms of Open CASCADE // commercial license or contractual agreement. +#include #include #include #include