Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 91ec695542de98cc96d4818fed8a2485621ef41d
Ticket: f8bc8efdf547eb8ddd92218ee1f8d91d0e0b4937
Tutorial lesson 15 uses listName inconsistently with lappend/linsert/lreplace
User & Date: neirbowj on 2016-08-23 22:32:46
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    The command signatures for lappend and linsert are presented in Lesson 15 of the tutorial ("Adding & Deleting members of a list") as follows.
    
    lappend listName ?arg1 arg2 ... argn?
    linsert listName index arg1 ?arg2 ... argn?
    
    The latter should read like this instead.
    
    linsert list index arg1 ?arg2 ... argn?
    
    According to the tutorial, the following interactive session should set `otherlist` to `{{one} {oneandahalf} {two} {three} {four}}` and return `two` from the final `lindex` command.
    
        % set mylist [list one two three]
        one two three
        % lappend mylist four
        one two three four
        % lindex $mylist 3
        four
        % set otherlist [linsert mylist 1 oneandahalf]
        mylist oneandahalf
        % lindex $otherlist 2
        %
    
  5. foundin changed to: "8.5"
  6. is_private changed to: "0"
  7. login: "neirbowj"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "1c2c806ffe757c7d753b24f4d1a4e6c176ba5348"
  10. resolution changed to: "None"
  11. severity changed to: "Minor"
  12. status changed to: "Open"
  13. submitter changed to: "neirbowj"
  14. subsystem changed to: "75. Tutorial"
  15. title changed to:
    Tutorial lesson 15 uses listName inconsistently with lappend/linsert
    
  16. type changed to: "Bug"