llvm-project/clang/test/CXX
Reid Kleckner 1a4ab7e772 Improve error message when referencing a non-tag type with a tag
Other compilers accept invalid code here that we reject, and we need a
better error message to try to convince users that the code is really
incorrect. Consider:
  class Foo {
    typedef MyIterHelper<Foo> iterator;
    friend class iterator;
  };

Previously our wording was "elaborated type refers to a typedef".
"elaborated type" isn't widely known terminology, so the new diagnostic
says "typedef 'iterator' cannot be referenced with class specifier".

Reviewers: rsmith

Differential Revision: https://reviews.llvm.org/D25216

llvm-svn: 289259
2016-12-09 19:47:58 +00:00
..
basic Improve error message when referencing a non-tag type with a tag 2016-12-09 19:47:58 +00:00
class Fix all tests under test/CXX (and test/Analysis) to pass if clang's default 2016-08-31 23:24:08 +00:00
class.access Fix all tests under test/CXX (and test/Analysis) to pass if clang's default 2016-08-31 23:24:08 +00:00
class.derived When diagnosing that a defaulted function is ill-formed because it would be 2016-10-31 18:18:29 +00:00
concepts-ts/dcl.dcl/dcl.spec/dcl.spec.concept [Concepts] Implement subsection [dcl.spec.concept]p7 of the Concepts TS 2016-04-09 02:55:27 +00:00
conv [c++1z] P0003R5: Removing dynamic exception specifications. 2016-12-08 02:49:07 +00:00
cpp/cpp.predefined P0035R4: add predefined __STDCPP_DEFAULT_NEW_ALIGNMENT__ macro. By default, we 2016-09-30 22:41:36 +00:00
dcl.dcl Improve error message when referencing a non-tag type with a tag 2016-12-09 19:47:58 +00:00
dcl.decl DR1295 and cleanup for P0135R1: Make our initialization code more directly 2016-12-09 18:49:13 +00:00
drs Improve error message when referencing a non-tag type with a tag 2016-12-09 19:47:58 +00:00
except P0012R1: Make exception specifications be part of the type system. This 2016-10-16 17:54:23 +00:00
expr [c++1z] P0003R5: Removing dynamic exception specifications. 2016-12-08 02:49:07 +00:00
lex Convert test/CXX/lex/lex.literal/lex.string/p4.cpp back to DOS line 2016-01-04 10:17:48 +00:00
over Add a note that points to the linkage specifier for the C++ linkage errors 2016-11-02 15:46:34 +00:00
special When diagnosing that a defaulted function is ill-formed because it would be 2016-10-31 18:18:29 +00:00
stmt.stmt Try contextually converting condition of constexpr if to Boolean value 2016-09-07 18:24:54 +00:00
temp Improve error message when referencing a non-tag type with a tag 2016-12-09 19:47:58 +00:00