On Fri, Aug 24, 2001 at 12:23:17PM -0700, Curtis Poe wrote:
> --- [EMAIL PROTECTED] wrote:
> This is such a common problem that "use strict 'system'" is being
> considered for Perl 6.
Hm, I don't remember any discussion on that one, but perhaps I missed
something.
Regardless, you don't need to wait until Perl 6 for similar functionality.
Perl has as standard, since at least Perl 5.005, the Fatal module.
use Fatal qw(:void open);
open(FILE, ">/etc/passwd");
*KABOOM*
Or, you can use it to do your checking for you (the above only does a check
if open is called in void context):
use Fatal qw(open);
open(FILE, ">/etc/passwd");
*KABOOM*
Granted, it's not as simple as use strict 'system', but you can pretty
easily write a pragma or module to effectively do that for you. You could
even patch strict.pm to do it, just don't expect it to get adopted into core
(strict's stricture are frozen, AFAIK).
Michael
--
Administrator www.shoebox.net
Programmer, System Administrator www.gallanttech.com
--
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]