From: Gurusamy Sarathy Date: Fri, 2 Jul 1999 03:09:04 +0000 (+0000) Subject: avoid warnings X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ad78e5492e8cc81959085c550786672cd0db9f47;p=p5sagit%2Fp5-mst-13.2.git avoid warnings p4raw-id: //depot/perl@3564 --- diff --git a/ext/Thread/Thread/Specific.pm b/ext/Thread/Thread/Specific.pm index 9c8a66a..46b9b60 100644 --- a/ext/Thread/Thread/Specific.pm +++ b/ext/Thread/Thread/Specific.pm @@ -18,7 +18,7 @@ C 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 54602a6..f54f639 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";