Consider this bash session:
set -- 1 2 3
echo "$*" # 1 2 3 (as expected)
IFS=a echo "$*" # 1 2 3 (why not "1a2a3"?)
IFS=a; echo "$*" # 1a2a3a (as expected)
Why does the "assignment before command" syntax not work to set IFS
to a different value for the duration of the single command? It appears you must change the value of IFS
first with a separate command.