anchor.diff:  {$OVERFLOWCHECKS OFF}
   
   uses
  -  Velthuis.ExactFloatStrings, Velthuis.FloatUtils;
  +  Velthuis.ExactFloatStrings, Velthuis.FloatUtils, Velthuis.Numerics;
   
   resourcestring
     SErrorBigDecimalParsing = '''%s'' is not valid BigDecimal value.';
  
positive.code:   FScale := Scale;
  end;
  
  // TODO: The following float conversions simply convert the float to a string and then use that to
  // initialize the BigDecimal. This works fine, but can perhaps be cut short a little, since
  // ExactString internally already converts the single to a BigInteger and a scale.
  
  constructor BigDecimal.Create(const S: Single);
  var
    Str: string;
  begin
    Str := Velthuis.ExactFloatStrings.ExactString(S);
    CheckInvalidFloatString(Str, 'Single'); // DO NOT TRANSLATE
    Create(Str);
  end;
  
  constructor BigDecimal.Create(const D: Double);
  var
    Str: string;
  begin
    Str := Velthuis.ExactFloatStrings.ExactString(D);
    CheckInvalidFloatString(Str, 'Double'); // DO NOT TRANSLATE
    Create(Str);
  end;
  
  {$IFDEF HasExtended}
  constructor BigDecimal.Create(const E: Extended);
  var
    Str: string;
  begin
    Str := Velthuis.ExactFloatStrings.ExactString(E);
    CheckInvalidFloatString(Str, 'Extended'); // DO NOT TRANSLATE
    Create(Str);
  end;
  {$ENDIF}
  
  
negative.code: 
    Value.FScale := LNumDecimals;
    Value.FValue := BigInteger(LIntValue);
    if not Value.FValue.IsZero and LIsNegative then
      Value.FValue.SetSign(-1);
    Result := True;
  end;
  