GNU bug report logs - #65470
29.1.50; js-ts-mode: regex pattern can cause incorrect parenthesis matching

Previous Next

Package: emacs;

Reported by: Augustin Chéneau (BTuin) <btuin <at> mailo.com>

Date: Wed, 23 Aug 2023 11:16:01 UTC

Severity: normal

Tags: patch

Found in version 29.1.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #78 received at 65470 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jostein Kjønigsen <jostein <at> secure.kjonigsen.net>
Cc: btuin <at> mailo.com, dmitry <at> gutov.dev, casouri <at> gmail.com, 65470 <at> debbugs.gnu.org,
 theo <at> thornhill.no
Subject: Re: bug#65470: 29.1.50; js-ts-mode: regex pattern can cause incorrect
 parenthesis matching
Date: Thu, 07 Sep 2023 11:59:37 +0300
> From: Jostein Kjønigsen <jostein <at> secure.kjonigsen.net>
> Date: Tue, 5 Sep 2023 21:31:25 +0200
> Cc: Eli Zaretskii <eliz <at> gnu.org>,
>  Yuan Fu <casouri <at> gmail.com>,
>  Theodor Thornhill <theo <at> thornhill.no>,
>  Jostein Kjønigsen <jostein <at> kjonigsen.net>,
>  btuin <at> mailo.com,
>  65470 <at> debbugs.gnu.org
> 
> Sorry for the somewhat slow response on this. Life has been busy for me as well :)
> 
> Based on the infamous “copy, paste & adapt” methodology I’ve come up with a patch for typescript-ts-mode and tsx-ts-mode which seems to work for the simple test case provided above.
> 
> However the patch for js-ts-mode has lots of … interesting stuff about jsx I have not included, for no other reason than not understanding what type of use-cases they are meant to support.
> 
> If someone can provide me some examples for the JSX use-cases, I can try to make room for TSX-variants of the same code.
> 
> The patch so far is attached. It’s intentionally -not- optimized to leave room for TSX cases which may arise, so hopefully no need to nitpick this yet.

Thanks, Jostein.

Any objections to my installing this on the emacs-29 branch, anyone?




This bug report was last modified 1 year and 249 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.