Nothing to do with map; it has more to do with precedence. The or operator always returns a scalar.
Consider:
print "D:"; for (qq{ab cd}) { print(/(\S+)/g or die); } print "\n";
In reply to Re: map BLOCK evaluation context
by tobyink
in thread map BLOCK evaluation context
by vsespb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |