Skip to content
Tcl Source Code History Of Ticket 2dff98e079
Login

History Of Ticket 2dff98e079

Artifacts Associated With Ticket 2dff98e079

  1. Ticket change [df84203e20] (rid 258350) by serhiy.storchaka on 2026-10-16 22:13:57:

    1. cmimetype initialized to: "text/x-fossil-wiki"
    2. comment initialized to:
      <nowiki>[format %A]</nowiki> overwrites the second character of the result with "x", assuming that it starts with "0X":
      
      <verbatim>
      format %A -1.5    ;# -xX1.8p+0
      format %+A 1.0    ;# +xX1p+0
      format %10A 1.5   ;#  x0X1.8p+0
      format %A Inf     ;# IxF
      </verbatim>
      
      Only plain positive values come out right (0x1.8p+0). The code came with %a/%A in [5cfe15b5d6].
      
    3. foundin initialized to: "9.0.5, 9.1.0"
    4. login: "serhiy.storchaka"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. severity initialized to: "Minor"
    8. status initialized to: "Open"
    9. submitter initialized to: "serhiy.storchaka"
    10. subsystem initialized to: "16. Commands A-H"
    11. title initialized to:
      format %A garbles negative, padded and infinite values
      
    12. type initialized to: "Bug"
  2. Ticket change [fb24a449fa] (rid 258357) by serhiy.storchaka on 2026-10-16 22:18:07:

    1. icomment:
      Proposed fix in branch [/timeline?r=format-A-prefix|format-A-prefix]: lowercase the "0X" prefix and the "P" exponent marker where they are, which is after the padding and the sign, and leave INF alone. Test format-19.5.
      
    2. login: "serhiy.storchaka"
    3. mimetype: "text/x-fossil-wiki"
  3. Ticket change [c63cde0537] (rid 258384) by jan.nijtmans on 2026-10-17 06:54:38:

    1. assignee changed to: "aku"
    2. closer changed to: "nobody"
    3. comment changed to:
      <nowiki>[format %A]</nowiki> overwrites the second character of the result with "x", assuming that it starts with "0X":
      
      <verbatim>
      format %A -1.5    ;# -xX1.8p+0
      format %+A 1.0    ;# +xX1p+0
      format %10A 1.5   ;#  x0X1.8p+0
      format %A Inf     ;# IxF
      </verbatim>
      
      Only plain positive values come out right (0x1.8p+0). The code came with %a/%A in [5cfe15b5d6].
      
    4. icomment:
      +1
      
      Please go ahead
      
    5. login: "jan.nijtmans"
    6. mimetype: "text/x-fossil-wiki"
  4. Ticket change [2f24eb1b1f] (rid 258446) by serhiy.storchaka on 2026-10-17 07:25:45:

    1. icomment:
      Merged into main in [9336b96c43] and into 9.0 in [06f25062c2].
      
    2. login: "serhiy.storchaka"
    3. mimetype: "text/x-fossil-wiki"
    4. resolution changed to: "Fixed"
    5. status changed to: "Closed"
  5. Ticket change [4b524ff3ba] (rid 258950) by jan.nijtmans on 2026-10-18 08:53:28:

    1. assignee changed to: "jan.nijtmans"
    2. icomment:
      Just one thing left to fix. With msvcrt (not ucrt):
      <pre>
      ==== format-19.5 %A with sign, padding and Inf, bug [2dff98e079] FAILED
      ==== Contents of test case:
      
          # explicit precision: without it MSVC prints all 13 hex digits
          list [format %.1A 1.5] [format %.1A -1.5] [format %+.0A 1.0]  [format "% .0A" 1.0] [format %10.1A 1.5] [format %-10.0A| -2.0]  [format %A Inf] [format %A -Inf]
      
      ---- Result was:
      0x1.8p+0 -0x1.8p+0 +0x1p+0 { 0x1p+0} {  0x1.8p+0} {-0x1p+1   |} 0x1.#INF00p+0 -0x1.#INF00p+0
      ---- Result should have been (exact matching):
      0x1.8p+0 -0x1.8p+0 +0x1p+0 { 0x1p+0} {  0x1.8p+0} {-0x1p+1   |} INF -INF
      ==== format-19.5 FAILED
      </pre>
      
      Matching with -glob would be easiest: If it contains 'INF' that should be OK
      
    3. login: "jan.nijtmans"
    4. mimetype: "text/x-fossil-wiki"
    5. status changed to: "Pending"
  6. Ticket change [5cdae507bc] (rid 258953) by jan.nijtmans on 2026-10-18 08:59:20:

    1. icomment:
      My proposal [6715b0e7eddf95f|here] (unless someone has a better idea)
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/x-fossil-wiki"
  7. Ticket change [a6dc151432] (rid 258954) by jan.nijtmans on 2026-10-18 08:59:32:

    1. icomment:
      My proposal [6715b0e7eddf95f|here] (unless someone has a better idea)
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/x-fossil-wiki"
  8. Ticket change [de90a6a88b] (rid 258955) by jan.nijtmans on 2026-10-18 09:00:57:

    1. icomment:
      My proposal [96715b0e7e|here] (unless someone has a better idea)
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/x-fossil-wiki"
  9. Ticket change [f442407fa0] (rid 258959) by serhiy.storchaka on 2026-10-18 09:21:47:

    1. icomment:
      Another option, done in [f5bb9702a9]: format infinities ourselves instead of passing them to the C library, as Python does. msvcrt gets them wrong for all float conversions, not only <tt>%A</tt> (<tt>1.#INF00e+000</tt>, <tt>1.#INF</tt> even for <tt>%G</tt>). Now they are <tt>inf</tt> or <tt>INF</tt> (for <tt>%A</tt>, <tt>%E</tt>, <tt>%G</tt>) with the sign flags, padded with spaces, as C99 specifies; the output on glibc and ucrt does not change. format-19.5 is exact again, new test format-19.6. Tested with a mingw msvcrt build on Windows 11: format.test passes, and fails without this change. NaN cannot get there, it is rejected earlier.
      
    2. login: "serhiy.storchaka"
    3. mimetype: "text/x-fossil-wiki"
  10. Ticket change [0252629989] (rid 259097) by jan.nijtmans on 2026-10-18 21:07:22:

    1. closedate changed to: "2461332.3801244674"
    2. closer changed to: "jan.nijtmans"
    3. icomment:
      Agreed! Follow-up patch now merged too.
      
      Thanks!
      
    4. login: "jan.nijtmans"
    5. mimetype: "text/x-fossil-wiki"
    6. status changed to: "Closed"
  11. Ticket change [51cb0e070f] (rid 260148) by serhiy.storchaka on 2026-10-23 09:32:19:

    1. icomment:
      The infinity part of the follow-up [185825858e] was backported to 8.6 in [326e1bf923] for [40f315bc23]. 8.6 has no %a/%A.
      
    2. login: "serhiy.storchaka"
    3. mimetype: "text/x-fossil-wiki"