X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperlbot.pod;h=0f7078f197bb3d46bf9f7b22a9b337822c1b58b8;hb=2c19844b698b17b45488d6c855e43f78c774c1f1;hp=61a37266a2bdc75a8a27ecfcf3dc85a20d3b228e;hpb=4633a7c4bad06b471d9310620b7fe8ddd158cccd;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perlbot.pod b/pod/perlbot.pod index 61a3726..0f7078f 100644 --- a/pod/perlbot.pod +++ b/pod/perlbot.pod @@ -2,7 +2,7 @@ perlbot - Bag'o Object Tricks (the BOT) -=head1 INTRODUCTION +=head1 DESCRIPTION The following collection of tricks and hints is intended to whet curious appetites about such things as the use of instance variables and the @@ -251,8 +251,8 @@ This example demonstrates an interface for the SDBM class. This creates a package Mydbm; require SDBM_File; - require TieHash; - @ISA = qw( TieHash ); + require Tie::Hash; + @ISA = qw( Tie::Hash ); sub TIEHASH { my $type = shift; @@ -277,11 +277,11 @@ This example demonstrates an interface for the SDBM class. This creates a package main; use Fcntl qw( O_RDWR O_CREAT ); - tie %foo, Mydbm, "Sdbm", O_RDWR|O_CREAT, 0640; + tie %foo, "Mydbm", "Sdbm", O_RDWR|O_CREAT, 0640; $foo{'bar'} = 123; print "foo-bar = $foo{'bar'}\n"; - tie %bar, Mydbm, "Sdbm2", O_RDWR|O_CREAT, 0640; + tie %bar, "Mydbm", "Sdbm2", O_RDWR|O_CREAT, 0640; $bar{'Cathy'} = 456; print "bar-Cathy = $bar{'Cathy'}\n"; @@ -494,8 +494,8 @@ behavior by adding custom FETCH() and STORE() methods, if this is desired. package Mydbm; require SDBM_File; - require TieHash; - @ISA = qw(TieHash); + require Tie::Hash; + @ISA = qw(Tie::Hash); sub TIEHASH { my $type = shift; @@ -522,6 +522,6 @@ behavior by adding custom FETCH() and STORE() methods, if this is desired. package main; use Fcntl qw( O_RDWR O_CREAT ); - tie %foo, Mydbm, "adbm", O_RDWR|O_CREAT, 0640; + tie %foo, "Mydbm", "adbm", O_RDWR|O_CREAT, 0640; $foo{'bar'} = 123; print "foo-bar = $foo{'bar'}\n";