aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-phiopt.cc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2023-09-18 09:14:46 +0200
committerMarc Poulhiès <poulhies@adacore.com>2023-09-26 13:43:18 +0200
commit6e8a0350a15c107d0079a0d953cea9f11d776aed (patch)
tree28ddb1c51cf180cd91fb186541a8ce66f7710d40 /gcc/tree-ssa-phiopt.cc
parentf6367fc211e52b3f7f8d0f2c481e20cb69839071 (diff)
downloadgcc-6e8a0350a15c107d0079a0d953cea9f11d776aed.zip
gcc-6e8a0350a15c107d0079a0d953cea9f11d776aed.tar.gz
gcc-6e8a0350a15c107d0079a0d953cea9f11d776aed.tar.bz2
ada: Fix missing call to Finalize_Protection for simple protected objects
There is a glitch in Exp_Ch7.Build_Finalizer causing the finalizer to do nothing for simple protected objects. The change also removes redundant calls to the Is_Simple_Protected_Type predicate and fixes a minor inconsistency between Requires_Cleanup_Actions and Build_Finalizer for this case. gcc/ada/ * exp_ch7.adb (Build_Finalizer.Process_Declarations): Remove call to Is_Simple_Protected_Type as redundant. (Build_Finalizer.Process_Object_Declaration): Do not retrieve the corresponding record type for simple protected objects. Make the flow of control more explicit in their specific processing. * exp_util.adb (Requires_Cleanup_Actions): Return false for simple protected objects present in library-level package bodies for the sake of consistency with Build_Finalizer and remove call to Is_Simple_Protected_Type as redundant.
Diffstat (limited to 'gcc/tree-ssa-phiopt.cc')
0 files changed, 0 insertions, 0 deletions