diff options
-rw-r--r-- | ext/Thread/Thread/Specific.pm | 2 | ||||
-rw-r--r-- | lib/fields.pm | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/ext/Thread/Thread/Specific.pm b/ext/Thread/Thread/Specific.pm index 9c8a66a9e6..46b9b60981 100644 --- a/ext/Thread/Thread/Specific.pm +++ b/ext/Thread/Thread/Specific.pm @@ -18,7 +18,7 @@ C<key_create> returns a unique thread-specific key. sub import { use attrs qw(locked method); require fields; - fields->import(@_); + fields::->import(@_); } sub key_create { diff --git a/lib/fields.pm b/lib/fields.pm index 54602a6b88..f54f639b07 100644 --- a/lib/fields.pm +++ b/lib/fields.pm @@ -111,7 +111,7 @@ sub inherit # called by base.pm { my($derived, $base) = @_; - if (defined %{"$derived\::FIELDS"}) { + if (keys %{"$derived\::FIELDS"}) { require Carp; Carp::croak("Inherited %FIELDS can't override existing %FIELDS"); } else { @@ -132,7 +132,7 @@ sub _dump # sometimes useful for debugging { for my $pkg (sort keys %attr) { print "\n$pkg"; - if (defined @{"$pkg\::ISA"}) { + if (@{"$pkg\::ISA"}) { print " (", join(", ", @{"$pkg\::ISA"}), ")"; } print "\n"; |