Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Delete a proc

1 view
Skip to first unread message

Daniel P. Stasinski

unread,
Jan 31, 2003, 9:09:56 PM1/31/03
to
Is there any way, by command, to completely remove all references to a proc
from an interpreter? Sort of an unproc?

Thanks,

Daniel

Michael Schlenker

unread,
Jan 31, 2003, 9:45:15 PM1/31/03
to
Daniel P. Stasinski wrote:
> Is there any way, by command, to completely remove all references to a proc
> from an interpreter? Sort of an unproc?
>

If by remove all references to a proc means just to delete the proc
itself then:

rename your_proc {}

is the command you look for.

If any code calls your_proc after you delete it like this, it will fail
and throw an error.

If you want to delete all _calls_ to a proc you will need some rather
complex trickery with tcl 8.4 [trace add execution]/[trace add command]
and introspection to modify the callers.

Michael Schlenker


Daniel P. Stasinski

unread,
Jan 31, 2003, 10:12:29 PM1/31/03
to

I love this language :)

Thank you,

Daniel

0 new messages