summaryrefslogtreecommitdiffstats
path: root/clang/test/CXX/basic/basic.lookup/basic.lookup.unqual
Commit message (Collapse)AuthorAgeFilesLines
* Add -std=c++20 flag, replace C++2a with C++20 throughout the ClangRichard Smith2020-02-191-2/+2
| | | | | | | | | | | | | user interface and documentation, and update __cplusplus for C++20. WG21 considers the C++20 standard to be finished (even though it still has some more steps to pass through in the ISO process). The old flag names are accepted for compatibility, as usual, and we still have lots of references to C++2a in comments and identifiers; those can be cleaned up separately. (cherry picked from commit 24ad121582454e625bdad125c90d9ac0dae948c8)
* [c++20] Implement P0846R0: allow (ADL-only) calls to template-ids whoseRichard Smith2019-05-091-9/+51
| | | | | | | | | | | | | | | | | | | | | | | | | template name is not visible to unqualified lookup. In order to support this without a severe degradation in our ability to diagnose typos in template names, this change significantly restructures the way we handle template-id-shaped syntax for which lookup of the template name finds nothing. Instead of eagerly diagnosing an undeclared template name, we now form a placeholder template-name representing a name that is known to not find any templates. When the parser sees such a name, it attempts to disambiguate whether we have a less-than comparison or a template-id. Any diagnostics or typo-correction for the name are delayed until its point of use. The upshot should be a small improvement of our diagostic quality overall: we now take more syntactic context into account when trying to resolve an undeclared identifier on the left hand side of a '<'. In fact, this works well enough that the backwards-compatible portion (for an undeclared identifier rather than a lookup that finds functions but no function templates) is enabled in all language modes. llvm-svn: 360308
* The exception-declaration for a function-try-block cannot redeclare aAaron Ballman2014-06-021-2/+6
| | | | | | | function parameter. One of our existing test cases was XFAILed because of this. This fixes the issue and un-XFAILs the test. llvm-svn: 210026
* Test requires exceptionsAlp Toker2014-05-281-1/+1
| | | | | | It's still XFAIL, but slightly closer to passing. llvm-svn: 209729
* Skip transparent contexts when looking for using directives in name lookup.Douglas Gregor2013-04-091-4/+8
| | | | | | Fixes the bootstrap regression I introduced in r179067. llvm-svn: 179079
* <rdar://problem/13540899> Collect using directives from all of the semantic ↵Douglas Gregor2013-04-081-0/+19
| | | | | | | | | | | | contexts not represented by scopes. This fixes a regression I introduced in r178136, where we would not consider the using directives from the semantic declaration contexts that aren't represented by the lexical scopes (Scope) when performing unqualified name lookup. This lead to horribly funny diagnostics like "no identifier named 'foo'; did you mean 'foo'?". llvm-svn: 179067
* <rdar://problem/13317030> Consider using directives when performing ↵Douglas Gregor2013-03-271-0/+30
| | | | | | unqualified name lookup into declarations contexts represented by the qualified-id but not in the actual scope hierarchy. llvm-svn: 178136
* Add quotation marks to template names in diagnostics.David Blaikie2013-03-051-1/+1
| | | | llvm-svn: 176474
* Prior to adding the new "expected-no-diagnostics" directive to ↵Andy Gibbs2012-10-194-0/+4
| | | | | | VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive. llvm-svn: 166280
* When a template (without arguments) is passed as a template typeJeffrey Yasskin2010-04-081-2/+2
| | | | | | | parameter, explicitly ask the user to give it arguments. We used to complain that it wasn't a type and expect the user to figure it out. llvm-svn: 100729
* Switch Sema::AddCXXDirectInitializerToDecl over to InitializationSequenceDouglas Gregor2009-12-221-1/+1
| | | | llvm-svn: 91927
* Enter the scope of an initializer for direct-initialization as well asDouglas Gregor2009-12-221-0/+2
| | | | | | for copy-initialization. llvm-svn: 91909
* Don't inject the class name until that magical lbrace.John McCall2009-12-201-0/+8
| | | | | | | | | | | | | | | | Because of the rules of base-class lookup* and the restrictions on typedefs, it was actually impossible for this to cause any problems more serious than the spurious acceptance of template <class T> class A : B<A> { ... }; instead of template <class T> class A : B<A<T> > { ... }; but I'm sure we can all agree that that is a very important restriction which is well worth making another Parser->Sema call for. (*) n.b. clang++ does not implement these rules correctly; we are not ignoring non-type names llvm-svn: 91792
* Test the lookup I wasn't sure would be done properly after the last patch.John McCall2009-12-201-5/+25
| | | | | | | | | Clang reasonably adds all the base specifiers in one pass; this is now required for correctness to prevent lookup from going mad. But this has the advantage of establishing the correct context when looking up base specifiers, which will be important for access control. llvm-svn: 91791
* Parse base specifiers within the scope of the class. This is possibly notJohn McCall2009-12-191-0/+9
| | | | | | quite right; I'll come back to it later. It does fix PR 5741. llvm-svn: 91789
* Just push a new scope when parsing an out-of-line variable definition.John McCall2009-12-191-1/+6
| | | | | | | Magically fixes all the terrible lookup problems associated with not pushing a new scope. Resolves an ancient xfail and an LLVM misparse. llvm-svn: 91769
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-156-6/+6
| | | | | | | | | - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). llvm-svn: 91446
* Tweak expected error message, although we still fail this testDouglas Gregor2009-11-251-1/+1
| | | | llvm-svn: 89875
* Switch XFAIL format to match LLVM.Daniel Dunbar2009-11-032-2/+2
| | | | llvm-svn: 85880
* First pass at friend semantics.John McCall2009-08-061-3/+1
| | | | llvm-svn: 78274
* Implement correct name lookup inside an initializer of a C++ class static ↵Argyrios Kyrtzidis2009-06-171-1/+0
| | | | | | | | data member. Fixes "test/CXX/basic/basic.lookup/basic.lookup.unqual/p13.cpp" test case. llvm-svn: 73652
* More [basic.lookup.unqual] tests.Daniel Dunbar2009-06-155-0/+62
| | | | | | - p13 and p14 are important failures. llvm-svn: 73392
* Test for [basic.lookup.unqual]p3Daniel Dunbar2009-06-151-0/+26
- Failing, at least in part, because lookup in parser is finding a friend function where it shouldn't. llvm-svn: 73388
OpenPOWER on IntegriCloud