Hi I 'm about to file a bug report and would like to have a confirmation. The compiler conplains( see the code below ) : "Fatal: Syntax error, ")" expected but "(" found" It compiles under Delphi ( D7 ). I tried with "mode delphi" and "mode objfpc" and still got the same syntax error ( WinXP fpc 2.2.1 19/11/2007 ).
Please can you confirm this bug. Thanks. <code> program test_syntax; {$IFNDEF FPC} {$APPTYPE CONSOLE} {$ENDIF} {$IFDEF FPC} {$mode objfpc}{$H+} {$ENDIF} type {$IFNDEF FPC} PPtrInt = ^Integer; {$ENDIF} PRecA = ^TRecA; TRecA = record _data : array[0..0] of Byte; end; TTestObj = class function Append() : PRecA; end; function TTestObj.Append() : PRecA; begin Result := nil; end; var ox : TTestObj; begin ox := TTestObj.Create(); PPtrInt(@((ox.Append()^._data[0])))^ := 0; //this one compiles PPtrInt(@(ox.Append()^._data[0]))^ := 0; // error on this line : "Fatal: Syntax error, ")" expected but "(" found" end. </code> -- Inoussa O. _______________________________________________ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel