1 2 3 4 5 6 7 8
# $FreeBSD: releng/12.0/bin/sh/tests/builtins/for3.0 230463 2012-01-22 14:00:33Z jilles $ r=x f() { return 42; } for i in x`f`; do r=$? done [ "$r" = 42 ]