PR tree-optimization/84740
[official-gcc.git] / gcc / testsuite / gcc.dg / inline-35.c
blobebbb8df2fe1a1d90ce9f9f995d9fcd2181d586fc
1 /* A function definition of an inline function following a static
2 declaration does not make an inline definition in C99/C11 terms.
3 PR 57574. */
4 /* { dg-do compile } */
5 /* { dg-options "-std=c99 -pedantic-errors" } */
7 static int n;
9 static inline int f1 (void);
10 inline int f1 (void) { return n; }
12 static int f2 (void);
13 inline int f2 (void) { return n; }
15 static inline int f3 (void);
16 int f3 (void) { return n; }
18 static int f4 (void);
19 int f4 (void) { return n; }