Menu

#1334 [exists] and colorful generator names

open
generator (1)
5
2012-10-19
2012-10-19
Poor Yorick
No

[exists] is currently defined like this:

proc exists generator { expr {[llength [info commands $generator]] != 0} }

this could fail if $generator contains interpreted [string match] characters. Also, the following fix is more performant (thanks kbk):

proc exists generator { expr {[namespace which $generator] ne {}} }

Discussion

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.