mirror of
https://github.com/golang/go.git
synced 2026-04-03 17:59:55 +09:00
types2 handles all constant-related bounds checks in user Go code now, so it's safe to remove all constants checking in tcSliceHeader function. Fixed #77919 Change-Id: Ibc137c84792d4898eb073cdeabac175684f73746 Reviewed-on: https://go-review.googlesource.com/c/go/+/751040 Reviewed-by: Keith Randall <khr@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Cherry Mui <cherryyz@google.com> Reviewed-by: Keith Randall <khr@golang.org> Auto-Submit: Cuong Manh Le <cuong.manhle.vn@gmail.com>
16 lines
271 B
Go
16 lines
271 B
Go
// compile
|
|
|
|
// Copyright 2026 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.
|
|
|
|
package main
|
|
|
|
var sink any
|
|
|
|
func main() {
|
|
i := 0
|
|
output := make([]string, 8, i)
|
|
sink = output
|
|
}
|