aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDoug Rupp <rupp@adacore.com>2006-02-15 10:43:32 +0100
committerArnaud Charlet <charlet@gcc.gnu.org>2006-02-15 10:43:32 +0100
commit851cfa6f0085f05b4833ada5ffb74b05d57a1ff0 (patch)
treeb486981914086663ea983b83e69a47991aed6a1a /gcc
parent3bcd6930a9492b00032d996ab3c700272d878f1e (diff)
downloadgcc-851cfa6f0085f05b4833ada5ffb74b05d57a1ff0.zip
gcc-851cfa6f0085f05b4833ada5ffb74b05d57a1ff0.tar.gz
gcc-851cfa6f0085f05b4833ada5ffb74b05d57a1ff0.tar.bz2
s-auxdec-vms_64.ads (Short_Address): Wrap it in a type.
2006-02-13 Douglas Rupp <rupp@adacore.com> * s-auxdec-vms_64.ads (Short_Address): Wrap it in a type. From-SVN: r111087
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ada/s-auxdec-vms_64.ads10
1 files changed, 8 insertions, 2 deletions
diff --git a/gcc/ada/s-auxdec-vms_64.ads b/gcc/ada/s-auxdec-vms_64.ads
index 3bf7a5b..87b7819 100644
--- a/gcc/ada/s-auxdec-vms_64.ads
+++ b/gcc/ada/s-auxdec-vms_64.ads
@@ -37,15 +37,21 @@
-- These definitions can be used directly by withing this package, or merged
-- with System using pragma Extend_System (Aux_DEC)
--- This is the IPF VMS 64 bit version.
+-- This is the VMS 64 bit version.
with Unchecked_Conversion;
package System.Aux_DEC is
pragma Preelaborate;
- subtype Short_Address is Address
+ type Short_Integer_Address is
range -2 ** (32 - 1) .. +2 ** (32 - 1) - 1;
+ -- Integer literals cannot appear naked in an address context, as a
+ -- result the bounds of Short_Address cannot be given simply as 2^32 etc.
+
+ subtype Short_Address is Address
+ range Address (Short_Integer_Address'First) ..
+ Address (Short_Integer_Address'Last);
for Short_Address'Object_Size use 32;
-- This subtype allows addresses to be converted from 64 bits to 32 bits
-- with an appropriate range check. Note that since this is a subtype of