[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#70076: 28.3; xml-escape-string parse issue
From: |
Eli Zaretskii |
Subject: |
bug#70076: 28.3; xml-escape-string parse issue |
Date: |
Fri, 29 Mar 2024 21:08:12 +0300 |
> Cc: Protesilaos Stavrou <public@protesilaos.com>
> From: "D. Schmudde" <d@schmud.de>
> Date: Fri, 29 Mar 2024 16:44:48 +0100
>
> Starting with `emacs -Q`:
>
> (require 'xml)
> (xml-escape-string "And now it\342\200\231s all this")
>
> The result is: `xml-escape-string: Invalid XML character: 4194274,
> 11`
>
> I expect that the string will parse correctly with these escape
> characters. Or is this expectation wrong?
Your expectation is wrong, AFAIU: you are inserting a unibyte string
(a string made out of raw bytes) instead of inserting a non-ASCII
multibyte string, which is what XML expects.
Why did you need to insert those bytes, and where did they come from?