[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: IFS field splitting doesn't conform with POSIX
From: |
Andreas Schwab |
Subject: |
Re: IFS field splitting doesn't conform with POSIX |
Date: |
Thu, 30 Mar 2023 21:48:57 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
On Mär 30 2023, Felipe Contreras wrote:
> On Thu, Mar 30, 2023 at 10:10 AM Oğuz İsmail Uysal
> <oguzismailuysal@gmail.com> wrote:
>>
>> On 3/30/23 2:12 PM, Felipe Contreras wrote:
>> > IFS=,
>> > str='foo,bar,,roo,'
>> > printf '"%s"\n' $str
>> zsh is the only shell that generates an empty last field, no other shell
>> exhibits this behavior.
>
> So? This is argumentum ad populum. The fact that most shells do X
> doesn't imply that POSIX says X.
>
> It could very well mean that all shells are implementing POSIX wrong.
> Except zsh.
Note that zsh by default is not a POSIX shell, and even in sh
compatibilty mode it doesn't strive to be POSIX compliant.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1
"And now for something completely different."
- Re: IFS field splitting doesn't conform with POSIX, (continued)
- Re: IFS field splitting doesn't conform with POSIX, Oğuz İsmail Uysal, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Felipe Contreras, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Andreas Kusalananda Kähäri, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Oğuz İsmail Uysal, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Felipe Contreras, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Lawrence Velázquez, 2023/03/30
- Re: IFS field splitting doesn't conform with POSIX, Chet Ramey, 2023/03/31
- Re: IFS field splitting doesn't conform with POSIX,
Andreas Schwab <=
- Re: IFS field splitting doesn't conform with POSIX, Chet Ramey, 2023/03/31
- Re: IFS field splitting doesn't conform with POSIX, Chet Ramey, 2023/03/31
- IFS field splitting doesn't conform with POSIX, Felipe Contreras, 2023/03/30