|
Tech GURU
Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Sat Oct 21, 2006 7:55 pm
[1.11] Problems with named parameters |
I've got a weird alias bug here.
Code: |
#VAR StepResult 50 0 {Money}
#LOCAL $Temp1 $ResultStr
#echo $Divisor $Dividend
$Temp1=$Divisor/$Dividend
#VAR Remainder %mod( $Divisor, $Dividend)
#show $Temp1 |
Outputs the correct value as expected but this
Code: |
#VAR StepResult 50 0 {Money}
#LOCAL $Temp1 $ResultStr
$Temp1=$Divisor/$Dividend
#VAR Remainder %mod( $Divisor, $Dividend)
#show $Temp1 |
Outputs 0.
It was called using conv_step 300 47 Mark
[Edit] My work around to avoid issuing #GAG is to replace the #ECHO with #CALL. |
|
_________________ Asati di tempari! |
|
|
|
Zugg MASTER
Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Mon Oct 23, 2006 7:29 pm |
I assume $Divisor and $Dividend are the named alias arguments?
I verified the problem. It was interesting that if I remove the line
#LOCAL $Temp1 $ResultStr
then it works. Since $Temp1 is defined by the assignment on the next line, the #LOCAL line wasn't needed. But it looks like #LOCAL is somehow messing up the named arguments, so I'll look into this. Thanks for the report. |
|
|
|
|
|