projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
81a0c1e
)
Fix treesit-query-validate for string input (bug#66400)
author
nverno
<noah.v.peart@gmail.com>
Sun, 8 Oct 2023 02:36:44 +0000
(19:36 -0700)
committer
Yuan Fu
<casouri@gmail.com>
Mon, 9 Oct 2023 05:00:32 +0000
(22:00 -0700)
* lisp/treesit.el (treesit-query-validate): Don't expand if QUERY is
string.
lisp/treesit.el
patch
|
blob
|
history
diff --git
a/lisp/treesit.el
b/lisp/treesit.el
index 98eac7f6d639caaa6be527b1f06d71420c5e65fa..e8d57dfcd060b2b361d2f63a7aedefadeb182d3b 100644
(file)
--- a/
lisp/treesit.el
+++ b/
lisp/treesit.el
@@
-2528,7
+2528,9
@@
to the offending pattern and highlight the pattern."
(start (nth 1 data))
(inhibit-read-only t))
(erase-buffer)
- (insert (treesit-query-expand query))
+ (insert (if (stringp query)
+ query
+ (treesit-query-expand query)))
(goto-char start)
(search-forward " " nil t)
(put-text-property start (point) 'face 'error)