I was trying to do this to decide whether to redirect stdin to a file or not:
[ ...some condition here... ] && input=$fileName || input=\"&0\" ./
( if [ ...some condition here... ]; then exec <$fileName fi exec ./myscript )
In a subshell, conditionally redirect stdin and exec the script.