This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
5.004_56: Patch to Tie::Hash and docs
[perl5.git] / lib / Tie / Hash.pm
index 2117c54..89fd61d 100644 (file)
@@ -110,7 +110,7 @@ sub new {
 
 sub TIEHASH {
     my $pkg = shift;
-    if (defined &{"{$pkg}::new"}) {
+    if (defined &{"${pkg}::new"}) {
        carp "WARNING: calling ${pkg}->new since ${pkg}->TIEHASH is missing"
            if $^W;
        $pkg->new(@_);