소스 검색

Merge branch 'bugfix'

Ihor Radchenko 2 년 전
부모
커밋
d8133e80d8
4개의 변경된 파일13개의 추가작업 그리고 10개의 파일을 삭제
  1. 1 0
      lisp/oc-basic.el
  2. 4 3
      lisp/ox-ascii.el
  3. 3 2
      lisp/ox-md.el
  4. 5 5
      testing/org-test.el

+ 1 - 0
lisp/oc-basic.el

@@ -73,6 +73,7 @@
 (require 'seq)
 
 (declare-function org-open-at-point "org" (&optional arg))
+(declare-function org-open-file "org" (path &optional in-emacs line search))
 
 (declare-function org-element-interpret-data "org-element" (data))
 (declare-function org-element-property "org-element" (property element))

+ 4 - 3
lisp/ox-ascii.el

@@ -953,9 +953,10 @@ channel."
 			   (org-export-resolve-fuzzy-link link info)
                          ;; Ignore broken links.  On broken link,
                          ;; `org-export-resolve-id-link' will throw an
-                         ;; error and `ignore-error' will return nil.
-			 (ignore-error 'org-link-broken
-                           (org-export-resolve-id-link link info)))))
+                         ;; error and we will return nil.
+			 (condition-case nil
+                             (org-export-resolve-id-link link info)
+                           (org-link-broken nil)))))
              (when dest
 	       (concat
 	        (org-ascii--fill-string

+ 3 - 2
lisp/ox-md.el

@@ -195,8 +195,9 @@ of contents can refer to headlines."
        (lambda (link)
 	 (equal headline
                 ;; Ignore broken links.
-                (ignore-error 'org-link-broken
-                  (org-export-resolve-link link info))))
+                (condition-case nil
+                    (org-export-resolve-id-link link info)
+                  (org-link-broken nil))))
        info t))))
 
 (defun org-md--headline-title (style level title &optional anchor tags)

+ 5 - 5
testing/org-test.el

@@ -471,12 +471,12 @@ TIME can be a non-nil Lisp time value, or a string specifying a date and time."
 		      (or time ,at) args)))
 	    ((symbol-function 'decode-time)
 	     (lambda (&optional time zone form)
-               (condition-case err
+               (condition-case nil
                    (funcall ,(symbol-function 'decode-time)
 			    (or time ,at) zone form)
-                 ;; Fallback for Emacs <27.1.
-                 (error (funcall ,(symbol-function 'decode-time)
-			         (or time ,at) zone)))))
+                 (wrong-number-of-arguments
+                  (funcall ,(symbol-function 'decode-time)
+			   (or time ,at))))))
 	    ((symbol-function 'encode-time)
 	     (lambda (time &rest args)
 	       (apply ,(symbol-function 'encode-time) (or time ,at) args)))
@@ -492,7 +492,7 @@ TIME can be a non-nil Lisp time value, or a string specifying a date and time."
 	       (funcall ,(symbol-function 'set-file-times) file (or time ,at))))
 	    ((symbol-function 'time-add)
 	     (lambda (a b) (funcall ,(symbol-function 'time-add)
-				    (or a ,at) (or b ,at))))
+			       (or a ,at) (or b ,at))))
 	    ((symbol-function 'time-equal-p)
 	     (lambda (a b) (funcall ,(symbol-function 'time-equal-p)
 				    (or a ,at) (or b ,at))))