lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


I figured it's been long enough around here without me saying something
stupid, so...

I'm fooling around with a sort of module system (using some code posted to
the list by Roberto) and I noticed that if you define a variable outside of
a function as local, then any global function that references it is
implicitly local as well. This makes sense, but I was more expecting
something like an error message or for the function to try and access a
global. I checked the manual but I didn't notice this mentioned anywhere. I
thought I'd mention it in case I'm right and it's not mentioned in the
manual, so that it could perhaps be added to a future version. Of course,
it's probably there and I just missed it...