bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#9160: 24.0.50; Emacs freezes in *shell* buffer.


From: Kenichi Handa
Subject: bug#9160: 24.0.50; Emacs freezes in *shell* buffer.
Date: Tue, 20 Sep 2011 14:16:27 +0900

In article <address@hidden>, Stefan Monnier <address@hidden> writes:

> That's a known (to me) bug.
> Making escaping (aka quoting) interact correctly with completion styles
> like partial-completion and substring is actually a nasty problem.
> The old code used to escape the strings returned by all-completions (so
> the *Completions* buffer would show the escaped names), which solves
> some of the problematic cases, but has the following downsides:
> - it's aesthetically unpleasant (the *Completions* buffer does not need
>   that kind of escaping).
> - it's inefficient (requires escaping all elements of all-completions).
> - more problematic: it doesn't actually solve the problem in all cases,
>   because the user may have typed "a\bc" but the escaping code cannot
>   know that the user decided to (unnecessarily) escape "b" so it won't
>   escape "b" and we're back at the problem that the completion will fail
>   because the output from all-completions doesn't actually match the
>   user's input, even tho it should.
> We have related problems with $ escaping in find-file (they manifest in
> different ways because we half-solved the issues differently).

> I'm still not quite sure yet how to best solve those problems, but it
> seems that a real solution will have to handle a more general problem,
> e.g. cases such as "/u-$b-c" in find-file, where "$b" is an env var that
> expands to (say) "c/d".

I agree that there are many problems behind.  But, my
testcase is a fairly simple one.  Even if we can't solve all
the related problem at the moment, I think there should be
some workaround for such a simple case as far as it's a
regression.  For instance, is it difficult to escape all
necessary characters on inserting a clicked item into
*shell* buffer?

> > (2) The second arg to rm command is not completed.
> > % mkdir tmp
> > % cd tmp
> > % touch abc def
> > % rm a<tab>
> > % rm abc d<tab>
> > Now just "No match" is shown instead of "d" completed to
> > "def".  This DOES NOT happen with 'ls' command.

> I think I just fixed it with the patch below.

I confirmed that it's fixed, thank you.

> > (3) Error in post-command-hook for *.tar.gz file.
> > % mkdir tmp
> > % cd tmp
> > % echo abc > abc
> > % echo def > def
> > % tar cfz temp.tar.gz abc def
> > % tar tfz temp<tab>
> > Now the command line is correctly completed to:
> > % tar tfz temp.tar.gz 
> > But, this error is signaled:
> > Error in post-command-hook (completion-in-region--postch):
> > (wrong-type-argument listp [tar-header #<marker at 513 in  *tar-data
> > temp.tar.gz*> abc 436 8308 8308 4 (20069 47563) 4380 nil  ustar  handa handa
> > 0 0 nil])

> I cannot reproduce this error.  Has it been fixed in the mean time?

No.  I still see that error with the above testcase.

---
Kenichi Handa
address@hidden





reply via email to

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