go issue12108 源码
golang issue12108 代码
文件路径:/test/fixedbugs/issue12108.go
// run
// Copyright 2015 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.
// A generated method with a return value large enough to be
// initialized by duffzero is not a leaf method, which violated
// assumptions made by cmd/internal/obj/ppc64.
package main
const N = 9 // values > 8 cause (Super).Method to use duffzero
type Base struct {
}
func (b *Base) Method() (x [N]uintptr) {
return
}
type Super struct {
Base
}
type T interface {
Method() [N]uintptr
}
func f(q T) {
q.Method()
}
func main() {
var s Super
f(&s)
}
相关信息
相关文章
0
赞
热门推荐
-
2、 - 优质文章
-
3、 gate.io
-
8、 golang
-
9、 openharmony
-
10、 Vue中input框自动聚焦