]> git.eshelyaron.com Git - emacs.git/commit
Add handling of contextual entities in tree-sitter font-lock
authorYuan Fu <casouri@gmail.com>
Wed, 2 Nov 2022 23:31:25 +0000 (16:31 -0700)
committerYuan Fu <casouri@gmail.com>
Wed, 2 Nov 2022 23:47:53 +0000 (16:47 -0700)
commitf331be1f074d68e7e5cdbac324419e07c186492a
treeeb2d16d70a9aa23ab3e5b2a083db4b59fefa780e
parent040991a4697b50ebcb54e498e7de54b8d0885101
Add handling of contextual entities in tree-sitter font-lock

* lisp/progmodes/python.el: Remove function.
(python--treesit-settings): Capture contextual node.
* lisp/treesit.el (treesit--set-nonsticky):
(treesit-font-lock-contextual-post-process): New functions.
(treesit-font-lock-fontify-region): Change local variable START and
END to NODE-START and NODE-END, handle special capture name
"contextual".
* doc/lispref/modes.texi (Parser-based Font Lock): Update manual.
doc/lispref/modes.texi
lisp/progmodes/python.el
lisp/treesit.el