From 53ec04cbdd192468d1975640759084f4e37fe4e8 Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Thu, 30 Jan 2020 04:05:44 -0500 Subject: [PATCH] [Ada] AI12-0184: Long Long C Data types 2020-06-04 Arnaud Charlet gcc/ada/ * libgnat/i-c.ads (long_long, unsigned_long_long): New definitions. --- gcc/ada/libgnat/i-c.ads | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gcc/ada/libgnat/i-c.ads b/gcc/ada/libgnat/i-c.ads index 1088836e25e..279c75a2721 100644 --- a/gcc/ada/libgnat/i-c.ads +++ b/gcc/ada/libgnat/i-c.ads @@ -36,13 +36,15 @@ package Interfaces.C is type short is new Short_Integer; type long is range -(2 ** (System.Parameters.long_bits - Integer'(1))) .. +(2 ** (System.Parameters.long_bits - Integer'(1))) - 1; + type long_long is new Long_Long_Integer; type signed_char is range SCHAR_MIN .. SCHAR_MAX; for signed_char'Size use CHAR_BIT; - type unsigned is mod 2 ** int'Size; - type unsigned_short is mod 2 ** short'Size; - type unsigned_long is mod 2 ** long'Size; + type unsigned is mod 2 ** int'Size; + type unsigned_short is mod 2 ** short'Size; + type unsigned_long is mod 2 ** long'Size; + type unsigned_long_long is mod 2 ** long_long'Size; type unsigned_char is mod (UCHAR_MAX + 1); for unsigned_char'Size use CHAR_BIT; -- 2.30.2