]> Cypherpunks.ru repositories - gostls13.git/commit
unsafe: allow unsafe.Slice up to end of address space
authorMatthew Dempsky <mdempsky@google.com>
Tue, 12 Oct 2021 22:31:25 +0000 (15:31 -0700)
committerMatthew Dempsky <mdempsky@google.com>
Wed, 13 Oct 2021 18:15:16 +0000 (18:15 +0000)
commit4efa216c9d753c0853aa96a8c54ed5014fbc12e6
tree36177e48d0ba8cdbbbea140f870c7b882f329d48
parent4a3daeee636751a262eb9f77d8e90c59955ee6bb
unsafe: allow unsafe.Slice up to end of address space

Allow the user to construct slices that are larger than the Go heap as
long as they don't overflow the address space.

Updates #48798.

Change-Id: I659c8334d04676e1f253b9c3cd499eab9b9f989a
Reviewed-on: https://go-review.googlesource.com/c/go/+/355489
Trust: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/slice.go
test/unsafebuiltins.go