go/types: improve errors for method calls with pointer receivers
The compiler has better error messages for methods called without a pointer receiver when one is expected. This change is similar to CL 229801, but for method calls. Also, added better error messages for functions called with the wrong capitalization. I left the third TODO in this switch statement almost as-is because I'm not sure that the extra complexity is worth it - I adjusted the error to look like the one the compiler reports. Fixes golang/go#38658 Change-Id: Ie0ca2503e12f3659f112f0135cc27db1b027fdcb Reviewed-on: https://go-review.googlesource.com/c/go/+/230380 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:Robert Griesemer <gri@golang.org>
Loading
Please sign in to comment