mirror of
https://github.com/golang/go
synced 2024-11-05 16:16:11 -07:00
f8e0ea3a3a
Getting the right indentation for the text in the AST proves to be a little complicated. The most reasonable approach seems to be writing out the AST, getting the lines with the struct definition on it, and trimming whitespace to get the current indent. Then, we add this indent to the struct fields in the new text. Change-Id: I1cc3421d95edae61cfb662254ff3fb759b5c487f Reviewed-on: https://go-review.googlesource.com/c/tools/+/239199 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Heschi Kreinick <heschi@google.com> |
||
---|---|---|
.. | ||
testdata/src/a | ||
undeclared_test.go | ||
undeclared.go |