The following message is a courtesy copy of an article
that has been posted to comp.emacs.xemacs,comp.emacs as well.
"Matthew O. Persico" <persicom(a)acedsl.com> writes:
(unless (or
(eq " *Minibuf-0*" 'buffer_name)
I assume this comparison wants to check whether the point is in the
minibuffer. You have several bugs there.
* You're comparing a literal string to a symbol. That is always
false, per definition. Lose the quote before buffer_name.
* You misspelled buffer_name -- what you meant was buffer-name. Even
so, buffer-name is a function rather than a variable, so you need to
call it -- change buffer-name to (buffer-name).
* You test for equality of identities (EQ) instead of equality of
values (EQUAL). Change eq to equal for proper string comparison.
The version that should do what the above was supposed to do is
(untested):
(equal " *Minibuf-0*" (buffer-name))
Still, it's probably not good style to hard-code internal buffer names
like that. A more correct comparison might be:
(eq (selected-window) (minibuffer-window))
Since I don't have the master code you're referring to, this is all
untested. Hope it helps.