Boost logo

Boost :

From: Douglas Gregor (gregod_at_[hidden])
Date: 2003-10-07 19:36:22


On Tuesday 07 October 2003 04:25 pm, Thomas Witt wrote:
> The review of enable_if submitted Jaakko Järvi & Jeremiah Willcock &
> Andrew Lumsdaine starts today and runs through Sunday, October 12.

I've read through the docs and the source code, and everything looks fine. I
use enable_if in Function with essentially the same interface/implementation
as is here.

The only omission I see is a listing of supported compilers, either in the
source or in the documentation. enable_if doesn't work anywhere, and I've
been trying to catalogue the places it fails. I'd like to have a config macro
BOOST_NO_ENABLE_IF to tell when this library is not available (and, in fact,
the library header should also check this macro: right now, it isn't safe to
include with compilers that don't support partial specialization). My laundry
list of compilers that I couldn't get to work with enable_if follows (it's
from boost/function/function_base.hpp).

I vote to accept this library.

        Doug

// GCC 2.95.3 (or earlier) doesn't support enable_if
#if BOOST_WORKAROUND(__GNUC__, < 3)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif

// MIPSpro 7.3.1.3m doesn't support enable_if
#if defined(__sgi) && defined(_COMPILER_VERSION) && _COMPILER_VERSION <= 730
&& !defined(BOOST_STRICT_CONFIG)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif

// MSVC 7.0 doesn't support enable_if
#if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 && !defined(BOOST_STRICT_CONFIG)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif

// Borland C++ 5.6.0 doesn't support enable_if
#if BOOST_WORKAROUND(__BORLANDC__, <= 0x564)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif

// Metrowerks 7.2 doesn't support enable_if
#if BOOST_WORKAROUND(__MWERKS__, <= 0x2407)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif

#if BOOST_WORKAROUND(__SUNPRO_CC, <= 0x540)
# define BOOST_FUNCTION_NO_ENABLE_IF
#endif


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