summaryrefslogtreecommitdiffstats
path: root/test/SemaCXX/typo-correction-delayed.cpp
diff options
context:
space:
mode:
authorKaelyn Takata <rikka@google.com>2014-12-16 23:07:00 +0000
committerKaelyn Takata <rikka@google.com>2014-12-16 23:07:00 +0000
commit5f7701a4def14b22cfd797fda53187c88c36489e (patch)
tree9d735061a280a01f3a0960ef3cab57e4bf97faec /test/SemaCXX/typo-correction-delayed.cpp
parentb2c6c4fef704d04a87c5b84ece95fb22f75db899 (diff)
Try typo correction on all initialization arguments and be less
pessimistic about when to do so. This also fixes PR21905 as the initialization argument was no longer viewed as being type dependent due to the TypoExpr being type-cast. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224386 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/typo-correction-delayed.cpp')
-rw-r--r--test/SemaCXX/typo-correction-delayed.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/SemaCXX/typo-correction-delayed.cpp b/test/SemaCXX/typo-correction-delayed.cpp
index c91fb6ca65..a9bc91e030 100644
--- a/test/SemaCXX/typo-correction-delayed.cpp
+++ b/test/SemaCXX/typo-correction-delayed.cpp
@@ -143,3 +143,7 @@ void test() {
int x = variableX.getX();
}
}
+
+namespace PR21905 {
+int (*a) () = (void)Z; // expected-error-re {{use of undeclared identifier 'Z'{{$}}}}
+}