Welcome to the Monastery | |
PerlMonks |
Re^2: Unexpected behavior of function 'say'by tobyink (Canon) |
on Mar 05, 2013 at 15:32 UTC ( [id://1021851]=note: print w/replies, xml ) | Need Help?? |
This is because of a change in Perl 5.14:
The OP's code does work in Perl 5.10, if you run it with the -MIO::Handle parameter to manually load the IO::Handle package.
package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name
In Section
Seekers of Perl Wisdom
|
|