Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [bug] sh: tilde expansion after field splitting

On Sun, 8 Oct 2017 13:45:14 -0700
Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> } > - There either isn't a Test/ for the keyvalpairelement() case in the
> } >   first hunk below, or it isn't rigorous enough, because I initially
> } >   forgot the incnode(node) in that hunk, yet the shell did *not* go
> } >   into an infinite loop during "make check", nor did any test
> } >   fail
> } 
> } That doesn't make sense.
> I don't know what to tell you; I just now commented it back out and tried
> again, and it still works.  I suspect what's happening is that after the
> first call to keyvalpairelement() node = insnode is done, and then we
> continue around the loop and call keyvalpairelement() a second time on
> the same node, at which point it fails and we fall through the rest of
> the loop and hit the incnode() at the end, which fixes things.

Yes, that's it --- the key / value pair is turned into a Marker, key,
value list triad, and furthermore the key and value are untokenised as
no more substitution is wanted.  So it'll just go striaght through.
This doesn't indicate a problem.


Messages sorted by: Reverse Date, Date, Thread, Author