Subject: | Method conflict error messages should report all methods in conflict |
Not a bug per se, but it might be nice to improve the error message this
throws:
{
package Bomb;
use Moose::Role;
sub fuse { print "Bomb explode\n" }
sub explode { print "Bomb fuse\n" }
}
{
package Spouse;
use Moose::Role;
sub fuse { print "Spouse explode\n" }
sub explode { print "Spouse fuse\n" }
}
{
package PracticalJoke;
use Moose;
with qw(Bomb Spouse);
}
This generates the following error:
"Due to a method name conflict in roles 'Bomb' and 'Spouse', the method
'fuse' must be implemented or excluded by 'PracticalJoke'".
However, explode() method is also in conflict. It would be helpful to
list all conflicts up front rather than require the programmer to fix
each one and keep rerunning the code until they're all found.
Cheers,
Ovid