Skip to content

Commit 8f78292

Browse files
committed
Correct note about file handles
Resolves #1561.
1 parent 15f03be commit 8f78292

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

doc/Type/IO/Handle.pod6

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,15 +87,18 @@ In B<6.d> language, path C<'-'> has no special meaning.
8787
The C<:out-buffer> controls output buffering and by default behaves as if
8888
it were C<Nil>. See method L<out-buffer> for details.
8989
90-
B<Note:> unlike some other languages, Perl 6 does not use reference counting,
91-
and so B<the file handles are NOT flushed or closed when they go out of scope>.
90+
B<Note (Rakudo versions before 2017.09):>
91+
B<File handles are NOT flushed or closed when they go out of scope>.
9292
While they I<will> get closed when garbage collected, garbage collection isn't
9393
guaranteed to get run. This means I<you should> use an explicit C<close> on
9494
handles opened for writing, to avoid data loss, and
9595
an explicit C<close> is I<recommended> on handles opened for reading as well, so
9696
that your program does not open too many files at the same time, triggering
9797
exceptions on further C<open> calls.
9898
99+
B<Note (Rakudo versions 2017.09 and after):> Open file handles are
100+
automatically closed on program exit.
101+
99102
=head2 method comb
100103
101104
Defined as:

0 commit comments

Comments
 (0)