repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Fix type of malloc parameter in trans-expr.cc
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
Wnonnull-9.c
blob
1c57eefd2aefc01d2508e8332a6b71bbb6bf2540
1
/* { dg-do compile } */
2
/* { dg-options "-Wall" } */
3
4
5
void
6
foo
(
int
a
[
static
1
])
7
{
8
if
((
void
*)
0
==
a
)
/* { dg-warning "argument" "compared to NULL" } */
9
return
;
10
}
11
12
int
13
main
()
14
{
15
foo
((
void
*)
0
);
/* { dg-warning "argument 1 null where non-null expected" } */
16
}
17