projects
/
platform
/
upstream
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6ae60a6
)
[Ada] Enable removal of side-effects in component declarations
author
Piotr Trojanek
<trojanek@adacore.com>
Tue, 16 Feb 2021 13:58:46 +0000
(14:58 +0100)
committer
Pierre-Marie de Rodat
<derodat@adacore.com>
Tue, 15 Jun 2021 10:19:38 +0000
(06:19 -0400)
gcc/ada/
* exp_util.adb (Possible_Side_Effect_In_SPARK): Handle component
declaration just like full type and subtype declarations.
gcc/ada/exp_util.adb
patch
|
blob
|
history
diff --git
a/gcc/ada/exp_util.adb
b/gcc/ada/exp_util.adb
index 1189870bd604756882aebd26ae962e3b2757261f..78797f64165ed06164e62949cc4e10c7704f95a7 100644
(file)
--- 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