Re: write string requires an object with REPR MVMOSHandle

2017-03-29 Thread Elizabeth Mattijsen
> On 29 Mar 2017, at 12:36, Shlomi Fish wrote: > > On Wed, 29 Mar 2017 12:10:15 +0200 > Timo Paulssen wrote: > >> As part of the IOwesome grant, zoffix is going to fix this error. It's >> what you get when you try to write to or read from or do

Re: write string requires an object with REPR MVMOSHandle

2017-03-29 Thread Shlomi Fish
On Wed, 29 Mar 2017 12:10:15 +0200 Timo Paulssen wrote: > As part of the IOwesome grant, zoffix is going to fix this error. It's > what you get when you try to write to or read from or do anything with a > closed IO::Handle. > > When you use "LEAVE:" you're just declaring a

Re: write string requires an object with REPR MVMOSHandle

2017-03-29 Thread Timo Paulssen
As part of the IOwesome grant, zoffix is going to fix this error. It's what you get when you try to write to or read from or do anything with a closed IO::Handle. When you use "LEAVE:" you're just declaring a label called "LEAVE". There are no labels with special function, so your code is

write string requires an object with REPR MVMOSHandle

2017-03-29 Thread Gabor Szabo
I was running the following buggy code: sub save { my $fh = open('data.txt', :w); LEAVE: $fh.close; $fh.print("hello\n"); } save(); (note the : after the LEAVE) Which if I am not mistaken is basically the same as: sub save { my $fh = open('data.txt', :w); $fh.close;