interp aliases ?path?This command returns a Tcl list of the names of all the source commands for aliases defined in the interpreter identified by
path.
Or actually, it returns a Tcl list of the
alias tokens for aliases defined in the interpreter — these are often the same as the command name you used to create them, but if aliases are being
renamed then things can get tricky. Consider:
% interp alias {} a {} list a 1
a
% a
a 1
% rename a a1
% interp alias {} a {} list a 2
::a
% a
a 2
% rename a a2
% interp alias {} a {} list a 3
::::a
% a
a 3
% interp aliases {}
::::a ::a a
% interp alias {} a
list a 1
% interp alias {} ::a
list a 2
% interp alias {} ::::a
list a 3
See also: