diff --git a/lib/mop.pm b/lib/mop.pm index d9849d7..87d2675 100644 --- a/lib/mop.pm +++ b/lib/mop.pm @@ -16,7 +16,7 @@ use mop::class; use mop::method; use mop::attribute; -use mop::observable; +use mop::internals::observable; use mop::internals::syntax; use mop::internals::mro; @@ -216,7 +216,7 @@ sub bootstrap { mop::class mop::attribute mop::method - mop::observable + mop::internals::observable ]; my $Object = find_meta('mop::object'); @@ -226,7 +226,7 @@ sub bootstrap { my $Method = find_meta('mop::method'); my $Attribute = find_meta('mop::attribute'); - my $Observable = find_meta('mop::observable'); + my $Observable = find_meta('mop::internals::observable'); # At this point the metaclass # layer class to role relationship @@ -250,7 +250,7 @@ sub bootstrap { } # and now this is no longer needed - remove_meta('mop::observable'); + remove_meta('mop::internals::observable'); foreach my $meta ( $Object, $Method, $Attribute, $Class, $Role ) { $meta->FINALIZE; diff --git a/lib/mop/attribute.pm b/lib/mop/attribute.pm index 586b2de..3881e31 100644 --- a/lib/mop/attribute.pm +++ b/lib/mop/attribute.pm @@ -8,7 +8,7 @@ use Scalar::Util qw[ weaken ]; our $VERSION = '0.01'; our $AUTHORITY = 'cpan:STEVAN'; -use parent 'mop::object', 'mop::observable'; +use parent 'mop::object', 'mop::internals::observable'; mop::internals::util::init_attribute_storage(my %name); mop::internals::util::init_attribute_storage(my %original_id); diff --git a/lib/mop/observable.pm b/lib/mop/internals/observable.pm similarity index 98% rename from lib/mop/observable.pm rename to lib/mop/internals/observable.pm index ccb9eb6..8956efa 100644 --- a/lib/mop/observable.pm +++ b/lib/mop/internals/observable.pm @@ -1,4 +1,4 @@ -package mop::observable; +package mop::internals::observable; use v5.16; use warnings; diff --git a/lib/mop/method.pm b/lib/mop/method.pm index b32d62e..ee27586 100644 --- a/lib/mop/method.pm +++ b/lib/mop/method.pm @@ -8,7 +8,7 @@ use Scalar::Util qw[ weaken ]; our $VERSION = '0.01'; our $AUTHORITY = 'cpan:STEVAN'; -use parent 'mop::object', 'mop::observable'; +use parent 'mop::object', 'mop::internals::observable'; mop::internals::util::init_attribute_storage(my %name); mop::internals::util::init_attribute_storage(my %body); diff --git a/lib/mop/role.pm b/lib/mop/role.pm index 425c105..fcef8d5 100644 --- a/lib/mop/role.pm +++ b/lib/mop/role.pm @@ -10,7 +10,7 @@ use Module::Runtime qw[ is_module_name module_notional_filename ]; our $VERSION = '0.01'; our $AUTHORITY = 'cpan:STEVAN'; -use parent 'mop::object', 'mop::observable'; +use parent 'mop::object', 'mop::internals::observable'; mop::internals::util::init_attribute_storage(my %name); mop::internals::util::init_attribute_storage(my %version); diff --git a/t/120-bugs/010-bread-board-bug.t b/t/120-bugs/010-bread-board-bug.t index eb0a784..90b1171 100644 --- a/t/120-bugs/010-bread-board-bug.t +++ b/t/120-bugs/010-bread-board-bug.t @@ -11,8 +11,8 @@ use mop; This issue came up after doy made a number of tweaks to the role composition and it uncovered -an issue with the mop::observable role, which -basically boiled down to the fact it wasn't +an issue with the mop::internals::observable role, +which basically boiled down to the fact it wasn't properly storing SCALAR refs in the $callbacks fieldhash. This is just a simple test to check for this specific issue.