name returns the name of this function, if known.
()
| 42 | |
| 43 | // name returns the name of this function, if known. |
| 44 | func (f Frame) name() string { |
| 45 | fn := runtime.FuncForPC(f.pc()) |
| 46 | if fn == nil { |
| 47 | return "unknown" |
| 48 | } |
| 49 | return fn.Name() |
| 50 | } |
| 51 | |
| 52 | // Format formats the frame according to the fmt.Formatter interface. |
| 53 | // |
no test coverage detected