diff options
author | Ed Schonberg <schonberg@adacore.com> | 2007-06-06 12:25:25 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2007-06-06 12:25:25 +0200 |
commit | a79ec8c58c6a8b452a3916fe8d74712c1b0ab708 (patch) | |
tree | 6543f310ee10860562ac2feddf3d18351989eb96 /gcc/ada/exp_intr.adb | |
parent | 26bff3d98f6cf1aad9668c401286ac31822ee986 (diff) | |
download | gcc-a79ec8c58c6a8b452a3916fe8d74712c1b0ab708.zip gcc-a79ec8c58c6a8b452a3916fe8d74712c1b0ab708.tar.gz gcc-a79ec8c58c6a8b452a3916fe8d74712c1b0ab708.tar.bz2 |
exp_ch5.adb (Expand_N_Assignment_Statement): For the assignment of a controlled type...
2007-04-20 Ed Schonberg <schonberg@adacore.com>
Gary Dismukes <dismukes@adacore.com>
Javier Miranda <miranda@adacore.com>
* exp_ch5.adb (Expand_N_Assignment_Statement): For the assignment of a
controlled type, use Make_Handler_For_Ctrl_Operation to construct the
required exception handler.
(Expand_Simple_Function_Return, Expand_N_Return_Statement): Handle
properly the case of a function whose return type is a limited
class-wide interface type. Modify the code of the accessibility
check to handle class-wide interface objects. In this case we need to
displace "this" to reference the primary dispatch table to get access
to the TSD of the object (to evaluate its accessibility level).
(Expand_N_Extended_Return_Statement): Test for a tagged result type
rather than a controlling result as one of the conditions for
generating tests of the implicit BIP_Alloc_Form formal. The
initialization assignment is also handled according to whether the
result is tagged instead of controlling.
In the case where the init assignment is inserted in the "then" part of
the allocation conditional, rewrite the target to be a dereference of
the implicit BIP_Object_Access formal.
If the returned value is unconstrained and created on the secondary
stack, mark the enclosing block and function so that the secondary
stack is not reclaimed on return.
Treat returns from functions with controlling results similarly to
returns from functions with unconstrained result subtypes.
If the object returned is unconstrained, and an allocator must be
created for it, analyze the allocator once the block for the extended
return is installed, to ensure that finalizable components
of the expression use the proper finalization list. Guard the call to
Move_Final_List with a check that there is something to finalize.
(Make_Tag_Ctrl_Assignment): Use "old" handling
of controlled type assignment for virtual machines, since new code uses
unsupported features (such as direct access to bytes in memory).
From-SVN: r125398
Diffstat (limited to 'gcc/ada/exp_intr.adb')
0 files changed, 0 insertions, 0 deletions