From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#57065: 29.0.50; Double evaluation in `c-make-no-parens-syntax-table` Date: Thu, 25 Aug 2022 17:00:56 -0400 Message-ID: References: Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="315"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: 57065-done@debbugs.gnu.org To: Alan Mackenzie Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 25 23:02:42 2022 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 1oRJzu-000AT8-6r for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 25 Aug 2022 23:02:42 +0200 Original-Received: from localhost ([::1]:34336 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oRJzs-0000ey-Jv for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 25 Aug 2022 17:02:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41844) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oRJzG-0000c6-Lx for bug-gnu-emacs@gnu.org; Thu, 25 Aug 2022 17:02:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33489) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oRJzG-0008GN-Cf for bug-gnu-emacs@gnu.org; Thu, 25 Aug 2022 17:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oRJzG-0003uR-7B for bug-gnu-emacs@gnu.org; Thu, 25 Aug 2022 17:02:02 -0400 Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Aug 2022 21:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 57065 X-GNU-PR-Package: emacs Mail-Followup-To: 57065@debbugs.gnu.org, monnier@iro.umontreal.ca, monnier@iro.umontreal.ca Original-Received: via spool by 57065-done@debbugs.gnu.org id=D57065.166146127614966 (code D ref 57065); Thu, 25 Aug 2022 21:02:02 +0000 Original-Received: (at 57065-done) by debbugs.gnu.org; 25 Aug 2022 21:01:16 +0000 Original-Received: from localhost ([127.0.0.1]:51466 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oRJyW-0003tG-1l for submit@debbugs.gnu.org; Thu, 25 Aug 2022 17:01:16 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:34624) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oRJyL-0003sL-IK for 57065-done@debbugs.gnu.org; Thu, 25 Aug 2022 17:01:09 -0400 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id AEBF480740; Thu, 25 Aug 2022 17:00:59 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 0C4198025F; Thu, 25 Aug 2022 17:00:58 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1661461258; bh=HryIrOg+4S2En8EaqDysFUoymVh12B1jtceUqCZ6EEs=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=LLOTplu+5IWDwf2vqVEQiY8cJq0fhr9yEuHziqnW7aKZovIcjesQyY79g4IfiTDUV 3ZKXTeJPdAUEJ94MybFl3aaR5fsURRpr7tdNxwgGm4uirGve9FwGx6F73YC6LQfoGn r4BeMcWjVVthQIYik77XKJkdoDw3uTRCkKWOYmPTp+ye1kKzoAFZfV2YhMH8liRTi9 GvMtPT2Hv4uAoDIlTq4kApCbosR0BRrU7qz3kMfO1z7X1RUgJonvXM+Ay4qVNWUoh0 nAjOzho123nTig3Hev38sd3zg3lTDPi5Wq75Vur7RsTtI3qAP1tCocKoEz1WaYHahy fb2lmpLfHzonA== Original-Received: from alfajor (66-163-28-139.ip.tor.radiant.net [66.163.28.139]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id D526E1202AA; Thu, 25 Aug 2022 17:00:57 -0400 (EDT) In-Reply-To: (Stefan Monnier's message of "Tue, 09 Aug 2022 03:53:53 -0400") 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:240750 Archived-At: Pushed to `master`, closing, Stefan Stefan Monnier [2022-08-09 03:53:53] wrote: > The patch below seems to be necessary to avoid a double-evaluation. > This can be seen if you do something like > > (c-lang-defconst c-make-mode-syntax-table my-lang #'my-fun) > > or > > (c-lang-defconst c-make-mode-syntax-table my-lang (symbol-value 'my-fun)) > > or > > (c-lang-defconst c-make-mode-syntax-table my-lang > (lambda () ..)) > > where you'll get errors like "void-variable `my-fun`" or "void-function > `closure`. > > > Stefan > > > diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el > index c5964165c8d..7826f38ca1a 100644 > --- a/lisp/progmodes/cc-langs.el > +++ b/lisp/progmodes/cc-langs.el > @@ -403,7 +403,7 @@ c-make-no-parens-syntax-table > t (if (c-lang-const c-recognize-<>-arglists) > `(lambda () > ;(if (c-lang-const c-recognize-<>-arglists) > - (let ((table (funcall ,(c-lang-const c-make-mode-syntax-table)))) > + (let ((table (funcall ',(c-lang-const c-make-mode-syntax-table)))) > (modify-syntax-entry ?\( "." table) > (modify-syntax-entry ?\) "." table) > (modify-syntax-entry ?\[ "." table)