Author Topic: Two small bugs  (Read 1859 times)

Offline davem

  • Imaging User
  • *
  • Posts: 20
    • View Profile
Two small bugs
« on: 1 November 2011, 11:09:25 »
  Hi,
  I have just installed the latest working version and found two small issues on delphi 2009 / Win 7 (they raise errors during compilation):

ImagingUtility.pas ([DCC Error] ImagingUtility.pas(1529): E2003 Undeclared identifier: 'Result')
Code: Delphi
  1. {$IF Defined(DELPHI)}
  2.   {$IF CompilerVersion >= 23}
  3.   FloatFormatSettings := TFormatSettings.Create('en-US');
  4.   {$ELSE}
  5.   // FloatFormatSettings := GetLocaleFormatSettings(1033, Result);  // 1.11.2011
  6.    GetLocaleFormatSettings(1033, FloatFormatSettings);
  7.   {$IFEND}
  8. {$ELSE FPC}
  9.   FloatFormatSettings := DefaultFormatSettings;
  10.   FloatFormatSettings.DecimalSeparator := '.';
  11. {$IFEND}
  12.  

ImagingRadiance.pas ([DCC Error] ImagingRadiance.pas(359): E2033 Types of actual and formal var parameters must be identical)
Code: Delphi
  1.   procedure EncodeRgbe(const Src: TColor96FPRec; var Dest: TRgbe); {$IFDEF USE_INLINE}inline;{$ENDIF}
  2.   var
  3.     V, M: Extended; // {$IFDEF FPC}Float{$ELSE}Single{$ENDIF}; // 1.11.2011
  4. ..
  5.       Frexp(V, M, E);     // 1.11.2011, here it used to report the error for M variable (
  6.  

In both cases I did a correction, hopefully they are fine (see my comment 1.11.2011)

Apart from that I also get this warning: [DCC Hint] ImagingRadiance.pas(366): H2445 Inline function 'ClampToByte' has not been expanded because its unit 'ImagingUtility' is specified in USES statement of IMPLEMENTATION section and current function is inline function or being inline function


Offline Galfar

  • Administrator
  • Imaging User
  • *****
  • Posts: 369
    • View Profile
    • Galfar's Homepage
Re: Two small bugs
« Reply #1 on: 1 November 2011, 23:50:04 »
Thanks for the report, working versions are not always tested in all Delphi versions :(
I'll update the repository with a fix in a short while.