From: Bart Schaefer <schaefer@brasslantern.com>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: [PATCH 3/3] Documentation for named references
Date: Mon, 6 Feb 2023 19:25:03 -0800 [thread overview]
Message-ID: <CAH+w=7YAvAVOiUzj_tyc=Amgs1N0S50FrrBHsuVWiO10Q3cY+A@mail.gmail.com> (raw)
In-Reply-To: <20230207005647.GA5789@tarpaulin.shahaf.local2>
On Mon, Feb 6, 2023 at 4:57 PM Daniel Shahaf <d.s@daniel.shahaf.name> wrote:
>
> Bart Schaefer wrote on Sun, Feb 05, 2023 at 18:26:50 -0800:
> > +tt(-n). The var(name) assigned-to may not be an array element nor use
>
> s/assigned-to/assigned to/
I did that on purpose to remove any ambiguity about what object "to" acts upon.
I've used s/assigned-to/so created/
> "incuding"
Thanks.
> > +the type information of var(rname), unless var(rname) is empty, in which
> > +case `tt(nameref)' is expanded, or when no variable var(rname) exists,
>
> "in which case the expansion is `tt(nameref)'"?
Better, thank you.
> > +When both a named reference and the `tt((P))' flag appear, the named
> > +reference is resolved before `tt((P))' is applied.
>
> Add a test for this last sentence?
I can't think of a way to do so. Given ${(P)ptr}, there are two possibilities:
1) ptr is a scalar, in which case we're not testing the right thing
2) ptr is a reference, so any other order of expansion is meaningless
If ptr is a reference, a working test of ${ptr} implies that ${(P)ptr}
also works. I almost didn't include that sentence in the doc at all,
but I found the nameref sections of "man ksh93" to be so nearly
unreadable that I went as far as I could in the other direction. (The
sections on discipline functions are even worse, even the author of
the O'Reilly ksh book basically gives up on the topic.)
> WDYT of documenting somewhere in the manual namerefs are new in 5.10?
I was going to add something to NEWS and README eventually ... also, I
wasn't sure we'd landed on a version number yet. I suppose (once we
do) a mention wouldn't hurt since the docs are likely to end up on
line.
> > +em(This is a misfeature.)
>
> Does "This is a misfeature" mean "This may change in the future to be
> compatible with ksh93"?
Oops, I was supposed to delete that whole paragraph, I already fixed
that with the base/width overloading.
> > texinode(Parameters Set By The Shell)(Parameters Used By The Shell)(Local Parameters)(Parameters)
> > sect(Parameters Set By The Shell)
>
> s/Local Parameters/Named References/
Thanks, thought I'd caught all of those ... it was nice when the older
version of yodl complained about those incorrect references.
> (public service announcement: we have *.yo syntax highlighting for Vim
> in our tree)
I have a yodl-mode.el file for emacs floating around somewhere too,
tho it hasn't been updated since about GNU emacs 12.
next prev parent reply other threads:[~2023-02-07 3:26 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-06 2:26 Bart Schaefer
2023-02-07 0:56 ` Daniel Shahaf
2023-02-07 3:25 ` Bart Schaefer [this message]
2023-02-07 10:51 ` Daniel Shahaf
2023-02-07 16:53 ` Bart Schaefer
2023-02-08 21:28 ` Bart Schaefer
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='CAH+w=7YAvAVOiUzj_tyc=Amgs1N0S50FrrBHsuVWiO10Q3cY+A@mail.gmail.com' \
--to=schaefer@brasslantern.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).