Even in cases where the compiler could take the address of a value to pass to the method, if the method modifies the value the changes will be lost in the caller. As an example, if the Write method of bytes.Buffer used a value receiver rather than a pointer, this code:
var buf bytes.Buffer
io.Copy(buf, os.Stdin)
would copy standard input into a copy of buf, not into buf itself. This is almost never the desired behavior.
This is an example from Go FAQ on the differences between method sets in Go.
I do understand the difference itself, but I stil don’t really understand what the authors meant by this example.
They assume a situation where a compiler could take the address, but then also assume that the Write method is defined with a value receiver. In this case, there is no need to take any addresses, right?
The call to Copy will just work and do nothing useful. That sort of makes the example clear, but not very useful in the context of what was said before in the paragraph.
Is that just a bad turn of phrase?
A more logical example in my opinion would be saying that allowing this call would yield unexpected results.