[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/flx 24dd436463 100/182: Fix compilation errors.
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/flx 24dd436463 100/182: Fix compilation errors. |
Date: |
Tue, 13 Dec 2022 03:59:34 -0500 (EST) |
branch: elpa/flx
commit 24dd436463cf622668b826ffdeace36899783f32
Author: Le Wang <le.wang@agworld.com.au>
Commit: Le Wang <le.wang@agworld.com.au>
Fix compilation errors.
---
flx.el | 39 +++++++++++++++++++--------------------
1 file changed, 19 insertions(+), 20 deletions(-)
diff --git a/flx.el b/flx.el
index ba96806b97..1de0131b57 100644
--- a/flx.el
+++ b/flx.el
@@ -56,26 +56,6 @@
"Face used by flx for highlighting flx match characters."
:group 'flx)
-
-(defun flx-get-hash-for-string (str heatmap-func)
- "Return hash-table for string where keys are characters value
- is a sorted list of indexes for character occurrences."
- (let* ((res (make-hash-table :test 'eq :size 32))
- (str-len (length str))
- down-char)
- (cl-loop for index from (1- str-len) downto 0
- for char = (aref str index)
- do (progn
- ;; simulate `case-fold-search'
- (if (flx-capital-p char)
- (progn
- (push index (gethash char res))
- (setq down-char (downcase char)))
- (setq down-char char))
- (push index (gethash down-char res))))
- (puthash 'heatmap (funcall heatmap-func str) res)
- res))
-
;;; Do we need more word separators than ST?
(defsubst flx-word-p (char)
"Check if CHAR is a word character."
@@ -113,6 +93,25 @@ from BEG (inclusive) to end (not inclusive).
(cl-incf beg))
vec)
+(defun flx-get-hash-for-string (str heatmap-func)
+ "Return hash-table for string where keys are characters value
+ is a sorted list of indexes for character occurrences."
+ (let* ((res (make-hash-table :test 'eq :size 32))
+ (str-len (length str))
+ down-char)
+ (cl-loop for index from (1- str-len) downto 0
+ for char = (aref str index)
+ do (progn
+ ;; simulate `case-fold-search'
+ (if (flx-capital-p char)
+ (progn
+ (push index (gethash char res))
+ (setq down-char (downcase char)))
+ (setq down-char char))
+ (push index (gethash down-char res))))
+ (puthash 'heatmap (funcall heatmap-func str) res)
+ res))
+
;; So we store one fixnum per character. Is this too memory inefficient?
(defun flx-get-heatmap-str (str &optional group-separator)
"Generate heat map vector of string.
- [nongnu] elpa/flx 67379d0a01 036/182: 2nd try fix for `ido-merge-work-directories`, (continued)
- [nongnu] elpa/flx 67379d0a01 036/182: 2nd try fix for `ido-merge-work-directories`, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 01818a56ae 039/182: handle of cons cells in completion list, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 3d15906942 019/182: move demo into misc, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx f1851c8983 037/182: treat last *non-zero* segment as basename, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 482b887215 046/182: (BREAKING) activate through proper minor-mode, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 451711cfeb 058/182: Improve comment headers, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx bebf045684 062/182: gracefully handle large collections, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 490412dcc9 061/182: Rename predicate functions according to Emacs Lisp style, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 1c42be202d 071/182: Merge pull request #29 from bbatsov/marmalade, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 638313b829 077/182: .gitignore: ignore emacs temporary files, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 24dd436463 100/182: Fix compilation errors.,
ELPA Syncer <=
- [nongnu] elpa/flx b322b72d7b 131/182: async comes from melpa, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 551b095274 130/182: fix travis cask path, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 26a1225431 137/182: rename optimization test, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 7a2601481c 142/182: Simplify flx-propertize, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx b95294518c 155/182: Debian and Ubuntu installation instructions, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 46040d0b09 160/182: Merge pull request #97 from antmak/patch-1, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 05600ff855 167/182: Merge pull request #103 from phst/add-license-file, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx e3b3f0533e 174/182: Merge pull request #108 from tarsiiformes/cleanup, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 48e10bf54f 177/182: Update to latest version of GPLv3 boilerplate, ELPA Syncer, 2022/12/13
- [nongnu] elpa/flx 8ee8a877ab 028/182: boost entire match score, ELPA Syncer, 2022/12/13