[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Problems with (defvar foo) and Emacs 23
From: |
Nick Dokos |
Subject: |
Re: [O] Problems with (defvar foo) and Emacs 23 |
Date: |
Sun, 01 Apr 2012 16:46:33 -0400 |
Bernt Hansen <address@hidden> wrote:
> Hi Bastien,
>
> I updated to master today e917477 ((org-xhtml.el): Removed, 2012-04-01)
> and am getting errors about org-clock-last-state not defined in my GNU
> Emacs 23.2.1 (i486-pc-linux-gnu, GTK+ Version 2.20.0) of 2010-12-11 on
> raven, modified by Debian
>
> I can see the variable in the source defined as
>
> lisp/org-clock.el:(defvar org-clock-state) ;; dynamically scoped into this
> function
>
> but I don't get a variable definition with this code in emacs 23.2.1.
>
> If I change the definition to
>
> (defvar org-clock-state nil)
>
> then it works for me.
>
> There are _lots_ of these types of definitions with no value in the
> org-mode source.
>
They are not supposed to *define* a variable. They are there to tell the
compiler not to worry. They are somewhat similar[fn:1] to extern declarations
in C code: whoever needs to use the variable says
(defvar foo)
There is (supposed to be) *one* place somewhere that actually defines
it:
(defvar foo 1)
Nick
Footnotes:
[fn:1] ...for some value of "similar". You have to take this with the
appropriately sized grain of salt.
- Re: [O] Problems with (defvar foo) and Emacs 23, (continued)
- Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/02
- Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/02
- Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/02
- Re: [O] Problems with (defvar foo) and Emacs 23, Achim Gratz, 2012/04/02
- Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/03
- Re: [O] Problems with (defvar foo) and Emacs 23, Achim Gratz, 2012/04/03
- Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/04
Re: [O] Problems with (defvar foo) and Emacs 23, Bastien, 2012/04/02
Re: [O] Problems with (defvar foo) and Emacs 23,
Nick Dokos <=