[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Antwort: global keyword instead of local
- From: Martin_Doering@...
- Date: Mon, 28 Aug 2000 10:25:51 +0200
>How hard would it be to modify Lua source code
>to add "global" keyword for explicit declaration
>of global variables and make all variables local
>by default?
This is one thing I never understood. Why is it implemented that way - in
all other programming languages (that I know) variables in
subroutines/functions are automatically local. Is there a reason, why it
is implemented the other way round?
--------------------------------------------------------------------------------------------------------
Martin Döring, Systemtechnik (IDT)
MAN Nutzfahrzeuge AG
Dachauerstraße 667
D-80995 München
Tel.: +49(0)89 / 1580 - 1199
Fax: +49(0)89 / 1580 - 91-1199
E-Mail: Martin_Doering@mn.man.de