aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/expander.adb
diff options
context:
space:
mode:
authorYannick Moy <moy@adacore.com>2019-07-08 08:13:52 +0000
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>2019-07-08 08:13:52 +0000
commit7800a8fb04adc60273185de201e9dff51b356952 (patch)
tree7a508b075f8729b84696d8be705686ce98e56116 /gcc/ada/expander.adb
parent1bb2e1d96eb23d2289765cd0fd9ef10b7a3b7ea3 (diff)
downloadgcc-7800a8fb04adc60273185de201e9dff51b356952.zip
gcc-7800a8fb04adc60273185de201e9dff51b356952.tar.gz
gcc-7800a8fb04adc60273185de201e9dff51b356952.tar.bz2
[Ada] Do not erase precise type on fixed-point real literal
Real literals of fixed-point type are expected to keep their precise fixed-point type in GNATprove. This is now correctly enforced. There is no impact on compilation. 2019-07-08 Yannick Moy <moy@adacore.com> gcc/ada/ * expander.adb (Expand): Do not reset Analyzed flag always. * sem_eval.adb (Fold_Ureal): Mark node as analyzed. From-SVN: r273211
Diffstat (limited to 'gcc/ada/expander.adb')
-rw-r--r--gcc/ada/expander.adb7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ada/expander.adb b/gcc/ada/expander.adb
index 11711b9..aac2e7d 100644
--- a/gcc/ada/expander.adb
+++ b/gcc/ada/expander.adb
@@ -112,7 +112,12 @@ package body Expander is
Expand_SPARK (N);
end if;
- Set_Analyzed (N, Full_Analysis);
+ -- Do not reset the Analyzed flag if it has been set on purpose
+ -- during preanalysis.
+
+ if Full_Analysis then
+ Set_Analyzed (N);
+ end if;
-- Regular expansion is normally followed by special handling for
-- transient scopes for unconstrained results, etc. but this is not