* lisp/org-macro.el (org-macro--collect-macros): Ignore macro
definitions in commented subtrees.
* lisp/ox.el (org-export--get-inbuffer-options): Ignore options in
commented subtrees.
(org-export--delete-commented-subtrees): Remove function.
(org-export-as): Apply removal.
Removing the whole subtree is not subtle as Babel might want to use
data there.
Reported-by: Robert Klein <RoKlein@roklein.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/96347>
* lisp/org-macro.el (org-macro-escape-arguments,
org-macro-extract-arguments): New functions.
* lisp/org-element.el (org-element-macro-parser): Use new function.
* testing/lisp/test-org-macro.el (test-org-macro/escape-arguments,
test-org-macro/extract-arguments): New tests.
* lisp/ob-eval.el, lisp/ob.el, lisp/org-macro.el, lisp/org-mhe.el:
Require org-macs and org-compat as necessary.
* lisp/ob-tangle.el: Declare function `org-store-link' and
`org-open-link-from-string'.
* lisp/org-compat.el: Extend eval-and-compile clause and add advices
for functions that have different parameter lists in XEmacs. Add
variable definitions that XEmacs lacks .
* lisp/org-macs.el (declare-function): Define macro to use autoload
instead for XEmacs.
* lisp/ox-html.el, lisp/ox-odt.el: XEmacs does not have table.el, so
use 'noerror on the require form.
* lisp/ox-texinfo.el (org-texinfo-table-column-widths): Fix spliced
argument list that XEmacs complains about by adding parenthesis.
This fixes all compilation failures on XEmacs and warnings related to
Org that indicate that XEmacs has compiled things wrongly (for
instance it might have interpreted a function as a variable symbol).
There are still many warnings that probably indicate serious problems.
* lisp/org-macro.el (org-macro-expand): Do not try to interpret the
macro replacement text as a regex so that escaped backslashes and
commas in macro arguments will be interpreted correctly.
* lisp/org-macro.el (org-macro--collect-macros): Fix a bug where
reading a macro in a setup file would remove other macros read so
far from template. Change function signature.
(org-macro-initialize-templates): Apply signature change from function
above.
* testing/lisp/test-org-macro.el: Add test.