http://qs1969.pair.com?node_id=544056


in reply to "map" sometimes uses only the last mapped value

It seems to have to do with returning a temp from inside a for loop. It's not just stringify, here:
print map sub{return $_ for 0+shift}->($_), 1, 2, 3; # 333 print map sub{return $_ for shift}->($_), 1, 2, 3; # 123 print map sub{return 0+shift}->($_), 1, 2, 3; # 123 print map sub{return 0+$_ for shift}->($_), 1, 2, 3; # 123
Only the first of these cases messes up, funny