Subject: Re: bug#70356: 30.0.50; [wishlist] Expose UTF-8 parse error to Lisp

From: Andreas Schwab <[email-masked]>
Date: Sat, 13 Apr 2024 09:41:52 +0200

On Apr 13 2024, Michael Albinus via "Bug reports for GNU Emacs, the Swiss army knife of text editors" wrote:

> What I'd like to get is a function, which takes a sequence of bytes as
> arguments, and which indicates, whether this is a valid UTF-8 byte
> sequence. This indication could be an error, or a respective return
> value.

That function could do the decoding and then check whether the result
contains any eight-bit characters (which mark the non-decodable parts).

-- 
Andreas Schwab, [email-masked]
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."