From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Daan Ro Newsgroups: gmane.emacs.bugs Subject: bug#74412: 31.0.50; Treesit-outline conflict with outli in Emacs 31 Date: Thu, 21 Nov 2024 15:16:14 +0700 Message-ID: <85CA4585-4E56-482E-AB91-2D0046D9B659@getmailspring.com> References: <86ikshspsm.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="673eec4e_38c9f473_90c" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31174"; mail-complaints-to="usenet@ciao.gmane.io" Cc: "74412@debbugs.gnu.org" <74412@debbugs.gnu.org>, "liaotx2@gmail.com" To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Nov 21 09:18:23 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1tE2ON-0007wZ-BU for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 21 Nov 2024 09:18:23 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tE2O4-0005Cq-NY; Thu, 21 Nov 2024 03:18:04 -0500 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 1tE2O2-0005CY-OZ for bug-gnu-emacs@gnu.org; Thu, 21 Nov 2024 03:18:02 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tE2O2-00083T-G0 for bug-gnu-emacs@gnu.org; Thu, 21 Nov 2024 03:18:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:From:Date:To:Subject; bh=oCUxR/mwOQW5nhlvluPY0WvHsJtcKaAtnRf82DZYBdQ=; b=UdX0HCj2QJL80tINMVNxhU9LvMCstvWclAjfXbEH/I8XNT6wIxljU9NzIo7i1prglgNmmkhMhyQWq+Sl0sHW3hyeTWZpQI3RvQiDn6tUo2wLcqS3NnQPG+FGNpVef3JkVnwBUHkMCvHSy8ZC8lGGkZEeMIvs6y/WBJXjr9ADja0QVMLWbnVguQ/9/wgzly+eCXnodz9Yp0MJtPAg15y821qkaqnsUSwTNE32HTfQ2zgGT8EcwiugXac1fZhmiiYNv1FSglSaOpF1FsCUQqsTcRLDwqlc2k9HtJi1oguAQ6ahQM1EyFJmdpCdNnsQ5yyks183af9cp0uN4lOSCr93aQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tE2O2-0005Fk-2Z for bug-gnu-emacs@gnu.org; Thu, 21 Nov 2024 03:18:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Daan Ro Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 21 Nov 2024 08:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74412 X-GNU-PR-Package: emacs Original-Received: via spool by 74412-submit@debbugs.gnu.org id=B74412.173217704820148 (code B ref 74412); Thu, 21 Nov 2024 08:18:02 +0000 Original-Received: (at 74412) by debbugs.gnu.org; 21 Nov 2024 08:17:28 +0000 Original-Received: from localhost ([127.0.0.1]:49018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tE2NT-0005Eu-T1 for submit@debbugs.gnu.org; Thu, 21 Nov 2024 03:17:28 -0500 Original-Received: from mail-pj1-f45.google.com ([209.85.216.45]:57596) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tE2NR-0005Eg-Lp for 74412@debbugs.gnu.org; Thu, 21 Nov 2024 03:17:26 -0500 Original-Received: by mail-pj1-f45.google.com with SMTP id 98e67ed59e1d1-2eade1cad26so556872a91.2 for <74412@debbugs.gnu.org>; Thu, 21 Nov 2024 00:17:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1732176979; x=1732781779; darn=debbugs.gnu.org; h=mime-version:subject:references:in-reply-to:message-id:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to; bh=oCUxR/mwOQW5nhlvluPY0WvHsJtcKaAtnRf82DZYBdQ=; b=ehoj5QlPDqUI0Z/zvg3OWoFIO356IyNqblB6P9tE52ih0f5fVK8SUV/qO0yUJzpiiK PJfVasMCCIt3DCpPsxbKo0nb5qvpH5D5wER1OZOGfuB73DlTzwOFkc3MeoX3ZUyhxgJC /HC9G88ram/rR5vUNW86NXEBwWDUm6eZ8lxl00ruRTOjP071gpTBbptS48hEPdKdQbU9 yte01x1iFenUD51JvgwNkHlxDzXNXRnUj37cqReddveYFQZEGV4Z4E9WD7OwaCNnsGu7 qbSw3M2RXEuLwjX2zJT+M6zSACDqOdbNAm+vjsGfdmnEopW8OW72enKUkmWKvLpdu/sg hvIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732176979; x=1732781779; h=mime-version:subject:references:in-reply-to:message-id:cc:to:from :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=oCUxR/mwOQW5nhlvluPY0WvHsJtcKaAtnRf82DZYBdQ=; b=g6f0mRdt8MdeozNxWz2ASUiOoX0UUvKNAmSnF8rn57iXNKRAh6S8uPBUeJgvlz53ma 3P+FpO79/SqayhMHm780MXF8b4wkblq7VUCJLbuQcO93x93phHB1b1RCdmlbUP1KnJ9d 6EVWCO4uNWUhQ3NmId+WCSclMaNdFUfA/BmOKC3RNLGXY0sravtVn9s7T+IZWV/CDmcd wkVaOyaO1XsDIngJoxoJkyLLuXk+nFbJClIAvchnlcTvkURWiFmxY50OKJ+cX3IWePTC keRoqvmRH4WcVYUECdzJlfgGus9R8eG/pRQ/ztXIJZGkJSmuHI+pTZtwM74nBwhjtNCh nckQ== X-Forwarded-Encrypted: i=1; AJvYcCWSXpE1xJn4GsusrpSN/9cRMsIS0LoryLlEFNS80sy5imBF0bHyxISV3+2htOHj9bHvWbtHjw==@debbugs.gnu.org X-Gm-Message-State: AOJu0YzttEkZm/Qlz+g0wed83A5Ro7UsDTPK2ATzdCkTFANa5DWj7dqA pylBG8G3cMmqqq5Ic+E64t8Yqo5CK5i6RrHEcvwzIXOMNoSQL0gLoL4DSqCO X-Gm-Gg: ASbGncuWNOaIcHYFuTH7uXCzn6tJxpnoHFd7jXstXEXlwriJLoJmHcg9C9I/p61hiJH nd6iskDmkejuCaCtZHjnWP5D7O9JRcIKF/NmUtkxTSUff+gK3Ljmck5Ik+i2B1oekkmc2KbuwBF I5G6lSgUm20jDzG7UaQnpgJXI30jL9E3cJ0W2UD9MaOfllZ28hrKK2rEG7ShTAZbJNmwSvcECgp UWnav4OQaJ31jzVZgKTT4zBj4mgTJ0mUMHkRHpRedo= X-Google-Smtp-Source: AGHT+IEqVi/naDEk0JAZuUXI8GfGH7sUqMGc5+/M5RBotLb4IMlIkTLDFLkS6B6r6KzgdbFR4Ko1iQ== X-Received: by 2002:a17:90b:288e:b0:2ea:8efd:48ad with SMTP id 98e67ed59e1d1-2eaca70999emr7317430a91.9.1732176979072; Thu, 21 Nov 2024 00:16:19 -0800 (PST) Original-Received: from dan-laptop ([1.53.153.91]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-21287ee14b6sm7953235ad.137.2024.11.21.00.16.17 for <74412@debbugs.gnu.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 21 Nov 2024 00:16:18 -0800 (PST) In-Reply-To: <86ikshspsm.fsf@gnu.org> X-Mailer: Mailspring X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:295717 Archived-At: --673eec4e_38c9f473_90c Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Before treesit.el went to set those variables, there have been already a bunch of packages based on outline-minor-mode for partitioning code into sections using comments only by highlighting headers and providing navigation, folding, etc. inspired by emacs-lisp-mode's outline-regexp settings. Such ones enable a feel of "literate" programming by bringing outline-mode features to code section delimited by headings (special comments like ";;;", ";; *") using just comments regardless of code semantic. The above is my use of outline-minor-mode, maybe other people have different use cases. treesit.el makes the configuration harder by the additional variable setting. I wish there's a hook like treesit-after-major-mode-setup-hook to let people fine-tune or even undo settings, but of course treesit-disable-features to prevent any execution from the start is still better. Daanturo On Nov 21 2024, at 1:50 am, Eli Zaretskii wrote: > > Cc: "74412@debbugs.gnu.org" <74412@debbugs.gnu.org> > > Date: Thu, 21 Nov 2024 00:06:41 +0700 > > From: Daan Ro > > > > Personally I also find treesit's decision to set outline variables > > somewhat intrusive. > > I don't understand why. These variables are meant to be set by modes, > so treesit.el uses them exactly as intended. > --673eec4e_38c9f473_90c Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline
Before treesit.el went to set those variables, there have been alrea= dy a
bunch of packages based on outline-minor-mode for partitio= ning code into
sections using comments only by highlighting hea= ders and providing
navigation, folding, etc. inspired by emacs-= lisp-mode's outline-regexp
settings.

Such ones en= able a feel of =22literate=22 programming by bringing
outline-m= ode features to code section delimited by headings (special
com= ments like =22;;;=22, =22;; *=22) using just comments regardless of code<= /div>
semantic.

The above is my use of outline-minor-mo= de, maybe other people have
different use cases. treesit.el mak= es the configuration harder by the
additional variable setting.= I wish there's a hook like
treesit-after-major-mode-setup-hook= to let people fine-tune or even undo
settings, but of course t= reesit-disable-features to prevent any
execution from the start= is still better.


Daanturo
On Nov 21 2024, at 1:50 am, Eli Zaretskii <eliz=40g= nu.org> wrote:
> Cc: =2274412=40debbugs.= gnu.org=22 <74412=40debbugs.gnu.org>
> Date: Thu, 21 N= ov 2024 00:06:41 +0700
> =46rom: Daan Ro <daanturo=40gmai= l.com>
>
> Personally I also find treesit's = decision to set outline variables
> somewhat intrusive.
I don't understand why. These variables are meant to be set by = modes,
so treesit.el uses them exactly as intended.
=
3D=22Sent --673eec4e_38c9f473_90c--