[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

eval-when-compile and declare-function

From: Joe Riel
Subject: eval-when-compile and declare-function
Date: Thu, 31 Dec 2009 15:39:17 -0800
User-agent: Thunderbird (X11/20090817)

Why does declare-function not work when used inside eval-when-compile?
It does work inside eval-and-compile. For example, byte-compile the following:

 (declare-function hello "hello"))
 (declare-function goodbye "goodbye"))
(declare-function whatever "whatever")
(defun junk ()

Compiling file /home/joe/emacs/mdb/lisp/test.el at Thu Dec 31 15:34:09 2009

In end of data:
test.el:13:1:Warning: the function `goodbye' is not known to be defined.

I'm guessing the expected usage is the declaration for "whatever", that is,
outside either eval-and-compile or eval-when-compile.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]