OSDN Git Service

2006-02-13 Thomas Quinot <quinot@adacore.com>
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 15 Feb 2006 09:38:10 +0000 (09:38 +0000)
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 15 Feb 2006 09:38:10 +0000 (09:38 +0000)
commitea150575d7b91fde3e0f0dfa8db003c08b68dd81
tree206359c222e19b3caaae36b5e2fbd40231df7656
parentc6eb017a825a226c0506e038e5a0722e833892e5
2006-02-13  Thomas Quinot  <quinot@adacore.com>
    Ed Schonberg  <schonberg@adacore.com>

* exp_ch4.adb (Expand_Allocator_Expression): Pass Allocator => True to
Make_Adjust_Call done for a newly-allocated object.

* exp_ch7.ads, exp_ch7.adb (Expand_Cleanup_Actions): If the statements
in a subprogram are wrapped in a cleanup block, indicate that the
subprogram contains an inner block with an exception handler.
(Make_Adjust_Call): New Boolean formal Allocator indicating whether the
Adjust call is for a newly-allocated object. In that case we must not
assume that the finalization list chain pointers are correct (since they
come from a bit-for-bit copy of the original object's pointers) so if
the attach level would otherwise be zero (no change), we set it to 4
instead to cause the pointers to be reset to null.

* s-finimp.adb (Attach_To_Final_List): New attach level: 4, meaning
reset chain pointers to null.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@111060 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ada/exp_ch4.adb
gcc/ada/exp_ch7.adb
gcc/ada/exp_ch7.ads
gcc/ada/s-finimp.adb