What does an ampersand after this assignment operator mean?
问题 I was reading through this nice answer regarding the "Rule-of-five" and I've noticed something that I don't recall seeing before: class C { ... C& operator=(const C&) & = default; C& operator=(C&&) & = default; ... }; What is the purpose of the & character placed in front of = default for the copy assignment operator and for the move assignment operator? Does anyone have a reference for this? 回答1: It's part of a feature allowing C++11 non-static member functions to differentiate between