1. defining variables ??
I have noticed that declaring a variables OUTSIDE of a procedure or
function, I can do this:
atom var1, var2
var1 = 1
var2 = 2
atom var3
var3 = 3
Declaring this same thing inside a procedure or function will cause an
error because of the intermixing of variable names and assigning of the
variables value
procedure rout1( )
atom var1, var2
var1 = 1
var2 = 2
atom var3
var3 = 3
end procedure
Why doesn't this work the same way inside a procedure ?
Bernie
2. Re: defining variables ??
Bernie Ryan writes:
> Why doesn't this work the same way inside a procedure ?
In the manual section 2.4.2 it states:
"Variable declarations inside a subroutine must all appear at the
beginning, before the executable statements of the subroutine."
I just felt it would promote readability if the private variable
declarations had to all appear at the beginning.
Regards,
Rob Craig
Rapid Deployment Software
http://www.RapidEuphoria.com
3. Re: defining variables ??
Thanks Rob
I did not remember reading about that.
Bernie