Boost logo

Boost :

Subject: Re: [boost] [outcome] Second high level summary of review feedback accepted so far
From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2017-05-30 18:05:19


On Tue, May 30, 2017 at 10:53 AM, Niall Douglas via Boost <
boost_at_[hidden]> wrote:

> On 30/05/2017 18:43, Peter Dimov via Boost wrote:
> > Niall Douglas wrote:
> >
> >> Do you accept that the static checked and runtime checked varieties
> >> are orthogonal user bases? There is a camp of users who strongly
> >> prefer no runtime overhead and static checking.
> >
> > Why are their needs not served by value_if?
> >
> > auto r = function();
> >
> > if( auto* p = r.value_if() )
> > {
> > // use *p
> > // no runtime overhead on using *p
> > // static checkers know use of *p implies p != nullptr
> > }
> >
> > Between this pattern and using `assert( r.has_value() )` directly to
> > advise the static checker, are we not covered?
>
> I'm still pondering your idea on this for the runtime checked editions.
> So far I am liking it, but I need to sleep on it some more.
>
> But there was still a large minority of folk who want all-narrow
> observers. They haven't voiced anything to say they have changed their
> minds.
>
> I currently, roughly speaking, find approx 50% in favour of a runtime
> checked edition, approx 40% in favour of a statically checked edition.
>
> Emil and Vicente make up the 10% of folk who want something completely
> different.
>

It is probably not a good idea to measure correctness by popular opinion,
especially if the popular opinion originates in the group that won't use
exceptions "because they're slow". In my experience such people will always
find "Overhead!!!" in any implementation.


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