diff --git a/plugin/singlechar.vim b/plugin/singlechar.vim index 896a25d..76d8b2f 100644 --- a/plugin/singlechar.vim +++ b/plugin/singlechar.vim @@ -72,7 +72,9 @@ def InsertChar(mode: string, count: number, pkey: string = ''): void g:last_singlechar_count = count #set vim-repeat - legacy call repeat#set("\(singlechar-repeat)") + if exists('*repeat#set') + legacy call repeat#set("\(singlechar-repeat)") + endif enddef def g:RepeatSingleChar(): void