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

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

[elpa] externals/denote c7d8d07119 12/17: Rename save-excursion and save


From: ELPA Syncer
Subject: [elpa] externals/denote c7d8d07119 12/17: Rename save-excursion and save-restriction when using with-temp-buffer
Date: Mon, 15 Aug 2022 01:57:35 -0400 (EDT)

branch: externals/denote
commit c7d8d0711976caaa9875e1ce24d06a7f71f169d1
Author: Jean-Philippe Gagné Guay <jeanphilippe150@gmail.com>
Commit: Jean-Philippe Gagné Guay <jeanphilippe150@gmail.com>

    Rename save-excursion and save-restriction when using with-temp-buffer
---
 denote.el | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/denote.el b/denote.el
index 7276a32349..ad5b645c5e 100644
--- a/denote.el
+++ b/denote.el
@@ -1289,11 +1289,8 @@ block if appropriate."
   "Return t if REGEXP matches in the FILE."
   (with-temp-buffer
     (insert-file-contents file)
-    (save-excursion
-      (save-restriction
-        (widen)
-        (goto-char (point-min))
-        (re-search-forward regexp nil t 1)))))
+    (goto-char (point-min))
+    (re-search-forward regexp nil t 1)))
 
 (defun denote--edit-front-matter-p (file file-type)
   "Test if FILE should be subject to front matter rewrite.



reply via email to

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