diff --git a/include/chaiscript/dispatchkit/boxed_cast.hpp b/include/chaiscript/dispatchkit/boxed_cast.hpp index c055ac4..c86b4e1 100644 --- a/include/chaiscript/dispatchkit/boxed_cast.hpp +++ b/include/chaiscript/dispatchkit/boxed_cast.hpp @@ -86,7 +86,7 @@ namespace chaiscript #pragma warning(disable : 4127) #endif - if (std::is_polymorphic::type>::value && t_conversions) + if (std::is_polymorphic>::value && t_conversions) { try { // std::cout << "trying an up conversion " << typeid(Type).name() << std::endl; diff --git a/include/chaiscript/dispatchkit/type_info.hpp b/include/chaiscript/dispatchkit/type_info.hpp index 4944e80..afa9e9e 100644 --- a/include/chaiscript/dispatchkit/type_info.hpp +++ b/include/chaiscript/dispatchkit/type_info.hpp @@ -16,14 +16,8 @@ namespace chaiscript { - namespace detail - { - template - struct Bare_Type - { - typedef typename std::remove_cv::type>::type>::type type; - }; - } + template + using Bare_Type = typename std::remove_cv::type>::type>::type; /// \brief Compile time deduced information about a type class Type_Info @@ -151,7 +145,7 @@ namespace chaiscript std::is_void::value, std::is_arithmetic::value && !std::is_same::type, bool>::value, &typeid(T), - &typeid(typename Bare_Type::type)); + &typeid(Bare_Type)); } }; @@ -166,7 +160,7 @@ namespace chaiscript std::is_void::value, std::is_arithmetic::value && !std::is_same::type, bool>::value, &typeid(std::shared_ptr ), - &typeid(typename Bare_Type::type)); + &typeid(Bare_Type)); } }; @@ -181,7 +175,7 @@ namespace chaiscript std::is_void::value, std::is_arithmetic::value && !std::is_same::type, bool>::value, &typeid(const std::shared_ptr &), - &typeid(typename Bare_Type::type)); + &typeid(Bare_Type)); } }; @@ -196,7 +190,7 @@ namespace chaiscript std::is_void::value, std::is_arithmetic::value && !std::is_same::type, bool>::value, &typeid(std::reference_wrapper ), - &typeid(typename Bare_Type::type)); + &typeid(Bare_Type)); } }; @@ -211,15 +205,10 @@ namespace chaiscript std::is_void::value, std::is_arithmetic::value && !std::is_same::type, bool>::value, &typeid(const std::reference_wrapper &), - &typeid(typename Bare_Type::type)); + &typeid(Bare_Type)); } }; - template - struct Stripped_Type - { - typedef typename Bare_Type::type>::type type; - }; } /// \brief Creates a Type_Info object representing the type passed in