emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/evil-matchit e941c695f3 173/244: Add [ and { as well.


From: ELPA Syncer
Subject: [nongnu] elpa/evil-matchit e941c695f3 173/244: Add [ and { as well.
Date: Thu, 6 Jan 2022 02:58:59 -0500 (EST)

branch: elpa/evil-matchit
commit e941c695f36eb2219024dcb4bc38caa9ecb85392
Author: Tomasz KoƂodziejski <tkolodziejski@gmail.com>
Commit: Tomasz KoƂodziejski <tkolodziejski@gmail.com>

    Add [ and { as well.
---
 evil-matchit-ocaml.el | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/evil-matchit-ocaml.el b/evil-matchit-ocaml.el
index 65819bf6ee..9239bf2a84 100644
--- a/evil-matchit-ocaml.el
+++ b/evil-matchit-ocaml.el
@@ -37,6 +37,8 @@
     (("while" "for") ("done"))
     (("let") ("in"))
     (("(") (")"))
+    (("[") ("]"))
+    (("{") ("}"))
     ())
   "Ocaml keywords.")
 
@@ -46,12 +48,12 @@
 ;; Please note this regex is a bit funny: we don't need to check for word
 ;; boundaries because later on we check evilmi-ocaml-in-keyword-p
 (defvar evilmi-ocaml-keywords-regex
-  (format "\\(%s\\)" (mapconcat 'identity evilmi-ocaml-all-keywords "\\|"))
+  (format "\\(%s\\)" (mapconcat 'regexp-quote evilmi-ocaml-all-keywords "\\|"))
   "Regexp to find next/previous keyword.")
 
 (defun evilmi-ocaml-row-regex (tag-info)
   "Build regexp to find next/previous keyword in a row."
-  (format "\\(%s\\)" (mapconcat 'identity (apply 'append tag-info) "\\|")))
+  (format "\\(%s\\)" (mapconcat 'regexp-quote (apply 'append tag-info) "\\|")))
 
 (defun evilmi-ocaml-in-keyword-p (pos)
   "Check character at POS is keyword by comparing font face."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]