🦋 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 aborazmeh joined, aborazmeh left, aborazmeh joined 00:09 pecastro left 00:15 tejr left 00:16 tejr joined 00:40 [Sno] joined 00:41 sno left 00:43 defaultxr left 00:53 defaultxr joined 00:58 gordonfish left, gordonfish joined 00:59 Kaeipi left 01:00 Kaeipi joined 01:17 BenGoldberg joined 01:22 BenGoldberg left 01:23 BenGoldberg joined 01:29 leont left 01:42 rir left
cpan-raku New module released to CPAN! Sparrowdo (0.1.12) by 03MELEZHIK 01:51
02:05 BenGoldberg left, Ben_Goldberg joined, Ben_Goldberg is now known as BenGoldberg 02:09 molaf left 02:13 guifa left 02:21 molaf joined 02:39 Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 03:01 fridim_ joined 03:03 fridim left 03:06 Manifest0 left, Manifest0 joined 03:10 Kaeipi left, Kaeipi joined 03:16 silug left, silug joined 03:19 BenGoldberg left, Ben_Goldberg joined, Ben_Goldberg is now known as BenGoldberg 03:30 ape666 joined 03:31 guifa joined 03:33 ape666 left, ape666 joined
guifa Internally, are there any optimizations if all the givens/when statements are integers or no? 03:36
04:01 perlbot left 04:03 simcop2387 left 04:31 ape666 left 04:36 perlbot joined, simcop2387 joined 04:38 BenGoldberg left, Ben_Goldberg joined, Ben_Goldberg is now known as BenGoldberg 04:47 ape666 joined 04:48 BenGoldberg left 04:51 ape666 left 05:02 aluaces joined 05:17 Doc_Holliwould joined 05:36 vrurg left 05:49 vrurg joined 05:55 sena_kun joined
timotimo not yet 06:20
06:25 a3r0 left 06:26 a3r0 joined 06:46 bocaneri joined 06:49 parabolize left
Geth_ doc/list-rotate: 3688a59670 | (Stoned Elipot)++ | doc/Type/List.pod6
List.rotate returns a Seq since Rakudo 2020.06

ref #3495
While here flesh out a bit the routine description and adopt a more common example style.
06:54
doc: stoned++ created pull request #3688:
List.rotate returns a Seq since Rakudo 2020.06
06:55
06:56 natrys joined 07:01 molaf left, ufobat_ joined, sjm_uk joined 07:04 imcsk8 left 07:05 imcsk8 joined 07:08 jmerelo joined 07:18 chris joined 07:19 chris is now known as Guest27337, Guest27337 left 07:22 roguelazer_ joined, roguelazer left, roguelazer_ is now known as roguelazer 07:23 aborazmeh left 07:27 abraxxa left 07:29 Doc_Holliwould left 07:32 abraxxa joined 07:54 domidumont joined 07:56 BenGoldberg joined 07:57 stoned75 left 07:58 wamba joined
Geth_ doc: 7ed6b35e6d | (Stoned Elipot)++ (committed by Juan Julián Merelo Guervós) | doc/Type/List.pod6
List.rotate returns a Seq since Rakudo 2020.06

