hush/shell/hush_test/hush-vars/var_unbackslash.tests
Denys Vlasenko 101a4e3e21 hush: make parse_dollar flag quited status regardless of glob escaping status
function                                             old     new   delta
parse_stream_dquoted                                 228     233      +5
parse_stream                                        2369    2371      +2
parse_dollar                                         730     717     -13
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/1 up/down: 7/-13)              Total: -6 bytes

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
2010-09-09 14:04:57 +02:00

24 lines
316 B
Plaintext
Executable File

# Test for correct handling of backslashes
a=qwerty
b=-$a-\t-\\-\"-\`-\--\z-\*-\?-
echo b1=$b
echo "b1=$b"
b="-$a-\t-\\-\"-\`-\--\z-\*-\?-"
echo b2=$b
echo "b2=$b"
b='-$a-\t-\\-\"-\`-\--\z-\*-\?-'
echo b3=$b
echo "b3=$b"
c=$b
echo "c=$c"
c=${b}
echo "c=$c"
c="$b"
echo "c=$c"
c="${b}"
echo "c=$c"
echo "Done: $?"