Skip to content
Tcl Source Code History Of Ticket a73c79081e8eab68
Login

History Of Ticket a73c79081e8eab68

Artifacts Associated With Ticket a73c79081e8eab68

  1. Ticket change [9b6d678357] (rid 193500) by chw on 2021-04-09 23:05:12:

    1. assignee initialized to: "nobody"
    2. closer initialized to: "nobody"
    3. cmimetype initialized to: "text/plain"
    4. comment initialized to:
      Index: generic/tcl.h
      ==================================================================
      --- generic/tcl.h
      +++ generic/tcl.h
      @@ -2134,12 +2134,14 @@
        */
       
       #if TCL_UTF_MAX > 3
           /*
            * int isn't 100% accurate as it should be a strict 4-byte value
      -     * (perhaps wchar_t). ILP64/SILP64 systems may have troubles. The
      -     * size of this value must be reflected correctly in regcustom.h.
      +     * (perhaps wchar_t, but certainly not on Windows since they have
      +     * 16 bit wchar_t equivalent to WCHAR). ILP64/SILP64 systems may
      +     * have troubles. The size of this value must be
      +     * reflected correctly in regcustom.h.
            */
       typedef int Tcl_UniChar;
       #else
       typedef unsigned short Tcl_UniChar;
       #endif
      
    5. foundin initialized to: "many"
    6. is_private initialized to: "0"
    7. login: "chw"
    8. priority initialized to: "5 Medium"
    9. private_contact initialized to: "0b3aff16612e1e9f3b675963fa64e01bd1d89307"
    10. resolution initialized to: "None"
    11. severity initialized to: "Cosmetic"
    12. status initialized to: "Open"
    13. submitter initialized to: "chw"
    14. subsystem initialized to: "- New Builtin Commands"
    15. title initialized to: "Doc fix in tcl.h"
    16. type initialized to: "Patch"
  2. Ticket change [1e2a1004de] (rid 194579) by jan.nijtmans on 2021-05-26 12:40:30:

    1. assignee changed to: "jan.nijtmans"
    2. closedate changed to: "2459361.02813057"
    3. closer changed to: "jan.nijtmans"
    4. icomment:
      Fixed in all branches.
      
      wchar_t is a bad idea on all platforms, not only windows. int32_t would be better, but it is not available always.
      
      Thanks!
      
    5. login: "jan.nijtmans"
    6. mimetype: "text/x-fossil-wiki"
    7. resolution changed to: "Fixed"
    8. status changed to: "Closed"
  3. Ticket change [368059cf50] (rid 194590) by chw on 2021-05-26 16:57:19:

    1. closedate changed to: "2459361.20647237"
    2. closer changed to: "chw"
    3. icomment:
      For the record: I'm not happy with the elimination of wording regarding
      wchar_t since it is IMHO *important* information for future implementors
      and porters (without capitalization, howdy DGP!) of still to be defined
      and invented platforms. Certainly, my initial proposal had the possibilty
      to be understood somewhat sarcastically. My fault!
      
      Don't forget, the future is unwritten. And here's a better wording:
      
      On current POSIX platforms, wchar_t is a candidate, as long as it can be
      assured, that wchar_t is a 32 bit quantity. On Windows, a wchar_t is
      equivalent to the WCHAR data type, which is only 16 bits wide and thus
      definitely not useable here. If the compiler and target platform have an
      int32_t data type, this might be the best choice. Maybe this should be
      made a configure time option, but this needs to be layed out in a TIP.
      
    4. login: "chw"
    5. mimetype: "text/plain"
  4. Ticket change [1ad7adb3b0] (rid 194593) by jan.nijtmans on 2021-05-27 08:56:42:

    1. closedate changed to: "2459361.8727128"
    2. closer changed to: "jan.nijtmans"
    3. icomment:
      Understood. However, for Tcl 8.5 and 8.6, TCL_UTF_MAX>3 is not supported, to there's no use to give any advise. For Tcl 8.7 and 9.0, we have TIP #592, which - basically - means we have int32_t. Problem: Changing this would mean that tcl.h would start depending on <stdint.h>, I'm not sure we want that.
      
      I don't know any platform where int != 32 bits, so the current implementation works fine now. As soon as someone actually wants to use Tcl (9.0) in such an environment, we can have a look at this again. But for now I don't see any urge to change it.
      
      Did you see the comment in tcl.h is different for Tcl 8.5/8.6 compared to Tcl 8.7/9.0?
      
    4. login: "jan.nijtmans"
    5. mimetype: "text/x-fossil-wiki"
  5. Ticket change [8003104433] (rid 194606) by chw on 2021-05-27 19:34:09:

    1. closedate changed to: "2459362.31539244"
    2. closer changed to: "chw"
    3. icomment:
      Despite TCL_UTF_MAX>3 being not supported on Tcl <= 8.6, the importance
      of tcl.h is IMO stronger than TIPpery, since it specifies the real interface
      for the respective version. Thus, it is not a bad idea to have some clear 
      explanation in the comment to Tcl_UniChar.
      
    4. login: "chw"
    5. mimetype: "text/plain"