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

Re: "${*:offset:length}" and ksh93/bash compatibility



On 10 March 2022 at 12:48 Mikael Magnusson <mikachu@xxxxxxxxx> wrote:
> On 3/10/22, Stephane Chazelas <stephane@xxxxxxxxxxxx> wrote:
> > Should zsh align with bash/ksh there.
> 
> If we do, it would probably look something like this (does not handle
> all cases), unless someone has a better idea...

I think it should change --- the documentation is already clear this is
here to please users of other shells, not native zsh.  Otherwise we end
up with what's (as we say where I come from) neither nowt nor something.

  This  syntax  gives  effects  similar to parameter subscripting in the form
  $name[start,end], but is compatible with other shells; note that both  off‐
  set  and  length  are interpreted differently from the components of a sub‐
  script.

pws




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