mirror of
https://github.com/golang/go
synced 2024-11-18 22:55:23 -07:00
3d17549cdc
This change adds a stub modFile struct for use in the future. It also moves the singleDiagnostic function out into the lsp package, so that the source package does not make decisions about what to show to the user as a diagnostic. Fixes golang/go#32221 Change-Id: I577c66fcd3c1daadaa221b52ff36bfa0fe07fb53 Reviewed-on: https://go-review.googlesource.com/c/tools/+/178681 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Cottrell <iancottrell@google.com>
17 lines
416 B
Go
17 lines
416 B
Go
package cache
|
|
|
|
import (
|
|
"context"
|
|
"go/token"
|
|
)
|
|
|
|
// modFile holds all of the information we know about a mod file.
|
|
type modFile struct {
|
|
fileBase
|
|
}
|
|
|
|
func (*modFile) GetToken(context.Context) *token.File { return nil }
|
|
func (*modFile) setContent(content []byte) {}
|
|
func (*modFile) filename() string { return "" }
|
|
func (*modFile) isActive() bool { return false }
|