mirror of https://github.com/golang/go.git
If the selected region is a block statement, gopls does not return a valid function extraction. This change adjusts the range to be the statements inside of the selected block statement. Fixes golang/go#48963 Change-Id: I9b1fb5005f961f30c1fa0333cd1f2050ed5eedef Reviewed-on: https://go-review.googlesource.com/c/tools/+/357615 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_method | ||
| extract_variable | ||