go/printer: parenthesize literal function types in conversions
Also: gofmt -w src misc
R=r
CC=golang-dev, iant
https://golang.org/cl/6591071
diff --git a/src/pkg/reflect/all_test.go b/src/pkg/reflect/all_test.go
index 5dad071..5ddd6be 100644
--- a/src/pkg/reflect/all_test.go
+++ b/src/pkg/reflect/all_test.go
@@ -1494,7 +1494,7 @@
}
// Curried method of value.
- tfunc := TypeOf(func(int) int(nil))
+ tfunc := TypeOf((func(int) int)(nil))
v := ValueOf(p).Method(1)
if tt := v.Type(); tt != tfunc {
t.Errorf("Value Method Type is %s; want %s", tt, tfunc)