diff --git a/include/chaiscript/dispatchkit/dispatchkit.hpp b/include/chaiscript/dispatchkit/dispatchkit.hpp index 3d6eba2a..ccaa03c0 100644 --- a/include/chaiscript/dispatchkit/dispatchkit.hpp +++ b/include/chaiscript/dispatchkit/dispatchkit.hpp @@ -437,9 +437,19 @@ namespace chaiscript /// of the object stack, functions and registered types. class Dispatch_Engine { + struct str_less { + bool operator()(const std::string &t_lhs, const std::string &t_rhs) const noexcept { + return t_lhs < t_rhs; + } + template + bool operator()(const LHS &t_lhs, const RHS &t_rhs) const noexcept { + return std::lexicographical_compare(t_lhs.begin(), t_lhs.end(), t_rhs.begin(), t_rhs.end()); + } + struct is_transparent{}; + }; public: - typedef std::map> Type_Name_Map; + typedef std::map Type_Name_Map; typedef std::vector> Scope; typedef Stack_Holder::StackData StackData; @@ -448,7 +458,7 @@ namespace chaiscript std::vector>>> m_functions; std::vector> m_function_objects; std::vector> m_boxed_functions; - std::map> m_global_objects; + std::map m_global_objects; Type_Name_Map m_types; };