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: Dan Nicolaescu
Subject: Re: suppressing byte-compiler warnings about undefined functions
Date: Sun, 11 Nov 2007 08:18:39 -0800

Alan Mackenzie <address@hidden> writes:

  > 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.

But that is not different from plain defvar, it just seems to add
a layer of obfuscation...

  > >   > 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.  ;-)

:-) Joke aside, please see the long discussion that preceded Glenn's
design, the thread was called "byte compiler warnings when bootstrapping".




reply via email to

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