summaryrefslogtreecommitdiffstats
path: root/clang/test/CXX/class/class.mem/p13.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Related to PR37768: improve diagnostics for class name shadowing.Richard Smith2018-06-201-0/+47
| | | | | | | | | | | | Diagnose the name of the class being shadowed by using declarations, and improve the diagnostics for the case where the name of the class is shadowed by a non-static data member in a class with constructors. In the latter case, we now always give the "member with the same name as its class" diagnostic regardless of the relative order of the member and the constructor, rather than giving an inscrutible diagnostic if the constructor appears second. llvm-svn: 335182
* Fix half of PR26048. We don't yet diagnose the case where the anonymous ↵Richard Smith2016-01-061-2/+2
| | | | | | union member is declared first and the tag name is declared second. llvm-svn: 256979
* DR1909: Diagnose all invalid cases of a class member sharing its name with ↵Richard Smith2015-07-061-6/+35
| | | | | | the class. llvm-svn: 241425
* Modify how the -verify flag works. Currently, the verification string andRichard Trieu2011-12-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | diagnostic message are compared. If either is a substring of the other, then no error is given. This gives rise to an unexpected case: // expect-error{{candidate function has different number of parameters}} will match the following error messages from Clang: candidate function has different number of parameters (expected 1 but has 2) candidate function has different number of parameters It will also match these other error messages: candidate function function has different number of parameters number of parameters This patch will change so that the verification string must be a substring of the diagnostic message before accepting. Also, all the failing tests from this change have been corrected. Some stats from this cleanup: 87 - removed extra spaces around verification strings 70 - wording updates to diagnostics 40 - extra leading or trailing characters (typos, unmatched parens or quotes) 35 - diagnostic level was included (error:, warning:, or note:) 18 - flag name put in the warning (-Wprotocol) llvm-svn: 146619
* Diagnose C++ [class.mem]p13-14, where a class member has the same nameDouglas Gregor2010-10-151-0/+40
as the class itself. Fixes PR7082. llvm-svn: 116573
OpenPOWER on IntegriCloud