From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/67352 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: macro within interactive form isn't expanded Date: Wed, 10 Sep 2008 10:03:57 +0900 Organization: Emacsen advocacy group Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1221008700 5248 80.91.229.12 (10 Sep 2008 01:05:00 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 10 Sep 2008 01:05:00 +0000 (UTC) To: emacs-devel@gnu.org, ding@gnus.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Sep 10 03:05:54 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KdE90-00080f-ES for ged-emacs-devel@m.gmane.org; Wed, 10 Sep 2008 03:05:45 +0200 Original-Received: from localhost ([127.0.0.1]:55671 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KdE7y-0002IU-Am for ged-emacs-devel@m.gmane.org; Tue, 09 Sep 2008 21:04:14 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KdE7s-0002Cu-QR for emacs-devel@gnu.org; Tue, 09 Sep 2008 21:04:08 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KdE7q-00028E-PK for emacs-devel@gnu.org; Tue, 09 Sep 2008 21:04:08 -0400 Original-Received: from [199.232.76.173] (port=35489 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KdE7q-00027m-HU for emacs-devel@gnu.org; Tue, 09 Sep 2008 21:04:06 -0400 Original-Received: from orlando.hostforweb.net ([216.246.45.90]:48581) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KdE7p-0000zR-NI for emacs-devel@gnu.org; Tue, 09 Sep 2008 21:04:06 -0400 Original-Received: from localhost ([127.0.0.1]:58491) by orlando.hostforweb.net with esmtpa (Exim 4.69) (envelope-from ) id 1KdE7k-0008FF-E4; Tue, 09 Sep 2008 20:04:01 -0500 X-Hashcash: 1:20:080910:emacs-devel@gnu.org::ZcWPS0axuKh1Df//:0000000000000000000000000000000000000000001jmd X-Hashcash: 1:20:080910:ding@gnus.org::bT5FGiBXdIoU2I45:00000Prf X-Face: #kKnN,xUnmKia.'[pp`; Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu; B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.0.60 (gnu/linux) Cancel-Lock: sha1:+hqFLc28zG+s12DzoPnu0Y5K9jE= X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - orlando.hostforweb.net X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:103746 gmane.emacs.gnus.general:67352 Archived-At: Hi, (Bcc'd to Iain Dalton) Iain Dalton reported to the list and I confirmed that performing the `gnus-group-make-useful-group' command causes an error as follows: list: Symbol's function definition is void: caddr Note that it is not due to not having compiled gnus-group.el. It happens with the byte compiled Gnus that is distributed with Emacs 22.1, 22,2, and 22.3. So is the one compiled with 23.0.60. The form (caddr X) should be expanded into (car (cdr (cdr X))) when compiling, however I realized today that macros within the `interactive' form will be neither expanded nor compiled. For instance: (defmacro foo (x) x) (byte-compile (lambda (x) (interactive (list (foo x))))) => #[(x) "\300\207" [nil] 1 nil (list (foo x))] (require 'cl) (load "cl-macs") (byte-compile (lambda (x) (interactive (list (caddr x))))) => #[(x) "\300\207" [nil] 1 nil (list (caddr x))] But macro outside `interactive' is compiled as follows: (disassemble (byte-compile (lambda (x) (caddr x)))) => byte code: args: (x) 0 varref x 1 dup 2 varbind x 3 cdr 4 cdr 5 unbind 1 6 car 7 return Shouldn't it be documented somewhere? Or only I didn't know it? Though there may also be similar problems in interactive functions other than `gnus-group-make-useful-group', I will replace `caddr' in it with the expanded form anyway. BTW, is there a better way than loading cl for Iain Dalton? Regards,