On 18-9-2011 13:41, Sven Barth wrote: > On 18.09.2011 13:29, Reinier Olislagers wrote: >> What am I doing wrong? > > Additionally to what Marco wrote: > > You must not use the "$" as prefix for the "variable" if you reference > such a compiler define inside an $if or $ifdef. > > Regards, > Sven
Thanks guys - reading manuals is not always my strong point ;) This works: program conditional; {$mode objfpc}{$H+} begin {$IF FPC_FULLVERSION > 20200} //apparently FPC_FULLVERSION was introduced //in FPC 2.2.4 though... //http://delphi.wikia.com/wiki/FreePascal_detection_and_versioning writeln('Version newer than 2.2'); {$ENDIF} end. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal