OSDN Git Service

type_traits/is_convertible.hpp: 別にis_convertible_funcにFROMなくて良くねぇか。と言うことに気付いた。
authorMyun2 <myun2@nwhite.info>
Thu, 16 Sep 2010 14:43:43 +0000 (23:43 +0900)
committerMyun2 <myun2@nwhite.info>
Thu, 16 Sep 2010 14:43:43 +0000 (23:43 +0900)
roast/include/roast/type_traits/is_convertible.hpp

index 59d4bf6..4443c17 100644 (file)
@@ -15,24 +15,28 @@ namespace roast
                typedef char is_not_convertible_t;
 
                
-               template <typename FROM, typename TO>
+               template <typename TO>
                //is_convertible_t is_convertible_func<TO,TO>(TO in);
                is_convertible_t is_convertible_func(TO in);
                
-               template <typename FROM, typename TO>
+               template <typename TO>
                //is_not_convertible_t is_convertible_func(FROM in);
                is_not_convertible_t is_convertible_func(...);
                
+               /*template <typename FROM, typename TO>
+               bool is_convertible_f(FROM from)
+               {
+               }*/
                
                template <typename FROM, typename TO>
                struct is_convertible
                {
                        static const bool value = (
                                sizeof( is_convertible_t ) ==
-                               sizeof( is_convertible_func<FROM,TO>(FROM()) )
+                               sizeof( is_convertible_func<TO>(FROM()) )
                                );
                };
-               
+
                //////////////////////////////////////
        }
 }