Subject: | Reference is already weak at Mouse/Meta/Role/Application.pm line 83. |
Date: | Fri, 17 Feb 2012 06:45:42 -0500 |
To: | bug-mouse [...] rt.cpan.org |
From: | Alexander <acca [...] cpan.org> |
while using weak reference attributes, applying a role to an instance
produces the warning:
Reference is already weak at
[...]/Mouse/Meta/Role/Application.pm line 83.
Please see the snippet below. With ANY_MOOSE=Moose the code is silent.
package A;
use Any::Moose;
package B;
use Any::Moose;
has 'root' => (is => 'ro', weak_ref => 1);
package C;
use Mouse::Role;
package main;
my $a = new A;
my $b= new B(root => $a);
C->meta->apply($b);