diff options
author | Piotr Trojanek <trojanek@adacore.com> | 2024-07-05 17:16:36 +0200 |
---|---|---|
committer | Marc Poulhiès <dkm@gcc.gnu.org> | 2024-08-02 09:08:10 +0200 |
commit | 913fa16483256daacd576476312dfcc2d2421517 (patch) | |
tree | 0c4bf81983821029d99a41c06db5bc8276c4f8fd /gcc | |
parent | 72ae355328fe30d61227501be4314689295a03f1 (diff) | |
download | gcc-913fa16483256daacd576476312dfcc2d2421517.zip gcc-913fa16483256daacd576476312dfcc2d2421517.tar.gz gcc-913fa16483256daacd576476312dfcc2d2421517.tar.bz2 |
ada: Simplify manipulation of the list with loop actions
Code cleanup; behavior is unaffected.
gcc/ada/
* exp_aggr.adb (Add_Loop_Actions): Change manipulation of list
to avoid unnecessary calls to Parent and Loop_Actions.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/exp_aggr.adb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/ada/exp_aggr.adb b/gcc/ada/exp_aggr.adb index 7a2d057..8496fcd 100644 --- a/gcc/ada/exp_aggr.adb +++ b/gcc/ada/exp_aggr.adb @@ -1262,9 +1262,9 @@ package body Exp_Aggr is elsif Nkind (Parent (Expr)) = N_Component_Association and then Present (Loop_Actions (Parent (Expr))) then - Append_List (Lis, Loop_Actions (Parent (Expr))); Res := Loop_Actions (Parent (Expr)); Set_Loop_Actions (Parent (Expr), No_List); + Append_List (Lis, To => Res); return Res; else |