3 // Copyright 2016 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
7 // This checks partially initialized structure literals
8 // used to create value.method functions have their
9 // non-initialized fields properly zeroed/nil'd
20 panic("t.B must be nil")
25 func caller(f func()) {
33 caller(func() { X{A: &i, C: &j}.Print() })
34 caller(X{A: &i, C: &j}.Print)