global
global ?varName ...?
In a proc, links each name to the variable of the same name at the top level. Outside a proc it has no effect.
Examples
A click on an example runs it in the shell of the page.
set total 5; proc show {} {global total; return $total}; show:5
Facts
- Capability: none.
- Compute cost: one compute unit for the call, and more for the commands that it runs.