Skip to content

Instantly share code, notes, and snippets.

@evanphx
Created November 4, 2014 21:54
Show Gist options
  • Save evanphx/846f72b91e1c937d6459 to your computer and use it in GitHub Desktop.
Save evanphx/846f72b91e1c937d6459 to your computer and use it in GitHub Desktop.
type A interface {
Foo() int
}
type B interface {
Foo() int
}
type D interface {
Report(a A)
}
type E struct {}
func (e *E) Report(b B) { ... }
var d D = &E{} // No type error here.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment