emacs-diffs
[Top][All Lists]
Advanced

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

emacs-29 d9add66161: ; * lisp/subr.el (internal--with-narrowing): Simpli


From: Philip Kaludercic
Subject: emacs-29 d9add66161: ; * lisp/subr.el (internal--with-narrowing): Simplify
Date: Fri, 16 Dec 2022 18:41:20 -0500 (EST)

branch: emacs-29
commit d9add661617dfba491465943d402230699a9a4ff
Author: Philip Kaludercic <philipk@posteo.net>
Commit: Philip Kaludercic <philipk@posteo.net>

    ; * lisp/subr.el (internal--with-narrowing): Simplify
    
    (Bug#60130)
---
 lisp/subr.el | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/lisp/subr.el b/lisp/subr.el
index e142eaa810..b21cce1669 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -3956,10 +3956,9 @@ detailed description.
 (defun internal--with-narrowing (start end body &optional tag)
   "Helper function for `with-narrowing', which see."
   (save-restriction
-    (progn
-      (narrow-to-region start end)
-      (if tag (narrowing-lock tag))
-      (funcall body))))
+    (narrow-to-region start end)
+    (when tag (narrowing-lock tag))
+    (funcall body)))
 
 (defun find-tag-default-bounds ()
   "Determine the boundaries of the default tag, based on text at point.



reply via email to

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