[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Emacs-diffs] master 9ffb6ce 5/5: Quoting fixes in lisp/internationa

From: David Kastrup
Subject: Re: [Emacs-diffs] master 9ffb6ce 5/5: Quoting fixes in lisp/international and lisp/leim
Date: Tue, 01 Sep 2015 09:35:59 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

Paul Eggert <address@hidden> writes:

> One alternative is to go with a system that normally has no
> translation, where Emacs source-code docstrings and diagnostics use
> curved quotes that merely stand for themselves, and where all curved
> quotes are displayed/searched-for/yanked as ASCII approximations for
> users who prefer the traditional style.  This would remove the need
> for format-message and/or substitute-command-keys doing any quote
> translation.  A downside is that source code docstrings and
> diagnostics would need to be converted to use curved quotes.

Well, it would save us from horribly wrong DOC strings like

quote is a special form in ‘C source code’.

(quote ARG)

Return the argument, without evaluating it.  ‘(quote x)’ yields ‘x’.
Warning: ‘quote’ does not construct its return value, but just returns
the value that was pre-constructed by the Lisp reader (see info node
‘(elisp)Printed Representation’).
This means that ’(a . b) is not identical to (cons ’a ’b): the former
does not cons.  Quoting should be reserved for constants that will
never be modified by side-effects, unless you like self-modifying code.
See the common pitfall in info node ‘(elisp)Rearrangement’ for an example
of unexpected results when a quoted object is modified.


Sometimes a quote is just a quote.

David Kastrup

reply via email to

[Prev in Thread] Current Thread [Next in Thread]