[cfe-commits] r127602 - /cfe/trunk/test/CXX/except/except.spec/p11.cpp
Sebastian Redl
sebastian.redl at getdesigned.at
Mon Mar 14 11:51:44 PDT 2011
Author: cornedbee
Date: Mon Mar 14 13:51:44 2011
New Revision: 127602
URL: http://llvm.org/viewvc/llvm-project?rev=127602&view=rev
Log:
Add another, pretty trivial, exception spec test case.
Added:
cfe/trunk/test/CXX/except/except.spec/p11.cpp
Added: cfe/trunk/test/CXX/except/except.spec/p11.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CXX/except/except.spec/p11.cpp?rev=127602&view=auto
==============================================================================
--- cfe/trunk/test/CXX/except/except.spec/p11.cpp (added)
+++ cfe/trunk/test/CXX/except/except.spec/p11.cpp Mon Mar 14 13:51:44 2011
@@ -0,0 +1,12 @@
+// RUN: %clang_cc1 -std=c++0x -fexceptions -fcxx-exceptions -fsyntax-only -verify %s
+
+// This is the "let the user shoot himself in the foot" clause.
+void f() noexcept {
+ throw 0; // no-error
+}
+void g() throw() {
+ throw 0; // no-error
+}
+void h() throw(int) {
+ throw 0.0; // no-error
+}
More information about the cfe-commits
mailing list