使用自动完成字典如果Vim冻结,以及当前文件 [英] Vim freezes when using auto-complete with dictionary as well as current file

查看:166
本文介绍了使用自动完成字典如果Vim冻结,以及当前文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

正如这里讨论:<一href=\"http://stackoverflow.com/questions/20887628/vim-auto-complete-both-with-current-file-and-dictionary\">Vim自动完成,都与当前文件和字典,
我试图同时使用词典和当前文件中自动完成时确定的建议。
在我的vimrc我有以下两行自动完成:

As was discussed here: Vim auto complete, both with current file and dictionary, I am trying to use both dictionary and current file in determining suggestions during auto-complete. In my vimrc I have the following two lines for auto-complete:

set complete=k,.
set dictionary+=pathfile-to-dictionary

但是当我preSS自动完成按钮,我得到错误:

But then when I press the auto-complete button I get error:

match in file the-dictionary-pathfile

和系统与错误完全冻结,我不得​​不关闭控制台,并重新开始要回我在那里。
我试图改变权限设置,字典文件为777,我试图把字典文件中的主目录。同样的错误。

And the system completely freezes with that error, i have to close the console and start over to get back to where I was. I've tried changing right settings to the dictionary file to 777 and I have tried putting dictionary file in home directory. Same error.

我也注意到了错误弹出时,我无论在字典中,并在当前文件中有一个词,然后尝试自动完成了这个词。因此,它可能是某种这两个之间的碰撞。

I have also noticed that the error pops up whenever I have a word both in dictionary and in current file and then try to auto-complete that very word. So it's probably some sort of collision between those two.

我怎么能同时使用词典和当前的文件进行文字完成?

How can I use both dictionary and current file for word completion?

推荐答案

我道歉:我问的更多信​​息,但不尝试重现该问题。我觉得你说得对具有相同的话,或者至少是可能的匹配,在这两个地方。

I apologize: I asked for more information without trying to reproduce the problem. I think you are right about having the same words, or at least possible matches, in both places.

它看起来像一个错误。我发现,&LT; C-C&GT; 一次或两次,让我出去;我没有做出什么过激举动。

It does look like a bug. I find that <C-C> once or twice gets me out; I do not have to do anything drastic.

我发现,问题消失,如果我颠倒了顺序:

I find that the problem goes away if I reverse the order:

:set complete=.,k

这篇关于使用自动完成字典如果Vim冻结,以及当前文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