in reply to Re^4: chopping a string into slices - is there a more elegant way to do it?
in thread chopping a string into slices - is there a more elegant way to do it?

I apologize, you were right!
$a= ( test() ); print $a; #> 9 sub test { return (1,2) if wantarray; return 9; }
the paranthesis don't force list context, they seem to be interpreted for the precedence of the lexer!
  • Comment on Re^5: chopping a string into slices - is there a more elegant way to do it?
  • Download Code