mirror of https://github.com/golang/go.git
Due to the limitations of comments in ast, it is difficult to move comments. The extract function feature currently does not handle comments at all. This change instead prints the comments that would have been lost above the call to the function, so that the user can easily recover them. Otherwise, it was possible for users to lose comments and not notice. Updates golang/go#37170 Change-Id: I1e2d865f5deddefbb0417732490decbdfcde5f3d Reviewed-on: https://go-review.googlesource.com/c/tools/+/313211 Trust: Suzy Mueller <suzmue@golang.org> Run-TryBot: Suzy Mueller <suzmue@golang.org> gopls-CI: kokoro <noreply+kokoro@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org> |
||
|---|---|---|
| .. | ||
| extract_function | ||
| extract_variable | ||