Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: Re: Useful addition to Perl?

by etcshadow (Priest)
on Mar 05, 2004 at 20:41 UTC ( #334360=note: print w/replies, xml ) Need Help??

in reply to Re: Useful addition to Perl?
in thread Useful addition to Perl?

Big ++.

I obviously agree very much. In fact, some of this stuff (like avoiding exploding @ARGV) are in my discussions of (in this thread and in its own thread, elsewhere). The nice thing about the way that -n or -p are actually processed (which is with while (<>) { ... }) is that they actually shift @ARGV. Thus, by tieing @ARGV and only exploding directory contents as they are fetched, you can do a highly efficient "perl -mr -ne ...".

I'm also a big fan of the glob thing... I even considered doing that automatically in, if $^0 =~ /MSWin32/. I decided, though, to fight one battle at a time.

Last of all, I totally love the idea of treating otherwise unrecognized switches as uses. ...Well, love the idea of it, and the cuteness... but of course, you run out of switches *real* fast, and actually, they're mostly already used up. Of course, if you want to get more into the perlrun mindset that gives us the -s option to perl, perhaps we would only activate this behavior with another special switch... or maybe a switch that leads a group of "external" switch modules... -X seems to be available. That would give you something like

perl -Xrg -ple '...' *
as a shorthand for
perl -Mr -Mg -ple '...' *
But, anyway... now I feel that I have clearly strayed off into hyperspace =D
------------ :Wq Not an editor command: Wq

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://334360]
[Your Mother]: The US government does not attract talent, but grafters and liars and it has been that way for the better part of a century. FEW exceptions.
[erix]: you think it only /looks/ worse this time?
[Your Mother]: HR Clinton was literally threatening Russia. She would have been MUCH more likely to start real trouble.
[Your Mother]: I think there is less decorum this time.
[Your Mother]: We’ve had rapists and thieves and unqualified government. They just had decorum.
[erix]: heh, understatement of the week :)
[erix]: well, I hope you're right
[Your Mother]: Bill Clinton assaulted and raped repeatedly. Even when it was hinted and finally all but proved, no one cared because his sexism, and racism, and killing was decorous.
[Your Mother]: I think Trump might be better specifically because no one respects him so he won't get his way the way the others did.
[Your Mother]: (I certainly did not vote for him and have been an outspoken critic of his for three decades, by the by.)

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (8)
As of 2017-01-20 01:01 GMT
Find Nodes?
    Voting Booth?
    Do you watch meteor showers?

    Results (173 votes). Check out past polls.