[Top][All Lists]

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

Re: should search ring contain duplicates?

From: Juri Linkov
Subject: Re: should search ring contain duplicates?
Date: Thu, 11 May 2006 01:55:47 +0300
User-agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux)

>>> Below is a tested patch that removes `keep-all' from `read-from-minibuffer',
> Did you test that with your changes, it still fixes the original problem
> which was the reason for the original change?
> http://lists.gnu.org/archive/html/emacs-pretest-bug/2004-11/msg00287.html

I tested it with all test cases from this thread, but that was before
adding add-to-history to CVS.

> But pls. consider using add-to-history instead of explicitly testing
> for history-delete-duplicates.

To use add-to-history there should be a way to tell read-from-minibuffer
not to add new elements to the history list, so add-to-history could
undertake this task itself later.  nil as the `hist' argument of
read-from-minibuffer doesn't count because the history list should be
available for M-p.

> BTW, add-to-history should probably be fixed to _not_ add an element
> which is already at the head of the history.

Then it becomes a complete duplicate of C code.  Isn't then better
to call the Lisp function add-to-history from the C implementation of

Juri Linkov

reply via email to

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