GNU bug report logs - #14742
24.3.50; enhancement request: be able to prepend stuff from buffer when search backward

Previous Next

Package: emacs;

Reported by: Drew Adams <drew.adams <at> oracle.com>

Date: Fri, 28 Jun 2013 18:19:01 UTC

Severity: wishlist

Found in version 24.3.50

Full log


Message #56 received at 14742 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: Juri Linkov <juri <at> jurta.org>
Cc: 14742 <at> debbugs.gnu.org, Drew Adams <drew.adams <at> oracle.com>
Subject: Re: bug#14742: 24.3.50;
 enhancement request: be able to prepend stuff from buffer when search
 backward
Date: Fri, 05 Jul 2013 20:40:30 -0400
> then code for `isearch-allow-scroll' should be moved to a separate
> function like `isearch-handle-scroll-function' too.

That would be nice, as well, yes.

> But still I don't understand how this would be possible to handle
> outside of `isearch-other-meta-char', because this code changes the
> local variables `key', `keylist', `main-event', `move-command'
> locally bound in `isearch-other-meta-char'.

AFAICT, `move-command' is not used by the rest of the code, so `setq'ing
it is not needed.  For the other three, I guess you could do something
like

   +       ((let ((hmf (isearch-handle-motion-function <blabla>)))
   +          (when hmf (setq key (nth 0 hmf))
   +                    (setq keylist (nth 1 hmf))
   +                    (setq main-event (nth 2 hmf))
   +                    (nth 3 hmf))))

It's not super elegant, but the reason is the messed up data-flow, so at
least this formulation makes the mes more clear and self-evident.
Hopefully someone will find a way to clean it up at some point.


        Stefan





This bug report was last modified 4 years and 265 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.