diff --git a/lisp/oc-biblatex.el b/lisp/oc-biblatex.el index 0031ec48b..6221286eb 100644 --- a/lisp/oc-biblatex.el +++ b/lisp/oc-biblatex.el @@ -363,7 +363,7 @@ INFO is the export state, as a property list." (_ nil)))) (apply #'org-cite-biblatex--command citation info - (pcase (seq-first candidates) + (pcase (seq-elt candidates 0) ;; `seq-first' is not available in Emacs 26. (`(,_ ,_ . ,command-parameters) command-parameters) ('nil (user-error diff --git a/lisp/org-persist.el b/lisp/org-persist.el index a30c75f38..ee28fc51d 100644 --- a/lisp/org-persist.el +++ b/lisp/org-persist.el @@ -358,15 +358,14 @@ FORMAT and ARGS are passed to `message'." "Bind container and associated from COLLECTION and execute BODY." (declare (debug (form body)) (indent 1)) `(with-no-warnings - ;; FIXME: We only need to suppress warnings about unused - ;; let-bindings. However, it is unclear how to achieve it with - ;; `with-suppressed-warnings'. (let* ((container (plist-get ,collection :container)) (associated (plist-get ,collection :associated)) (path (plist-get associated :file)) (inode (plist-get associated :inode)) (hash (plist-get associated :hash)) (key (plist-get associated :key))) + ;; Suppress "unused variable" warnings. + (ignore container associated path inode hash key) ,@body))) (defun org-persist--find-index (collection) diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el index 6cd751409..0d1d05f74 100644 --- a/lisp/ox-latex.el +++ b/lisp/ox-latex.el @@ -3420,10 +3420,10 @@ and FLOAT are extracted from SRC-BLOCK and INFO in `org-latex-src-block'." (equal '("false") (cdr opt))) 'no))))) opts)))) - (if-let ((mathescape (or (funcall mathescape-status default-options) - (funcall mathescape-status options)))) - (when (eq mathescape 'yes) - (or engrave-faces-latex-mathescape t))))) + (let ((mathescape (or (funcall mathescape-status default-options) + (funcall mathescape-status options)))) + (when (eq mathescape 'yes) + (or engrave-faces-latex-mathescape t))))) (defun org-latex-src--engrave-code (content lang &optional theme options inline) "Engrave CONTENT to LaTeX in a LANG-mode buffer, and give the result. @@ -3443,7 +3443,7 @@ to the Verbatim environment or Verb command." engrave-faces-current-preset-style)) (engraved-buffer (with-temp-buffer - (insert (string-trim-right content "\n")) + (insert (replace-regexp-in-string "\n\\'" "" content)) (when lang-mode (if (functionp lang-mode) (funcall lang-mode) diff --git a/lisp/ox.el b/lisp/ox.el index 03af47001..8223940fb 100644 --- a/lisp/ox.el +++ b/lisp/ox.el @@ -4520,6 +4520,7 @@ Return value can be an object or an element: (org-persist-register location-type path :write-immediately t)))) +(require 'subr-x) ;; FIXME: For `thread-first' in Emacs 26. (defun org-export-link-localise (link) "Convert remote LINK to local link. If LINK refers to a remote resource, modify it to point to a local