all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Understanding macros and the compilation flow
@ 2010-06-03 15:03 LanX
  2010-06-03 17:22 ` Helmut Eller
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: LanX @ 2010-06-03 15:03 UTC (permalink / raw)
  To: help-gnu-emacs

Hi

I've put the following code into *scratch* and did M-x eval-buffer and
got a for me suprising result:

-------------------
(defmacro mac () '(insert "		; => before "))

(defun func () (mac))

(func)		; => before

(defmacro mac () '(insert "		; => after"))

(func)		; => after
-----------------

Seems like I didn't understand the compilation process, for my
understanding the redefinition of the macro "mac" after defining the
function "func" should not effect the expansion anymore...

Please, what am I missing here?


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-06-04 16:48 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-03 15:03 Understanding macros and the compilation flow LanX
2010-06-03 17:22 ` Helmut Eller
     [not found] ` <87fx14rpyi.fsf@kuiper.lan.informatimago.com>
2010-06-03 17:45   ` LanX
     [not found] ` <jwvljaulvog.fsf-monnier+gnu.emacs.help@gnu.org>
2010-06-04 15:34   ` LanX
2010-06-04 16:48     ` Andreas Politz

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.