Boost logo

Boost :

From: Daniel Frey (d.frey_at_[hidden])
Date: 2003-02-15 12:41:55

And just for your amusement:

#include <boost/type_traits.hpp>
// #include <mfl/type_traits.hpp>
namespace test = boost;

class A {};

int main()
    typedef test::remove_pointer< int A::* >::type t1;
    typedef test::remove_pointer< int A::* const >::type t2;
    typedef test::remove_pointer< int A::* volatile >::type t3;
    typedef test::remove_pointer< int A::* const volatile >::type t4;

    typedef test::add_const< int( int ) >::type t5;
    typedef test::add_volatile< int( int ) >::type t6;
    typedef test::add_cv< int( int ) >::type t7;

    typedef char t8[ test::is_convertible< double, int >::value ];
    typedef char t9[ !test::is_class< int( int ) >::value ];
    typedef char t10[ !test::is_enum< int( int ) >::value ];

My implementation of type-traits doesn't give a single warning, but boost
gives me (for the GCC 3.2.2) several pages full or errors and warnings.

I won't try to fix any of these anymore. I neither understand the
documentation nor the implementation of boost's type-traits. I tried to
make the code better but AFAICS there is no interest in improvment.


Boost list run by bdawes at, gregod at, cpdaniel at, john at