Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: package and do

by ikegami (Patriarch)
on Feb 03, 2006 at 04:52 UTC ( [id://527535]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $pkg = 'Foo';
    my $foo = do { local $/; eval "<${pkg}::DATA>" };
    
  2. or download this
    my $pkg     = 'Foo';
    my $data_fh = do { no strict 'refs'; *{"${pkg}::DATA"} };
    my $foo     = do { local $/; <$data_fh> };
    
  3. or download this
    my $pkg = 'Foo';
    my $data_fh; { no strict 'refs'; $data_fh = *{"${pkg}::DATA"}; }
    my $foo;     { local $/; $foo = <$data_fh>; }
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2024-04-26 01:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found