summaryrefslogtreecommitdiff
path: root/weak/a.c
diff options
context:
space:
mode:
Diffstat (limited to 'weak/a.c')
-rw-r--r--weak/a.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/weak/a.c b/weak/a.c
new file mode 100644
index 0000000..49f7d57
--- /dev/null
+++ b/weak/a.c
@@ -0,0 +1,11 @@
+int __sym(int x)
+{
+ return x+1;
+}
+
+extern int sym(int x) __attribute__((weak,alias("__sym")));
+
+int same(int x)
+{
+ return sym(x)*3;
+}