Front page | perl.perl6.language |
Postings from April 2005
-X's auto-(un)quoting?
Thread Next
From:
Michele Dondi
Date:
April 21, 2005 01:18
Subject:
-X's auto-(un)quoting?
Message ID:
Pine.LNX.4.61.0504210953250.4902@rhum.pcteor1.mi.infn.it
Are the -X functions still going to be there? I definitely hope so!
However, to come to the actual question, it has happened to me to have to
do, in perl5 that is:
perl -lne 's/^"//;s/"$//;print if -e'
or (less often)
perl -lne '$o=$_;s/^"//;s/"$//;print $o if -e'
Ok: no much harm done (to my fingertips). But then, talking about
huffmanization, could a standard adverb be provided for -X's to the effect
of specifying that the passed filename is quoted, say in double (or if
sensible in single) quotes: for I find that to be a common filelist
"format". Ideally, what I'd like to do is
perl -lne 'print if -e :q'
Michele
--
Mary had a little lamb;/Its fleece was green as limes.
And every even number greater than two/Is the sum of two primes.
- Robert Israel in sci.math, "Re: all math problems reduce to linguistics"
Thread Next
-
-X's auto-(un)quoting?
by Michele Dondi