GNU bug report logs -
#35802
Broken data loaded from uni-decomposition
Previous Next
Reported by: Juri Linkov <juri <at> linkov.net>
Date: Sun, 19 May 2019 20:21:02 UTC
Severity: normal
Tags: fixed, patch
Fixed in version 27.1
Done: Noam Postavsky <npostavs <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
Message #23 received at 35802 <at> debbugs.gnu.org (full text, mbox):
>>> Actually maybe it's just a matter of making isearch bind
>>> search-spaces-regexp less widely. I'm not quite following when the your
>>> problem happens though. Can you show a backtrace from your original
>>> problem using
>>>
>>> (add-hook 'after-load-functions
>>> (lambda (f) (when (string-match-p "uni-decomposition" f)
>>> (debug nil :search-spaces-regexp search-spaces-regexp))))
>>
>> When I eval both the above and (setq search-whitespace-regexp "\\(\\s-\\|\n\\)+")
>> then debugger still shows that search-spaces-regexp is nil
>> (also note where search-spaces-regexp is let-bound to non-nil in the backtrace,
>> see also more info after the backtrace):
>
> Hmm, can you show exactly what's needed to trigger this? I tried the
> above after applying your patch in Bug#35802, but uni-decomposition was
> never loaded.
Here is a complete reproducible test case:
-1. Apply the following patch to master and recompile
0. emacs -Q
1. Eval:
(progn
(setq search-whitespace-regexp "\\(\\s-\\|\n\\)+")
(add-hook 'after-load-functions
(lambda (f) (when (string-match-p "uni-decomposition" f)
(debug nil :search-spaces-regexp search-spaces-regexp)))))
2. Type C-s M-s ' a
diff --git a/lisp/char-fold.el b/lisp/char-fold.el
index d2fa7108bb..7b0e55bb11 100644
--- a/lisp/char-fold.el
+++ b/lisp/char-fold.el
@@ -28,7 +28,6 @@
(defun char-fold-make-table ()
(let* ((equiv (make-char-table 'char-fold-table))
(equiv-multi (make-char-table 'char-fold-table))
- (search-spaces-regexp nil) ; workaround for bug#35802
(table (unicode-property-table-internal 'decomposition)))
(set-char-table-extra-slot equiv 0 equiv-multi)
@@ -141,6 +140,11 @@ char-fold-table
Exceptionally for the space character (32), ALIST is ignored.")
+(progn
+ (message "search-spaces-regexp: %S" search-spaces-regexp)
+ ;; Emulate funcall from defcustom :set
+ (setq char-fold-table (char-fold-make-table)))
+
(defun char-fold--make-space-string (n)
"Return a string that matches N spaces."
(format "\\(?:%s\\|%s\\)"
This bug report was last modified 6 years and 2 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.