ox: Add autoload cookies

* lisp/ox.el (org-export-derived-backend-p):
(org-export-data):
(org-export-raw-string): Autoload function.

These functions are required at runtime by some other libraries (e.g.,
"oc-basic.el"), which cannot require `ox' because of circular
dependencies.

In particular, this fixes
<http://lists.gnu.org/r/emacs-orgmode/2021-11/msg00594.html>.
This commit is contained in:
Nicolas Goaziou 2021-11-26 11:40:28 +01:00
parent 30a6126bb9
commit 2b0007a808
1 changed files with 3 additions and 0 deletions

View File

@ -1048,6 +1048,7 @@ BACKEND is a structure with `org-export-backend' type."
(unless (org-export-backend-p backend)
(error "Unknown \"%s\" back-end: Aborting export" backend)))
;;;###autoload
(defun org-export-derived-backend-p (backend &rest backends)
"Non-nil if BACKEND is derived from one of BACKENDS.
BACKEND is an export back-end, as returned by, e.g.,
@ -1858,6 +1859,7 @@ INFO is a plist containing export directives."
(let ((transcoder (cdr (assq type (plist-get info :translate-alist)))))
(and (functionp transcoder) transcoder)))))
;;;###autoload
(defun org-export-data (data info)
"Convert DATA into current back-end format.
@ -4586,6 +4588,7 @@ objects of the same type."
;; `org-export-raw-string' builds a pseudo-object out of a string
;; that any export back-end returns as-is.
;;;###autoload
(defun org-export-raw-string (s)
"Return a raw object containing string S.
A raw string is exported as-is, with no additional processing