From dd7c7173f160f55e5c8583101f0e9ae2b7c4ce57 Mon Sep 17 00:00:00 2001 From: Henry Wong Date: Mon, 8 Jul 2019 09:55:40 +0000 Subject: [PATCH] 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 Run-TryBot: Rebecca Stambler --- internal/lsp/hover.go | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/internal/lsp/hover.go b/internal/lsp/hover.go index 05910ccf..5f0be117 100644 --- a/internal/lsp/hover.go +++ b/internal/lsp/hover.go @@ -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 -}