[PATCH] D39937: [Sema] Improve diagnostics for const- and ref-qualified member functions

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 15 11:07:51 PST 2017


aaron.ballman added reviewers: rsmith, aaron.ballman.
aaron.ballman added a comment.

I think the new wording is a bit more clear, in general.



================
Comment at: include/clang/Basic/DiagnosticSemaKinds.td:1595-1597
+def err_member_function_call_other : Error<
+  "cannot initialize object parameter of type %0 with an expression "
+  "of type %1">;
----------------
I don't think this diagnostic needs to be moved and renamed; the old name was more clear than "other" on the new name.


================
Comment at: test/CXX/over/over.match/over.match.funcs/p4-0x.cpp:22-24
+  void lvalue() &; // expected-note 2 {{'lvalue' declared here}}
+  void const_lvalue() const&;
+  void rvalue() &&; // expected-note {{'rvalue' declared here}}
----------------
Can you add examples that cover the other diagnostic wordings as well (volatile, restrict, combinations, etc)?


https://reviews.llvm.org/D39937





More information about the cfe-commits mailing list