laziness, impatience, and hubris | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
I hope to ear working solutions but i humbly suspect we'll not.
I also suspect that this file handle is bring to existence only when logical end of the file is different from the physical one (as you have read in Special Literals) and this is due to the special token __DATA__
If no token is found (i suspect) that anyone that was reading the code close the file before any possible existence of a Perl filehandle. Infact DATA is not available during a BEGIN block, obviously. Also the fact that $. starts just after the token, with the value of 1 make me suspicious. I've still waiting for that trick solution.. but some test is still interesting (oneliners acts like plain file here):
About the fool idea of opening $0 and just for curiosity, was my 7th post here. L*
There are no rules, there are no thumbs.. Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS. In reply to Re: Introsepcting the current Perl file via DATA, even w/o DATA?
by Discipulus
|
|