-
Notifications
You must be signed in to change notification settings - Fork 17.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
go/types: missing error message for incorrect (generic) program #45635
Comments
This is a panic in the go2go type checker. The current type checker reports an error ( |
Well
is quite cryptic for the end user in my opinion, so I think it's definitely worth improving. Note, again, that it works fine with single parameter identifiers. What's more important is that this seems to also break references to identifiers in different packages. |
I don't see that error on tip. Which version of the program are you testing? |
@rvolosatovs This is working as expected on tip (types2, and compiler with -G=3 option). It doesn't produce any error message with go/types at the moment, and that seems like a bug. What you are seeing is likely due to running a version that is not fully up-to-date. The |
@findleyr This program: package main
func main() {
some[int, int]()
} doesn't seem to produce an error message with |
Change https://golang.org/cl/311669 mentions this issue: |
Change https://golang.org/cl/312149 mentions this issue: |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Panics(two or more parameters): https://go2goplay.golang.org/p/gc3cZ-qe5bG
Works: https://go2goplay.golang.org/p/AQ_JWojgRic
Prints correct error(single parameter): https://go2goplay.golang.org/p/bW2i30OWP6F
What did you expect to see?
The first example should print an error same as last one
Note, that calls to identifiers defined in imported packages with multiple parameters fail with the same error
What did you see instead?
Panic in parser
The text was updated successfully, but these errors were encountered: