🦋 Welcome to Raku! raku.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: colabti.org/irclogger/irclogger_log/raku
Set by ChanServ on 14 October 2019.
00:01 hungrydonkey joined 00:04 titsuki joined 00:10 pmurias left 00:11 Doc_Holliwood left 00:14 imcsk8 left 00:16 imcsk8 joined
japhb Anyone have any idea how to create and display a new window in GTK::Simple? I'm feeling like an idiot because the obvious things are very much not working for me, but there aren't any examples that spawn a new window in Raku code (11-file-chooser-button.pl6 opens a new window, but it happens in C code) 00:39
00:41 chloekek left 00:56 Kaiepi left 01:01 Kaiepi joined
rypervenche japhb: What do you mean it happens in C code? 01:29
01:34 sena_kun joined 01:36 Altai-man_ left 01:39 _jrjsmrtn left, __jrjsmrtn__ joined
japhb rypervenche: It's builtin (C-level) GTK+ functionality of the gtk_file_chooser_button to open a gtk_file_chooser when clicked, not something wired up in the Raku code of GTK::Simple 01:48
01:54 cpan-raku left, cpan-raku joined, cpan-raku left, cpan-raku joined 02:09 Kaeipi joined, Kaiepi left 02:12 Kaeipi left 02:14 Kaeipi joined, ufobat_ joined 02:18 ufobat__ left 02:32 Maylay left 02:56 Maylay joined 03:01 Manifest0 left 03:02 Manifest0 joined 03:03 k-man left 03:07 k-man joined 03:08 orinthe left 03:33 Altai-man_ joined 03:35 aborazmeh left 03:36 sena_kun left
SmokeMachine Voldenet: www.irccloud.com/pastebin/Il7vS6Hs/ 04:12
04:33 heth left 04:36 hungrydonkey left
SmokeMachine Voldenet: this is working as expected: github.com/FCO/EventExpressionLang...t-knocking 04:36
04:37 hungrydonkey joined 04:43 heth joined 04:46 orinthe joined 04:47 orinthe left 04:53 cfa left 05:06 orinsu joined 05:20 vrurg left 05:21 molaf joined, vrurg joined 05:34 sena_kun joined 05:36 Altai-man_ left 05:45 orinsu is now known as orinthe 05:56 Doc_Holliwood joined 06:08 reach_satori_ left 06:29 sauvin joined 06:36 NODE left 06:39 NODE joined, domidumont joined 06:41 marcusr left 06:42 NODE left, marcusr joined, domidumont left 06:43 NODE joined, NODE left 06:45 NODE joined 06:52 domidumont joined
Geth doc: eb754a2b3c | (JJ Merelo)++ | doc/Language/variables.pod6
Revision and reindexing #2632
07:01
doc: c7c185394b | (JJ Merelo)++ | 2 files
Revision and reindexing #2632

Eliminates the word "container" in the variables file, since constants are defined in "terms" as variables with no container.
linkable6 Link: docs.raku.org/language/variables
Geth doc: ba52a17d3d | (JJ Merelo)++ | doc/Language/terms.pod6
Revision of constant constraints #2632

