init
This commit is contained in:
29
src/testfile/main.go
Normal file
29
src/testfile/main.go
Normal file
@@ -0,0 +1,29 @@
|
||||
package main
|
||||
|
||||
// MyStruct 介绍
|
||||
type MyStruct struct {
|
||||
Value int
|
||||
Key string
|
||||
Do func(
|
||||
a int,
|
||||
b struct{ A, B int })
|
||||
S struct{ A int }
|
||||
}
|
||||
|
||||
// ExStruct 升级
|
||||
type ExStruct struct {
|
||||
ChildStruct struct {
|
||||
A int
|
||||
B interface{}
|
||||
}
|
||||
}
|
||||
|
||||
// SetChildStructA set
|
||||
func (e *ExStruct) SetChildStructA(a int) {
|
||||
e.ChildStruct.A = a
|
||||
}
|
||||
|
||||
func main() {
|
||||
a := ExStruct{}
|
||||
println(a)
|
||||
}
|
||||
0
src/testfile/main.java
Normal file
0
src/testfile/main.java
Normal file
Reference in New Issue
Block a user