projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3bccef6
)
; * lisp/progmodes/c-ts-mode.el: Change rx to regexp-opt.
author
Yuan Fu
<casouri@gmail.com>
Fri, 2 Dec 2022 02:57:54 +0000
(18:57 -0800)
committer
Yuan Fu
<casouri@gmail.com>
Fri, 2 Dec 2022 03:59:51 +0000
(19:59 -0800)
lisp/progmodes/c-ts-mode.el
patch
|
blob
|
history
diff --git
a/lisp/progmodes/c-ts-mode.el
b/lisp/progmodes/c-ts-mode.el
index f802a6ddb2da12264b413484bafa1ccf06d73b7a..ad64df6143ca4c3786b0ab3c6ac931efb50fb7f0 100644
(file)
--- a/
lisp/progmodes/c-ts-mode.el
+++ b/
lisp/progmodes/c-ts-mode.el
@@
-525,11
+525,11
@@
the subtrees."
;; Navigation.
(setq-local treesit-defun-type-regexp
- (r
x (or
"function_definition"
- "type_definition"
- "struct_specifier"
- "enum_specifier"
- "union_specifier")))
+ (r
egexp-opt '(
"function_definition"
+
"type_definition"
+
"struct_specifier"
+
"enum_specifier"
+
"union_specifier")))
;; Nodes like struct/enum/union_specifier can appear in
;; function_definitions, so we need to find the top-level node.