Subject: Re: [SG10] [isocpp-core] P1907R1 should have updated a feature test macro
From: Richard Smith (richardsmith_at_[hidden])
Date: 2019-11-13 18:49:52
On Wed, Nov 13, 2019 at 4:15 PM Barry Revzin via Core <core_at_[hidden]>
> On Wed, Nov 13, 2019, 6:08 PM David Vandevoorde via Core <
> core_at_[hidden]> wrote:
>> > On Nov 13, 2019, at 6:56 PM, Richard Smith via Core <
>> core_at_[hidden]> wrote:
>> > Hi core and SG10!
>> > (Noticed by Jens when reviewing the merge of CWG motion 8.)
>> > P1907R1 made significant changes to the behavior of non-type template
>> parameters. It should have affected some feature-test macro, but didn't.
>> Should we bump the version of __cpp_nontype_template_args or
>> A bump in __cpp_nontype_template_parameter_class seems appropriate to me.
> I agree. This is the one introduced by P0732. I'd emailed Jens on Friday
> to say the same but he missed the email.
Maybe we should bump both macros? P1907 also allows more kinds of NTTP
argument (eg, pointers/references to subobjects) and more kinds of
parameter (eg, floating-point parameters), not just classes.
That said... I'm actually more inclined to say we should remove
__cpp_nontype_template_parameter_class entirely and just bump
__cpp_nontype_template_args. No-one ever fully implemented
__cpp_nontype_template_parameter_class as far as I'm aware, and the feature
we ended up with isn't class-type-specific (what we have now is "anything
fully constant other than non-public subobjects or rvalue references").
Is this editorial or does this need to go through a paper/issue?
If there's no objection from either CWG or SG10, I'd be prepared to make a
change editorially. (We bump __cplusplus editorially, and this seems to be
in a somewhat similar bucket.)
SG10 list run by firstname.lastname@example.org