lineedit: trivial codeshrink for vi-mode
authorNatanael Copa <ncopa@alpinelinux.org>
Sun, 14 Aug 2016 21:30:29 +0000 (23:30 +0200)
committerDenys Vlasenko <vda.linux@googlemail.com>
Sun, 14 Aug 2016 21:30:29 +0000 (23:30 +0200)
commit7e6f9316a8bf3030da6c283e43aa0709d0cef259
treeec5f4ba877f846b6fff854e2af8507d734edb98b
parent9e5820a86277818c2f83c11c2aa76d7f0a38283e
lineedit: trivial codeshrink for vi-mode

Introduce and use BB_isalnum_or_underscore().

function                                             old     new   delta
BB_isalnum_or_underscore                               -      43     +43
vi_word_motion                                       162     150     -12
vi_end_motion                                        163     145     -18
vi_back_motion                                       198     179     -19
BB_isalnum                                            39       -     -39
------------------------------------------------------------------------------
(add/remove: 1/1 grow/shrink: 0/3 up/down: 43/-88)            Total: -45 bytes

Signed-off-by: Natanael Copa <ncopa@alpinelinux.org>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
libbb/lineedit.c