summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPerl 5 Porters <perl5-porters@africa.nicoh.com>1996-07-15 00:36:25 +0000
committerCharles Bailey <bailey@genetics.upenn.edu>1996-07-15 00:36:25 +0000
commitc954a603b8f02c172ffe0fd3503b4d7ca983ad99 (patch)
tree73abb08ca471579b836d3c6aa18efcce51cd59bd
parentd825a42e0a67d546192c470c4cca7da269ab90b1 (diff)
downloadperl-c954a603b8f02c172ffe0fd3503b4d7ca983ad99.tar.gz
Quote string argument in example -- necessary if using strict subs
-rw-r--r--ext/GDBM_File/GDBM_File.pm2
-rw-r--r--ext/NDBM_File/NDBM_File.pm2
-rw-r--r--ext/ODBM_File/ODBM_File.pm2
-rw-r--r--ext/SDBM_File/SDBM_File.pm2
-rw-r--r--lib/AnyDBM_File.pm4
-rw-r--r--lib/Tie/Hash.pm4
-rw-r--r--lib/Tie/Scalar.pm4
-rw-r--r--lib/Tie/SubstrHash.pm2
-rw-r--r--pod/perlbot.pod6
9 files changed, 14 insertions, 14 deletions
diff --git a/ext/GDBM_File/GDBM_File.pm b/ext/GDBM_File/GDBM_File.pm
index 3f1d83e004..9c7ae066b7 100644
--- a/ext/GDBM_File/GDBM_File.pm
+++ b/ext/GDBM_File/GDBM_File.pm
@@ -7,7 +7,7 @@ GDBM_File - Perl5 access to the gdbm library.
=head1 SYNOPSIS
use GDBM_File ;
- tie %hash, GDBM_File, $filename, &GDBM_WRCREAT, 0640);
+ tie %hash, 'GDBM_File', $filename, &GDBM_WRCREAT, 0640);
# Use the %hash array.
untie %hash ;
diff --git a/ext/NDBM_File/NDBM_File.pm b/ext/NDBM_File/NDBM_File.pm
index 6072e651fc..47b1f5aa3c 100644
--- a/ext/NDBM_File/NDBM_File.pm
+++ b/ext/NDBM_File/NDBM_File.pm
@@ -28,7 +28,7 @@ NDBM_File - Tied access to ndbm files
use NDBM_File;
- tie(%h,NDBM_File,'Op.dbmx', O_RDWR|O_CREAT, 0640);
+ tie(%h, 'NDBM_File', 'Op.dbmx', O_RDWR|O_CREAT, 0640);
untie %h;
diff --git a/ext/ODBM_File/ODBM_File.pm b/ext/ODBM_File/ODBM_File.pm
index e5386e853b..923640ff34 100644
--- a/ext/ODBM_File/ODBM_File.pm
+++ b/ext/ODBM_File/ODBM_File.pm
@@ -24,7 +24,7 @@ ODBM_File - Tied access to odbm files
use ODBM_File;
- tie(%h,ODBM_File,'Op.dbmx', O_RDWR|O_CREAT, 0640);
+ tie(%h, 'ODBM_File', 'Op.dbmx', O_RDWR|O_CREAT, 0640);
untie %h;
diff --git a/ext/SDBM_File/SDBM_File.pm b/ext/SDBM_File/SDBM_File.pm
index 9b7acc1e09..a2d4df8558 100644
--- a/ext/SDBM_File/SDBM_File.pm
+++ b/ext/SDBM_File/SDBM_File.pm
@@ -24,7 +24,7 @@ SDBM_File - Tied access to sdbm files
use SDBM_File;
- tie(%h,SDBM_File,'Op.dbmx', O_RDWR|O_CREAT, 0640);
+ tie(%h, 'SDBM_File', 'Op.dbmx', O_RDWR|O_CREAT, 0640);
untie %h;
diff --git a/lib/AnyDBM_File.pm b/lib/AnyDBM_File.pm
index 50acce412a..c985e7ed25 100644
--- a/lib/AnyDBM_File.pm
+++ b/lib/AnyDBM_File.pm
@@ -39,8 +39,8 @@ will only find GDBM_File.
Having multiple DBM implementations makes it trivial to copy database formats:
use POSIX; use NDBM_File; use DB_File;
- tie %newhash, DB_File, $new_filename, O_CREAT|O_RDWR;
- tie %oldhash, NDBM_File, $old_filename, 1, 0;
+ tie %newhash, 'DB_File', $new_filename, O_CREAT|O_RDWR;
+ tie %oldhash, 'NDBM_File', $old_filename, 1, 0;
%newhash = %oldhash;
=head2 DBM Comparisons
diff --git a/lib/Tie/Hash.pm b/lib/Tie/Hash.pm
index 9a9d059a7f..20b6777978 100644
--- a/lib/Tie/Hash.pm
+++ b/lib/Tie/Hash.pm
@@ -26,8 +26,8 @@ Tie::Hash, Tie::StdHash - base class definitions for tied hashes
package main;
- tie %new_hash, NewHash;
- tie %new_std_hash, NewStdHash;
+ tie %new_hash, 'NewHash';
+ tie %new_std_hash, 'NewStdHash';
=head1 DESCRIPTION
diff --git a/lib/Tie/Scalar.pm b/lib/Tie/Scalar.pm
index 2db02ae1da..ef27dc1398 100644
--- a/lib/Tie/Scalar.pm
+++ b/lib/Tie/Scalar.pm
@@ -26,8 +26,8 @@ Tie::Scalar, Tie::StdScalar - base class definitions for tied scalars
package main;
- tie $new_scalar, NewScalar;
- tie $new_std_scalar, NewStdScalar;
+ tie $new_scalar, 'NewScalar';
+ tie $new_std_scalar, 'NewStdScalar';
=head1 DESCRIPTION
diff --git a/lib/Tie/SubstrHash.pm b/lib/Tie/SubstrHash.pm
index a01c66ef8d..825f305714 100644
--- a/lib/Tie/SubstrHash.pm
+++ b/lib/Tie/SubstrHash.pm
@@ -8,7 +8,7 @@ Tie::SubstrHash - Fixed-table-size, fixed-key-length hashing
require Tie::SubstrHash;
- tie %myhash, Tie::SubstrHash, $key_len, $value_len, $table_size;
+ tie %myhash, 'Tie::SubstrHash', $key_len, $value_len, $table_size;
=head1 DESCRIPTION
diff --git a/pod/perlbot.pod b/pod/perlbot.pod
index 0fd545fe88..0f7078f197 100644
--- a/pod/perlbot.pod
+++ b/pod/perlbot.pod
@@ -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";
@@ -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";