printer: simplify indenting of objects

This commit is contained in:
Fatih Arslan 2015-10-25 16:13:06 +03:00
parent 4d7ec81122
commit 2ea5683566

View File

@ -70,13 +70,7 @@ func (p *printer) printObjectType(o *ast.ObjectType) []byte {
buf.WriteByte(newline) buf.WriteByte(newline)
for _, item := range o.List.Items { for _, item := range o.List.Items {
// buf.WriteByte(tab) buf.Write(indent(p.printObjectItem(item)))
// buf.Write(p.printObjectItem(item))
a := p.printObjectItem(item)
a = indent(a)
buf.Write(a)
buf.WriteByte(newline) buf.WriteByte(newline)
} }