Integer version check ability
Original Reporter info from Mantis: marco @marcoonthegit
-
Reporter name: Marco van de Voort
Original Reporter info from Mantis: marco @marcoonthegit
- Reporter name: Marco van de Voort
Description:
Complex version checking is cumbersome. To futureproof check if something is 2.0.1 or above I have to do: (from the docs actually)
{$IF (FPC_VERSION > 2) or
((FPC_VERSION = 2)
and ((FPC_RELEASE > 0) or
((FPC_RELEASE = 0) and (FPC_PATCH >= 1))))}
{$DEFINE FPC_VER_201_PLUS}
{$ENDIF}
Can we please have some easier way for this often used construct?
Can we compare with an integer, or even dotted version?
Mantis conversion info:
- Mantis ID: 11568
- Fixed in version: 2.2.4
- Fixed in revision: 460 (#01a7a755).