Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2020-10-27
20:29 • Closed ticket [11229bad5f]: string insert compiler fails plus 8 other chan... artifact: 84a898b81f user: dgp
20:27
[11229bad5f] Fix the bytecode compiler for [string insert]. check-in: 1e1a593ca4 user: dgp tags: core-8-branch
20:16 • Ticket [11229bad5f] string insert compiler fails status still Open with 3 ... artifact: 25fe18e865 user: dgp
20:09
[11229bad5f] New test to demonstrate the bug. check-in: 87bb381d4e user: dgp tags: bug-11229bad5f
20:07 • New ticket [11229bad5f] string insert compiler fails. artifact: 76d2b97a59 user: dgp

[string insert] compiler fails

Closed / Fixed11229bad5f90d18d8e7f77f435674b8bff62f33eCreated 6 years agoUpdated 6 years ago
Descriptionplain2020-10-27 20:07:32
Thanks to "Dave B" on comp.lang.tcl for the alert about this.

Use this test to start demonstrations that bytecode compiler
for [string insert] is badly broken.

test string-31.26.$noComp {string insert, bytecompiler} -setup {
    set i 2
} -body {
    run {tcl::string::insert abcd $i xyz}
} -cleanup {
    unset i 
} -result abxyzcd
Referenced by2
dgpplain2020-10-27 20:16:20
Looks like a very simple error, returning TCL_OK, when it
should be TCL_ERROR instead.
dgpplain2020-10-27 20:29:34
Simple fix committed.
Log in (anonymous is fine) to add a comment.