emacs-devel
[Top][All Lists]
Advanced

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

Re: Double hyphens in variable names.


From: Lute Kamstra
Subject: Re: Double hyphens in variable names.
Date: Fri, 03 Oct 2003 21:37:42 +0200
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

Luc Teirlinck <address@hidden> writes:

> Lute Kamstra wrote:
>
>    Imenu's functionality can be easily explained without referring to
>    imenu--info-alist, so I think I'll do that.
>
> I guess you really mean imenu--index-alist.  

Yes, me braindead.

> If I understand correctly, (elisp)Imenu explains how a major mode
> author can help construct imenu--index-alist in various ways.  The
> major mode author is not supposed to play around with
> imenu--index-alist directly.  But is taking a look at
> imenu--index-alist not useful for the author to check his work?
> Also could knowing about the alist he is trying to construct with
> the other functions not be useful in understanding those other
> functions?  (Assuming my above interpretation of the facts is
> correct).

The author could just check the return value of the
imenu-create-index-function function that (s)he is writing.  Note that
I do describe this return value in detail.  I also mention that the
two other ways of setting up Imenu work through
imenu-create-index-function's default function.  I think that knowing
the name of the variable in which Imenu stores the return value is
only important when hacking on Imenu itself.

> I saw you removed the documentation for the variable.  If you really
> think it ought to be removed, then that is OK.

Yes, I do.

> I am not necessarily contesting that removal.  You know the node
> better than I do.  I just took a quick look at it.  However, as a
> solution to the double dash problem, removal seems a little bit too
> radical.

Getting rid of that problem is a nice by-product.  :-)

> I believe the following works in all situations, main text and index
> of both Info and printed output:
>
> @defvar address@hidden
>
> OK this is ugly, but you could mention in the Texinfo source in a
> comment that the ugliness is a work-around for a bug in Texinfo.
> The @- allows for a discretionary hyphen, but the text is short, so
> no problem.  The braces around the entire name prevent the Info
> index from just listing `imenu-'.  This will work even if the user
> does not have makeinfo 4.7 or higher.  The current problems in Info
> need to be fixed, but any such fix will require the user to install
> make-info version 4.7 or higher.

Indeed, that seems to work well.  Thanks for the tip.

> (I believe 4.6 is still the latest released version.)

Yes.


  Lute.




reply via email to

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