GNU bug report logs - #60454
30.0.50; `format-message' does not allow displaying "`" and "'" verbatim

Previous Next

Package: emacs;

Reported by: Ihor Radchenko <yantar92 <at> posteo.net>

Date: Sat, 31 Dec 2022 15:05:01 UTC

Severity: wishlist

Found in version 30.0.50

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Andreas Schwab <schwab <at> linux-m68k.org>
Cc: Ihor Radchenko <yantar92 <at> posteo.net>, 60454 <at> debbugs.gnu.org
Subject: bug#60454: 30.0.50; `format-message' does not allow displaying "`" and "'" verbatim
Date: Sat, 31 Dec 2022 11:39:35 -0500
>> However, sometimes, it is desired to keep these chars literal.
>> For example, `org-assert-version' displays a warning that suggests Elisp
>> code:
>>
>> (warn "...
>>    It is recommended to put
>>     (straight-use-package 'org)
>> ...")
>
> The mangling only happens in the format string.  Pass the text as
> argument and substitute it with %s.
>
> (warn "...
>    It is recommended to put
>     %s
> ..." "(straight-use-package 'org)")

That's rather cumbersome.
I think it would make a lot of sense to offer escapes like %' and %`


        Stefan





This bug report was last modified 1 year and 284 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.