Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2004-06-17
04:12 • Closed ticket [808319ffff]: stop use of ::unknown_pending plus 7 other chang... artifact: 356d0e6d68 user: dgp
2004-05-06
15:40 • Ticket [808319ffff]: 4 changes artifact: 4fd36eef7d user: dkf
03:48 • Ticket [808319ffff]: 2 changes artifact: 9e4af0010d user: dgp
2003-09-22
23:31 • Ticket [808319ffff]: 4 changes artifact: 4eaefd70df user: dgp
23:31 • Ticket [808319ffff]: 4 changes artifact: 6521f7a655 user: dgp
23:31 • Add attachment 808319.patch to ticket [808319ffff] artifact: 19da1b055b user: dgp
2003-09-18
04:39 • New ticket [808319ffff] stop use of ::unknown_pending. artifact: 334bced356 user: dgp

stop use of ::unknown_pending

Closed / Fixed808319ffffffffffffffffffffffffffffffffffCreated 23 years agoUpdated 22 years ago
Descriptionplain2003-09-18 04:39:54
The default [unknown] command, defined
in Tcl's init.tcl script, makes use of a
global array variable ::unknown_pending
just to catch circular [unknown] invocations
that would lead to an infinite loop.

It would be a complete no-brainer to replace
this impolite use of a global variable with
the use of a private variable in the ::tcl
namespace for the same purpose (something
that should have been part of the 7 -> 8 
transition), except for one thing:

we documented it.

In library(n), the use of ::unknown_pending
is documented.

Looking for anyone to make the case that
based on that documentation, someone
might be making use of that variable.
If not, I request we ditch the docs and
the use of the variable in 8.5a development.
dgpplain2003-09-22 23:31:15
Logged In: YES 
user_id=80530

here's the simple patch.
Doesn't deal with the docs issue.
dgpplain2003-09-22 23:31:16
File Added - 62201: 808319.patch
dgp Ticket [808319ffff]: 2 changes [History diff]2004-05-06 03:48:51
dkfplain2004-05-06 15:40:52
Logged In: YES 
user_id=79902

The documentation of ::unknown_pending pretty much indicates
that it is not useful for general scripts (e.g. it states
that it is not set at all outside the processing of the
default ::unknown) unless they really want to find out
whether they are being autoloaded.  But that's *really* bad
practice IMHO.
dgpplain2004-06-17 04:12:27
Logged In: YES 
user_id=80530

fixed for Tcl 8.5
Log in (anonymous is fine) to add a comment.

Attachments: