Mike Gilbert wrote:
> > [] is shorthand for test. Both test and [[]] in my man bash read:
> >
> > --8<--
> > Expressions are composed of the primaries described .. under
> > CONDITIONAL EXPRESSIONS.
> > -->8--

And the next sentence is exactly what you wrote. :)

"Word splitting and pathname expansion are not performed on the words
between the [[ and ]]"


> Word splitting does not occur within double brackets. This is
> documented in the bash manual.
> 
> http://www.gnu.org/software/bash/manual/bashref.html#Conditional-Constructs
> 
> This causes empty output from a command substitution within double
> brackets to be treated as a zero-length string.

Thanks for pointing me to the right place!


//Peter

Reply via email to