Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Print "Verifying the contents again";
- .
- .
- .
- Print "Verifying the output to be shown"; // line 2
- set completefunc=CompleteInsideSymbols
- function! CompleteInsideSymbols(findstart, base) abort
- if a:findstart
- let start = col('.') - 1
- let line = getline('.')
- while start > 0 && line[start - 1] !~ "["'[]"
- let start -= 1
- endwhile
- return start
- else
- let groups_of_words = []
- %s/v("zs.{-}ze"|'zs.{-}ze'|[zs.{-}ze])/=add(groups_of_words,submatch(0))/gn
- return filter(groups_of_words, 'v:val =~ "^" . a:base')
- endif
- endfunction
- if a:findstart
- ...
- else
- ...
- endif
- let start = col('.') - 1
- let line = getline('.')
- while start > 0 && line[start - 1] !~ "["'[]"
- let start -= 1
- endwhile
- return start
- let groups_of_words = []
- %s/v("zs.{-}ze"|'zs.{-}ze'|[zs.{-}ze])/=add(groups_of_words,submatch(0))/gn
- return filter(groups_of_words, 'v:val =~ "^" . a:base')
- here is " a group of quoted words " and here is " another one "
- " an
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement