Skip to content
Tcl Source Code History Of Ticket 684433
Login

History Of Ticket 684433

Artifacts Associated With Ticket 684433

  1. Ticket change [109002bbf4] (rid 94990) by nobody on 2003-02-11 07:51:51:

    1. assignee initialized to: "dkf"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      The glob command can accept many pattern arguments 
      but the lsearch do not. As it is often interesting to 
      search lists for several elements, this feature could be 
      powerful:
      
      lsearch ?switches? list pattern ?pattern...?
      
      This syntax is totally compatible with the current lsearch 
      command. It would provide a smart replacement for:
      
      set newList {}
      foreach pattern patternList {
         set result [lsearch ?switches? $list $pattern]
         set newList [concat $newList $pattern]
      }
      
      It would then be possible to easily find the common 
      elements of 2 lists:
      
      eval lsearch -all -inline [list $list1] $list2
      
      or to delete list elements that are already in the second 
      list:
      
      eval lsearch -all -not -inline [list $list1] $list2
      
      
      JM. Philippe
      
      
    4. foundin initialized to: "None"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "nobody"
    9. subsystem initialized to: "17. Commands I-L"
    10. title initialized to: "lsearch multiple pattern matching"
    11. type initialized to: "RFE"