Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 272dbcfc500866fea259b6f6f1911ee1a27b8497
Ticket: 578030ffffffffffffffffffffffffffffffffff
Tcl_UniChar is only 16 bits
User & Date: hobbs on 2002-07-09 23:48:29
Changes

  1. assignee changed to: "hobbs"
  2. icomment:
    Logged In: YES 
    user_id=72656
    
    I've spoken with Markus Kuhn about this at length when 
    moving to the 3.0 spec (3.[12] were out, but I decided to not 
    go there for now).  Tcl will be staying by default at the 16-bit 
    Tcl_UniChar value with TCL_UTF_MAX == 3.  These are 
    tweakable parameters during compile, and one can specify 
    32-bit Tcl_UniChars and TCL_UTF_MAX == 6.  There is code 
    to support it.
    
    At one point I tested the code to see that it ran through the 
    test suite, which it did with a few minor problems (mostly in 
    test suite assumptions).  However, the 8.x line of Tcl needs 
    to stay with 16-bit UCS2 for binary compatability reasons.
    
    Should we move to UCS4 in Tcl 9?  That is an outstanding 
    question.  Java and Windows both use UCS2 only, X is 
    moving towards full UCS4, but very few apps use it and I'm 
    not even sure the extent to which it will be used 5 or 10 years 
    from now.
    
    I think the best solution would be to introduce UCS2/UCS4 
    conversion functions in the Tcl API.  The reason for this is 
    that, as Keith notes, they are useful now, and will definitely 
    be useful going forward as we are bound to need to deal with 
    UCS2 systems for a long time to come.
    
    
  3. login: "hobbs"
  4. mimetype: "text/plain"
  5. username: "hobbs"