view gcc/testsuite/gcc.dg/struct-in-proto-1.c @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
line wrap: on
line source

/* { dg-do compile } */
/* { dg-options "-w" } */
int foo(struct S { int i; } s) {
  return sizeof(struct S); /* { dg-bogus "incomplete type" "S visible here" } */
}
int bar(void) {
  return sizeof(struct S); /* { dg-error "incomplete type" "not here" } */
}