From: Stefan Monnier <monnier@iro.umontreal.ca>
To: help-gnu-emacs@gnu.org
Subject: Re: compiler macros without byte-compilation
Date: Fri, 20 Mar 2015 09:42:06 -0400 [thread overview]
Message-ID: <jwv8uer23lc.fsf-monnier+gmane.emacs.help@gnu.org> (raw)
In-Reply-To: 871tkkf1g9.fsf@yahoo.fr
> => ((lambda nil (message "Done !")) "compiler-macro")
> Now I'm puzzled : why does this happen ? foobar wasn't compiled here !
The exact cases where compiler-macros are used are unspecified and
likely to change between versions.
If you want to know the details: compiler-macros are expanded by
macroexpand-all. So everytime we rely on macroexpand-all (i.e. "eager"
expansion) rather than on macroexpand (i.e. "lazy" expansion), compiler
macros will be expanded.
"Lazy" macroexpansion is on the way out: `eval' does not call
macroexpand-all (because it can happen that `eval' is called repeatedly
in a tight loop to evaluate very short code sequences, where going
through macroexpand-all might be detrimental for performance), but
pretty much all other paths to `eval' do or should (i.e. `load',
`eval-region', ...).
Stefan
prev parent reply other threads:[~2015-03-20 13:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-20 9:44 compiler macros without byte-compilation Nicolas Richard
2015-03-20 13:42 ` Stefan Monnier [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwv8uer23lc.fsf-monnier+gmane.emacs.help@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).