mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 17:59:25 +02:00
* new bugs
This commit is contained in:
parent
4f53ca7d23
commit
f58a8fc277
@ -1,4 +1,6 @@
|
||||
{ %CPU=i386 }
|
||||
{ %VERSION=1.1 }
|
||||
|
||||
{$ifdef fpc}
|
||||
{$mode delphi}
|
||||
{$asmmode intel}
|
||||
|
17
tests/tbs/tb0368.pp
Normal file
17
tests/tbs/tb0368.pp
Normal file
@ -0,0 +1,17 @@
|
||||
type
|
||||
tproc = procedure of object;
|
||||
trec = record
|
||||
l1,l2 : longint;
|
||||
end;
|
||||
var
|
||||
pfn : tproc;
|
||||
|
||||
begin
|
||||
pfn:=nil;
|
||||
if (trec(pfn).l1<>0) or
|
||||
(trec(pfn).l2<>0) then
|
||||
begin
|
||||
writeln('Error!');
|
||||
halt(1);
|
||||
end;
|
||||
end.
|
37
tests/tbs/tb0369.pp
Normal file
37
tests/tbs/tb0369.pp
Normal file
@ -0,0 +1,37 @@
|
||||
|
||||
type
|
||||
ptchar=^tchar;
|
||||
tchar=record
|
||||
c : char;
|
||||
end;
|
||||
|
||||
function inl(l:ptchar):ptchar;
|
||||
begin
|
||||
inc(l);
|
||||
inl:=l;
|
||||
end;
|
||||
|
||||
var
|
||||
i : longint;
|
||||
j : ptchar;
|
||||
s : string;
|
||||
error : boolean;
|
||||
begin
|
||||
error:=false;
|
||||
s:='012345789';
|
||||
j:=@s[1];
|
||||
for i:=1to 8 do
|
||||
begin
|
||||
writeln(inl(j)^.c);
|
||||
If (inl(j)^.c<>s[i+1]) Then
|
||||
error:=true;
|
||||
inc(j);
|
||||
end;
|
||||
if error then
|
||||
begin
|
||||
writeln('Error!');
|
||||
halt(1);
|
||||
end;
|
||||
end.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user