Hi monks,
this code...
package MyParseExcel;
use Spreadsheet::ParseExcel;
use Moo::Role;
use MooX::Types::MooseLike::Base qw(InstanceOf Str);
1;
...leads to:
Use of uninitialized value $roles[0] in sort at
C:/Perl/site/lib/Role/Tiny.pm line 199.
Compilation failed in require at C:\path\run.pl line 6.
But this one...
package MyParseExcel;
# use Spreadsheet::ParseExcel;
use Moo::Role;
use MooX::Types::MooseLike::Base qw(InstanceOf Str);
1;
...works. In Role::Tiny i see...
sub _composite_info_for {
my ($me, @roles) = @_;
$COMPOSITE_INFO{join('|', sort @roles)} ||= do { # <-- 199
_load_module($_) for @roles;
my %methods;
foreach my $role (@roles) {
my $this_methods = $me->_concrete_methods_of($role);
$methods{$_}{$this_methods->{$_}} = $role for keys %$this_methods
+;
}
delete $methods{$_} for grep keys(%{$methods{$_}}) == 1, keys %meth
+ods;
+{ conflicts => \%methods }
};
}
Perhaps i found another module that can't with Moo? This was my doubt using Moo: Long time used modules don't work as expected. Hope i don't miss something.
Thank you for your patience and help.
Regards, Karl
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.