File tree 1 file changed +13
-17
lines changed
1 file changed +13
-17
lines changed Original file line number Diff line number Diff line change @@ -868,13 +868,12 @@ highlighted region)."
868
868
(setq docelt (funcall docelt)))
869
869
(goto-char listbeg)
870
870
(forward-char 1 )
871
- (condition-case nil
872
- (while (and (> docelt 0 ) (< (point ) startpos)
873
- (progn (forward-sexp 1 ) t ))
874
- ; ; ignore metadata and type hints
875
- (unless (looking-at " [ \n\t ]*\\ (\\ ^[A-Z:].+\\ |\\ ^?{.+\\ )" )
876
- (setq docelt (1- docelt))))
877
- (error nil ))
871
+ (ignore-errors
872
+ (while (and (> docelt 0 ) (< (point ) startpos)
873
+ (progn (forward-sexp 1 ) t ))
874
+ ; ; ignore metadata and type hints
875
+ (unless (looking-at " [ \n\t ]*\\ (\\ ^[A-Z:].+\\ |\\ ^?{.+\\ )" )
876
+ (setq docelt (1- docelt)))))
878
877
(and (zerop docelt) (<= (point ) startpos)
879
878
(progn (forward-comment (point-max )) t )
880
879
(= (point ) (nth 8 state)))))
@@ -901,20 +900,17 @@ highlighted region)."
901
900
Note that this means that there is no guarantee of proper font
902
901
locking in def* forms that are not at top level."
903
902
(goto-char point)
904
- (condition-case nil
905
- (beginning-of-defun )
906
- (error nil ))
903
+ (ignore-errors
904
+ (beginning-of-defun ))
907
905
908
906
(let ((beg-def (point )))
909
907
(when (and (not (= point beg-def))
910
908
(looking-at " (def" ))
911
- (condition-case nil
912
- (progn
913
- ; ; move forward as much as possible until failure (or success)
914
- (forward-char )
915
- (dotimes (_ 4 )
916
- (forward-sexp )))
917
- (error nil ))
909
+ (ignore-errors
910
+ ; ; move forward as much as possible until failure (or success)
911
+ (forward-char )
912
+ (dotimes (_ 4 )
913
+ (forward-sexp )))
918
914
(cons beg-def (point )))))
919
915
920
916
(defun clojure-font-lock-extend-region-def ()
You can’t perform that action at this time.
0 commit comments