From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.bugs Subject: bug#21466: [PATCH] Avoid defining (temporarily) vars and functions Date: Fri, 23 Jul 2021 11:01:03 -0400 Message-ID: References: <87eeeestgu.fsf@gnus.org> <87fsw5cgu6.fsf@gnus.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="28080"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) Cc: Alan Mackenzie , Stefan Monnier , 21466@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jul 23 17:02:10 2021 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 1m6wgk-00076Y-5D for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 23 Jul 2021 17:02:10 +0200 Original-Received: from localhost ([::1]:48196 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6wgj-00086p-3a for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 23 Jul 2021 11:02:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58486) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6wgc-00086N-BL for bug-gnu-emacs@gnu.org; Fri, 23 Jul 2021 11:02:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:60961) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m6wgc-0001v1-2y; Fri, 23 Jul 2021 11:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m6wgc-0003eU-1z; Fri, 23 Jul 2021 11:02:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Glenn Morris Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org, bug-cc-mode@gnu.org Resent-Date: Fri, 23 Jul 2021 15:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21466 X-GNU-PR-Package: emacs,cc-mode X-GNU-PR-Keywords: patch Original-Received: via spool by 21466-submit@debbugs.gnu.org id=B21466.162705247813985 (code B ref 21466); Fri, 23 Jul 2021 15:02:02 +0000 Original-Received: (at 21466) by debbugs.gnu.org; 23 Jul 2021 15:01:18 +0000 Original-Received: from localhost ([127.0.0.1]:44274 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m6wfu-0003dV-In for submit@debbugs.gnu.org; Fri, 23 Jul 2021 11:01:18 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:60548) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m6wft-0003dI-4X for 21466@debbugs.gnu.org; Fri, 23 Jul 2021 11:01:17 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:57710) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6wfm-0001K5-K2; Fri, 23 Jul 2021 11:01:10 -0400 Original-Received: from rgm by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1m6wff-0002Po-Nx; Fri, 23 Jul 2021 11:01:05 -0400 X-Spook: Swine CipherTAC-2000 Montenegro Biological infection X-Ran: 0}X.!1DDyN1Fazc,*`N{X3VQ-z^`/hr;cY (Lars Ingebrigtsen's message of "Fri, 23 Jul 2021 15:14:41 +0200") 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" Xref: news.gmane.io gmane.emacs.bugs:210591 Archived-At: Lars Ingebrigtsen wrote: >> So indeed, a real FILE argument would be preferable, but passing nil >> works fine (it will simply prevent `check-declare` from making sure >> that file indeed defines that function, > > I've now amended the doc string to `declare-function on the trunk to > mention this. Whilst that may happen to work as a kludge, it's against the intent of declare-function, so personally I would prefer that it either remained undocumented, or you do it properly and make FILE an optional argument (I haven't checked if check-declare would need changes for that). Ref: https://lists.gnu.org/r/emacs-devel/2007-11/msg01409.html