This channel is intended for people just starting with the Raku Programming Language (raku.org). Logs are available at irclogs.raku.org/raku-beginner/live.html Set by lizmat on 8 June 2022. |
|||
05:20
teatime left
06:00
teatime joined
07:00
lizmat_ joined
07:04
lizmat left
09:15
lizmat_ left,
lizmat joined
17:04
lizmat_ joined
17:08
lizmat left
17:09
lizmat_ left,
lizmat joined
17:25
gfldex left
17:29
gfldex joined
|
|||
dano | Let's say I get a file handle with open, for example $handle = open "wut.txt"; | 17:53 | |
What is the way in Raku of closing that handle automatically as I leave the scope in which the handle was defined? | 17:54 | ||
nemokosch | I wonder if there is such a way at all | 18:02 | |
gfldex | dano: Filehandles are closed during GC run. If you open loads of FH and need to close them quickly, a LEAVE-phaser might be in order. | 18:07 | |
dano | OK, thanks. I will need to read about phasers, haven't heard of them | 18:14 | |
20:20
lizmat_ joined
20:23
lizmat__ joined
20:24
lizmat left
20:27
lizmat_ left
20:29
lizmat__ left
20:30
lizmat joined
21:20
lizmat left
|