aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRobert Dewar <dewar@adacore.com>2014-02-04 14:52:05 +0000
committerArnaud Charlet <charlet@gcc.gnu.org>2014-02-04 15:52:05 +0100
commit3e247e586cb2b7cdc3519b3dddd1c50749a810ce (patch)
tree39da47473582973f22382a940c8bcfd5c399e97d /gcc
parent2db5b47e6d87fd9f76c11cb578a8b0e7fdeca87e (diff)
downloadgcc-3e247e586cb2b7cdc3519b3dddd1c50749a810ce.zip
gcc-3e247e586cb2b7cdc3519b3dddd1c50749a810ce.tar.gz
gcc-3e247e586cb2b7cdc3519b3dddd1c50749a810ce.tar.bz2
exp_ch5.adb, [...]: Minor reformatting.
2014-02-04 Robert Dewar <dewar@adacore.com> * exp_ch5.adb, einfo.ads, freeze.adb, sem_ch8.adb: Minor reformatting. From-SVN: r207470
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ada/ChangeLog4
-rw-r--r--gcc/ada/einfo.ads2
-rw-r--r--gcc/ada/exp_ch5.adb2
-rw-r--r--gcc/ada/freeze.adb5
-rw-r--r--gcc/ada/sem_ch8.adb3
5 files changed, 13 insertions, 3 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 8f43cfe..8417198 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,7 @@
+2014-02-04 Robert Dewar <dewar@adacore.com>
+
+ * exp_ch5.adb, einfo.ads, freeze.adb, sem_ch8.adb: Minor reformatting.
+
2014-02-04 Gary Dismukes <dismukes@adacore.com>
* sem_aggr.adb: Change "runtime" to "run time" in warning message,
diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads
index fae25de..18a1e18 100644
--- a/gcc/ada/einfo.ads
+++ b/gcc/ada/einfo.ads
@@ -2775,7 +2775,7 @@ package Einfo is
-- Is_Pure (Flag44)
-- Defined in all entities. Set in all entities of a unit to which a
--- pragma Pure is applied except for non intrinsic imported subprogram,
+-- pragma Pure is applied except for non-intrinsic imported subprograms,
-- and also set for the entity of the unit itself. In addition, this
-- flag may be set for any other functions or procedures that are known
-- to be side effect free, so in the case of subprograms, the Is_Pure
diff --git a/gcc/ada/exp_ch5.adb b/gcc/ada/exp_ch5.adb
index d64d0c8..a65365b 100644
--- a/gcc/ada/exp_ch5.adb
+++ b/gcc/ada/exp_ch5.adb
@@ -3132,7 +3132,7 @@ package body Exp_Ch5 is
-- the element is a constant in the loop.
if No (Find_Value_Of_Aspect
- (Container_Typ, Aspect_Variable_Indexing))
+ (Container_Typ, Aspect_Variable_Indexing))
then
Set_Ekind (Id, E_Constant);
end if;
diff --git a/gcc/ada/freeze.adb b/gcc/ada/freeze.adb
index ad74fba..93e7248 100644
--- a/gcc/ada/freeze.adb
+++ b/gcc/ada/freeze.adb
@@ -6521,6 +6521,11 @@ package body Freeze is
-- can bypass the normal check to ensure that pure units call only pure
-- subprograms.
+ -- The reason for the intrinsic exception is that in general, intrinsic
+ -- functions (such as shifts) are pure anyway. The only exceptions are
+ -- the intrinsics in GNAT.Source_Info, and that unit is not marked Pure
+ -- in any case, so no problem arises.
+
if Is_Imported (E)
and then Is_Pure (E)
and then not Has_Pragma_Pure_Function (E)
diff --git a/gcc/ada/sem_ch8.adb b/gcc/ada/sem_ch8.adb
index da5c600..bb98947 100644
--- a/gcc/ada/sem_ch8.adb
+++ b/gcc/ada/sem_ch8.adb
@@ -1195,7 +1195,8 @@ package body Sem_Ch8 is
-- Set the Ekind of the entity, unless it has been set already, as is
-- the case for the iteration object over a container with no variable
- -- indexing.
+ -- indexing. In that case it's been marked as a constant, and we do not
+ -- want to change it to a variable.
if Ekind (Id) /= E_Constant then
Set_Ekind (Id, E_Variable);