* new bugs

This commit is contained in:
peter 2001-08-05 12:23:31 +00:00
parent 4f53ca7d23
commit f58a8fc277
3 changed files with 56 additions and 0 deletions

View File

@ -1,4 +1,6 @@
{ %CPU=i386 }
{ %VERSION=1.1 }
{$ifdef fpc}
{$mode delphi}
{$asmmode intel}

17
tests/tbs/tb0368.pp Normal file
View 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
View 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.