"How do I calculate the line number of ...?" is a very frequently-asked question.
There's no satisfying answer, in general. While introspection is generally one of Tcl's strengths, no one has yet invested what's necessary to implement a line-number calculation satisfyingly.
[Explain difficulties (byte-coded vs. not, in script vs. proc body vs. eval)?]
[Various ways to instrument existing procedures ... ]
[Tom Tromey once wrote extension (?) to do this.]
[tclguy's summary: "it is going to have to be somebody's science project"]