From 189fb6203262340e7a59e782be970bcd8ae28e61 Mon Sep 17 00:00:00 2001 From: Lewis Russell Date: Wed, 17 May 2023 11:42:18 +0100 Subject: feat(treesitter): improved logging (#23638) - Add bindings to Treesitter ts_parser_set_logger and ts_parser_logger - Add logfile with path STDPATH('log')/treesitter.c - Rework existing LanguageTree loggin to use logfile - Begin implementing log levels for vim.g.__ts_debug --- runtime/lua/vim/fs.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'runtime/lua/vim/fs.lua') diff --git a/runtime/lua/vim/fs.lua b/runtime/lua/vim/fs.lua index 2a51bde263..7f9f3a2bce 100644 --- a/runtime/lua/vim/fs.lua +++ b/runtime/lua/vim/fs.lua @@ -73,10 +73,14 @@ function M.basename(file) end ---@private -local function join_paths(...) +---@param ... string +---@return string +function M._join_paths(...) return (table.concat({ ... }, '/'):gsub('//+', '/')) end +local join_paths = M._join_paths + ---@alias Iterator fun(): string?, string? --- Return an iterator over the files and directories located in {path} -- cgit