From: Matthew Dempsky Date: Tue, 15 Sep 2020 02:24:55 +0000 (-0700) Subject: test: fix inline.go to pass linux-amd64-noopt X-Git-Tag: go1.16beta1~1053 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=bae9cf651796db898b1e4bd77a1a47c5f2d7b04d;p=gostls13.git test: fix inline.go to pass linux-amd64-noopt Updates #33485. Change-Id: I3330860cdff1e9797466a7630bcdb7792c465b06 Reviewed-on: https://go-review.googlesource.com/c/go/+/254938 Run-TryBot: Matthew Dempsky Reviewed-by: Cuong Manh Le TryBot-Result: Go Bot Trust: Matthew Dempsky --- diff --git a/test/inline.go b/test/inline.go index 1c5c1bc8d3..3edcf2edfd 100644 --- a/test/inline.go +++ b/test/inline.go @@ -10,7 +10,6 @@ package foo import ( - "errors" "runtime" "unsafe" ) @@ -50,7 +49,7 @@ func j(x int) int { // ERROR "can inline j" } } -var somethingWrong error = errors.New("something went wrong") // ERROR "can inline init" "inlining call to errors.New" "errors.errorString.* escapes to heap" +var somethingWrong error // local closures can be inlined func l(x, y int) (int, int, error) {