From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Philip Kaludercic Newsgroups: gmane.emacs.devel Subject: Re: New Package for NonGNU-ELPA: clojure-ts-mode Date: Sat, 12 Aug 2023 20:22:32 +0000 Message-ID: <871qg89fjr.fsf@posteo.net> References: <87il9kksqz.fsf@dfreeman.email> <87a5uw9ivs.fsf@posteo.net> <83y1igcban.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7482"; mail-complaints-to="usenet@ciao.gmane.io" Cc: danny@dfreeman.email, emacs-devel@gnu.org, manuel.uberti@inventati.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Aug 12 22:23:24 2023 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 1qUv8s-0001fN-Ob for ged-emacs-devel@m.gmane-mx.org; Sat, 12 Aug 2023 22:23:22 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qUv8H-0000CJ-5t; Sat, 12 Aug 2023 16:22:45 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qUv8C-0000C4-5b for emacs-devel@gnu.org; Sat, 12 Aug 2023 16:22:40 -0400 Original-Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qUv88-0006bv-MN for emacs-devel@gnu.org; Sat, 12 Aug 2023 16:22:39 -0400 Original-Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 4D520240101 for ; Sat, 12 Aug 2023 22:22:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1691871754; bh=OSJTxo8OejCNfMysoFe5QYwHbfPqOL8+GzJm6Kq3sWY=; h=From:To:Cc:Subject:Autocrypt:Date:Message-ID:MIME-Version:From; b=XMB51/vsooVltCDuW7s2N7tGzjDfEa+HTuUg05mmHxYOMvgboLXX8EX4IdHvqmtZV 2T2xkDO5l11drtgmKbjhP+1Dg9CLy93A6hAWUpqOo49dM+LKx0xBZB2paC2gK7nA1U hhD2xOy45+1OcWdiRLLGVtZGQETp41F20TNL+XVQHAe4b9YXJKsXnkm0Aq4hZl3So3 SCaWbvuc8Zk0zgRwPjPmxW/nUZA1DYhd9evfnW5iOzF/lvtGb9XCLCTyclKO1kcmxY qp0U2pNjdn4IBnT9Ev0tA6QMnXeIohRTt/YxDpyre+XZfeibgGXh7wvgVQ8PIGKlV0 NRfyYgYXv8Naw== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4RNXCF1HGqz6tw5; Sat, 12 Aug 2023 22:22:33 +0200 (CEST) In-Reply-To: <83y1igcban.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 12 Aug 2023 22:26:08 +0300") Autocrypt: addr=philipk@posteo.net; keydata= mDMEZBBQQhYJKwYBBAHaRw8BAQdAHJuofBrfqFh12uQu0Yi7mrl525F28eTmwUDflFNmdui0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiWBBMWCAA+FiEEDg7HY17ghYlni8XN8xYDWXahwukFAmQQUEICGwMFCQHhM4AFCwkI BwIGFQoJCAsCBBYCAwECHgECF4AACgkQ8xYDWXahwulikAEA77hloUiSrXgFkUVJhlKBpLCHUjA0 mWZ9j9w5d08+jVwBAK6c4iGP7j+/PhbkxaEKa4V3MzIl7zJkcNNjHCXmvFcEuDgEZBBQQhIKKwYB BAGXVQEFAQEHQI5NLiLRjZy3OfSt1dhCmFyn+fN/QKELUYQetiaoe+MMAwEIB4h+BBgWCAAmFiEE Dg7HY17ghYlni8XN8xYDWXahwukFAmQQUEICGwwFCQHhM4AACgkQ8xYDWXahwukm+wEA8cml4JpK NeAu65rg+auKrPOP6TP/4YWRCTIvuYDm0joBALw98AMz7/qMHvSCeU/hw9PL6u6R2EScxtpKnWof z4oM Received-SPF: pass client-ip=185.67.36.66; envelope-from=philipk@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:308631 Archived-At: Eli Zaretskii writes: >> From: Philip Kaludercic >> Cc: emacs-devel , Manuel Uberti >> >> Date: Sat, 12 Aug 2023 19:10:31 +0000 >> >> If added to GNU ELPA and NonGNU ELPA, this would be the first *-ts-mode >> package, from what I see. From what I recall, the -ts-mode approach was >> a compromise to add some basic support for Tree Sitter in Emacs 29, but >> I am not sure if it was a final decision on the matter, because at least >> from my perspective of following the tree sitter development from a >> close distance, but also from user reports I have heard of since the >> release of Emacs 29, the current approach is slightly confusing. Adding >> a -ts-mode to ELPA might be misinterpreted as a commitment to the >> current trajectory, and I am not sure if that is intended. > > If you mean that the *-ts-modes could be a minor mode, then I believe > we found that to be unworkable, except in very rare cases where the > major mode supporting the same language is very thin and has only a > couple of simple mode-specific features. Otherwise, the very > different way of doing font-lock, indentation, imenu, etc. means that > basically all the features must be reimplemented anew, and in many > cases make no sense at all. So a minor mode is not TRT here. This was my understanding as well, and while I understand it from a technical perspective, I have a hunch there must be a tolerable alternative with a better user interface. Perhaps this is a point at which the approach at which the major-mode abstraction breaks down and has to be rethought? There have been instances of alternative major modes for different languages in the past (cperl, perl; js, js2, js3) that have found one way or another to co-exist, but seeing how this is becoming more and more common, it would be nice to have some consistent and unified way of expressing these kinds of alternatives. > The aspects of these modes that are not yet firmly decided are how to > activate/deactivate them in a way that would be convenient and simple. > But I don't think we will be removing the *-ts-modes as major modes, > no. I get that we wouldn't want to remove them, out of backwards compatibility, but is the plan to write more ...-ts-mode major modes?