llvm-project/clang/lib
Richard Smith 42bc73a3f1 When we see a '<' operator, check whether it's a probable typo for a template-id.
The heuristic that we use here is:
 * the left-hand side must be a simple identifier or a class member access
 * the right-hand side must be '<' followed by either a '>' or by a type-id that
   cannot be an expression (in particular, not followed by '(' or '{')
 * there is a '>' token matching the '<' token

The second condition guarantees the expression would otherwise be ill-formed.

If we're confident that the user intended the name before the '<' to be
interpreted as a template, diagnose the fact that we didn't interpret it
that way, rather than diagnosing that the template arguments are not valid
expressions.

llvm-svn: 302615
2017-05-10 02:30:28 +00:00
..
ARCMigrate [ARCMigrate] When applying changes from remap files, disable the 'adjustRemovals' functionality of EditedSource 2017-04-28 00:25:06 +00:00
AST [Sema] Implement Core 2094: Trivial copy/move constructor for class with volatile member 2017-05-09 22:21:24 +00:00
ASTMatchers Add cxxStdInitializerListExpr AST matcher 2017-05-05 21:01:12 +00:00
Analysis Fix PR13910: Don't warn that __builtin_unreachable() is unreachable 2017-04-11 15:36:06 +00:00
Basic [X86][LWP] Add clang support for LWP instructions. 2017-05-08 12:09:45 +00:00
CodeGen [ubsan] Mark overflow checks with !nosanitize 2017-05-09 23:34:49 +00:00
Driver [asan] A clang flag to enable ELF globals-gc. 2017-05-09 21:57:43 +00:00
Edit [ARCMigrate] When applying changes from remap files, disable the 'adjustRemovals' functionality of EditedSource 2017-04-28 00:25:06 +00:00
Format clang-format: [JS] Don't indent JavaScript IIFEs. 2017-05-09 20:04:09 +00:00
Frontend [asan] A clang flag to enable ELF globals-gc. 2017-05-09 21:57:43 +00:00
FrontendTool unique_ptrify createDriverOptTable 2017-01-13 17:34:15 +00:00
Headers [X86][LWP] Remove MSVC LWP intrinsics stubs. 2017-05-09 17:50:16 +00:00
Index [Index] The relation between the declarations in template 2017-05-04 10:42:06 +00:00
Lex [Modules] Allow umbrella frameworks to define private submodules for subframeworks 2017-05-09 00:41:38 +00:00
Parse When we see a '<' operator, check whether it's a probable typo for a template-id. 2017-05-10 02:30:28 +00:00
Rewrite [analyzer] Re-apply r283092, attempt no.4, chunk no.4 (last) 2016-10-07 19:25:10 +00:00
Sema When we see a '<' operator, check whether it's a probable typo for a template-id. 2017-05-10 02:30:28 +00:00
Serialization Silences gcc's -Wnarrowing. 2017-05-03 07:48:27 +00:00
StaticAnalyzer Suppress all uses of LLVM_END_WITH_NULL. NFC. 2017-05-09 19:31:30 +00:00
Tooling [Tooling] Remove redundant check, NFCi 2017-05-05 14:07:23 +00:00
CMakeLists.txt