ast/printer: support for printing ast.Spec nodes
R=gri
CC=golang-dev
https://golang.org/cl/682041
diff --git a/src/pkg/go/printer/printer.go b/src/pkg/go/printer/printer.go
index 3bb51b4..4c530d2 100644
--- a/src/pkg/go/printer/printer.go
+++ b/src/pkg/go/printer/printer.go
@@ -1018,6 +1018,9 @@
case ast.Decl:
p.useNodeComments = true
p.decl(n, atTop, ignoreMultiLine)
+ case ast.Spec:
+ p.useNodeComments = true
+ p.spec(n, 1, atTop, false, ignoreMultiLine)
case *ast.File:
p.comments = n.Comments
p.useNodeComments = n.Comments == nil