File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
autoload/vital/__vital__/Text Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ function! s:obj.exec(string) dict abort
3737 for tkn in self .tokens
3838 let matched_text = matchstr (a: string [(idx):],' ^' . tkn.regex)
3939 if ! empty (matched_text)
40- let best_tkn = s: token (tkn.label ,matched_text,idx)
40+ let best_tkn = s: _token (tkn.label ,matched_text,idx)
4141 break
4242 endif
4343 endfor
@@ -59,14 +59,15 @@ function! s:lexer(patterns) abort
5959 return obj
6060endfunction
6161
62- function ! s: token (label ,matched_text,col ) abort
62+ function ! s: _token (label ,matched_text,col ) abort
6363 let obj = {}
6464 let obj[' label' ] = a: label
6565 let obj[' matched_text' ] = a: matched_text
6666 let obj[' col' ] = a: col
6767 return obj
6868endfunction
6969
70+ " Deprecated
7071function ! s: simple_parser (expr ) abort
7172 echoerr ' vital: Text.Lexer: simple_parser(expr) is obsolete. Use Text.Parser.parser() instead.'
7273 let obj = { ' expr' : a: expr , ' idx' : 0 , ' tokens' : [] }
You can’t perform that action at this time.
0 commit comments