aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Sema/const-eval.c
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/Sema/const-eval.c')
-rw-r--r--clang/test/Sema/const-eval.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/clang/test/Sema/const-eval.c b/clang/test/Sema/const-eval.c
index 87c2112..11cc7fb 100644
--- a/clang/test/Sema/const-eval.c
+++ b/clang/test/Sema/const-eval.c
@@ -41,9 +41,6 @@ struct s {
};
EVAL_EXPR(19, ((int)&*(char*)10 == 10 ? 1 : -1));
-// expected-error@-1 {{not an integer constant expression}} \
-// expected-note@-1 {{dereferencing a null pointer is not allowed in a constant expression}}
-
EVAL_EXPR(20, __builtin_constant_p(*((int*) 10)));
@@ -153,3 +150,7 @@ struct PR35214_X {
int PR35214_x;
int PR35214_y = ((struct PR35214_X *)&PR35214_x)->arr[1]; // expected-error {{not a compile-time constant}}
int *PR35214_z = &((struct PR35214_X *)&PR35214_x)->arr[1]; // ok, &PR35214_x + 2
+
+
+int * GH149500_p = &(*(int *)0x400);
+static const void *GH149500_q = &(*(const struct sysrq_key_op *)0);