Use conforming is_class for EDG compilers

Make is_enum work for class types which are convertible to anything at
all (on many compilers).

smart_ptr library workarounds for __MWERKS__ (must use member function
pointer for unspecified_bool_type).


[SVN r20244]
This commit is contained in:
Dave Abrahams
2003-10-02 17:49:06 +00:00
parent 26a93f224e
commit feff6e40ea
4 changed files with 35 additions and 4 deletions

View File

@ -102,7 +102,15 @@ public:
return px != 0;
}
#else
#elif defined(__MWERKS__) && BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3003))
typedef T * (this_type::*unspecified_bool_type)() const;
operator unspecified_bool_type() const // never throws
{
return px == 0? 0: &this_type::get;
}
#else
typedef T * this_type::*unspecified_bool_type;