On Fri, Jul 12, 2024 at 6:12 AM William Tang <
galaxyk...@gmail.com> wrote:
>
> I’m reading the current implementation of io.Copy for TCPConn. It has a struct called tcpConnWithoutWriteTo 3, which will cause the WriterTo casting from a io.Reader to fail 1. How and why does it work internally?
When there are two promoted methods with the same name, both methods
are ignored. The language spec lists the rules at
https://go.dev/ref/spec#Selectors.
Ian