From: Yuan Fu Date: Wed, 6 Sep 2023 03:15:11 +0000 (-0700) Subject: ; Update Ftreesit_parser_list docstring. X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6b387d2edd1cdbc7d617cc6aad19914d9b1de661;p=emacs.git ; Update Ftreesit_parser_list docstring. * doc/lispref/parsing.texi (Using Parser): Update manual. * src/treesit.c (Ftreesit_parser_list): Update docstring. --- diff --git a/doc/lispref/parsing.texi b/doc/lispref/parsing.texi index 20d4b09ed4c..a0479050f27 100644 --- a/doc/lispref/parsing.texi +++ b/doc/lispref/parsing.texi @@ -462,7 +462,8 @@ buffers use their base buffer's parsers. If @var{language} is non-@var{nil}, only include parsers for that language. And only include parsers with @var{tag}. @var{tag} defaults -to @code{nil}. +to @code{nil}. If @var{tag} is @code{t}, include parsers in the +returned list regardless of their tag. @end defun @defun treesit-parser-delete parser diff --git a/src/treesit.c b/src/treesit.c index dfd098e3c85..f40bd32f156 100644 --- a/src/treesit.c +++ b/src/treesit.c @@ -1475,8 +1475,6 @@ See `treesit-parser-list' for the buffer's parser list. */) return Qnil; } -/* If TAG is t, include all parsers regardless of their tag. But - don't document this until there's some actual need for it. */ DEFUN ("treesit-parser-list", Ftreesit_parser_list, Streesit_parser_list, 0, 3, 0, @@ -1488,8 +1486,9 @@ use their base buffer's parsers. If LANGUAGE is non-nil, only return parsers for that language. -The returned list only contain parsers with TAG. TAG defaults to -nil. */) +The returned list only contain parsers with TAG. TAG defaults to nil. +If TAG is t, include parsers in the returned list regardless of their +tag. */) (Lisp_Object buffer, Lisp_Object language, Lisp_Object tag) { struct buffer *buf;