uplevel

uplevel - Execute a script in a different stack frame

 suppose that procedure a was invoked from top-level, and that it called b, and that b called c. Suppose that c invokes the uplevel command.  If level is 1 or #2  or omitted, then the command will be executed in the variable context of b.  If level is 2 or #1 then the command will be executed in the variable context of a. If level is 3 or #0 then the command will be executed at top-level (only global variables will be visible).

原文地址:https://www.cnblogs.com/greencolor/p/4005781.html