aboutsummaryrefslogtreecommitdiff
path: root/test/CXX/expr/expr.cond/p4.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/CXX/expr/expr.cond/p4.cpp')
-rw-r--r--test/CXX/expr/expr.cond/p4.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/CXX/expr/expr.cond/p4.cpp b/test/CXX/expr/expr.cond/p4.cpp
new file mode 100644
index 000000000000..4d0cf3538cf0
--- /dev/null
+++ b/test/CXX/expr/expr.cond/p4.cpp
@@ -0,0 +1,10 @@
+// RUN: %clang_cc1 -std=c++98 -verify %s
+// RUN: %clang_cc1 -std=c++1z -verify %s
+
+// expected-no-diagnostics
+
+struct A { A(); A(int); };
+void f() {
+ const A a;
+ true ? a : 0;
+}