🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel! Set by lizmat on 6 September 2022. |
|||
00:00
codesections joined
00:07
reportable6 left
00:08
reportable6 joined
00:14
Kaiepi left
00:38
mahafyi left
01:04
doomvox joined
01:07
jjido left
01:09
doomvox left
01:13
codesections left,
codesections joined
01:22
ToddAndMargo joined
|
|||
ToddAndMargo | I can't find my booboo: vpaste.net/ngl1h | 01:22 | |
raku PopUpTest.pl6 | |||
===SORRY!=== Error while compiling K:\Windows\NtUtil/PopUpTest.pl6 | |||
Unable to parse expression in argument list; couldn't find final ')' (corresponding starter was at line 167) | |||
at K:\Windows\NtUtil/PopUpTest.pl6:168 | |||
------>Â Â Â DWORD<HERE> $dwProcessId, | |||
------>Â Â Â DWORD<HERE> $dwProcessId, | 01:23 | ||
   expecting any of: | |||
       infix | |||
       infix stopper | |||
01:25
codesections left,
codesections joined
01:38
derpydoo joined
|
|||
Guest78 | BOOL ProcessIdToSessionId( | 01:38 | |
 [in] DWORD dwProcessId, | |||
 [out] DWORD *pSessionId | |||
ToddAndMargo | That is C++ code | 01:40 | |
Guest78 | yep | ||
#`{ | 01:42 | ||
ProcessIdToSessionId function (processthreadsapi.h) | |||
learn.microsoft.com/en-us/windows/...osessionid | |||
C++ | |||
BOOL ProcessIdToSessionId( | |||
 [in] DWORD dwProcessId, | |||
 [out] DWORD *pSessionId | |||
} | |||
01:42
frost joined
|
|||
Guest78 | there is no ) before } | 01:42 | |
ToddAndMargo | not seeing it | 01:47 | |
01:48
derpydoo left
|
|||
Guest78 | vpaste.net/99s1a | 01:49 | |
does it work now? | |||
02:02
codesections left,
derpydoo joined
02:03
codesections joined
|
|||
Guest78 | ToddAndMargo did the new file work? | 02:23 | |
avuserow | [ | 02:26 | |
SmokeMachine | .tell guifa I've been playing with the idea of matching RakuAST and saw that could work for any object (like your objex). it's far from ok yet and I plan writing a slang to make that look like grammar and also accept actions, but do you have any opinion about that? usercontent.irccloud-cdn.com/file/.../image.png | 02:27 | |
tellable6 | SmokeMachine, I'll pass your message to guifa | ||
SmokeMachine | .tell guifa on this case, TOP is not special and any method inside the "grammar"would be searched on the ast/object tree... | 02:28 | |
tellable6 | SmokeMachine, I'll pass your message to guifa | ||
02:28
epony left
|
|||
SmokeMachine | .tell any method with `is matcher`while there is no slang... | 02:30 | |
tellable6 | SmokeMachine, I haven't seen any around, did you mean aye? | ||
SmokeMachine | .tell any, sorry, wrong nick | ||
tellable6 | SmokeMachine, I haven't seen any around, did you mean aye? | ||
SmokeMachine | .tell guifa any method with `is matcher`while there is no slang... | ||
tellable6 | SmokeMachine, I'll pass your message to guifa | ||
02:39
tirnanog left
02:45
razetime joined
02:57
mahafyi joined
|
|||
Guest78 | hey guys | 03:06 | |
03:22
codesections left
03:23
codesections joined
03:25
ToddAndMargo left
03:41
euandreh left
03:57
euandreh joined
04:00
euandreh left
04:03
euandreh joined
04:08
derpydoo left
04:09
codesections left,
codesections joined
04:24
codesections left,
codesections joined,
codesections left
04:25
codesections joined
04:27
codesections left,
codesections joined
04:30
codesections left,
codesections joined
04:43
razetime left
05:26
Guest78 left
05:31
ToddAndMargo joined
|
|||
ToddAndMargo | Found it! I forgot the stinkin' `sub`. Bad `ProcessIdToSessionId(`; corrected `sub ProcessIdToSessionId(`   AAAAHHHHH!!!!! | 05:32 | |
05:49
dpk left
05:50
camelia left,
dpk joined,
gfldex left,
gfldex joined
06:08
reportable6_ joined
06:10
reportable6 left
06:59
squashable6 left
07:00
squashable6 joined
07:01
jmcgnh left
07:09
jmcgnh joined
07:12
daxim left
07:13
kaskal left,
mahafyi left
07:22
equinox joined
07:33
ToddAndMargo left
07:45
abraxxa joined
07:50
abraxxa left,
abraxxa joined
07:51
camelia joined
08:02
Sgeo left,
Kaiepi joined
08:28
jjido joined
08:56
daxim joined
|
|||
Nemokosch | why does :kv flatten the values? | 09:15 | |
say you have { a => (1, 2, 3), b => (4, 5, 6) } | |||
the kv version of this would be something like ('a', 1, 2, 3, 'b', 4, 5, 6) | |||
eh damn, it's not this easy to reproduce... | 09:17 | ||
well then, I will be back once I pinpointed what went wrong for me | |||
what I can quickly guess is that this has something to do with itemization | 09:19 | ||
which in turn might have something to do with constant Maps | |||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); dd $_ for %a.kv | 09:36 | |
camelia | "b" (4, 5, 6) "a" (1, 2, 3) |
||
lizmat | m: my constant %a = a => (1,2,3), b => (4,5,6); dd $_ for %a.kv | 09:37 | |
camelia | "a" (1, 2, 3) "b" (4, 5, 6) |
||
09:41
equinox left
09:42
Nemokosch joined
|
|||
Nemokosch | m: my constant %a = a => (1,2,3), b => (4,5,6); dd $_ for %a<>:kv | 09:43 | |
camelia | "a" 1 2 3 "b" 4 5 6 |
||
tellable6 | 2022-11-16T18:36:34Z #raku <El_Che> Nemokosch: I didn't pay attention who participated | ||
Nemokosch | aha! | ||
09:44
Nemokosch left
|
|||
lizmat | interesting | 09:58 | |
m: my %a = a => (1,2,3), b => (4,5,6); dd $_ for %a<>:kv | 09:59 | ||
camelia | "a" List %a = $(1, 2, 3) "b" List %a = $(4, 5, 6) |
||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); dd $_ for %a<>:kv | ||
camelia | "b" 4 5 6 "a" 1 2 3 |
||
lizmat | it's the Mappiness, not the constantness | 10:00 | |
10:00
jjido left
|
|||
Nemokosch | is this intended? seems quite odd to me | 10:03 | |
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); dd %a<> | ||
camelia | Map.new((:a((1, 2, 3)),:b((4, 5, 6)))) | ||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); dd %a | ||
camelia | Map.new((:a((1, 2, 3)),:b((4, 5, 6)))) | ||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); use nqp; dd nqp::iscont(%a) | ||
camelia | 0 | ||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); use nqp; dd nqp::iscont(%a<>) | 10:04 | |
camelia | 0 | ||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); say %a.kv.iterator | ||
camelia | Map::KV.new | ||
lizmat | m: my %a is Map = a => (1,2,3), b => (4,5,6); say %a.kv<>.iterator | ||
camelia | Map::KV.new | ||
lizmat | feels like an issue is in order | 10:05 | |
10:06
sena_kun joined
10:07
squashable6 left
10:09
squashable6 joined
|
|||
Nemokosch | is there a mutable interface to the values of a Hash, all at once? %hash.values[0] is a Scalar but %hash.values itself is a Seq, I can't just assign to that | 10:44 | |
10:45
jjido joined
|
|||
seems like %hash.values[*] does the trick 😄 | 10:46 | ||
> %options-left.values[*] X(-)= 10 | |||
I propose the concept of More Than Awesome | |||
How can this just work and do what I wanted to do... | 10:48 | ||
10:53
equinox joined
10:58
sena_kun left
10:59
sena_kun joined
11:04
codesections left
11:05
codesections1 joined
11:07
codesections1 is now known as codesections
|
|||
lizmat | m: my %h = a => 41, b => 136; $_++ for %h.values; dd %h | 11:07 | |
camelia | Hash %h = {:a(42), :b(137)} | ||
lizmat | the magic of containers! | ||
Nemokosch | yes, that one I knew, that's also pretty good | 11:08 | |
but this X(-)= 10 on a list of containers is just... out of this world | |||
and, of course not because of this "trickery" in particular, but my solution is actually pretty fast for the weeklies, up until 10-ish | 11:09 | ||
11:10
Nemokosch joined
|
|||
Nemokosch | .seen Util | 11:10 | |
tellable6 | Nemokosch, I saw Util 2022-08-07T20:57:04Z in #raku: <Util> lizmat: Thanks! | ||
Nemokosch | runs in around 6 seconds for n=12 | ||
Nemokosch | I wonder what Bruce has... o.O | 11:12 | |
11:12
Nemokosch left
|
|||
SmokeMachine | Nemokosch: why the `[*]` wouldn't it work without it? | 11:14 | |
tellable6 | SmokeMachine, I'll pass your message to Nemokosch | ||
SmokeMachine | m: my %a = a => 1, b => 2; %a.values X-= 1; say %a | ||
camelia | {a => 0, b => 1} | ||
Nemokosch | originally I didn't put X there and then it surely didn't work | 11:15 | |
SmokeMachine | m: my %a = a => set(1, 2, 3), b =>set( 2, 3, 4); %a.values X(-)= 2; say %a | ||
camelia | {a => Set(1 3), b => Set(3 4)} | ||
11:15
Nemokosch joined
|
|||
Nemokosch | okay, the solution runs in about a minute for n=15 | 11:15 | |
I'd say that's still acceptable for an actually exponential problem | 11:17 | ||
SmokeMachine | m: my %a = a => set(1, 2, 3), b =>set( 2, 3, 4); %a.values >>(-)=>> 2; say %a | ||
camelia | Cannot modify an immutable Bool (True) in block <unit> at <tmp> line 1 |
||
Nemokosch | m: my %a = a => set(1, 2, 3), b =>set( 2, 3, 4); %a.values = %a.values X(-) 2; say %a | ||
camelia | Cannot modify an immutable Seq ((Set(1 2 3) Set(2 3 4))) in block <unit> at <tmp> line 1 |
||
tellable6 | 2022-11-18T11:14:01Z #raku <SmokeMachine> Nemokosch: why the `[*]` wouldn't it work without it? | ||
Nemokosch | see? that was my original attempt and this failed | ||
actually, I'm not sure what sort of black magic makes X(-)= work, then | 11:18 | ||
in what order is this resolved? | |||
now I'm starting to think it's X[(-)=], I originally was thinking of [X(-)]= | 11:19 | ||
SmokeMachine | m: my %a = a => set(1, 2, 3), b => set( 2, 3, 4); say %a.values X(-) 2 # The problem is setting it back to values... | ||
camelia | (Set(3 4) Set(1 3)) | ||
SmokeMachine | X(-)= will set the value for each container returned by .values and not to the .values itself... | 11:21 | |
Nemokosch: `%a.values X(-)= 2` kinda is equivalent to `for %a.keys -> $key { %a{$key} (-)= 2 }` | 11:23 | ||
that's equivalent to `for %a.keys -> $key { %a{$key} = %a{$key} (-) 2 }` | 11:24 | ||
m: my %a = a => 10, b => 20; say %a.values = 1, 2 # but on the other hand | 11:25 | ||
camelia | Cannot modify an immutable Seq ((20 10)) in block <unit> at <tmp> line 1 |
||
Nemokosch | eventually, the result will be the same | 11:27 | |
I was thinking of less mutation on the way | |||
anyway, this explains why it worked in the first place :D thank you for the hints | 11:28 | ||
11:30
razetime joined
|
|||
Nemokosch | something that boggles me hard, though... | 11:44 | |
I compared my performance with other contenders and I noticed that someone who does something similar but way simpler, actually beats me like 5 to 1 | 11:45 | ||
without doing any .race | |||
I removed .race and suddenly my performance went a magnitude UP | |||
now N=15 runs in about 6 seconds | 11:46 | ||
what can be the takeaway of this? function calls are expensive with threading? | |||
that's the main thing I can think of, it's a recursive function after all | |||
11:57
Nemokosch left
12:07
reportable6_ left
12:09
reportable6 joined
|
|||
moritz | the first takeway is that you should always benchmark before and after optimizing :-) | 12:15 | |
the second is that .race is only good if each individual element takes long to process | 12:16 | ||
if instead you have very many elements that are somewhat quick to process, you might succeed by manually specifying a pretty big batch size | 12:17 | ||
Nemokosch | perhaps I should but that's never gonna happen for weekly challenge solutions 😛 | 12:28 | |
well, this was a branching recursion so probably it could have made sense to race over the first couple of levels and then just count them sequentially | 12:33 | ||
12:36
abraxxa left
|
|||
lizmat | weekly: dev.to/lizmat/its-time-to-rak-part-4-334i | 12:37 | |
notable6 | lizmat, Noted! (weekly) | ||
Nemokosch | nope, not worth it | 12:41 | |
12:59
codesections left
13:02
codesections joined
13:09
MasterDuke joined
13:22
mahafyi joined
13:29
equinox left
13:39
equinox joined
14:02
codesections left
14:15
lucasb joined
14:36
derpydoo joined
14:40
jjido left
14:49
tirnanog joined
15:00
tirnanog left
15:13
Guest16 joined
15:22
Sgeo joined
|
|||
[Coke] | RSC folks - can we get a linkedin post for the volunteer infra "job"? | 15:29 | |
Would help with finding candidates with devops background who are looking to volunteer. | 15:30 | ||
putting a copy on linked in will make it easier for me to get eyeballs on it, at least. | 15:31 | ||
vrurg | [Coke]: looks like a good idea. Could you mail it to [email@hidden.address] please? | 15:33 | |
[Coke]: looks like a good idea. Could you mail it to rsc@raku.org, please? | |||
Not everybody may follow IRC and my attention to this channel is rather accidental. | 15:34 | ||
[Coke] | Done. | 15:35 | |
vrurg | Thanks! | ||
15:44
jgaz joined
16:24
justGrit left
16:25
justache joined
16:30
justache left
16:31
justache joined
16:44
lucasb left
17:16
Maylay left
17:28
Maylay joined
17:31
jjido joined
17:32
mahafyi left
17:36
jgaz left
17:50
razetime left
18:07
reportable6 left,
reportable6 joined
18:48
epony joined
19:05
kaskal joined,
AdonisExberger joined,
AdonisExberger left
19:14
sgrs joined
19:23
jjido left
19:33
nicole left,
nicole joined
19:35
xinming left
19:37
xinming joined
19:44
equinox left
|
|||
guifa finally came up with a topic for Advent CAlendar | 20:04 | ||
tellable6 | 2022-11-18T02:28:30Z #raku <SmokeMachine> guifa on this case, TOP is not special and any method inside the "grammar"would be searched on the ast/object tree... | ||
2022-11-18T02:30:35Z #raku <SmokeMachine> guifa any method with `is matcher`while there is no slang... | |||
hey guifa, you have a message: gist.github.com/703c5e4af9ea8bf42a...ea29543e61 | |||
20:20
n1to joined
20:38
lucasb joined
20:45
euandreh2 joined
20:47
euandreh left,
euandreh2 is now known as euandreh
21:12
derpydoo left
21:18
discord-raku-bot left,
discord-raku-bot joined
21:22
discord-raku-bot left
21:41
samcv left,
samcv joined
22:00
frost left
22:08
xinming left
22:10
xinming joined
22:20
xinming left
22:27
euandreh left,
euandreh2 joined
22:29
euandreh2 is now known as euandreh
22:42
discord-raku-bot joined
22:44
discord-raku-bot left
22:52
discord-raku-bot joined
22:53
discord-raku-bot left,
discord-raku-bot joined
23:01
jgaz joined
|
|||
Geth | advent: cfc18acef5 | L'Alabameñu++ (committed using GitHub Web editor) | raku-advent-2022/authors.md Add guifa to author list |
23:03 | |
23:17
Guest16 left,
jjido joined
23:21
Kaiepi left
|
|||
Geth | advent: melezhik++ created pull request #98: parrowCI pipelines for everything |
23:23 |