From: Peter Stephenson <p.w.stephenson@ntlworld.com>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: Defining function based on alias
Date: Sun, 8 Jan 2017 20:23:45 +0000 [thread overview]
Message-ID: <20170108202345.7e8f052c@ntlworld.com> (raw)
In-Reply-To: <170108121454.ZM10678@torch.brasslantern.com>
On Sun, 8 Jan 2017 12:14:54 -0800
Bart Schaefer <schaefer@brasslantern.com> wrote:
> On Jan 8, 7:19pm, Peter Stephenson wrote:
> } Subject: Re: Defining function based on alias
> }
> } I am about to commit the following, which I hope will hope will stop
> } people coming to grief with this common confusion. Please say if you
> } see any problems.
>
> No problems, but -- if it's possible to detect this situation, why not
> simply suppress the alias expansion and define the function as named,
> rather than trigger an error?
It's too late; we'd have to wind back to where the alias was read and
read eveything in again, which is quite contorted, and not actually
guaranteed to fix things if it's a tortuous alias. Possibly an even better
argument is that this silently changes the syntax, which is usually a
bad idea.
> I never remember how to rebuild FAQ from FAQ.yo ... can someone check
> my yodl syntax?
It seems OK but you just run "make" in Etc.
pws
next prev parent reply other threads:[~2017-01-08 20:23 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-07 22:16 Peter Stephenson
2017-01-08 19:19 ` Peter Stephenson
2017-01-08 20:14 ` Bart Schaefer
2017-01-08 20:23 ` Peter Stephenson [this message]
2017-01-09 0:09 ` Bart Schaefer
2017-01-09 4:02 ` Daniel Shahaf
2017-01-09 10:33 ` Peter Stephenson
2017-01-09 1:55 ` Daniel Shahaf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170108202345.7e8f052c@ntlworld.com \
--to=p.w.stephenson@ntlworld.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).