0

I installed neocomplcache for vim in both my computer, macbook air and Linux ubuntu 11.10 I use macVim on macbook air, but I use console vim on ubuntu.

First,I copied the sample code to the .vimrc of macVIm. And it works for my macbook and no errors occurs.

After that,I copied the code to the .vimrc of console vim. When I try to run vim on terminal every time. It tolds me that the following sentence is wrong expression.

let g:neocomplcache_dictionary_filetype_lists = {\ 'default' : '',
        \ 'vimshell' : $HOME.'/.vimshell_hist',
            \ 'scheme' : $HOME.'/.gosh_completions'
              \ }

Although I cannot see any negative effects on the function of this plugin,(I use java completion) what wrong it is going on??

Ingo Karkat
  • 167,457
  • 16
  • 250
  • 324
code4j
  • 4,208
  • 5
  • 34
  • 51

1 Answers1

2

Seems like it is missing a line break before the \ in s = {\ '. This can be caused by different newline delimiters (CR vs. LF).

Ingo Karkat
  • 167,457
  • 16
  • 250
  • 324
  • It's a question long time ago, I really appreciate you that you have found this post and replied it. I tried your suggestion and joined those lines. But the gVim still said that they are invalid expression. In my point of view, the reason behind that is I am missing the file `/.vimshell_hist` and `/.gosh_completions` – code4j Nov 07 '12 at 15:36
  • When you joined the lines, have you removed the leading backslash characters? An _invalid expression_ cannot be caused by missing files, Vim doesn't even recognize then and there that files are involved. – Ingo Karkat Nov 07 '12 at 15:38
  • wow you comment is just a minute after my comment. thanks for your remind, I didn't remove those leading \ characters. And I have remove them right now and no any errors:) . I would like to ask what is the actual meaning of \ ?? – code4j Nov 07 '12 at 15:45
  • 1
    Glad that one got finally fixed! The backslash is Vim syntax for breaking an expression over multiple lines. See `:help line-continuation`. – Ingo Karkat Nov 07 '12 at 15:49