From 3c1d70f20b5d5bad3bec121e589187d15f325a9b Mon Sep 17 00:00:00 2001 From: Thomas Vigouroux Date: Mon, 25 Jul 2022 12:23:04 +0200 Subject: feat(treesitter): allow customizing language symbol name --- runtime/doc/treesitter.txt | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/treesitter.txt b/runtime/doc/treesitter.txt index 52531a1525..06409f9980 100644 --- a/runtime/doc/treesitter.txt +++ b/runtime/doc/treesitter.txt @@ -387,16 +387,20 @@ inspect_language({lang}) *inspect_language()* Parameters: ~ {lang} The language. -require_language({lang}, {path}, {silent}) *require_language()* + *require_language()* +require_language({lang}, {path}, {silent}, {symbol_name}) Asserts that the provided language is installed, and optionally provide a path for the parser Parsers are searched in the `parser` runtime directory. Parameters: ~ - {lang} The language the parser should parse - {path} Optional path the parser is located at - {silent} Don't throw an error if language not found + {lang} (string) The language the parser should parse + {path} (string|nil) Optional path the parser is located at + {silent} (boolean|nil) Don't throw an error if language not + found + {symbol_name} (string|nil) Internal symbol name for the language to + load ============================================================================== -- cgit From 48a4657aee76e41d097b0730c91bcca78b5bc9c7 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Tue, 23 Aug 2022 08:36:22 +0800 Subject: vim-patch:8.1.{1915,1921,1953} (#19900) vim-patch:8.1.1915: more functions can be used as methods Problem: More functions can be used as methods. Solution: Make various functions usable as a method. https://github.com/vim/vim/commit/1a3a89168d61c2fed91cbca812cf1c6983901b79 Move debugbreak() to the right place. vim-patch:8.1.1921: more functions can be used as methods Problem: More functions can be used as methods. Solution: Make various functions usable as a method. https://github.com/vim/vim/commit/a4208966fb289a505ebdef62bbc37c214069bab4 vim-patch:8.1.1953: more functions can be used as a method Problem: More functions can be used as a method. Solution: Allow more functions to be used as a method. https://github.com/vim/vim/commit/f9f24ce7a0e5988fedf2e2ff751818f9b07510a6 Omit test_termcodes.vim: cannot be used and superseded by later patches. Cherry-pick test_bufline.vim change from patch 8.1.1993. --- runtime/doc/builtin.txt | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) (limited to 'runtime/doc') diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt index 0be9e9b9d1..a47eae8274 100644 --- a/runtime/doc/builtin.txt +++ b/runtime/doc/builtin.txt @@ -1136,6 +1136,9 @@ chdir({dir}) *chdir()* " ... do some work call chdir(save_dir) endif + +< Can also be used as a |method|: > + GetDir()->chdir() < cindent({lnum}) *cindent()* Get the amount of indent for line {lnum} according the C @@ -1526,6 +1529,18 @@ cursor({list}) Can also be used as a |method|: > GetCursorPos()->cursor() +debugbreak({pid}) *debugbreak()* + Specifically used to interrupt a program being debugged. It + will cause process {pid} to get a SIGTRAP. Behavior for other + processes is undefined. See |terminal-debugger|. + {Sends a SIGINT to a process {pid} other than MS-Windows} + + Returns |TRUE| if successfully interrupted the program. + Otherwise returns |FALSE|. + + Can also be used as a |method|: > + GetPid()->debugbreak() + deepcopy({expr} [, {noref}]) *deepcopy()* *E698* Make a copy of {expr}. For Numbers and Strings this isn't different from using {expr} directly. @@ -1967,18 +1982,6 @@ exp({expr}) *exp()* Can also be used as a |method|: > Compute()->exp() -debugbreak({pid}) *debugbreak()* - Specifically used to interrupt a program being debugged. It - will cause process {pid} to get a SIGTRAP. Behavior for other - processes is undefined. See |terminal-debugger|. - {Sends a SIGINT to a process {pid} other than MS-Windows} - - Returns |TRUE| if successfully interrupted the program. - Otherwise returns |FALSE|. - - Can also be used as a |method|: > - GetPid()->debugbreak() - expand({string} [, {nosuf} [, {list}]]) *expand()* Expand wildcards and the following special keywords in {string}. 'wildignorecase' applies. -- cgit From ffa1335047047ac00280ac742bcc6dfcc7fa3589 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sat, 20 Aug 2022 07:54:14 +0800 Subject: vim-patch:8.2.4726: cannot use expand() to get the script name Problem: Cannot use expand() to get the script name. Solution: Support expand('