ref #3495
While here flesh out a bit the routine description and adopt a more common example style.
07:59
linkable6 Link: docs.raku.org/type/List
linkable6 DOC#3495 [open]: github.com/Raku/doc/issues/3495 [checklist][docs] Checklist for 2020.06
08:02 stoned75 joined 08:04 skids left, kensanata joined 08:06 rindolf joined, aluaces left 08:09 Altai-man joined 08:12 sena_kun left 08:13 kensanata left 08:16 kensanata joined 08:25 codesect` left 08:27 stoned75 left 08:29 BenGoldberg left 08:39 dakkar joined 08:51 andreoss joined
andreoss m: subset Book where *.^lookup: 'isbn'; 08:56
camelia ( no output )
andreoss is there a better way to write that? especially if I want to check of method's signature? 08:57
timotimo i believe you can use can or cando for this purpose, though that is probably on a routine rather than a class 08:59
09:09 abraxxa left 09:10 abraxxa joined
andreoss is it possible to place an anonymous trait somewhere? i.e `where * ~~ role { ... }`? 09:14
09:15 leont joined, Sgeo left
timotimo that will not do what you expect :) 09:16
it will match against this exact role, not by shape, but by identity
09:18 MasterDuke joined, pecastro joined
andreoss thanks. btw, why it's impossible to augment subsets? `subset Book ... { ...more methods here... }` 09:24
timotimo not possible i'm afraid
subsets are really just a matcher on top of an existing class 09:25
all the methods and attributes and such come only from the existing class / type
the matcher only changes how type checks act
09:31 aluaces joined
andreoss i see, ^add_method does not work either 09:33
but you can call ^add_method inside `where` block, hmm 09:37
09:39 guifa` left 09:40 stoned75 joined 09:51 schlaftier left 09:53 xinming left, xinming joined 09:57 frost-lab joined
timotimo that operates on the whole type of whatever you're passing in 10:01
so if it's the exact class you're subtyping that will get the method, if it's a subclass, that will get the method
10:02 [Sno] left 10:05 rindolf left 10:07 schlaftier joined 10:12 rindolf joined 10:21 stoned75 left 10:25 jhill left, skaji_ left 10:27 jhill joined 10:28 skaji_ joined 10:37 pecastro left
cpan-raku New module released to CPAN! Log::Colored (0.1.2) by 03TYIL 10:39
tyil been a while since cpan-raku highlighted me :'D 10:41
lizmat :-) 10:43
tyil jjatria: while I'm here, your RSS feed doesn't include a protocol in the links, which makes it not open the post on my rss reader (nextcloud) 10:44
and lastly
jmerelo: is it intended for the rakudo-star docker image to no longer come with zef? 10:45
(gitlab.com/tyil/perl6-app-assixt/-...3116#L301, zef not found error, goes away when I use a personal image where I'm sure zef is available) 10:46
10:49 fridim_ left, fridim joined 11:11 stoned75 joined 11:13 andreoss left 11:20 BenGoldberg joined 11:26 Kaeipi left 11:27 Kaiepi joined 11:36 [Sno] joined 11:39 [Sno] left
JJAtria[m] tyil: Ha! Thanks. Well spotted 11:40
I might have to spend some time looking at whatever Jekyll plugin I used for that, but I'm leaning heavily towards moving away from Jekyll entirely at some point, so maybe that is the catalyst? 11:41
11:42 sno joined
tyil my blog is using jekyll too, you can look at that for inspiration if you want to keep using jekyll 11:43
11:45 stoned75 left, MasterDuke left 11:47 aborazmeh joined, aborazmeh left, aborazmeh joined
JJAtria[m] tyil: Thanks, I'll take a look. It's definitely going to be faster than "port whole site to different static generator" 11:50
11:52 tejr left, tejr joined 11:54 harrison joined 11:55 BenGoldberg left
harrison p6: say now - init now; 11:55
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
init used at line 1. Did you mean 'INIT'?
harrison p6: say now - INIT now; 11:56
camelia 0.00110829
harrison say #`foo "bar"; 11:58
p6 say #`foo "bar";
p6: say #`foo "bar";
camelia 5===SORRY!5=== Error while compiling <tmp>
Opening bracket required for #` comment
at <tmp>:1
------> 3say #`7⏏5foo "bar";
harrison p6: say #`(foo) "bar"; 11:59
camelia bar
harrison p6: say #`(foo) "bar" #`(baz); 12:00
camelia bar
harrison p6: say int.WHAT;
camelia (int)
harrison p6: say int ~~ Int;
camelia True
harrison p6: my @a = | 1..3; say @a; 12:02
camelia Potential difficulties:
To apply a Slip flattener to a range, parenthesize the whole range.
(Or parenthesize the whole endpoint expression, if you meant that.)
at <tmp>:1
------> 3my @a = 7⏏5| 1..3; say @a;
[1 2 3]
harrison p6: my @a = | (1..3); say @a;
camelia [1 2 3]
harrison p6: my @a = (1..3); say @a;
camelia [1 2 3]
harrison p6: my @a = R[\] (1..3); say @a;
camelia 5===SORRY!5=== Error while compiling <tmp>
You can't backslash that
at <tmp>:1
------> 3my @a = R[\7⏏5] (1..3); say @a;
expecting any of:
list composer
prefix
term
harrison p6: say [\] (1..3); 12:03
camelia 5===SORRY!5=== Error while compiling <tmp>
You can't backslash that
at <tmp>:1
------> 3say [\7⏏5] (1..3);
expecting any of:
prefix
term
harrison p6: say [] (1..3);
camelia 5===SORRY!5=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> 3say []7⏏5 (1..3);
expecting any of:
infix
infix stopper
postfix
statement end
statement modifier…
harrison p6: say [+] (1..3);
camelia 6
12:03 cpan-raku left
harrison p6: say [*] (1..3); 12:03
camelia 6
12:04 cpan-raku joined, cpan-raku left, cpan-raku joined
harrison p6: say "\x0062"; 12:04
camelia b
harrison p6: say "\c[WHITE SMILLING FACE]"; 12:05
camelia 5===SORRY!5=== Error while compiling <tmp>
Unrecognized character name [WHITE SMILLING FACE]
at <tmp>:1
------> 3say "\c[WHITE SMILLING FACE7⏏5]";
harrison p6: say "\c[WHITE SMILING FACE]";
camelia
harrison p6: say ⅒.WHAT; 12:06
camelia (Rat)
harrison p6: say ⅒ * 10;
camelia 1
12:10 sena_kun joined 12:12 Altai-man left 12:42 frost-lab left 12:52 kensanata left 12:54 pecastro joined, ufobat__ joined 12:58 ufobat_ left 13:00 pecastro left
harrison p6: say ⅒.WHAT.methods; 13:00
camelia No such method 'methods' for invocant of type 'Rat'
in block <unit> at <tmp> line 1
13:00 pecastro joined
harrison p6: say ⅒.WHAT.^methods; 13:01
camelia (Rat FatRat new nude Num floor ceiling Int Bridge Range isNaN is-prime base base-repeating succ pred norm narrow abs sign conj sqrt rand sin asin cos acos tan atan atan2 sec asec cosec acosec cotan acotan sinh asinh cosh acosh tanh atanh sech asech co…
harrison p6: say (⅒.WHAT.^methods); 13:02
camelia (Rat FatRat new nude Num floor ceiling Int Bridge Range isNaN is-prime base base-repeating succ pred norm narrow abs sign conj sqrt rand sin asin cos acos tan atan atan2 sec asec cosec acosec cotan acotan sinh asinh cosh acosh tanh atanh sech asech co…
harrison p6: (⅒.WHAT.^methods).>>say;
camelia 5===SORRY!5=== Error while compiling <tmp>
Missing dot on method call
at <tmp>:1
------> 3(⅒.WHAT.^methods).>>7⏏5say;
expecting any of:
postfix
harrison p6: (⅒.WHAT.^methods).>>(say);
camelia 5===SORRY!5=== Error while compiling <tmp>
Unsupported use of bare "say". In Raku please use: .say if you meant
to call it as a method on $_, or use an explicit invocant or argument,
or use &say to refer to the function as a noun.
at <tmp…
harrison p6: (⅒.WHAT.^methods).>>(&say);
camelia Rat&say
FatRat&say
new&say
nude&say
Num&say
floor&say
ceiling&say
Int&say
Bridge&say
Range&say
isNaN&say
is-prime&say
base&say
base-repeating&say
succ&say
pred&say
norm&say
narrow&say
abs&say
sign&say
conj&say…
lizmat clickbaits rakudoweekly.blog/2020/11/09/2020-...-serviced/
13:04 molaf joined 13:06 squashable6 left, squashable6 joined 13:07 stoned75 joined 13:13 tejr left 13:19 tejr joined 13:20 jmerelo left 13:28 thundergnat joined
thundergnat m: put Rat.^methods(:local)>>.gist.sort 13:28
camelia ACCEPTS Bool Bridge Complex DUMP FatRat Int Num Numeric Range Rat Real Str Submethod+{is-hidden-from-backtrace}.new WHICH abs acos acosec acosech acosh acotan acotanh asec asech asin asinh atan atan2 atanh base base-repeating ceiling cis conj cos cose…
tellable6 2020-11-05T13:02:10Z #raku <perryprog> thundergnat Thank you!
13:28 thundergnat left 13:32 stoned75 left 13:35 stoned75 joined 13:37 pecastro left 13:54 aborazmeh left 14:02 harrison left 14:03 aindilis left 14:06 hal99999 joined
tib Hello, what are the key features of the Rakudo compiler except being able to compile Raku and precompilation ? I can't find any list (rakudo.org/docs points to the manual page github.com/rakudo/rakudo/blob/master/README.md that does not have this infos). I found this web.archive.org/web/20150801100611/...s/features but it is mainly "Rakudo is able to compile full Raku" (which is already great). Maybe the answer i 14:08
dakkar your message got truncated at "maybe the answer" (IRC doesn't like long messages) 14:11
[Coke] your send cut of at "answer i"
dakkar++
dakkar (also I don't understand the question)
[Coke] Can you give an example of the kind of feature you mean? 14:13
(e.g. from another compiler?)
tib a page like this : www.moarvm.org/features.html but for rakudo
The end of my message was : Maybe the answer is "there is not" 😃 just asking 14:14
dakkar I mean, a compiler… compiles
that's the only thing it does
tib ok, any optims ?
14:15 jmerelo joined
[Coke] Rakudo is implementing the Raku language... so yes, the language features is what you want. 14:15
tib ok, thank you a lot 14:16
[Coke] there's really no other compiler to compare it to at this point if you're looking for "why use rakudo instead of <other compiler>"
14:30 wamba left 14:36 parabolize joined 14:46 BenGoldberg joined 14:49 squashable6 left 14:52 squashable6 joined 14:54 BenGoldberg left, Ben_Goldberg joined, Ben_Goldberg is now known as BenGoldberg 14:56 Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 14:58 Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 15:00 Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 15:01 hal99999 left 15:10 reisinge joined 15:18 Sgeo joined 15:19 wamba joined, BenGoldberg left 15:30 MasterDuke joined, reisinge left 15:37 molaf left 15:39 Doc_Holliwould joined 15:44 squashable6 left 15:45 squashable6 joined, squashable6 left 15:48 squashable6 joined 15:53 abraxxa left 15:54 abraxxa joined, pecastro joined, abraxxa left 15:56 __jrjsmrtn__ left, __jrjsmrtn__ joined 16:00 abraxxa joined 16:04 pecastro left 16:05 pecastro joined 16:09 Altai-man joined 16:12 sena_kun left, pecastro left 16:14 pecastro joined 16:18 Doc_Holliwould left 16:20 abraxxa left 16:21 hal99999 joined 16:25 MilkmanDan left 16:27 abraxxa joined
guifa timotimo: alright thanks. Trying to improve load times on CLDR — was using given + when ‘longString’ and have cut it down to given + when int. In most cases, it’s under 12 items, so I can probably self-optimize with if/thens, unless arrays of code blocks would be even faster 16:29
16:46 Kaiepi left
MasterDuke m: my $a; $a = do given $_ { when 3 { "three" }; when 5 { "five" }; default { "default" } } for ^1_000_000; say now - INIT now; say $a 16:49
camelia 4.25276669
default
MasterDuke m:
m: my $a; $a = do given $_ { if $_ == 3 { "three" } elsif $_ == 5 { "five" } else { "default" } } for ^1_000_000; say now - INIT now; say $a
camelia 0.7213009
default
16:50 Kaiepi joined
guifa MasterDuke: wow, that’s even more a speed reduction that I expected 16:51
guifa hasn’t started writing the new decoding code yet…. have to finish the encoding code 16:52
MasterDuke the `when`s compile to a chain of ACCEPT method calls, the `if`s to a chain of...drumroll please...`if`s 16:53
seems like some optimizations could be possible
16:54 molaf joined
guifa MasterDuke: I think the catch is that ~~ is not always the same as eq and ==, so I’m not sure if you can make that assumption 16:55
MasterDuke correct, but i bet something could be done in some cases 16:58
16:58 mowcat joined
guifa let’s see how this one does 16:59
m: my @options = {“zero”}, {“one”}, {“two”}, {“three”}, {“four”}, {“five”}; my $time = now; my $a; $a = (@options[6.rand.floor] // {"default"})() for 1_000_000; say now - $time; say $a;
camelia 0.00183585
one
guifa wow
err 17:00
I missed a ^
my @options = {“zero”}, {“one”}, {“two”}, {“three”}, {“four”}, {“five”}; my $time = now; my $a; $a = (@options[7] // {"default"})() for ^1_000_000; say now - $time; say $a;
evalable6 0.780211
default
guifa m: my @options = {“zero”}, {“one”}, {“two”}, {“three”}, {“four”}, {“five”}; my $time = now; my $a; $a = (@options[3] // {"default"})() for ^1_000_000; say now - $time; say $a; 17:01
camelia 0.3417322
three
guifa m: my @options = {“zero”}, {“one”}, {“two”}, {“three”}, {“four”}, {“five”}; my $time = now; my $a; $a = (@options[$_] // {"default"})() for ^1_000_000; say now - $time; say $a; 17:03
camelia 1.2759247
default
17:05 mowcat left, mowcat joined 17:09 abraxxa left 17:10 Doc_Holliwould joined 17:11 abraxxa joined 17:12 Kaiepi left 17:15 Kaiepi joined 17:19 natrys left 17:40 dakkar left 17:59 MasterDuke left 18:09 Doc_Holliwould left 18:10 skids joined, Doc_Holliwould joined 18:11 BenGoldberg joined 18:14 kylese joined, Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 18:25 BenGoldberg left, Ben_Goldberg joined, Ben_Goldberg is now known as BenGoldberg 18:45 BenGoldberg left 18:55 Doc_Holliwould left, zxcvz joined 18:56 domidumont left 18:58 Doc_Holliwould joined 19:15 MasterDuke joined 19:21 bocaneri left 19:24 Black_Ribbon joined 19:27 jmerelo left 19:29 guifa` joined 19:38 kylese left
cpan-raku New module released to CPAN! Test::Async (0.0.16) by 03VRURG 19:39
19:41 hal99999 left 19:48 aborazmeh joined, aborazmeh left, aborazmeh joined 19:49 abraxxa left 19:52 hal99999 joined 19:58 kensanata joined 20:02 defaultxr left 20:06 MilkmanDan joined, Doc_Holliwould left 20:08 defaultxr joined 20:09 abraxxa joined 20:10 sena_kun joined 20:12 Altai-man left 20:17 aborazmeh left 20:32 zxcvz left 21:08 kensanata left 21:12 mowcat left 21:17 hoelzro left, wmoxam left 21:18 rjbs left 21:19 ufobat__ left 21:22 sjm_uk left
JJAtria[m] tyil: The feed should be sorted now :D 21:28
tyil JJAtria[m]: cool, thanks!
21:29 mendel left, MilkmanDan left 21:31 MilkmanDan joined 21:36 BenGoldberg joined
El_Che !seen patrickbr 21:37
seen patrickbr 21:38
.seen patrickbr
tellable6 El_Che, I haven't seen patrickbr around, did you mean patrickb?
El_Che .seen patrickb
tellable6 El_Che, I saw patrickb 2020-11-06T21:21:02Z in #raku-dev: <patrickb> \o
21:38 MasterDuke left 21:39 rjbs joined
El_Che .tell patrickb I saw your mention on the github ticket, but I hadn't had the time to read it. Just moved and right away started demolishing walls and rooms on the old place. Tired :) 21:39
tellable6 El_Che, I'll pass your message to patrickb
21:42 wmoxam joined
Geth_ doc/supply-rotate: cd1001227a | (Stoned Elipot)++ | doc/Type/Supply.pod6
Add Supply.rotate
21:46
doc: stoned++ created pull request #3689:
Add Supply.rotate
21:47
22:03 wamba left 22:10 BenGoldberg left 22:11 MilkmanDan left 22:18 rindolf left 22:32 squashable6 left 22:33 squashable6 joined 22:41 grumble left 22:42 sena_kun left 22:43 stoned75 left, grumble joined 22:57 hal99999 left 23:21 eater joined
MitarashiDango[m Exercism has asked for programming language feature highlights. If anyone has input for Raku it would be appreciated: github.com/exercism/v3/issues/2763 23:23
23:31 skids left 23:35 MilkmanDan joined 23:39 eater left
timotimo hmm. malleable? reactive? (with react/supply/whenever) something with glue, like having Inline::Python and Inline::Perl5 23:42
23:56 eater joined 23:58 eater left