return — Returns a value from a procedure.
return value
return
value
The return command returns a value from a proc command.
proc someproc {} { set res 1 return $res set res 2 return $res } puts [someproc]
Produces:
1