Boost logo

Boost :

From: Joe Gottman (jgottman_at_[hidden])
Date: 2008-04-03 19:35:32

Peter Dimov wrote:
> Joe Gottman quite correctly points out in
> that shared_ptr should honor user definitions of BOOST_DISABLE_THREADS and
> disable MT support.
> Unfortunately, despite documenting quite clearly that BOOST_DISABLE_THREADS
> is a user macro, Boost.Config defines it in some situations. This means that
> I can't rely on this macro to reflect the user's intent, as I don't know
> whether it's been set explicitly by the user, or implicitly (and incorrectly
> IMO) by Boost.Config.
> _______________________________________________
> Unsubscribe & other changes:

    The code in suffix.hpp looks like

#if defined(BOOST_DISABLE_WIN32) && defined(_WIN32) \
    && !defined(BOOST_DISABLE_THREADS) && !defined(BOOST_HAS_PTHREADS)

As far as I can tell, the purpose of this is to disable threading if
Windows is disabled and there is no other threading system available. I
think we can get the same result in a much clearer fashion without
touching BOOST_DISABLE_THREADS by the following:

#if defined(BOOST_DISABLE_WIN32) && defined(_WIN32)

Joe Gottman

Boost list run by bdawes at, gregod at, cpdaniel at, john at