From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#66752: 30.0.50; [PATCH] Add support for 'thing-at-point' to 'bug-reference-mode' Date: Sun, 05 Nov 2023 07:31:30 +0200 Message-ID: <83fs1k4vgt.fsf@gnu.org> References: <87o7g9tj79.fsf@gnu.org> <47a54242-d331-5864-7b2c-f1990034091a@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39941"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 66752@debbugs.gnu.org, tsdh@gnu.org To: Jim Porter , Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Nov 05 06:32:42 2023 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 1qzVkX-000A7R-IF for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 05 Nov 2023 06:32:41 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qzVkJ-0003Lv-9d; Sun, 05 Nov 2023 01:32:27 -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 1qzVkH-0003Ll-T9 for bug-gnu-emacs@gnu.org; Sun, 05 Nov 2023 01:32:25 -0400 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 1qzVkH-00031q-LI for bug-gnu-emacs@gnu.org; Sun, 05 Nov 2023 01:32:25 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qzVkr-0004kb-R8 for bug-gnu-emacs@gnu.org; Sun, 05 Nov 2023 01:33:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 05 Nov 2023 05:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66752 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 66752-submit@debbugs.gnu.org id=B66752.169916235318213 (code B ref 66752); Sun, 05 Nov 2023 05:33:01 +0000 Original-Received: (at 66752) by debbugs.gnu.org; 5 Nov 2023 05:32:33 +0000 Original-Received: from localhost ([127.0.0.1]:35956 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qzVkP-0004jf-C5 for submit@debbugs.gnu.org; Sun, 05 Nov 2023 01:32:33 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57582) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qzVkN-0004jP-8D for 66752@debbugs.gnu.org; Sun, 05 Nov 2023 01:32:32 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qzVjh-00030f-CG; Sun, 05 Nov 2023 01:31:49 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=WUkwS6lWE24OY0V0WrSyqm1eLuICsVrLPaf+vrO1itY=; b=Wq02cIHnF2qU 3bmrDc4cBLisuDtLMe2nvCU9XiXk74+s+uFGb2el7fgPljdf6VPPARAYRxoaZ4xmD8cuc75Cc2R/V wmJ8Tby1DDIQMqpcFvBUNsugK6uN/SHGUigkrdYRjlL1a3rPN71axxKCJG7Y6q8FKwJnWAFqP+Caq Ti5rPCBXVW/QaDrd/+8MEhSpHnxrXHZDICTdXbRR5q61DJJj+E3DDgehWYztj+d1n5BWqB58Ta4L8 zCAqiW/QTt+sfvwRi3p61djQdmtV7+w0CeAgD03ovdpISIetfeE0X8GaegRZO+KHLivrcAp051iCi dS3YLf8uFiC3PXzSMczvAw==; In-Reply-To: <47a54242-d331-5864-7b2c-f1990034091a@gmail.com> (message from Jim Porter on Sat, 4 Nov 2023 13:07:38 -0700) 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:273799 Archived-At: > Date: Sat, 4 Nov 2023 13:07:38 -0700 > Cc: 66752@debbugs.gnu.org, Eli Zaretskii > From: Jim Porter > > On 11/4/2023 12:24 PM, Tassilo Horn wrote: > > Jim Porter writes: > >> (jit-lock-unregister #'bug-reference-fontify) > >> + (setq thing-at-point-provider-alist > >> + (delete '((url . bug-reference--url-at-point)) > >> + thing-at-point-provider-alist)) > >> + (when (equal thing-at-point-provider-alist > >> + (default-value 'thing-at-point-provider-alist)) > >> + (kill-local-variable 'thing-at-point-provider-alist)) > > > > Is that conventional, nuking a buffer-local value once it's back to its > > default value. Just asking out of curiosity. > > I'm not sure. The only example I saw for adding to > 'thing-at-provider-alist' was for EWW (a major mode). I thought, "What > if someone activated and deactivated 'bug-reference-mode' and then later > added something to the default value of 'thing-at-provider-alist'?" > > I don't know if that's a case we want to support; maybe I'm just being > overly cautious. (Or maybe there should be - or already is - some > utility function that does this for us.) Eli, do you have any thoughts > on this part? I don't see any problems with this. But I added Stefan in case he has an opinion.