llvm-project/clang/unittests
Nico Weber b2673a1e48 [clang-format] Fix PR30527: Regression when clang-format insert spaces in [] when in template
Actual regression was introduced in r272668. This revision fixes JS script, but
also regress Cpp case. It manifests with spaces added when template is followed
with array. Bug 30527 mentions case of array as a nested template type
(foo<bar<baz>[]>). Fix is to detect such case and to prevent treating it as
array initialization, but as a subscript case. However, before r272668, this
case was treated simple because we were detecting it as a StartsObjCMethodExpr.
Same was true for other similar case - array of templates (foo<int>[]). This
patch tries to address two problems: 1) fixing regression 2) making sure both
cases (array as a nested type, array of templates) which were entering
StartsObjCMethodExpr branch are handled now appropriately.

https://reviews.llvm.org/D26163
Patch from Branko Kokanovic <branko@kokanovic.org>!

llvm-svn: 286507
2016-11-10 21:49:25 +00:00
..
AST Make output of -ast-print a valid C++ code. 2016-11-10 08:49:37 +00:00
ASTMatchers [ASTMatcher] Add CXXNewExpr support to hasDeclaration 2016-10-31 22:04:07 +00:00
Analysis CFGTests: Update libdeps. 2016-07-08 17:06:27 +00:00
Basic [VFS] Replace TimeValue usage with std::chrono 2016-11-09 10:52:22 +00:00
CodeGen Make sure the LLVMContext outlive the CompilerInstance 2016-04-14 05:37:41 +00:00
Driver [Driver] Set the default driver mode based on the executable. 2016-08-12 17:47:52 +00:00
Format [clang-format] Fix PR30527: Regression when clang-format insert spaces in [] when in template 2016-11-10 21:49:25 +00:00
Frontend [NFC] Header cleanup 2016-07-18 19:02:11 +00:00
Lex [Lexer] Don't merge macro args from different macro files 2016-05-19 23:44:02 +00:00
Rewrite Remove autoconf support 2016-01-26 21:30:40 +00:00
Sema [Sema] Allow an external sema source to handle delayed typo corrections. 2016-05-19 10:46:10 +00:00
StaticAnalyzer Add a method to get the list of registered static analyzer checkers. 2016-11-08 07:23:32 +00:00
Tooling Fix memory leak caused by r286096. 2016-11-07 18:40:41 +00:00
libclang Fixed more signed/unsigned mismatch warnings introduced in my change at r279076 2016-08-18 20:56:48 +00:00
CMakeLists.txt CFGBuilder: Fix crash when visiting a range-based for over a dependent type 2016-07-08 10:50:51 +00:00