summaryrefslogtreecommitdiffstats
path: root/test/SemaCXX/for-range-no-std.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCXX/for-range-no-std.cpp')
-rw-r--r--test/SemaCXX/for-range-no-std.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/SemaCXX/for-range-no-std.cpp b/test/SemaCXX/for-range-no-std.cpp
index dae41f1..fa42ca4 100644
--- a/test/SemaCXX/for-range-no-std.cpp
+++ b/test/SemaCXX/for-range-no-std.cpp
@@ -1,5 +1,5 @@
// RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++11
-// RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++98 -Wno-c++0x-extensions
+// RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++98 -Wno-c++11-extensions
struct S {
int *begin();
@@ -36,3 +36,8 @@ void f() {
for (int b : NS::ADL()) {} // ok
for (int b : NS::NoADL()) {} // expected-error {{no matching function for call to 'begin'}} expected-note {{range has type}}
}
+
+void PR11601() {
+ void (*vv[])() = {PR11601, PR11601, PR11601};
+ for (void (*i)() : vv) i();
+}
OpenPOWER on IntegriCloud