-
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
cmd/compile: better error message for invalid for i,j,k := range
#50372
Comments
Thanks for reporting this. It triggers an internal compiler error on go1.17.5, but tip correctly gives an error:
Since the program is invalid, this may not qualify for a fix in a 1.17 minor release. |
for i,j,k := range
@randall77 @griesemer per owners. |
I agree with @ALTree , I don't think there's anything to fix here. |
The error message here should be better: an "invalid AST" error is typically expected for ASTs that are created "manually" (not by the parser) and are incorrect. I'm going to re-open this as a reminder to fix error message. |
for i,j,k := range
for i,j,k := range
Change https://golang.org/cl/375255 mentions this issue: |
Change https://golang.org/cl/375475 mentions this issue: |
…lause Fixes golang#50372. Change-Id: I8e4c0020dae42744cce016433e398e0b884bb044 Reviewed-on: https://go-review.googlesource.com/c/go/+/375475 Trust: Robert Griesemer <gri@golang.org> Reviewed-by: Robert Findley <rfindley@google.com>
Does this issue reproduce with the latest release?
yes
What did you do?
What did you see?
./prog.go:15:14: internal compiler error: expected an error about map2[k]
The text was updated successfully, but these errors were encountered: