I am working on a project, the nature of which requires that it is portable across dialects, compilers, targets and memory models.target and the bit widths for CARDINAL and LONGINT.
Having examined some 16 or 17 classic Modula-2 compilers (PIM and ISO), I concluded that there are three different memory models:
(1) 16-bit CARDINAL, 32-bit LONGINT
(2) 32-bit CARDINAL, 32-bit LONGINT
(3) 32-bit CARDINAL, 64-bit LONGINT
In other words, it would seem that no matter which compiler, target and memory model, type LONGINT is always at least 32-bit wide.
Nevertheless, I would be interested to learn of any exceptions where this is not the case. So, if you have come across a compiler providing a memory model different than the above mentioned three cases, please post a reply to let me know which compiler/
Thank you in advance.
compiler/target and the bit widths for CARDINAL and LONGINT.Having examined some 16 or 17 classic Modula-2 compilers (PIM and ISO), I concluded that there are three different memory models:
(1) 16-bit CARDINAL, 32-bit LONGINT
(2) 32-bit CARDINAL, 32-bit LONGINT
(3) 32-bit CARDINAL, 64-bit LONGINT
In other words, it would seem that no matter which compiler, target and memory model, type LONGINT is always at least 32-bit wide.
Nevertheless, I would be interested to learn of any exceptions where this is not the case. So, if you have come across a compiler providing a memory model different than the above mentioned three cases, please post a reply to let me know which
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 468 |
Nodes: | 16 (2 / 14) |
Uptime: | 20:36:54 |
Calls: | 9,440 |
Calls today: | 3 |
Files: | 13,594 |
Messages: | 6,109,945 |