-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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: error in Go 1.23.0 with generics, type aliases and indexing #68903
Comments
@gopherbot Please open a backport to the 1.23 release. This appears to be a regression in the compiler. |
Backport issue(s) opened: #68905 (for 1.23). Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases. |
Thank you for the report. This looks like a bug in You can get the 1.22 behavior by overriding the 1.23 default |
Change https://go.dev/cl/606075 mentions this issue: |
Change https://go.dev/cl/607635 mentions this issue: |
Go version
go1.23.0
Output of
go env
in your module/workspace:Can be seen in Go Playground
What did you do?
See: https://go.dev/play/p/cFkeJ6ppEBk
What did you see happen?
This compiler error is seen on Go 1.23:
The program compiles and runs as expected on Go 1.22.
If we move the type definition of
A
to a different package then the code runs fine in Go 1.23:https://go.dev/play/p/l_x4F190M3y
What did you expect to see?
There should be no compilation error.
The text was updated successfully, but these errors were encountered: