Boost logo

Boost :

Subject: Re: [boost] New library proposal: Autodiff
From: John Maddock (jz.maddock_at_[hidden])
Date: 2018-12-19 20:33:38

>> - C++17 compiler that supports constexpr if statements. There are a fair
>> amount of calculations done at compile-time which would require messy
>> SFINAE hacks to make this C++14-compatible.
> I know my position is unpopular, but I don't think this is a good
> tradeoff. Supporting C++11 certainly requires more work on the
> author's part but that is a finite investment. The return on this is a
> practically unbounded amount of utility, as the number of users is
> normally expected to greatly outnumber the amount of authors (1 in
> this case). In fact you could argue that there is infinite utility in
> laboring to produce "messy SFINAE hacks", because otherwise users of
> C++14 and C++11 cannot use the library at all. Most users only care
> that the library works, and are unaffected by the particulars of the
> sausage-making.
> In general, I feel like it is a good engineering practice for Boost
> libraries to only require C++14 or C++17 when absolutely necessary. In
> this case it does not seem necessary. This year's developer surveys
> indicate that C++11 has the most widespread use:

I get that, and haven't looked in detail at the code yet, but for the
record, for Math heavy code, "if constexpr" is probably more useful than
anything else in C++11 and 14.... the next "biggy" is C++20's
is_constant_evaluated which is likely to make a lot of things that can't
quite be fully constexpr yet, more or less possible in the future
(Boost.Multiprecision for one).


This email has been checked for viruses by Avast antivirus software.

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