[Top][All Lists]

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

bug#23425: master branch: `message' wrongly corrupts ' to curly quote.

From: Paul Eggert
Subject: bug#23425: master branch: `message' wrongly corrupts ' to curly quote.
Date: Tue, 3 May 2016 08:17:56 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0

On 05/02/2016 12:10 PM, Alan Mackenzie wrote:

(message "%s" M) is the usual way to output a message M without
formatting it, and something like this is needed anyway if M might
contain %.
That is the case for a string that might contain percent characters.  It
is not the case for a string known to be without percents.

Sure, but the most common problem here is using (message M) to output an arbitrary string M that is under user control, which is why the advice about (message "%s" M) is helpful. This advice works for all format directives, not just % directives.

There is no mention of its corruption of quotes in
`messages''s doc string.

Thanks, good point. I fixed it by installing the attached patch, which should address the other documentation problems you mention too.

It appears to me that these substitutions are only done on pairs of
quote marks, not single quotes.

What gives you that impression? Substitutions are done on all quotes, not just paired quotes.

Properly, for me, means that it handles percent escape sequences, AND

This alternative was considered when designing text-quoting-style, but at the time we didn't see a need for the extra complexity. The particular glitch you ran into is not a strong argument for revisiting this now.

Why is it not in the section "incompatible Lisp changes"?

It is in that section, under "** New variable 'text-quoting-style' ...".

Attachment: 0001-Doc-fixes-for-quoting.txt
Description: Text document

reply via email to

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