From b77c5f11070ecb2ff343aa18b4ea859e6168f16c Mon Sep 17 00:00:00 2001 From: Adam Stankiewicz Date: Thu, 17 Feb 2022 04:31:35 +0100 Subject: Update --- autoload/unison.vim | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'autoload/unison.vim') diff --git a/autoload/unison.vim b/autoload/unison.vim index cdc2efe5..e91699f0 100644 --- a/autoload/unison.vim +++ b/autoload/unison.vim @@ -56,7 +56,17 @@ function! unison#Complete(findstart, base) abort " locate the start of the word let line = getline('.') let start = col('.') - 1 - while start > 0 && line[start - 1] !~ '\s' && line[start - 1] != '(' && line[start - 1] != ')' + " Examples of where we want to count the start of a word: + " + " foo List.fold + " ^ + " + " {Abor + " ^ + " + " (List.fol + " ^ + while start > 0 && line[start - 1] !~ '\v\s|[(){}\[\]]' let start -= 1 endwhile return start -- cgit v1.2.3