diff options
| author | Rob Pike <r@golang.org> | 2010-03-24 16:46:53 -0700 |
|---|---|---|
| committer | Rob Pike <r@golang.org> | 2010-03-24 16:46:53 -0700 |
| commit | 325cf8ef217b4e9ae2caf53fa0d4534cd5003bd8 (patch) | |
| tree | 72405fbc32b0bef0850cac2797f818bccc12b44e /test/mallocrep.go | |
| parent | acfd6d5f055ca5283dff5de16390c1d0cfc9f0ca (diff) | |
| download | go-325cf8ef217b4e9ae2caf53fa0d4534cd5003bd8.tar.xz | |
delete all uses of panicln by rewriting them using panic or,
in the tests, println+panic.
gofmt some tests too.
R=rsc
CC=golang-dev
https://golang.org/cl/741041
Diffstat (limited to 'test/mallocrep.go')
| -rw-r--r-- | test/mallocrep.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/mallocrep.go b/test/mallocrep.go index ab49aae880..e7f3f06f4e 100644 --- a/test/mallocrep.go +++ b/test/mallocrep.go @@ -24,7 +24,8 @@ func bigger() { println(st.Sys, " system bytes for ", st.Alloc, " Go bytes") } if st.Sys > 1e9 { - panicln("too big") + println("too big") + panic("fail") } } } @@ -39,7 +40,8 @@ func main() { println("First alloc:", j) } if a := runtime.MemStats.Alloc; a != 0 { - panicln("no allocations but stats report", a, "bytes allocated") + println("no allocations but stats report", a, "bytes allocated") + panic("fail") } b := runtime.Alloc(uintptr(j)) during := runtime.MemStats.Alloc |
