mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-02 13:19:34 +01:00
+ known problems described
This commit is contained in:
parent
1df2fe0bb8
commit
487408c8da
@ -1,4 +1,4 @@
|
||||
{ %KNOWN }
|
||||
{ %KNOWNRUNERROR=1 Free Pascal does not compute args from left to right }
|
||||
|
||||
{ Old file: tbs0243.pp }
|
||||
{ Arguments of functions are computed from right to left this }
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
{ %KNOWN }
|
||||
{ %KNOWNCOMPILEERROR= Problem with virtual and overloaded methods }
|
||||
{ Old file: tbs0262.pp }
|
||||
{ problems with virtual and overloaded methods }
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
{ %KNOWN }
|
||||
{ %KNOWNRUNERROR=1 Known array of char problems }
|
||||
|
||||
{$P+}
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
{ %KNOWN }
|
||||
{ %KNOWNRUNERROR=1 Known array of char problems }
|
||||
{$P-}
|
||||
|
||||
type
|
||||
|
||||
@ -1,12 +1,15 @@
|
||||
|
||||
{ %KNOWNRUNERROR=2 v1.0 computes binary nodes with longint and cardinals as cardinals }
|
||||
{ Testing longint and cardinal addtions }
|
||||
{ The current 1.0 compiler does handle these operations
|
||||
differently depending on range check state,
|
||||
which is rather bad thing PM }
|
||||
const
|
||||
has_errors : boolean = false;
|
||||
has_severe_errors : boolean = false;
|
||||
|
||||
procedure fail(a,b,c,d : int64;range_check_on : boolean);
|
||||
var
|
||||
r1,r2 : longint;
|
||||
begin
|
||||
Write('Error: ',a,'+',b,' does not give ',c,' but ',d,'($',hexstr(d,16),') with $R');
|
||||
if range_check_on then
|
||||
@ -14,6 +17,11 @@ begin
|
||||
else
|
||||
Writeln('-');
|
||||
has_errors:=true;
|
||||
{$R-}
|
||||
r1:=c;
|
||||
r2:=d;
|
||||
if r1<>r2 then
|
||||
has_severe_errors:=true;
|
||||
end;
|
||||
|
||||
var
|
||||
@ -224,6 +232,11 @@ begin
|
||||
if (res+5<>f) or ((res and $ffff) <>$fff9) or (res<>res2) then
|
||||
fail(f,c,res2,res,false);
|
||||
|
||||
if has_errors then
|
||||
if {$R-} a+e <> {$R+} a+e then
|
||||
has_severe_errors:=true;
|
||||
if has_severe_errors then
|
||||
halt(1);
|
||||
|
||||
if has_errors then
|
||||
halt(2);
|
||||
end.
|
||||
|
||||
Loading…
Reference in New Issue
Block a user