summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp')
-rw-r--r--clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp b/clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp
index de0996ad0ae..3c1550d0f07 100644
--- a/clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp
+++ b/clang-tools-extra/test/cpp11-migrate/UseNullptr/macros.cpp
@@ -153,4 +153,12 @@ void test_macro_args() {
// CHECK: PTR_AND_PTR_USE(nullptr);
PTR_AND_PTR_USE(NULL);
// CHECK: PTR_AND_PTR_USE(nullptr);
+
+#define OPTIONAL_CODE(...) __VA_ARGS__
+#define NOT_NULL dummy(0)
+#define CALL(X) X
+ OPTIONAL_CODE(NOT_NULL);
+ // CHECK: OPTIONAL_CODE(NOT_NULL);
+ CALL(NOT_NULL);
+ // CHECK: CALL(NOT_NULL);
}
OpenPOWER on IntegriCloud