(grokparms): Copy arg type list to savable obstack if nec.
From-SVN: r2071
This commit is contained in:
parent
bc690db148
commit
023de2924d
13
gcc/c-decl.c
13
gcc/c-decl.c
@ -4438,6 +4438,19 @@ grokparms (parms_info, funcdef_flag)
|
||||
typelt = TREE_CHAIN (typelt);
|
||||
}
|
||||
|
||||
/* Allocate the list of types the way we allocate a type. */
|
||||
if (allocation_temporary_p ())
|
||||
{
|
||||
/* Construct a copy of the list of types
|
||||
on the saveable obstack. */
|
||||
tree result = NULL;
|
||||
for (typelt = first_parm; typelt; typelt = TREE_CHAIN (typelt))
|
||||
result = saveable_tree_cons (NULL_TREE, TREE_VALUE (typelt),
|
||||
result);
|
||||
return nreverse (result);
|
||||
}
|
||||
else
|
||||
/* The list we have is permanent already. */
|
||||
return first_parm;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user