Re: Loops and pipes

Bart Schaefer <[email protected]> Sun, 2 Aug 2026 14:55:24 -0700
Newsgroups gmane.comp.shells.zsh.devel
Message-ID <CAH+w=7bgpFxEyCg=Fa4pyBtWcfRPszahKX6hsRXwZTtCadpt3Q@mail.gmail.com>
On Fri, Jul 31, 2026 at 8:57=E2=80=AFPM Bart Schaefer <schaefer@brasslanter=
n.com> wrote:
>
> On Fri, Jul 31, 2026 at 3:12=E2=80=AFPM Mark J. Reed <[email protected]=
> wrote:
> >
> > Bash introduced a feature in 4.4 whereby process substitution places th=
e child process's PID into $!
>
> I would think that's not too hard to do.

This is already available from the zsh/system module as $sysparams[procsubs=
tpid]

Which means if we want the $! variation, we just have to decide where
to assign 'lastpid =3D procsubstpid'

There would still be cases where [[ $! !=3D $sysparams[procsubstpid] ]]
so I wouldn't suggest dropping the latter.