Permalink
Browse files

Remove support for snipmate.

  • Loading branch information...
1 parent 68b0691 commit 557e986d3a32145143416ea4319318596d675c00 @Rip-Rip committed Mar 4, 2013
Showing with 3 additions and 53 deletions.
  1. +0 −50 autoload/snippets/snipmate.vim
  2. +3 −3 doc/clang_complete.txt
@@ -1,50 +0,0 @@
-" clang_complete snipmate's snippet generator
-" Author: Philippe Vaucher
-
-function! snippets#snipmate#init()
- call snippets#snipmate#reset()
-endfunction
-
-" fullname = strcat(char *dest, const char *src)
-" args_pos = [ [8, 17], [20, 34] ]
-function! snippets#snipmate#add_snippet(fullname, args_pos)
- " If we are already in a snipmate snippet, well not much we can do until snipmate supports nested snippets
- if exists('g:snipPos')
- return a:fullname
- endif
-
- let l:snip = ''
- let l:prev_idx = 0
- let l:snip_idx = 1
- for elt in a:args_pos
- let l:snip .= a:fullname[l:prev_idx : elt[0] - 1] . '${' . l:snip_idx . ':' . a:fullname[elt[0] : elt[1] - 1] . '}'
- let l:snip_idx += 1
- let l:prev_idx = elt[1]
- endfor
-
- let l:snip .= a:fullname[l:prev_idx : ] . '${' . l:snip_idx . '}'
-
- let l:snippet_id = substitute(a:fullname, ' ', '_', 'g')
-
- call MakeSnip(&filetype, l:snippet_id, l:snip)
-
- return l:snippet_id
-endfunction
-
-function! snippets#snipmate#trigger()
- " If we are already in a snipmate snippet, well not much we can do until snipmate supports nested snippets
- if exists('g:snipPos')
- return
- endif
-
- " Trigger snipmate
- call feedkeys("\<Tab>", 't')
-endfunction
-
-function! snippets#snipmate#reset()
- " Quick & Easy way to prevent snippets to be added twice
- " Ideally we should modify snipmate to be smarter about this
- call ReloadSnippets(&filetype)
-endfunction
-
-" vim: set ts=2 sts=2 sw=2 expandtab :
View
@@ -114,7 +114,7 @@ Default: 0
*clang_complete-snippets_engine*
*g:clang_snippets_engine*
-The snippets engine (clang_complete, snipmate, ultisnips... see the snippets
+The snippets engine (clang_complete, ultisnips... see the snippets
subdirectory).
Default: "clang_complete"
@@ -325,10 +325,10 @@ for example:
let g:clang_snippets = 1
let g:clang_snippets_engine = 'clang_complete'
-If you have snipmate installed, you can use
+If you have ultisnips installed, you can use
let g:clang_snippets = 1
-let g:clang_snippets_engine = 'snipmate'
+let g:clang_snippets_engine = 'ultisnips'
instead. After a completetion you can use <Tab> in normal mode to jump to the
next parameter.

0 comments on commit 557e986

Please sign in to comment.