1
0
mirror of https://github.com/golang/go synced 2024-11-18 18:54:42 -07:00
go/internal/lsp/source
Rebecca Stambler 59ae353e8e internal/lsp: recreate the view when needed
If the initial workspace load fails (due to a lack of a go.mod file or
an invalid go.mod file), we should try to re-load as changes to the
go.mod come in. Rather than retrying within the view, we just drop the
view entirely and try to recreate it. This shouldn't lead to any
noticeable lag, as anything that has been cached can still be reused.

Fixes golang/go#36531

Change-Id: I6e157075e8b3665f0ceef35e051e56ac3c29f286
Reviewed-on: https://go-review.googlesource.com/c/tools/+/216037
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Heschi Kreinick <heschi@google.com>
2020-01-23 21:53:29 +00:00
..
comment_test.go internal/lsp: convert comments to markdown before sending to client 2019-10-04 18:35:38 +00:00
comment.go internal/lsp: convert comments to markdown before sending to client 2019-10-04 18:35:38 +00:00
completion_builtin.go internal/lsp/cache: initialize view before LookupBuiltin 2020-01-16 00:42:58 +00:00
completion_format.go internal/lsp/source: support dereferencing for completion 2020-01-22 21:43:17 +00:00
completion_keywords.go internal/lsp: sort by label after score 2019-12-30 21:11:21 +00:00
completion_labels.go internal/lsp: sort by label after score 2019-12-30 21:11:21 +00:00
completion_literal.go internal/lsp/source: rename "typeInference" to "candidateInference" 2020-01-21 20:43:48 +00:00
completion_snippet.go internal/lsp: merge completion options into source.Options 2020-01-13 20:09:44 +00:00
completion.go internal/lsp/source: support dereferencing for completion 2020-01-22 21:43:17 +00:00
deep_completion.go internal/lsp: merge completion options into source.Options 2020-01-13 20:09:44 +00:00
diagnostics.go internal/lsp: use correct file identities when computing diagnostics 2020-01-21 20:00:43 +00:00
errors.go internal/lsp: do not invoke the Go command when checking common errors 2020-01-17 21:23:25 +00:00
folding_range.go internal/lsp: eliminate source.File type and move GetFile to snapshot 2019-12-19 20:51:25 +00:00
format_test.go internal/lsp/source: trim file very carefully 2020-01-17 20:34:13 +00:00
format.go internal/lsp/source: trim file very carefully 2020-01-17 20:34:13 +00:00
highlight.go internal/lsp: add highlighting for import statement 2020-01-17 17:07:20 +00:00
hover.go internal/lsp: show comments for grouped variable declarations 2019-12-18 20:39:36 +00:00
identifier.go internal/lsp: refactor find-references and rename 2020-01-16 06:24:15 +00:00
implementation.go internal/lsp: refactor find-references and rename 2020-01-16 06:24:15 +00:00
options.go internal/lsp/source: enable unimported completions by default 2020-01-17 22:05:05 +00:00
references.go internal/lsp/source: return obj decl first in find-references 2020-01-16 16:57:51 +00:00
rename_check.go internal/lsp: improve literal func completion candidates 2019-11-07 21:18:00 +00:00
rename.go internal/lsp: refactor find-references and rename 2020-01-16 06:24:15 +00:00
signature_help.go internal/lsp/cache: initialize view before LookupBuiltin 2020-01-16 00:42:58 +00:00
source_test.go internal/lsp: batch file changes in didChangeWatchedFiles 2020-01-23 20:51:52 +00:00
symbols.go internal/lsp/source: always look up mapper when building ranges 2020-01-16 01:10:02 +00:00
util.go internal/lsp/source: fix typeIsValid() inf recursion 2020-01-21 04:27:40 +00:00
view.go internal/lsp: recreate the view when needed 2020-01-23 21:53:29 +00:00