The reason for the related example is as follows:
wc <(cat /usr/share/dict/linux.words)
And the mapfile answer is as follows:
mapfile -t array < <(./inner.sh)
Due to the difference in wc and mapfile and how the replaced process should be specified for the command.
As anishsane says, the extension <(command) is a file name and can be used wherever a file name can be used.
wc accepts file names as arguments, so they can be used directly as an argument.
mapfile is read from standard input, so to read it from the specific file you are using, you redirect standard input from the file </path/to/somefile , but, as I said, the extension <(command) is the name of the file, so you can use that in input redirect.
However, you cannot just pass two bits directly (the way you can with the file name / path), because << also a valid shell construct (here is a document), and this will be ambiguous for the shell. Therefore, in order to avoid the fact that you need to select two characters < and the result is < <(command) (which is similar to < file , which is completely legal).
Etan reisner
source share