mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-12 02:50:05 +02:00
+ typed const alignment bug
This commit is contained in:
parent
f07799a2ef
commit
8e8348c304
22
bugs/bug0251.pp
Normal file
22
bugs/bug0251.pp
Normal file
@ -0,0 +1,22 @@
|
||||
|
||||
|
||||
const
|
||||
c : byte = 5;
|
||||
r : real = 3.4;
|
||||
var
|
||||
l : longint;
|
||||
cc : char;
|
||||
rr : real;
|
||||
|
||||
begin
|
||||
l:=longint(@r);
|
||||
if (l mod 4)<>0 then
|
||||
begin
|
||||
Writeln('static const are not aligned properly !');
|
||||
end;
|
||||
l:=longint(@rr);
|
||||
if (l mod 4)<>0 then
|
||||
begin
|
||||
Writeln('static var are not aligned properly !');
|
||||
end;
|
||||
end.
|
@ -344,3 +344,4 @@ bug0245.pp assigning pointers to address of consts is allowed (refused by BP !
|
||||
bug0246.pp const para can be changed without error
|
||||
bug0249.pp procedure of object cannot be assigned to property.
|
||||
bug0250.PP error with Ansistrings and loops.
|
||||
bug0251.pp typed const are not aligned correctly
|
Loading…
Reference in New Issue
Block a user