ash: add test for issue with here document
This used to work but doesn't now: foo () { cat <<EOF && { echo "$1" ; } $1 EOF } foo "bar" Reported-by: Natanael Copa <ncopa@alpinelinux.org> Signed-off-by: Ron Yorston <rmy@pobox.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
4c8576fea1
commit
9121510dc6
2
shell/ash_test/ash-heredoc/heredoc2.right
Normal file
2
shell/ash_test/ash-heredoc/heredoc2.right
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
bar
|
||||||
|
bar
|
7
shell/ash_test/ash-heredoc/heredoc2.tests
Executable file
7
shell/ash_test/ash-heredoc/heredoc2.tests
Executable file
@ -0,0 +1,7 @@
|
|||||||
|
foo () {
|
||||||
|
cat <<EOF && { echo "$1" ; }
|
||||||
|
$1
|
||||||
|
EOF
|
||||||
|
}
|
||||||
|
|
||||||
|
foo "bar"
|
Loading…
x
Reference in New Issue
Block a user