huge enumeration type definitions (i. e. sizeOf > 4) silently fails
Original Reporter info from Mantis: kays @KaiBurghardt
-
Reporter name: Kai Burghardt
Original Reporter info from Mantis: kays @KaiBurghardt
- Reporter name: Kai Burghardt
Description:
One can define enumeration type elements that are not storeable.
Steps to reproduce:
program bigEnum(input, output, stderr);
var
enum: (null = 0, semimax = high(longWord), max = high(qWord));
begin
enum := max;
writeLn(enum); // erroneously prints "semimax"
end.
Additional information:
The {$packEnum} directive only allows enumeration types up to and including 4 bytes. Maybe this needs an update?
Mantis conversion info:
- Mantis ID: 35849
- OS: GNU/Linux
- OS Build: 4.2
- Build: 3.0.4+dfsg-11 [2017/12/30]
- Platform: x86_64
- Version: 3.0.4