From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 10:49:30 2025 Received: (at submit) by debbugs.gnu.org; 2 Mar 2025 15:49:30 +0000 Received: from localhost ([127.0.0.1]:33213 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tolZJ-0002NZ-MY for submit@debbugs.gnu.org; Sun, 02 Mar 2025 10:49:30 -0500 Received: from lists.gnu.org ([2001:470:142::17]:48668) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tolZG-0002MU-B9 for submit@debbugs.gnu.org; Sun, 02 Mar 2025 10:49:26 -0500 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 1tolZA-00016y-Cz for bug-gnu-emacs@gnu.org; Sun, 02 Mar 2025 10:49:20 -0500 Received: from dancol.org ([2600:3c01:e000:3d8::1]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tolZ8-0001FG-8W for bug-gnu-emacs@gnu.org; Sun, 02 Mar 2025 10:49:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From:Sender: Reply-To:Cc:Content-Transfer-Encoding:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=NZKz3qatX1fJBL9GRlDpmxCWalHFNAJ9lSNpm6gMCMI=; b=QmjH22YEt1UOaoma/BcQl34Xty imdOVoDvA1UM9wwhWOqbCVLlJvTfCjfXwQLIiMEbWUNdNTKtizwBIyGt8EabH5jOiMXW6BW9qxHTo IIz87KDROk5wc+6iKh1g9tcBniuhFEbcm2FrrCQgeVN9v4AXFTcDI5EukgUuWdqlHJxQJAPGEqotY Nd5fqbXDwS4npz3fhUUMRsMJncVDAC5EYgAZM0Fl8TEMaRFa0nascP0nfhPtgMieOCILMEWi/r9lh XnBHMeAzIlzPn5EePYBnzKWI8V8pLbMUWMxmVHvbed+10GLGWzq9eQpD89Oa6kUqe+3eyVmOmCX+q FEOY2eDw==; Received: from dancol by dancol.org with local (Exim 4.96) (envelope-from ) id 1tolYy-001c6f-0k for bug-gnu-emacs@gnu.org; Sun, 02 Mar 2025 10:49:08 -0500 From: Daniel Colascione To: bug-gnu-emacs@gnu.org Subject: global-hi-lock-mode prompts on its own help User-Agent: mu4e 1.12.8; emacs 31.0.50 Date: Sun, 02 Mar 2025 10:49:15 -0500 Message-ID: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2600:3c01:e000:3d8::1; envelope-from=dancol@dancol.org; helo=dancol.org 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, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.1 (/) >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the help buffer, and type C-h m again. You'll get prompted about whether you want to apply the hi-lock patterns in the help buffer. And then, because for some reason we don't actually clear the help buffer but just narrow it to what we want, the next time you ask for help, even on something unrelated to hi-lock (e.g. progn), hi-lock will ask you whether you want to apply hi-lock patterns. From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 11:34:01 2025 Received: (at 76687) by debbugs.gnu.org; 2 Mar 2025 16:34:01 +0000 Received: from localhost ([127.0.0.1]:33750 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tomGO-0001XM-Vc for submit@debbugs.gnu.org; Sun, 02 Mar 2025 11:34:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50362) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tomGM-0001Wc-4D for 76687@debbugs.gnu.org; Sun, 02 Mar 2025 11:33:58 -0500 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 1tomGF-0005Iy-7k; Sun, 02 Mar 2025 11:33:51 -0500 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=9R9UwGCy2roGX6tCGxYty9vgciiT7uFt+i84IVmeXAg=; b=Rw8AmFSswlS0 H6cIV0hrWyOC6KDjtdAFT7ykLFalVm8jckVWnY3qTBXLmO6Kt8VOtLziIGyrj/ZqXasEW9Afw74RX 6K2HUNd9d3gg0rq2gqPt1loN2jPyPel9Em04ngunihlZOaQd5wY6Zrv3Hakebxt3yo6aF6L1k7JSe RTd1v6LZ9gSLxdjs69tutiDMYSXqnmO8DvNqZ4ZN9GH0TydCEt9tyRYdnH3eH+oeYAs59zUiCPBip 1F4bRfptQJ2MrGqbE4D5MvoSSvDvB5bdPWxxyy0bBV+DyNQpMechvBMbSjBBcoq59E9bTBNIcKR3h oD+RhllbQSJW1SGMv1KKVA==; Date: Sun, 02 Mar 2025 18:33:46 +0200 Message-Id: <86wmd7mlxx.fsf@gnu.org> From: Eli Zaretskii To: Daniel Colascione In-Reply-To: (message from Daniel Colascione on Sun, 02 Mar 2025 10:49:15 -0500) Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help References: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 76687 Cc: 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Daniel Colascione > Date: Sun, 02 Mar 2025 10:49:15 -0500 > > >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the help > buffer, and type C-h m again. You'll get prompted about whether you > want to apply the hi-lock patterns in the help buffer. And then, > because for some reason we don't actually clear the help buffer but just > narrow it to what we want, the next time you ask for help, even on > something unrelated to hi-lock (e.g. progn), hi-lock will ask you > whether you want to apply hi-lock patterns. That's the default of hi-lock-file-patterns-policy, no? IIUC, hi-lock asks this question for every file you visit, if it finds the patterns there. Or what am I missing? From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 12:21:45 2025 Received: (at 76687) by debbugs.gnu.org; 2 Mar 2025 17:21:45 +0000 Received: from localhost ([127.0.0.1]:34278 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ton0a-0000sv-Lm for submit@debbugs.gnu.org; Sun, 02 Mar 2025 12:21:44 -0500 Received: from dancol.org ([2600:3c01:e000:3d8::1]:59524) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ton0Y-0000sf-2z for 76687@debbugs.gnu.org; Sun, 02 Mar 2025 12:21:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=Xn1+iEDc0X8Uk4+Dp9UDIqyNbAXhRV4cAgzlLqs6yuw=; b=mCGtdrB9tRL5Dy+knCVFXPIJqd jL851PsSWuOvM8Bc7Gl3zlA11SC+baPI+SdQI8B6KCk3zPvBidqR5NdtzxZun25eO5XcV4Yurif6n 2yJXGqbo7LAdquxrdcvucZwQaxl+CUn/YieTto3dQ1WGZyz4qIP9zSi8zOwYlPK09+aLsv2vaq4lN qjP5lA91UJ1n/cSM+OzGF5AXtuMuFfZLraRXQg05XVxsVFQdjC6WZT+tDCd6egMozdw+Z2Xf9FFzJ dhfQpKHWMkGkbyotkwIPwi2BwdikUuTx6qi1bBEPha8PoS0LYKxP89FPPVfH+OYELbsRh8cgMm+3K Bf+GGQYg==; Received: from dancol by dancol.org with local (Exim 4.96) (envelope-from ) id 1ton0P-001d2P-0x; Sun, 02 Mar 2025 12:21:33 -0500 From: Daniel Colascione To: Eli Zaretskii Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help In-Reply-To: <86wmd7mlxx.fsf@gnu.org> References: <86wmd7mlxx.fsf@gnu.org> User-Agent: mu4e 1.12.8; emacs 31.0.50 Date: Sun, 02 Mar 2025 12:21:40 -0500 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Daniel Colascione >> Date: Sun, 02 Mar 2025 10:49:15 -0500 >> >> >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the help >> buffer, and type C-h m again. You'll get prompted about whether you >> want to apply the hi-lock patterns in the help buffer. And then, >> because for some reason we don't actually clear the help buffer but just >> narrow it to what we want, the next time you ask for help, even on >> something unrelated to hi-lock (e.g. progn), hi-lock will ask you >> whether you want to apply hi-lock patterns. > > That's the default of hi-lock-file-patterns-policy, no? IIUC, hi-lock > asks this question for every file you visit, if it finds the patterns > there. > > Or what am I missing? Hi-lock is asking to apply patterns in the help buffer because it's matching its own example patterns, not patterns any user meant to actually apply. When hi-lock is started and if the mode is not excluded or patterns rejected, the beginning of the buffer is searched for lines of the form: Hi-lock: (FOO ...) It's not helpful to prompt the user in this case, especially not for help invocations unrelated to hi-lock. From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 12:24:31 2025 Received: (at 76687) by debbugs.gnu.org; 2 Mar 2025 17:24:31 +0000 Received: from localhost ([127.0.0.1]:34303 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ton3G-00016R-Lw for submit@debbugs.gnu.org; Sun, 02 Mar 2025 12:24:30 -0500 Received: from mail-ed1-x530.google.com ([2a00:1450:4864:20::530]:45428) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1ton3D-00015i-Pl for 76687@debbugs.gnu.org; Sun, 02 Mar 2025 12:24:28 -0500 Received: by mail-ed1-x530.google.com with SMTP id 4fb4d7f45d1cf-5dee07e51aaso6847022a12.3 for <76687@debbugs.gnu.org>; Sun, 02 Mar 2025 09:24:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1740936261; x=1741541061; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=KpgxCCn0SOGwRpfqVI9SZqohylfAPFJ06bGhUb5I5DA=; b=UYWEhGCkYDinoMfMeET8TSfjz5ui5npJfJU7S4ok2jFLGHeWRnAQqxhZzDM0rC979M rg5j3jR3Oi8xDESeaNpjS/hr/BDgJMp9C909PhWYpLDuh43y6EScCIHMJJT+km93YRaw O6yoeMR53zOryaQFnSzLyrcYYsaHcfHhj3O09q3ZhQlEx4AxXLaWZPWup2+U0PnnvOEd +/cNDb5FmNiiaJZUb5oOqJslahZGyzxDz/TKG80aUrlYDTmknxZ4LRenXpdIJQ6vNXva mfsHoJ+B20d/iSXUyewcpvQa/VYbuK/wfUd9dxZN/6m9bO0123XQoar4kvuMbftekJEO oCsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1740936261; x=1741541061; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=KpgxCCn0SOGwRpfqVI9SZqohylfAPFJ06bGhUb5I5DA=; b=kv1DvMQnA9RMP2JsgTT+Xb5y5byp/erOig43a8rPxMnAyt+7HXLwLdJO1pQt1rqXjL 4wl9NycsS/zrSDhjBTJi9e3gbZl4qwyeq0QM3jrucMa5ebAnQIdujl3AZ06PVeQpGh3B 6Bm08C/+MU71XIkP97bJblJMI+O+z0PpP3KjciRb6moejOP+gVjFWcNEl3QJosE5xXTH 7SDX/8LlYUBQ00MaxLRXW89s3y0XZ6/MuT1090mBJyCm0dioicG0FUH8+MGyLTqP+nYq IyVdMLTgt8XY1zQxiP511sXRlHUDn1pVcPFiSoiWAKhUN562dVawWHlfp5pIWyyTkqHr vDxw== X-Gm-Message-State: AOJu0YxdkXzBi2EIjYpHI4DhoaSsZmnzqAA3T7Vrw8brHNHogG7lOUlc dBFWtdOmBVbzZcvDccx8WlAwq6QmBuarEV3jVx9bOzaw21DUc7YPDR0YMm/U2tGN5qPk326NlQC zbY9vxbsv32bAsaEei8TZinedk9s= X-Gm-Gg: ASbGncvu3Cyk16nNQczXOMt/EcEpGKQZHM5+AgeDNg3HInDaFqmo+ikPD2fsxNLdcwT ciEuMvmQY18USWA3QxNRCJruFpVYGE/8rR3Iw0zIGWft/2F8+/27Pc7IQ2yX2G3mSndoemLb7KC 6pK6tot2CP0cMAXc8FWJYtdJDrg5wF X-Google-Smtp-Source: AGHT+IEc5Ig2+msWCsVROLrEBhAg9cyWMIaJqZxru2pRqQ02kwF100a4/x/5Xm0f4/mqKMnK4lUCjRM2ej01v9AbENA= X-Received: by 2002:a05:6402:348a:b0:5dc:929a:a726 with SMTP id 4fb4d7f45d1cf-5e4d6b70f43mr10727621a12.26.1740936261333; Sun, 02 Mar 2025 09:24:21 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 2 Mar 2025 09:24:21 -0800 From: Stefan Kangas In-Reply-To: <86wmd7mlxx.fsf@gnu.org> References: <86wmd7mlxx.fsf@gnu.org> MIME-Version: 1.0 Date: Sun, 2 Mar 2025 09:24:21 -0800 X-Gm-Features: AQ5f1JrlfaByS1_w_U6JbpLkzEw5MmAziiXEYzZn6IqdtxLbWpi9bv3eVJ87OlA Message-ID: Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help To: Eli Zaretskii , Daniel Colascione Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Daniel Colascione >> Date: Sun, 02 Mar 2025 10:49:15 -0500 >> >> >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the help >> buffer, and type C-h m again. You'll get prompted about whether you >> want to apply the hi-lock patterns in the help buffer. And then, >> because for some reason we don't actually clear the help buffer but just >> narrow it to what we want, the next time you ask for help, even on >> something unrelated to hi-lock (e.g. progn), hi-lock will ask you >> whether you want to apply hi-lock patterns. > > That's the default of hi-lock-file-patterns-policy, no? IIUC, hi-lock > asks this question for every file you visit, if it finds the patterns > there. > > Or what am I missing? The default is `ask`, which is documented to mean: If `ask', prompt when patterns found in buffer; if bound to a function, but `(describe-function 'progn)` doesn't describe any patterns. (FWIW, I'm very much not a fan of this default. If the user didn't want them highlighted, she would not have turned on `global-hi-lock-mode`.) From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 12:32:37 2025 Received: (at 76687) by debbugs.gnu.org; 2 Mar 2025 17:32:37 +0000 Received: from localhost ([127.0.0.1]:34371 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tonB7-0001ux-8H for submit@debbugs.gnu.org; Sun, 02 Mar 2025 12:32:37 -0500 Received: from dancol.org ([2600:3c01:e000:3d8::1]:43234) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tonB4-0001ua-4m for 76687@debbugs.gnu.org; Sun, 02 Mar 2025 12:32:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=VyKiGW4/roP2w+tP7Dk8K+usJWfg0DeHtfcQbYiaVIg=; b=o5XdtOeF1pZKMNBlltrNYWra5f Cz5PUG/ZwMKD6CEYgFXBz2WVos47zjb0z6m9pndgI9oy5f8SLIs6yFJXxhn1JdH/QzSYVZSp3UAQf F5HHlcxRAz2a9EVe81NAqlX0GfDUYFsS/yPLJ08nOMHL9msLgMIUmNbPDH3bpwPc8b5JJqJgxI2sJ 92v/GyD56vnTalf1LEsPSD8CEuDUyuPwF2liyJd4R5Wo5d32nOeTdG7ev6HJ38+zzr1CoNsPSZQW4 REy+MfUQzs2t3nNOxQmBEtIuGQ3TlFy0ZuOvWvwazKraHHHV446H2SPYJODlA5lMPGX5SbLRAKXYI mwbn37tw==; Received: from dancol by dancol.org with local (Exim 4.96) (envelope-from ) id 1tonAu-001d8h-28; Sun, 02 Mar 2025 12:32:24 -0500 From: Daniel Colascione To: Stefan Kangas Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help In-Reply-To: References: <86wmd7mlxx.fsf@gnu.org> User-Agent: mu4e 1.12.8; emacs 31.0.50 Date: Sun, 02 Mar 2025 12:32:32 -0500 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: Eli Zaretskii , 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stefan Kangas writes: > Eli Zaretskii writes: > >>> From: Daniel Colascione >>> Date: Sun, 02 Mar 2025 10:49:15 -0500 >>> >>> >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the help >>> buffer, and type C-h m again. You'll get prompted about whether you >>> want to apply the hi-lock patterns in the help buffer. And then, >>> because for some reason we don't actually clear the help buffer but just >>> narrow it to what we want, the next time you ask for help, even on >>> something unrelated to hi-lock (e.g. progn), hi-lock will ask you >>> whether you want to apply hi-lock patterns. >> >> That's the default of hi-lock-file-patterns-policy, no? IIUC, hi-lock >> asks this question for every file you visit, if it finds the patterns >> there. >> >> Or what am I missing? > > The default is `ask`, which is documented to mean: > > If `ask', prompt when patterns found in buffer; if bound to a > function, > > but `(describe-function 'progn)` doesn't describe any patterns. > > (FWIW, I'm very much not a fan of this default. If the user didn't want > them highlighted, she would not have turned on `global-hi-lock-mode`.) Isn't the idea that hi-lock patterns can contain arbitrary font lock keywords which can run arbitrary code? From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 02 13:56:59 2025 Received: (at 76687) by debbugs.gnu.org; 2 Mar 2025 18:56:59 +0000 Received: from localhost ([127.0.0.1]:35364 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tooUj-0007yT-Fn for submit@debbugs.gnu.org; Sun, 02 Mar 2025 13:56:59 -0500 Received: from mail-vk1-xa2a.google.com ([2607:f8b0:4864:20::a2a]:53401) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tooUg-0007xZ-6T for 76687@debbugs.gnu.org; Sun, 02 Mar 2025 13:56:55 -0500 Received: by mail-vk1-xa2a.google.com with SMTP id 71dfb90a1353d-5238a2fd2b0so142243e0c.2 for <76687@debbugs.gnu.org>; Sun, 02 Mar 2025 10:56:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1740941808; x=1741546608; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=tc2amu6IUghbOd2ink/XBrIsLozdY8sa4ktAy5iqVzI=; b=mfrAn6NgufDO95RfwcKBasCeuik6TG3lhZyhw50thm5Fb/gf8YF/+nPyq9NkJU0+2Z /Wz8ogOQ95dGpnFqoFHRA9BoJqFuzA2lFry5TG8rtORMpC6zt/1pKyJk8OwrDughk6GB J+bTlAY4JsPbrzYJlpP0faVlgQAvwSwA+RMmaM5kvtCLbDicLzvJrNECWEIGtUEvBfLv l4ULpVedXjA4QrvdohC6p6LJaVEKezYMduKtNPL1G0lHnLYMGy9GOYr5tZTIjbdubuea klrwReduJPFBAd1WDgJ6CVtdphUc1dzu51Wmg3CYBexGx2a3YACcXdSwiy5eDN61FUYP FPIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1740941808; x=1741546608; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=tc2amu6IUghbOd2ink/XBrIsLozdY8sa4ktAy5iqVzI=; b=hhWxQ3PSigrB16T1ZnYsn37WZxzdAaYs1mRf+kKUF/C9rZ6XkWFZPRCI2KohIDC91o 4+7msZtu+On+Ge74CDzriXYOeEBRKDjTR8qyx7S2kFMdPu7QhkyP222rb4Jkd0h4P5yn 7OQI9zWEl1i3SEeGkiX5nZUe4bCHfB6X+5XIFB2WB3scXDKXNF4xOuWK6lJwRnxX+5Hn VfD7UB3ZNUxTTfsu2O9TpY4pPFNpGKbkvJ8n/brJcKsRGbgGGqvaty6YR3KJpq1vBpFt ts8PTcldthEOGy2md4Tb8kZUYeFkiMHpG+Dy3r0rqEtmds4HLB7WT14zrFBt9L8HZ7gJ ibMQ== X-Forwarded-Encrypted: i=1; AJvYcCU3lv9dbNFA77MWxTINI2ihffq+nOox/NVhdim74gSCBrVH8gYtzRouyMFXh0i54vqz3WcojQ==@debbugs.gnu.org X-Gm-Message-State: AOJu0YxuLZ1Co1OaZ7J+gtiVBzirwu7LUdAzS1MxrYSclwzwk/jIIhru i+q/9+RzvmSPRu4/xT2bs7nmoAEY8TBali6AwY0Fc9K60JNJ8q9grZULm10wGFcXTNAa995GVBR 6SoW3m+U44PM2F93CS+hnu/48hrA= X-Gm-Gg: ASbGncs4+LJXaNYLUlO3U/2KKAKElqlmSDbOlI0FsJE2AZC9DHU0lm3EWfBwkUOYucA caMXgqQgBkxVuBjUAA8FWVmrmgF4qNAdD5l7+OCtC9VbIPHhlpVU9g2bK/2qO+9VSY2nbtXzCtR n0dExCruDD7/lbmtkaxpSjIhG5qg== X-Google-Smtp-Source: AGHT+IFdt7YzJGd8pYXYTXiPikFqrceWetiCFe7R7aEgK1Ke+BUc1ANMyrD0THfxYgPbPlT3XygcZ9GNofJKKGhDWNI= X-Received: by 2002:a05:6102:918:b0:4c1:9536:523c with SMTP id ada2fe7eead31-4c195365578mr881132137.24.1740941808399; Sun, 02 Mar 2025 10:56:48 -0800 (PST) MIME-Version: 1.0 References: <86wmd7mlxx.fsf@gnu.org> In-Reply-To: From: Ship Mints Date: Sun, 2 Mar 2025 13:56:37 -0500 X-Gm-Features: AQ5f1JpKLIodvGvlaBV5P2MQyrgwJowaBanZQA7YWFDPjNg9wjbOya5Mkhtt_Rg Message-ID: Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help To: Daniel Colascione Content-Type: multipart/alternative; boundary="000000000000107deb062f609ad3" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: Eli Zaretskii , Stefan Kangas , 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --000000000000107deb062f609ad3 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Perhaps as simple as adding help modes to hi-lock-exclude-modes? It looks like hi-lock mode exclusion logic might need a little improvement to honor derived modes. On Sun, Mar 2, 2025 at 12:33=E2=80=AFPM Daniel Colascione wrote: > Stefan Kangas writes: > > > Eli Zaretskii writes: > > > >>> From: Daniel Colascione > >>> Date: Sun, 02 Mar 2025 10:49:15 -0500 > >>> > >>> >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then quit the he= lp > >>> buffer, and type C-h m again. You'll get prompted about whether you > >>> want to apply the hi-lock patterns in the help buffer. And then, > >>> because for some reason we don't actually clear the help buffer but > just > >>> narrow it to what we want, the next time you ask for help, even on > >>> something unrelated to hi-lock (e.g. progn), hi-lock will ask you > >>> whether you want to apply hi-lock patterns. > >> > >> That's the default of hi-lock-file-patterns-policy, no? IIUC, hi-lock > >> asks this question for every file you visit, if it finds the patterns > >> there. > >> > >> Or what am I missing? > > > > The default is `ask`, which is documented to mean: > > > > If `ask', prompt when patterns found in buffer; if bound to a > > function, > > > > but `(describe-function 'progn)` doesn't describe any patterns. > > > > (FWIW, I'm very much not a fan of this default. If the user didn't wan= t > > them highlighted, she would not have turned on `global-hi-lock-mode`.) > > Isn't the idea that hi-lock patterns can contain arbitrary font lock > keywords which can run arbitrary code? > > > > --000000000000107deb062f609ad3 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Perhaps as simple as adding help modes to=C2=A0hi-lock-exclude-modes?=C2= =A0 It looks like hi-lock mode exclusion logic might need a little improvem= ent to honor derived modes.

On Sun, Mar 2, 2025 = at 12:33=E2=80=AFPM Daniel Colascione <dancol@dancol.org> wrote:
Stefan Kangas <stefankangas@gmail.com> writes:

> Eli Zaretskii <el= iz@gnu.org> writes:
>
>>> From: Daniel Colascione <dancol@dancol.org>
>>> Date: Sun, 02 Mar 2025 10:49:15 -0500
>>>
>>> >From emacs -Q, M-x global-hi-lock-mode, then C-h m, then q= uit the help
>>> buffer, and type C-h m again.=C2=A0 You'll get prompted ab= out whether you
>>> want to apply the hi-lock patterns in the help buffer.=C2=A0 A= nd then,
>>> because for some reason we don't actually clear the help b= uffer but just
>>> narrow it to what we want, the next time you ask for help, eve= n on
>>> something unrelated to hi-lock (e.g. progn), hi-lock will ask = you
>>> whether you want to apply hi-lock patterns.
>>
>> That's the default of hi-lock-file-patterns-policy, no?=C2=A0 = IIUC, hi-lock
>> asks this question for every file you visit, if it finds the patte= rns
>> there.
>>
>> Or what am I missing?
>
> The default is `ask`, which is documented to mean:
>
>=C2=A0 =C2=A0 =C2=A0If `ask', prompt when patterns found in buffer;= if bound to a
>=C2=A0 =C2=A0 =C2=A0function,
>
> but `(describe-function 'progn)` doesn't describe any patterns= .
>
> (FWIW, I'm very much not a fan of this default.=C2=A0 If the user = didn't want
> them highlighted, she would not have turned on `global-hi-lock-mode`.)=

Isn't the idea that hi-lock patterns can contain arbitrary font lock keywords which can run arbitrary code?



--000000000000107deb062f609ad3-- From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 07:51:00 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 12:51:00 +0000 Received: from localhost ([127.0.0.1]:45895 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp5G7-00086U-Al for submit@debbugs.gnu.org; Mon, 03 Mar 2025 07:51:00 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:56352) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tp5G4-00085r-Ne for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 07:50:57 -0500 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 1tp5Fz-0002Zm-6g; Mon, 03 Mar 2025 07:50:51 -0500 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=BCpkc2m6ok0eBUZLx5ZUw5UJ4SnkbcgmpZDPdlyf3wY=; b=ptovxHWpM8R8 JzELIn+4yz1DguFjgVyak6zncGmzFPnEpwbmsU4XC9OhHFHwMQfi89dKD3K6hu2C6KgOhYuArQXOx uz0R8r6nyRCR1eR2pe/2nadGqGSzIGxNl/YrFs/CBipm5NDHsA5lqJeeQpSUwqz3RgW04QA0UTK51 kCmvVPXsrnHEPaJiiYY1BBCNYXK9IjQc9EBYVJ86Ox8COBu3fRBq1ST4tMVcaVltjKYm7fSMTS+9P /mJzJbSza4OLa8uQYbGp8ii0Ym7Ag+q7fCt0suLVyizpvU7p0iikBBSf3DJuTpIHZ4m5/xkjB3vel LlE2ibe1mt5fMi9kH6XO6g==; Date: Mon, 03 Mar 2025 14:50:40 +0200 Message-Id: <86h64amg67.fsf@gnu.org> From: Eli Zaretskii To: Ship Mints In-Reply-To: (message from Ship Mints on Sun, 2 Mar 2025 13:56:37 -0500) Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help References: <86wmd7mlxx.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, stefankangas@gmail.com, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ship Mints > Date: Sun, 2 Mar 2025 13:56:37 -0500 > Cc: Stefan Kangas , Eli Zaretskii , 76687@debbugs.gnu.org > > Perhaps as simple as adding help modes to hi-lock-exclude-modes? It looks like hi-lock mode exclusion > logic might need a little improvement to honor derived modes. Any reason why Help mode should be exempt from global-hi-lock-mode? This bug report shows a single instance of that mode which perhaps needs to be fixed, so why disable the mode for all of the Help buffers? From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 08:10:14 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 13:10:14 +0000 Received: from localhost ([127.0.0.1]:46081 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp5Yj-0000rc-MC for submit@debbugs.gnu.org; Mon, 03 Mar 2025 08:10:14 -0500 Received: from mail-vk1-xa31.google.com ([2607:f8b0:4864:20::a31]:53273) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tp5Ye-0000lZ-NK for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 08:10:10 -0500 Received: by mail-vk1-xa31.google.com with SMTP id 71dfb90a1353d-5238a2fd2b0so449298e0c.2 for <76687@debbugs.gnu.org>; Mon, 03 Mar 2025 05:10:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1741007403; x=1741612203; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=iWoIHRe+k0nSunwERRfx6ByWgjdrhc6VBU5+5tpMm8Y=; b=TykP5jB2bi23C3VK8Ua+v7eFYyQGZ0ss8QgGOAM0n5tzl6XAaUUpZezN5zn3fIHQ+k r7a64l7BRaV4mX2EMpbssmVgnu9N3XUNDaBgBCVae5TAJnbuhqriqiy+ob5+tT6fCAwf Rd9NTdAwlxqrdwN6doeY5ztrvYzQ1yOWGPbfIrCrXsCNm7iSqkAdujwIi7DDnE0jFST1 HTr0PesUROSSjZpy5TfrHAAphjuuz5gZy6snhuGVgb2ag7l3WKJ2aepIpuz2NNc2X1S7 zIyS0HbmlIn9shoQkLe34eDki6LPEhKX+M4smNoxcZL+zJJI/4pom/eRv0Gvgu9CIZMK z3ng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1741007403; x=1741612203; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=iWoIHRe+k0nSunwERRfx6ByWgjdrhc6VBU5+5tpMm8Y=; b=BTy8W4vR+ZHbNEHKEcwxpKxFmO4qRuWITOifPqMnHLf5mi82puoShAbm+a1+zDMp0L KsnfUY5YWYMnwM6M8Ad19RdZ4bPyZ9WLBZsUv1pmcX9TuxLVOmpX95dcMLNMLURpZmU3 cxUH72Z4X0qOTEAayC91ULTn1qYZZ92nQgFfV4lHN8bz1vg+4NlNqCUuqu3GY4J+HGIk kVFiNYuKEdObBUjqYzCC4IOg+0wCYxPfmIO4JwBwmD0lfWvrJQ64bJYviEw1ByMGg9s7 vMtQfpG8L9jY8ahquiYI15bt6V9suzRix7sqG3bMNfbNmug9D8aAIAllNcCuy6B1HqLt hu6Q== X-Forwarded-Encrypted: i=1; AJvYcCUP3KsJgT42gfBe84tSRny2TEipmKDEW5Lbat5B//gXg3F6hLkZez/GhWDt0d0KE1Jh82aupQ==@debbugs.gnu.org X-Gm-Message-State: AOJu0YyJlkRJ8rRy6nPKEAucdTccXd7KYMJsQhS4FAqbKm3ZMaaQpS6T 9dORf+FLhtaSS87rWk2oWm/JMlfDozbHUhXHZA6eNGzAO3/Vu0ZU1XlIliOll0BdGU4LYjK769I /kb7NG4CUQqkVoXUIJzmP6JmScxU= X-Gm-Gg: ASbGncsdubkukAyE9EpQ35/wzgpwoeLtT2ME0NRPAdI5SLCf5FB3tQ1yY3xftgZwl/H cmHnx3xm2PFF+j1X4reV3GJvMt9hqdEZLG3fRFBSasgP/1qvUoBY3/KQsSU8Lss+UvJTZkz+OdP faIKbkxFEMUpi7onwXn64eCfy2hg== X-Google-Smtp-Source: AGHT+IHzhAkBtIjt+eSgyEKD5Xav0EqbNuwsB1M01d6dJz6QPHMYru3nNToMHTb5iNBo+A0Tk4F15KNMXcyg7aL/syM= X-Received: by 2002:a05:6122:2897:b0:520:3987:ce0b with SMTP id 71dfb90a1353d-5235b519bf9mr8110813e0c.2.1741007402760; Mon, 03 Mar 2025 05:10:02 -0800 (PST) MIME-Version: 1.0 References: <86wmd7mlxx.fsf@gnu.org> <86h64amg67.fsf@gnu.org> In-Reply-To: <86h64amg67.fsf@gnu.org> From: Ship Mints Date: Mon, 3 Mar 2025 08:09:51 -0500 X-Gm-Features: AQ5f1JqJHBGnNBJGR7wMSkjRCI7Lm2wMHv33S80je8SmnhIJIW1FQSWYCcr9-8c Message-ID: Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help To: Eli Zaretskii Content-Type: multipart/alternative; boundary="000000000000cb03e9062f6fdffe" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, stefankangas@gmail.com, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --000000000000cb03e9062f6fdffe Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Daniel can put help modes into the exclude list if this solves his problem, even if imperfect. On Mon, Mar 3, 2025 at 7:50=E2=80=AFAM Eli Zaretskii wrote: > > From: Ship Mints > > Date: Sun, 2 Mar 2025 13:56:37 -0500 > > Cc: Stefan Kangas , Eli Zaretskii , > 76687@debbugs.gnu.org > > > > Perhaps as simple as adding help modes to hi-lock-exclude-modes? It > looks like hi-lock mode exclusion > > logic might need a little improvement to honor derived modes. > > Any reason why Help mode should be exempt from global-hi-lock-mode? > This bug report shows a single instance of that mode which perhaps > needs to be fixed, so why disable the mode for all of the Help > buffers? > --000000000000cb03e9062f6fdffe Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Daniel can put help modes into the exclude list if this solves his probl= em, even if imperfect.

On Mon, Mar 3, 2025 at 7:= 50=E2=80=AFAM Eli Zaretskii <eliz@gnu.or= g> wrote:
> From: Ship Mints <shipmints@gmail.com>
> Date: Sun, 2 Mar 2025 13:56:37 -0500
> Cc: Stefan Kangas <stefankangas@gmail.com>, Eli Zaretskii <eliz@gnu.org>, 76687@debbugs.gnu.org
>
> Perhaps as simple as adding help modes to hi-lock-exclude-modes?=C2=A0= It looks like hi-lock mode exclusion
> logic might need a little improvement to honor derived modes.

Any reason why Help mode should be exempt from global-hi-lock-mode?
This bug report shows a single instance of that mode which perhaps
needs to be fixed, so why disable the mode for all of the Help
buffers?
--000000000000cb03e9062f6fdffe-- From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 08:39:49 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 13:39:49 +0000 Received: from localhost ([127.0.0.1]:46323 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp61M-0003HA-FO for submit@debbugs.gnu.org; Mon, 03 Mar 2025 08:39:49 -0500 Received: from mail-ed1-x535.google.com ([2a00:1450:4864:20::535]:49469) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tp61J-0003GU-LS for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 08:39:46 -0500 Received: by mail-ed1-x535.google.com with SMTP id 4fb4d7f45d1cf-5e058ca6806so7170444a12.3 for <76687@debbugs.gnu.org>; Mon, 03 Mar 2025 05:39:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1741009179; x=1741613979; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=SZkLF5vTi6OYKzoQjcVmCRORnFSsPpeM1LtDZfeV2lE=; b=h1S8FQFW6772XP1i9f/fuAqOeCeCIH/p6blbcs+/Wgb5jlTqppyRIBXq0r7EuKCtid ut+rFva01BvqlKBMEQJ059UKurlKOra3k2/rWkm4pG9PUVuRKamdDzvk0e83WY45Htpp xGR6LGQxita8XpUy4MisgKmA3/6MS2ovMFhjBO6JMHp313wa7aZdM90S6stNFWoFgavV lKExubFFqfAG7FjmQjZ09hOJjZMZulXd32icvq360todggjCP99Vhrd8SHjFXHUJKG6m MHRm7aps5sGFJPb7LH/0dyF7eD+u4Zmdf7fqdN3uLDHPJiMmV4AL27+5QloiCuCXIqDA I4Ig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1741009179; x=1741613979; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=SZkLF5vTi6OYKzoQjcVmCRORnFSsPpeM1LtDZfeV2lE=; b=lpi4zSeywjtbI6W9xIdIq/SRbZ0RAZa1t6mcGWZ495uaTn04rJN1FqhkUcac//uihL HA1T3tfYFmI2Lv//AptQZXmy6MXQPRf3XFz+H7hZvVQhY+G934WkErMnlNR1h0qvKEGZ SskBEb2wkwtnmbfa8B1FluLjfJiRcdjJpjaS0m8OjwXfMVYXkwJowdkI+Uxen2yGCJWj fxwvuwYdye3LS4+SrpW3NE2O0ugNRm9u38Jn0v6lzF04peNYK0WLzkWPIFYsXeNea3rk XHjLStY79DTO7VhME+4CcGuv3SSrQtOlGRL6O8hGW4HEn0fTGNeW12h/zEWhivw21gT8 Kwpg== X-Forwarded-Encrypted: i=1; AJvYcCXYhqAq+7Ijsh0JS7ZNRgr3BzG2r2aTtFZoENKqsoPEpFyuH+gAI3N9ljKIAISWTw6bbKY8KQ==@debbugs.gnu.org X-Gm-Message-State: AOJu0YwYqlSnoX746GTqk/EHaYpduJy2k9vvChiW5fyt06ymO9/muwo1 gUQ9hqbOPTaMFc+qlrKwXNwWq2d3H3RY6mmF/j4NaRUHWczrSaQyLd1xsOlXlBUj67Iu062UUiC +M25NJgL9u3M0Oiy7DR2emC1DSDo= X-Gm-Gg: ASbGncv1tT48xaCvukcD6YSh88RdLfj3WM1IMJjVkGMKMYxQMeX8qQJMSIBJaMTS1HO /uPB4b/44ogHDg3OCjwm446tJoshBE/si6leMXrRU7nLxbrgfcGjEJra8jZdW/6WYpv4Wv3j4L+ QPPClyc8XA9cFh9SdZ8RdWN46iyQ== X-Google-Smtp-Source: AGHT+IEYBl88gSawtCl2fkz+Z/rLXeGg4+JJgGdTmzndQrMzjyIcsv2ZSuphtZGwdihQmvmTu92Y6FLPxt6pGfwIBp8= X-Received: by 2002:a05:6402:40ce:b0:5e4:97bc:6577 with SMTP id 4fb4d7f45d1cf-5e4d6b6e2d1mr13850556a12.20.1741009179264; Mon, 03 Mar 2025 05:39:39 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Mon, 3 Mar 2025 13:39:38 +0000 From: Stefan Kangas In-Reply-To: <86h64amg67.fsf@gnu.org> References: <86wmd7mlxx.fsf@gnu.org> <86h64amg67.fsf@gnu.org> MIME-Version: 1.0 Date: Mon, 3 Mar 2025 13:39:38 +0000 X-Gm-Features: AQ5f1JoAckSQDHWwp7uZSG0Rk9vFusbbq7N-68hrzn0PBiCuvlFke6dq-NoiD8A Message-ID: Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help To: Eli Zaretskii , Ship Mints Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Ship Mints >> Date: Sun, 2 Mar 2025 13:56:37 -0500 >> Cc: Stefan Kangas , Eli Zaretskii , 76687@debbugs.gnu.org >> >> Perhaps as simple as adding help modes to hi-lock-exclude-modes? It looks like hi-lock mode exclusion >> logic might need a little improvement to honor derived modes. > > Any reason why Help mode should be exempt from global-hi-lock-mode? > This bug report shows a single instance of that mode which perhaps > needs to be fixed, so why disable the mode for all of the Help > buffers? First, isn't the bug here that you get a prompt despite there being no Hi-lock lines? Why would you prompt in that case? Second, and orthogonally, perhaps special-mode should be in hi-lock-exclude modes by default. From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 09:28:52 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 14:28:52 +0000 Received: from localhost ([127.0.0.1]:46813 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp6mp-0007DZ-Bq for submit@debbugs.gnu.org; Mon, 03 Mar 2025 09:28:51 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:41552) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tp6ml-0007DK-Oj for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 09:28:49 -0500 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 1tp6mg-0001Pq-5D; Mon, 03 Mar 2025 09:28:42 -0500 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=l3FzTr0vvIk0gezufQu6+syEX4ZSQ6FFyIuHOWTjLK8=; b=B88Nd8XqP0Qg p2hJKTqweUZ/ohqNQsAeQnfghLaoU3DnbVFKNmmKG8n+4EhoBqwFEgZlnlOTKz2tnMz7OvxYDrm1W BMJ/QmIflwDMI8Spow9J4yOtgMUhHUo6jDyW+TT5eDi0Px7e0O7clur91nuUdb1PP5eZntNwIre8S xnhg92CoUerO11oVStc8VSPytftPtYJ7qbKwr97slh6gkJpDscx36oLf0Uv7jl61e1ubB3WByJE0u GFEHRkrvdTCjz4SvV2tK25fwxUKr2p3xuO2N9vzxmrxGavZoGeXw15j+uUW9+idiR+/7ueXy18AQd nq0VH1iEjgVGTuUAB67bvg==; Date: Mon, 03 Mar 2025 16:28:39 +0200 Message-Id: <86r03ekx2g.fsf@gnu.org> From: Eli Zaretskii To: Stefan Kangas In-Reply-To: (message from Stefan Kangas on Mon, 3 Mar 2025 13:39:38 +0000) Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help References: <86wmd7mlxx.fsf@gnu.org> <86h64amg67.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, shipmints@gmail.com, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stefan Kangas > Date: Mon, 3 Mar 2025 13:39:38 +0000 > Cc: dancol@dancol.org, 76687@debbugs.gnu.org > > Eli Zaretskii writes: > > >> From: Ship Mints > >> Date: Sun, 2 Mar 2025 13:56:37 -0500 > >> Cc: Stefan Kangas , Eli Zaretskii , 76687@debbugs.gnu.org > >> > >> Perhaps as simple as adding help modes to hi-lock-exclude-modes? It looks like hi-lock mode exclusion > >> logic might need a little improvement to honor derived modes. > > > > Any reason why Help mode should be exempt from global-hi-lock-mode? > > This bug report shows a single instance of that mode which perhaps > > needs to be fixed, so why disable the mode for all of the Help > > buffers? > > First, isn't the bug here that you get a prompt despite there being no > Hi-lock lines? Why would you prompt in that case? I understood that there _are_ Hi-lock lines in that buffer. > Second, and orthogonally, perhaps special-mode should be in > hi-lock-exclude modes by default. Again, I find no reasons to exclude special-mode. People may wish to highlight a regexp everywhere. From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 09:55:09 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 14:55:09 +0000 Received: from localhost ([127.0.0.1]:47068 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp7CG-0000qX-Eh for submit@debbugs.gnu.org; Mon, 03 Mar 2025 09:55:08 -0500 Received: from mail-ed1-x52a.google.com ([2a00:1450:4864:20::52a]:52383) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tp7CC-0000lC-4V for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 09:55:06 -0500 Received: by mail-ed1-x52a.google.com with SMTP id 4fb4d7f45d1cf-5e539ea490dso1748186a12.0 for <76687@debbugs.gnu.org>; Mon, 03 Mar 2025 06:55:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1741013698; x=1741618498; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:from:to:cc:subject:date:message-id:reply-to; bh=8zJq2Hp3A0KmQpu//EDRVqWoXlO46Zs9pPIJKTcWpuM=; b=BDuoaPW/dalQ3otxD44NkNiSy1RAMzdEAFMDxmEPUblUu+6Sy4WN7oaNEWjXbttAbI 0HI/Y88XwRr05dBE3QXJ97qzesdj9GAToEf4CS3urKBz6hPdJy0x2YJykotqbI7Z/mdv 9ZJwMTc4OLWBEK9DnyKhox09d9yrUvrG3zS0rCN4qM4JkRmR83O4BQVJEXJbbORe3ks5 XZXs4MAAcjJUfjGRgKvxYXka2KV4Oy9qcN8Q635NqDgXDKhU3fZO0O/ILsJZ8RsrHfiK Zi6rdIgKlJrvUgzyc4pHXoTLwAgr0FU/XHnvZGvWMs1oYXJNwIJFy32TsLcvpF2Nj5C7 Kyzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1741013698; x=1741618498; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=8zJq2Hp3A0KmQpu//EDRVqWoXlO46Zs9pPIJKTcWpuM=; b=DWpP/ti2nDDf9viqXsaRD51rSD61/aNjI5BO3jEffQs8jPw6MfHaAEZ9x9qZHZEDtq V01qeYs5vq62KvY+0YtF2BdlUtopHUHFMBIw+24p4fdmOR+YVvNGM0vBYZ4o1ldqaaZM KWkVLGlXk/eI+H/FWKLFPVaqAqRJSmDm3Bg6smJhTce2wLJy1/En3OW9X+Nqb/6FP9ZN 2aGC8b/3SsvKk66syKkqqxctnftZO0I/1oBrKvaX9Y8HQEYhTUgmHwTXO5uzLl7HWlBh hq32tXRVPVICRgHg7isyHIKyaBj6bGG7O2UxxxZySvf08Wwo3jmHemSpJEozkWLEbkXq VDGg== X-Forwarded-Encrypted: i=1; AJvYcCU6NgfxoMvuQjPix15pOhBX1vTSJpiFPqEe2Bbf+z5dv3N4qLmPc1TR8dEf4CcfK4D4IUkONQ==@debbugs.gnu.org X-Gm-Message-State: AOJu0YyYA+hixKkjD69isLC3AD9/u+tICn8irzpeTLBicU5g003uG/V+ s5g+xEHZ60kASt6uaTtJhlckkVqcdKqgyxY2Yd5vixY0xGHAE4VvkfCXzaogk/cTrpUtGK5H5/z BklmSiNbV0n1chuq1hTehf1tcUhQ= X-Gm-Gg: ASbGnct9SEknIrhk37Y/wIIJTcblpyFANATSov7IdDW88a6F9o+bKccD7JIPi92jM7f gkVqBWyf/Z8RTYIlp2kqug5Fivn0OfJuxXtfnO83AP+HJ3Aq8E8xsysxLUI+bA2ZZxrW7+fo6Jf 6gqcK1bqnz18Fs0lcJGEjeYaDbJw== X-Google-Smtp-Source: AGHT+IF7IRyjYqj5XdfyF6yz+qHmbgYfBHWgjeAMzZIvkzKXLYFRYsIHCiaknPoINrAS+Oxl7+MJ3/jNmvoaC3RE9QU= X-Received: by 2002:a05:6402:2714:b0:5e0:922e:527a with SMTP id 4fb4d7f45d1cf-5e4d6908f02mr38472528a12.0.1741013697657; Mon, 03 Mar 2025 06:54:57 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Mon, 3 Mar 2025 06:54:56 -0800 From: Stefan Kangas In-Reply-To: <86r03ekx2g.fsf@gnu.org> References: <86wmd7mlxx.fsf@gnu.org> <86h64amg67.fsf@gnu.org> <86r03ekx2g.fsf@gnu.org> MIME-Version: 1.0 Date: Mon, 3 Mar 2025 06:54:56 -0800 X-Gm-Features: AQ5f1JrvuHIVdGQK5chAVJAG_9hRloOOPERBbps0QCDfp9raKukC5g3K4dvu1Xg Message-ID: Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help To: Eli Zaretskii Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, shipmints@gmail.com, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> From: Stefan Kangas >> Date: Mon, 3 Mar 2025 13:39:38 +0000 >> Cc: dancol@dancol.org, 76687@debbugs.gnu.org >> >> Eli Zaretskii writes: >> >> >> From: Ship Mints >> >> Date: Sun, 2 Mar 2025 13:56:37 -0500 >> >> Cc: Stefan Kangas , Eli Zaretskii , 76687@debbugs.gnu.org >> >> >> >> Perhaps as simple as adding help modes to hi-lock-exclude-modes? It looks like hi-lock mode exclusion >> >> logic might need a little improvement to honor derived modes. >> > >> > Any reason why Help mode should be exempt from global-hi-lock-mode? >> > This bug report shows a single instance of that mode which perhaps >> > needs to be fixed, so why disable the mode for all of the Help >> > buffers? >> >> First, isn't the bug here that you get a prompt despite there being no >> Hi-lock lines? Why would you prompt in that case? > > I understood that there _are_ Hi-lock lines in that buffer. Right, so more precisely there are two bugs: 1. We incorrectly treat the examples from the hi-lock-mode docstring as highlighting patterns in the *Help* buffer. 2. We incorrectly consider the examples from the hi-lock-mode docstring, when looking at _other_ docstrings, after having looked at that one. I think adding help-mode to `hi-lock-exclude` would solve both bugs, however see below. >> Second, and orthogonally, perhaps special-mode should be in >> hi-lock-exclude modes by default. > > Again, I find no reasons to exclude special-mode. People may wish to > highlight a regexp everywhere. That's true. The issue is that `hi-lock-exclude-modes' disables all highlighting, even when manually added. That is undesirable, I agree. This suggests that we need a more fine-grained control that disables only the "Hi-lock:" pattern handling (i.e. only the unsafe part). From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 03 10:38:12 2025 Received: (at 76687) by debbugs.gnu.org; 3 Mar 2025 15:38:12 +0000 Received: from localhost ([127.0.0.1]:50179 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tp7rv-0004yu-T9 for submit@debbugs.gnu.org; Mon, 03 Mar 2025 10:38:12 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:57140) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tp7rt-0004yR-Lx for 76687@debbugs.gnu.org; Mon, 03 Mar 2025 10:38:10 -0500 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 1tp7ro-0006iI-20; Mon, 03 Mar 2025 10:38:04 -0500 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=lM5j04t5MWWAx63QP0of1SBs/0EYSmQMNVzpqZBxoCw=; b=AzL9y5RDXwpH hRgdPzJ4/ynhurpK5+QhXyBTu+TMXqlkOpn2KpQZJb/LrP1n4PBfWeKfALWjpI5ltpCd2VUL/Ln+H f34aZwQO5pGTgZASnJn/UoNou5EKILiUBFEX07swTWy6rpH6pkQBd5dDH21wG4fjvidid/bMi5aLH uZu3PR5QOuBxJZUbmo7VA63uB7ytF/fNiiFtXfIzm4b1DEz79xWSbR0pG8keFpgPxhrch8O+JOw/3 cqexnX9e7/4PyEpbieDtCXg4PJhg4uQw2lY3ThExd4YV/KRbGMRvpnq43CSm4Z8AVNN49IBSPoq1W j3KHCuO1F32PdI0efe9BnQ==; Date: Mon, 03 Mar 2025 17:37:57 +0200 Message-Id: <86eczektuy.fsf@gnu.org> From: Eli Zaretskii To: Stefan Kangas In-Reply-To: (message from Stefan Kangas on Mon, 3 Mar 2025 06:54:56 -0800) Subject: Re: bug#76687: global-hi-lock-mode prompts on its own help References: <86wmd7mlxx.fsf@gnu.org> <86h64amg67.fsf@gnu.org> <86r03ekx2g.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 76687 Cc: dancol@dancol.org, shipmints@gmail.com, 76687@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stefan Kangas > Date: Mon, 3 Mar 2025 06:54:56 -0800 > Cc: shipmints@gmail.com, dancol@dancol.org, 76687@debbugs.gnu.org > > Eli Zaretskii writes: > > > Again, I find no reasons to exclude special-mode. People may wish to > > highlight a regexp everywhere. > > That's true. The issue is that `hi-lock-exclude-modes' disables all > highlighting, even when manually added. That is undesirable, I agree. > > This suggests that we need a more fine-grained control that disables > only the "Hi-lock:" pattern handling (i.e. only the unsafe part). Yes, and only in a *Help* buffer that shows this hi-lock variable itself. Maybe we should format the example in some very special way or something like that.