Here's an interesting turn-of-the-tables: I was experimenting with
using SFINAE to disable conversion operators, and I discovered that
almost every compiler except vc6/7 rejects this code:

template <class T> struct voidify { typedef void type; };
template <class T> struct Y {};
struct X
{
    template <class T>
    operator Y<T> (typename voidify<T>::type) const { return Y<T>(); }
};
int main()
{
    X x;
    return 0;
}


You can substitute enable_if<condition,void> for voidify to see why I
care; this is just a minimal example.

Note that many of the same compilers will accept voidify<int>::type as
the argument, though!

-- 
                       David Abrahams
   [EMAIL PROTECTED] * http://www.boost-consulting.com
Boost support, enhancements, training, and commercial distribution

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to