Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 96798d93d3a0b2b75a401c6a25dd6f8a5c948ef0004cde55501256eecb511835
Ticket: 7f1162a8674cc65c9b72169818badc3186f97678
concatenation does not make usable surrogate pairs
User & Date: jan.nijtmans on 2021-04-14 08:30:30
Changes

  1. icomment:
    Closing the ticket now, since the last bug in it is found and fixed.
    
    On the "Tcl should refuse" ...   Indeed, I think that Tcl should refuse invalid byte sequences. There is an experimental branch for that (encodings-with-flags), compiling this with -DTCL_NO_DEPRECATED (intended for 9.0) will activate the change. I don't think we can introduce that earlier than 9.0, it needs a TIP. Upcoming (I hope).
    
    Currently, Tcl doesn't refuse any byte sequence, it just tries to correct it, using CP1252 (or ISO8859-1, for Tcl 8.6) as fallback, when necessary. So your questin (to which time point exactly it becomes not valid?) makes no sense: byte sequences are valid or invalid, as documented by WTF-8 (or CESU-8 for Tcl 8.6). Invalid byte sequences currently are handled as if they are valid, that's something we cannot change in Tcl 8.x. The only think we can improve is the fallback handling conforming to EIAS.
    
  2. login: "jan.nijtmans"
  3. mimetype: "text/x-fossil-wiki"