This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH]: Fix PARM_DECL size issue
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Nathan Sidwell <nathan at codesourcery dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 30 Jun 2005 14:39:28 -0400
- Subject: [PATCH]: Fix PARM_DECL size issue
This calls relayout_decl on the types in
require_parms_havecompleted_type, which gives PARM_DECL the correct
DECL_SIZE (ie not 0).
Bootstrapped and regtested on i686-pc-linux-gnu.
Okay for mainline?
--Dan
2005-06-30 Daniel Berlin <dberlin@dberlin.org>
* decl.c (require_complete_types_for_parms): Call relayout_decl
instead of layout_decl.
Index: decl.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/decl.c,v
retrieving revision 1.1409
diff -u -p -r1.1409 decl.c
--- decl.c 25 Jun 2005 00:58:10 -0000 1.1409
+++ decl.c 30 Jun 2005 18:16:14 -0000
@@ -8207,7 +8207,7 @@ require_complete_types_for_parms (tree p
TREE_TYPE (parms) = error_mark_node;
else if (complete_type_or_else (TREE_TYPE (parms), parms))
{
- layout_decl (parms, 0);
+ relayout_decl (parms);
DECL_ARG_TYPE (parms) = type_passed_as (TREE_TYPE (parms));
}
}