Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^6: Introsepcting the current Perl file via DATA, even w/o DATA? (perl5db.pl)

by Mr. Muskrat (Canon)
on Feb 05, 2016 at 16:37 UTC ( #1154489=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    # main.pl
    my @source = @{ $main::{ '_<' . __FILE__ } };
    shift @source; # get rid of sub DB::DB{};
    print for @source;
    
  2. or download this
    PERL5DB="sub DB::DB{}" perl -d main.pl
    
  3. or download this
    my @source = @{ $main::{ '_<' . __FILE__ } };
    shift @source; # get rid of sub DB::DB{};
    print for @source;
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (2)
As of 2022-07-06 10:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?