This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[Patch] Avoid useless type copy
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Fri, 18 Sep 2009 23:17:20 +0200
- Subject: [Patch] Avoid useless type copy
Both calls (originally to copy_node) were introduced in 2000 but it looks like
they were already useless by that time.
Tested on i586-suse-linux, OK for mainline?
2009-09-18 Eric Botcazou <ebotcazou@adacore.com>
* stor-layout.c (set_sizetype): Avoid useless type copy.
--
Eric Botcazou
Index: stor-layout.c
===================================================================
--- stor-layout.c (revision 151832)
+++ stor-layout.c (working copy)
@@ -2310,9 +2310,9 @@ set_sizetype (tree type)
if (TYPE_UNSIGNED (type))
{
fixup_unsigned_type (bitsizetype);
- ssizetype = build_distinct_type_copy (make_signed_type (oprecision));
+ ssizetype = make_signed_type (oprecision);
TYPE_IS_SIZETYPE (ssizetype) = 1;
- sbitsizetype = build_distinct_type_copy (make_signed_type (precision));
+ sbitsizetype = make_signed_type (precision);
TYPE_IS_SIZETYPE (sbitsizetype) = 1;
}
else