in reply to Extracting a slice from an array ref

in ARRAYREF->[EXPR] EXPR is evaluated in scalar context. So .. is treated as the flip-flop style range operrator and not expanded into a list. Which when numeric literals are used they are compared to $.