I ran into another problem scenario, dealing with $include'd files. Given these two files:
==iputils.pas======================================================== unit iputils; {$mode objfpc}{$H+} interface {$define IPv6_Types} {$include ip.inc} {$undef IPv6_Types} {$define IPv6_Interface} {$include ip.inc} {$undef IPv6_Interface} implementation {$define IPv6_Implementation} {$include ip.inc} {$undef IPv6_Implementation} end. ===================================================================== ==ip.inc============================================================= {$IFDEF IPv6_Types} type IPv6Addr = array[0..15] of byte; type IPv4Addr = longword; {$ENDIF} {$IFDEF IPv6_Interface} function IsIPv4CompatibleIPv6Addr(const ipv6 : IPv6Addr) : boolean; {$ENDIF} {$IFDEF IPv6_Implementation} function IsIPv4CompatibleIPv6Addr(const ipv6 : IPv6Addr) : boolean; begin result := false; end; {$ENDIF} ===================================================================== I get an error like this: Syntax error at token "EOF" in file iputils.pas at line 21 column -7202378 line:21 column:-7202378 file:iputils.pas An unhandled exception occurred at $000000000046FCA1 : EParserError : Syntax error at token "EOF" in file iputils.pas at line 21 column -7202378 $000000000046FCA1 $0000000000475C0C $0000000000474C83 $0000000000474C3B $0000000000474396 $00000000004091A4 line 1913 of test_parser.pp Thanks, -SG -- This email is fiction. Any resemblance to actual events or persons living or dead is purely coincidental. Seth Grover _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal