Perl monking (was Menu{Master,Maestro,etc} question(s)

Jay R. Ashworth jra at baylink.com
Mon May 14 13:08:21 PDT 2007


On Mon, May 14, 2007 at 01:09:38PM -0700, Bill Campbell wrote:
> One of the things I really like in perl, that's not in python, is
> the concept of alternative methods of quoting which can make
> things like this much cleaner.
> 
> Single quotes, 'stuf' can be replaced with q(stuf).
> 
> Double auotes, "stuf$variable" by qq(stuf$variable).
> 
> Backticks `somecommand` by qx(somecomand).
> 
> Regular expressions /expression/ by qr(expression).
> 
> This is particularly useful when the stuff you want quoted
> contains the character you need to use for the quotes.

I'd forgotten about these.  Happens they weren't actually the problem,
of course, but...

> Furthermore, the quoted text can be enclosed in parenthesis,
> braces, etc., so that vi(m)'s ``%'' key can be used to find the
> matching delimiter (this is very high on my list of priorities).

Indeed.  Newer Vim's seem to auto-highlight the matches as your cursor
across them, as well; I think this was whatever ships on SuSE 10.2.

Cheers,
-- jra
-- 
Jay R. Ashworth                                                jra at baylink.com
Designer                          Baylink                             RFC 2100
Ashworth & Associates        The Things I Think                        '87 e24
St Petersburg FL USA      http://baylink.pitas.com             +1 727 647 1274


More information about the Filepro-list mailing list