mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 07:19:27 +02:00
* packenum bug
This commit is contained in:
parent
5d7597c09f
commit
3503b88e37
20
tests/tbs/tbs0340.pp
Normal file
20
tests/tbs/tbs0340.pp
Normal file
@ -0,0 +1,20 @@
|
||||
{$packenum 1}
|
||||
type
|
||||
t = (a,b,c,d,e);
|
||||
|
||||
const arr: array[0..4] of t = (a,b,c,d,e);
|
||||
|
||||
var
|
||||
x: byte;
|
||||
|
||||
begin
|
||||
x := 0;
|
||||
writeln(ord(arr[x]),' ',ord(arr[x+1]),' ',ord(arr[x+2]),' ',ord(arr[x+3]),' ',ord(arr[x+4]));
|
||||
for x:=0 to 4 do
|
||||
if ord(arr[x])<>x then
|
||||
begin
|
||||
writeln('error in {$packenum 1}');
|
||||
halt(1);
|
||||
end;
|
||||
end.
|
||||
|
Loading…
Reference in New Issue
Block a user