commit | 91e56e6486a24a9e8cced7197df7cef6cba6da1a | [log] [tgz] |
---|---|---|
author | Dmitriy Vyukov <dvyukov@google.com> | Sun Jul 01 21:59:50 2012 +0400 |
committer | Dmitriy Vyukov <dvyukov@google.com> | Sun Jul 01 21:59:50 2012 +0400 |
tree | bbce646c86ec8eaede07592cff6f74ead3d7ff7e | |
parent | ed516df4e43c5e3467bd6a39ffc9277157574788 [diff] [blame] |
test: enforce 1 proc in the test otherwise it fails spuriously with "newfunc allocated unexpectedly" message when run with GOMAXPROCS>1 (other goroutine allocates). R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/6347056
diff --git a/test/closure.go b/test/closure.go index ae38900..c4a3124 100644 --- a/test/closure.go +++ b/test/closure.go
@@ -81,6 +81,7 @@ func newfunc() func(int) int { return func(x int) int { return x } } func main() { + runtime.GOMAXPROCS(1) var fail bool go f()