This is used by new selftests later on in the patch kit.
gcc/ChangeLog:
* function-tests.c (selftest::make_fndecl): Make non-static.
* selftest.h (selftest::make_fndecl): New decl.
---
gcc/function-tests.c | 4 ++--
gcc/selftest.h | 7 +++++++
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/gcc/function-tests.c b/gcc/function-tests.c
index 2440dd6..f3406c4 100644
--- a/gcc/function-tests.c
+++ b/gcc/function-tests.c
@@ -82,11 +82,11 @@ namespace selftest {
/* Helper function for selftests of function-creation. */
-static tree
+tree
make_fndecl (tree return_type,
const char *name,
vec <tree> ¶m_types,
- bool is_variadic = false)
+ bool is_variadic)
{
tree fn_type;
if (is_variadic)
diff --git a/gcc/selftest.h b/gcc/selftest.h
index 165dfff..c67b688 100644
--- a/gcc/selftest.h
+++ b/gcc/selftest.h
@@ -171,6 +171,13 @@ class line_table_test
~line_table_test ();
};
+/* Helper function for selftests that need a function decl. */
+
+extern tree make_fndecl (tree return_type,
+ const char *name,
+ vec <tree> ¶m_types,
+ bool is_variadic = false);
+
/* Run TESTCASE multiple times, once for each case in our test matrix. */
extern void
--
1.8.5.3