mIRC Homepage
Posted By: praetorian_ $+ and $iif - 26/03/03 09:45 PM
i believe i have found a bug in $+ when an $iif statement is preceded by a null variable. example (make sure %test is unset or choose a different variable name):

Code:
//echo -a $+(%test,$iif(testing,test))


echos '$nulltest'. it doesnt matter how many parameters you pass to $+, nor does the position of the null variable\$iif combo in the list (i.e. $+(one,two,three,%var,$iif) breaks, as does $+(one,%test,two,$iif)).

one could argue that this is working correctly because %test is actually $null, but this is not true because the same statement switched around (or even with the $iif removed) excludes the $null.

i reproduced this bug on both mIRC 6.3 and 5.91
Posted By: qwerty Re: $+ and $iif - 26/03/03 10:46 PM
It's definitely a bug. Looks like mirc never got over the $null-considered-a-literal-string problem completely...

Btw, $+() has other quirks too, like //echo -s $+($+,a)
Posted By: Ic3flamez Re: $+ and $iif - 05/06/03 03:00 AM
$+(",blah",)
blah.. why am i even bothering to answer this?
© mIRC Discussion Forums