in reply to use strict and exporting package variables
That's important, because it's how you locate variables inside a package. (Variables declared with my or localized are bound to a particular lexical scope -- they don't live in the symbol table. I'm simplifying things here by ignoring what happens when you localize a variable in the symbol table.)
The upshot of it is, import works by creating an alias in the current package's symbol table to point to a thingie in another package's symbol table.
Since lexical variables don't live in a symbol table, that doesn't work.
The important thing to remember is that namespaces use symbol tables, which are not the same thing as lexical scopes. I can get away with this jargon because you mention the Camel. :)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
(bbfu) (just to confuse the issue) Re(2): use strict and exporting package variables
by bbfu (Curate) on May 01, 2001 at 07:42 UTC | |
by tye (Sage) on May 01, 2001 at 09:39 UTC | |
by bbfu (Curate) on May 01, 2001 at 10:30 UTC |