aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2001-09-26 13:02:51 -0700
committerRichard Henderson <rth@gcc.gnu.org>2001-09-26 13:02:51 -0700
commit9c2f7166cbaad7eed6b8155daf6b4e1df1fea3a5 (patch)
tree4535a58290d213bdfdf02efffb4d843c4d6f017c
parentaaa5f039eb95c50ee9dfb8b810f5b1d607cabeee (diff)
downloadgcc-9c2f7166cbaad7eed6b8155daf6b4e1df1fea3a5.zip
gcc-9c2f7166cbaad7eed6b8155daf6b4e1df1fea3a5.tar.gz
gcc-9c2f7166cbaad7eed6b8155daf6b4e1df1fea3a5.tar.bz2
optabs.c (init_one_libfunc): Create a dummy function type instead of using error_mark_node.
* optabs.c (init_one_libfunc): Create a dummy function type instead of using error_mark_node. From-SVN: r45830
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/optabs.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 891bfef..a63b303 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2001-09-26 Richard Henderson <rth@redhat.com>
+
+ * optabs.c (init_one_libfunc): Create a dummy function type
+ instead of using error_mark_node.
+
2001-09-26 Neil Booth <neil@daikokuya.demon.co.uk>
* cpphash.h (struct _cpp_buff, _cpp_get_buff, _cpp_release_buff,
diff --git a/gcc/optabs.c b/gcc/optabs.c
index 6421adf..035beac 100644
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -4689,9 +4689,9 @@ init_one_libfunc (name)
{
/* Create a FUNCTION_DECL that can be passed to ENCODE_SECTION_INFO. */
/* ??? We don't have any type information except for this is
- a function. See if error_mark_node is good enough. */
+ a function. Pretend this is "int foo()". */
tree decl = build_decl (FUNCTION_DECL, get_identifier (name),
- error_mark_node);
+ build_function_type (integer_type_node, NULL_TREE));
DECL_ARTIFICIAL (decl) = 1;
DECL_EXTERNAL (decl) = 1;
TREE_PUBLIC (decl) = 1;