Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2002-03-26
03:59 • Closed ticket [534845ffff]: bad variable initialization plus 7 other changes artifact: 1bf7e9af0d user: dgp
2002-03-25
20:23 • New ticket [534845ffff]. artifact: 76450ed3d9 user: dgp

bad variable initialization

Closed / Fixed534845ffffffffffffffffffffffffffffffffffCreated 25 years agoUpdated 25 years ago
Descriptionplain2002-03-25 20:23:00
% set verbose fake
fake
% package require tcltest
2.0.2
% tcltest::verbose
can't read "tcltest::verbose": no such variable

The problem is that variable initialization in
tcltest uses a construct like:

if {![info exists verbose]} {
    variable verbose $default
]

Due to the strange resolution of variables, the
existence of variable ::verbose prevents initialization
of tcltest::verbose.

There's lots of this in tcltest.  Other packages
should probably check for it too.
dgpplain2002-03-26 03:59:05
Logged In: YES 
user_id=80530

fixed in HEAD (2.0.2)

probably still buggy in tcltest 1
Log in (anonymous is fine) to add a comment.