for i in bash mksh; do
echo $i:
$i <<'!'
set 'a b' 'c d'
quoted="$@"
unquoted=$@
echo "$quoted"
echo "$unquoted"
!
done
here bash treats unquoted $@ on rhs differently, expanding it like $*:
Unquoted $@ *is* the same as $*.
--
Chris F.A. Johnson, <http://cfajohnson.com/>
Author:
Pro Bash Programming: Scripting the GNU/Linux Shell (2009, Apress)
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)