summaryrefslogtreecommitdiffstats
path: root/test/SemaCXX/null_in_arithmetic_ops.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCXX/null_in_arithmetic_ops.cpp')
-rw-r--r--test/SemaCXX/null_in_arithmetic_ops.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/SemaCXX/null_in_arithmetic_ops.cpp b/test/SemaCXX/null_in_arithmetic_ops.cpp
index a6c0dbf..a919213 100644
--- a/test/SemaCXX/null_in_arithmetic_ops.cpp
+++ b/test/SemaCXX/null_in_arithmetic_ops.cpp
@@ -90,4 +90,6 @@ void f() {
b = e == NULL || NULL == e || e != NULL || NULL != e;
b = f == NULL || NULL == f || f != NULL || NULL != f;
b = "f" == NULL || NULL == "f" || "f" != NULL || NULL != "f";
+
+ return NULL; // expected-error{{void function 'f' should not return a value}}
}
OpenPOWER on IntegriCloud