test: don't assign address of array to slice.
R=rsc
CC=golang-dev
https://golang.org/cl/2084042
diff --git a/test/ken/array.go b/test/ken/array.go
index 7785cdf..40209f5 100644
--- a/test/ken/array.go
+++ b/test/ken/array.go
@@ -81,8 +81,8 @@
// call ptr dynamic with ptr fixed from new
func testpdpf1() {
a := new([40]int)
- setpd(a)
- res(sumpd(a), 0, 40)
+ setpd(a[0:])
+ res(sumpd(a[0:]), 0, 40)
b := (*a)[5:30]
res(sumpd(b), 5, 30)
@@ -92,8 +92,8 @@
func testpdpf2() {
var a [80]int
- setpd(&a)
- res(sumpd(&a), 0, 80)
+ setpd(a[0:])
+ res(sumpd(a[0:]), 0, 80)
}
// generate bounds error with ptr dynamic