From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.devel Subject: Re: Unsafe local variable in eglot.el Date: Thu, 9 Mar 2023 11:24:37 +0000 Message-ID: References: <83mt4m2w23.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11680"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Mar 09 12:25:23 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 1paEOh-0002ry-MG for ged-emacs-devel@m.gmane-mx.org; Thu, 09 Mar 2023 12:25:23 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1paEOF-0007rx-AD; Thu, 09 Mar 2023 06:24:55 -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 1paEOC-0007rV-Af for emacs-devel@gnu.org; Thu, 09 Mar 2023 06:24:52 -0500 Original-Received: from mail-oa1-x2b.google.com ([2001:4860:4864:20::2b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1paEOA-0002QJ-Fr; Thu, 09 Mar 2023 06:24:51 -0500 Original-Received: by mail-oa1-x2b.google.com with SMTP id 586e51a60fabf-17711f56136so1896843fac.12; Thu, 09 Mar 2023 03:24:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678361089; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=wie7a6Yib/FUy/ksP8cKIxthfKCBsPRTCsKXh3TCLig=; b=OiE3T3PlN1Ok7f0ZvubnH1Mrm1etkhQGGEw6Ua2vNrvy/RHgIPgGK7A5eVNZFnN66d ALQClH40CFXgwuKDZf86sVxJRoKo718RXiTtz9qkedoKipwbBKppTjoAWneb6CBV/0iF O/WMurCS5mRw4uLvb8g7yu3O2XVHYR7VfjWEKFD9KoLVLG+483ModmyMo7nFHIZT/7eE uCpiEqGZLP6NQ2XhWhRpyMTcDZocg5Y+6/URsgcDN4I6Sqw6wOzL5JDYWxpeDsB4vvcY SuWbZPrBgFqQF3ro1f68UqflGRzMjtwnC0G+HtMs0lqksbz4DpyaBVdrXq3mj7hLj+/T n1UQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678361089; h=content-transfer-encoding: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=wie7a6Yib/FUy/ksP8cKIxthfKCBsPRTCsKXh3TCLig=; b=28k4E2QzxooSsx0FkySe2J3po3BNRxl5LJtjPKIc7ZjtzKVDcK5RCg8mvQNCaHMqTX KLIseXvwMN+czZOxPK3pIzlc6c/IBhsWPGlKawK8WoDnLdDRBqMokqqQkRfJwSvZ/dZv 4B2981+nuAynooL2AkM9NFTHcBw2DyXShTH/3YLyCOaEk0gjSGuDrBSKWCmcqdrMZ45d udlh91ThyjKuFniJf5ScyQNptPaKQwe22yqZHLd8IyDtvxbU6fIqJzZFIo0yzzh9oIhG UtXxAayDnGE3Mo1MIRm/v7iVBFfW1O2PG6oVhyn+OV9mxjqaA58tCYQVFTZLkH8lZPMD 4FGA== X-Gm-Message-State: AO0yUKXxi5dqmVipBSKzaRj6/PRB83lnxcaQ7ztzsTJXrH2dyhudesju awxg+IkNtQz6Ruzebsp8+rmNDIOjGGQzLReFFFGULeojYW4= X-Google-Smtp-Source: AK7set8Re0fOraGHOBhiJJaIApdkj0EuatMkcMCOSEEuN9DT34bhABA52hJJK69ecgXk3htFYVDH3QXDHQMXkqEPpxc= X-Received: by 2002:a05:6870:5b15:b0:16a:1d37:78dd with SMTP id ds21-20020a0568705b1500b0016a1d3778ddmr5881025oab.5.1678361088843; Thu, 09 Mar 2023 03:24:48 -0800 (PST) In-Reply-To: Received-SPF: pass client-ip=2001:4860:4864:20::2b; envelope-from=joaotavora@gmail.com; helo=mail-oa1-x2b.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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:304186 Archived-At: On Thu, Mar 9, 2023 at 9:31=E2=80=AFAM Jo=C3=A3o T=C3=A1vora wrote: > But curiously, this doesn't reproduce it > > src/emacs -Q > C-h f eglot RET > C-x o TAB RET ;; to visit the "eglot.el" link > > Why is that? It's probably because C-h v loads the file to show the docstring (did it always do that?) > > Maybe the function can be autoloaded? I played a bit and this patch seems to fix it. Can you test? diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 2491c86ea5b..94cc86d1e97 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -3666,12 +3666,14 @@ eglot-inlay-hints-mode ;;; Misc ;;; -(defun eglot--debbugs-or-github-bug-uri () - (format (if (string=3D (match-string 2) "github") - "https://github.com/joaotavora/eglot/issues/%s" - "https://debbugs.gnu.org/%s") - (match-string 3))) -(put 'eglot--debbugs-or-github-bug-uri 'bug-reference-url-format t) +;;;###autoload +(progn + (put 'eglot--debbugs-or-github-bug-uri 'bug-reference-url-format t) + (defun eglot--debbugs-or-github-bug-uri () + (format (if (string=3D (match-string 2) "github") + "https://github.com/joaotavora/eglot/issues/%s" + "https://debbugs.gnu.org/%s") + (match-string 3)))) ;;; Obsolete ;;;