autoload/lsp/buffer.vim | 6 +++--- autoload/lsp/codeaction.vim | 2 +- autoload/lsp/completion.vim | 4 ++-- autoload/lsp/diag.vim | 4 ++-- autoload/lsp/handlers.vim | 14 +++++++------- autoload/lsp/lsp.vim | 26 +++++++++++++------------- autoload/lsp/lspserver.vim | 80 +++++++++++++++++++++++++++--------------------------- autoload/lsp/textedit.vim | 4 ++-- autoload/lsp/util.vim | 4 ++-- diff --git a/autoload/lsp/buffer.vim b/autoload/lsp/buffer.vim index c34f9a929d99c6b097e26032defc2b914d2fe5c9..455e6920f9ea03f3415e1c9f0f54b66b26b64aea 100644 --- a/autoload/lsp/buffer.vim +++ b/autoload/lsp/buffer.vim @@ -157,15 +157,15 @@ endif var lspserver: dict = CurbufGetServer(domain) if lspserver->empty() - util.ErrMsg($'Error: Language server for "{&filetype}" file type is not found') + util.ErrMsg($'Language server for "{&filetype}" file type is not found') return {} endif if !lspserver.running - util.ErrMsg($'Error: Language server for "{&filetype}" file type is not running') + util.ErrMsg($'Language server for "{&filetype}" file type is not running') return {} endif if !lspserver.ready - util.ErrMsg($'Error: Language server for "{&filetype}" file type is not ready') + util.ErrMsg($'Language server for "{&filetype}" file type is not ready') return {} endif diff --git a/autoload/lsp/codeaction.vim b/autoload/lsp/codeaction.vim index faa11bd3e8f793f7d24f3cb9468ab46ce27e9441..2c1680e0cd84fff79b3f298e8b7c2aa2abd4d80b 100644 --- a/autoload/lsp/codeaction.vim +++ b/autoload/lsp/codeaction.vim @@ -18,7 +18,7 @@ var CmdHandler: func = CommandHandlers[cmd.command] try call CmdHandler(cmd) catch - util.ErrMsg($'Error: "{cmd.command}" handler raised exception {v:exception}') + util.ErrMsg($'"{cmd.command}" handler raised exception {v:exception}') endtry else lspserver.executeCommand(cmd) diff --git a/autoload/lsp/completion.vim b/autoload/lsp/completion.vim index 9159e10dc4e10849fb49b7be08bb9619c34de07d..75e0a7836570fab00fe0318d32cc9ed63ff253eb 100644 --- a/autoload/lsp/completion.vim +++ b/autoload/lsp/completion.vim @@ -324,13 +324,13 @@ elseif cItem.documentation.kind == 'markdown' infoText->extend(cItem.documentation.value->split("\n")) infoKind = 'lspgfm' else - util.ErrMsg($'Error: Unsupported documentation type ({cItem.documentation.kind})') + util.ErrMsg($'Unsupported documentation type ({cItem.documentation.kind})') return endif elseif cItem.documentation->type() == v:t_string infoText->extend(cItem.documentation->split("\n")) else - util.ErrMsg($'Error: Unsupported documentation ({cItem.documentation->string()})') + util.ErrMsg($'Unsupported documentation ({cItem.documentation->string()})') return endif endif diff --git a/autoload/lsp/diag.vim b/autoload/lsp/diag.vim index 1d28a40e0d00200cf94cd4adb89663a855fdbbc2..8dec2dc4938453db61847792db7f77348c6c2fbb 100644 --- a/autoload/lsp/diag.vim +++ b/autoload/lsp/diag.vim @@ -590,9 +590,9 @@ return endif if which == 'here' - util.WarnMsg('Error: No more diagnostics found on this line') + util.WarnMsg('No more diagnostics found on this line') else - util.WarnMsg('Error: No more diagnostics found') + util.WarnMsg('No more diagnostics found') endif enddef diff --git a/autoload/lsp/handlers.vim b/autoload/lsp/handlers.vim index b4219f51c5e6df156d58c11c747d6681afb8ff19..2c840482f7023a7621472b2250aa1c759386dc9e 100644 --- a/autoload/lsp/handlers.vim +++ b/autoload/lsp/handlers.vim @@ -10,7 +10,7 @@ import './textedit.vim' # Process various reply messages from the LSP server export def ProcessReply(lspserver: dict, req: dict, reply: dict): void - util.ErrMsg($'Error: Unsupported reply received from LSP server: {reply->string()} for request: {req->string()}') + util.ErrMsg($'Unsupported reply received from LSP server: {reply->string()} for request: {req->string()}') enddef # process a diagnostic notification message from the LSP server @@ -62,7 +62,7 @@ enddef # process unsupported notification messages def ProcessUnsupportedNotif(lspserver: dict, reply: dict) - util.ErrMsg($'Error: Unsupported notification message received from the LSP server ({lspserver.path}), message = {reply->string()}') + util.ErrMsg($'Unsupported notification message received from the LSP server ({lspserver.path}), message = {reply->string()}') enddef # per-filetype private map inside to record if ntf once or not @@ -109,7 +109,7 @@ lsp_notif_handlers[reply.method](lspserver, reply) elseif lspserver.customNotificationHandlers->has_key(reply.method) lspserver.customNotificationHandlers[reply.method](lspserver, reply) elseif lsp_ignored_notif_handlers->index(reply.method) == -1 - util.ErrMsg($'Error: Unsupported notification received from LSP server {reply->string()}') + util.ErrMsg($'Unsupported notification received from LSP server {reply->string()}') endif enddef @@ -178,7 +178,7 @@ lspserver.sendResponse(request, {}, {}) enddef def ProcessUnsupportedReq(lspserver: dict, request: dict) - util.ErrMsg($'Error: Unsupported request message received from the LSP server ({lspserver.path}), message = {request->string()}') + util.ErrMsg($'Unsupported request message received from the LSP server ({lspserver.path}), message = {request->string()}') enddef # process a request message from the server @@ -198,7 +198,7 @@ if lspRequestHandlers->has_key(request.method) lspRequestHandlers[request.method](lspserver, request) else - util.ErrMsg($'Error: Unsupported request message received from the LSP server ({lspserver.path}), message = {request->string()}') + util.ErrMsg($'Unsupported request message received from the LSP server ({lspserver.path}), message = {request->string()}') endif enddef @@ -227,7 +227,7 @@ emsg ..= $', code = {msg.error.code}' if msg.error->has_key('data') emsg ..= $', data = {msg.error.data->string()}' endif - util.ErrMsg($'Error(LSP): request {req.method} failed ({emsg})') + util.ErrMsg($'request {req.method} failed ({emsg})') endif endif elseif msg->has_key('id') && msg->has_key('method') @@ -237,7 +237,7 @@ elseif msg->has_key('method') # notification message from the server lspserver.processNotif(msg) else - util.ErrMsg($'Error(LSP): Unsupported message ({msg->string()})') + util.ErrMsg($'Unsupported message ({msg->string()})') endif enddef diff --git a/autoload/lsp/lsp.vim b/autoload/lsp/lsp.vim index 945ea47851322022af7a2aa77a6ab34b5c6ab398..b2db8b2f2f9cd727e56e4a9475e93d788390d585 100644 --- a/autoload/lsp/lsp.vim +++ b/autoload/lsp/lsp.vim @@ -87,7 +87,7 @@ # Enable/disable the logging of the language server protocol messages def ServerDebug(arg: string) if ['errors', 'messages', 'off', 'on']->index(arg) == -1 - util.ErrMsg($'Error: Unsupported argument "{arg}" for LspServer debug') + util.ErrMsg($'Unsupported argument "{arg}" for LspServer debug') return endif @@ -223,7 +223,7 @@ endif lines->extend(lspserver.getMessages()) endfor else - util.ErrMsg($'Error: Unsupported argument "{arg}"') + util.ErrMsg($'Unsupported argument "{arg}"') return endif @@ -566,7 +566,7 @@ # Register a LSP server for one or more file types export def AddServer(serverList: list>) for server in serverList if !server->has_key('filetype') || !server->has_key('path') - util.ErrMsg('Error: LSP server information is missing filetype or path') + util.ErrMsg('LSP server information is missing filetype or path') continue endif # Enable omni-completion by default @@ -574,14 +574,14 @@ server.omnicompl = get(server, 'omnicompl', v:true) if !server.path->executable() if !opt.lspOptions.ignoreMissingServer - util.ErrMsg($'Error: LSP server {server.path} is not found') + util.ErrMsg($'LSP server {server.path} is not found') endif return endif var args: list = [] if server->has_key('args') if server.args->type() != v:t_list - util.ErrMsg($'Error: Arguments for LSP server {server.args} is not a List') + util.ErrMsg($'Arguments for LSP server {server.args} is not a List') return endif args = server.args @@ -603,7 +603,7 @@ features = server.features endif if server.omnicompl->type() != v:t_bool - util.ErrMsg($'Error: Setting of omnicompl {server.omnicompl} is not a Boolean') + util.ErrMsg($'Setting of omnicompl {server.omnicompl} is not a Boolean') return endif @@ -656,7 +656,7 @@ for ftype in ftypes AddServerForFiltype(lspserver, ftype, server.omnicompl) endfor else - util.ErrMsg($'Error: Unsupported file type information "{ftypes->string()}" in LSP server registration') + util.ErrMsg($'Unsupported file type information "{ftypes->string()}" in LSP server registration') continue endif endfor @@ -688,7 +688,7 @@ # set the LSP server trace level for the current buffer # Params: SetTraceParams def ServerTraceSet(traceVal: string) if ['off', 'messages', 'verbose']->index(traceVal) == -1 - util.ErrMsg($'Error: Unsupported LSP server trace value {traceVal}') + util.ErrMsg($'Unsupported LSP server trace value {traceVal}') return endif @@ -809,7 +809,7 @@ # Format the entire file export def TextDocFormat(range_args: number, line1: number, line2: number) if !&modifiable - util.ErrMsg('Error: Current file is not a modifiable file') + util.ErrMsg('Current file is not a modifiable file') return endif @@ -947,7 +947,7 @@ endif endif :redraw! if !dirName->isdirectory() - util.ErrMsg($'Error: {dirName} is not a directory') + util.ErrMsg($'{dirName} is not a directory') return endif @@ -969,7 +969,7 @@ endif endif :redraw! if !dirName->isdirectory() - util.ErrMsg($'Error: {dirName} is not a directory') + util.ErrMsg($'{dirName} is not a directory') return endif @@ -1007,7 +1007,7 @@ return endif if &foldmethod != 'manual' - util.ErrMsg("Error: Only works when 'foldmethod' is 'manual'") + util.ErrMsg("Only works when 'foldmethod' is 'manual'") return endif @@ -1130,7 +1130,7 @@ elseif args->stridx('trace ') == 0 var subcmd = args[6 : ]->trim() ServerTraceSet(subcmd) else - util.ErrMsg($'Error: LspServer - Unsupported argument "{args}"') + util.ErrMsg($'LspServer - Unsupported argument "{args}"') endif enddef diff --git a/autoload/lsp/lspserver.vim b/autoload/lsp/lspserver.vim index 6f4f559fba5268d6bb409d170c4497669a90e157..aa192ed729fe4b5e4eb40edac1858b1fe01f1261 100644 --- a/autoload/lsp/lspserver.vim +++ b/autoload/lsp/lspserver.vim @@ -75,7 +75,7 @@ lspserver.signaturePopup = -1 var job = cmd->job_start(opts) if job->job_status() == 'fail' - util.ErrMsg($'Error: Failed to start LSP server {lspserver.path}') + util.ErrMsg($'Failed to start LSP server {lspserver.path}') return 1 endif @@ -317,7 +317,7 @@ if (request.id->type() == v:t_string && (request.id->trim() =~ '[^[:digit:]]\+' || request.id->trim() == '')) || (request.id->type() != v:t_string && request.id->type() != v:t_number) - util.ErrMsg('Error: request.id of response to LSP server is not a correct number') + util.ErrMsg('request.id of response to LSP server is not a correct number') return endif var resp: dict = lspserver.createResponse( @@ -383,7 +383,7 @@ emsg ..= $', code = {reply.error.code}' if reply.error->has_key('data') emsg ..= $', data = {reply.error.data->string()}' endif - util.ErrMsg($'Error(LSP): request {method} failed ({emsg})') + util.ErrMsg($'request {method} failed ({emsg})') endif return {} @@ -404,12 +404,12 @@ emsg = $'{reply.error.message}, code = {reply.error.code}' if reply.error->has_key('data') emsg ..= $', data = {reply.error.data->string()}' endif - util.ErrMsg($'Error(LSP): request {method} failed ({emsg})') + util.ErrMsg($'request {method} failed ({emsg})') return endif if !reply->has_key('result') - util.ErrMsg($'Error(LSP): request {method} failed (no result)') + util.ErrMsg($'request {method} failed (no result)') return endif @@ -611,7 +611,7 @@ # Param: CompletionParams def GetCompletion(lspserver: dict, triggerKind_arg: number, triggerChar: string): void # Check whether LSP server supports completion if !lspserver.isCompletionProvider - util.ErrMsg('Error: LSP server does not support completion') + util.ErrMsg('LSP server does not support completion') return endif @@ -636,7 +636,7 @@ # Param: CompletionItem def ResolveCompletion(lspserver: dict, item: dict): void # Check whether LSP server supports completion item resolve if !lspserver.isCompletionResolveProvider - util.ErrMsg('Error: LSP server does not support completion item resolve') + util.ErrMsg('LSP server does not support completion item resolve') return endif @@ -668,13 +668,13 @@ var reply = lspserver.rpc(msg, GetLspTextDocPosition(true), false) if reply->empty() || reply.result->empty() var emsg: string if msg ==# 'textDocument/declaration' - emsg = 'Error: symbol declaration is not found' + emsg = 'symbol declaration is not found' elseif msg ==# 'textDocument/typeDefinition' - emsg = 'Error: symbol type definition is not found' + emsg = 'symbol type definition is not found' elseif msg ==# 'textDocument/implementation' - emsg = 'Error: symbol implementation is not found' + emsg = 'symbol implementation is not found' else - emsg = 'Error: symbol definition is not found' + emsg = 'symbol definition is not found' endif util.WarnMsg(emsg) @@ -715,7 +715,7 @@ # Param: DefinitionParams def GotoDefinition(lspserver: dict, peek: bool, cmdmods: string) # Check whether LSP server supports jumping to a definition if !lspserver.isDefinitionProvider - util.ErrMsg('Error: Jumping to a symbol definition is not supported') + util.ErrMsg('Jumping to a symbol definition is not supported') return endif @@ -729,7 +729,7 @@ # Param: DeclarationParams def GotoDeclaration(lspserver: dict, peek: bool, cmdmods: string) # Check whether LSP server supports jumping to a declaration if !lspserver.isDeclarationProvider - util.ErrMsg('Error: Jumping to a symbol declaration is not supported') + util.ErrMsg('Jumping to a symbol declaration is not supported') return endif @@ -743,7 +743,7 @@ # Param: TypeDefinitionParams def GotoTypeDef(lspserver: dict, peek: bool, cmdmods: string) # Check whether LSP server supports jumping to a type definition if !lspserver.isTypeDefinitionProvider - util.ErrMsg('Error: Jumping to a symbol type definition is not supported') + util.ErrMsg('Jumping to a symbol type definition is not supported') return endif @@ -757,7 +757,7 @@ # Param: ImplementationParams def GotoImplementation(lspserver: dict, peek: bool, cmdmods: string) # Check whether LSP server supports jumping to a implementation if !lspserver.isImplementationProvider - util.ErrMsg('Error: Jumping to a symbol implementation is not supported') + util.ErrMsg('Jumping to a symbol implementation is not supported') return endif @@ -774,7 +774,7 @@ var param = {} param.uri = util.LspFileToUri(@%) var reply = lspserver.rpc('textDocument/switchSourceHeader', param) if reply->empty() || reply.result->empty() - util.WarnMsg('Error: No alternate file found') + util.WarnMsg('No alternate file found') return endif @@ -796,7 +796,7 @@ # Param: SignatureHelpParams def ShowSignature(lspserver: dict): void # Check whether LSP server supports signature help if !lspserver.isSignatureHelpProvider - util.ErrMsg('Error: LSP server does not support signature help') + util.ErrMsg('LSP server does not support signature help') return endif @@ -846,7 +846,7 @@ # Param: ReferenceParams def ShowReferences(lspserver: dict, peek: bool): void # Check whether LSP server supports getting reference information if !lspserver.isReferencesProvider - util.ErrMsg('Error: LSP server does not support showing references') + util.ErrMsg('LSP server does not support showing references') return endif @@ -859,7 +859,7 @@ var reply = lspserver.rpc('textDocument/references', param) # Result: Location[] | null if reply->empty() || reply.result->empty() - util.WarnMsg('Error: No references found') + util.WarnMsg('No references found') return endif @@ -904,7 +904,7 @@ # Param: DocumentHighlightParams def DocHighlight(lspserver: dict, cmdmods: string): void # Check whether LSP server supports getting highlight information if !lspserver.isDocumentHighlightProvider - util.ErrMsg('Error: LSP server does not support document highlight') + util.ErrMsg('LSP server does not support document highlight') return endif @@ -921,7 +921,7 @@ # Param: DocumentSymbolParams def GetDocSymbols(lspserver: dict, fname: string): void # Check whether LSP server supports getting document symbol information if !lspserver.isDocumentSymbolProvider - util.ErrMsg('Error: LSP server does not support getting list of symbols') + util.ErrMsg('LSP server does not support getting list of symbols') return endif @@ -941,7 +941,7 @@ def TextDocFormat(lspserver: dict, fname: string, rangeFormat: bool, start_lnum: number, end_lnum: number) # Check whether LSP server supports formatting documents if !lspserver.isDocumentFormattingProvider - util.ErrMsg('Error: LSP server does not support formatting documents') + util.ErrMsg('LSP server does not support formatting documents') return endif @@ -1023,7 +1023,7 @@ # Request: "callHierarchy/incomingCalls" def IncomingCalls(lspserver: dict, fname: string) # Check whether LSP server supports call hierarchy if !lspserver.isCallHierarchyProvider - util.ErrMsg('Error: LSP server does not support call hierarchy') + util.ErrMsg('LSP server does not support call hierarchy') return endif @@ -1046,7 +1046,7 @@ # Request: "callHierarchy/outgoingCalls" def OutgoingCalls(lspserver: dict, fname: string) # Check whether LSP server supports call hierarchy if !lspserver.isCallHierarchyProvider - util.ErrMsg('Error: LSP server does not support call hierarchy') + util.ErrMsg('LSP server does not support call hierarchy') return endif @@ -1070,7 +1070,7 @@ # Inlay hints. def InlayHintsShow(lspserver: dict) # Check whether LSP server supports type hierarchy if !lspserver.isInlayHintProvider && !lspserver.isClangdInlayHintsProvider - util.ErrMsg('Error: LSP server does not support inlay hint') + util.ErrMsg('LSP server does not support inlay hint') return endif @@ -1101,7 +1101,7 @@ # doesn't support that method. def TypeHiearchy(lspserver: dict, direction: number) # Check whether LSP server supports type hierarchy if !lspserver.isTypeHierarchyProvider - util.ErrMsg('Error: LSP server does not support type hierarchy') + util.ErrMsg('LSP server does not support type hierarchy') return endif @@ -1126,7 +1126,7 @@ # Param: RenameParams def RenameSymbol(lspserver: dict, newName: string) # Check whether LSP server supports rename operation if !lspserver.isRenameProvider - util.ErrMsg('Error: LSP server does not support rename operation') + util.ErrMsg('LSP server does not support rename operation') return endif @@ -1154,7 +1154,7 @@ def CodeAction(lspserver: dict, fname_arg: string, line1: number, line2: number, query: string) # Check whether LSP server supports code action operation if !lspserver.isCodeActionProvider - util.ErrMsg('Error: LSP server does not support code action operation') + util.ErrMsg('LSP server does not support code action operation') return endif @@ -1197,14 +1197,14 @@ # Param: CodeLensParams def CodeLens(lspserver: dict, fname: string) # Check whether LSP server supports code lens operation if !lspserver.isCodeLensProvider - util.ErrMsg('Error: LSP server does not support code lens operation') + util.ErrMsg('LSP server does not support code lens operation') return endif var params = {textDocument: {uri: util.LspFileToUri(fname)}} var reply = lspserver.rpc('textDocument/codeLens', params) if reply->empty() || reply.result->empty() - util.WarnMsg($'Error: No code lens actions found for the current file') + util.WarnMsg($'No code lens actions found for the current file') return endif @@ -1230,7 +1230,7 @@ # Param: WorkspaceSymbolParams def WorkspaceQuerySymbols(lspserver: dict, query: string) # Check whether the LSP server supports listing workspace symbols if !lspserver.isWorkspaceSymbolProvider - util.ErrMsg('Error: LSP server does not support listing workspace symbols') + util.ErrMsg('LSP server does not support listing workspace symbols') return endif @@ -1239,7 +1239,7 @@ var param = {} param.query = query var reply = lspserver.rpc('workspace/symbol', param) if reply->empty() || reply.result->empty() - util.WarnMsg($'Error: Symbol "{query}" is not found') + util.WarnMsg($'Symbol "{query}" is not found') return endif @@ -1252,12 +1252,12 @@ if !lspserver.caps->has_key('workspace') || !lspserver.caps.workspace->has_key('workspaceFolders') || !lspserver.caps.workspace.workspaceFolders->has_key('supported') || !lspserver.caps.workspace.workspaceFolders.supported - util.ErrMsg('Error: LSP server does not support workspace folders') + util.ErrMsg('LSP server does not support workspace folders') return endif if lspserver.workspaceFolders->index(dirName) != -1 - util.ErrMsg($'Error: {dirName} is already part of this workspace') + util.ErrMsg($'{dirName} is already part of this workspace') return endif @@ -1275,13 +1275,13 @@ if !lspserver.caps->has_key('workspace') || !lspserver.caps.workspace->has_key('workspaceFolders') || !lspserver.caps.workspace.workspaceFolders->has_key('supported') || !lspserver.caps.workspace.workspaceFolders.supported - util.ErrMsg('Error: LSP server does not support workspace folders') + util.ErrMsg('LSP server does not support workspace folders') return endif var idx: number = lspserver.workspaceFolders->index(dirName) if idx == -1 - util.ErrMsg($'Error: {dirName} is not currently part of this workspace') + util.ErrMsg($'{dirName} is not currently part of this workspace') return endif @@ -1299,7 +1299,7 @@ # Param: SelectionRangeParams def SelectionRange(lspserver: dict, fname: string) # Check whether LSP server supports selection ranges if !lspserver.isSelectionRangeProvider - util.ErrMsg('Error: LSP server does not support selection ranges') + util.ErrMsg('LSP server does not support selection ranges') return endif @@ -1325,7 +1325,7 @@ # Expand the previous selection or start a new one def SelectionExpand(lspserver: dict) # Check whether LSP server supports selection ranges if !lspserver.isSelectionRangeProvider - util.ErrMsg('Error: LSP server does not support selection ranges') + util.ErrMsg('LSP server does not support selection ranges') return endif @@ -1336,7 +1336,7 @@ # Shrink the previous selection or start a new one def SelectionShrink(lspserver: dict) # Check whether LSP server supports selection ranges if !lspserver.isSelectionRangeProvider - util.ErrMsg('Error: LSP server does not support selection ranges') + util.ErrMsg('LSP server does not support selection ranges') return endif @@ -1349,7 +1349,7 @@ # Param: FoldingRangeParams def FoldRange(lspserver: dict, fname: string) # Check whether LSP server supports fold ranges if !lspserver.isFoldingRangeProvider - util.ErrMsg('Error: LSP server does not support folding') + util.ErrMsg('LSP server does not support folding') return endif diff --git a/autoload/lsp/textedit.vim b/autoload/lsp/textedit.vim index 4fdc615824a8a0efbd4e0be1d592145b315246d8..7a30137ae398c9f279fe82499bd3d4123d545c83 100644 --- a/autoload/lsp/textedit.vim +++ b/autoload/lsp/textedit.vim @@ -189,7 +189,7 @@ # interface TextDocumentEdit def ApplyTextDocumentEdit(textDocEdit: dict) var bnr: number = bufnr(util.LspUriToFile(textDocEdit.textDocument.uri)) if bnr == -1 - util.ErrMsg($'Error: Text Document edit, buffer {textDocEdit.textDocument.uri} is not found') + util.ErrMsg($'Text Document edit, buffer {textDocEdit.textDocument.uri} is not found') return endif ApplyTextEdits(bnr, textDocEdit.edits) @@ -200,7 +200,7 @@ export def ApplyWorkspaceEdit(workspaceEdit: dict) if workspaceEdit->has_key('documentChanges') for change in workspaceEdit.documentChanges if change->has_key('kind') - util.ErrMsg($'Error: Unsupported change in workspace edit [{change.kind}]') + util.ErrMsg($'Unsupported change in workspace edit [{change.kind}]') else ApplyTextDocumentEdit(change) endif diff --git a/autoload/lsp/util.vim b/autoload/lsp/util.vim index 39a3a478d4d9529872efc81306bd0392302aa423..dd02a1ebbb60bfb34fe39ba09cb3a613b9e11b1f 100644 --- a/autoload/lsp/util.vim +++ b/autoload/lsp/util.vim @@ -3,14 +3,14 @@ # Display a warning message export def WarnMsg(msg: string) :echohl WarningMsg - :echomsg msg + :echomsg $'Warn: [Lsp] {msg}' :echohl None enddef # Display an error message export def ErrMsg(msg: string) :echohl Error - :echomsg msg + :echomsg $'Error: [Lsp] {msg}' :echohl None enddef