]> code.delx.au - gnu-emacs-elpa/commitdiff
js2-indent-operator-re, js2-declaration-keyword-re: Use symbols boundaries
authorDmitry Gutov <dgutov@yandex.ru>
Fri, 18 Mar 2016 15:46:10 +0000 (17:46 +0200)
committerDmitry Gutov <dgutov@yandex.ru>
Fri, 18 Mar 2016 15:46:10 +0000 (17:46 +0200)
Fixes #319

js2-old-indent.el

index 9768d1e513037d9b68f2effd2f992746587f562f..d855b9e2561ffa0005051f8a8c311204fc293a88 100644 (file)
@@ -132,12 +132,12 @@ followed by an opening brace.")
 
 (defconst js2-indent-operator-re
   (concat "[-+*/%<>&^|?:.]\\([^-+*/]\\|$\\)\\|!?=\\|"
-          (regexp-opt '("in" "instanceof") 'words))
+          (regexp-opt '("in" "instanceof") 'symbols))
   "Regular expression matching operators that affect indentation
 of continued expressions.")
 
 (defconst js2-declaration-keyword-re
-  (regexp-opt '("var" "let" "const") 'words)
+  (regexp-opt '("var" "let" "const") 'symbols)
   "Regular expression matching variable declaration keywords.")
 
 (defun js2-re-search-forward-inner (regexp &optional bound count)