diff --git a/toml/traits.hpp b/toml/traits.hpp index a565d86..7711900 100644 --- a/toml/traits.hpp +++ b/toml/traits.hpp @@ -60,13 +60,14 @@ struct has_resize_method_impl struct has_from_toml_method_impl { - template + template class Tb, template class A> static std::true_type check( - decltype(std::declval().from_toml(std::declval<::toml::basic_value< - ::toml::discard_comments, std::unordered_map, std::vector>>() - ) - )*); - template + decltype(std::declval().from_toml( + std::declval<::toml::basic_value>()))*); + + template class Tb, template class A> static std::false_type check(...); }; struct has_into_toml_method_impl @@ -94,9 +95,11 @@ struct has_mapped_type : decltype(has_mapped_type_impl::check(nullptr)){}; template struct has_resize_method : decltype(has_resize_method_impl::check(nullptr)){}; -template +template class Tb, template class A> struct has_from_toml_method -: decltype(has_from_toml_method_impl::check(nullptr)){}; +: decltype(has_from_toml_method_impl::check(nullptr)){}; + template struct has_into_toml_method : decltype(has_into_toml_method_impl::check(nullptr)){};