Skip to content

Commit 9e79585

Browse files
John Marriottchrisbra
authored andcommitted
patch 9.1.0685: too many strlen() calls in usercmd.c
Problem: too many strlen() calls in usercmd.c Solution: refactor code to reduce the number or strlen() calls (John Marriott) closes: #15516 Signed-off-by: John Marriott <basilisk@internode.on.net> Signed-off-by: Christian Brabandt <cb@256bit.org>
1 parent e44e644 commit 9e79585

3 files changed

Lines changed: 304 additions & 213 deletions

File tree

src/testdir/test_usercommands.vim

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,10 @@ function Test_cmdmods()
133133
\ 'silent verbose aboveleft belowright botright tab topleft vertical',
134134
\ g:mods)
135135

136+
kee keep keepm keepma keepmar keepmarks keepa keepalt keepj keepjumps
137+
\ keepp keeppatterns MyCmd
138+
call assert_equal('keepalt keepjumps keepmarks keeppatterns', g:mods)
139+
136140
let g:mods = ''
137141
command! -nargs=* MyQCmd let g:mods .= '<q-mods> '
138142

0 commit comments

Comments
 (0)