]> Cypherpunks repositories - gostls13.git/commit
runtime: make test independent of inlining
authorDavid Lazar <lazard@golang.org>
Wed, 19 Apr 2017 16:04:18 +0000 (12:04 -0400)
committerDavid Lazar <lazard@golang.org>
Thu, 20 Apr 2017 20:41:15 +0000 (20:41 +0000)
commitda75700a641c7e2bd264dd873d637abfcbfffab1
tree1ef0f26ddfc21fcc1facd8a9788e762dc90161d1
parent6f2e6f8dd6d2b0fc1b32447c4ed38231fde4a3c2
runtime: make test independent of inlining

TestBreakpoint expects to see "runtime.Breakpoint()" in the stack trace.
If runtime.Breakpoint() is inlined, then the stack trace prints
"runtime.Breakpoint(...)" since the runtime does not have information
about arguments (or lack thereof) to inlined functions. This change
makes the test independent of inlining by looking for the string
"runtime.Breakpoint(". Now TestBreakpoint passes with -l=4.

Change-Id: Ia044a8e8a4de2337cb2b393d6fa78c73a2f25926
Reviewed-on: https://go-review.googlesource.com/40997
Run-TryBot: David Lazar <lazard@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
src/runtime/crash_test.go