xref: /freebsd/bin/sh/tests/parser/heredoc8.0 (revision 27c43fe1f3795622c5bd4bbfc465a29a800c0799)
1# $FreeBSD$
2
3failures=0
4
5check() {
6	if ! eval "[ $* ]"; then
7		echo "Failed: $*"
8		: $((failures += 1))
9	fi
10}
11
12s='ast*que?non' sq=\' dq=\"
13
14# This is possibly useful but differs from other shells.
15check '"$(cat <<EOF
16${s+"x"}
17EOF
18)" = ${dq}x${dq}'
19
20exit $((failures != 0))
21