tools/internal/lsp
Muir Manders eda2c2f1ae internal/lsp: fix completion insertion with non-identifier suffix
Completions like "foo.Bar(baz.<>)" were replacing one too many
characters resulting in "foo.Bar(baz.Qux()". This is because the go
parser adds a phantom "_" identifier when parsing "foo.". We thought
the "_" was really there, so we were issuing text edits to replace
it. Fix by ignoring "_" selectors when the cursor is positioned to
their left.

Fixes microsoft/vscode-go#2525

Change-Id: I1233a9d6275e2a79b666ca0230862238160b4aab
GitHub-Last-Rev: de9a3f00187b1b9bfcc4e497461f4602ae6f8923
GitHub-Pull-Request: golang/tools#104
Reviewed-on: https://go-review.googlesource.com/c/tools/+/178217
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-05-20 21:53:15 +00:00
..
browser internal/lsp: add version and bug commands 2019-05-11 04:16:02 +00:00
cache internal/lsp: support definitions and hover for builtins 2019-05-17 00:35:10 +00:00
cmd internal/lsp: fix race in delivering diagnostics to the command line client 2019-05-20 19:38:31 +00:00
diff internal/lsp: normalise and make public diff<->edit conversions 2019-04-15 20:31:36 +00:00
protocol internal/lsp: update column mapper with content on incremental changes 2019-05-20 19:04:59 +00:00
snippet internal/lsp: introduce snippet builder object 2019-04-25 18:37:29 +00:00
source internal/lsp: fix completion insertion with non-identifier suffix 2019-05-20 21:53:15 +00:00
testdata internal/lsp: fix completion insertion 2019-05-17 18:32:58 +00:00
tests internal/lsp: fix completion insertion 2019-05-17 18:32:58 +00:00
xlog internal/lsp: add the ability to log back to the client 2019-04-01 16:22:08 +00:00
code_action.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
completion.go internal/lsp: fix completion insertion 2019-05-17 18:32:58 +00:00
definition.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
diagnostics.go internal/lsp: fix swallowed package errors 2019-05-17 18:33:31 +00:00
format.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
general.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
highlight.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
hover.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
info.1.11.go internal/lsp: add version and bug commands 2019-05-11 04:16:02 +00:00
info.go internal/lsp: add version and bug commands 2019-05-11 04:16:02 +00:00
link.go internal/lsp: add nil checks for ASTs and token 2019-05-20 20:09:54 +00:00
lsp_test.go internal/lsp: fix swallowed package errors 2019-05-17 18:33:31 +00:00
reset_golden.sh internal/lsp: fix definition tests to use golden files 2019-05-10 21:06:55 +00:00
server.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
signature_help.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
symbols.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00
text_synchronization.go internal/lsp: update column mapper with content on incremental changes 2019-05-20 19:04:59 +00:00
util.go internal/lsp: update column mapper with content on incremental changes 2019-05-20 19:04:59 +00:00
workspace.go internal/lsp: add structured layers to the cache 2019-05-16 21:30:38 +00:00