| 1 |
// Copyright 2016 The Go Authors. All rights reserved. |
| 2 |
// Use of this source code is governed by a BSD-style |
| 3 |
// license that can be found in the LICENSE file. |
| 4 |
|
| 5 |
//go:build ignore |
| 6 |
|
| 7 |
package main |
| 8 |
|
| 9 |
// // No C code required. |
| 10 |
import "C" |
| 11 |
|
| 12 |
func FuncInt() int { return 1 } |
| 13 |
|
| 14 |
// Add a recursive type to check that type equality across plugins doesn't |
| 15 |
// crash. See https://golang.org/issues/19258 |
| 16 |
func FuncRecursive() X { return X{} } |
| 17 |
|
| 18 |
type Y struct { |
| 19 |
X *X |
| 20 |
} |
| 21 |
type X struct { |
| 22 |
Y Y |
| 23 |
} |
| 24 |
|
| 25 |
func main() {} |