in reply to Howto return a reference of an array of custom class?
For one thing you're attempting to use the concatenation operator ($_.p() parses as "concatenate the string in $_ with the return value from calling the subroutine p with no arguments") to invoke a method rather than the correct syntax, $_->p().
|
|---|