I don't really know how to explain the quoted documentation though. I just edited your function to include a return statement, and it still worked the same way.The (poorly worded) documentation doesn't mean next won't leave that scope - it just means you can't use next to resume execution just after of the current eval {}, etc. when there's no loop in the eval {}, etc.
In reply to Re^2: Exiting subroutine via next
by ysth
in thread Exiting subroutine via next
by InfiniteLoop
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |