* new bugs

This commit is contained in:
peter 2002-12-15 20:25:29 +00:00
parent 8e66f19170
commit 8d0dc4b69d
8 changed files with 20194 additions and 1 deletions

35
tests/webtbf/tw1969.pp Normal file
View File

@ -0,0 +1,35 @@
{ %fail }
{ Source provided for Free Pascal Bug Report 1969 }
{ Submitted by "Sergey Kosarevsky" on 2002-05-13 }
{ e-mail: netsurfer@au.ru }
Type tDemo=Object
Static:Longint;
Constructor Init;
Procedure Run(Var Msg); Message 1; // But this is an Object, not a Class !!! How can a make use of this declaration ?
End;
Type tDemo1=Object
Static:Longint;
Constructor Init;
Procedure Run; Dynamic; // I caouldn't find this keyword in documentation
End;
Constructor tDemo.Init;
Begin
End;
Constructor tDemo1.Init;
Begin
End;
Procedure tDemo.Run(Var Msg);
Begin
End;
Procedure tDemo1.Run;
Begin
End;
Begin
End.

20
tests/webtbf/tw2018.pp Normal file
View File

@ -0,0 +1,20 @@
{ %fail }
{ Source provided for Free Pascal Bug Report 2018 }
{ Submitted by "Sergey Kosarevsky" on 2002-06-29 }
{ e-mail: netsurfer@au.ru }
Unit tw2018;
Interface
Type tExtObject=Object
{ The next line should be refused }
Procedure Draw;External;
End;
Implementation
Procedure tExtObject.Draw;External;
Begin
End.

View File

@ -5,7 +5,14 @@ program printftest;
{$mode objfpc}{$H+}
procedure printf(fm: pchar; args: array of const); cdecl; external 'c';
const
{$ifdef win32}
libc='msvcrt';
{$else}
libc='c';
{$endif}
procedure printf(fm: pchar; args: array of const); cdecl; external libc;
procedure print(args: array of const);
begin

69
tests/webtbs/tw2233.pp Normal file
View File

@ -0,0 +1,69 @@
{ Source provided for Free Pascal Bug Report 2233 }
{ Submitted by "Sergey Kosarevsky" on 2002-11-19 }
{ e-mail: netsurfer@au.ru }
Type pGUIView=^tGUIView;
tGUIView=Object
Constructor Init;
Procedure RenderView;Virtual;Abstract;
End;
Type tGUIWindow=Object(tGUIView)
Constructor Init;
Procedure RenderView;Virtual;
End;
Type tGUICommonControl=Object(tGUIWindow)
Constructor Init;
Constructor Init(Param1:Longint);
End;
Type pGUIRadioGroup=^tGUIRadioGroup;
tGUIRadioGroup=Object(tGUICommonControl)
Constructor Init;
Constructor Init(Param1:Longint);
Procedure RenderView;Virtual;
End;
var
err : boolean;
Constructor tGUIView.Init;
Begin
End;
Constructor tGUIWindow.Init;
Begin
Inherited Init;
End;
Procedure tGUIWindow.RenderView;
Begin
WriteLn('tGUIWindow.RenderView()');
End;
Constructor tGUICommonControl.Init;
Begin
Init(0);
End;
Constructor tGUICommonControl.Init(Param1:Longint);
Begin
Inherited Init;
End;
Constructor tGUIRadioGroup.Init;
Begin
Inherited Init;
End;
Constructor tGUIRadioGroup.Init(Param1:Longint);
Begin
Inherited Init(Param1);
End;
Procedure tGUIRadioGroup.RenderView;
Begin
Inherited RenderView;
WriteLn('tGUIRadioGroup.RenderView()');
err:=false;
End;
Var View:pGUIView;
Begin
err:=true;
View:=New(pGUIRadioGroup,Init);
View^.RenderView;
if err then
begin
writeln('ERROR!');
halt(1);
end;
End.

20006
tests/webtbs/tw2242.pp Normal file

File diff suppressed because it is too large Load Diff

31
tests/webtbs/tw2250.pp Normal file
View File

@ -0,0 +1,31 @@
{ Source provided for Free Pascal Bug Report 2250 }
{ Submitted by "Konstantin Seiler" on 2002-12-04 }
{ e-mail: list@kseiler.de }
procedure stringbug;
var env:ansistring;
procedure addenv(s:ansistring);
begin
// Uncomment next line and everything works as espected.
//writeln(length(env));
if length(env)=0 then env:=s
else env:=env+'|'+s;
end;
begin
env:='';
addenv('first');
addenv('second');
addenv('third');
// It schould write "first|second|third",
// but only writes "third".
writeln(env);
if env<>'first|second|third' then
begin
writeln('ERROR!');
halt(1);
end;
end;
begin
stringbug;
end.

12
tests/webtbs/tw2259.pp Normal file
View File

@ -0,0 +1,12 @@
{ Source provided for Free Pascal Bug Report 2259 }
{ Submitted by "Sergey Kosarevsky" on 2002-12-14 }
{ e-mail: netsurfer@au.ru }
{$STATIC ON}
Type tObject=Object
ClassFlags:Longint;Static;
End;
Begin
tObject.ClassFlags:=255;
End.

13
tests/webtbs/tw2260.pp Normal file
View File

@ -0,0 +1,13 @@
{ %version=1.1 }
{$mode delphi}
procedure test(x: integer = 2);
begin
writeln(x);
end;
begin
test(1);
test;
end.