🦋 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.
Geth_ ecosystem/JJ-patch-10: 0d0f8b0c5c | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | META.list
RE-adds Lingua::En::Stem::Porter
08:11
ecosystem: JJ++ created pull request #501:
RE-adds Lingua::En::Stem::Porter
Geth_ ecosystem: 0d0f8b0c5c | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | META.list
RE-adds Lingua::En::Stem::Porter
08:34
ecosystem: 941ea46dc0 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | META.list
Merge pull request #501 from Raku/JJ-patch-10

RE-adds Lingua::En::Stem::Porter
sarna hello! how do I check if a thing is present in a Seq? `contains`? 08:39
oh, contains is a trap probably :) 08:40
∈ is what I wanted 08:42
sarna m: my @foo = [[1,2,3],[4,5,6]]; my @bar = @foo.shift; say @bar 09:06
camelia [[1 2 3]]
sarna how to get `[1,2,3]`? 09:07
m: my @foo = [[1,2,3],[4,5,6]]; my @bar := @foo.shift; say @bar
camelia [1 2 3]
sarna this works, but is it The Way?
luk_v m: my @foo = [[1,2,3],[4,5,6]]; my @bar = |@foo.shift; say @bar 09:11
camelia [1 2 3]
sarna thanks :) 09:13
MasterDuke m: my @foo = [[1,2,3],[4,5,6]]; my @bar = @foo.shift.list; say @bar # also works with `.[]` and `.<>` 09:19
camelia [1 2 3]
sarna neat! that's more readable, imo 09:31
MasterDuke or `.self` 09:32
sarna weird, why would .self help here? 09:33
m: say [[[1]]].self 09:34
camelia [1]
sarna whew
sarna m: my @foo = [1,2,3]; my @bar = [4,5,6]; say @foo.grep: * > 1; say @foo.grep: * > 1 && * ∉ @bar; # what the hell? 09:57
camelia (2 3)
(1 2 3)
MasterDuke can't use * twice in an expression to refer to the same thing 09:59
sarna oh.. welp
I wrapped it in a block - is that the preferred solution?
MasterDuke and then changed to $_? yep 10:00
sarna yeah
thanks, it was so hard to debug :(
can I name the thing instead of referring to `$_`? 10:01
like, `@bar.grep -> $foo { $foo > 1 }`
sarna m: my @foo = [1,2,3]; my @bar = [4,5,6]; say @foo.grep: -> $baz {$baz > 1 && $baz ∉ @bar}; 10:03
camelia (2 3)
sarna woohoo!
tbrowder hip 10:18
hooray
i need some regex help, please 10:19
lizmat hopes moritz will be triggered by this :-) 10:20
tbrowder hi, lizmat
lizmat tbrowder o/
tbrowder i need a token that considers this false: '#=x' but either of these true: 10:23
'#=' or '#= '
jnthn tbrowder: Something like: '#=' <![x]> ' ' (well, or whatever appropriate kind of whitespace you want) 10:25
Uh, ' '? on the end there
But you probably don't want a literal space
tbrowder yes, a trailing decl line. the bare '#=' on a line is the problem.
the 10:26
i should have shown the second true token as '#=\h \N*' 10:28
jnthn, i hadn't thought of that, thnx, food to chew on! 10:30
bye 10:34
tbrowder hm, the problem is the token has to be considered as anchored before a \n 10:44
tbrowder i think i 10:58
mumble... 11:00
tbrowder i wonder if i need a back look somehow. 11:20
either "#= \h \N*" or "#=" 11:22
include the "#=" in the alternation...that hasn't been tried yet 11:23
moritz look-aheads are OK, but if I were you, I'd try *really* hard to avoid look-behinds 11:31
tbrowder roger! 11:54
i'm not doing that...yet...still some new thoughts triggered by jnthn 11:55
tbrowder |o| yea! 3 pts, not enough square brackets was apparent problem!! 12:07
later, thnx all 12:08
ThomBoyer docs.raku.org frequently mentions `truthy` and `falsy`, and sometimes `truish`. They're not in the glossary, and I can't find proper definitions anywhere on the site. Is there one somewhere? 12:26
moritz ThomBoyer: it means "true when evaluated in a boolean context" 12:29
like 0 is falsy and 1, 2, 3 are truthy
ThomBoyer Right. But even class Bool doesn't define what's true in a boolean context.
moritz ThomBoyer: it would be great if you could add it to the docs
right, that's under the sovereignty of the objects in question 12:31
Int defines it for Int, Str for Str and so on
ThomBoyer I'd summarize as: A value is falsy if it's Bool::True, a Numeric equal to zero, or an empty container of a built-in type (Str, Hash, etc). For non-builtin classes, it's whatever its `.Bool` method says 12:34
Is that accurate?
ThomBoyer That's pretty close to Perl5's definition, except that "0" seems to be different from Perl 5. Which led me to search out a more precise definition. 12:36
moritz it's Bool::False 12:39
otherwise pretty good
also, type objects are falsy as well
ThomBoyer Heh. Yeah. I sure _hope_ True isn't falsy. :-)
And I'd forgotten the type-object thing. Ok. Thanks, moritz. 12:40
moritz well, those Raku people... :D 12:42
sarna rakudoers? rakuists? 12:45
sarna opens an issue in the problem-solving repo
moritz rakutos :D 12:47
lizmat www.reddit.com/r/rakulang/ uses "Rakoons" 12:51
which we now have 500+ of :-)
afk for a few hours&
sarna "rakoons" is awesome! 12:52
tbrowder "rakutos like fritos" we should get with frito-lay marketing 13:02
sarna the only programming language with their own chips! 13:06
except forth and lisp
by the way, I've been thinking about this `self` stuff.. why does it "unpack" the nested thing? I mean it's cool, but how does that work? 13:07
m: say [[[[[[1]]]]]] # I mean this
camelia [1]
jnthn That's nothing to do with `self`, but rather the single argument rule
sarna okay what, I forgot .self and it did the same thing 13:08
jnthn: where can I read about it? I saw a comment on reddit but I didn't fully grasp it yet :(
jnthn docs.raku.org/language/list#index-...ument_Rule
sarna I read this one already, but this time I'll follow up with the p6advent article. maybe it will click now :) thanks 13:12
oh darn, so everything unpacks stuff like [[[1]]] automatically.. so I don't need the `self`! nice 13:27
melezhik I am thinking about usability of repo.westus.cloudapp.azure.com/hub/ for Raku community. Do people any command tools on daily basis? I am thinking about Raku related utils or whatever ... 16:08
melezhik usability -> usefullness 16:10
[Coke] is there any discussion before adding things to the community modules group? 16:24
konvertex Damn, transforming cross products and a shaped array into nested loops and an regular old array brought my 20s runtime down to 4.5s. 18:42
Has anyone compiled a list that compares/benchmarks similar lang constructs yet?
The crystal peeps have a lot of these, for example: 18:43
String.build 597.57k ( 1.67µs) (± 5.52%) fastest
IO::Memory 423.82k ( 2.36µs) (± 3.76%) 1.41× slower
tbrowder raku taco
with grammar sauce 18:44
tbrowder being of advanced age i would like to see a way for my modules to be in a group repo some place i could still mantain while able, but easily able to quietly go away and leave it to others if they are interested 18:48
guifa tbrowder: I think that’s the idea of the community modules 18:58
SmokeMachine is there a easy way of running only 1 test on comma? 19:00
tbrowder so should i start moving them over or what? i haven’t looked closely but do they designate a primary maintainer? etc.
guifa tbrowder: I’m not actually entirely sure. I know there has been some talk about how to handle things following DrForr’s passing. I admit I’ve been a bit out of the loop 19:02
cpan-raku New module released to CPAN! Tomtit (0.1.7) by 03MELEZHIK 19:17
SmokeMachine how can I set the test root? 19:35
on comma
tbrowder melezhik: i would like to be able to run a cron job to use it every so often for selected modules if that can be done easily. or even my rakudo branches 19:41
tellable6 tbrowder, I'll pass your message to melezhik
melezhik I wrote a short article on how one could easy test Raku cli applications shipped as Raku modules using RakuDist - sparrowdo.wordpress.com/2020/06/06...s-testing/ 20:54
tellable6 2020-06-05T19:41:33Z #raku <tbrowder> melezhik: i would like to be able to run a cron job to use it every so often for selected modules if that can be done easily. or even my rakudo branches
melezhik .tell tbrowder are you talking about testing modules with RakuDist? 20:56
tellable6 melezhik, I'll pass your message to tbrowder
tbrowder yes, but pushed from my local host. including rakudo branches if possible. 20:59
melezhik to run RakuDist jobs one could use HTTP API - github.com/melezhik/RakuDist/blob/...ueue-build 21:01
are you branches available from github.com/rakudo/rakudo/commits/ ?
if so, you can also use specific sha to point a certain branch (commit)
it all would work if your modules are hosted on github/gitlab 21:03
not sure if this is what you need ...
but basically you'd start with a following request (just an example) - `curl -d thing=github.com/Kaiepi/p6-Kind sha=f0594084e88e3d36bdcbc220989c7c823233876b rakudist.raku.org/queue` 21:05
SmokeMachine m: sub a(*%bla) { dd |%bla }; a :1a, :2b # is that expected? 21:38
camelia :a(1)
:b(2)
SmokeMachine oh! that's different from my mCHINE... 21:39
*machine
lizmat yeah, that looks valid to me 21:41
tbrowder melezhik: erg, more trouble than it's worth for me now for local. but maybe for stuff on github. on my Todo 23:43
p
tellable6 tbrowder, I'll pass your message to melezhik
tbrowder list. ;-) 23:43