Array-based process expansion insufficiently documented
an array-based process expansion will split the output into an array delimited by whitespaces.
... let array = @(cmd args...)
NOTES:
...
@(cmd)
is equivalent to@split($(cmd))
But in a test directory containing files aa, bb, and cc, doing
let res=@(ls)
echo @res[0]
gives
while doing
echo @split($(ls))[0]
gives
aa
Edited by ngirard