Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2020-06-19
06:07 • Closed ticket [ad8df845fe]: bug in manpage of lset plus 5 other changes artifact: 99959b265e user: andy
06:06 • Ticket [ad8df845fe]: 4 changes artifact: 8dd1af9f95 user: andy
06:06
Correct man page per [ad8df845fef2c76d95b9f1aaa4815f3b23d4c472] check-in: 45084da691 user: andy tags: trunk
2020-04-25
16:22 • New ticket [ad8df845fe] bug in manpage of lset. artifact: b43c6dff41 user: anonymous

bug in manpage of lset

Closed / Fixedad8df845fef2c76d95b9f1aaa4815f3b23d4c472Created 7 years agoUpdated 6 years ago
Descriptionplain2020-04-25 16:22:38
Here it is: https://www.tcl-lang.org/man/tcl/TclCmd/lset.htm

In the man page of "lset", section EXAMPLES, the last example of the first example list is incorrect (I have tried it in tclsh of 8.6). The example states:

set x [list [list a b c] [list d e f] [list g h i]]
lset x {2 3} j
   → list index out of range

but second index "3" is still ok, it extends the third sublist:
→ {a b c} {d e f} {g h i j}

Probably the example should be changed to use index "4" instead of "3":

lset x {2 4} j → list index out of range
Referenced by1
andy (claiming to be Andy Goth)wiki2020-06-19 06:06:56
andy Closed ticket [ad8df845fe]. [History diff]2020-06-19 06:07:59
Log in (anonymous is fine) to add a comment.