summaryrefslogtreecommitdiffstats
path: root/test/PCH/cxx_exprs.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/PCH/cxx_exprs.cpp')
-rw-r--r--test/PCH/cxx_exprs.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/test/PCH/cxx_exprs.cpp b/test/PCH/cxx_exprs.cpp
index 51269d5..0f0fe88 100644
--- a/test/PCH/cxx_exprs.cpp
+++ b/test/PCH/cxx_exprs.cpp
@@ -1,13 +1,14 @@
// Test this without pch.
-// RUN: %clang_cc1 -include %S/cxx_exprs.h -fsyntax-only -verify %s
+// RUN: %clang_cc1 -include %S/cxx_exprs.h -std=c++0x -fsyntax-only -verify %s
// Test with pch.
-// RUN: %clang_cc1 -x c++-header -emit-pch -o %t %S/cxx_exprs.h
-// RUN: %clang_cc1 -include-pch %t -fsyntax-only -verify %s
+// RUN: %clang_cc1 -x c++-header -std=c++0x -emit-pch -o %t %S/cxx_exprs.h
+// RUN: %clang_cc1 -std=c++0x -include-pch %t -fsyntax-only -verify %s
int integer;
double floating;
char character;
+bool boolean;
// CXXStaticCastExpr
static_cast_result void_ptr = &integer;
@@ -24,3 +25,11 @@ const_cast_result char_ptr = &character;
// CXXFunctionalCastExpr
functional_cast_result *double_ptr = &floating;
+
+// CXXBoolLiteralExpr
+bool_literal_result *bool_ptr = &boolean;
+static_assert(true_value, "true_value is true");
+static_assert(!false_value, "false_value is false");
+
+// CXXNullPtrLiteralExpr
+cxx_null_ptr_result null_ptr = nullptr;
OpenPOWER on IntegriCloud