emacs-devel
[Top][All Lists]
Advanced

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

Re: should search ring contain duplicates?


From: Kim F. Storm
Subject: Re: should search ring contain duplicates?
Date: Thu, 04 May 2006 23:55:28 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

"Stuart D. Herring" <address@hidden> writes:

> (defun isearch-update-ring (string &optional regexp)
>   "Add STRING to the beginning of the search ring.
> REGEXP says which ring to use."
>   (history-push string
>                 (if regexp 'regexp-search-ring 'search-ring)
>                 (if regexp regexp-search-ring-max search-ring-max)))

What a piece of art!  Thanks!

It shows exactly why add-to-history is the rigth way to go.

And fixes the bug in isearch-update-ring too !

-- 
Kim F. Storm <address@hidden> http://www.cua.dk





reply via email to

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