Revert "; * lisp/progmodes/c-ts-mode.el: allow loading file without treesit"

This reverts commit 7d246c359c.
The same problem was already fixed on the release branch,and this
change will just cause merge conflicts.
This commit is contained in:
Eli Zaretskii 2023-05-02 15:43:51 +03:00
parent 7d246c359c
commit 4f44c56c86

View file

@ -1001,14 +1001,13 @@ For BOL see `treesit-simple-indent-rules'."
(looking-at c-ts-mode--for-each-tail-regexp))))
(defvar c-ts-mode--emacs-c-range-query
(and (treesit-available-p)
(treesit-query-compile
'emacs-c `(((declaration
type: (macro_type_specifier
name: (identifier) @_name)
@for-each-tail)
(:match ,c-ts-mode--for-each-tail-regexp
@_name)))))
(treesit-query-compile
'emacs-c `(((declaration
type: (macro_type_specifier
name: (identifier) @_name)
@for-each-tail)
(:match ,c-ts-mode--for-each-tail-regexp
@_name))))
"Query that finds a FOR_EACH_* macro with an unbracketed body.")
(defvar-local c-ts-mode--for-each-tail-ranges nil