bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#65470: 29.1.50; js-ts-mode: regex pattern can cause incorrect parent


From: Dmitry Gutov
Subject: bug#65470: 29.1.50; js-ts-mode: regex pattern can cause incorrect parenthesis matching
Date: Sat, 16 Sep 2023 23:07:50 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0

On 16/09/2023 14:40, Eli Zaretskii wrote:
This also causes byte-compilation warnings on a system that has no
tree-sitter installed:

   In end of data:
   progmodes/typescript-ts-mode.el:498:17: Warning: the function 
‘treesit-node-end’ is not known to be defined.
   progmodes/typescript-ts-mode.el:497:17: Warning: the function 
‘treesit-node-start’ is not known to be defined.
   progmodes/typescript-ts-mode.el:474:6: Warning: the function 
‘treesit-query-compile’ is not known to be defined.

Could you please fix these?
I fixed this myself by simply declaring the functions the
byte-compiler was complaining about, but I'd be happier if someone
could explain these warnings, since the offending functions are not
called anywhere in the code I could see.  What did I miss?

treesit-node-start/end are called in tsx-ts--syntax-propertize-captures (note the rename I just performed), and treesit-query-compile is called in *-ts--s-p-query's init forms.

Both added in commit 1fb2fb501f3 reviewed by yours truly, so, sorry about that.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]