Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 8fc99ca7d1e53a9dbdb89b9f3911d79b635d47c8
Ticket: 3525469fffffffffffffffffffffffffffffffff
[lindex] with empty index bug
User & Date: sebres on 2012-05-10 08:59:38
Changes

  1. assignee changed to: "sebres"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    lt. documentation [lindex] could be executed with empty index.
    But if additional index arguments are supplied, it fails with error "bad index".
    It's not consistent for following "alternative" lines, if any of $a, $b or $c is empty:
        [lindex [lindex [lindex $l $a] $b] $c] - always success
    is not compatible with 
        [lindex $l $a $b $c]  - may fails
    or with 
        [lindex $l [list $a $b $c]]  - may fails
    
    Example:
    % lindex list {}
    list
    % lindex [lindex list {}] 0
    list
    % lindex list {} 0
    bad index "": must be integer?[+-]integer? or end?[+-]integer?
    
    
  4. foundin changed to: "obsolete: 8.5.11"
  5. is_private changed to: "0"
  6. priority changed to: "6"
  7. resolution changed to: "None"
  8. status changed to: "Open"
  9. submitter changed to: "sebres"
  10. subsystem changed to: "17. Commands I-L"
  11. title changed to: "[lindex] with empty index bug"
  12. type changed to: "Bug"