mirror of
https://github.com/golang/go
synced 2024-11-13 13:20:39 -07:00
test: add test that caused a gofrontend crash
Change-Id: Idd872c5b90dbca564ed8a37bb3683e642142ae63 Reviewed-on: https://go-review.googlesource.com/c/go/+/505015 Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com> Auto-Submit: Ian Lance Taylor <iant@google.com> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Ian Lance Taylor <iant@google.com>
This commit is contained in:
parent
ad2c517708
commit
633b742ae0
13
test/fixedbugs/bug516.go
Normal file
13
test/fixedbugs/bug516.go
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
// compile
|
||||||
|
|
||||||
|
// Copyright 2023 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.
|
||||||
|
|
||||||
|
// Caused a gofrontend crash.
|
||||||
|
|
||||||
|
package p
|
||||||
|
|
||||||
|
func F(b []byte, i int) {
|
||||||
|
*(*[1]byte)(b[i*2:]) = [1]byte{}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user