Title
§[c.math] Can any of float/double/long double overloads be fused into template overloads?
Status
new
Section
[c.math]
Submitter
Jiang An

Created on 2022-04-28.00:00:00 last changed 31 months ago

Messages

Date: 2022-05-15.00:00:00

[ 2022-05-17; Reflector poll ]

Set priority to 2 after reflector poll. One vote for NAD.

Date: 2022-04-28.00:00:00

IIUC LWG 3234 will be resolved by the recently approved paper P1467R9. While considering adding the newly required overloads of math special functions to MSVC STL, I found that it may be more convenient to implement the whole overload set as a single function template.

However, it's unclear for me whether the every "overload for each cv-unqualified floating-point type", or every currently separately shown overloads in the synopsis of <cmath>, is required to be a separated function. As discussed in microsoft/STL#1335, if there were only a separated double overload (usually comes from the C standard library) and a fused template overload, calling the overload set with {} would be accepted, which is definitely ambiguous when there are separated float/double/long double overloads.

I think it may be better to allow implementations to arbitrarily fuse the required overloads.

History
Date User Action Args
2022-05-17 11:58:16adminsetmessages: + msg12465
2022-04-28 00:00:00admincreate