From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.devel Subject: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r111086: gmm-utils.el (gmm-flet, gmm-labels): New macros. Date: Wed, 05 Dec 2012 07:39:19 +0900 Organization: Emacsen advocacy group Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1354660768 24747 80.91.229.3 (4 Dec 2012 22:39:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 4 Dec 2012 22:39:28 +0000 (UTC) Cc: emacs-devel@gnu.org To: monnier@iro.umontreal.ca Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Dec 04 23:39:41 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Tg19Q-0004pT-Dl for ged-emacs-devel@m.gmane.org; Tue, 04 Dec 2012 23:39:40 +0100 Original-Received: from localhost ([::1]:57013 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg19E-0001nQ-Iz for ged-emacs-devel@m.gmane.org; Tue, 04 Dec 2012 17:39:28 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:55476) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg19A-0001nJ-GC for emacs-devel@gnu.org; Tue, 04 Dec 2012 17:39:26 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tg18y-0003Jt-HT for emacs-devel@gnu.org; Tue, 04 Dec 2012 17:39:24 -0500 Original-Received: from orlando.hostforweb.net ([216.246.45.90]:38572) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg18y-0003Hn-Cj for emacs-devel@gnu.org; Tue, 04 Dec 2012 17:39:12 -0500 Original-Received: from localhost ([127.0.0.1]:47289) by orlando.hostforweb.net with smtp (Exim 4.77) (envelope-from ) id 1Tg18u-0005xp-6s; Tue, 04 Dec 2012 16:39:08 -0600 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.130006 (=?iso-2022-jp?B?GyRCPz8bKEI=?= Gnus v0.6) Emacs/24.3.50 (i686-pc-cygwin) Cancel-Lock: sha1:SowEQFnKZLXQDbiT9KmKbafSXMU= 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-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (barebone) [generic] X-Received-From: 216.246.45.90 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:155268 Archived-At: Stefan Monnier wrote: >> +;; `flet' and `labels' got obsolete since Emacs 24.3. >> +(defmacro gmm-flet (bindings &rest body) [...] > Nooooooooooooooo!!!!!!!!! > Please don't! [...] > Same for gmm-labels! Ok, I'll replace both so as to use cl-flet and cl-labels soon. IIRC I didn't see neither cl-flet nor cl-letf wasn't usable as an analogue to flet (I tried them right after flet was marked obsolete). But now I confirmed it: (progn (pp (macroexpand '(cl-flet ((message (&rest args) (concat "X " (apply #'format args)))) (message "Hello")) )) nil) (let ((--cl-message-- (cl-function (lambda (&rest args) (concat "X " (apply #'format args)))))) (funcall --cl-message-- "Hello")) OTHO, as for gmm-labels I was already using cl-labels in the same way as you suggested for flet. But why I tried it so as not to depend on cl was to try to reduce the ugliness of the way cl handles the #'FUNC cases in a labels form.