Mostly reflow, since everything was there already (thanks @zoffix)
linkable6 DOC#2632 [open]: github.com/Raku/doc/issues/2632 [Hacktoberfest][RFE][big][docs][good first issue][help wanted][new][⚠ Top Priority ⚠] Checklist for 6.d
linkable6 Link: docs.raku.org/language/terms
07:03 jmerelo joined 07:04 ctilmes1 left, ctilmes1 joined 07:09 marcusr left 07:11 marcusr joined
El_Che hopefully he'll return some day 07:13
jmerelo El_Che: zoffix? I don't think so. For the foreseeable future, at least 07:14
tellable6 2020-02-20T20:17:35Z #raku <tbrowder> jmerelo: sorry about the news...
2020-02-20T21:36:10Z #raku <patrickb> jmerelo: Is there a way to find out why we were rejected at this years GSoC? That'd be really good to know.
2020-02-20T21:36:42Z #raku <patrickb> jmerelo: Was the TPF organization deleted? When I try to log in with my google account it says I'm not part of any organization anymore...
07:14 rindolf joined
jmerelo .tell patrickb, no, no way that I know of. And yes, the organization has been deleted for me too; it returned a 403. 07:15
tellable6 jmerelo, I'll pass your message to patrickb
07:28 xinming joined 07:31 xinming_ left 07:33 rindolf left, Altai-man_ joined 07:36 sena_kun left 07:44 stoned75 left 07:45 kktt007 joined 07:50 Kaeipi left 07:51 wamba joined 07:53 Kaiepi joined, domidumont left 07:54 wamba left 08:02 cognomin_ joined 08:05 cognominal left 08:09 rindolf joined 08:16 domidumont joined 08:34 Doc_Holliwood left
jmerelo releasable6: status 08:41
releasable6 jmerelo, Next release in ≈1 day and ≈10 hours. There are no known blockers. 163 out of 247 commits logged
jmerelo, Details: gist.github.com/81970e56864179f595...86bd98f47e
jmerelo .tell Altai-man great job!
tellable6 jmerelo, I'll pass your message to Altai-man_
08:51 darkstardev13 joined 08:52 titsuki left 08:53 raven__ left 09:02 Doc_Holliwood joined 09:10 titsuki joined 09:20 [Sno] left 09:21 [Sno] joined 09:23 nwc10 joined, |Sno| joined
nwc10 OK, I (technically $ork, written by $other) have a long running process that seems to slowly eat all the RAM. It *looks* like I can use the snapper module to tell it to periodically take heap snapshots (eg once an hour) - but I can't find any example docs to "steal". Where should I be looking? 09:25
09:26 [Sno] left 09:27 reach_satori_ joined
jmerelo nwc10 it's part of Telemetry: docs.raku.org/type/Telemetry#module_snapper 09:28
09:28 veesh_ joined
nwc10 jmerelo: yes, and *that* doesn't seem to have many docs either 09:28
09:28 wamba joined, veesh left
nwc10 aha, at least, not in the repository. 09:29
jmerelo nwc10: what you see is what you get, I'm afraid... Please raise an issue requesting an enhancement
09:32 [Sno] joined, wamba left, wamba joined 09:34 |Sno| left, sena_kun joined 09:36 Altai-man_ left 09:37 pecastro joined
lizmat nwc10: RAKUDO_SNAPPER=3600 raku -Msnapper your program ? 09:38
nwc10 cool, that's what I thought might well do the job
(was distracted by actual $ork)
but I have to
1) figure out where the CWD is
2) figuure how how to do this when it's currently run from a systemd unit
and *then* I have to figure out what to do to process heap snapshots 09:39
lizmat well, snapper doesn't take heap snapshots, it just queries some system parameters in a separate thread and writes them to STDERR
nwc10 jmerelo: I had gone quiet because your link to docs.raku.org looked like it might give me enough clue to figure something out
lizmat it is really simple, almost braindead 09:40
09:41 Doc_Holliwood left
nwc10 hangon, confused by that last statement. I *thought* that I'd figured it out as the snapper module calls Telemetry::snapper, and in turn that creates a thread tha calls Telemetry::snap (at the regular interval) and *that* takes snapshots 09:41
and in turn, snapper (the module) can be controled from the environment. But *only* the interval (which is what matters most) 09:42
the basic question I'm trying to answer is "is this memory consumption from
1) a but in the code which is keeping objects around?
lizmat yeah, so it's nothing like the snapshot module that Timo is working on, is what I'm saying 09:43
nwc10 2) a problemetic interaction with the MoarVM GC, such that the amound of system memory grows, but the GC doesn't actually leak anything
or
3) a real leak
"
we've eliminated answer 0 - "bad reaction to something it's talking to" 09:44
ie it's slowly eating RAM, not geting upset by something and (figuratively) expoding
exploding
lizmat can you not rule out 2. by running on ulimit something ?
nwc10 lizmat: I think I understand the question, and I don't think so. Left to run, this process eats all RAM on the VM in about 2 or 3 days 09:45
lizmat and will it die then because of OOM ? or will it continue to run ? 09:46
nwc10 it does because of OOM
the OOM killer takes an unhealthy interest in it
so I'm asuming that ulimit will just mean something else kilsl it first 09:47
although, I see, that might be itneresting because it might give a backtrace of *where* the failed allocation was
but first, apart from $ork, my coffee cup has a bug that I need to fix. 09:49
09:54 kktt007 left, titsuki left 10:04 mowcat joined 10:11 cognominal joined 10:15 cognomin_ left
Geth doc: jsoref++ created pull request #3225:
Spelling
10:31
10:33 wamba left 10:35 Black_Ribbon left 10:44 veesh_ left, veesh joined 10:49 mowcat left 10:50 darkstardev13 left
Geth doc/master: 5 commits pushed by (Josh Soref)++, (Juan Julián Merelo Guervós)++ 10:52
10:56 darkstardevx joined
Voldenet SmokeMachine: that's fairly cool, I'll maybe try to write an actual port knocking solution with that, just to see how short would it be :) 11:11
11:18 Doc_Holliwood joined 11:19 hankache joined 11:23 rindolf left 11:27 hungryd59 joined 11:28 titsuki joined, reach_satori_ left, reach_satori joined 11:29 rindolf joined, hungrydonkey left 11:30 wamba joined 11:33 Altai-man_ joined 11:36 sena_kun left 11:42 hungrydonkey joined 11:44 hungryd59 left 11:45 hungrydonkey left, hungrydonkey joined 11:57 titsuki left 11:59 titsuki joined
Geth rakudo.org: 2b6fb4dd16 | (Naoum Hankache)++ (committed using GitHub Web editor) | templates/star.html.ep
Update some links
12:04
12:11 reach_satori left, reach_satori joined 12:15 xinming left, xinming joined 12:19 Sgeo left, Sgeo joined 12:20 reach_satori left 12:21 reach_satori joined, wamba left 12:38 Doc_Holliwood left 12:46 lucasb joined, Kaiepi left 12:47 domidumont left 12:49 Kaiepi joined 12:53 brtastic joined 12:57 reach_satori left 12:58 reach_satori joined 12:59 mowcat joined 13:00 reach_satori left, xinming left 13:01 reach_satori joined, xinming joined 13:09 reach_satori left 13:13 Doc_Holliwood joined 13:23 hankache left 13:24 aborazmeh joined, aborazmeh left, aborazmeh joined 13:34 sena_kun joined 13:36 Altai-man_ left 13:37 mowcat left 13:51 Doc_Holliwood left 13:59 jmerelo left 14:02 molaf left 14:15 molaf joined
discord6 <Highlander> How does one check what type restriction is on a container? 14:18
jnthn m: my Int $a; say $a.VAR.of 14:19
evalable6 (Int)
discord6 <Highlander> Thanks
<Highlander> Ah, so VAR gets the Scalar 14:20
<Highlander> makes sense
14:20 cpan-raku left, cpan-raku joined, cpan-raku left, cpan-raku joined
guifa Not that if using a where clause that might fail 14:21
Well, it doesn’t fail, it just doesn’t get you very useful information
m: my $a where Int|Str = 4; say $a.VAR.of 14:22
evalable6 (<anon>)
guifa . o O ( yet another reason to prefer subtypes to where clauses )
errr subsets*
14:26 mensvaga joined
[Coke] jnthn++ # finally able to run a full "make xtest" in doc again. 14:27
discord6 <Highlander> Another somewhat more complex question about subroutine calling: say I have my $a = 1 -- $a.VAR.of is (Mu), fine 14:28
<Highlander> but then if I pass that into sub test(Int $param) { say $param.VAR.of; } it tells me Int doesn't have an "of" method 14:29
jnthn Yes, because there's no container there, the Int is bound directly into $param 14:30
discord6 <Highlander> Oh? I was under the impression it was just a readonly container
jnthn You'd need `Int $param is copy` to insist on that
A readonly container is created if the thing is Iterable and would flatten when it shoudln't, otherwise it optimizes that way and just binds the value 14:31
*away
discord6 <Highlander> Fair enough 14:32
jnthn (Which in some programs saves a non-trivial percentage of allocations...)
discord6 <Highlander> Yeah, I could see direct binding being a big gain there 14:33
Geth doc: 54843fdae3 | Coke++ | xt/words.pws
learn new class

