What nonsense. I want to parse source code. ')' is not an uncommon line of
source code. It should work.

On Wed, 29 Dec 2021 at 19:52, Paul Eggert <egg...@cs.ucla.edu> wrote:

> On 12/29/21 08:31, Davide Brini wrote:
> > I think you need to use '+' before the offending token
>
> Yes. That's a GNU extension. If you want to be portable to any POSIX
> implementation, you can use this instead:
>
> expr "X(" : '.*' - 1
>
> A similar example is given in the POSIX spec for 'expr':
>
> https://pubs.opengroup.org/onlinepubs/9699919799/utilities/expr.html
>
> As this is not a bug, I'm closing the bug report.
>

Reply via email to