Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight

Re: Re^5: Macros, LFSPs and LFMs

by demerphq (Chancellor)
on Jun 15, 2003 at 14:20 UTC ( #266031=note: print w/replies, xml ) Need Help??

in reply to Re^5: Macros, LFSPs and LFMs
in thread Macros, LFSPs and LFMs

I can see your point here. Ive done things like this

sub assert{ my ($stmt,@args)=@_; my $ok=eval"$stmt" or die "Failed to eval assertion '$stmt':$@"; unless ($ok) { no warnings; my $str=eval qq("$stmt") or die "Failed to eval assertion '$stmt' as a string:$@"; die "Failed assertion '$str'\n"; } }

which works reasonably well, but obviously isn't as satisfactory as your approach, and could even be a security risk as presently written if it were run on untrustworthy data.

Anyway, Itll be nice though when the new stuff is out at a production grade. I look forward to it. :-)


<Elian> And I do take a kind of perverse pleasure in having an OO assembly language...

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://266031]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2017-02-25 03:33 GMT
Find Nodes?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?

    Results (365 votes). Check out past polls.