[fpc-pascal] Type of file mode variable

Jürgen Hestermann juergen.hestermann at gmx.de
Thu Mar 17 19:07:01 CET 2011


In the file \lazarus\fpc\2.4.3\source\rtl\inc\systemh.inc I found the 
following definitions:

{ file input modes }
  fmClosed = $D7B0;
  fmInput  = $D7B1;
  fmOutput = $D7B2;
  fmInOut  = $D7B3;
  fmAppend = $D7B4;
  Filemode : byte = 2;

If I assign "Filemode := fmInOut" I get a constant range check error (at 
compilation time) which is clear because all constants are larger than 
byte.
Is this a bug?



More information about the fpc-pascal mailing list