Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/gcc.dg/attr-ifunc-4.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* { dg-do run } */ | |
2 /* { dg-require-ifunc "" } */ | |
3 /* { dg-options "" } */ | |
4 | |
5 #include <stdio.h> | |
6 | |
7 static int implementation (void) | |
8 { | |
9 printf ("'ere I am JH\n"); | |
10 return 0; | |
11 } | |
12 | |
13 static __typeof__ (implementation)* resolver (void) | |
14 { | |
15 return implementation; | |
16 } | |
17 | |
18 static int magic (void) __attribute__ ((ifunc ("resolver"))); | |
19 | |
20 int main () | |
21 { | |
22 return magic () != 0; | |
23 } |