summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/recovery-crash.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [c++20] Implement P0846R0: allow (ADL-only) calls to template-ids whoseRichard Smith2019-05-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | 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
* Lit C++11 Compatibility Patch #8Charles Li2016-04-141-3/+11
| | | | | | 24 tests have been updated for C++11 compatibility. llvm-svn: 266387
* [Sema] Avoid crashing during this-> insertion recoveryReid Kleckner2015-09-301-0/+22
| | | | | | | | | We get into this bad state when someone defines a new member function for a class but forgets to add the declaration to the class body. Calling the new member function from a member function template of the class will crash during instantiation. llvm-svn: 248925
* Fix to PR16225 (Assert-on-invalid: isa<LabelDecl>(D) && "declaration not ↵Serge Pavlov2013-08-101-0/+13
| | | | | | | | instantiated in this scope") Differential Revision: http://llvm-reviews.chandlerc.com/D920 llvm-svn: 188137
* Add testcase for PR16134, which no longer crashes with ToT.Richard Smith2013-07-221-0/+6
| | | | llvm-svn: 186849
* Show fixit for unqualified calls to methods of dependent basesNico Weber2012-06-221-2/+1
| | | | | | | | when the calling site is a member function template. Effectively reverts r111675. llvm-svn: 159004
* Add a workaround for PR7947, a crash trying to recover from invalid C++ code.Nick Lewycky2010-08-201-0/+19
llvm-svn: 111675
OpenPOWER on IntegriCloud