* "void-variable: tree" in agenda in emacs 23.4.1
@ 2014-01-11 6:01 Daniel Clemente
2014-01-11 9:22 ` Nicolas Goaziou
0 siblings, 1 reply; 2+ messages in thread
From: Daniel Clemente @ 2014-01-11 6:01 UTC (permalink / raw)
To: emacs-orgmode
Hi,
since some days ago I get an export error after C-a a, batch export, C-e on .org files, … Backtrace at the end.
Even (avl-tree--root org-element--cache) or (avl-tree--root nil) produce the same error.
This is not a bug in org, but in Emacs 23.4.1. avl-tree.el says:
(defmacro avl-tree--root (tree)
;; Return the root node for an avl-tree. INTERNAL USE ONLY.
`(avl-tree--node-left (avl-tree--dummyroot tree)))
And it should have a comma before the word „tree“ in the body. Like this (org-mode works with this):
(defmacro avl-tree--root (tree)
;; Return the root node for an avl-tree. INTERNAL USE ONLY.
`(avl-tree--node-left (avl-tree--dummyroot ,tree)))
This was fixed in emacs from Bazaar (in rev. 104392, Fri 2011-05-27 20:03:26 -0300).
But at the moment org-mode does not work in Emacs 23.4.1, so I think it should have a work-around.
The fix can be: „if Emacs version is lower than […] then define the macro again with the correct code“. Like:
(if (version< emacs-version "24")
(defmacro avl-tree--root (tree)
;; Backport fix for older versions due to missing comma in ,tree
`(avl-tree--node-left (avl-tree--dummyroot ,tree)))
)
Thanks,
Daniel
Backtrace:
Debugger entered--Lisp error: (void-variable tree)
(avl-tree--dummyroot tree)
(avl-tree--node-left (avl-tree--dummyroot tree))
(avl-tree--root org-element--cache)
(let ((node ...) last) (catch (quote found) (while node ...) last))
(if (not (wholenump key)) (gethash key org-element--cache-objects) (let (... last) (catch ... ... last)))
(progn (when (and ... ...) (org-element--cache-sync ...)) (if (not ...) (gethash key org-element--cache-objects) (let ... ...)))
(if (and org-element-use-cache org-element--cache) (progn (when ... ...) (if ... ... ...)))
(when (and org-element-use-cache org-element--cache) (when (and ... ...) (org-element--cache-sync ...)) (if (not ...) (gethash key org-element--cache-objects) (let ... ...)))
org-element-cache-get(65264)
(let* ((cached ...) (begin ...)) (cond (... ... ... ...) (... ...) (... ... ... ...) (t ...)))
(let ((origin ...) element next) (end-of-line) (skip-chars-backward " \r \n") (cond (... ...) (... ... ...)) (goto-char origin) (let* (... ...) (cond ... ... ... ...)) (let (... parent special-flag) (while t ... ... ...)))
(save-restriction (widen) (let (... element next) (end-of-line) (skip-chars-backward " \r \n") (cond ... ...) (goto-char origin) (let* ... ...) (let ... ...)))
(save-excursion (save-restriction (widen) (let ... ... ... ... ... ... ...)))
(org-with-wide-buffer (let (... element next) (end-of-line) (skip-chars-backward " \r \n") (cond ... ...) (goto-char origin) (let* ... ...) (let ... ...)))
…
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: "void-variable: tree" in agenda in emacs 23.4.1
2014-01-11 6:01 "void-variable: tree" in agenda in emacs 23.4.1 Daniel Clemente
@ 2014-01-11 9:22 ` Nicolas Goaziou
0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2014-01-11 9:22 UTC (permalink / raw)
To: Daniel Clemente; +Cc: emacs-orgmode
Hello,
Daniel Clemente <n142857@gmail.com> writes:
> since some days ago I get an export error after C-a a, batch export, C-e on .org files, … Backtrace at the end.
>
> Even (avl-tree--root org-element--cache) or (avl-tree--root nil) produce the same error.
>
> This is not a bug in org, but in Emacs 23.4.1. avl-tree.el says:
>
> (defmacro avl-tree--root (tree)
> ;; Return the root node for an avl-tree. INTERNAL USE ONLY.
> `(avl-tree--node-left (avl-tree--dummyroot tree)))
>
> And it should have a comma before the word „tree“ in the body. Like this (org-mode works with this):
>
> (defmacro avl-tree--root (tree)
> ;; Return the root node for an avl-tree. INTERNAL USE ONLY.
> `(avl-tree--node-left (avl-tree--dummyroot ,tree)))
>
> This was fixed in emacs from Bazaar (in rev. 104392, Fri 2011-05-27
> 20:03:26 -0300).
I wasn't aware of this bug. Thank you.
> But at the moment org-mode does not work in Emacs 23.4.1, so I think it should have a work-around.
> The fix can be: „if Emacs version is lower than […] then define the macro again with the correct code“. Like:
>
> (if (version< emacs-version "24")
> (defmacro avl-tree--root (tree)
> ;; Backport fix for older versions due to missing comma in ,tree
> `(avl-tree--node-left (avl-tree--dummyroot ,tree)))
> )
I just avoided to use `avl-tree--root' altogether. Hopefully, this
should fix the problem.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-01-11 9:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-11 6:01 "void-variable: tree" in agenda in emacs 23.4.1 Daniel Clemente
2014-01-11 9:22 ` Nicolas Goaziou
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.