From: <apn...@ya...> - 2025-05-15 16:23:35
|
https://core.tcl-lang.org/tcl/wiki?name=New+abstract+list+representations <https://core.tcl-lang.org/tcl/wiki?name=New+abstract+list+representations&p > &p is a proposal to implement some list operations using new internal list representations enabled by Brian's TIP 636. The wiki post has the full details but TL;DR memory efficiency at a small (probably fixable) cost in iteration speed for large lists. The post has the numbers. The apn-tip636-appl branch contains the implementation of the proposal. The listTypes.test file contains the test cases to exercise the three new internal list types as well as the existing ones. Passes -enable-symbols=mem and valgrind OMM. gcov shows 91% code and 100% function coverage of the new implementation. Missing coverage is for "panic blocks" and validation which is not exercised as it is already done by upper callers. Not planning a TIP as there are no changes at the script or C API level. Please review (both proposal and code) and raise any objections you may have. (It's not that much code to review and pretty isolated thanks to 636). /Ashok |