From: Joe Riel <joer@san.rr.com>
To: Help GNU Emacs <help-gnu-emacs@gnu.org>
Subject: Docstring prevents constant from being fully byte-compiled
Date: Sun, 10 Mar 2013 23:26:47 -0700 [thread overview]
Message-ID: <20130310232647.6475b4d1@gauss> (raw)
Byte-compile the following (Emacs 23.3.1)
(defconst A "A")
(defconst B "B")
(defconst AB1
(concat constA constB))
(defconst AB2
(concat constA constB)
"docstring")
I get
(byte-code "\303\bB\x10\304\305!\210\306\bB\x10\307\310!\210\311\bB\x10\312 \nP!\207" [current-load-list constA constB A (lambda (#1=#:defconst-tmp-var) (defconst A #1#)) "A" B (lambda (#2=#:defconst-tmp-var) (defconst B #2#)) "B" AB1 (lambda (#3=#:defconst-tmp-var) (defconst AB1 #3#))] 3)
#@11 docstring\x1f
(defconst AB2 (concat constA constB) (#$ . 800))
Note that AB2 retains the original (non-byte-compiled) definition, while AB1 does not.
Is that actually the case? Is AB2 byte-compiled, or not?
Why does the presence of the docstring make a difference?
--
Joe Riel
reply other threads:[~2013-03-11 6:26 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20130310232647.6475b4d1@gauss \
--to=joer@san.rr.com \
--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).