Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: 'require/use' scoping

by brian_d_foy (Abbot)
on Jan 29, 2008 at 15:26 UTC ( #664910=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use Foo;
    
    ...
        require Foo;
        Foo->import;
        }
    
  2. or download this
    use MODULE qw(import list);
    
    ...
        require MODULE;
        MODULE->import(import list);
        }
    
  3. or download this
    use MODULE ();
    
    BEGIN {
        require MODULE;
        }
    
  4. or download this
    require "lib/Foo.pm"; # no @INC searching!
    
  5. or download this
    sub require {
      my ($filename) = @_;
    ...
          return $result;
      }
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://664910]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (7)
As of 2014-12-25 21:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (163 votes), past polls