View Issue Details

IDProjectCategoryView StatusLast Update
0037377FPCCompilerpublic2020-07-17 04:26
ReporterGameHunter Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
Product Version3.2.0 
Summary0037377: Error in numerical constants with {$IEEEERRORS ON}
DescriptionIn the following unit all the declared constants are within range of double type.;
However there is a range chekh error at declaration of t64.
This error takes place with {$IEEEERRORS ON} and doesn't take place with {$IEEEERRORS OFF}

{$IEEEERRORS ON}
{$apptype console}
Program TestNumbers;

Const
  t1 = 2.0;
  t2 = t1*t1;
  t4 = t2*t2;
  t8 = t4*t4;
  t16 = t8*t8;
  t32 = t16*t16;
  t64 = t32*t32; (* Here is the error: range check error while evaluating constants *)
  t128 = t64*t64;
  t256 = t128*t128;
  t512 = t256*t256;

Var
  x:double;

Begin
  x:=t512;
  writeln(x);
End.
TagsNo tags attached.
Fixed in Revision
FPCOldBugId
FPCTarget
Attached Files

Activities

GameHunter

2020-07-17 04:26

reporter  

Numbers.rar (3,682 bytes)

Issue History

Date Modified Username Field Change
2020-07-17 04:26 GameHunter New Issue
2020-07-17 04:26 GameHunter File Added: Numbers.rar