Perl: the Markov chain saw | |
PerlMonks |
Re: Intercepting IO file accessby blahblahblah (Priest) |
on Jul 28, 2007 at 02:53 UTC ( [id://629242]=note: print w/replies, xml ) | Need Help?? |
I've never tried the ex::override module mentioned in your update, but I can point you to a similar thing I did a while ago using the subs pragma. After a few rounds of improvements from the great folks here, it worked pretty well. There were a couple of subtle things about open's behavior that I missed initially:
Re: anonymous filehandle for overridden open sub helped me get it right for undefined lexical filehandles Re: Re: use subs enlightened me somewhat on the difference between lists and arrays, or why I couldn't just pass @_ on to the CORE::open function. I wouldn't at all be surprised if there are more bugs in my open sub, but my program's use of open is limited to some very simple cases and my sub seems to handle them well enough. Joe
In Section
Seekers of Perl Wisdom
|
|