2009/7/20 Peter Stephenson <p...@csr.com>: > On Sun, 19 Jul 2009 23:20:41 +0000 > Clint Adams <sch...@debian.org> wrote: >> On Sun, Jul 19, 2009 at 07:16:51PM +0200, martin f krafft wrote: >> > % eval 'lt() { (_lt-en $*; _en-lt $*) | more }' >> > zsh: parse error near `()' >> > >> > Alright, so lt is special: >> > >> > % which lt >> > lt: aliased to ls -lt > > Assuming lt was defined as an alias first, this has always been the wrong > thing to do: > > % alias lt="one two" > % eval 'lt() { (_lt-en $*; _en-lt $*) | more }' > % which one two > one () { > ( > _lt-en $* > _en-lt $* > ) | more > } > two () { > ( > _lt-en $* > _en-lt $* > ) | more > } > > This is not a new feature; it's been mentioned in the FAQ for many years.
Just thought I'd mention you can also use \ at any time to escape an alias: % alias lt="one two" % eval '\lt() { echo foo }' % which lt lt: aliased to one two % unalias lt % which lt lt () { echo foo } % alias lt="one two" % which lt lt: aliased to one two % lt zsh: command not found: one % \lt foo % l\t foo -- Mikael Magnusson -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org