On Thu, Jun 29, 2017 at 6:56 AM, Eduardo A. Bustamante López <dual...@gmail.com> wrote: > On Wed, Jun 28, 2017 at 07:08:27PM -0700, Keith Thompson wrote: > [...] >> mapfile REDIRECT < /tmp/input.txt >> cat /tmp/input.txt | mapfile PIPE > > The `mapfile PIPE' is a piece of a pipeline, and as such, it runs in a > subshell (different process). > > See: http://mywiki.wooledge.org/BashFAQ/024
OK, that makes sense, and of course the same thing applies to "read". I suggest that it would be worthwhile to mention this issue in the documentation. The fact that it's a FAQ suggests that people are likely to run into it.