[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/anzu 2a9785459b 111/288: Merge pull request #20 from syohe
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/anzu 2a9785459b 111/288: Merge pull request #20 from syohex/enable-lexical-binding |
Date: |
Thu, 6 Jan 2022 03:58:45 -0500 (EST) |
branch: elpa/anzu
commit 2a9785459b25fdeb44a7ce90089206f7df116498
Merge: e26f29af37 a06fb937b5
Author: Syohei YOSHIDA <syohex@gmail.com>
Commit: Syohei YOSHIDA <syohex@gmail.com>
Merge pull request #20 from syohex/enable-lexical-binding
Enable lexical-binding
---
anzu.el | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/anzu.el b/anzu.el
index 3e16c3d953..ca84395897 100644
--- a/anzu.el
+++ b/anzu.el
@@ -1,4 +1,4 @@
-;;; anzu.el --- Show number of matches in mode-line while searching
+;;; anzu.el --- Show number of matches in mode-line while searching -*-
lexical-binding: t; -*-
;; Copyright (C) 2014 by Syohei YOSHIDA
@@ -132,7 +132,7 @@
(defvar anzu--last-replace-input "")
(defun anzu--validate-regexp (regexp)
- (condition-case err
+ (condition-case nil
(progn
(string-match-p regexp "")
t)
@@ -377,7 +377,7 @@
((and (consp compiled) (stringp (car compiled)))
(car compiled)))))
-(defun anzu--evaluate-occurrence (ov to-regexp replace-count)
+(defun anzu--evaluate-occurrence (ov to-regexp replacements)
(let ((from-regexp (overlay-get ov 'from-regexp))
(from-string (overlay-get ov 'from-string))
(compiled (anzu--compile-replace-text to-regexp)))
@@ -387,7 +387,7 @@
(when (re-search-forward from-regexp nil t)
(if (consp compiled)
(replace-match (funcall (car compiled) (cdr compiled)
- replace-count) t)
+ replacements) t)
(replace-match compiled t))
(buffer-substring (point-min) (point-max))))))
@@ -406,15 +406,15 @@
(defun anzu--append-replaced-string (buf beg end use-regexp overlay-limit)
(let ((content (minibuffer-contents))
- (replace-count 0))
+ (replacements 0))
(unless (string= content anzu--last-replace-input)
(setq anzu--last-replace-input content)
(with-current-buffer buf
(dolist (ov (anzu--overlays-in-range beg (min end overlay-limit)))
(let ((replace-evaled (and use-regexp (anzu--evaluate-occurrence
- ov content replace-count))))
+ ov content replacements))))
(if replace-evaled
- (cl-incf replace-count)
+ (cl-incf replacements)
(setq replace-evaled content))
(overlay-put ov 'after-string (anzu--propertize-to-string
replace-evaled))))))))
@@ -457,7 +457,7 @@
(forward-line 1)
(point)))
-(defun anzu--query-from-at-cursor (prompt buf beg end overlay-limit)
+(defun anzu--query-from-at-cursor (buf beg end overlay-limit)
(let ((symbol (thing-at-point 'symbol)))
(unless symbol
(error "No symbol at cursor!!"))
@@ -529,7 +529,7 @@
(let* ((from (if (and at-cursor beg)
(progn
(setq delimited nil)
- (anzu--query-from-at-cursor prompt curbuf beg end
overlay-limit))
+ (anzu--query-from-at-cursor curbuf beg end
overlay-limit))
(anzu--query-from-string prompt beg end use-regexp
overlay-limit)))
(to (if (consp from)
(prog1 (cdr from) (setq from (car from)))
- [nongnu] elpa/anzu 5718f08dc6 066/288: Fix case fold issue, (continued)
- [nongnu] elpa/anzu 5718f08dc6 066/288: Fix case fold issue, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 17b3ab244b 074/288: Fix case, no symbol at cursor, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu c324833756 080/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu f50be69c0f 082/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu eb2b4ec103 084/288: fix link, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 156980dc69 092/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu c7ecd57c24 095/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 91f3478003 097/288: Merge pull request #15 from syohex/fix-nonprefix-case, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 189c0eaf9f 101/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 0b3cf4b0a6 103/288: Merge pull request #17 from syohex/add-nonquery-replace-command, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 2a9785459b 111/288: Merge pull request #20 from syohex/enable-lexical-binding,
ELPA Syncer <=
- [nongnu] elpa/anzu 8e92765ab7 113/288: Specify Emacs version, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 8fe3d080ff 114/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 11dcdf722f 128/288: Use package-file instead of package, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 718d5845d1 126/288: Merge pull request #25 from syohex/add-lines-region, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 485f463a40 127/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu ffcffffc1a 130/288: Merge pull request #26 from cedricporter/master, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 1ae7297bc7 132/288: Merge pull request #27 from syohex/fix-for-toggle-search, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu c0d58a61c2 136/288: A couple of grammar and typo fixes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 41f19cd2c2 214/288: Bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 4426cff3bf 205/288: Correct removed hook function name, ELPA Syncer, 2022/01/06