summaryrefslogtreecommitdiff
path: root/test/recover2.go
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2011-11-01 22:06:05 -0400
committerRuss Cox <rsc@golang.org>2011-11-01 22:06:05 -0400
commitbff16976d902e297999e2813ead7f161ab619f18 (patch)
treea72976dffc1751229bb1f25a64290af6928e9be6 /test/recover2.go
parent35b030f60c6ba41d1f003cfca5cca64e025a51e8 (diff)
downloadgo-bff16976d902e297999e2813ead7f161ab619f18.tar.gz
non-pkg: gofix -r error -force=error
R=golang-dev, iant, r, r CC=golang-dev http://codereview.appspot.com/5307066
Diffstat (limited to 'test/recover2.go')
-rw-r--r--test/recover2.go7
1 files changed, 2 insertions, 5 deletions
diff --git a/test/recover2.go b/test/recover2.go
index 9affe25d4..ccaf8ced1 100644
--- a/test/recover2.go
+++ b/test/recover2.go
@@ -11,10 +11,7 @@
package main
-import (
- "os"
- "strings"
-)
+import "strings"
var x = make([]byte, 10)
@@ -33,7 +30,7 @@ func mustRecover(s string) {
if v == nil {
panic("expected panic")
}
- if e := v.(os.Error).String(); strings.Index(e, s) < 0 {
+ if e := v.(error).Error(); strings.Index(e, s) < 0 {
panic("want: " + s + "; have: " + e)
}
}