File tree Expand file tree Collapse file tree 5 files changed +104
-1
lines changed Expand file tree Collapse file tree 5 files changed +104
-1
lines changed Original file line number Diff line number Diff line change @@ -2,4 +2,7 @@ module github.com/bigwhite/experiments
2
2
3
3
go 1.12
4
4
5
- require github.com/bigwhite/gocmpp v0.0.0-20190917110902-55b5d3d9ff3b
5
+ require (
6
+ github.com/bigwhite/gocmpp v0.0.0-20190917110902-55b5d3d9ff3b
7
+ github.com/codeskyblue/go-sh v0.0.0-20190412065543-76bd3d59ff27
8
+ )
Original file line number Diff line number Diff line change @@ -16,6 +16,10 @@ github.com/bwmarrin/snowflake v0.3.0/go.mod h1:NdZxfVWX+oR6y2K0o6qAYv6gIOP9rjG0/
16
16
github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible /go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag =
17
17
github.com/circonus-labs/circonusllhist v0.1.3 /go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I =
18
18
github.com/client9/misspell v0.3.4 /go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw =
19
+ github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0 h1:sDMmm+q/3+BukdIpxwO365v/Rbspp2Nt5XntgQRXq8Q =
20
+ github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0 /go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM =
21
+ github.com/codeskyblue/go-sh v0.0.0-20190412065543-76bd3d59ff27 h1:HHUr4P/aKh4quafGxDT9LDasjGdlGkzLbfmmrlng3kA =
22
+ github.com/codeskyblue/go-sh v0.0.0-20190412065543-76bd3d59ff27 /go.mod h1:VQx0hjo2oUeQkQUET7wRwradO6f+fN5jzXgB/zROxxE =
19
23
github.com/coreos/bbolt v1.3.3 /go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk =
20
24
github.com/coreos/etcd v3.3.15+incompatible /go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE =
21
25
github.com/coreos/go-semver v0.3.0 /go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk =
@@ -166,6 +170,7 @@ golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7w
166
170
golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3 /go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs =
167
171
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456 /go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs =
168
172
golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe /go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs =
173
+ golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg =
169
174
golang.org/x/text v0.3.0 /go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ =
170
175
golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs =
171
176
golang.org/x/text v0.3.2 /go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk =
Original file line number Diff line number Diff line change
1
+ package foo
2
+
3
+ type I interface {
4
+ f ()
5
+ String () string
6
+ }
7
+ type J interface {
8
+ g ()
9
+ String () string
10
+ }
11
+
12
+ type IJ interface {
13
+ I
14
+ J
15
+ }
Original file line number Diff line number Diff line change
1
+ package main
2
+
3
+ type I interface {
4
+ f ()
5
+ String () string
6
+ }
7
+
8
+ type implOfI struct {}
9
+
10
+ func (implOfI ) f () {}
11
+ func (implOfI ) String () string {
12
+ return "implOfI"
13
+ }
14
+
15
+ type J interface {
16
+ g ()
17
+ String () string
18
+ }
19
+
20
+ type implOfJ struct {}
21
+
22
+ func (implOfJ ) g () {}
23
+ func (implOfJ ) String () string {
24
+ return "implOfJ"
25
+ }
26
+
27
+ type Foo struct {
28
+ I
29
+ J
30
+ }
31
+
32
+ func main () {
33
+ f := Foo {
34
+ I : implOfI {},
35
+ J : implOfJ {},
36
+ }
37
+ println (f .String ())
38
+ }
Original file line number Diff line number Diff line change
1
+ package main
2
+
3
+ type I interface {
4
+ f ()
5
+ String () string
6
+ }
7
+
8
+ type implOfI struct {}
9
+
10
+ func (implOfI ) f () {}
11
+ func (implOfI ) String () string {
12
+ return "implOfI"
13
+ }
14
+
15
+ type J interface {
16
+ g ()
17
+ String () string
18
+ }
19
+
20
+ type implOfJ struct {}
21
+
22
+ func (implOfJ ) g () {}
23
+ func (implOfJ ) String () string {
24
+ return "implOfJ"
25
+ }
26
+
27
+ type Foo struct {
28
+ I
29
+ J
30
+ }
31
+
32
+ func (Foo ) String () string {
33
+ return "Foo"
34
+ }
35
+
36
+ func main () {
37
+ f := Foo {
38
+ I : implOfI {},
39
+ J : implOfJ {},
40
+ }
41
+ println (f .String ())
42
+ }
You can’t perform that action at this time.
0 commit comments