Boost logo

Boost :

Subject: Re: [boost] boost::mpl::for_each and value_initialized
From: Niels Dekker - address until 2010-10-10 (niels_address_until_2010-10-10_at_[hidden])
Date: 2010-01-26 10:27:40

>> Anyway, I wouldn't mind if the memset call in utility/value_init.hpp
>> would become conditional, for example as follows:
>> std::memset(&x, 0, sizeof(x));
>> #endif

Fernando (the author of value_init) mailed me that it's okay to him if I add
an #ifdef like that to utility/value_init.hpp. Still I think it would be
useful to have the issue officially reported. Aleksey, were you already
planning to open a ticket on this issue? If so, please do! And please feel
free to assign the ticket to niels_dekker :-)

Of course, <boost/config/compiler/...> also needs to have
BOOST_VALUE_INITIALIZATION_NEEDS_MEMSET added to various compiler versions:

  MSVC (all versions)
  Borland/Codegear build < 12.0.3140.16150
  Sun (possibly all versions, I don't know exactly)
  GCC < 4.4.0

>> What do you think? And would it be okay to you to have such a macro,
>> boost/config/compiler/, for those specific compiler versions?

Aleksey Gurtovoy wrote:
> Sounds good to me. John?

Hope it's okay to John as well.

Kind regards,


Niels Dekker
Scientific programmer at LKEB, Leiden University Medical Center

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