1
0
mirror of https://github.com/golang/go synced 2024-11-18 23:24:39 -07:00
go/internal/lsp/cache
Heschi Kreinick 4981f6b3ad internal/lsp/cache: consolidate snapshot cloning
Cloning is complicated enough without worrying about concurrency, so
hold the snapshot's lock during the entire process.

Consolidate everything into one function. I don't think that the split
was making it easier to understand, and I was able to see and clean up
some extra complexity once it was all in one place. Let's discuss
options if you think the result is too long.

I don't intend any semantic changes in this CL.

Updates golang/go#35638.

Change-Id: I05c4b28875976293f5fcd56248d9c9e468f85cc6
Reviewed-on: https://go-review.googlesource.com/c/tools/+/211537
Run-TryBot: Heschi Kreinick <heschi@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2019-12-16 21:51:44 +00:00
..
analysis.go internal/lsp: propagate and handle context cancellation errors 2019-12-05 22:50:56 +00:00
builtin.go internal/lsp: rename Files to CompiledGoFiles 2019-11-20 22:19:51 +00:00
cache.go internal/lsp: use options hooks to install diff driver 2019-10-11 16:38:31 +00:00
check.go internal/lsp: add diagnostic on import causing import cycle 2019-12-13 19:54:01 +00:00
error_test.go internal/lsp: refactor error handling code in type-checking 2019-10-21 18:57:46 +00:00
errors.go internal/lsp: add diagnostic on import causing import cycle 2019-12-13 19:54:01 +00:00
external.go internal/lsp: use versioned URIs in rename and code actions 2019-11-13 05:52:40 +00:00
file.go internal/lsp: modify approach to watching changed files 2019-10-22 21:33:45 +00:00
load.go internal/lsp: create parseModHandle for storing go.mod data 2019-12-13 22:03:54 +00:00
parse_mod.go internal/lsp: create parseModHandle for storing go.mod data 2019-12-13 22:03:54 +00:00
parse.go internal/lsp: create parseModHandle for storing go.mod data 2019-12-13 22:03:54 +00:00
pkg.go internal/lsp: set version correctly after textDocument/didOpen 2019-11-25 19:35:51 +00:00
session.go internal/lsp: move DidModifyFile into internal/lsp/cache 2019-12-12 03:49:59 +00:00
snapshot.go internal/lsp/cache: consolidate snapshot cloning 2019-12-16 21:51:44 +00:00
view.go internal/lsp/cache: consolidate snapshot cloning 2019-12-16 21:51:44 +00:00
watcher.go internal/lsp/cache: add finer-grained control of file changes 2019-11-14 16:11:15 +00:00