-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Open
Labels
BadErrorMessageIssues related compiler error messages that should be better.Issues related compiler error messages that should be better.BugReportIssues describing a possible bug in the Go implementation.Issues describing a possible bug in the Go implementation.compiler/runtimeIssues related to the Go compiler and/or runtime.Issues related to the Go compiler and/or runtime.
Milestone
Description
Go version
go version go1.24.1 linux/amd64
Output of go env
in your module/workspace:
AR='ar'
CC='gcc'
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_ENABLED='1'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
CXX='g++'
GCCGO='gccgo'
GO111MODULE=''
GOAMD64='v1'
GOARCH='amd64'
GOAUTH='netrc'
GOBIN=''
GOCACHE='/home/andrew/.cache/go-build'
GOCACHEPROG=''
GODEBUG=''
GOENV='/home/andrew/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFIPS140='off'
GOFLAGS=''
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build2188541391=/tmp/go-build -gno-record-gcc-switches'
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMOD='/home/andrew/git/src/github.com/meln5674/goj-compiler-bug/go.mod'
GOMODCACHE='/home/andrew/git/pkg/mod'
GONOPROXY='github.com/meln5675/*'
GONOSUMDB='github.com/meln5675/*'
GOOS='linux'
GOPATH='/home/andrew/git/'
GOPRIVATE='github.com/meln5675/*'
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/usr/local/go-1.24.1'
GOSUMDB='sum.golang.org'
GOTELEMETRY='off'
GOTELEMETRYDIR='/home/andrew/.config/go/telemetry'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/usr/local/go-1.24.1/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.24.1'
GOWORK=''
PKG_CONFIG='pkg-config'
What did you do?
https://go.dev/play/p/oCCeMP7r2Jk
This is not the original source this defect was discovered in, which is not publicly releasable. The above was derived by removing source elements until the error no longer occurred and then anonymizing names.
A few previous versions of go that I happened to have installed were spot checked across 1.23 and 1.22 and they all produced internal errors, so this is likely not a regression in 1.24.1 .
What did you see happen?
Received the following error message:
# <REDACTED: root package of module>
<unknown line number>: internal compiler error: unexpected types2.Invalid
Please file a bug report including a short program that triggers the error.
https://go.dev/issue/new
This occurs identically locally and in the linked go playground.
What did you expect to see?
The command to either succeed or produce a usable error message.
Metadata
Metadata
Labels
BadErrorMessageIssues related compiler error messages that should be better.Issues related compiler error messages that should be better.BugReportIssues describing a possible bug in the Go implementation.Issues describing a possible bug in the Go implementation.compiler/runtimeIssues related to the Go compiler and/or runtime.Issues related to the Go compiler and/or runtime.
Type
Projects
Status
In Progress