mirror of
https://github.com/golang/go
synced 2024-11-08 18:26:14 -07:00
0ba4eba864
Updates #22389 @mdempsky's CL 70850 fixed the unnecessary compile stack trace printing during ICE diagnostics. This CL adds a test to lock in this behavior. Change-Id: I9ce49923c80b78cb8c0bb5dc4af3c860a43d63ba Reviewed-on: https://go-review.googlesource.com/74630 Run-TryBot: Emmanuel Odeke <emm.odeke@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
19 lines
327 B
Go
19 lines
327 B
Go
// errorcheck
|
|
|
|
// Copyright 2017 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
package p
|
|
|
|
type Foo struct{}
|
|
|
|
func (f *Foo) Call(cb func(*Foo)) {
|
|
cb(f)
|
|
}
|
|
|
|
func main() {
|
|
f := &Foo{}
|
|
f.Call(func(f) {}) // ERROR "f is not a type"
|
|
}
|