emacs-diffs
[Top][All Lists]
Advanced

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

emacs-29 6fe9075ff38 2/2: Revert workaround introduced in Bug#56271


From: Eli Zaretskii
Subject: emacs-29 6fe9075ff38 2/2: Revert workaround introduced in Bug#56271
Date: Thu, 9 Mar 2023 05:15:33 -0500 (EST)

branch: emacs-29
commit 6fe9075ff3814ce825c9869c901903edad9d0b44
Author: kobarity <kobarity@gmail.com>
Commit: Eli Zaretskii <eliz@gnu.org>

    Revert workaround introduced in Bug#56271
    
    * lisp/progmodes/python.el (python-nav-end-of-statement)
    (python-nav-end-of-block): Revert workaround introduced in Bug#56271
    as the bug is fixedin Bug#58780.
---
 lisp/progmodes/python.el | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index ccf78e13148..5b11d204de1 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -2062,10 +2062,6 @@ of the statement."
                        ;; are somehow out of whack.  This has been
                        ;; observed when using `syntax-ppss' during
                        ;; narrowing.
-                       ;; It can also fail in cases where the buffer is in
-                       ;; the process of being modified, e.g. when creating
-                       ;; a string with `electric-pair-mode' disabled such
-                       ;; that there can be an unmatched single quote
                        (when (>= string-start last-string-end)
                          (goto-char string-start)
                          (if (python-syntax-context 'paren)
@@ -2154,10 +2150,7 @@ backward to previous statement."
       (while (and (forward-line 1)
                   (not (eobp))
                   (or (and (> (current-indentation) block-indentation)
-                           (let ((start (point)))
-                             (python-nav-end-of-statement)
-                             ;; must move forward otherwise infinite loop
-                             (> (point) start)))
+                           (or (python-nav-end-of-statement) t))
                       (python-info-current-line-comment-p)
                       (python-info-current-line-empty-p))))
       (python-util-forward-comment -1)



reply via email to

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