aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/progmodes/python.el
diff options
context:
space:
mode:
authorYuan Fu2022-11-15 02:22:41 -0800
committerYuan Fu2022-11-15 02:22:41 -0800
commite0760599b045a7ef3828ae4b624246b6beec2e75 (patch)
treec9b144b2fd9418f350ba5590a96a49e2a76f7f20 /lisp/progmodes/python.el
parent34e50dc4a23505dce0499f120477e2e1a1327432 (diff)
downloademacs-e0760599b045a7ef3828ae4b624246b6beec2e75.tar.gz
emacs-e0760599b045a7ef3828ae4b624246b6beec2e75.zip
Remove the contextual hack in tree-sitter fontification
We now have a better facility that can replace the contextual hack. The C part is in the previous commit, and the Lisp part work will be in the next commit. * doc/lispref/modes.texi (Parser-based Font Lock): Update manual. * lisp/progmodes/js.el (js--treesit-font-lock-settings) * lisp/progmodes/python.el (python--treesit-settings) * lisp/progmodes/ts-mode.el (ts-mode--font-lock-settings): Stop marking contextual nodes. * lisp/treesit.el (treesit-font-lock-contextual-post-process): Remove function. (treesit-font-lock-fontify-region): Remove code processing contextual nodes.
Diffstat (limited to 'lisp/progmodes/python.el')
-rw-r--r--lisp/progmodes/python.el3
1 files changed, 1 insertions, 2 deletions
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index a5d02d0fcba..7919484e096 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -1047,8 +1047,7 @@ be fontified."
1047 :language 'python 1047 :language 'python
1048 :override t 1048 :override t
1049 ;; TODO Document on why we do this. 1049 ;; TODO Document on why we do this.
1050 '((string :anchor "\"" @python--treesit-fontify-string) 1050 '((string :anchor "\"" @python--treesit-fontify-string))
1051 (string) @contextual)
1052 1051
1053 :feature 'string-interpolation 1052 :feature 'string-interpolation
1054 :language 'python 1053 :language 'python