Please answer these questions before submitting your issue. Thanks!
tmp/sandbox815323628/main.go:4:13: undefined: G
tmp/sandbox815323628/main.go:6:5: internal compiler error: unexpected Interface for <nil>
goroutine 1 [running]:
runtime/debug.Stack(0x0, 0x0, 0x0)
/usr/local/go/src/runtime/debug/stack.go:24 +0xa7
cmd/compile/internal/gc.Fatalf(0xb654a1, 0x1b, 0xc4202fc0e8, 0x1, 0x1)
/usr/local/go/src/cmd/compile/internal/gc/subr.go:181 +0x230
cmd/compile/internal/gc.Val.Interface(0x0, 0x0, 0xc4202fc2e8, 0xc4202fc318)
/usr/local/go/src/cmd/compile/internal/gc/const.go:99 +0x2df
cmd/compile/internal/gc.checkDupExprCases(0xc4202cee80, 0xc42000c548, 0x1, 0x1)
/usr/local/go/src/cmd/compile/internal/gc/swt.go:628 +0x5ad
cmd/compile/internal/gc.typecheckswitch(0xc4202ceb80)
/usr/local/go/src/cmd/compile/internal/gc/swt.go:210 +0x13a8
cmd/compile/internal/gc.typecheck1(0xc4202ceb80, 0x1, 0xc4202cea80)
/usr/local/go/src/cmd/compile/internal/gc/typecheck.go:2157 +0xc871
cmd/compile/internal/gc.typecheck(0xc4202ceb80, 0x1, 0xc4202cea80)
/usr/local/go/src/cmd/compile/internal/gc/typecheck.go:201 +0x764
cmd/compile/internal/gc.typecheckslice(0xc4202c7b40, 0x3, 0x4, 0x1)
/usr/local/go/src/cmd/compile/internal/gc/typecheck.go:55 +0x54
cmd/compile/internal/gc.Main(0xb73f98)
/usr/local/go/src/cmd/compile/internal/gc/main.go:480 +0x1fd0
main.main()
/usr/local/go/src/cmd/compile/main.go:49 +0x95
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version)?Playground
Does this issue reproduce with the latest release?
Yes
What did you do?
Ran https://play.golang.org/p/0Cq3cm9-bo
What did you expect to see?
main.go:4:13: undefined: GWhat did you see instead?