Add support for Tcl 9

Started by Peter Eisentrautover 1 year ago3 messageshackers
Jump to latest
#1Peter Eisentraut
peter_e@gmx.net

Tcl 9 changed several API functions to take Tcl_Size, which is
ptrdiff_t, instead of int, for 64-bit enablement. We have to change a
few local variables to be compatible with that. We also provide a
fallback typedef of Tcl_Size for older Tcl versions. Here is a patch
for that.

The affected variables are used for quantities that will not approach
values beyond the range of int (usually number of columns), so this
doesn't change any functionality, AFAICT.

Attachments:

0001-Add-support-for-Tcl-9.patchtext/plain; charset=UTF-8; name=0001-Add-support-for-Tcl-9.patchDownload+10-7
#2Tristan Partin
tristan@partin.io
In reply to: Peter Eisentraut (#1)
Re: Add support for Tcl 9

Looks correct to me. TIPs 628[0]https://core.tcl-lang.org/tips/doc/trunk/tip/628.md and 666[1]https://core.tcl-lang.org/tips/doc/trunk/tip/666.md seem to be the proposals which added
Tcl_Size and changed functions to use the type.

Reviewed-by: Tristan Partin <tristan@partin.io>

[0]: https://core.tcl-lang.org/tips/doc/trunk/tip/628.md
[1]: https://core.tcl-lang.org/tips/doc/trunk/tip/666.md

--
Tristan Partin
Neon (https://neon.tech)

#3Peter Eisentraut
peter_e@gmx.net
In reply to: Tristan Partin (#2)
Re: Add support for Tcl 9

On 25.11.24 05:07, Tristan Partin wrote:

Looks correct to me. TIPs 628[0] and 666[1] seem to be the proposals
which added Tcl_Size and changed functions to use the type.

Reviewed-by: Tristan Partin <tristan@partin.io>

Committed and backpatched. Thanks for checking.