You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After submitting #6465, I feel like the wording for saying what a return type of void means is out-of-place. [basic.fundamental] p15 says:
It is used as the return type for functions that do not return a value.
This wording is redundant, as the meaning of return type void and calls to functions with return type void emerges from other parts of the standard. It even emerges from the paragraph itself because if "such a type has an empty set of values", it is obvious that a function with return type void cannot return a value.
Furthermore, this is too specific for [basic.fundamental]. If we're already explaining what a return type of void does here, why not also explain what a parameter-list containing just void means?
Suggested Change
A type cv void is an incomplete type that cannot be completed; such a type has an empty set of values.
-It is used as the return type for functions that do not return a value.
[...]
+[ Note: A function with a cv void return type does not return a value. -- end note ]
Alternatively, remove this sentence completely and leave no note.
The text was updated successfully, but these errors were encountered:
After submitting #6465, I feel like the wording for saying what a return type of
void
means is out-of-place. [basic.fundamental] p15 says:This wording is redundant, as the meaning of return type
void
and calls to functions with return typevoid
emerges from other parts of the standard. It even emerges from the paragraph itself because if "such a type has an empty set of values", it is obvious that a function with return typevoid
cannot return a value.Furthermore, this is too specific for [basic.fundamental]. If we're already explaining what a return type of
void
does here, why not also explain what a parameter-list containing justvoid
means?Suggested Change
Alternatively, remove this sentence completely and leave no note.
The text was updated successfully, but these errors were encountered: