File tree Expand file tree Collapse file tree 1 file changed +17
-13
lines changed Expand file tree Collapse file tree 1 file changed +17
-13
lines changed Original file line number Diff line number Diff line change @@ -1626,19 +1626,23 @@ Point must be between the opening paren and the -> symbol."
1626
1626
" Unwind thread at point or above point by one level.
1627
1627
Return nil if there are no more levels to unwind."
1628
1628
(interactive )
1629
- (ignore-errors
1630
- (when (looking-at " (" )
1631
- (forward-char 1 )
1632
- (forward-sexp 1 )))
1633
- (search-backward-regexp " ([^-]*->" )
1634
- (if (clojure--nothing-more-to-unwind)
1635
- (progn (clojure--pop-out-of-threading)
1636
- nil )
1637
- (down-list )
1638
- (cond
1639
- ((looking-at " [^-]*->\\ _>" ) (clojure--unwind-first))
1640
- ((looking-at " [^-]*->>\\ _>" ) (clojure--unwind-last)))
1641
- t ))
1629
+ (save-excursion
1630
+ (let ((limit (save-excursion
1631
+ (beginning-of-defun )
1632
+ (point ))))
1633
+ (ignore-errors
1634
+ (when (looking-at " (" )
1635
+ (forward-char 1 )
1636
+ (forward-sexp 1 )))
1637
+ (search-backward-regexp " ([^-]*->" limit)
1638
+ (if (clojure--nothing-more-to-unwind)
1639
+ (progn (clojure--pop-out-of-threading)
1640
+ nil )
1641
+ (down-list )
1642
+ (cond
1643
+ ((looking-at " [^-]*->\\ _>" ) (clojure--unwind-first))
1644
+ ((looking-at " [^-]*->>\\ _>" ) (clojure--unwind-last)))
1645
+ t ))))
1642
1646
1643
1647
;;;### autoload
1644
1648
(defun clojure-unwind-all ()
You can’t perform that action at this time.
0 commit comments