sub Str::TYPEDSCALAR { }
sub Str1::TYPEDSCALAR {
- $_[0] = 'dongs';
+ $_[0] = 'derp';
();
}
sub Str2::TYPEDSCALAR {
- $_[2] = 'hlagh';
+ $_[2] = 'herp';
();
}
maybe_warn();
local $@;
eval q!
- use Lexical::Types as => sub { $_[0] = 'dongs'; () };
+ use Lexical::Types as => sub { $_[0] = 'derp'; () };
my Str $x;
!;
like $@, ro_re('', 2), '$_[0] in initializer is read only';
maybe_warn();
local $@;
eval q!
- use Lexical::Types as => sub { $_[1] = 'hlagh'; () };
+ use Lexical::Types as => sub { $_[1] = 'herp'; () };
my Str $x;
!;
like $@, ro_re('', 2), '$_[1] in initializer is read only';