3 ms·
In Go you define the methods in interfaces but implementors do not have to specify that they implement a given interface. Instead any object (though Go has no
by jabbrwcky 12y ago
In Go you define the methods in interfaces but implementors do not have to specify that they implement a given interface.
Instead any object (though Go has no real objects) is considered to be an implementation of an interface iff it implements all define methods.