Phil R has fixed the LFC sources so that there are no longer any
'Assignment to free variable' warnings (e.g.:
[java] Warning: Assignment to free variable canvas in views/
LaszloCanvas.lzs (146)
[java] Warning: Assignment to free variable LzMonitor in
debugger/LzMonitor.lzs (17)
If you get a warning compiling the LFC from now on, you need to
understand why you are getting the warning, and decide whether it is
legitimate or not. This will help us catch erroneous code, such as
for loops that do not declare their iteration variable or functions
that do not declare local variables. If you actually _do_ intend to
set a global variable, there are two ways to silence the warning. If
you are defining a global variable, you should use a `var` declaration:
var LzMonitor = ...;
If you actually mean to set a global variable (say in the body of a
function) you should prefix it by `global.`:
global.canvas = ...;
It's important not to let spurious warnings creep in. We missed
several errors in our conversion to new classes because the compiler
warnings were buried in noise that we had been conditioned to ignore.
Thanks for your help! (And thanks Phil for getting us to this clean
state!)
_______________________________________________
Laszlo-dev mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-dev