OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [inline-19.c] - Blame information for rev 689

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* Test -fgnu89-extern-inline.  */
2
/* { dg-do compile } */
3
/* { dg-options "-fgnu89-inline" } */
4
/* { dg-final { scan-assembler "func1" } } */
5
/* { dg-final { scan-assembler-not "func2" } } */
6
/* { dg-final { scan-assembler "func3" } } */
7
/* { dg-final { scan-assembler "func4" } } */
8
 
9
#ifndef __GNUC_GNU_INLINE__
10
#error __GNUC_GNU_INLINE__ is not defined
11
#endif
12
 
13
#ifdef __GNUC_STDC_INLINE__
14
#error __GNUC_STDC_INLINE__ is defined
15
#endif
16
 
17
extern inline int func1 (void) { return 0; }
18
inline int func1 (void) { return 1; }
19
 
20
extern int func2 (void);
21
extern inline int func2 (void) { return 2; }
22
 
23
inline int func3 (void);
24
inline int func3 (void) { return 3; }
25
 
26
extern int func4 (void);
27
extern inline int func4 (void) { return 4; }
28
int func4 (void) { return 5; }

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.