summaryrefslogtreecommitdiff
path: root/pod/perltie.pod
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1999-02-15 00:05:33 +0000
committerGurusamy Sarathy <gsar@cpan.org>1999-02-15 00:05:33 +0000
commit889a76e8f1e5631a20f50ddde7021ae552342884 (patch)
treedc8685470cee06131776b39a88c9c56dfdb0d145 /pod/perltie.pod
parent2a94b7cea54b3d506736da8295e8510b9ce821c2 (diff)
downloadperl-889a76e8f1e5631a20f50ddde7021ae552342884.tar.gz
tweak READ() docs to mention $buffer must be altered by reference
p4raw-id: //depot/perl@2920
Diffstat (limited to 'pod/perltie.pod')
-rw-r--r--pod/perltie.pod11
1 files changed, 7 insertions, 4 deletions
diff --git a/pod/perltie.pod b/pod/perltie.pod
index cae0a15a54..665265818d 100644
--- a/pod/perltie.pod
+++ b/pod/perltie.pod
@@ -680,9 +680,12 @@ This method will be called when the handle is read from via the C<read>
or C<sysread> functions.
sub READ {
- $r = shift;
- my($buf,$len,$offset) = @_;
- print "READ called, \$buf=$buf, \$len=$len, \$offset=$offset";
+ my $self = shift;
+ my $$bufref = \$_[0];
+ my(undef,$len,$offset) = @_;
+ print "READ called, \$buf=$bufref, \$len=$len, \$offset=$offset";
+ # add to $$bufref, set $len to number of characters read
+ $len;
}
=item READLINE this
@@ -690,7 +693,7 @@ or C<sysread> functions.
This method will be called when the handle is read from via <HANDLE>.
The method should return undef when there is no more data.
- sub READLINE { $r = shift; "PRINT called $$r times\n"; }
+ sub READLINE { $r = shift; "READLINE called $$r times\n"; }
=item GETC this