Add explanation of "in", "of", "names", "denotes", and "designates"#950
Add explanation of "in", "of", "names", "denotes", and "designates"#950eisenwave wants to merge 2 commits into
Conversation
| appears directly in the definition of *template-parameter*, | ||
| and *type-specifier* is nested several levels deep into *parameter-declaration* | ||
| (*type-specifier* → *defining-type-specifier* → *decl-specifier* → *decl-specifier-seq* | ||
| → *parameter-declaration*). |
There was a problem hiding this comment.
... and that example shows why "in" is generally bad: The parameter-declaration can have a type-specifier in different places: as a top-level decl-specifier or as a type-specifier in a parameter-declaration of a function type that appears in the outer parameter-declaration. Maybe add a sentence explaining that?
There was a problem hiding this comment.
It turns out we already had a short description of "in" vs. "of" in the guidelines that even came with a negative example.
I've absorbed that into the new section that goes a bit more into detail now.
I think it's still worth the upgrade and having a dedicated section on it, just because of how common these terms are, and I'd like to keep the <dl> list element style going throughout the guidelines. It's also easier to link by #anchor if you have a dedicated subsection.
There was a problem hiding this comment.
The Tip portion also adds value because paper authors might feel forced into using "in" if there isn't a single-level, direct relationship between two things, and we wouldn't want them to get that impression. Using chains of of is also possible.
I've had a chat in the CWG Mattermost channel, and there looks to be some appetite for explaining more CWG wording idioms.
We can start with "in" vs. "of", as well as "names"/"denotes"/"designates'. These idioms are used all the time, and it would be nice to have something to point authors at.