Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/compile: casts from slices to array pointers are known to be non-nil
The cast is proceeded by a bounds check. If the bounds check passes then we know the pointer in the slice is non-nil. ... except casts to pointers of 0-sized arrays. They are strange, as the bounds check can pass for a nil input. Change-Id: Ic01cf4a82d59fbe3071d4b271c94efca9cafaec1 Reviewed-on: https://go-review.googlesource.com/c/go/+/479335 Run-TryBot: Keith Randall <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Keith Randall <[email protected]> Reviewed-by: Cuong Manh Le <[email protected]> Auto-Submit: Keith Randall <[email protected]> Reviewed-by: Matthew Dempsky <[email protected]>
- Loading branch information