mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-19 23:39:31 +02:00
+ 809-810-812-813-814-815
This commit is contained in:
parent
bf32e168f9
commit
0e9aecc98c
7
tests/webtbs/tbug809.pp
Normal file
7
tests/webtbs/tbug809.pp
Normal file
@ -0,0 +1,7 @@
|
||||
PROGRAM Test;
|
||||
|
||||
USES Tbug809a;
|
||||
|
||||
BEGIN
|
||||
Schreib('Test');
|
||||
END.
|
14
tests/webtbs/tbug809a.pp
Normal file
14
tests/webtbs/tbug809a.pp
Normal file
@ -0,0 +1,14 @@
|
||||
UNIT tbug809a;
|
||||
|
||||
INTERFACE
|
||||
|
||||
PROCEDURE Schreib(st : STRING);
|
||||
|
||||
IMPLEMENTATION
|
||||
|
||||
PROCEDURE Schreib(st : STRING);
|
||||
BEGIN
|
||||
WriteLn(st);
|
||||
END;
|
||||
|
||||
END.
|
13
tests/webtbs/tbug810.pp
Normal file
13
tests/webtbs/tbug810.pp
Normal file
@ -0,0 +1,13 @@
|
||||
program bug;
|
||||
var i:byte;
|
||||
e:extended;
|
||||
s:string;
|
||||
begin
|
||||
e:=103; (*1003,100003,1000003*)
|
||||
for i:=0 to 17 do
|
||||
begin
|
||||
str(e:0:i,s);
|
||||
writeln(s);
|
||||
end;
|
||||
|
||||
end.
|
26
tests/webtbs/tbug812.pp
Normal file
26
tests/webtbs/tbug812.pp
Normal file
@ -0,0 +1,26 @@
|
||||
program TestVm2;
|
||||
|
||||
{$IFDEF WIN32}{$APPTYPE CONSOLE}{$ENDIF}
|
||||
|
||||
procedure Test;
|
||||
var
|
||||
P: Pointer;
|
||||
begin
|
||||
P:=nil;
|
||||
ReAllocMem(P, 8);
|
||||
ReAllocMem(P, 0);
|
||||
end;
|
||||
|
||||
var MemBefore : longint;
|
||||
begin
|
||||
writeln(MemAvail);
|
||||
MemBefore:=MemAvail;
|
||||
Test;
|
||||
writeln(MemAvail);
|
||||
if MemBefore<>MemAvail then
|
||||
begin
|
||||
Writeln('ReAllocMem creates emory leaks');
|
||||
Writeln('Bug 812 is not yet fixed');
|
||||
Halt(1);
|
||||
end;
|
||||
end.
|
31
tests/webtbs/tbug813.pp
Normal file
31
tests/webtbs/tbug813.pp
Normal file
@ -0,0 +1,31 @@
|
||||
program TestVm2;
|
||||
|
||||
{$IFDEF WIN32}{$APPTYPE CONSOLE}{$ENDIF}
|
||||
|
||||
procedure Test;
|
||||
var
|
||||
P: Pointer;
|
||||
begin
|
||||
P:=nil;
|
||||
ReAllocMem(P, 8);
|
||||
ReAllocMem(P, 0);
|
||||
if P<>nil then
|
||||
begin
|
||||
Writeln('ReAllocMem wtih zero size does not set pointer to nil');
|
||||
Writeln('Bug 813 is not yet fixed');
|
||||
Halt(1);
|
||||
end;
|
||||
end;
|
||||
|
||||
var MemBefore : longint;
|
||||
begin
|
||||
writeln(MemAvail);
|
||||
MemBefore:=MemAvail;
|
||||
Test;
|
||||
writeln(MemAvail);
|
||||
if MemBefore<>MemAvail then
|
||||
begin
|
||||
Writeln('ReAllocMem creates emory leaks');
|
||||
Writeln('Bug 812 is not yet fixed');
|
||||
end;
|
||||
end.
|
5
tests/webtbs/tbug814.pp
Normal file
5
tests/webtbs/tbug814.pp
Normal file
@ -0,0 +1,5 @@
|
||||
const
|
||||
MaxFloat80 = 1.1E+4932;
|
||||
begin
|
||||
Writeln(MaxFloat80);
|
||||
end.
|
10
tests/webtbs/tbug815.pp
Normal file
10
tests/webtbs/tbug815.pp
Normal file
@ -0,0 +1,10 @@
|
||||
{$mode delphi}
|
||||
|
||||
function T: Integer;
|
||||
begin
|
||||
for Result:=0 to 10 do ;
|
||||
end;
|
||||
|
||||
begin
|
||||
T;
|
||||
end.
|
Loading…
Reference in New Issue
Block a user