TABLE OF CONTENTS
::pwtk::procName
SYNOPSIS
proc ::pwtk::procName {{level -1}} {
DESCRIPTION
If level == -1, returns the name of the calling proc or "top-level" if called from the top level. If level == -2, return the name of the calling proc of the calling proc, i.e., the name of the proc two-levels back. If level == -N, returns the name of the proc N-levels back.
Typically used internally by PWTK.
ARGUMENTS
- level -- [optional, default = -1] how many levels back to report the name of the proc.
SOURCE
if { [info level] > abs($level) } { return [lindex [info level $level] 0] } else { return "top-level" } }