3 comments

[ 290 ms ] story [ 1152 ms ] thread
FWIW, I gather that contemporary Go docs have stopped using the phrase "duck typing" because it has too much of a dynamic connotation to convey what Go in fact does ("structural typing").
Correct. An io.Reader doesn't just look and sound like a Reader. It _is_ a reader.
If it looks like duck typing, and it sounds like duck typing, ... that's good enough for duck typing.