diff options
author | Piotr Trojanek <trojanek@adacore.com> | 2021-02-16 14:58:46 +0100 |
---|---|---|
committer | Pierre-Marie de Rodat <derodat@adacore.com> | 2021-06-15 06:19:38 -0400 |
commit | 2a344c79824904d3903805ff2c2113af64af8b16 (patch) | |
tree | 29d45762838eebf3be4d152c43de1b2a41d47828 /gcc/ada/exp_util.adb | |
parent | 6ae60a649ee76755632adef16decdf90fb8c1ec8 (diff) | |
download | gcc-2a344c79824904d3903805ff2c2113af64af8b16.tar.gz |
[Ada] Enable removal of side-effects in component declarations
gcc/ada/
* exp_util.adb (Possible_Side_Effect_In_SPARK): Handle component
declaration just like full type and subtype declarations.
Diffstat (limited to 'gcc/ada/exp_util.adb')
-rw-r--r-- | gcc/ada/exp_util.adb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ada/exp_util.adb b/gcc/ada/exp_util.adb index 1189870bd60..78797f64165 100644 --- a/gcc/ada/exp_util.adb +++ b/gcc/ada/exp_util.adb @@ -11485,7 +11485,8 @@ package body Exp_Util is return not Inside_A_Generic and then Full_Analysis and then Nkind (Enclosing_Declaration (Exp)) in - N_Full_Type_Declaration + N_Component_Declaration + | N_Full_Type_Declaration | N_Iterator_Specification | N_Loop_Parameter_Specification | N_Object_Renaming_Declaration |