Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
Re: Attempt to copy freed scalar and return value semanticsby stephen (Priest) |
on May 24, 2013 at 17:39 UTC ( [id://1035177]=note: print w/replies, xml ) | Need Help?? |
The most obvious possibility is context. If you assign the method to $rv, it forces scalar context, while if you return it directly, it has whatever context the method was called in, which could be list or void context. We'd have to see the calling statement to be sure. Update: See http://community.activestate.com/node/8760. stephen
In Section
Seekers of Perl Wisdom
|
|