diff --git a/include/fintamath/core/MathObjectTypes.hpp b/include/fintamath/core/MathObjectTypes.hpp index 619a48c44..3c04c6054 100644 --- a/include/fintamath/core/MathObjectTypes.hpp +++ b/include/fintamath/core/MathObjectTypes.hpp @@ -188,22 +188,10 @@ struct hash { namespace fintamath { class MathObjectBoundTypes { - static constexpr auto getTypeHash = [](const MathObjectType &type) { return size_t(type); }; - - using TypeMap = std::unordered_map; - using enum MathObjectType::Id; -public: - static const TypeMap &get() { - return getMutable(); - } - - static void reg(const MathObjectType &type, const MathObjectType &boundType) { - getMutable().emplace(type, boundType); - } + using TypeMap = std::unordered_map; -private: static TypeMap &getMutable() { static TypeMap ids{ {IMathObject, None}, @@ -223,6 +211,15 @@ class MathObjectBoundTypes { return ids; } + +public: + static const TypeMap &get() { + return getMutable(); + } + + static void reg(const MathObjectType &type, const MathObjectType &boundType) { + getMutable().emplace(type, boundType); + } }; inline bool isBaseOf(const MathObjectType &toType, const MathObjectType &fromType) {