cplusplus / draft

C++ standards drafts
http://www.open-std.org/jtc1/sc22/wg21/
5.64k stars 742 forks source link

Non grammatical term initializer is used like a language construct but not defined #3197

Open sdkrystian opened 5 years ago

sdkrystian commented 5 years ago

While the grammatical term initializer has a definition, initializer as used throughout the standard is not defined anywhere, and since it is used as if it is a langauge construct, a definition should be specified, just like it is in the C11 standard. Such a definition should include grammatical initializers, as well as initializer-clauses (for function calls as the arguments are initializers, but not initializers)

jensmaurer commented 4 years ago

See also #2847.

jensmaurer commented 4 years ago

Editorial teleconference: Defining a term "initializer" is problematic, because the very definition could be confused with the grammarterm. But we do something similar for "expression". This would be helped if grammar would use a different font; see #323. Maybe turn uses of grammarterms into links to their definition (will make them blue). In any case, defer until we have distinct presentation for grammarterms vs. defined terms.

jensmaurer commented 4 years ago

We now have a distinct presentation for grammarterms vs. defined terms.

jensmaurer commented 4 years ago

Editorial meeting: We want /initializer/ plus function arguments plus return/throw operands and other operands (e.g. co_await) and to overloaded operators. -> function arguments after rewriting. Sometime determine the kind of initialization from /initializer/, except that you don't in the other cases. Maybe embody that in the transition from /initializer/ to initializer.