Home
last modified time | relevance | path

Searched refs:byteidx (Results 1 – 12 of 12) sorted by relevance

/vim-8.2.3635/src/
H A Dstrings.c813 byteidx(typval_T *argvars, typval_T *rettv, int comp UNUSED) in byteidx() function
850 byteidx(argvars, rettv, FALSE); in f_byteidx()
859 byteidx(argvars, rettv, TRUE); in f_byteidxcomp()
1026 int byteidx = 0; in f_strgetchar() local
1043 while (charidx >= 0 && byteidx < len) in f_strgetchar()
1047 rettv->vval.v_number = mb_ptr2char(str + byteidx); in f_strgetchar()
1051 byteidx += MB_CPTR2LEN(str + byteidx); in f_strgetchar()
H A Deval.c5161 buf_byteidx_to_charidx(buf_T *buf, int lnum, int byteidx) in buf_byteidx_to_charidx() argument
5182 for (count = 0; *t != NUL && t <= str + byteidx; count++) in buf_byteidx_to_charidx()
5188 if (*t == NUL && byteidx != 0 && t == str + byteidx) in buf_byteidx_to_charidx()
/vim-8.2.3635/src/testdir/
H A Dtest_functions.vim1196 " Test for byteidx() and byteidxcomp() functions
1199 call assert_equal(0, byteidx(a, 0))
1201 call assert_equal(1, byteidx(a, 1))
1203 call assert_equal(3, byteidx(a, 2))
1205 call assert_equal(4, byteidx(a, 3))
1207 call assert_equal(-1, byteidx(a, 4))
1211 call assert_equal(0, b->byteidx(0))
1212 call assert_equal(1, b->byteidx(1))
1213 call assert_equal(4, b->byteidx(2))
1214 call assert_equal(5, b->byteidx(3))
[all …]
H A Dtest_vim9_builtin.vim390 …CheckDefAndScriptFailure2(['byteidx(1, 2)'], 'E1013: Argument 1: type mismatch, expected string bu…
391 …CheckDefAndScriptFailure2(['byteidx("a", "b")'], 'E1013: Argument 2: type mismatch, expected numbe…
392 byteidx('', 0)->assert_equal(0)
393 byteidx('', 1)->assert_equal(-1)
H A Dtest_vim9_expr.vim3070 RetVoid()->byteidx(3)
/vim-8.2.3635/src/proto/
H A Deval.pro58 int buf_byteidx_to_charidx(buf_T *buf, int lnum, int byteidx);
/vim-8.2.3635/runtime/doc/
H A Deval.txt2538 byteidx({expr}, {nr}) Number byte index of {nr}'th char in {expr}
3622 byteidx({expr}, {nr}) *byteidx()*
3633 echo matchstr(str, ".", byteidx(str, 3))
3636 let s = strpart(str, byteidx(str, 3))
3637 echo strpart(s, 0, byteidx(s, 1))
3645 GetName()->byteidx(idx)
3648 Like byteidx(), except that a composing character is counted
3651 echo byteidx(s, 1)
3657 Only works differently from byteidx() when 'encoding' is set
3764 See |byteidx()| and |byteidxcomp()| for getting the byte index
[all …]
H A Dusr_41.txt637 byteidx() byte index of a character in a string
638 byteidxcomp() like byteidx() but count composing characters
H A Dtags5621 byteidx() eval.txt /*byteidx()*
H A Dversion7.txt849 |byteidx()| index of a character (Ilya Sher)
H A Dversion8.txt263 |byteidxcomp()| like byteidx() but count composing characters
823 Problem: byteidx() does not work for composing characters.
/vim-8.2.3635/runtime/syntax/
H A Dvim.vim81 syn keyword vimFuncName contained abs argc assert_equal assert_match atan browse bufloaded byteidx