Added !if S==, S!=, = and <> compare ops and hex/int/float parsing support

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@6198 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
anders_k 2011-12-06 19:14:45 +00:00
parent 357aa9675b
commit 67d0b165b1
5 changed files with 44 additions and 18 deletions

View file

@ -64,10 +64,10 @@ The opposite of !ifdef. The lines will be compiled when the gflag has not been d
\c [!] /FileExists "c:\path\file.exe"
This command, when paired with an !endif command, will tell the compiler whether or not to compile the lines in between the two lines. If value is non-zero, or the comparison of value and value2 depending on the operator results in true, the contained lines will be compiled. Otherwise, they will be skipped.
op can be either == or != (string comparison), <=, < > or >= (float comparison), & (bitwise AND comparison), && or || (boolean comparison).
op can be either == or != (case-insensitive string comparison), S== or S!= (case-sensitive string comparison), =, <>, <=, <, > or >= (int/hex/float comparison), & (bitwise AND comparison), && or || (boolean comparison).
If [!] is set, return value will be switched from true to false and vice versa.
\c !if 1 < 2
\c !if 1 < 0x2
\c !echo "1 is smaller than 2!!"
\c !else if ! 3.1 > 1.99
\c !error "this line should never appear"