tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: sh(1) vs. ksh(1)



> The quoting semantics of `` and $() are different.  You should never
> use `` because they also don't nest.

That's funny.  I've used nested backquotes moderately often, and, while
they don't work in csh, I've never had any trouble in sh.

You need to backslash the inner backquotes, of course, but that's no
different from double-quote quoting; any shell programmer good enough
to be able to design a working command using nested backquotes surely
should be able to handle backslashes.

This is not to say that $( ) isn't better in various ways (relevantly
at the moment, no particular quoting is needed for nesting, because the
open and close delimiters are different).  Just that I think "they
don't nest" is not a fair criticism to level at ` `.

/~\ The ASCII                             Mouse
\ / Ribbon Campaign
 X  Against HTML                mouse%rodents-montreal.org@localhost
/ \ Email!           7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B


Home | Main Index | Thread Index | Old Index