]> git.ipfire.org Git - thirdparty/gcc.git/commit
ada: Couple of cleanups in finalization machinery
authorEric Botcazou <ebotcazou@adacore.com>
Mon, 24 Jun 2024 12:46:21 +0000 (14:46 +0200)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Thu, 1 Aug 2024 15:14:34 +0000 (17:14 +0200)
commitf61d9979a75b171a917ffcd03da5e4e5f62bcc50
tree7bffb0921f938a5fc984bf18834317c1070bfafe
parent76d37f8612faa0bf89983869a90e773794eaa227
ada: Couple of cleanups in finalization machinery

This removes a parameter and a variable that are entirely determined by
another parameter and another variable respectively.

gcc/ada/

* exp_ch7.ads (Build_Finalizer): Remove Top_Decls parameter.
* exp_ch7.adb (Build_Finalizer): Likewise. Rename Counter_Val into
Count, replace Has_Ctrl_Objs local variable by expression
function, remove Spec_Decls local variable and do not reset
Finalizer_Decls.
(Expand_Cleanup_Actions): Adjust call to Build_Finalizer.
(Expand_N_Package_Body): Likewise.
(Expand_N_Package_Declaration): Likewise.
* inline.adb (Cleanup_Scopes): Likewise.
gcc/ada/exp_ch7.adb
gcc/ada/exp_ch7.ads
gcc/ada/inline.adb