From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.devel Subject: Re: Turing on tree-sitter (was: Call for volunteers: add tree-sitter support to major modes) Date: Sun, 9 Oct 2022 23:54:45 -0700 Message-ID: <78205E8D-B2D4-4460-BE0A-9BF7C627A79B@gmail.com> References: <83czb1jrm3.fsf@gnu.org> <87v8ot2nfi.fsf@posteo.net> <837d19jfia.fsf@gnu.org> <83edvgi3mx.fsf@gnu.org> <87r0zg5g76.fsf@thornhill.no> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.1\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11823"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , philipk@posteo.net, emacs-devel@gnu.org To: Theodor Thornhill Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Oct 10 08:55:54 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ohmhe-0002oz-D8 for ged-emacs-devel@m.gmane-mx.org; Mon, 10 Oct 2022 08:55:54 +0200 Original-Received: from localhost ([::1]:44594 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohmhd-00079w-15 for ged-emacs-devel@m.gmane-mx.org; Mon, 10 Oct 2022 02:55:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55572) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohmgf-0006Ni-AJ for emacs-devel@gnu.org; Mon, 10 Oct 2022 02:54:54 -0400 Original-Received: from mail-pj1-x1031.google.com ([2607:f8b0:4864:20::1031]:38887) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohmgb-0003w6-FM; Mon, 10 Oct 2022 02:54:50 -0400 Original-Received: by mail-pj1-x1031.google.com with SMTP id x1-20020a17090ab00100b001fda21bbc90so12269128pjq.3; Sun, 09 Oct 2022 23:54:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=8i1ueFmdNFJE1d/NwrkmLh5HYNMV7zVNfpMrQ9ss/04=; b=YtykKOjc74tv6ybN2JsVo6gpCFOI8O96KjWTLHycjRBWM2k3kn9SpcLe3MfDn2gup1 lNymUIr97yDO9ydKTAW9sxCI7B8r+QouUNt7ZaiHz9KmbmB4LcFamQw+XBuEl4BetKEX R714dA2IBHmjUPBQNRgPPKegpQdoPzIDG+KAsIROgqnSqqgs/O6wqMGnSJpxTjj2GLli v3auUCX88iOSzLvZbaavKk7ZbpudNCPQKVNMZYsT6LnKy4IH9U0VlkBOw7ixk8TY2Gzl jhhMYrpsjQYMUeUIthtJBkY/nzQ5rLA0/0k94XRZw7rCBcA0AcRhkon/6cDbuItwaE8R tyFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8i1ueFmdNFJE1d/NwrkmLh5HYNMV7zVNfpMrQ9ss/04=; b=1yu+ROdEnX6BS1lXs7lGZUNDEaX4o9MquerCnIbKENoJFUmDIur1XqBanmzIrV7brw LxFCnp+9jextPfT7L0MpFZT4nBICr6zyf9/WgRYuca0HDYnw4oHMM8hzm6f9ZcbLrp3c OjGIdxfy03lqxjUVr6UcxiRVOOkpvTxL9P70a1QL6454WkgY9uIB4ZP5L1HP8kJRYrJc k6g9xm/pxOMCAcNlYVh1s8xcbc2RiigAxcppd+OxjaJN8p4zYVWGvoyrd/vfissqoKDv /sZoWpnhZZphz3li6hHbI7DGiLQoYKHO0lZIj4Qy+hVsnkBBV9Tq2c4CAxDXQKa2A94n XA5w== X-Gm-Message-State: ACrzQf083wA8Xtz3kuSAcZHiDOCiqfDIrngmUJbmdy7c/QNiVSm5Apc/ 6hKLSRM81bAew8E+TDXwjDI= X-Google-Smtp-Source: AMsMyM4aXiXoya7FUg+6U7GPzTthc7wcTtY+yARqQ7NShRDNwMuWno/2GZaMZN1pbSREZYtnzGy6bQ== X-Received: by 2002:a17:902:b942:b0:178:4a7e:da04 with SMTP id h2-20020a170902b94200b001784a7eda04mr17399899pls.8.1665384887744; Sun, 09 Oct 2022 23:54:47 -0700 (PDT) Original-Received: from smtpclient.apple (cpe-172-117-161-177.socal.res.rr.com. [172.117.161.177]) by smtp.gmail.com with ESMTPSA id x6-20020a628606000000b005629b6a8b53sm6291716pfd.15.2022.10.09.23.54.46 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Oct 2022 23:54:47 -0700 (PDT) In-Reply-To: <87r0zg5g76.fsf@thornhill.no> X-Mailer: Apple Mail (2.3696.120.41.1.1) Received-SPF: pass client-ip=2607:f8b0:4864:20::1031; envelope-from=casouri@gmail.com; helo=mail-pj1-x1031.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:297320 Archived-At: > On Oct 9, 2022, at 11:46 PM, Theodor Thornhill = wrote: >=20 > Eli Zaretskii writes: >=20 >>> Date: Sun, 09 Oct 2022 16:25:17 +0300 >>> From: Eli Zaretskii >>> Cc: emacs-devel@gnu.org, casouri@gmail.com >>>=20 >>>> From: Philip Kaludercic >>>> Cc: emacs-devel@gnu.org, Yuan Fu >>>> Date: Sun, 09 Oct 2022 12:26:09 +0000 >>>>=20 >>>> One more thing, it looks like the usage of tree-sitter is enabled = for >>>> python by toggling `python-use-tree-sitter'. Will every mode now = have >>>> this kind of an option? I would hope not... >>>=20 >>> That's a separate discussion, so please start a new thread. >>=20 >> So here I am, starting that separate discussion. >>=20 >> Since tree-sitter support is per-language, I do think it makes sense >> for each mode to have its tree-sitter support turned on separately. >> But we could also have a global "turn on tree-sitter support in every >> mode that has it" option, which will turn this on for those modes >> which can be supported by tree-sitter, if the appropriate >> language-support library is installed. >>=20 >> Comments? >=20 > +1 for this, but also keep the per-modes customs. Then we can eat the > cake and have it too. >=20 > Such a mechanism can be made later, I think? >=20 > Theo +1 for this, but also add a third possible value to per-mode customs = that keeps tree-sitter always off for the mode. That way someone can = enable tree-sitter for all but that mode. Are there precedents for such = ternary variables? nil, t, and 'never? Yuan