[class.copy.ctor][class.copy.assign] Tweak style and indexing for copy/move constructors and assignment operators, remove "user-declared"#8195
Conversation
| A \defnadj{move}{assignment operator} \tcode{X::operator=} is | ||
| a non-static non-template member function of class \tcode{X} with exactly |
There was a problem hiding this comment.
I don't like that for copy constructors, X is first introduced as
A non-template constructor for class
X
... but down here, it's phrased as
... is a non-static non-template member function of class
X
Surely, we can make the wording for all these special member functions more symmetrical, and be more consistent about whether X or X::operator= is introduced first.
It also feels a bit redundant that we need to state that operator= is a non-static member function. Shouldn't that be obvious from its code spelling?
There was a problem hiding this comment.
We're also inconsistent about "for class" vs. "of class".
There was a problem hiding this comment.
We're inconsistent about a lot of things across the standard. The present pull request seems like a pure indexing improvement and thus can be reviewed/applied a lot quicker than changes beyond that. Don't do that here.
There was a problem hiding this comment.
To be fair, it's not just a pure indexing change. The PR also removes the term "user-declared" from wording. I wouldn't have said anything if that wasn't the case. I can live with the consistency tweaks being done separately though.
There was a problem hiding this comment.
Removal of "user-declared" was planned for discussion in 2017 (#556 (comment)). I think this can be applied together (otherwise we might need another issue for it).
Terms copy constructor, move constructor, copy assignment operator, and move assignment operator should be italicized as a whole.
\defnadjseems appropriate for this.Some
\indextextseem attached to wrong paragraphs, so this PR moves them.It's probably superfluous to say "user-declared" as the implicitly declared ones are arguably left uncovered.
Fixes #556.