If you did:
var i I
// initialize i
i.f1()
Embedding I1 and I2 exposes their methods/fields as members of I. So when you
do i.f1(), which f1 method should be called?
> On Aug 18, 2016, at 1:41 PM, T L <[email protected]> wrote:
>
>
> package main
>
> type I1 interface {
> f1()
> fa()
> }
>
> type I2 interface {
> f1()
> fb()
> }
>
> type I interface {
> I1
> I2
> } // error: duplicate method f1
>
>
> func main() {
> }
>
> --
> You received this message because you are subscribed to the Google Groups
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.