garbas / vim-snipmate

snipMate.vim aims to be a concise vim script that implements some of TextMate's snippets features in Vim.
www.vim.org/scripts/script.php?script_id=2540
2.01k stars 181 forks source link

Not working with Go language #267

Closed arcseldon closed 6 years ago

arcseldon commented 6 years ago

Whenever I press tab, or use a known snippet shortcut in a Go file, I receive the following message:

Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E716: Key not present in Dictionary: get_snippets
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E116: Invalid arguments for function funcref#Call
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E116: Invalid arguments for function items
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E15: Invalid expression: items(funcref#Call(g:snipMate['get_snippets'], [snipMate#ScopesByFile(), word]))
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E716: Key not present in Dictionary: get_snippets
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E116: Invalid arguments for function funcref#Call
Error detected while processing function snipMate#TriggerSnippet[35]..snipMate#GetSnippetsForWordBelowCursor:
line   31:
E116: Invalid arguments for function items

Am using neovim, on MacBook Pro. Snippets work great for other languages such as JavaScript, Elixir etc. But Go language, always receive the above.

Any thoughts?

arcseldon commented 6 years ago

Sorry, this is now working after installing some Go tools and restarting VIM...