summaryrefslogtreecommitdiffstats
path: root/test/Parser/cxx0x-in-cxx98.cpp
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2012-04-14 14:01:31 +0000
committerdim <dim@FreeBSD.org>2012-04-14 14:01:31 +0000
commit50b73317314e889cf39c7b1d6cbf419fa7502f22 (patch)
treebe1815eb79b42ff482a8562b13c2dcbf0c5dcbee /test/Parser/cxx0x-in-cxx98.cpp
parentdc04cb328508e61aad809d9b53b12f9799a00e7d (diff)
downloadFreeBSD-src-50b73317314e889cf39c7b1d6cbf419fa7502f22.zip
FreeBSD-src-50b73317314e889cf39c7b1d6cbf419fa7502f22.tar.gz
Vendor import of clang trunk r154661:
http://llvm.org/svn/llvm-project/cfe/trunk@r154661
Diffstat (limited to 'test/Parser/cxx0x-in-cxx98.cpp')
-rw-r--r--test/Parser/cxx0x-in-cxx98.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/Parser/cxx0x-in-cxx98.cpp b/test/Parser/cxx0x-in-cxx98.cpp
index 9e41a70..b4bda89 100644
--- a/test/Parser/cxx0x-in-cxx98.cpp
+++ b/test/Parser/cxx0x-in-cxx98.cpp
@@ -8,3 +8,16 @@ struct X {
};
}
+struct B {
+ virtual void f();
+ virtual void g();
+};
+struct D final : B { // expected-warning {{'final' keyword is a C++11 extension}}
+ virtual void f() override; // expected-warning {{'override' keyword is a C++11 extension}}
+ virtual void g() final; // expected-warning {{'final' keyword is a C++11 extension}}
+};
+
+void NewBracedInitList() {
+ // A warning on this would be sufficient once we can handle it correctly.
+ new int {}; // expected-error {{}}
+}
OpenPOWER on IntegriCloud