Subject: Re: [boost] [config] [regression] Regression test failures due to compiler bugs -- your advice needed
From: formiaczek (lukasz.forynski_at_[hidden])
Date: 2015-01-22 04:28:29
Andrey Semashev-2 wrote
> On Thu, Jan 22, 2015 at 12:27 AM, Peter Dimov <
> > wrote:
>> Andrzej Krzemienski wrote:
>>> Are you saying that on a compiler where an operation on
>>> optional<T&> might
>>> give wrong run-time result, the operation should be disabled (render a
>>> compile-time error)?
>> I think that am I saying that if an operation on optional<T&>
>> is apt to
>> result in dangling pointers on many popular compilers, the operation
>> be disabled for all compilers for consistency, not just those that will
>> exhibit the failure. This interface is obviously too dangerous to be of
>> use and, while it will work on some compilers, its use will not be
> It's also possible to make the feature optional, so that it can be
> enabled by a macro.
On a recent project I did come across this with optional references: we
to do exactly that: disabled them with optional macro to re-enable them.
Mind that optional references are easily replaceable by raw pointers ->
the same syntax as optionals and are plain simple.
-- View this message in context: http://boost.2283326.n4.nabble.com/config-regression-Regression-test-failures-due-to-compiler-bugs-your-advice-needed-tp4671425p4671495.html Sent from the Boost - Dev mailing list archive at Nabble.com.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk