aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--vimrc7
1 files changed, 3 insertions, 4 deletions
diff --git a/vimrc b/vimrc
index a18f33f..afeb53c 100644
--- a/vimrc
+++ b/vimrc
@@ -332,14 +332,13 @@ function Textobj_regex(inner, count)
let lines = getline(1, pos[1] - 1) + [line]
let linenum = pos[1]
for line in reverse(lines)
- let objstart = match(line, '.*\zs\\\@<!/')
- if objstart != -1
- let objstart += 1
+ let objstart = match(line, '.*\zs\\\@<!/') + 1
+ if objstart != 0
break
endif
let linenum -= 1
endfor
- if objstart == -1
+ if objstart == 0
throw 'no-match'
endif
let objstart += a:inner