funcdef-var-1.c

来自「用于进行gcc测试」· C语言 代码 · 共 11 行

C
11
字号
/* Test ICE on defining function with a name previously declared as a   nonfunction.  Bug 28299 from Bernhard Fischer   <aldot@gcc.gnu.org>.  *//* { dg-do compile } *//* { dg-options "-Wmissing-prototypes" } */extern __typeof(foo) foo __asm__(""); /* { dg-error "undeclared" } *//* { dg-error "previous declaration" "previous declaration" { target *-*-* } 7 } */void *foo (void) {} /* { dg-error "redeclared as different kind of symbol" } *//* { dg-warning "no previous prototype" "no previous prototype" { target *-*-* } 9 } */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?