emacs-devel
[Top][All Lists]
Advanced

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

Re: new apropos feature in Emacs-22


From: Luc Teirlinck
Subject: Re: new apropos feature in Emacs-22
Date: Sat, 5 Nov 2005 11:39:53 -0600 (CST)

Eli Zaretskii wrote:

   > Nothing in that discussion changes the fact that:
   > 
   >    (string-equal (regexp-quote regexp) regexp)
   > 
   > is just a horrible way to distinguish a regexp from a list of keywords.

   Please don't get angry with me:

I was not angry and did not intend to sound angry.  I am sorry if
something in the above quote gave the impression I was.

   I was only trying to say that the
   seemingly arbitrary rule of "at least two matching keywords" might
   have some valid reasons which are spelled out in the discussions.

My _main_ objection was the confused semantics.  I just thought that
it might be possible to fix the semantics while at the same time
giving the user more flexibility, but this was secondary.

   I think these problems were raised and discussed back then, but I
   might be wrong.

I read through the entire thread and could not find it.  The danger of
misinterpreting an intended regexp as a list of keywords was
mentioned, but not the opposite danger of misinterpreting a list of
keywords as a regexp.  This danger can occur even if a single keyword
is specified, say .emacs, *scratch* , ses+.  Unless something is done
to avert that problem, then at least that problem should be mentioned
clearly in `(emacs)Apropos' (and in the docstrings).  The only mention
of regexps in `(emacs)Apropos' is:

    For even greater flexibility, you can also supply a regular expression
    to Apropos (*note Regexps::).

It does not explicitly mention that this "greater flexibility" means
that you can not use certain characters in your keywords.  It does
also not give any tips on how to make sure that an intended regexp
really gets interpreted by Emacs as a regexp.

Sincerely,

Luc.





reply via email to

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