applied patch #1412982 - "!if" - enhanced compile time flow control
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@4526 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
0bcee34186
commit
b1dc917843
5 changed files with 138 additions and 34 deletions
|
@ -51,6 +51,40 @@ d\
|
|||
i\
|
||||
f
|
||||
|
||||
# tests for !if statement
|
||||
!if 'test' == 'test'
|
||||
!if 1 <= 2
|
||||
!if ! 100 < 99.99
|
||||
!if 2.2 > 1.12
|
||||
!if ! 23 >= 37
|
||||
!if 1 && 1
|
||||
!if ! 0 || 0
|
||||
|
||||
# this should be compiled
|
||||
|
||||
!else
|
||||
!error "!if ! 0 || 0 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if 1 && 1 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if ! 23 >= 37 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if 2.2 > 1.12 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if ! 100 < 99.99 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if 1 <= 2 is true!"
|
||||
!endif
|
||||
!else
|
||||
!error "!if 'test' == 'test' is true!"
|
||||
!endif
|
||||
|
||||
|
||||
# this should just give a warning, not an error
|
||||
!include /NONFATAL file_that_doesnt_exist.nsh
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue