in reply to Re^3: Unexpected behaviour with constant lists
in thread Unexpected behavior of '..' lists

It's not implemented like that at all. There's a specific set of ops meant for the range operator. It's much better than the longhand for(;;) which would be lots of more ops to dispatch.

⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

  • Comment on Re^4: Unexpected behaviour with constant lists

Replies are listed 'Best First'.
Re^5: Unexpected behaviour with constant lists
by ysth (Canon) on Jul 21, 2006 at 19:22 UTC
    There's a specific set of ops meant for the range operator.
    In general, yes, but those aren't used at all in this optimization. The only compilation difference between for (1..4) { } and for (1,4) { } is the former sets OPf_STACKED on the enteriter op. </c>
    t's much better than the longhand for(;;) which would be lots of more ops to dispatch.
    Yes.