Re: Parsing regression with for loop in case statement

2024-04-13 Thread Chet Ramey
On 4/10/24 8:51 PM, nbow...@draconx.ca wrote: Bash Version: 5.2 Patch Level: 21 Release Status: release Description: The POSIX shell grammar specifies that a newline may optionally appear before the in keyword of a for loop. [...] However, if the exact same loop is placed within the

Re: Parsing regression with for loop in case statement

2024-04-10 Thread Kerin Millar
On Thu, 11 Apr 2024 15:07:14 +1200 Martin D Kealey wrote: > I can confirm that this changed between 4.4.23(49)-release and > 5.0.0(1)-beta, which coincides with the parser being largely rewritten. > > On Thu, 11 Apr 2024 at 12:51, wrote: > > > The POSIX shell grammar specifies that a newline m

Re: Parsing regression with for loop in case statement

2024-04-10 Thread Lawrence Velázquez
On Wed, Apr 10, 2024, at 11:07 PM, Martin D Kealey wrote: > But ... oh look, it's mentioned in §2.10.2 ( > https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_10_02 > ). > > I wonder when that was added, and why? It's been there since at least POSIX.2-1992 [1]. At a g

Re: Parsing regression with for loop in case statement

2024-04-10 Thread Martin D Kealey
I can confirm that this changed between 4.4.23(49)-release and 5.0.0(1)-beta, which coincides with the parser being largely rewritten. On Thu, 11 Apr 2024 at 12:51, wrote: > The POSIX shell grammar specifies that a newline may optionally appear > before the in keyword of a for loop. I don't se