From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcin Borkowski Subject: Re: Why does evaluating a piece of Elisp code seemingly not expand a macro? Date: Mon, 18 Jan 2016 21:03:33 +0100 Message-ID: <8737tu8xka.fsf@mbork.pl> References: <87a8o7duj6.fsf@mbork.pl> <878u3rcdpu.fsf@gmail.com> <87io2r95n2.fsf@mbork.pl> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:41128) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLG1g-00026D-Ll for emacs-orgmode@gnu.org; Mon, 18 Jan 2016 15:03:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aLG1d-0005jA-Ft for emacs-orgmode@gnu.org; Mon, 18 Jan 2016 15:03:44 -0500 In-reply-to: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Stefan Monnier Cc: help-gnu-emacs@gnu.org, emacs-orgmode@gnu.org On 2016-01-18, at 14:54, Stefan Monnier wrote: >> Does it mean that C-M-x is different than loading? > > Yes. > >> Or C-x C-e, for that matter? > > As well. > >> Is this covered by the manual? (If not, it might need correcting.) > > Not really. The basic idea is that macroexpansion can take place > *anytime* (tho, before the code is actually executed). If you care > about when expansion takes place you probably have a bug. Does that mean that it's possible that a function definition contains unexpanded macros? Does that mean that `symbol-function' will expand them? Does that mean that if I define a macro, then a function using that macro, and then change the definition of the macro, the behavior of the function is undefined? Sorry for so many questions, but I really want to understand this. (Also, when that happens, I might send a patch for the manual.) > Stefan Best, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University