From: Elena <egarrulo@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Redefining functions and variables
Date: Thu, 29 Jul 2010 03:28:00 -0700 (PDT) [thread overview]
Message-ID: <ed2bc63d-205a-4ab0-aa10-042e9eedbb20@x21g2000yqa.googlegroups.com> (raw)
In-Reply-To: 877hkeiozz.fsf@kuiper.lan.informatimago.com
On Jul 29, 10:03 am, p...@informatimago.com (Pascal J. Bourguignon)
wrote:
> the "..." are only used to display the list when print-length or
> eval-expression-print-length are not nil. See also print-level and
> eval-expression-print-level.
Didn't know about this. Thanks.
> %s can format symbols too:
>
> (format ">> %s <<" 'example)
> ;; --> ">> example <<"
>
> And you had your the old defun inside the when!
Gosh! What an oversight... Sorry.
> Note: while name is known at macroexpansion time, you should refrain
> to insert it in the string like this:
>
> (message ,(format "Warning: %s is being redefined in %%s." name) load-file-name)
>
> since name could contain percents and then you'd have build a wrong
> format string for message.
I don't understand this. Doc about `message' says:
> Note: Use (message "%s" VALUE) to print the value of expressions and
> variables to avoid accidentally interpreting `%' as format specifiers.
And in fact:
(message "%s" 'example%)
correctly outputs:
"example%"
next prev parent reply other threads:[~2010-07-29 10:28 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-27 15:12 Redefining functions and variables Elena
2010-07-27 20:21 ` Stefan Monnier
2010-07-27 22:16 ` Elena
2010-07-28 0:35 ` Andreas Politz
2010-07-28 7:51 ` Elena
2010-07-28 14:29 ` Elena
2010-07-28 18:48 ` Andreas Politz
2010-07-28 20:37 ` Pascal J. Bourguignon
2010-07-29 8:32 ` Elena
2010-07-29 9:57 ` Stefan Monnier
2010-07-29 10:16 ` Elena
2010-07-29 13:14 ` Stefan Monnier
2010-07-30 19:32 ` Uday S Reddy
2010-07-29 10:31 ` Andreas Politz
2010-07-29 11:46 ` Johan Bockgård
2010-07-29 15:54 ` Andreas Politz
2010-07-29 12:41 ` Tim X
2010-07-29 10:03 ` Pascal J. Bourguignon
2010-07-29 10:28 ` Elena [this message]
2010-07-29 20:35 ` Johan Bockgård
2010-07-29 22:22 ` Tim X
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=ed2bc63d-205a-4ab0-aa10-042e9eedbb20@x21g2000yqa.googlegroups.com \
--to=egarrulo@gmail.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).