emacs-diffs
[Top][All Lists]
Advanced

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

master 0ebe267: * lisp/char-fold.el (char-fold-to-regexp): Handle lax-wh


From: Juri Linkov
Subject: master 0ebe267: * lisp/char-fold.el (char-fold-to-regexp): Handle lax-whitespace (bug#38539)
Date: Mon, 7 Sep 2020 14:33:32 -0400 (EDT)

branch: master
commit 0ebe2678002ffb82a25311c56cbc4b8ba3bd5fa1
Author: Juri Linkov <juri@linkov.net>
Commit: Juri Linkov <juri@linkov.net>

    * lisp/char-fold.el (char-fold-to-regexp): Handle lax-whitespace (bug#38539)
---
 lisp/char-fold.el | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lisp/char-fold.el b/lisp/char-fold.el
index 5a3c20c..34561a2 100644
--- a/lisp/char-fold.el
+++ b/lisp/char-fold.el
@@ -324,6 +324,13 @@ from which to start."
     (while (< i end)
       (pcase (aref string i)
         (?\s (setq spaces (1+ spaces)))
+        ((pred (lambda (c) (and char-fold-symmetric
+                                (if isearch-regexp
+                                    isearch-regexp-lax-whitespace
+                                  isearch-lax-whitespace)
+                                (stringp search-whitespace-regexp)
+                                (string-match-p search-whitespace-regexp 
(char-to-string c)))))
+         (setq spaces (1+ spaces)))
         (c (when (> spaces 0)
              (push (char-fold--make-space-string spaces) out)
              (setq spaces 0))



reply via email to

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