in reply to where to use "use" and package
Any time you're in a file and haven't declared the namespace with package, the namespace defaults to main. After your package declaration, you're in the Mods::Debug namespace.
So by putting the use's after the package declaration, you import them into the Mods::Debug namespace instead of main. This is the right way to do it.
elusion : http://matt.diephouse.com
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: where to use "use" and package
by Abigail-II (Bishop) on Aug 01, 2002 at 09:29 UTC | |
|
Re: Re: where to use "use" and package
by smackdab (Pilgrim) on Aug 01, 2002 at 05:20 UTC | |
by hossman (Prior) on Aug 01, 2002 at 07:08 UTC |