Skip to content

Commit

Permalink
[io grant] Document IO::Handle.put
Browse files Browse the repository at this point in the history
  • Loading branch information
zoffixznet committed May 29, 2017
1 parent 373c60b commit 70a80ec
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions doc/Type/IO/Handle.pod6
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,25 @@ my $fh = open 'path/to/file', :w;
$fh.printf: "The value is %d\n", 32;
$fh.close;
=head2 method put
Defined as:
multi method put(**@text --> True)
Writes the given C<@text> to the handle, coercing any non-L<Str> objects
to L<Str> by calling L«C<.Str>|/routine/Str» method on them, and appending the
value of L«C<.nl-out>|/type/IO::Handle#method_nl-out» at the end.
Attempting to call this method when the handle is
L<in binary mode|/type/IO::Handle#method_encoding> will result in
C<X::IO::BinaryMode> exception being thrown.
=for code :skip-test
my $fh = 'path/to/file'.IO.open: :w;
$fh.print: 'some text';
$fh.close;
=head2 method say
Defined as:
Expand Down

0 comments on commit 70a80ec

Please sign in to comment.