xref: /freebsd/bin/sh/tests/expansion/cmdsubst13.0 (revision a64729f5077d77e13b9497cb33ecb3c82e606ee8)
1
2x=1 y=2
3[ "$(
4	case $((x+=1)) in
5	($((y+=1)))	echo bad1 ;;
6	($((y-1)))	echo $x.$y ;;
7	($((y=2)))	echo bad2 ;;
8	(*)		echo bad3 ;;
9	esac
10)" = "2.3" ] || echo "Error at $LINENO"
11[ "$x.$y" = "1.2" ] || echo "Error at $LINENO"
12