go/internal/lsp/testdata
Rebecca Stambler f8e0ea3a3a internal/lsp/analysis/fillstruct: add indentation for struct fields
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>
2020-06-23 20:47:33 +00:00
..
indirect internal/lsp: plumb fillstruct through analysis 2020-06-15 21:22:08 +00:00
lsp internal/lsp/analysis/fillstruct: add indentation for struct fields 2020-06-23 20:47:33 +00:00
missingdep internal/lsp: plumb fillstruct through analysis 2020-06-15 21:22:08 +00:00
missingtwodep internal/lsp: plumb fillstruct through analysis 2020-06-15 21:22:08 +00:00
unused internal/lsp: plumb fillstruct through analysis 2020-06-15 21:22:08 +00:00
upgradedep internal/lsp: plumb fillstruct through analysis 2020-06-15 21:22:08 +00:00