emacs-devel
[Top][All Lists]
Advanced

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

Re: suppressing byte-compiler warnings about undefined functions


From: Alan Mackenzie
Subject: Re: suppressing byte-compiler warnings about undefined functions
Date: Sun, 11 Nov 2007 16:10:42 +0000
User-agent: Mutt/1.5.9i

Hi, Dan!

On Sun, Nov 11, 2007 at 07:51:24AM -0800, Dan Nicolaescu wrote:
> Alan Mackenzie <address@hidden> writes:

>   > On Fri, Nov 09, 2007 at 07:55:08PM -0500, Glenn Morris wrote:

>   > > Here's an attempt at a method to allow for suppressing of
>   > > byte-compiler warnings about undefined functions.

>   > > I haven't yet written the function to check that functions are
>   > > actually defined in the specified files, but I imagine it would be
>   > > straightforward.

>   > As a matter of interest, there has been this sort of functionality
>   > in cc-bytecomp.el (written by Martin Stjernholm) for some time.  In
>   > particular, `cc-bytecomp-defun' and `cc-bytecomp-defvar', whose
>   > prime use is suppressing compiler warnings.

> What is the advantage of (cc-bytecomp-defvar VARIABLE) over plain
> (defvar VARIABLE)? 

You can have the variable "defined" solely for the duration of the
byte-compilation.  This is useful for `xemacs-foo' and `gnu-emacs-bar'
if your file.el is portable.  It's useful for core Emacs
variables/functions defined in a file which isn't currently loaded.

>   > It might be sensible to reuse this.

> Would that be possible without editing all elisp files in emacs?

Yes, absolutely!  But it'll need some files to be edited.  ;-)

-- 
Alan Mackenzie (Ittersbach, Germany).




reply via email to

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