[Python-3000] Suggestion to replace `global' keyword with `modular' ...

chris at seberino.org chris at seberino.org
Fri Jul 7 03:51:01 CEST 2006


I would like to suggest replacing the 'global' keyword
with a new keyword 'modular'.

Why?  In my limited understanding, 'global' means "in all namespaces"
or "visible everywhere".

Because globals are accessed like this:
    mymodule.myvariable
they are just as "global" as this:
    mymodule.myclass.myclassattribute

In other words, Python does not *really* have true globals
(which is a good thing).

It really has attributes visible at the module level.
Hence, perhaps they should be called "modular".

(If you look up "modular" at dictionary.com you will
see the first definition is exactly what we are trying to say..
'Of, relating to, or based on a module...")

Chris


More information about the Python-3000 mailing list