<<< Date Index >>>     <<< Thread Index >>>

Re: [PATCHES] Re: We need unbind function (was Re: [PATCHES] awaiting...)



On Fri, May 28, 2004 at 01:10:59AM -0400, David Yitzchak Cohen wrote:
> On Wed, May 26, 2004 at 10:32:39PM EDT, TAKAHASHI Tamotsu wrote:
> > On Wed, May 26, 2004 at 11:17:05PM +0200, Alain Bench wrote:
<snip>
> > >     I see #1880 as a misunderstanding of the intended and documented
> > > behaviour, not as a bug. I would have closed it, but am surprised you
> > > are 3 to think the contrary (Pawel, you, and Dave). So I hesitate.
> > 
> > Reading your post, I finally realize that the problem is just
> > "the word <unbind> is unclear." I don't think I misunderstood
> > the document. But I might have misunderstood the intended behaviour.
> 
> The word "unbind" is not unclear by any stretch of the imagination,
> AFAICT.  If "binding" creates a binding in Mutt's tables, "unbinding"
> should toss the binding out of Mutt's tables, not clobber it with some
> other binding that happens to do nothing.  Put another way, an "unbind"
> operation should exactly undo a "bind" operation.
> 
> IMHO, the current behavior of "bind noop" makes more sense than the
> documented behavior, since it's really _not_ a special case at all,
> and the behavior is quite useful :-)

Yes! That's what I wanted to say.


> However, an "unbind" operation that exactly undoes a "bind" operation
> should really exist, IMHO.
<snip>
> > Here is one more patch, which implements "bind map key generic."
> 
> Nooooooooooo :-(

Aha, then, how about "bind map key blank"
or "bind map key clear"? :)

        perl -p -i -e 's/generic/blank/g' mypatch
        perl -p -i -e 's/generic/clear/g' mypatch
        perl -p -i -e 's/generic/undo/g' mypatch
        perl -p -i -e 's/generic/unbind/g' mypatch
        ....

If they doesn't satisfy you, shall I write a patch
to make a function "unbind" which simply does the same
as "bind key map generic"?
(I suppose Thomas Roessler won't accept it, though.)

It is too hard for me to really remove the bindings
from binding tables.
So I think dgc's "unbind index *" is sufficient.
We have "source" command.

-- 
tamo