From: Juri Linkov <juri@linkov.net>
To: Vincenzo Pupillo <v.pupillo@gmail.com>
Cc: Yuan Fu <casouri@gmail.com>, Eli Zaretskii <eliz@gnu.org>,
74610@debbugs.gnu.org
Subject: bug#74610: 31.0.50; Submitting mhtml-ts-mode, treesitter alternative to mhtml-mode
Date: Mon, 16 Dec 2024 19:37:35 +0200 [thread overview]
Message-ID: <87r067fs0w.fsf@mail.linkov.net> (raw)
In-Reply-To: <26683715.1r3eYUQgxm@fedora> (Vincenzo Pupillo's message of "Sat, 14 Dec 2024 11:37:01 +0100")
Ciao Vincenzo,
> In data mercoledì 11 dicembre 2024 05:54:09 Ora standard dell’Europa centrale,
>
> Attached is the revised patch following your previous comments.
> As I already wrote to Dmitry, I am doing some tests to see if html-ts-mode can
> be extended and if there is a way to integrate one multi-language mode into
> another multi-language mode.
I'm testing your patch with mhtml-ts-mode, and everything works nicely.
At the same time I'm adding a new ts-thing named 'sexp-list' in bug#73404.
While 'sexp' defines both lists and atoms, 'sexp-list' defines only lists.
So I added (sexp-list ,(regexp-opt '("element")) 'symbols)
to treesit-thing-settings in html-ts-mode.el.
But then discovered surprisingly that it has no effect on mhtml-ts-mode.
The problem is that treesit-thing-settings should be duplicated
from html-ts-mode to mhtml-ts-mode.
On the one hand, integrating multi-language mode to the exiting mode
html-ts-mode could avoid the need to duplicate treesit-thing-settings
for html.
But on the other hand, integrating mhtml-ts-mode to html-ts-mode
doesn't help to avoid such duplication for other embedded modes.
Because I needed to duplicate treesit-thing-settings for javascript
as well.
So extending html-ts-mode doesn't help here, and maybe even better
to add mhtml-ts-mode to keep the symmetry with existing mhtml-mode
such as used in mode remapping:
(add-to-list 'major-mode-remap-alist '(mhtml-mode .
mhtml-ts-mode))
What could really help is to try to get settings from html-ts-mode
and js-ts-mode to avoid the need to duplicate settings in mhtml-ts-mode.
next prev parent reply other threads:[~2024-12-16 17:37 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-29 21:57 bug#74610: 31.0.50; Submitting mhtml-ts-mode, treesitter alternative to mhtml-mode Vincenzo Pupillo
2024-12-01 6:01 ` Yuan Fu
2024-12-01 8:00 ` Eli Zaretskii
2024-12-01 8:18 ` Yuan Fu
2024-12-03 14:29 ` Vincenzo Pupillo
2024-12-11 4:54 ` Yuan Fu
2024-12-14 10:37 ` Vincenzo Pupillo
2024-12-16 17:37 ` Juri Linkov [this message]
2024-12-04 1:27 ` Dmitry Gutov
2024-12-04 10:47 ` Vincenzo Pupillo
2024-12-05 16:51 ` Dmitry Gutov
2024-12-06 13:39 ` Vincenzo Pupillo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r067fs0w.fsf@mail.linkov.net \
--to=juri@linkov.net \
--cc=74610@debbugs.gnu.org \
--cc=casouri@gmail.com \
--cc=eliz@gnu.org \
--cc=v.pupillo@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).