GNU bug report logs - #77746
[PATCH] sh-mode: Fix incorrect word syntax for punctuation in sh-mode

Previous Next

Package: emacs;

Reported by: James Cherti <contact <at> jamescherti.com>

Date: Fri, 11 Apr 2025 14:56:02 UTC

Severity: normal

Tags: patch

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: James Cherti <contact <at> jamescherti.com>
To: Eli Zaretskii <eliz <at> gnu.org>, Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 77746 <at> debbugs.gnu.org, juri <at> linkov.net
Subject: bug#77746: [PATCH] sh-mode: Fix incorrect word syntax for punctuation in sh-mode
Date: Tue, 15 Apr 2025 12:22:08 -0400
On 2025-04-15 11:24, Eli Zaretskii wrote:
>> From: Stefan Monnier <monnier <at> iro.umontreal.ca>
>> Cc: James Cherti <contact <at> jamescherti.com>,  77746 <at> debbugs.gnu.org,
>>    juri <at> linkov.net
>> Date: Tue, 15 Apr 2025 11:17:02 -0400
>>
>>>> The issue occurs in both sh-mode and bash-ts-mode.
>>> I'm surprised that bash-ts-mode should use syntax tables, instead of
>>> relying on the results of parsing by tree-sitter.
>>
>> It's not front-and-center in his bug report, but what he means by
>> "completion" seems to be mostly dabbrev completion, which doesn't make
>> use of tree-sitter.
>
> He also mentioned font-lock.

Yes, this patch fixes dabbrev, functions such as
(highlight-symbol-at-point), and any other function that
relies on thing-at-point for symbol detection.

(The core issue is inaccurate symbol detection. This patch
improves it by excluding characters that should not be
considered part of a valid variable name.)

--
James Cherti
GitHub: https://github.com/jamescherti
Website: https://www.jamescherti.com/




This bug report was last modified 107 days ago.

Previous Next


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