1
0
mirror of https://github.com/golang/go synced 2024-11-11 23:40:22 -07:00

godoc: log node printing error

Invaluable when changing template files.

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/5571044
This commit is contained in:
Robert Griesemer 2012-01-22 19:36:34 -08:00
parent 5fde5cd5cb
commit 2a9c012498

View File

@ -378,7 +378,10 @@ func writeNode(w io.Writer, fset *token.FileSet, x interface{}) {
// with an another printer mode (which is more efficiently
// implemented in the printer than here with another layer)
mode := printer.TabIndent | printer.UseSpaces
(&printer.Config{mode, *tabwidth}).Fprint(&tconv{output: w}, fset, x)
err := (&printer.Config{mode, *tabwidth}).Fprint(&tconv{output: w}, fset, x)
if err != nil {
log.Print(err)
}
}
func filenameFunc(path string) string {