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

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

bug#4848: 23.1.50; \u and \x in string


From: Richard Stallman
Subject: bug#4848: 23.1.50; \u and \x in string
Date: Wed, 04 Nov 2009 20:56:45 -0500

    I'm not sure what you wanted to be documented.  Is the description in
    "(elisp)General Escape Syntax" what you were looking for?

The version I have is from August.  If it has been substantially
improved since then, maybe it is good.  The text from August was
inadequate and even wrong:

      To use hex, write a question mark followed by a backslash, @samp{x},
    and the hexadecimal character code.  You can use any number of hex
    digits, so you can represent any character code in this way.
    Thus, @samp{?\x41} for the character @kbd{A}, @samp{?\x1} for the
    character @kbd{C-a}, and @code{?\x8e0} for the Latin-1 character
    @iftex
    @address@hidden
    @end iftex
    @ifnottex
    @samp{a} with grave accent.
    @end ifnottex

And here is something from Non-ASCII In Strings:

      You can also represent a multibyte address@hidden character with its
    character code: use a hex escape, @address@hidden, with as many
    digits as necessary.  (Multibyte address@hidden character codes are all
    greater than 256.)  Any character which is not a valid hex digit
    terminates this construct.  If the next character in the string could be
    interpreted as a hex digit, write @address@hidden }} (backslash and space) 
to
    terminate the hex escape---for example, @address@hidden }} represents
    one character, @samp{a} with grave accent.  @address@hidden }} in a string
    constant is just like backslash-newline; it does not contribute any
    character to the string, but it does terminate the preceding hex escape.





reply via email to

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