From dc699db9f5006433913b762ddf6c09d6c1c4e0bd Mon Sep 17 00:00:00 2001 From: David Brown Date: Thu, 15 Sep 2016 15:23:08 +0100 Subject: [PATCH] Support 64 bit integer literals on all builds, and fix 64 bit Console.hex display. --- bootstrap/unix-44/Configuration.c | 4 +- bootstrap/unix-44/Configuration.h | 2 +- bootstrap/unix-44/Console.c | 5 +- bootstrap/unix-44/Console.h | 2 +- bootstrap/unix-44/Files.c | 2 +- bootstrap/unix-44/Files.h | 2 +- bootstrap/unix-44/Heap.c | 2 +- bootstrap/unix-44/Heap.h | 2 +- bootstrap/unix-44/Modules.c | 2 +- bootstrap/unix-44/Modules.h | 2 +- bootstrap/unix-44/OPB.c | 2 +- bootstrap/unix-44/OPB.h | 2 +- bootstrap/unix-44/OPC.c | 2 +- bootstrap/unix-44/OPC.h | 2 +- bootstrap/unix-44/OPM.c | 2 +- bootstrap/unix-44/OPM.h | 2 +- bootstrap/unix-44/OPP.c | 2 +- bootstrap/unix-44/OPP.h | 2 +- bootstrap/unix-44/OPS.c | 19 +- bootstrap/unix-44/OPS.h | 4 +- bootstrap/unix-44/OPT.c | 2 +- bootstrap/unix-44/OPT.h | 2 +- bootstrap/unix-44/OPV.c | 2 +- bootstrap/unix-44/OPV.h | 2 +- bootstrap/unix-44/Platform.c | 2 +- bootstrap/unix-44/Platform.h | 2 +- bootstrap/unix-44/Reals.c | 2 +- bootstrap/unix-44/Reals.h | 2 +- bootstrap/unix-44/Strings.c | 2 +- bootstrap/unix-44/Strings.h | 2 +- bootstrap/unix-44/Texts.c | 2 +- bootstrap/unix-44/Texts.h | 2 +- bootstrap/unix-44/Vishap.c | 2 +- bootstrap/unix-44/errors.c | 2 +- bootstrap/unix-44/errors.h | 2 +- bootstrap/unix-44/extTools.c | 2 +- bootstrap/unix-44/extTools.h | 2 +- bootstrap/unix-44/vt100.c | 2 +- bootstrap/unix-44/vt100.h | 2 +- bootstrap/unix-48/Configuration.c | 4 +- bootstrap/unix-48/Configuration.h | 2 +- bootstrap/unix-48/Console.c | 5 +- bootstrap/unix-48/Console.h | 2 +- bootstrap/unix-48/Files.c | 2 +- bootstrap/unix-48/Files.h | 2 +- bootstrap/unix-48/Heap.c | 2 +- bootstrap/unix-48/Heap.h | 2 +- bootstrap/unix-48/Modules.c | 2 +- bootstrap/unix-48/Modules.h | 2 +- bootstrap/unix-48/OPB.c | 2 +- bootstrap/unix-48/OPB.h | 2 +- bootstrap/unix-48/OPC.c | 2 +- bootstrap/unix-48/OPC.h | 2 +- bootstrap/unix-48/OPM.c | 2 +- bootstrap/unix-48/OPM.h | 2 +- bootstrap/unix-48/OPP.c | 2 +- bootstrap/unix-48/OPP.h | 2 +- bootstrap/unix-48/OPS.c | 19 +- bootstrap/unix-48/OPS.h | 4 +- bootstrap/unix-48/OPT.c | 2 +- bootstrap/unix-48/OPT.h | 2 +- bootstrap/unix-48/OPV.c | 2 +- bootstrap/unix-48/OPV.h | 2 +- bootstrap/unix-48/Platform.c | 2 +- bootstrap/unix-48/Platform.h | 2 +- bootstrap/unix-48/Reals.c | 2 +- bootstrap/unix-48/Reals.h | 2 +- bootstrap/unix-48/Strings.c | 2 +- bootstrap/unix-48/Strings.h | 2 +- bootstrap/unix-48/Texts.c | 2 +- bootstrap/unix-48/Texts.h | 2 +- bootstrap/unix-48/Vishap.c | 2 +- bootstrap/unix-48/errors.c | 2 +- bootstrap/unix-48/errors.h | 2 +- bootstrap/unix-48/extTools.c | 2 +- bootstrap/unix-48/extTools.h | 2 +- bootstrap/unix-48/vt100.c | 2 +- bootstrap/unix-48/vt100.h | 2 +- bootstrap/unix-88/Configuration.c | 4 +- bootstrap/unix-88/Configuration.h | 2 +- bootstrap/unix-88/Console.c | 7 +- bootstrap/unix-88/Console.h | 2 +- bootstrap/unix-88/Files.c | 2 +- bootstrap/unix-88/Files.h | 2 +- bootstrap/unix-88/Heap.c | 2 +- bootstrap/unix-88/Heap.h | 2 +- bootstrap/unix-88/Modules.c | 2 +- bootstrap/unix-88/Modules.h | 2 +- bootstrap/unix-88/OPB.c | 2 +- bootstrap/unix-88/OPB.h | 2 +- bootstrap/unix-88/OPC.c | 2 +- bootstrap/unix-88/OPC.h | 2 +- bootstrap/unix-88/OPM.c | 2 +- bootstrap/unix-88/OPM.h | 2 +- bootstrap/unix-88/OPP.c | 2 +- bootstrap/unix-88/OPP.h | 2 +- bootstrap/unix-88/OPS.c | 9 +- bootstrap/unix-88/OPS.h | 2 +- bootstrap/unix-88/OPT.c | 2 +- bootstrap/unix-88/OPT.h | 2 +- bootstrap/unix-88/OPV.c | 2 +- bootstrap/unix-88/OPV.h | 2 +- bootstrap/unix-88/Platform.c | 2 +- bootstrap/unix-88/Platform.h | 2 +- bootstrap/unix-88/Reals.c | 2 +- bootstrap/unix-88/Reals.h | 2 +- bootstrap/unix-88/Strings.c | 2 +- bootstrap/unix-88/Strings.h | 2 +- bootstrap/unix-88/Texts.c | 2 +- bootstrap/unix-88/Texts.h | 2 +- bootstrap/unix-88/Vishap.c | 2 +- bootstrap/unix-88/errors.c | 2 +- bootstrap/unix-88/errors.h | 2 +- bootstrap/unix-88/extTools.c | 2 +- bootstrap/unix-88/extTools.h | 2 +- bootstrap/unix-88/vt100.c | 2 +- bootstrap/unix-88/vt100.h | 2 +- bootstrap/windows-48/Configuration.c | 4 +- bootstrap/windows-48/Configuration.h | 2 +- bootstrap/windows-48/Console.c | 5 +- bootstrap/windows-48/Console.h | 2 +- bootstrap/windows-48/Files.c | 2 +- bootstrap/windows-48/Files.h | 2 +- bootstrap/windows-48/Heap.c | 2 +- bootstrap/windows-48/Heap.h | 2 +- bootstrap/windows-48/Modules.c | 2 +- bootstrap/windows-48/Modules.h | 2 +- bootstrap/windows-48/OPB.c | 2 +- bootstrap/windows-48/OPB.h | 2 +- bootstrap/windows-48/OPC.c | 2 +- bootstrap/windows-48/OPC.h | 2 +- bootstrap/windows-48/OPM.c | 2 +- bootstrap/windows-48/OPM.h | 2 +- bootstrap/windows-48/OPP.c | 2 +- bootstrap/windows-48/OPP.h | 2 +- bootstrap/windows-48/OPS.c | 19 +- bootstrap/windows-48/OPS.h | 4 +- bootstrap/windows-48/OPT.c | 2 +- bootstrap/windows-48/OPT.h | 2 +- bootstrap/windows-48/OPV.c | 2 +- bootstrap/windows-48/OPV.h | 2 +- bootstrap/windows-48/Platform.c | 2 +- bootstrap/windows-48/Platform.h | 2 +- bootstrap/windows-48/Reals.c | 2 +- bootstrap/windows-48/Reals.h | 2 +- bootstrap/windows-48/Strings.c | 2 +- bootstrap/windows-48/Strings.h | 2 +- bootstrap/windows-48/Texts.c | 2 +- bootstrap/windows-48/Texts.h | 2 +- bootstrap/windows-48/Vishap.c | 2 +- bootstrap/windows-48/errors.c | 2 +- bootstrap/windows-48/errors.h | 2 +- bootstrap/windows-48/extTools.c | 2 +- bootstrap/windows-48/extTools.h | 2 +- bootstrap/windows-48/vt100.c | 2 +- bootstrap/windows-48/vt100.h | 2 +- bootstrap/windows-88/Configuration.c | 4 +- bootstrap/windows-88/Configuration.h | 2 +- bootstrap/windows-88/Console.c | 7 +- bootstrap/windows-88/Console.h | 2 +- bootstrap/windows-88/Files.c | 2 +- bootstrap/windows-88/Files.h | 2 +- bootstrap/windows-88/Heap.c | 2 +- bootstrap/windows-88/Heap.h | 2 +- bootstrap/windows-88/Modules.c | 2 +- bootstrap/windows-88/Modules.h | 2 +- bootstrap/windows-88/OPB.c | 2 +- bootstrap/windows-88/OPB.h | 2 +- bootstrap/windows-88/OPC.c | 2 +- bootstrap/windows-88/OPC.h | 2 +- bootstrap/windows-88/OPM.c | 2 +- bootstrap/windows-88/OPM.h | 2 +- bootstrap/windows-88/OPP.c | 2 +- bootstrap/windows-88/OPP.h | 2 +- bootstrap/windows-88/OPS.c | 9 +- bootstrap/windows-88/OPS.h | 2 +- bootstrap/windows-88/OPT.c | 2 +- bootstrap/windows-88/OPT.h | 2 +- bootstrap/windows-88/OPV.c | 2 +- bootstrap/windows-88/OPV.h | 2 +- bootstrap/windows-88/Platform.c | 2 +- bootstrap/windows-88/Platform.h | 2 +- bootstrap/windows-88/Reals.c | 2 +- bootstrap/windows-88/Reals.h | 2 +- bootstrap/windows-88/Strings.c | 2 +- bootstrap/windows-88/Strings.h | 2 +- bootstrap/windows-88/Texts.c | 2 +- bootstrap/windows-88/Texts.h | 2 +- bootstrap/windows-88/Vishap.c | 2 +- bootstrap/windows-88/errors.c | 2 +- bootstrap/windows-88/errors.h | 2 +- bootstrap/windows-88/extTools.c | 2 +- bootstrap/windows-88/extTools.h | 2 +- bootstrap/windows-88/vt100.c | 2 +- bootstrap/windows-88/vt100.h | 2 +- src/compiler/OPS.Mod | 16 +- src/library/ulm/ulmIO.Mod | 429 +++++++++++++-------------- src/library/ulm/ulmSYSTEM.Mod | 14 +- src/system/Console.Mod | 6 +- 199 files changed, 478 insertions(+), 477 deletions(-) diff --git a/bootstrap/unix-44/Configuration.c b/bootstrap/unix-44/Configuration.c index d8c934bf..06ec0ed7 100644 --- a/bootstrap/unix-44/Configuration.c +++ b/bootstrap/unix-44/Configuration.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -18,6 +18,6 @@ export void *Configuration__init(void) __DEFMOD; __REGMOD("Configuration", 0); /* BEGIN */ - __MOVE("1.95 [2016/09/14] for gcc LP64 on cygwin", Configuration_versionLong, 41); + __MOVE("1.95 [2016/09/15] for gcc LP64 on cygwin", Configuration_versionLong, 41); __ENDMOD; } diff --git a/bootstrap/unix-44/Configuration.h b/bootstrap/unix-44/Configuration.h index 2b7bdf82..9276e796 100644 --- a/bootstrap/unix-44/Configuration.h +++ b/bootstrap/unix-44/Configuration.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Configuration__h #define Configuration__h diff --git a/bootstrap/unix-44/Console.c b/bootstrap/unix-44/Console.c index 5a0b29a2..4007101f 100644 --- a/bootstrap/unix-44/Console.c +++ b/bootstrap/unix-44/Console.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -102,7 +102,8 @@ void Console_Bool (BOOLEAN b) void Console_Hex (int32 i) { - int32 k, n; + int16 k; + int64 n; k = -28; while (k <= 0) { n = __MASK(__ASH(i, k), -16); diff --git a/bootstrap/unix-44/Console.h b/bootstrap/unix-44/Console.h index 0af02096..23ec5930 100644 --- a/bootstrap/unix-44/Console.h +++ b/bootstrap/unix-44/Console.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Console__h #define Console__h diff --git a/bootstrap/unix-44/Files.c b/bootstrap/unix-44/Files.c index 58145066..17a56a1d 100644 --- a/bootstrap/unix-44/Files.c +++ b/bootstrap/unix-44/Files.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Files.h b/bootstrap/unix-44/Files.h index 521906c3..81a5660b 100644 --- a/bootstrap/unix-44/Files.h +++ b/bootstrap/unix-44/Files.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef Files__h #define Files__h diff --git a/bootstrap/unix-44/Heap.c b/bootstrap/unix-44/Heap.c index b3a5908c..c3422d37 100644 --- a/bootstrap/unix-44/Heap.c +++ b/bootstrap/unix-44/Heap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Heap.h b/bootstrap/unix-44/Heap.h index 29b4cb26..2a231c6e 100644 --- a/bootstrap/unix-44/Heap.h +++ b/bootstrap/unix-44/Heap.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #ifndef Heap__h #define Heap__h diff --git a/bootstrap/unix-44/Modules.c b/bootstrap/unix-44/Modules.c index a71d3e4d..74cb4e47 100644 --- a/bootstrap/unix-44/Modules.c +++ b/bootstrap/unix-44/Modules.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Modules.h b/bootstrap/unix-44/Modules.h index 6a744f9b..ba7f2930 100644 --- a/bootstrap/unix-44/Modules.h +++ b/bootstrap/unix-44/Modules.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Modules__h #define Modules__h diff --git a/bootstrap/unix-44/OPB.c b/bootstrap/unix-44/OPB.c index a905da35..5bc128d1 100644 --- a/bootstrap/unix-44/OPB.c +++ b/bootstrap/unix-44/OPB.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPB.h b/bootstrap/unix-44/OPB.h index f9bf31fe..8579409b 100644 --- a/bootstrap/unix-44/OPB.h +++ b/bootstrap/unix-44/OPB.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPB__h #define OPB__h diff --git a/bootstrap/unix-44/OPC.c b/bootstrap/unix-44/OPC.c index 1fecd152..c1a7d45a 100644 --- a/bootstrap/unix-44/OPC.c +++ b/bootstrap/unix-44/OPC.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPC.h b/bootstrap/unix-44/OPC.h index b8f44225..576bdf18 100644 --- a/bootstrap/unix-44/OPC.h +++ b/bootstrap/unix-44/OPC.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPC__h #define OPC__h diff --git a/bootstrap/unix-44/OPM.c b/bootstrap/unix-44/OPM.c index 6af53f8c..ffc05a37 100644 --- a/bootstrap/unix-44/OPM.c +++ b/bootstrap/unix-44/OPM.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPM.h b/bootstrap/unix-44/OPM.h index 67edafa5..56b587e9 100644 --- a/bootstrap/unix-44/OPM.h +++ b/bootstrap/unix-44/OPM.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPM__h #define OPM__h diff --git a/bootstrap/unix-44/OPP.c b/bootstrap/unix-44/OPP.c index d8dee08e..7c0b62db 100644 --- a/bootstrap/unix-44/OPP.c +++ b/bootstrap/unix-44/OPP.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPP.h b/bootstrap/unix-44/OPP.h index 9ddded2f..e578b0bd 100644 --- a/bootstrap/unix-44/OPP.h +++ b/bootstrap/unix-44/OPP.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPP__h #define OPP__h diff --git a/bootstrap/unix-44/OPS.c b/bootstrap/unix-44/OPS.c index cd51e788..5243ea65 100644 --- a/bootstrap/unix-44/OPS.c +++ b/bootstrap/unix-44/OPS.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -17,7 +17,7 @@ typedef export OPS_Name OPS_name; export OPS_String OPS_str; export int16 OPS_numtyp; -export int32 OPS_intval; +export int64 OPS_intval; export REAL OPS_realval; export LONGREAL OPS_lrlval; static CHAR OPS_ch; @@ -132,7 +132,7 @@ static int16 Ord__7 (CHAR ch, BOOLEAN hex) static void OPS_Number (void) { - int16 i, m, n, d, e, maxHdig; + int16 i, m, n, d, e; CHAR dig[24]; LONGREAL f; CHAR expCh; @@ -178,7 +178,7 @@ static void OPS_Number (void) OPS_numtyp = 1; if (n <= 2) { while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -187,13 +187,12 @@ static void OPS_Number (void) } else if (OPS_ch == 'H') { OPM_Get(&OPS_ch); OPS_numtyp = 2; - maxHdig = 8; - if (n <= maxHdig) { - if ((n == maxHdig && dig[0] > '7')) { + if (n <= 16) { + if ((n == 16 && dig[0] > '7')) { OPS_intval = -1; } while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -204,8 +203,8 @@ static void OPS_Number (void) while (i < n) { d = Ord__7(dig[i], 0); i += 1; - if (OPS_intval <= __DIV(2147483647 - d, 10)) { - OPS_intval = OPS_intval * 10 + d; + if (OPS_intval <= (int64)__DIV(9223372036854775807 - d, 10)) { + OPS_intval = OPS_intval * 10 + (int64)d; } else { OPS_err(203); } diff --git a/bootstrap/unix-44/OPS.h b/bootstrap/unix-44/OPS.h index 658c87db..af53d634 100644 --- a/bootstrap/unix-44/OPS.h +++ b/bootstrap/unix-44/OPS.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef OPS__h #define OPS__h @@ -15,7 +15,7 @@ typedef import OPS_Name OPS_name; import OPS_String OPS_str; import int16 OPS_numtyp; -import int32 OPS_intval; +import int64 OPS_intval; import REAL OPS_realval; import LONGREAL OPS_lrlval; diff --git a/bootstrap/unix-44/OPT.c b/bootstrap/unix-44/OPT.c index ab44584b..a12c1a7f 100644 --- a/bootstrap/unix-44/OPT.c +++ b/bootstrap/unix-44/OPT.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPT.h b/bootstrap/unix-44/OPT.h index 978ae16b..dff6a509 100644 --- a/bootstrap/unix-44/OPT.h +++ b/bootstrap/unix-44/OPT.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPT__h #define OPT__h diff --git a/bootstrap/unix-44/OPV.c b/bootstrap/unix-44/OPV.c index c20aef90..b34d16d0 100644 --- a/bootstrap/unix-44/OPV.c +++ b/bootstrap/unix-44/OPV.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/OPV.h b/bootstrap/unix-44/OPV.h index ea1f9aaa..0716a62f 100644 --- a/bootstrap/unix-44/OPV.h +++ b/bootstrap/unix-44/OPV.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPV__h #define OPV__h diff --git a/bootstrap/unix-44/Platform.c b/bootstrap/unix-44/Platform.c index 1bf0628e..a7b7d28a 100644 --- a/bootstrap/unix-44/Platform.c +++ b/bootstrap/unix-44/Platform.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Platform.h b/bootstrap/unix-44/Platform.h index 7c0b2d21..574abdf6 100644 --- a/bootstrap/unix-44/Platform.h +++ b/bootstrap/unix-44/Platform.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Platform__h #define Platform__h diff --git a/bootstrap/unix-44/Reals.c b/bootstrap/unix-44/Reals.c index a64c2d13..30d7462f 100644 --- a/bootstrap/unix-44/Reals.c +++ b/bootstrap/unix-44/Reals.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Reals.h b/bootstrap/unix-44/Reals.h index d7981245..034d0e43 100644 --- a/bootstrap/unix-44/Reals.h +++ b/bootstrap/unix-44/Reals.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Reals__h #define Reals__h diff --git a/bootstrap/unix-44/Strings.c b/bootstrap/unix-44/Strings.c index 67c0f055..a4ed943e 100644 --- a/bootstrap/unix-44/Strings.c +++ b/bootstrap/unix-44/Strings.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Strings.h b/bootstrap/unix-44/Strings.h index 6f4f1073..226b6aeb 100644 --- a/bootstrap/unix-44/Strings.h +++ b/bootstrap/unix-44/Strings.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Strings__h #define Strings__h diff --git a/bootstrap/unix-44/Texts.c b/bootstrap/unix-44/Texts.c index 503c4e06..9ae78a2d 100644 --- a/bootstrap/unix-44/Texts.c +++ b/bootstrap/unix-44/Texts.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/Texts.h b/bootstrap/unix-44/Texts.h index b5b22e1b..af7ba940 100644 --- a/bootstrap/unix-44/Texts.h +++ b/bootstrap/unix-44/Texts.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Texts__h #define Texts__h diff --git a/bootstrap/unix-44/Vishap.c b/bootstrap/unix-44/Vishap.c index 2efce68f..93bbfaf4 100644 --- a/bootstrap/unix-44/Vishap.c +++ b/bootstrap/unix-44/Vishap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkamSf */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkamSf */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/errors.c b/bootstrap/unix-44/errors.c index 6f8e3d33..330d0f79 100644 --- a/bootstrap/unix-44/errors.c +++ b/bootstrap/unix-44/errors.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/errors.h b/bootstrap/unix-44/errors.h index 58286fd8..f916c173 100644 --- a/bootstrap/unix-44/errors.h +++ b/bootstrap/unix-44/errors.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef errors__h #define errors__h diff --git a/bootstrap/unix-44/extTools.c b/bootstrap/unix-44/extTools.c index bbecb9f2..a0370292 100644 --- a/bootstrap/unix-44/extTools.c +++ b/bootstrap/unix-44/extTools.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/extTools.h b/bootstrap/unix-44/extTools.h index 8a0d60be..04a7b8d6 100644 --- a/bootstrap/unix-44/extTools.h +++ b/bootstrap/unix-44/extTools.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef extTools__h #define extTools__h diff --git a/bootstrap/unix-44/vt100.c b/bootstrap/unix-44/vt100.c index b5422c40..7e16410c 100644 --- a/bootstrap/unix-44/vt100.c +++ b/bootstrap/unix-44/vt100.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-44/vt100.h b/bootstrap/unix-44/vt100.h index 85494a63..c1c3c8fa 100644 --- a/bootstrap/unix-44/vt100.h +++ b/bootstrap/unix-44/vt100.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef vt100__h #define vt100__h diff --git a/bootstrap/unix-48/Configuration.c b/bootstrap/unix-48/Configuration.c index d8c934bf..06ec0ed7 100644 --- a/bootstrap/unix-48/Configuration.c +++ b/bootstrap/unix-48/Configuration.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -18,6 +18,6 @@ export void *Configuration__init(void) __DEFMOD; __REGMOD("Configuration", 0); /* BEGIN */ - __MOVE("1.95 [2016/09/14] for gcc LP64 on cygwin", Configuration_versionLong, 41); + __MOVE("1.95 [2016/09/15] for gcc LP64 on cygwin", Configuration_versionLong, 41); __ENDMOD; } diff --git a/bootstrap/unix-48/Configuration.h b/bootstrap/unix-48/Configuration.h index 2b7bdf82..9276e796 100644 --- a/bootstrap/unix-48/Configuration.h +++ b/bootstrap/unix-48/Configuration.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Configuration__h #define Configuration__h diff --git a/bootstrap/unix-48/Console.c b/bootstrap/unix-48/Console.c index 5a0b29a2..4007101f 100644 --- a/bootstrap/unix-48/Console.c +++ b/bootstrap/unix-48/Console.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -102,7 +102,8 @@ void Console_Bool (BOOLEAN b) void Console_Hex (int32 i) { - int32 k, n; + int16 k; + int64 n; k = -28; while (k <= 0) { n = __MASK(__ASH(i, k), -16); diff --git a/bootstrap/unix-48/Console.h b/bootstrap/unix-48/Console.h index 0af02096..23ec5930 100644 --- a/bootstrap/unix-48/Console.h +++ b/bootstrap/unix-48/Console.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Console__h #define Console__h diff --git a/bootstrap/unix-48/Files.c b/bootstrap/unix-48/Files.c index 58145066..17a56a1d 100644 --- a/bootstrap/unix-48/Files.c +++ b/bootstrap/unix-48/Files.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Files.h b/bootstrap/unix-48/Files.h index 521906c3..81a5660b 100644 --- a/bootstrap/unix-48/Files.h +++ b/bootstrap/unix-48/Files.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef Files__h #define Files__h diff --git a/bootstrap/unix-48/Heap.c b/bootstrap/unix-48/Heap.c index b3a5908c..c3422d37 100644 --- a/bootstrap/unix-48/Heap.c +++ b/bootstrap/unix-48/Heap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Heap.h b/bootstrap/unix-48/Heap.h index 29b4cb26..2a231c6e 100644 --- a/bootstrap/unix-48/Heap.h +++ b/bootstrap/unix-48/Heap.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #ifndef Heap__h #define Heap__h diff --git a/bootstrap/unix-48/Modules.c b/bootstrap/unix-48/Modules.c index a71d3e4d..74cb4e47 100644 --- a/bootstrap/unix-48/Modules.c +++ b/bootstrap/unix-48/Modules.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Modules.h b/bootstrap/unix-48/Modules.h index 6a744f9b..ba7f2930 100644 --- a/bootstrap/unix-48/Modules.h +++ b/bootstrap/unix-48/Modules.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Modules__h #define Modules__h diff --git a/bootstrap/unix-48/OPB.c b/bootstrap/unix-48/OPB.c index a905da35..5bc128d1 100644 --- a/bootstrap/unix-48/OPB.c +++ b/bootstrap/unix-48/OPB.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPB.h b/bootstrap/unix-48/OPB.h index f9bf31fe..8579409b 100644 --- a/bootstrap/unix-48/OPB.h +++ b/bootstrap/unix-48/OPB.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPB__h #define OPB__h diff --git a/bootstrap/unix-48/OPC.c b/bootstrap/unix-48/OPC.c index 1fecd152..c1a7d45a 100644 --- a/bootstrap/unix-48/OPC.c +++ b/bootstrap/unix-48/OPC.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPC.h b/bootstrap/unix-48/OPC.h index b8f44225..576bdf18 100644 --- a/bootstrap/unix-48/OPC.h +++ b/bootstrap/unix-48/OPC.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPC__h #define OPC__h diff --git a/bootstrap/unix-48/OPM.c b/bootstrap/unix-48/OPM.c index 6af53f8c..ffc05a37 100644 --- a/bootstrap/unix-48/OPM.c +++ b/bootstrap/unix-48/OPM.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPM.h b/bootstrap/unix-48/OPM.h index 67edafa5..56b587e9 100644 --- a/bootstrap/unix-48/OPM.h +++ b/bootstrap/unix-48/OPM.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPM__h #define OPM__h diff --git a/bootstrap/unix-48/OPP.c b/bootstrap/unix-48/OPP.c index d8dee08e..7c0b62db 100644 --- a/bootstrap/unix-48/OPP.c +++ b/bootstrap/unix-48/OPP.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPP.h b/bootstrap/unix-48/OPP.h index 9ddded2f..e578b0bd 100644 --- a/bootstrap/unix-48/OPP.h +++ b/bootstrap/unix-48/OPP.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPP__h #define OPP__h diff --git a/bootstrap/unix-48/OPS.c b/bootstrap/unix-48/OPS.c index cd51e788..5243ea65 100644 --- a/bootstrap/unix-48/OPS.c +++ b/bootstrap/unix-48/OPS.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -17,7 +17,7 @@ typedef export OPS_Name OPS_name; export OPS_String OPS_str; export int16 OPS_numtyp; -export int32 OPS_intval; +export int64 OPS_intval; export REAL OPS_realval; export LONGREAL OPS_lrlval; static CHAR OPS_ch; @@ -132,7 +132,7 @@ static int16 Ord__7 (CHAR ch, BOOLEAN hex) static void OPS_Number (void) { - int16 i, m, n, d, e, maxHdig; + int16 i, m, n, d, e; CHAR dig[24]; LONGREAL f; CHAR expCh; @@ -178,7 +178,7 @@ static void OPS_Number (void) OPS_numtyp = 1; if (n <= 2) { while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -187,13 +187,12 @@ static void OPS_Number (void) } else if (OPS_ch == 'H') { OPM_Get(&OPS_ch); OPS_numtyp = 2; - maxHdig = 8; - if (n <= maxHdig) { - if ((n == maxHdig && dig[0] > '7')) { + if (n <= 16) { + if ((n == 16 && dig[0] > '7')) { OPS_intval = -1; } while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -204,8 +203,8 @@ static void OPS_Number (void) while (i < n) { d = Ord__7(dig[i], 0); i += 1; - if (OPS_intval <= __DIV(2147483647 - d, 10)) { - OPS_intval = OPS_intval * 10 + d; + if (OPS_intval <= (int64)__DIV(9223372036854775807 - d, 10)) { + OPS_intval = OPS_intval * 10 + (int64)d; } else { OPS_err(203); } diff --git a/bootstrap/unix-48/OPS.h b/bootstrap/unix-48/OPS.h index 658c87db..af53d634 100644 --- a/bootstrap/unix-48/OPS.h +++ b/bootstrap/unix-48/OPS.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef OPS__h #define OPS__h @@ -15,7 +15,7 @@ typedef import OPS_Name OPS_name; import OPS_String OPS_str; import int16 OPS_numtyp; -import int32 OPS_intval; +import int64 OPS_intval; import REAL OPS_realval; import LONGREAL OPS_lrlval; diff --git a/bootstrap/unix-48/OPT.c b/bootstrap/unix-48/OPT.c index ab44584b..a12c1a7f 100644 --- a/bootstrap/unix-48/OPT.c +++ b/bootstrap/unix-48/OPT.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPT.h b/bootstrap/unix-48/OPT.h index 978ae16b..dff6a509 100644 --- a/bootstrap/unix-48/OPT.h +++ b/bootstrap/unix-48/OPT.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPT__h #define OPT__h diff --git a/bootstrap/unix-48/OPV.c b/bootstrap/unix-48/OPV.c index c20aef90..b34d16d0 100644 --- a/bootstrap/unix-48/OPV.c +++ b/bootstrap/unix-48/OPV.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/OPV.h b/bootstrap/unix-48/OPV.h index ea1f9aaa..0716a62f 100644 --- a/bootstrap/unix-48/OPV.h +++ b/bootstrap/unix-48/OPV.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPV__h #define OPV__h diff --git a/bootstrap/unix-48/Platform.c b/bootstrap/unix-48/Platform.c index 1bf0628e..a7b7d28a 100644 --- a/bootstrap/unix-48/Platform.c +++ b/bootstrap/unix-48/Platform.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Platform.h b/bootstrap/unix-48/Platform.h index 7c0b2d21..574abdf6 100644 --- a/bootstrap/unix-48/Platform.h +++ b/bootstrap/unix-48/Platform.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Platform__h #define Platform__h diff --git a/bootstrap/unix-48/Reals.c b/bootstrap/unix-48/Reals.c index a64c2d13..30d7462f 100644 --- a/bootstrap/unix-48/Reals.c +++ b/bootstrap/unix-48/Reals.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Reals.h b/bootstrap/unix-48/Reals.h index d7981245..034d0e43 100644 --- a/bootstrap/unix-48/Reals.h +++ b/bootstrap/unix-48/Reals.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Reals__h #define Reals__h diff --git a/bootstrap/unix-48/Strings.c b/bootstrap/unix-48/Strings.c index 67c0f055..a4ed943e 100644 --- a/bootstrap/unix-48/Strings.c +++ b/bootstrap/unix-48/Strings.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Strings.h b/bootstrap/unix-48/Strings.h index 6f4f1073..226b6aeb 100644 --- a/bootstrap/unix-48/Strings.h +++ b/bootstrap/unix-48/Strings.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Strings__h #define Strings__h diff --git a/bootstrap/unix-48/Texts.c b/bootstrap/unix-48/Texts.c index 4d12f6cb..660559f5 100644 --- a/bootstrap/unix-48/Texts.c +++ b/bootstrap/unix-48/Texts.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/Texts.h b/bootstrap/unix-48/Texts.h index 2b694f6c..5ac796d7 100644 --- a/bootstrap/unix-48/Texts.h +++ b/bootstrap/unix-48/Texts.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Texts__h #define Texts__h diff --git a/bootstrap/unix-48/Vishap.c b/bootstrap/unix-48/Vishap.c index 2efce68f..93bbfaf4 100644 --- a/bootstrap/unix-48/Vishap.c +++ b/bootstrap/unix-48/Vishap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkamSf */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkamSf */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/errors.c b/bootstrap/unix-48/errors.c index 6f8e3d33..330d0f79 100644 --- a/bootstrap/unix-48/errors.c +++ b/bootstrap/unix-48/errors.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/errors.h b/bootstrap/unix-48/errors.h index 58286fd8..f916c173 100644 --- a/bootstrap/unix-48/errors.h +++ b/bootstrap/unix-48/errors.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef errors__h #define errors__h diff --git a/bootstrap/unix-48/extTools.c b/bootstrap/unix-48/extTools.c index bbecb9f2..a0370292 100644 --- a/bootstrap/unix-48/extTools.c +++ b/bootstrap/unix-48/extTools.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/extTools.h b/bootstrap/unix-48/extTools.h index 8a0d60be..04a7b8d6 100644 --- a/bootstrap/unix-48/extTools.h +++ b/bootstrap/unix-48/extTools.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef extTools__h #define extTools__h diff --git a/bootstrap/unix-48/vt100.c b/bootstrap/unix-48/vt100.c index b5422c40..7e16410c 100644 --- a/bootstrap/unix-48/vt100.c +++ b/bootstrap/unix-48/vt100.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/unix-48/vt100.h b/bootstrap/unix-48/vt100.h index 85494a63..c1c3c8fa 100644 --- a/bootstrap/unix-48/vt100.h +++ b/bootstrap/unix-48/vt100.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef vt100__h #define vt100__h diff --git a/bootstrap/unix-88/Configuration.c b/bootstrap/unix-88/Configuration.c index f3f2e52d..e936fb1b 100644 --- a/bootstrap/unix-88/Configuration.c +++ b/bootstrap/unix-88/Configuration.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -18,6 +18,6 @@ export void *Configuration__init(void) __DEFMOD; __REGMOD("Configuration", 0); /* BEGIN */ - __MOVE("1.95 [2016/09/14] for gcc LP64 on cygwin", Configuration_versionLong, 41); + __MOVE("1.95 [2016/09/15] for gcc LP64 on cygwin", Configuration_versionLong, 41); __ENDMOD; } diff --git a/bootstrap/unix-88/Configuration.h b/bootstrap/unix-88/Configuration.h index 2b7bdf82..9276e796 100644 --- a/bootstrap/unix-88/Configuration.h +++ b/bootstrap/unix-88/Configuration.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Configuration__h #define Configuration__h diff --git a/bootstrap/unix-88/Console.c b/bootstrap/unix-88/Console.c index 5039dae6..c25651d5 100644 --- a/bootstrap/unix-88/Console.c +++ b/bootstrap/unix-88/Console.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -102,8 +102,9 @@ void Console_Bool (BOOLEAN b) void Console_Hex (int64 i) { - int64 k, n; - k = -28; + int32 k; + int64 n; + k = -60; while (k <= 0) { n = __MASK(__ASH(i, k), -16); if (n <= 9) { diff --git a/bootstrap/unix-88/Console.h b/bootstrap/unix-88/Console.h index 8336a3d0..288d9e0a 100644 --- a/bootstrap/unix-88/Console.h +++ b/bootstrap/unix-88/Console.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Console__h #define Console__h diff --git a/bootstrap/unix-88/Files.c b/bootstrap/unix-88/Files.c index 1f4e38bf..79b77102 100644 --- a/bootstrap/unix-88/Files.c +++ b/bootstrap/unix-88/Files.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Files.h b/bootstrap/unix-88/Files.h index b1a16504..048e6c0f 100644 --- a/bootstrap/unix-88/Files.h +++ b/bootstrap/unix-88/Files.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef Files__h #define Files__h diff --git a/bootstrap/unix-88/Heap.c b/bootstrap/unix-88/Heap.c index 26f7af6f..fa10e8c0 100644 --- a/bootstrap/unix-88/Heap.c +++ b/bootstrap/unix-88/Heap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Heap.h b/bootstrap/unix-88/Heap.h index 08afe43e..ecebdfeb 100644 --- a/bootstrap/unix-88/Heap.h +++ b/bootstrap/unix-88/Heap.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #ifndef Heap__h #define Heap__h diff --git a/bootstrap/unix-88/Modules.c b/bootstrap/unix-88/Modules.c index 3a48e24a..66df0a5c 100644 --- a/bootstrap/unix-88/Modules.c +++ b/bootstrap/unix-88/Modules.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Modules.h b/bootstrap/unix-88/Modules.h index 3ebde4f3..86580ab4 100644 --- a/bootstrap/unix-88/Modules.h +++ b/bootstrap/unix-88/Modules.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Modules__h #define Modules__h diff --git a/bootstrap/unix-88/OPB.c b/bootstrap/unix-88/OPB.c index 883d2559..5a6a8dda 100644 --- a/bootstrap/unix-88/OPB.c +++ b/bootstrap/unix-88/OPB.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPB.h b/bootstrap/unix-88/OPB.h index 35fb2186..94ff6cbf 100644 --- a/bootstrap/unix-88/OPB.h +++ b/bootstrap/unix-88/OPB.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPB__h #define OPB__h diff --git a/bootstrap/unix-88/OPC.c b/bootstrap/unix-88/OPC.c index ef8f41a1..a4e6388c 100644 --- a/bootstrap/unix-88/OPC.c +++ b/bootstrap/unix-88/OPC.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPC.h b/bootstrap/unix-88/OPC.h index 646d0151..185ac689 100644 --- a/bootstrap/unix-88/OPC.h +++ b/bootstrap/unix-88/OPC.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPC__h #define OPC__h diff --git a/bootstrap/unix-88/OPM.c b/bootstrap/unix-88/OPM.c index 96868200..6b30d07b 100644 --- a/bootstrap/unix-88/OPM.c +++ b/bootstrap/unix-88/OPM.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPM.h b/bootstrap/unix-88/OPM.h index d4b77c79..9c71f996 100644 --- a/bootstrap/unix-88/OPM.h +++ b/bootstrap/unix-88/OPM.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPM__h #define OPM__h diff --git a/bootstrap/unix-88/OPP.c b/bootstrap/unix-88/OPP.c index 7e958472..dce9eaec 100644 --- a/bootstrap/unix-88/OPP.c +++ b/bootstrap/unix-88/OPP.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPP.h b/bootstrap/unix-88/OPP.h index 9ddded2f..e578b0bd 100644 --- a/bootstrap/unix-88/OPP.h +++ b/bootstrap/unix-88/OPP.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPP__h #define OPP__h diff --git a/bootstrap/unix-88/OPS.c b/bootstrap/unix-88/OPS.c index 208f4934..61d3ad08 100644 --- a/bootstrap/unix-88/OPS.c +++ b/bootstrap/unix-88/OPS.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -132,7 +132,7 @@ static int32 Ord__7 (CHAR ch, BOOLEAN hex) static void OPS_Number (void) { - int32 i, m, n, d, e, maxHdig; + int32 i, m, n, d, e; CHAR dig[24]; LONGREAL f; CHAR expCh; @@ -187,9 +187,8 @@ static void OPS_Number (void) } else if (OPS_ch == 'H') { OPM_Get(&OPS_ch); OPS_numtyp = 2; - maxHdig = 16; - if (n <= maxHdig) { - if ((n == maxHdig && dig[0] > '7')) { + if (n <= 16) { + if ((n == 16 && dig[0] > '7')) { OPS_intval = -1; } while (i < n) { diff --git a/bootstrap/unix-88/OPS.h b/bootstrap/unix-88/OPS.h index bb045fe9..eef23e1f 100644 --- a/bootstrap/unix-88/OPS.h +++ b/bootstrap/unix-88/OPS.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef OPS__h #define OPS__h diff --git a/bootstrap/unix-88/OPT.c b/bootstrap/unix-88/OPT.c index afc5a8b6..82c2df59 100644 --- a/bootstrap/unix-88/OPT.c +++ b/bootstrap/unix-88/OPT.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPT.h b/bootstrap/unix-88/OPT.h index 090d9111..7b529043 100644 --- a/bootstrap/unix-88/OPT.h +++ b/bootstrap/unix-88/OPT.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPT__h #define OPT__h diff --git a/bootstrap/unix-88/OPV.c b/bootstrap/unix-88/OPV.c index 098463c4..023ee089 100644 --- a/bootstrap/unix-88/OPV.c +++ b/bootstrap/unix-88/OPV.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/OPV.h b/bootstrap/unix-88/OPV.h index ea1f9aaa..0716a62f 100644 --- a/bootstrap/unix-88/OPV.h +++ b/bootstrap/unix-88/OPV.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPV__h #define OPV__h diff --git a/bootstrap/unix-88/Platform.c b/bootstrap/unix-88/Platform.c index f428c2b1..8bbc2357 100644 --- a/bootstrap/unix-88/Platform.c +++ b/bootstrap/unix-88/Platform.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Platform.h b/bootstrap/unix-88/Platform.h index d9212710..077cb445 100644 --- a/bootstrap/unix-88/Platform.h +++ b/bootstrap/unix-88/Platform.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Platform__h #define Platform__h diff --git a/bootstrap/unix-88/Reals.c b/bootstrap/unix-88/Reals.c index b3e89e04..b4890fa9 100644 --- a/bootstrap/unix-88/Reals.c +++ b/bootstrap/unix-88/Reals.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Reals.h b/bootstrap/unix-88/Reals.h index 3892d49c..37f91340 100644 --- a/bootstrap/unix-88/Reals.h +++ b/bootstrap/unix-88/Reals.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Reals__h #define Reals__h diff --git a/bootstrap/unix-88/Strings.c b/bootstrap/unix-88/Strings.c index 1eef261b..4f6767e1 100644 --- a/bootstrap/unix-88/Strings.c +++ b/bootstrap/unix-88/Strings.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Strings.h b/bootstrap/unix-88/Strings.h index 8145aa00..235891d2 100644 --- a/bootstrap/unix-88/Strings.h +++ b/bootstrap/unix-88/Strings.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Strings__h #define Strings__h diff --git a/bootstrap/unix-88/Texts.c b/bootstrap/unix-88/Texts.c index d8710e54..7a6726a6 100644 --- a/bootstrap/unix-88/Texts.c +++ b/bootstrap/unix-88/Texts.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/Texts.h b/bootstrap/unix-88/Texts.h index 8389bc47..ea9dde4b 100644 --- a/bootstrap/unix-88/Texts.h +++ b/bootstrap/unix-88/Texts.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Texts__h #define Texts__h diff --git a/bootstrap/unix-88/Vishap.c b/bootstrap/unix-88/Vishap.c index 3972af10..fef94478 100644 --- a/bootstrap/unix-88/Vishap.c +++ b/bootstrap/unix-88/Vishap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkamSf */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkamSf */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/errors.c b/bootstrap/unix-88/errors.c index 8864c777..88cb5688 100644 --- a/bootstrap/unix-88/errors.c +++ b/bootstrap/unix-88/errors.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/errors.h b/bootstrap/unix-88/errors.h index 58286fd8..f916c173 100644 --- a/bootstrap/unix-88/errors.h +++ b/bootstrap/unix-88/errors.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef errors__h #define errors__h diff --git a/bootstrap/unix-88/extTools.c b/bootstrap/unix-88/extTools.c index bb60848a..08e242e0 100644 --- a/bootstrap/unix-88/extTools.c +++ b/bootstrap/unix-88/extTools.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/extTools.h b/bootstrap/unix-88/extTools.h index 8a0d60be..04a7b8d6 100644 --- a/bootstrap/unix-88/extTools.h +++ b/bootstrap/unix-88/extTools.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef extTools__h #define extTools__h diff --git a/bootstrap/unix-88/vt100.c b/bootstrap/unix-88/vt100.c index c143a6b3..96358c5b 100644 --- a/bootstrap/unix-88/vt100.c +++ b/bootstrap/unix-88/vt100.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/unix-88/vt100.h b/bootstrap/unix-88/vt100.h index 11a9c941..b9c5430c 100644 --- a/bootstrap/unix-88/vt100.h +++ b/bootstrap/unix-88/vt100.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef vt100__h #define vt100__h diff --git a/bootstrap/windows-48/Configuration.c b/bootstrap/windows-48/Configuration.c index d8c934bf..06ec0ed7 100644 --- a/bootstrap/windows-48/Configuration.c +++ b/bootstrap/windows-48/Configuration.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -18,6 +18,6 @@ export void *Configuration__init(void) __DEFMOD; __REGMOD("Configuration", 0); /* BEGIN */ - __MOVE("1.95 [2016/09/14] for gcc LP64 on cygwin", Configuration_versionLong, 41); + __MOVE("1.95 [2016/09/15] for gcc LP64 on cygwin", Configuration_versionLong, 41); __ENDMOD; } diff --git a/bootstrap/windows-48/Configuration.h b/bootstrap/windows-48/Configuration.h index 2b7bdf82..9276e796 100644 --- a/bootstrap/windows-48/Configuration.h +++ b/bootstrap/windows-48/Configuration.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Configuration__h #define Configuration__h diff --git a/bootstrap/windows-48/Console.c b/bootstrap/windows-48/Console.c index 359bad0a..931e8e9b 100644 --- a/bootstrap/windows-48/Console.c +++ b/bootstrap/windows-48/Console.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -102,7 +102,8 @@ void Console_Bool (BOOLEAN b) void Console_Hex (int32 i) { - int32 k, n; + int16 k; + int64 n; k = -28; while (k <= 0) { n = __MASK(__ASH(i, k), -16); diff --git a/bootstrap/windows-48/Console.h b/bootstrap/windows-48/Console.h index 0af02096..23ec5930 100644 --- a/bootstrap/windows-48/Console.h +++ b/bootstrap/windows-48/Console.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Console__h #define Console__h diff --git a/bootstrap/windows-48/Files.c b/bootstrap/windows-48/Files.c index 01218f26..50b625ff 100644 --- a/bootstrap/windows-48/Files.c +++ b/bootstrap/windows-48/Files.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Files.h b/bootstrap/windows-48/Files.h index ffdc05f6..f680e056 100644 --- a/bootstrap/windows-48/Files.h +++ b/bootstrap/windows-48/Files.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef Files__h #define Files__h diff --git a/bootstrap/windows-48/Heap.c b/bootstrap/windows-48/Heap.c index b3a5908c..c3422d37 100644 --- a/bootstrap/windows-48/Heap.c +++ b/bootstrap/windows-48/Heap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Heap.h b/bootstrap/windows-48/Heap.h index 29b4cb26..2a231c6e 100644 --- a/bootstrap/windows-48/Heap.h +++ b/bootstrap/windows-48/Heap.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #ifndef Heap__h #define Heap__h diff --git a/bootstrap/windows-48/Modules.c b/bootstrap/windows-48/Modules.c index a71d3e4d..74cb4e47 100644 --- a/bootstrap/windows-48/Modules.c +++ b/bootstrap/windows-48/Modules.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Modules.h b/bootstrap/windows-48/Modules.h index 6a744f9b..ba7f2930 100644 --- a/bootstrap/windows-48/Modules.h +++ b/bootstrap/windows-48/Modules.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Modules__h #define Modules__h diff --git a/bootstrap/windows-48/OPB.c b/bootstrap/windows-48/OPB.c index a905da35..5bc128d1 100644 --- a/bootstrap/windows-48/OPB.c +++ b/bootstrap/windows-48/OPB.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPB.h b/bootstrap/windows-48/OPB.h index f9bf31fe..8579409b 100644 --- a/bootstrap/windows-48/OPB.h +++ b/bootstrap/windows-48/OPB.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPB__h #define OPB__h diff --git a/bootstrap/windows-48/OPC.c b/bootstrap/windows-48/OPC.c index 1fecd152..c1a7d45a 100644 --- a/bootstrap/windows-48/OPC.c +++ b/bootstrap/windows-48/OPC.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPC.h b/bootstrap/windows-48/OPC.h index b8f44225..576bdf18 100644 --- a/bootstrap/windows-48/OPC.h +++ b/bootstrap/windows-48/OPC.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPC__h #define OPC__h diff --git a/bootstrap/windows-48/OPM.c b/bootstrap/windows-48/OPM.c index 6af53f8c..ffc05a37 100644 --- a/bootstrap/windows-48/OPM.c +++ b/bootstrap/windows-48/OPM.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPM.h b/bootstrap/windows-48/OPM.h index 67edafa5..56b587e9 100644 --- a/bootstrap/windows-48/OPM.h +++ b/bootstrap/windows-48/OPM.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPM__h #define OPM__h diff --git a/bootstrap/windows-48/OPP.c b/bootstrap/windows-48/OPP.c index d8dee08e..7c0b62db 100644 --- a/bootstrap/windows-48/OPP.c +++ b/bootstrap/windows-48/OPP.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPP.h b/bootstrap/windows-48/OPP.h index 9ddded2f..e578b0bd 100644 --- a/bootstrap/windows-48/OPP.h +++ b/bootstrap/windows-48/OPP.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPP__h #define OPP__h diff --git a/bootstrap/windows-48/OPS.c b/bootstrap/windows-48/OPS.c index cd51e788..5243ea65 100644 --- a/bootstrap/windows-48/OPS.c +++ b/bootstrap/windows-48/OPS.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int16 #define LONGINT int32 @@ -17,7 +17,7 @@ typedef export OPS_Name OPS_name; export OPS_String OPS_str; export int16 OPS_numtyp; -export int32 OPS_intval; +export int64 OPS_intval; export REAL OPS_realval; export LONGREAL OPS_lrlval; static CHAR OPS_ch; @@ -132,7 +132,7 @@ static int16 Ord__7 (CHAR ch, BOOLEAN hex) static void OPS_Number (void) { - int16 i, m, n, d, e, maxHdig; + int16 i, m, n, d, e; CHAR dig[24]; LONGREAL f; CHAR expCh; @@ -178,7 +178,7 @@ static void OPS_Number (void) OPS_numtyp = 1; if (n <= 2) { while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -187,13 +187,12 @@ static void OPS_Number (void) } else if (OPS_ch == 'H') { OPM_Get(&OPS_ch); OPS_numtyp = 2; - maxHdig = 8; - if (n <= maxHdig) { - if ((n == maxHdig && dig[0] > '7')) { + if (n <= 16) { + if ((n == 16 && dig[0] > '7')) { OPS_intval = -1; } while (i < n) { - OPS_intval = __ASHL(OPS_intval, 4) + Ord__7(dig[i], 1); + OPS_intval = __ASHL(OPS_intval, 4) + (int64)Ord__7(dig[i], 1); i += 1; } } else { @@ -204,8 +203,8 @@ static void OPS_Number (void) while (i < n) { d = Ord__7(dig[i], 0); i += 1; - if (OPS_intval <= __DIV(2147483647 - d, 10)) { - OPS_intval = OPS_intval * 10 + d; + if (OPS_intval <= (int64)__DIV(9223372036854775807 - d, 10)) { + OPS_intval = OPS_intval * 10 + (int64)d; } else { OPS_err(203); } diff --git a/bootstrap/windows-48/OPS.h b/bootstrap/windows-48/OPS.h index 658c87db..af53d634 100644 --- a/bootstrap/windows-48/OPS.h +++ b/bootstrap/windows-48/OPS.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef OPS__h #define OPS__h @@ -15,7 +15,7 @@ typedef import OPS_Name OPS_name; import OPS_String OPS_str; import int16 OPS_numtyp; -import int32 OPS_intval; +import int64 OPS_intval; import REAL OPS_realval; import LONGREAL OPS_lrlval; diff --git a/bootstrap/windows-48/OPT.c b/bootstrap/windows-48/OPT.c index ab44584b..a12c1a7f 100644 --- a/bootstrap/windows-48/OPT.c +++ b/bootstrap/windows-48/OPT.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPT.h b/bootstrap/windows-48/OPT.h index 978ae16b..dff6a509 100644 --- a/bootstrap/windows-48/OPT.h +++ b/bootstrap/windows-48/OPT.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPT__h #define OPT__h diff --git a/bootstrap/windows-48/OPV.c b/bootstrap/windows-48/OPV.c index c20aef90..b34d16d0 100644 --- a/bootstrap/windows-48/OPV.c +++ b/bootstrap/windows-48/OPV.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/OPV.h b/bootstrap/windows-48/OPV.h index ea1f9aaa..0716a62f 100644 --- a/bootstrap/windows-48/OPV.h +++ b/bootstrap/windows-48/OPV.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPV__h #define OPV__h diff --git a/bootstrap/windows-48/Platform.c b/bootstrap/windows-48/Platform.c index 8740b5b0..afc6f96c 100644 --- a/bootstrap/windows-48/Platform.c +++ b/bootstrap/windows-48/Platform.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Platform.h b/bootstrap/windows-48/Platform.h index ce51df39..2d3185ce 100644 --- a/bootstrap/windows-48/Platform.h +++ b/bootstrap/windows-48/Platform.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Platform__h #define Platform__h diff --git a/bootstrap/windows-48/Reals.c b/bootstrap/windows-48/Reals.c index a64c2d13..30d7462f 100644 --- a/bootstrap/windows-48/Reals.c +++ b/bootstrap/windows-48/Reals.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Reals.h b/bootstrap/windows-48/Reals.h index d7981245..034d0e43 100644 --- a/bootstrap/windows-48/Reals.h +++ b/bootstrap/windows-48/Reals.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Reals__h #define Reals__h diff --git a/bootstrap/windows-48/Strings.c b/bootstrap/windows-48/Strings.c index 67c0f055..a4ed943e 100644 --- a/bootstrap/windows-48/Strings.c +++ b/bootstrap/windows-48/Strings.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Strings.h b/bootstrap/windows-48/Strings.h index 6f4f1073..226b6aeb 100644 --- a/bootstrap/windows-48/Strings.h +++ b/bootstrap/windows-48/Strings.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Strings__h #define Strings__h diff --git a/bootstrap/windows-48/Texts.c b/bootstrap/windows-48/Texts.c index 4d12f6cb..660559f5 100644 --- a/bootstrap/windows-48/Texts.c +++ b/bootstrap/windows-48/Texts.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/Texts.h b/bootstrap/windows-48/Texts.h index 2b694f6c..5ac796d7 100644 --- a/bootstrap/windows-48/Texts.h +++ b/bootstrap/windows-48/Texts.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Texts__h #define Texts__h diff --git a/bootstrap/windows-48/Vishap.c b/bootstrap/windows-48/Vishap.c index 2efce68f..93bbfaf4 100644 --- a/bootstrap/windows-48/Vishap.c +++ b/bootstrap/windows-48/Vishap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkamSf */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkamSf */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/errors.c b/bootstrap/windows-48/errors.c index 6f8e3d33..330d0f79 100644 --- a/bootstrap/windows-48/errors.c +++ b/bootstrap/windows-48/errors.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/errors.h b/bootstrap/windows-48/errors.h index 58286fd8..f916c173 100644 --- a/bootstrap/windows-48/errors.h +++ b/bootstrap/windows-48/errors.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef errors__h #define errors__h diff --git a/bootstrap/windows-48/extTools.c b/bootstrap/windows-48/extTools.c index bbecb9f2..a0370292 100644 --- a/bootstrap/windows-48/extTools.c +++ b/bootstrap/windows-48/extTools.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/extTools.h b/bootstrap/windows-48/extTools.h index 8a0d60be..04a7b8d6 100644 --- a/bootstrap/windows-48/extTools.h +++ b/bootstrap/windows-48/extTools.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef extTools__h #define extTools__h diff --git a/bootstrap/windows-48/vt100.c b/bootstrap/windows-48/vt100.c index b5422c40..7e16410c 100644 --- a/bootstrap/windows-48/vt100.c +++ b/bootstrap/windows-48/vt100.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int16 #define LONGINT int32 diff --git a/bootstrap/windows-48/vt100.h b/bootstrap/windows-48/vt100.h index 85494a63..c1c3c8fa 100644 --- a/bootstrap/windows-48/vt100.h +++ b/bootstrap/windows-48/vt100.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef vt100__h #define vt100__h diff --git a/bootstrap/windows-88/Configuration.c b/bootstrap/windows-88/Configuration.c index f3f2e52d..e936fb1b 100644 --- a/bootstrap/windows-88/Configuration.c +++ b/bootstrap/windows-88/Configuration.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -18,6 +18,6 @@ export void *Configuration__init(void) __DEFMOD; __REGMOD("Configuration", 0); /* BEGIN */ - __MOVE("1.95 [2016/09/14] for gcc LP64 on cygwin", Configuration_versionLong, 41); + __MOVE("1.95 [2016/09/15] for gcc LP64 on cygwin", Configuration_versionLong, 41); __ENDMOD; } diff --git a/bootstrap/windows-88/Configuration.h b/bootstrap/windows-88/Configuration.h index 2b7bdf82..9276e796 100644 --- a/bootstrap/windows-88/Configuration.h +++ b/bootstrap/windows-88/Configuration.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Configuration__h #define Configuration__h diff --git a/bootstrap/windows-88/Console.c b/bootstrap/windows-88/Console.c index f1d67d28..ef385b37 100644 --- a/bootstrap/windows-88/Console.c +++ b/bootstrap/windows-88/Console.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -102,8 +102,9 @@ void Console_Bool (BOOLEAN b) void Console_Hex (int64 i) { - int64 k, n; - k = -28; + int32 k; + int64 n; + k = -60; while (k <= 0) { n = __MASK(__ASH(i, k), -16); if (n <= 9) { diff --git a/bootstrap/windows-88/Console.h b/bootstrap/windows-88/Console.h index 8336a3d0..288d9e0a 100644 --- a/bootstrap/windows-88/Console.h +++ b/bootstrap/windows-88/Console.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Console__h #define Console__h diff --git a/bootstrap/windows-88/Files.c b/bootstrap/windows-88/Files.c index 6c40d595..6b890417 100644 --- a/bootstrap/windows-88/Files.c +++ b/bootstrap/windows-88/Files.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Files.h b/bootstrap/windows-88/Files.h index d3432e7a..ab570a35 100644 --- a/bootstrap/windows-88/Files.h +++ b/bootstrap/windows-88/Files.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef Files__h #define Files__h diff --git a/bootstrap/windows-88/Heap.c b/bootstrap/windows-88/Heap.c index 26f7af6f..fa10e8c0 100644 --- a/bootstrap/windows-88/Heap.c +++ b/bootstrap/windows-88/Heap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Heap.h b/bootstrap/windows-88/Heap.h index 08afe43e..ecebdfeb 100644 --- a/bootstrap/windows-88/Heap.h +++ b/bootstrap/windows-88/Heap.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tskSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tskSfF */ #ifndef Heap__h #define Heap__h diff --git a/bootstrap/windows-88/Modules.c b/bootstrap/windows-88/Modules.c index 3a48e24a..66df0a5c 100644 --- a/bootstrap/windows-88/Modules.c +++ b/bootstrap/windows-88/Modules.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Modules.h b/bootstrap/windows-88/Modules.h index 3ebde4f3..86580ab4 100644 --- a/bootstrap/windows-88/Modules.h +++ b/bootstrap/windows-88/Modules.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Modules__h #define Modules__h diff --git a/bootstrap/windows-88/OPB.c b/bootstrap/windows-88/OPB.c index 883d2559..5a6a8dda 100644 --- a/bootstrap/windows-88/OPB.c +++ b/bootstrap/windows-88/OPB.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPB.h b/bootstrap/windows-88/OPB.h index 35fb2186..94ff6cbf 100644 --- a/bootstrap/windows-88/OPB.h +++ b/bootstrap/windows-88/OPB.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPB__h #define OPB__h diff --git a/bootstrap/windows-88/OPC.c b/bootstrap/windows-88/OPC.c index ef8f41a1..a4e6388c 100644 --- a/bootstrap/windows-88/OPC.c +++ b/bootstrap/windows-88/OPC.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPC.h b/bootstrap/windows-88/OPC.h index 646d0151..185ac689 100644 --- a/bootstrap/windows-88/OPC.h +++ b/bootstrap/windows-88/OPC.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPC__h #define OPC__h diff --git a/bootstrap/windows-88/OPM.c b/bootstrap/windows-88/OPM.c index 96868200..6b30d07b 100644 --- a/bootstrap/windows-88/OPM.c +++ b/bootstrap/windows-88/OPM.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPM.h b/bootstrap/windows-88/OPM.h index d4b77c79..9c71f996 100644 --- a/bootstrap/windows-88/OPM.h +++ b/bootstrap/windows-88/OPM.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPM__h #define OPM__h diff --git a/bootstrap/windows-88/OPP.c b/bootstrap/windows-88/OPP.c index 7e958472..dce9eaec 100644 --- a/bootstrap/windows-88/OPP.c +++ b/bootstrap/windows-88/OPP.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPP.h b/bootstrap/windows-88/OPP.h index 9ddded2f..e578b0bd 100644 --- a/bootstrap/windows-88/OPP.h +++ b/bootstrap/windows-88/OPP.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPP__h #define OPP__h diff --git a/bootstrap/windows-88/OPS.c b/bootstrap/windows-88/OPS.c index 208f4934..61d3ad08 100644 --- a/bootstrap/windows-88/OPS.c +++ b/bootstrap/windows-88/OPS.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #define INTEGER int32 #define LONGINT int64 @@ -132,7 +132,7 @@ static int32 Ord__7 (CHAR ch, BOOLEAN hex) static void OPS_Number (void) { - int32 i, m, n, d, e, maxHdig; + int32 i, m, n, d, e; CHAR dig[24]; LONGREAL f; CHAR expCh; @@ -187,9 +187,8 @@ static void OPS_Number (void) } else if (OPS_ch == 'H') { OPM_Get(&OPS_ch); OPS_numtyp = 2; - maxHdig = 16; - if (n <= maxHdig) { - if ((n == maxHdig && dig[0] > '7')) { + if (n <= 16) { + if ((n == 16 && dig[0] > '7')) { OPS_intval = -1; } while (i < n) { diff --git a/bootstrap/windows-88/OPS.h b/bootstrap/windows-88/OPS.h index bb045fe9..eef23e1f 100644 --- a/bootstrap/windows-88/OPS.h +++ b/bootstrap/windows-88/OPS.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin tspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin tspkaSfF */ #ifndef OPS__h #define OPS__h diff --git a/bootstrap/windows-88/OPT.c b/bootstrap/windows-88/OPT.c index afc5a8b6..82c2df59 100644 --- a/bootstrap/windows-88/OPT.c +++ b/bootstrap/windows-88/OPT.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPT.h b/bootstrap/windows-88/OPT.h index 090d9111..7b529043 100644 --- a/bootstrap/windows-88/OPT.h +++ b/bootstrap/windows-88/OPT.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPT__h #define OPT__h diff --git a/bootstrap/windows-88/OPV.c b/bootstrap/windows-88/OPV.c index 098463c4..023ee089 100644 --- a/bootstrap/windows-88/OPV.c +++ b/bootstrap/windows-88/OPV.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/OPV.h b/bootstrap/windows-88/OPV.h index ea1f9aaa..0716a62f 100644 --- a/bootstrap/windows-88/OPV.h +++ b/bootstrap/windows-88/OPV.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef OPV__h #define OPV__h diff --git a/bootstrap/windows-88/Platform.c b/bootstrap/windows-88/Platform.c index 3bb993de..a8579af5 100644 --- a/bootstrap/windows-88/Platform.c +++ b/bootstrap/windows-88/Platform.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Platform.h b/bootstrap/windows-88/Platform.h index c1175e02..a016f061 100644 --- a/bootstrap/windows-88/Platform.h +++ b/bootstrap/windows-88/Platform.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Platform__h #define Platform__h diff --git a/bootstrap/windows-88/Reals.c b/bootstrap/windows-88/Reals.c index b3e89e04..b4890fa9 100644 --- a/bootstrap/windows-88/Reals.c +++ b/bootstrap/windows-88/Reals.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Reals.h b/bootstrap/windows-88/Reals.h index 3892d49c..37f91340 100644 --- a/bootstrap/windows-88/Reals.h +++ b/bootstrap/windows-88/Reals.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Reals__h #define Reals__h diff --git a/bootstrap/windows-88/Strings.c b/bootstrap/windows-88/Strings.c index 1eef261b..4f6767e1 100644 --- a/bootstrap/windows-88/Strings.c +++ b/bootstrap/windows-88/Strings.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Strings.h b/bootstrap/windows-88/Strings.h index 8145aa00..235891d2 100644 --- a/bootstrap/windows-88/Strings.h +++ b/bootstrap/windows-88/Strings.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Strings__h #define Strings__h diff --git a/bootstrap/windows-88/Texts.c b/bootstrap/windows-88/Texts.c index d8710e54..7a6726a6 100644 --- a/bootstrap/windows-88/Texts.c +++ b/bootstrap/windows-88/Texts.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/Texts.h b/bootstrap/windows-88/Texts.h index 8389bc47..ea9dde4b 100644 --- a/bootstrap/windows-88/Texts.h +++ b/bootstrap/windows-88/Texts.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef Texts__h #define Texts__h diff --git a/bootstrap/windows-88/Vishap.c b/bootstrap/windows-88/Vishap.c index 3972af10..fef94478 100644 --- a/bootstrap/windows-88/Vishap.c +++ b/bootstrap/windows-88/Vishap.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkamSf */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkamSf */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/errors.c b/bootstrap/windows-88/errors.c index 8864c777..88cb5688 100644 --- a/bootstrap/windows-88/errors.c +++ b/bootstrap/windows-88/errors.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/errors.h b/bootstrap/windows-88/errors.h index 58286fd8..f916c173 100644 --- a/bootstrap/windows-88/errors.h +++ b/bootstrap/windows-88/errors.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef errors__h #define errors__h diff --git a/bootstrap/windows-88/extTools.c b/bootstrap/windows-88/extTools.c index bb60848a..08e242e0 100644 --- a/bootstrap/windows-88/extTools.c +++ b/bootstrap/windows-88/extTools.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/extTools.h b/bootstrap/windows-88/extTools.h index 8a0d60be..04a7b8d6 100644 --- a/bootstrap/windows-88/extTools.h +++ b/bootstrap/windows-88/extTools.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef extTools__h #define extTools__h diff --git a/bootstrap/windows-88/vt100.c b/bootstrap/windows-88/vt100.c index c143a6b3..96358c5b 100644 --- a/bootstrap/windows-88/vt100.c +++ b/bootstrap/windows-88/vt100.c @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #define INTEGER int32 #define LONGINT int64 diff --git a/bootstrap/windows-88/vt100.h b/bootstrap/windows-88/vt100.h index 11a9c941..b9c5430c 100644 --- a/bootstrap/windows-88/vt100.h +++ b/bootstrap/windows-88/vt100.h @@ -1,4 +1,4 @@ -/* voc 1.95 [2016/09/14] for gcc LP64 on cygwin xtspkaSfF */ +/* voc 1.95 [2016/09/15] for gcc LP64 on cygwin xtspkaSfF */ #ifndef vt100__h #define vt100__h diff --git a/src/compiler/OPS.Mod b/src/compiler/OPS.Mod index 33b325d8..909cdee2 100644 --- a/src/compiler/OPS.Mod +++ b/src/compiler/OPS.Mod @@ -1,6 +1,6 @@ MODULE OPS; (* NW, RC 6.3.89 / 18.10.92 *) (* object model 3.6.92 *) - IMPORT OPM; + IMPORT OPM, SYSTEM; CONST MaxStrLen* = 256; @@ -51,8 +51,8 @@ MODULE OPS; (* NW, RC 6.3.89 / 18.10.92 *) (* object model 3.6.92 *) (* name, str, numtyp, intval, realval, lrlval are implicit results of Get *) name*: Name; str*: String; - numtyp*: INTEGER; (* 1 = char, 2 = integer, 3 = real, 4 = longreal *) - intval*: LONGINT; (* integer value or string length *) + numtyp*: INTEGER; (* 1 = char, 2 = integer, 3 = real, 4 = longreal *) + intval*: SYSTEM.INT64; (* integer value or string length *) realval*: REAL; lrlval*: LONGREAL; @@ -89,7 +89,8 @@ MODULE OPS; (* NW, RC 6.3.89 / 18.10.92 *) (* object model 3.6.92 *) END Identifier; PROCEDURE Number; - VAR i, m, n, d, e, maxHdig: INTEGER; dig: ARRAY 24 OF CHAR; f: LONGREAL; expCh: CHAR; neg: BOOLEAN; + CONST maxhexdigits = 16; + VAR i, m, n, d, e: INTEGER; dig: ARRAY 24 OF CHAR; f: LONGREAL; expCh: CHAR; neg: BOOLEAN; PROCEDURE Ten(e: INTEGER): LONGREAL; VAR x, p: LONGREAL; @@ -135,15 +136,14 @@ MODULE OPS; (* NW, RC 6.3.89 / 18.10.92 *) (* object model 3.6.92 *) ELSE err(203) END ELSIF ch = "H" THEN (* hexadecimal *) OPM.Get(ch); numtyp := integer; - IF MAX(LONGINT) > 2147483647 THEN maxHdig := 16 ELSE maxHdig := 8 END; - IF n <= maxHdig THEN - IF (n = maxHdig) & (dig[0] > "7") THEN (* prevent overflow *) intval := -1 END; + IF n <= maxhexdigits THEN + IF (n = maxhexdigits) & (dig[0] > "7") THEN (* prevent overflow *) intval := -1 END; WHILE i < n DO intval := intval*10H + Ord(dig[i], TRUE); INC(i) END ELSE err(203) END ELSE (* decimal *) numtyp := integer; WHILE i < n DO d := Ord(dig[i], FALSE); INC(i); - IF intval <= (MAX(LONGINT) - d) DIV 10 THEN intval := intval*10 + d + IF intval <= (MAX(SYSTEM.INT64) - d) DIV 10 THEN intval := intval*10 + d ELSE err(203) END END diff --git a/src/library/ulm/ulmIO.Mod b/src/library/ulm/ulmIO.Mod index 2fa775e1..87ff46fa 100644 --- a/src/library/ulm/ulmIO.Mod +++ b/src/library/ulm/ulmIO.Mod @@ -1,244 +1,243 @@ MODULE ulmIO; - IMPORT SYS := ulmSYSTEM, SYSTEM; + IMPORT SYS := ulmSYSTEM, SYSTEM; - CONST nl = 0AX; + CONST nl = 0AX; - (* conversions *) + (* conversions *) - CONST - oct = 0; - dec = 1; - hex = 2; - TYPE - Basetype = SHORTINT; (* oct..hex *) + CONST + oct = 0; + dec = 1; + hex = 2; + TYPE + Basetype = SHORTINT; (* oct..hex *) - (* basic IO *) + (* basic IO *) - VAR - Done*: BOOLEAN; - oldch: CHAR; - readAgain: BOOLEAN; + VAR + Done*: BOOLEAN; + oldch: CHAR; + readAgain: BOOLEAN; - (* ==================== conversions ================================= *) + (* ==================== conversions ================================= *) - PROCEDURE ConvertNumber(num, len: LONGINT; btyp: Basetype; neg: BOOLEAN; - VAR str: ARRAY OF CHAR); + PROCEDURE ConvertNumber(num, len: LONGINT; btyp: Basetype; neg: BOOLEAN; + VAR str: ARRAY OF CHAR); - (* conversion of a number into a string of characters *) - (* num must get the absolute value of the number *) - (* len is the minimal length of the generated string *) - (* neg means: "the number is negative" for btyp = dec *) + (* conversion of a number into a string of characters *) + (* num must get the absolute value of the number *) + (* len is the minimal length of the generated string *) + (* neg means: "the number is negative" for btyp = dec *) - (*CONST - NumberLen = 11;*) - (* we need it as variable to change the value depending on architecture; -- noch *) - VAR - (*digits : ARRAY NumberLen+1 OF CHAR;*) - digits : POINTER TO ARRAY OF CHAR; - base : INTEGER; - cnt, ix : INTEGER; - maxlen : LONGINT; - dig : LONGINT; - NumberLen : SHORTINT; - BEGIN - - IF SIZE(LONGINT) = 4 THEN - NumberLen := 11 - ELSIF SIZE(LONGINT) = 8 THEN - NumberLen := 21 + (*CONST + NumberLen = 11;*) + (* we need it as variable to change the value depending on architecture; -- noch *) + VAR + (*digits : ARRAY NumberLen+1 OF CHAR;*) + digits : POINTER TO ARRAY OF CHAR; + base : INTEGER; + cnt, ix : INTEGER; + maxlen : LONGINT; + dig : LONGINT; + NumberLen : SHORTINT; + BEGIN + IF SIZE(LONGINT) = 4 THEN + NumberLen := 11 + ELSIF SIZE(LONGINT) = 8 THEN + NumberLen := 21 + ELSE + NumberLen := 11 (* default value, corresponds to 32 bit *) + END; + NEW(digits, NumberLen + 1 ); + ASSERT(num >= 0); + ix := 1; + WHILE ix <= NumberLen DO + digits[ix] := "0"; + INC(ix); + END; (* initialisation *) + IF btyp = oct THEN + base := 8; + ELSIF btyp = dec THEN + base := 10; + ELSIF btyp = hex THEN + base := 10H; + END; + cnt := 0; + REPEAT + INC(cnt); + dig := num MOD base; + num := num DIV base; + IF dig < 10 THEN + dig := dig + ORD("0"); ELSE - NumberLen := 11 (* default value, corresponds to 32 bit *) + dig := dig - 10 + ORD("A"); END; - NEW(digits, NumberLen + 1 ); - ASSERT(num >= 0); - ix := 1; - WHILE ix <= NumberLen DO - digits[ix] := "0"; - INC(ix); - END; (* initialisation *) - IF btyp = oct THEN - base := 8; - ELSIF btyp = dec THEN - base := 10; - ELSIF btyp = hex THEN - base := 10H; - END; - cnt := 0; - REPEAT - INC(cnt); - dig := num MOD base; - num := num DIV base; - IF dig < 10 THEN - dig := dig + ORD("0"); - ELSE - dig := dig - 10 + ORD("A"); - END; - digits[cnt] := CHR(dig); - UNTIL num = 0; - (* (* i don't like this *) - IF btyp = oct THEN - cnt := 11; - ELSIF btyp = hex THEN - cnt := 8; - ELSIF neg THEN - *) - IF neg THEN - INC(cnt); - digits[cnt] := "-"; - END; - maxlen := LEN(str); (* get maximal length *) - IF len > maxlen THEN - len := SHORT(maxlen); - END; - IF cnt > maxlen THEN - cnt := SHORT(maxlen); - END; - ix := 0; - WHILE len > cnt DO - str[ix] := " "; - INC(ix); - DEC(len); - END; - WHILE cnt > 0 DO - str[ix] := digits[cnt]; - INC(ix); - DEC(cnt); - END; - IF ix < maxlen THEN - str[ix] := 0X; - END; - END ConvertNumber; + digits[cnt] := CHR(dig); + UNTIL num = 0; + (* (* i don't like this *) + IF btyp = oct THEN + cnt := 11; + ELSIF btyp = hex THEN + cnt := 8; + ELSIF neg THEN + *) + IF neg THEN + INC(cnt); + digits[cnt] := "-"; + END; + maxlen := LEN(str); (* get maximal length *) + IF len > maxlen THEN + len := SHORT(maxlen); + END; + IF cnt > maxlen THEN + cnt := SHORT(maxlen); + END; + ix := 0; + WHILE len > cnt DO + str[ix] := " "; + INC(ix); + DEC(len); + END; + WHILE cnt > 0 DO + str[ix] := digits[cnt]; + INC(ix); + DEC(cnt); + END; + IF ix < maxlen THEN + str[ix] := 0X; + END; + END ConvertNumber; - PROCEDURE ConvertInteger(num: LONGINT; len: INTEGER; VAR str: ARRAY OF - CHAR); - (* conversion of an integer decimal number to a string *) - BEGIN - ConvertNumber(ABS(num),len,dec,num < 0,str); - END ConvertInteger; + PROCEDURE ConvertInteger(num: LONGINT; len: INTEGER; VAR str: ARRAY OF + CHAR); + (* conversion of an integer decimal number to a string *) + BEGIN + ConvertNumber(ABS(num),len,dec,num < 0,str); + END ConvertInteger; - (* ========================= terminal ============================ *) + (* ========================= terminal ============================ *) - PROCEDURE ReadChar(VAR ch: CHAR) : BOOLEAN; - CONST read = 3; - (*VAR r0, r1: INTEGER;*) - VAR r0, r1: LONGINT; (* in ulm system INTEGER and LONGINT have the same 4 byte size; -- noch *) - BEGIN - RETURN SYS.UNIXCALL(read, r0, r1, 0, SYSTEM.ADR(ch), 1) & (r0 > 0) - END ReadChar; + PROCEDURE ReadChar(VAR ch: CHAR) : BOOLEAN; + CONST read = 3; + (*VAR r0, r1: INTEGER;*) + VAR r0, r1: LONGINT; (* in ulm system INTEGER and LONGINT have the same 4 byte size; -- noch *) + BEGIN + RETURN SYS.UNIXCALL(read, r0, r1, 0, SYSTEM.ADR(ch), 1) & (r0 > 0) + END ReadChar; - PROCEDURE WriteChar(ch: CHAR) : BOOLEAN; - CONST write = 4; - (*VAR r0, r1: INTEGER;*) - VAR r0, r1: LONGINT; (* same here *) - BEGIN - RETURN SYS.UNIXCALL(write, r0, r1, 1, SYSTEM.ADR(ch), 1) - END WriteChar; + PROCEDURE WriteChar(ch: CHAR) : BOOLEAN; + CONST write = 4; + (*VAR r0, r1: INTEGER;*) + VAR r0, r1: LONGINT; (* same here *) + BEGIN + RETURN SYS.UNIXCALL(write, r0, r1, 1, SYSTEM.ADR(ch), 1) + END WriteChar; - PROCEDURE Read*(VAR ch: CHAR); - BEGIN - Done := TRUE; - IF readAgain THEN - ch := oldch; - readAgain := FALSE; - ELSIF ~ReadChar(ch) THEN - Done := FALSE; - ch := 0X; - ELSE - oldch := ch; - END; - END Read; - - PROCEDURE ReadAgain*; - BEGIN - IF readAgain THEN - Done := FALSE; - ELSE - Done := TRUE; - readAgain := TRUE; - END; - END ReadAgain; - - PROCEDURE Write*(ch: CHAR); - BEGIN - Done := WriteChar(ch); - END Write; - - PROCEDURE WriteLn*; - CONST nl = 0AX; - BEGIN - Write(nl); - END WriteLn; - - PROCEDURE WriteString*(s: ARRAY OF CHAR); - VAR i: INTEGER; - BEGIN - i := 0; - WHILE (i < LEN(s)) & (s[i] # 0X) DO - Write(s[i]); - INC(i); - END; - END WriteString; - - PROCEDURE InitIO; - BEGIN + PROCEDURE Read*(VAR ch: CHAR); + BEGIN + Done := TRUE; + IF readAgain THEN + ch := oldch; readAgain := FALSE; + ELSIF ~ReadChar(ch) THEN + Done := FALSE; + ch := 0X; + ELSE + oldch := ch; + END; + END Read; + + PROCEDURE ReadAgain*; + BEGIN + IF readAgain THEN + Done := FALSE; + ELSE Done := TRUE; - END InitIO; + readAgain := TRUE; + END; + END ReadAgain; - PROCEDURE WriteInt*(arg: LONGINT); - VAR field: ARRAY 23 OF CHAR; - BEGIN (* the field size should be big enough to hold the long number. it was 12 to hold just 32 bit numbers, now it can hold 64 bit numbers; need to be more for 128bit numbers; -- noch *) - ConvertInteger(arg, 1, field); - WriteString(field); - END WriteInt; + PROCEDURE Write*(ch: CHAR); + BEGIN + Done := WriteChar(ch); + END Write; - PROCEDURE ReadInt*(VAR arg: LONGINT); - VAR ch: CHAR; - minus: BOOLEAN; - BEGIN - minus := FALSE; - REPEAT - Read(ch); - IF ~Done THEN RETURN END; - IF ch = "-" THEN - minus := TRUE; - ELSIF (ch # " ") & (ch # nl) & ((ch < "0") OR (ch > "9")) THEN - WriteString("--- Integer expected on input"); WriteLn; - END; - UNTIL (ch >= "0") & (ch <= "9"); - arg := ORD(ch) - ORD("0"); - REPEAT - Read(ch); - IF ~Done THEN RETURN END; - IF (ch >= "0") & (ch <= "9") THEN - arg := arg*10 + (ORD(ch) - ORD("0")); - END; - UNTIL (ch < "0") OR (ch > "9"); - ReadAgain; - IF minus THEN arg := -arg; END; - END ReadInt; + PROCEDURE WriteLn*; + CONST nl = 0AX; + BEGIN + Write(nl); + END WriteLn; - PROCEDURE ReadLine*(VAR string: ARRAY OF CHAR); - VAR - index: INTEGER; - ch: CHAR; - ok: BOOLEAN; - BEGIN - index := 0; ok := TRUE; - LOOP - IF ~ReadChar(ch) THEN ok := FALSE; EXIT END; - IF ch = nl THEN EXIT END; - IF index < LEN(string) THEN - string[index] := ch; INC(index); - END; + PROCEDURE WriteString*(s: ARRAY OF CHAR); + VAR i: INTEGER; + BEGIN + i := 0; + WHILE (i < LEN(s)) & (s[i] # 0X) DO + Write(s[i]); + INC(i); + END; + END WriteString; + + PROCEDURE InitIO; + BEGIN + readAgain := FALSE; + Done := TRUE; + END InitIO; + + PROCEDURE WriteInt*(arg: LONGINT); + VAR field: ARRAY 23 OF CHAR; + BEGIN (* the field size should be big enough to hold the long number. it was 12 to hold just 32 bit numbers, now it can hold 64 bit numbers; need to be more for 128bit numbers; -- noch *) + ConvertInteger(arg, 1, field); + WriteString(field); + END WriteInt; + + PROCEDURE ReadInt*(VAR arg: LONGINT); + VAR ch: CHAR; + minus: BOOLEAN; + BEGIN + minus := FALSE; + REPEAT + Read(ch); + IF ~Done THEN RETURN END; + IF ch = "-" THEN + minus := TRUE; + ELSIF (ch # " ") & (ch # nl) & ((ch < "0") OR (ch > "9")) THEN + WriteString("--- Integer expected on input"); WriteLn; END; + UNTIL (ch >= "0") & (ch <= "9"); + arg := ORD(ch) - ORD("0"); + REPEAT + Read(ch); + IF ~Done THEN RETURN END; + IF (ch >= "0") & (ch <= "9") THEN + arg := arg*10 + (ORD(ch) - ORD("0")); + END; + UNTIL (ch < "0") OR (ch > "9"); + ReadAgain; + IF minus THEN arg := -arg; END; + END ReadInt; + + PROCEDURE ReadLine*(VAR string: ARRAY OF CHAR); + VAR + index: INTEGER; + ch: CHAR; + ok: BOOLEAN; + BEGIN + index := 0; ok := TRUE; + LOOP + IF ~ReadChar(ch) THEN ok := FALSE; EXIT END; + IF ch = nl THEN EXIT END; IF index < LEN(string) THEN - string[index] := 0X; + string[index] := ch; INC(index); END; - Done := ok OR (index > 0); - END ReadLine; + END; + IF index < LEN(string) THEN + string[index] := 0X; + END; + Done := ok OR (index > 0); + END ReadLine; BEGIN - InitIO; + InitIO; END ulmIO. diff --git a/src/library/ulm/ulmSYSTEM.Mod b/src/library/ulm/ulmSYSTEM.Mod index 838548f0..bbd054b8 100644 --- a/src/library/ulm/ulmSYSTEM.Mod +++ b/src/library/ulm/ulmSYSTEM.Mod @@ -50,23 +50,25 @@ TYPE pchar = POINTER TO ARRAY 1 OF CHAR; END TAS; PROCEDURE UNIXCALL*(syscall: LONGINT; VAR d0, d1: LONGINT; (* in ulm version both LONGINT and INTEGER are 4 byte size *) - arg1, arg2, arg3: LONGINT) : BOOLEAN; + arg1, arg2, arg3: LONGINT) : BOOLEAN; VAR n: LONGINT; ch: CHAR; pch: pchar; - pstr: pstring; + pstr: pstring; h: Platform.FileHandle; (* pst : pstatus; *) BEGIN - + IF syscall = Sys.read THEN - RETURN Platform.Read(arg1, arg2, arg3, n) = 0; + d0 := Platform.Read(arg1, arg2, arg3, n); + IF d0 >= 0 THEN d0 := n END; + RETURN d0 >= 0; (*NEW(pch); pch := SYSTEM.VAL(pchar, arg2); ch := pch^[0]; n := read(ch); - IF n # 1 THEN + IF n # 1 THEN ch := 0X; RETURN FALSE ELSE @@ -81,7 +83,7 @@ TYPE pchar = POINTER TO ARRAY 1 OF CHAR; n := Write(SYSTEM.VAL(LONGINT, pch), 1); IF n # 1 THEN RETURN FALSE ELSE RETURN TRUE END *) - ELSIF syscall = Sys.open THEN + ELSIF syscall = Sys.open THEN pstr := SYSTEM.VAL(pstring, arg1); IF SYSTEM.VAL(SET, arg3) * {0,1} # {} THEN RETURN Platform.OldRW(pstr^, d0) = 0 diff --git a/src/system/Console.Mod b/src/system/Console.Mod index 8e2be161..430519df 100644 --- a/src/system/Console.Mod +++ b/src/system/Console.Mod @@ -10,7 +10,7 @@ MODULE Console; (* J. Templ, 29-June-96 *) PROCEDURE Flush*; VAR error: Platform.ErrorCode; BEGIN - error := Platform.Write(Platform.StdOut, SYSTEM.ADR(line), pos); + error := Platform.Write(Platform.StdOut, SYSTEM.ADR(line), pos); pos := 0; END Flush; @@ -53,9 +53,9 @@ MODULE Console; (* J. Templ, 29-June-96 *) END Bool; PROCEDURE Hex*(i: LONGINT); - VAR k, n: LONGINT; + VAR k: INTEGER; n: SYSTEM.INT64; BEGIN - k := -28; + k := 4 - 8 * SIZE(LONGINT); WHILE k <= 0 DO n := ASH(i, k) MOD 16; IF n <= 9 THEN Char(CHR(ORD("0") + n)) ELSE Char(CHR(ORD("A") - 10 + n)) END ;