summaryrefslogtreecommitdiff
path: root/test/FixIt
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2016-06-23 19:02:52 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2016-06-23 19:02:52 +0000
commita64a49776e41ee8edeb24caf928e489f7b1df0e5 (patch)
tree6b775601632fc52f916af0ee057604c7d1e0fede /test/FixIt
parentc4e95c76197d386452a9b4524a4a5429b32bce72 (diff)
Re-commit r273548, reverted in r273589, with a fix to not produce
-Wfor-loop-analysis warnings for a for-loop with a condition variable. In such a case, the loop condition variable is modified on each iteration of the loop by definition. Original commit message: Rearrange condition handling so that semantic checks on a condition variable are performed before the other substatements of the construct are parsed, rather than deferring them until the end. This allows better error recovery from semantic errors in the condition, improves diagnostic order, and is a prerequisite for C++17 constexpr if. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@273600 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/FixIt')
-rw-r--r--test/FixIt/fixit-vexing-parse.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/FixIt/fixit-vexing-parse.cpp b/test/FixIt/fixit-vexing-parse.cpp
index 0232f5dbb0..71d3eff532 100644
--- a/test/FixIt/fixit-vexing-parse.cpp
+++ b/test/FixIt/fixit-vexing-parse.cpp
@@ -60,7 +60,7 @@ namespace N {
VO m(int (*p)[4]);
// Don't emit warning and fixit because direct initializer is not permitted here.
- if (int n(int())){} // expected-error {{function type is not allowed here}} expected-error {{condition must have an initializer}}
+ if (int n(int())){} // expected-error {{function type is not allowed here}}
// CHECK: fix-it:"{{.*}}":{66:8-66:10}:" = {}"
U u(); // expected-warning {{function declaration}} expected-note {{replace parentheses with an initializer}}