mirror of
https://github.com/golang/go
synced 2024-11-18 15:04:44 -07:00
internal/lsp: remove the unused function 'markupContent'.
The last usage of 'markupContent' has been deleted in https://go-review.googlesource.com/c/tools/+/172958. Change-Id: I03296fa93069427339f17c7b2ad2267030a5b99b GitHub-Last-Rev: a85b88cdfd00c8d1edf4fdad6302486379beae9a GitHub-Pull-Request: golang/tools#132 Reviewed-on: https://go-review.googlesource.com/c/tools/+/185237 Reviewed-by: Rebecca Stambler <rstambler@golang.org> Run-TryBot: Rebecca Stambler <rstambler@golang.org>
This commit is contained in:
parent
60762fc531
commit
dd7c7173f1
@ -6,8 +6,6 @@ package lsp
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
"golang.org/x/tools/internal/lsp/protocol"
|
||||
"golang.org/x/tools/internal/lsp/source"
|
||||
"golang.org/x/tools/internal/span"
|
||||
@ -52,19 +50,3 @@ func (s *Server) hover(ctx context.Context, params *protocol.TextDocumentPositio
|
||||
Range: &rng,
|
||||
}, nil
|
||||
}
|
||||
|
||||
func markupContent(decl, doc string, kind protocol.MarkupKind) protocol.MarkupContent {
|
||||
result := protocol.MarkupContent{
|
||||
Kind: kind,
|
||||
}
|
||||
switch kind {
|
||||
case protocol.PlainText:
|
||||
result.Value = decl
|
||||
case protocol.Markdown:
|
||||
result.Value = "```go\n" + decl + "\n```"
|
||||
}
|
||||
if doc != "" {
|
||||
result.Value = fmt.Sprintf("%s\n%s", doc, result.Value)
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user