Boost logo

Boost :

From: Markus Schöpflin (markus.schoepflin_at_[hidden])
Date: 2002-10-01 06:08:22


Björn Karlsson wrote:
>
> Argh. Ok, assuming that only STLPort also defines _YVALS in this context,
> this would work:
>
> #if (defined(_MSC_VER) && (_MSC_VER <= 1300)) && ((!defined(_CPP_LIB_VER) &&
> defined(_YVALS) && !defined(__SGI_STL_PORT)) || (defined(_CPPLIB_VER) &&
> (_CPPLIB_VER < 306)))
>
> And it's so elegant and readable, too. :-)
>

The config check for STLport is

 defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)

So I think we should be ok with

#if (defined(_MSC_VER) && (_MSC_VER <= 1300)) // msvc <= 7.0
&& !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) // no stlport
&& (
  (!defined(_CPP_LIB_VER) && defined(_YVALS)) // old dinkumware
  ||
  (defined(_CPPLIB_VER) && (_CPPLIB_VER < 306)) // newer dinkumware
)

Luckily, there are only two places to apply this. Maybe add some config
macro to dynamic_bitset.hpp?

#if (defined(_MSC_VER) && (_MSC_VER <= 1300)) // msvc <= 7.0
  && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) // no stlport
  && (
    (!defined(_CPP_LIB_VER) && defined(_YVALS)) // old dinkumware
    ||
    (defined(_CPPLIB_VER) && (_CPPLIB_VER < 306)) // newer dinkumware
  )
# define BOOST_DYNAMIC_BITSET_HAVE_MSVC_ALLOCATOR
#endif

And later on

#ifdef BOOST_DYNAMIC_BITSET_HAVE_MSVC_ALLOCATOR
...
#else
...
#endif

Markus

PS: Whatever we do, someone should run a regression test on the platform
in question after we apply this patch!


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