emacs-devel
[Top][All Lists]
Advanced

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

RE: face for non-ASCII characters


From: Drew Adams
Subject: RE: face for non-ASCII characters
Date: Sat, 16 Apr 2011 09:00:08 -0700

> > Yes, `idn-is-recommended' is autoloaded.  It may be a 
> > problem with the fboundp call, which will return true even
> > if the library is not available:
> > (when (autoload 'coocoo "coo")(fboundp 'coocoo)) => t
> > so maybe (require 'idn nil t) is a better approach
> 
> I think autoloading and checking if the function is defined is the
> best way. (Autoloading of `idn-is-recommended' should of course not be
> setup if idn.el is not available.)

I'm not following this thread, so ignore if this question doesn't help:

Why set up autoloading here?  Seems like you would want to either soft-require
the library (no error if not there) or simply test whether the function is
defined (which presumably happens when the library is loaded).

IOW, why don't you just choose between (require 'foo nil t) and (fboundp
'foobar)?  What's the point of having this library autoload the other one but
not soft-require it?

(FWIW, it sounds a priori like you should maybe just use the `fboundp' test, and
not worry about automatically loading the other library.)

Again, ignore if irrelevant to your discussion.




reply via email to

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