Overview
| Artifact ID: | fb4399791c8a89e120e0fdd88731d215f577bc45e223c713d7d5e78a6fa85d4c |
|---|---|
| Ticket: | 0842331eba4e78318b795abcfddf84ad878311f1
[scan _ %d] 64-bit issue |
| User & Date: | anonymous on 2022-03-14 07:49:32 |
Changes
- assignee changed to: "nobody"
- closer changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
I'm seeing a platform dependency in the Tcl "scan" command when it comes to conversion of oversized positive decimal numbers. According to the docs, "scan ... %d" is supposed to return the greatest integer value that makes sense - according to the given size modifiers. Without any size modifier (just %d) I'd expect to get a large positive number. But instead, I get this on a LP64 machine (x64 GNU/Linux): % info patchlevel 8.6.4 % set tcl_platform(wordSize) 8 % scan 11111111111111111111 %d -7335632962598440505 ...whereas on a ILP32 machine (x86 GNU/Linux) I get this: % info patchlevel 8.6.4 % set tcl_platform(wordSize) 4 % scan 11111111111111111111 %d 2147483647 I've found old bug #1011860 [https://core.tcl-lang.org/tcl/tktview/1011860fffffffffffff], which seems to be related to this. What's going on here?
- foundin changed to: "8.6.4"
- is_private changed to: "0"
- login: "anonymous"
- priority changed to: "5 Medium"
- private_contact changed to: "7059cfaad662ca85cba09bbf879f8783c497066b"
- resolution changed to: "None"
- severity changed to: "Minor"
- status changed to: "Open"
- submitter changed to: "anonymous"
- subsystem changed to: "23. [scan]"
- title changed to: "[scan _ %d] 64-bit issue"
- type changed to: "Bug"