Skip to content

Commit 73f2096

Browse files
feohsfrick
authored andcommitted
Merge pull request nvim-lua#467 from theopn/master
Use Telescope builtin functions for LSP definition and type definition
2 parents bb3ec24 + b1220a5 commit 73f2096

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

init.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -425,10 +425,10 @@ local on_attach = function(_, bufnr)
425425
nmap('<leader>L', vim.lsp.buf.format, '[F]ormat')
426426
nmap('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
427427

428-
nmap('gd', vim.lsp.buf.definition, '[G]oto [D]efinition')
428+
nmap('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
429429
nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
430430
nmap('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
431-
nmap('<leader>D', vim.lsp.buf.type_definition, 'Type [D]efinition')
431+
nmap('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
432432
nmap('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
433433
nmap('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
434434

0 commit comments

Comments
 (0)