Boost logo

Boost :

From: Jonathan D. Turkanis (technews_at_[hidden])
Date: 2003-12-05 16:37:50


"Jaakko Jarvi" <jajarvi_at_[hidden]> wrote in message:
> Is this what you have in mind?
>
> #ifndef BOOST_NO_SFINAE
>
> // real enable_if
>
> #else
>
> template<class T> struct enable_if {
> BOOST_STATIC_ASSERT(false); // enable_if is known not to work
> };
>
> // same for enable_if_c, lazy_enable_if, ...
>
> #endif

That's it.

Or BOOST_STATIC_ASSERT(!BOOST_NO_SFINAE), for self-documentation.

Jonathan


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