1: ### 2: ## lempty <list> 3: ## 4: ## Returns 1 if <list> is empty or 0 if it has any elements. This command 5: ## emulates the TclX lempty command. 6: ### 7: 8: proc lempty {list} { 9: if {[catch {llength $list} len]} { return 0 } 10: return [expr $len == 0] 11: } |