This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

(C++) patch to build_exception_variant


The old code failed to force the types themselves into the permanent
obstack.

1999-03-06  Jason Merrill  <jason@yorick.cygnus.com>

	* tree.c (build_exception_variant): Use copy_to_permanent.

Index: tree.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/cp/tree.c,v
retrieving revision 1.97
diff -c -p -r1.97 tree.c
*** tree.c	1999/02/26 12:11:43	1.97
--- tree.c	1999/03/07 01:37:16
*************** build_exception_variant (type, raises)
*** 1517,1528 ****
    v = build_type_copy (type);
  
    if (raises && ! TREE_PERMANENT (raises))
!     {
!       push_obstacks_nochange ();
!       end_temporary_allocation ();
!       raises = copy_list (raises);
!       pop_obstacks ();
!     }
  
    TYPE_RAISES_EXCEPTIONS (v) = raises;
    return v;
--- 1517,1523 ----
    v = build_type_copy (type);
  
    if (raises && ! TREE_PERMANENT (raises))
!     raises = copy_to_permanent (raises);
  
    TYPE_RAISES_EXCEPTIONS (v) = raises;
    return v;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]