hush: fix a bug where we don't properly handle f() { a=A; b=B; }; a= f
authorDenys Vlasenko <vda.linux@googlemail.com>
Wed, 4 Apr 2018 22:51:55 +0000 (00:51 +0200)
committerDenys Vlasenko <vda.linux@googlemail.com>
Wed, 4 Apr 2018 22:51:55 +0000 (00:51 +0200)
commitd358b0b65dae83d52e511a126757e2aa7b1881b2
tree6ff6f7c14a399c0e5ff659b69080822a0e84cc83
parent332e4115c978094b3630cde62a7154a4fcd564d8
hush: fix a bug where we don't properly handle f() { a=A; b=B; }; a= f

function                                             old     new   delta
unset_local_var                                       20     274    +254
leave_var_nest_level                                   -      98     +98
set_vars_and_save_old                                128     164     +36
enter_var_nest_level                                   -      32     +32
builtin_local                                         46      50      +4
pseudo_exec_argv                                     554     544     -10
redirect_and_varexp_helper                            77      64     -13
run_pipe                                            1890    1641    -249
unset_local_var_len                                  267       -    -267
------------------------------------------------------------------------------
(add/remove: 2/1 grow/shrink: 3/3 up/down: 424/-539)         Total: -115 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
shell/hush.c
shell/hush_test/hush-vars/var_nested1.right [new file with mode: 0644]
shell/hush_test/hush-vars/var_nested1.tests [new file with mode: 0755]
shell/hush_test/hush-vars/var_nested2.right [new file with mode: 0644]
shell/hush_test/hush-vars/var_nested2.tests [new file with mode: 0755]