Boost logo

Boost :

From: David Abrahams (david.abrahams_at_[hidden])
Date: 2002-03-20 13:10:42


----- Original Message -----
From: "Yitzhak Sapir" <yitzhaks_at_[hidden]>

> I couldn't get it to work for MSVC6. In fact, I had problems calling
a
> templated function in sizeof in a a class definition. The solution I
> had sent here about a week ago makes use of a bug similar to the one
we
> had before. In particular, the following function:
> template <class T> T* make_tptr(wraps<T>);
> is instantiated as T** make_tptr(wraps<T*>); when called as
> make_tptr(wraps<X&>)
>
> I also tried an alternative implementation of is_class that is based
on
> inheritance. It doesn't work with MSVC6.5 though.

I suggest looking at the current implementation of is_array and
is_reference in boost/type_traits/array_traits.hpp and
boost/type_traits/reference_traits.hpp.

These work with msvc6 and you should be able to make variations on the
same theme work for is_class.

-Dave


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk