Syntactic Confectionery Delight | |
PerlMonks |
Code asks, in what file do I live?by water (Deacon) |
on Sep 23, 2004 at 17:44 UTC ( [id://393282]=perlquestion: print w/replies, xml ) | Need Help?? |
water has asked for the wisdom of the Perl Monks concerning the following question:
How can a snippet of running code determine which file it came from (assuming it wasn't built on the fly)? I know $0 gives you the program, and __PACKAGE__ gives you the package, but how does one get to the filename? Thanks!
Back to
Seekers of Perl Wisdom
|
|