aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base/callfuncs.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/testsuite/gdb.base/callfuncs.c')
-rw-r--r--gdb/testsuite/gdb.base/callfuncs.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.base/callfuncs.c b/gdb/testsuite/gdb.base/callfuncs.c
index 2d40650..406d22a 100644
--- a/gdb/testsuite/gdb.base/callfuncs.c
+++ b/gdb/testsuite/gdb.base/callfuncs.c
@@ -510,3 +510,15 @@ int main ()
t_structs_c(struct_val1);
return 0 ;
}
+
+static int
+Lcallfunc (int arg)
+{
+ return arg + 1;
+}
+
+int
+callfunc (int (*func) (int value), int value)
+{
+ return Lcallfunc (0) * 0 + func (value) * 2;
+}