Boost logo

Boost :

From: Jaap Suter (J.Suter_at_[hidden])
Date: 2003-03-12 05:15:48


>> Well, considering that what we want is just a no-op, which do you
>> prefer?
>>
>> a) typedef ::boost::static_assert_test<
>> sizeof(::boost::STATIC_ASSERTION_FAILURE< (bool)( true ) >)>
>> BOOST_JOIN(boost_static_assert_typedef_, _LINE_);
>>
>> (I've just picked up one of the implementations in static_assert.hpp,
>> but the others don't differ too much.)
>>
>>
>> b) typedef void boost_static_assert_typedef;
>
> The effect is the same.
> However, (a) or BOOST_STATIC_ASSERT_IMPL( true ) avoids all of the
> (potential?) problems you are worrying about. So why do you prefer
> (b)?

Because if we do this to save time, we might as well make sure that we save
as much time as possible.

Benchmarks coming up soon.

Cheers,

Jaap Suter


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