refacto: deprecate used_by in parsers.lua

- remove print_warning function from utils.lua (unused)
- cleanup some functions in parsers.lua (parameters overloading
  and wrong bufnr used).
- log a deprecation notice when using used_by in a parser definition
- default the filetype_to_parsername table to the list of filetypes
  previously in the used_by keys
- update the README to indicate that change
This commit is contained in:
kiyan 2022-02-06 13:34:08 +01:00 committed by Kiyan
parent d7eab3a5a9
commit 58a4897e6d
3 changed files with 37 additions and 37 deletions

View file

@ -136,12 +136,6 @@ function M.get_at_path(tbl, path)
return result
end
-- Prints a warning message
-- @param text the text message
function M.print_warning(text)
api.nvim_command(string.format([[echohl WarningMsg | echo "%s" | echohl None]], text))
end
function M.set_jump()
vim.cmd "normal! m'"
end