Source file test/fixedbugs/issue22200.go
1 // errorcheck 2 3 // Copyright 2017 The Go Authors. All rights reserved. 4 // Use of this source code is governed by a BSD-style 5 // license that can be found in the LICENSE file. 6 7 package p 8 9 func f1(x *[1<<30 - 1e6]byte) byte { 10 sum := byte(0) 11 for _, b := range *x { 12 sum += b 13 } 14 return sum 15 } 16 func f2(x *[1<<30 + 1e6]byte) byte { // GC_ERROR "stack frame too large" 17 sum := byte(0) 18 for _, b := range *x { 19 sum += b 20 } 21 return sum 22 } 23