Lech Lorens wrote:
> On 20-Oct-2010 Xavier Deguillard <[email protected]> wrote:
> > On Wed, Oct 20, 2010 at 09:04:22PM +0200, Lech Lorens wrote:
> > > On 20-Oct-2010 Lech Lorens <[email protected]> wrote:
> > > > OK, I can reproduce the crash. Do the following (vim-crash.vim
> > > > attached):
> > > >
> > > > $ vim -u NONE -S vim-crash.vim
> > >
> > > Here's a patch fixing the problem and adding a proper test.
> > >
> >
> > Thanks a lot!
> >
> > I was trying to debug it when I saw your patch, and indeed, it's
> > working as excepted now :)
>
> I was too fast. We still have a problem (I get a segmentation fault):
> - if the completion function opens a new tab,
> - if the completion function closes the current window.
>
> Fixing the former problem seems trivial, but I'm not sure how the latter
> should be dealt with. Should we prevent the buffer from being closed?
> Should we discard the completion data if the buffer for which the
> completion was done becomes unavailable?
I would say that a completion function is not allowed to open or close
windows. It probably also should not be allowed to open/close buffers.
On the other hand, perhaps the completion would like to look in another
file, and temporary opening a window for that could be useful. It might
be difficult to allow this while disallowing to touch the window and
buffer where the completion is happening.
--
PRINCE: He's come to rescue me, father.
LAUNCELOT: (embarrassed) Well, let's not jump to conclusions ...
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php