expressions: make assign_expression() take an op argument
[smatch.git] / validation / constexpr-pointer-cast.c
blobd19c10828d4d7a089bafa0eb54c73054a7d49861
1 static int *a = (int*)0; // OK
2 static int b = 0;
3 static int *c = (int*)b; // KO
6 /*
7 * check-name: integer literal cast to pointer type constness verification.
8 * check-command: sparse -Wconstexpr-not-const $file
10 * check-error-start
11 constexpr-pointer-cast.c:3:18: warning: non-constant initializer for static object
12 * check-error-end