bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#27270: display-raw-bytes-as-hex generates ambiguous output for Emacs


From: Paul Eggert
Subject: bug#27270: display-raw-bytes-as-hex generates ambiguous output for Emacs strings
Date: Thu, 8 Jun 2017 13:35:45 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0

On 06/08/2017 12:56 PM, Eli Zaretskii wrote:
How do you know "\2205" is a two character string

Because I use Emacs out of the box, with the default printable-chars.


The difference is that I don't use display tables and don't want to use
them. In contrast, I would like to use hexadecimal display, if it worked
as well as octal does (which it does not).
Then we need to code a separate feature in the Lisp reader, I think.

What do you think of using capital X for hexadecimal escapes with at most two digits? That way, "\X905" would be a two-character string, which is what is wanted here. Or we could use small h for hexadecimal, and "\h905".

If we were feeling ambitous and concise, we could use no character at all and upper-case hex digits for bytes in the range 0x80 through 0xFF; this would be unambiguous in strings (the example would be "\905"). This may be a bridge too far, though.






reply via email to

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