-
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: inline static init cause compile time error #58439
Comments
The fix for #58293 only deal with the integer overflow case. |
This needs to be backport, too cc @randall77 @mdempsky @dr2chase There're a plenty of issue with inline static init happens, and although I think https://go-review.googlesource.com/c/go/+/466277 should fix them, maybe a safer way to backport is disable inline static init for go1.20, then re-enable by default during go1.21 cycle. |
Change https://go.dev/cl/466277 mentions this issue: |
I agree, probably the safest thing to do for 1.20 is just disable inline static init. We can fix for 1.21 properly. |
Disabling the optimization for 1.20 seems right to me too, unfortunately. |
@gopherbot please backport this issue to 1.20 |
Backport issue(s) opened: #58444 (for 1.20). Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases. |
Change https://go.dev/cl/467016 mentions this issue: |
Updates #58293 Updates #58339 Fixes #58439 Change-Id: I06d2d92f86fa4a672d69515c4066d69d3e0fc75b Reviewed-on: https://go-review.googlesource.com/c/go/+/467016 TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Keith Randall <khr@google.com> Reviewed-by: David Chase <drchase@google.com> Reviewed-by: Keith Randall <khr@golang.org> Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com>
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?
What did you expect to see?
Runtime error.
What did you see instead?
Compile time error.
The text was updated successfully, but these errors were encountered: