mirror of
https://github.com/golang/go
synced 2024-11-22 20:24:47 -07:00
test: add test that caused a gofrontend internal error
For #44383 Change-Id: I3610105dad3574e210e226d3ba80a4ba5a7eeaa6 Reviewed-on: https://go-review.googlesource.com/c/go/+/300789 Trust: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>
This commit is contained in:
parent
0fc370c5d2
commit
415ca3f1f0
18
test/fixedbugs/issue44383.go
Normal file
18
test/fixedbugs/issue44383.go
Normal file
@ -0,0 +1,18 @@
|
||||
// compile
|
||||
|
||||
// Copyright 2021 The Go Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
// Issue 44383: gofrontend internal compiler error
|
||||
|
||||
package main
|
||||
|
||||
func main() {
|
||||
var b1, b2 byte
|
||||
f := func() int {
|
||||
var m map[byte]int
|
||||
return m[b1/b2]
|
||||
}
|
||||
f()
|
||||
}
|
Loading…
Reference in New Issue
Block a user