hush: fix "$v" expansion in case patterns when v='[a]'

function                                             old     new   delta
run_list                                            1053    1063     +10
setup_redirects                                      311     320      +9
encode_then_expand_string                            135     142      +7
run_pipe                                            1784    1789      +5
expand_assignments                                    81      86      +5
expand_string_to_string                              124     125      +1
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 6/0 up/down: 37/0)               Total: 37 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2018-04-11 13:47:59 +02:00
parent 680c3016a2
commit 34179956f9
5 changed files with 52 additions and 16 deletions

View File

@@ -0,0 +1 @@
s

View File

@@ -0,0 +1,8 @@
g='[3](a)(b)(c)'
s='[3](a)(b)(c)'
case $g in
"$s") echo s
;;
*) echo "*"
;;
esac