Save some repeated strlen()s in Perl_swash_init
[p5sagit/p5-mst-13.2.git] / t / lib / TieOut.pm
CommitLineData
39234879 1package TieOut;
2
3sub TIEHANDLE {
4 bless( \(my $scalar), $_[0]);
5}
6
7sub PRINT {
8 my $self = shift;
9 $$self .= join('', @_);
10}
11
1452766c 12sub PRINTF {
13 my $self = shift;
14 my $fmt = shift;
15 $$self .= sprintf $fmt, @_;
16}
17
39234879 18sub read {
19 my $self = shift;
1452766c 20 return substr($$self, 0, length($$self), '');
39234879 21}
22
231;