-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CWG2537 [dcl.fct] Overbroad grammar for parameter-declaration #7
Comments
[dcl.stc]/4, /5, [dcl.typedef]/1, and [dcl.inline]/4 can be simplified by removing references to function parameters. |
Fixed. I also found one more. |
Don't keep me in such suspense—what's the one more? |
I did, but I see edits to only the four places I found. |
Ah, sorry, I had overlooked the /5 in your list. So, nothing extra. Sorry for the noise. |
In review yesterday we realized that the even narrower type-specifier-seq would be sufficient, which could replace part of [dcl.fct]/17. Several places do use decl-specifier-seq to refer to the appropriate part of any declaration, which would need updating here:
The sensible thing to do would presumably be to introduce a term (e.g., "the specifiers of a declaration are…") and use that everywhere. This is a larger change, of course, and might not be worth doing, although there the indicated places in the above list need work anyway. |
Full name of submitter (unless configured in github; will be published with the issue): Davis Herring
Reference (section label): dcl.fct 9.3.4.6
Link to reflector thread (if any): cplusplus/draft#4521
Issue description:
It should have a defining-type-specifier-seq instead of a decl-specifier-seq, since no other decl-specifier (a storage-class-specifier, a function-specifier,
friend
,typedef
,constexpr
,consteval
,constinit
, orinline
) can be used there (unless we expect to get constexpr function parameters any day now!).Suggested resolution:
The text was updated successfully, but these errors were encountered: