blob: 3377eb27fb4311d9b60238bb30777bbe08f80ad0 [file] [log] [blame] [edit]
f() { echo start:; for i; do echo "|$i|"; done; echo end; }
x=a
echo "Unquoted '':"
f ${x:+''}
f ${x:+'' }
f ${x:+ ''}
f ${x:+ '' }
f ${x:+'' ''}
echo
echo 'Unquoted "":'
f ${x:+""}
f ${x:+"" }
f ${x:+ ""}
f ${x:+ "" }
f ${x:+"" ""}
echo
echo "Quoted '':"
f "${x:+''}"
f "${x:+'' }"
f "${x:+ ''}"
f "${x:+ '' }"
f "${x:+'' ''}"
echo
echo 'Quoted "":'
f "${x:+""}"
f "${x:+"" }"
f "${x:+ ""}"
f "${x:+ "" }"
f "${x:+"" ""}"