diff options
author | Austin Clements <austin@google.com> | 2017-07-06 12:36:25 -0400 |
---|---|---|
committer | Austin Clements <austin@google.com> | 2017-07-07 19:30:06 +0000 |
commit | d58125ecd22649eb0a4b33715f39d6696b13c5fb (patch) | |
tree | 8f096102d437e0c5be35601b4a29d54decd81262 /src/runtime/symtab.go | |
parent | fcc35147d5940d5b077586c02a97894c3edf870d (diff) | |
download | go-d58125ecd22649eb0a4b33715f39d6696b13c5fb.tar.gz go-d58125ecd22649eb0a4b33715f39d6696b13c5fb.zip |
runtime: document FuncForPC behavior with inlining
Change-Id: I1c02aa4f7131ae984fda66b32e8a993c0a40b8f4
Reviewed-on: https://go-review.googlesource.com/47690
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Russ Cox <rsc@golang.org>
Diffstat (limited to 'src/runtime/symtab.go')
-rw-r--r-- | src/runtime/symtab.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/runtime/symtab.go b/src/runtime/symtab.go index 40add013e4..ced42dad61 100644 --- a/src/runtime/symtab.go +++ b/src/runtime/symtab.go @@ -573,6 +573,9 @@ func moduledataverify1(datap *moduledata) { // FuncForPC returns a *Func describing the function that contains the // given program counter address, or else nil. +// +// If pc represents multiple functions because of inlining, it returns +// the *Func describing the outermost frame at pc. func FuncForPC(pc uintptr) *Func { return findfunc(pc)._Func() } |