summaryrefslogtreecommitdiffstats
path: root/trunk/testsuite/ifunctest.c
diff options
context:
space:
mode:
Diffstat (limited to 'trunk/testsuite/ifunctest.c')
-rw-r--r--trunk/testsuite/ifunctest.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/trunk/testsuite/ifunctest.c b/trunk/testsuite/ifunctest.c
new file mode 100644
index 0000000..9ce7b1a
--- /dev/null
+++ b/trunk/testsuite/ifunctest.c
@@ -0,0 +1,16 @@
+#include "ifunc.h"
+
+static int foo1 (void) { return 1; }
+static int foo2 (void) { return 2; }
+
+IFUNC_LOCAL (foo, foo1, foo2);
+
+extern void abort (void);
+
+int
+main (void)
+{
+ if (foo () != PICKNO)
+ abort ();
+ return 0;
+}