unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Theodor Thornhill <theo@thornhill.no>
To: Perry Smith <pedz@easesoftware.com>
Cc: emacs-devel@gnu.org, Yuan Fu <casouri@gmail.com>
Subject: Re: Creating a paradigm for leveraging Tree Sitter's power
Date: Sat, 24 Dec 2022 16:13:05 +0100	[thread overview]
Message-ID: <CAB01BE2-86B1-4B9E-AAF6-CFEA96FD4B70@thornhill.no> (raw)
In-Reply-To: <26841F01-ADE5-422F-A0EC-0F0798EB40E5@easesoftware.com>



On 24 December 2022 15:57:30 CET, Perry Smith <pedz@easesoftware.com> wrote:
>
>> On Dec 24, 2022, at 04:07, Theodor Thornhill <theo@thornhill.no> wrote:
>> 
>> Yeah. One shortcoming of tree-sitter imo is that the parser author decides what the nodes are named. So I think we need to create a framework so that every mode can map over ast-names to Emacs concepts. The goal must be for the normal Emacs things to require little to no changes, but get the benefits from treesit.
>
>To me, in my brain, Tree Sitter is far more expressive and powerful than existing concepts.  “Little to no changes” to me implies fitting a much larger concept into a smaller container and sacrificing the possible expressiveness and power.
>

Yeah I agree, but for many things such as movement, there are some pretty advanced utilities already in Emacs. Would be a shame to just implement it all in an incompatible package just because we didn't try really hard to incorporate it :)

>> I think we should just start doing that immediately on the master branch and allow for "big" changes going forward. We should settle on something good for Emacs 30, hopefully.
>> 
>> I'm a little worried we feel we need "complete" proposals too soon.
>> 
>> Let's get all good ideas on the table, implemented and installed, then we can consolidate after we discover pain points etc.
>> 
>> I'm working on changing the forward/backward thing and transpose. Not only for tree-sitter, but for others as well :)
>> 
>> What do you think?
>
>Yes.  I completely agree.  I guess for others, you can take my initial post as “this is the direction I’m exploring in” but it is helpful to get feedback of new ideas and experiences from past mistakes.
>
>

Yeah I'm in no way objecting to anything you say. From experience (when it was mostly Yuan and me) these things solidify over time, and the more the merrier!

Theo



  reply	other threads:[~2022-12-24 15:13 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-24  1:32 Creating a paradigm for leveraging Tree Sitter's power Perry Smith
2022-12-24  9:09 ` Yuan Fu
2022-12-24 10:07   ` Theodor Thornhill
2022-12-24 14:57     ` Perry Smith
2022-12-24 15:13       ` Theodor Thornhill [this message]
2022-12-24 14:32   ` Perry Smith
2022-12-24 16:52     ` [External] : " Drew Adams
2022-12-24 17:29       ` Perry Smith

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=CAB01BE2-86B1-4B9E-AAF6-CFEA96FD4B70@thornhill.no \
    --to=theo@thornhill.no \
    --cc=casouri@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=pedz@easesoftware.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).