]> git.eshelyaron.com Git - emacs.git/commitdiff
Rename variables from last change
authorTheodor Thornhill <theo@thornhill.no>
Mon, 16 Jan 2023 07:36:49 +0000 (08:36 +0100)
committerTheodor Thornhill <theo@thornhill.no>
Mon, 16 Jan 2023 07:36:49 +0000 (08:36 +0100)
* lisp/progmodes/js.el (js--treesit-sentence-nodes): Rename variable
from 'js--treesit-sentence-type-regexp'.
(js-ts-mode): Refer to it.
* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--sentence-nodes): Rename variable from
'typescript-ts-mode--sentence-type-regexp'.
(typescript-ts-base-mode, tsx-ts-mode): Refer to it.

lisp/progmodes/js.el
lisp/progmodes/typescript-ts-mode.el

index f6103d43eea41c3ba2bda206a156d65745877b2b..fa3b4687ef2a385fab00c72d2baac38b9e3a397f 100644 (file)
@@ -3789,7 +3789,7 @@ Currently there are `js-mode' and `js-ts-mode'."
   ;;(syntax-propertize (point-max))
   )
 
-(defvar js--treesit-sentence-type-regexp
+(defvar js--treesit-sentence-nodes
   '("import_statement"
     "debugger_statement"
     "expression_statement"
@@ -3855,7 +3855,7 @@ See `treesit-sentence-type-regexp' for more information.")
     (setq-local treesit-defun-name-function #'js--treesit-defun-name)
 
     (setq-local treesit-sentence-type-regexp
-                (regexp-opt js--treesit-sentence-type-regexp))
+                (regexp-opt js--treesit-sentence-nodes))
 
     ;; Fontification.
     (setq-local treesit-font-lock-settings js--treesit-font-lock-settings)
index be84caa7b26219a9f76cfd55f40eb689af8ee2c4..cd631d048ea522d0e3d4c87b9c569c10149c6322 100644 (file)
@@ -312,7 +312,7 @@ Argument LANGUAGE is either `typescript' or `tsx'."
    :override t
    '((escape_sequence) @font-lock-escape-face)))
 
-(defvar typescript-ts-mode--sentence-type-regexp
+(defvar typescript-ts-mode--sentence-nodes
   '("import_statement"
     "debugger_statement"
     "expression_statement"
@@ -369,7 +369,7 @@ See `treesit-sentence-type-regexp' for more information.")
   (setq-local treesit-defun-name-function #'js--treesit-defun-name)
 
   (setq-local treesit-sentence-type-regexp
-              (regexp-opt typescript-ts-mode--sentence-type-regexp))
+              (regexp-opt typescript-ts-mode--sentence-nodes))
 
   ;; Imenu (same as in `js-ts-mode').
   (setq-local treesit-simple-imenu-settings
@@ -432,7 +432,7 @@ See `treesit-sentence-type-regexp' for more information.")
     ;; Navigation
     (setq-local treesit-sentence-type-regexp
                 (regexp-opt (append
-                             typescript-ts-mode--sentence-type-regexp
+                             typescript-ts-mode--sentence-nodes
                              '("jsx_element"
                                "jsx_self_closing_element"))))