Subject: bug#19032: bug#43120: 28.0.50; fido-mode: M-j before completions appear selects wrong choice

From: João Távora <[email-masked]>
Date: Wed, 9 Sep 2020 17:11:43 +0100

On Wed, Sep 9, 2020 at 3:01 PM OGAWA Hirofumi <[email-masked]>
wrote:

> João Távora <[email-masked]> writes:
>
> > Stefan Monnier <[email-masked]> writes:
> >
> >>> I think something like this is the way to go for a behaviour change
> such
> >>> as this.
> >>
> >> Looks fine to me.
> >
> > Thanks, pushed.
> >
> >>> +    (define-key map (kbd "RET") 'icomplete-ret)
> >>
> >> Maybe use a `remap`ping instead?
> >
> > I did that, too.
>
> > +(defun icomplete-ret ()
> > +  "Exit minibuffer for icomplete."
> > +  (interactive)
> > +  (if (and icomplete-show-matches-on-no-input
> > +           (car completion-all-sorted-completions)
> > +           (eql (icomplete--field-end) (icomplete--field-beg)))
> > +      (icomplete-force-complete-and-exit)
> > +    (exit-minibuffer)))
>
> This changed the behavior of RET from `minibuffer-complete-and-exit' to
> `exit-minibuffer'. Was that intention?
>

Nope, sorry. You're right. It should read minibuffer-complete-and-exit there
of course.

João