1
0
mirror of https://github.com/golang/go synced 2024-11-18 22:04:43 -07:00
go/internal/lsp/cache
Muir Manders 1f0dd0289f internal/lsp: start handling watched file change events
Now we register for and handle didChangeWatchedFiles "change"
events. We don't handle "create" or "delete" yet.

When a file changes on disk, there are two basic cases. If the editor
has the file open, we want to ignore the change since we need to
respect the file contents in the editor. If the file isn't open in the
editor then we need to re-type check (and re-diagnose) any packages it
belongs to.

We will need special handling of go.mod changes, but start with
just *.go files for now.

I'm putting the new behavior behind an initialization flag while it is
under development.

Updates golang/go#31553

Change-Id: I81a767ebe12f5f82657752dcdfb069c5820cbaa0
Reviewed-on: https://go-review.googlesource.com/c/tools/+/190857
Reviewed-by: Ian Cottrell <iancottrell@google.com>
Run-TryBot: Ian Cottrell <iancottrell@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-08-26 19:00:32 +00:00
..
cache.go internal/lsp: remove the non context xlog path 2019-07-15 03:45:47 +00:00
check.go internal/lsp: unlabel context, log errors when canceled 2019-08-20 20:39:21 +00:00
external.go internal/lsp: split the telemetry library out 2019-08-15 21:28:02 +00:00
file.go internal/lsp: cache the *ast.File and *token.File on the package 2019-07-16 19:44:59 +00:00
gofile.go internal/lsp: split the telemetry library out 2019-08-15 21:28:02 +00:00
load.go internal/lsp: unlabel context, log errors when canceled 2019-08-20 20:39:21 +00:00
modfile.go internal/lsp: use x/xerrors to create new errors 2019-08-06 19:46:56 +00:00
parse.go internal/lsp: unlabel context, log errors when canceled 2019-08-20 20:39:21 +00:00
pkg.go go/analysis: handle common nil pointers 2019-08-24 21:01:00 +00:00
session.go internal/lsp: start handling watched file change events 2019-08-26 19:00:32 +00:00
sumfile.go internal/lsp: use x/xerrors to create new errors 2019-08-06 19:46:56 +00:00
token.go internal/lsp: unlabel context, log errors when canceled 2019-08-20 20:39:21 +00:00
view.go internal/lsp: split the telemetry library out 2019-08-15 21:28:02 +00:00
watcher.go internal/lsp: fix deadlocks loading lots of files at once 2019-07-03 17:22:52 +00:00