PR middle-end/85602 - -Wsizeof-pointer-memaccess for strncat with size of source
[official-gcc.git] / gcc / testsuite / gcc.dg / Wshadow-local-1.c
blob161f9941fb69300f09d6ee3a3a50bccceb8291e6
1 /* { dg-do compile } */
2 /* { dg-options "-Wshadow=local" } */
4 int decl1; /* should not warn */
5 void foo (double decl1) /* should not warn */
6 {
9 void foo2 (int d) /* { dg-message "shadowed declaration" } */
12 double d; /* { dg-warning "shadows a parameter" } */
16 void foo3 ()
18 int local; /* { dg-message "shadowed declaration" } */
20 int local; /* { dg-warning "shadows a previous local" } */