Allow simple plural - it's clear from formatting Supply is a class name we aren't going to dynamically change spelling on
14:34
14:41 colomon_ left 14:42 Doc_Holliwood joined 14:47 pmurias joined, pmurias left, pmurias joined 14:48 titsuki left
pmurias MasterDuke: I have started working on getting the truffle backend to work on the new graalvm 14:48
MasterDuke pmurias: nice!
pmurias MasterDuke: got to refactor some stuff as they enforce a separation between the language implementation and the launcher (In our case that would be the part running on the old backend) 14:49
MasterDuke hm, is that a good thing for us in the long run anyway? i.e., will it help with eventually making the truffle backend the primary/only jvm backend? 14:50
pmurias in the long run we want our backend to be registered the same way all the other truffle languages are 14:52
so they can eval Raku code using the same API as they use for JS and TruffleRuby
MasterDuke yeah, that would be nice 14:53
pmurias but in the short run the truffle NQP isn't yet bootstrapped so we use a workaround where we parse on the old backend
15:02 aborazmeh left 15:11 mowcat joined 15:18 brtastic left 15:23 Doc_Holliwood left 15:33 Altai-man_ joined 15:34 cognomin_ joined 15:36 sena_kun left 15:37 pmurias left, cognominal left 16:13 Doc_Holliwood joined
discord6 <もふもふいつ撫でも (Mofu MOFO)> I am not complaining, friends, but I am curious. I once caught wind that hawtness related to vastly improving performance in Perl6 is somewhere down the pipe. Is this gonna be reality someday? I am excite. 16:30
Altai-man_ have you seen www.youtube.com/watch?v=QNeu0wK92NE ? 16:32
there are new releases montly and each one packs numerous "Make Foo.bar baz percents faster". Also some heavy VM optimizations are work in progress, some of them will be included in 2020.03 release (hopefully). 16:33
discord6 <もふもふいつ撫でも (Mofu MOFO)> As long as it'll eventually be as fast as Ruby, das all I want. I am very entitled human being who demands things I didn't pay for to be gr8. 16:36
Altai-man_ as the report states, some things are _already_ faster/on par with ruby, some are not there yet, so one might hope (and help). :) 16:37
Doc_Holliwood Another great day in Apple Support. Now for the interesting stuff in life :) 16:41
16:43 pecastro left
Doc_Holliwood This tweet: twitter.com/jjatria/status/1230554758215155713 we should adopt that and use it as a motto / marketing ploy 16:44
"Raku, the language you never knew you always wanted", that's just poetic
discord6 <もふもふいつ撫でも (Mofu MOFO)> I wonder how long it's going to take for me to stop calling it Perl6. 16:45
Doc_Holliwood maybe it helps getting rid of the 6 in your name? 16:47
discord6 <もふもふいつ撫でも (Mofu MOFO)> I mean, I could do it now. But it wouldn't be coming from the heart.
<もふもふいつ撫でも (Mofu MOFO)> I dunno mang, this is what my username looks like: i.imgur.com/osAP3k1.png 16:49
Grinnz it's the discord bridge that has 6 in the name
discord6 <もふもふいつ撫でも (Mofu MOFO)> This Bridge guy has so many personalities.
Altai-man_ >Russian locale 16:50
surprising
Doc_Holliwood Are you one of those russian hackers they talk about in the news all the time, Grinnz? 16:51
discord6 <もふもふいつ撫でも (Mofu MOFO)> Vodka joke goes here.
Grinnz I'm only like, 1/16th russian
Altreus hmm that's less than roulette 16:52
16:54 domidumont joined
discord6 <もふもふいつ撫でも (Mofu MOFO)> is there any way to do something like perl my \Х = 3; my \У = 8; my \Й = 11; say ( X²+Y²=Й² ); ? 17:00
lizmat m: my \Х = 3; my \У = 8; my \Й = 11; say Х²+У²==Й² # if you consistently use the right characters, and use == instead of =, then yes 17:03
evalable6 False
17:04 jmerelo joined 17:08 guifa left
jmerelo After the GSoC upset, we've still got to try outreachy. Please submit your ideas here github.com/perl-foundation-outreac...2020-ideas 17:11
Doc_Holliwood Does this leak? gist.github.com/holli-holzer/74caa...646edcdf43 17:13
i guess not, but ...
17:13 xinming left 17:14 xinming joined 17:20 aborazmeh joined, aborazmeh left, aborazmeh joined 17:25 domidumont left 17:27 domidumont joined 17:32 domidumont left 17:33 domidumont joined 17:34 sena_kun joined
tyil Doc_Holliwood: discord6 is the name of a bot which bridges this channel to a channel on discord 17:35
I guess I *should* change the nickname sometime soon
17:36 Altai-man_ left
rypervenche Consistency <3 17:39
tyil jmerelo: I haven't paid a lot of attention lately, what happened with gsoc?
you may pm or email if thats more convenient
lizmat TPF was not selected for GSOC 17:41
tyil :(
17:47 hungryd5 joined, mtj_ left 17:50 hungrydonkey left 18:01 aborazmeh left 18:03 hungryd5 left 18:06 jmerelo left 18:07 xinming left, domidumont left 18:08 patrickb joined, xinming joined
Doc_Holliwood i'm tired of writing %% 2 18:10
can i have .even and .odd please?
18:11 rba[m] left, pmf[m] left, uzl[m] left, unclechu left 18:12 NODE left, awwaiid left, CIAvash left, BlackChaosNL[m] left, EuAndreh[m] left, matiaslina left, AlexDaniel` left, tadzik[m]1 left 18:13 NODE joined
sena_kun Doc_Holliwood, sure! *jokes about sub even / sub odd* 18:13
18:13 reach_satori joined
sena_kun m: my &foo = method(Int:D $a --> Bool) { $a %% 2 }; say 43.&foo; 18:14
evalable6 (exit code 1) 04===SORRY!04=== Er…
sena_kun, Full output: gist.github.com/f4db6fbc7e8479d475...fca63308da
sena_kun hm
m: my &foo = method { self %% 2 }; say 43.&foo; say 42.&foo; 18:15
evalable6 False
True
sena_kun shorter one wins. :P
m: my &foo = * %% 2 ; say 43.&foo; say 42.&foo; 18:16
evalable6 False
True
Doc_Holliwood I know you can do that. That's not the point.
sena_kun Doc_Holliwood, I got your point, but while not being core dev, I somehow can't say I appreciate the idea of making CORE fatter. 18:17
Doc_Holliwood The only way to enhance a builtin type is monkeypatching it, yes? 18:19
sena_kun Doc_Holliwood, but / does role also?
Doc_Holliwood and thus code that does that cannot be precompiled, right?
sena_kun m: '1 %% 2'.chars.say; '1.is-even'.chars.say; 18:20
evalable6 6
9
sena_kun m: '(1 %% 2)'.chars.say; '1.is-even'.chars.say;
evalable6 8
9
Doc_Holliwood Yeah, but then you have to write it out everywhere like here: gist.github.com/holli-holzer/74caa...646edcdf43
sena_kun is not sure if right gist 18:21
Doc_Holliwood 1 but Linked
sena_kun ah, I see
I still don't get it. Typing `is-even` is slower / requires more keystokes than `%% 2` even with parens on. 18:22
Doc_Holliwood m: role foo { method bar { say "bar" } }; subset FInt of Int does foo;
evalable6 (exit code 1) 04===SORRY!04=== Error while compiling /tmp/eBPqH3ePIO
No such method 'add_role' for invocant of type 'Perl6::Metamodel::SubsetHOW'
at /tmp/eBPqH3ePIO:1
Doc_Holliwood german keyboards are horrible, let me put it this way
sena_kun you might argue that `()` keys are more distant than letters
Doc_Holliwood also the shift key 18:23
m: role foo { method bar { say "bar" } }; class FInt is Int does foo {}; 18:24
evalable6
Doc_Holliwood m: role foo { method bar { say "bar" } }; class FInt is Int does foo {}; FInt(99).bar;
evalable6 (exit code 1) Cannot find method 'FInt' on object of type Int
in block <unit> at /tmp/dEfwwv0d6H line 1
Doc_Holliwood m: role foo { method bar { say "bar" } }; class FInt is Int does foo {}; FInt.new(99).bar;
evalable6 bar
18:24 tadzik[m]1 joined
Doc_Holliwood that's not pretty either 18:25
18:28 orinthe left, orinthe joined 18:29 rba[m] joined 18:30 rba[m] left, tadzik[m]1 left 18:33 orinthe left 18:47 reach_satori left 18:50 cognominal joined, Black_Ribbon joined 18:54 cognomin_ left
lizmat Doc_Holliwood: get a US Intl keyboard :-) 18:54
Doc_Holliwood I'm confused enough by using a Mac at day and a PC at night, liz =) 18:56
18:59 Xliff joined
discord6 <もふもふいつ撫でも (Mofu MOFO)> My life is using all mac as my portable workstation, winderp with WSL at home, SSH-ing into servers all day-everyday, and then using NetBSD's pkgsrc all day everyday on Linux and especially macOS. AKA, all the same shit if I have a POSIX shell and can open a web browser to look at catgirls 19:01
19:03 AlexDaniel` joined 19:15 orinthe joined, orinthe left 19:18 orinthe joined 19:25 xinming left 19:27 xinming joined 19:33 Altai-man_ joined 19:34 orinthe left, CIAvash joined, EuAndreh[m] joined, rba[m] joined, unclechu joined, pmf[m] joined, BlackChaosNL[m] joined, awwaiid joined, uzl[m] joined, matiaslina joined, tadzik[m]1 joined 19:36 sena_kun left 19:37 molaf left 19:43 domidumont joined 19:45 xinming left 19:46 xinming joined 19:47 domidumont left 19:52 orinthe joined 20:00 orinthe left 20:14 xinming left, xinming joined 20:30 orinthe3 joined 20:31 orinthe3 is now known as orinthe 20:33 MilkmanDan left 20:34 MilkmanDan joined
Geth ¦ problem-solving: lizmat assigned to jnthn Issue $*CWD is an IO::Path, IO::Path.CWD is a Str github.com/Raku/problem-solving/issues/164 20:34
20:39 mensvaga left 20:48 SCHAPiE left 20:50 SCHAPiE joined 21:09 SCHAPiE left 21:11 pecastro joined 21:12 SCHAPiE joined
SmokeMachine Hi guys! I was thinking... there is a big difference between EEL and regexp is that if I do this `/"a" "a" "a"/` it matches "aaa" and do not matches "aaba" but with EEL, if I do `bla() bla() bla()` would match this sequence `{"type" : "bla"}{"type" : "bla"}{"type" : "bla"}` but also would match this sequence `{"type" : "bla"}{"type" : "bla"}{"type" : "ble"}{"type" : "bla"}` it would ignore the `ble` one... so I'm 21:20
thinking on doing something like: `:!ignore`. and it could receive condition, for example: `:!ignore(bla(a == #1.a)) bla(#1, b == 1) bla(a == #1.a, b == 1)` that way, it would match `{"type" : "bla", "a" : 42, "b" : 1 }{"type" : "bla", "a" : 42, "b" : 1 }` and `{"type" : "bla", "a" : 42, "b" : 1 }{"type" : "bla", "a" : 42, "b" : 2 }{"type" : "bla", "a" : 42, "b" : 1 }` but not `{"type" : "bla", "a" : 42, "b" : 1
}{"type" : "bla", "a" : 42, "b" : 2 }{"type" : "bla", "a" : 42, "b" : 1 }`. But I don't think `ignore` is the right name for it... what do you guys thing?
Voldenet: ^^
21:21 chloekek joined 21:24 kensanata joined 21:26 pecastro left 21:34 sena_kun joined 21:36 Altai-man_ left
[Coke] yays as he gets to use a little Raku for a small work project. 21:39
21:43 pecastro joined
rypervenche [Coke]: Woot woot! 21:44
21:52 Doc_Holliwood left 22:17 laama left 22:19 [Sno] left 22:21 [Sno] joined
Xliff What would be the best way to resolve this? 22:25
m: role A { submethod BUILD (:$a) { say "A" } }; role B { also does A; submethod BUILD (:$b) { say "B" } }; class C does B { }; C.new
evalable6 (exit code 1) 04===SORRY!04=== Error while compiling /tmp/v_517kM0wL
Package 'B' already has a submethod 'BUILD' (did you mean to declare a multi-method?)
at /tmp/v_517kM0wL:1
22:26 molaf joined
Xliff m: role A { submethod BUILD (:$a) { say "A" } }; role B { submethod BUILD (:$b) { say "B" } }; class C does B does A { }; C.new 22:26
evalable6 (exit code 1) 04===SORRY!04=== Error while compiling /tmp/ViCJryQeYE
Method 'BUILD' must be resolved by class C because it exists in multiple roles (A, B)
at /tmp/ViCJryQeYE:1
Xliff m: role A { submethod BUILD (:$a) { say "A" } }; role B { submethod BUILD (:$b) { say "B" } }; class C does B { also does A }; C.new
evalable6 (exit code 1) 04===SORRY!04=== Error while compiling /tmp/eFSAPiFHek
Method 'BUILD' must be resolved by class C because it exists in multiple roles (A, B)
at /tmp/eFSAPiFHek:1
Xliff Tricky because I sometimes have need for an object to be created from either role A or role B. A few objects must do both for functionality's sake. 22:27
xinming in Proc::Async.new: blabla 22:29
my $sed = Proc::Async.new: 'sed', '-e', 's/xxx/yyy/g'; $sed.bind-stdin($*IN); await $sed.start; <--- How can this promise to be Kept when the $*IN is closed by external program? Or, what is the right way to close the $*IN ? 22:30
hmm, Ignore me, this example works, the problem is, when I add something like $sed.stdout.lines.map(...) broke the code 22:33
the $sed.stdout.lines.map(...) will hang the script, what caused that please? 22:34
jnthn I'd need to see how you're consuming that supply to help 22:36
xinming my $sed = Proc::Async.new: 'sed', '-e', 's/xxx/yyy/g'; $sed.bind-stdin($*IN); $sed.stdout.lines.map({ $_ }); await $sed.start; 22:37
jnthn: I changed $sed.stdout.lines... to $sed.stdout.tap(-> $_ { ... }); worked fine. 22:38
I just curious why with stdout.lines will pause the script.
jnthn Because you don't consume the data 22:40
And it won't fire the process exit supply until the stdout/stderr were cosumed
Otherwise you could easily get data loss
Sorry, process exit *promise* 22:41
22:44 xinming left, xinming joined 22:50 sarna left 22:53 sarna joined 23:00 chloekek left, xinming left 23:02 xinming joined 23:03 rindolf left 23:27 reach_satori joined 23:30 wamba joined 23:33 Altai-man_ joined 23:36 kensanata left, sena_kun left 23:46 lucasb left