🦋 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.
moon-child say I wanted to make + act the same as «+». Is there a better way than making 3 different multimethods for (Iterable, Iterable), (Iterable, any), (any, Iterable)? 01:06
moon-child how do I define my own metaoperator? I can't find any docs (except for a 15-year-old mailing list post) 04:00
elcaro moon-child: I don't think it's supported... at least not currently 04:02
If I recall... I think I know this from a talk Larry gave at a Racket conf. The vid's on YouTube
pretty sure at the end, someone asks if one can define their own meta-operators, and Larry says something along the lines of "not yet" 04:03
moon-child elcaro: ok
shame. I was hoping it would be possible to implement (most of) apl inside raku
elcaro regarding your earlier question.. this works, though I dunno if it's the best way 04:18
glot.io/snippets/fnw929r5bf
Geth doc: 31d1ecb96a | (JJ Merelo)++ | doc/Language/containers.pod6
Link description to class #3443
09:00
linkable6 Link: docs.raku.org/language/containers
DOC#3443 [open]: github.com/Raku/doc/issues/3443 [docs] The description of Proxy is LTA
ab5tract o/ 09:42
. o ( wouldn't it be nice if Proxy was a role rather than a class? ) 09:43
Geth doc: 711924fa28 | (JJ Merelo)++ | doc/Language/containers.pod6
Minor grammar adjustments #3443
10:18
linkable6 Link: docs.raku.org/language/containers
DOC#3443 [open]: github.com/Raku/doc/issues/3443 [docs] The description of Proxy is LTA
ShimmerFairy I really wish the value of $?LINE wasn't decided in the Actions, not even macros are helping get the line at which a function call was done. 10:30
MasterDuke ShimmerFairy: maybe try turning on line coverage? 11:06
ShimmerFairy what's that? 11:07
MasterDuke set MVM_COVERAGE_LOG=foo-%p.log (or %d maybe, it creates a per-pid file) 11:08
MasterDuke you can also use MVM_COVERAGECONTROL=1 and then `nqp::coveragecontrol(1); nqp::coveragecontrol(0);` to start and stop it where you want in your code 11:10
ShimmerFairy A quick glance at the output and it looks like it tells you where the callees are, not where the callers are. 11:31
poohman hi 11:31
do we have a separate irc channel for comma ide? 11:32
MasterDuke is #comma a thing?
MasterDuke ShimmerFairy: modules.raku.org/dist/Trait::Traced:cpan:KAIEPI maybe? 11:34
poohman not a lot of people at #comma - just one 11:34
MasterDuke well, sena_kun, jnthn, and timotimo can probably help, they're comma devs 11:35
sena_kun poohman, no specific channel, anything I can be helpful with?
poohman Just did a Comma update and have in Tools an option calle XML options 11:36
im working with XML libraries for the past few days
and the options there seem tailor made for what Im trying to do
but they are greyed out
sena_kun poohman, did it work before this release? 11:37
poohman I did not notice
just happened to notice it when I tried to check the Grammar Preview as it is in the same menu 11:38
sena_kun poohman, indeed, seeing them. Ok, I'll create a ticket to look into why they are not active, shouldn't be too hard to fix it next release. 11:41
poohman thanks 11:42
sena_kun poohman, ticket created, will work on it. Thanks for reporting!
tbrowder can comma be used to debug rakudo/rakudo/src/Perl6 code during a build? 12:06
ShimmerFairy Depends on how good it is at NQP (or grammars if that's all you need, since NQP and Raku grammars are pretty much the same), I'd imagine. 12:07
lucs Grammar with proto`s question: gist.github.com/lucs/b6b5e77126b89...bc02a2b498 12:22
ShimmerFairy lucs: the usual strategy, which you can find being done in Raku's grammar, is to bring that out into a separate rule, so things look like elem:sym<let> { <let> } ... ld { <let> <dig> } 12:27
ShimmerFairy Maybe <elem:sym<let>> could work, but I wouldn't count on it. 12:28
lucs ShimmerFairy: Trying... 12:29
lucs ShimmerFairy: Interestingly, both approaches work. 12:34
Thanks
ShimmerFairy I'd factor it out anyway, since needing the same regex in two places is usually a sign it should be put in a separate rule (like with regular code and functions) :) 12:35
lucs I'll have to see how I handle associated actions -- as you can guess, I golfed this down from some real code I'm trying to build. 12:36
cpan-raku New module released to CPAN! Set::Equality (0.0.1) by 03ELIZABETH 12:39
lucs By the way, I'd say the regex was already factored outr; your first suggested approach factors out its name -- the second one lets me reuse the name, but yeah, it looks a bit heavy. 12:41
*out
fink92 I find myself difficult to understand the code to sort an array by descending: my @x = {5,1,3,4,-9, 0}; 12:49
.sort: * < *
intuitively I assume it be sorting by ascending ... 12:50
ShimmerFairy m: my @x = 5,1,3,4,-9,0; say @x.sort; say @x.sort: * < * 12:52
camelia (-9 0 1 3 4 5)
(5 4 3 1 0 -9)
MasterDuke m: my @x = 5,1,3,4,-9,0; say @x.sort; say @x.sort: -* 12:55
camelia (-9 0 1 3 4 5)
(5 4 3 1 0 -9)
Geth doc: Michael-S++ created pull request #3445:
Add tuple section for Python to Raku page.
13:50
Geth doc: Michael-S++ created pull request #3446:
Add section on tail call optimization/elimination.
14:09
Xliff How does one go looking into the main symbol table, again? 14:25
Particularly, I'd like to go through the entire table and pull out all of the CStructs. 14:26
MasterDuke m: .say for ::.keys # something like this? 14:30
camelia $=finish
$/
$_
EXPORT
$!
!UNIT_MARKER
GLOBALish
::?PACKAGE
$=pod
$?PACKAGE
lizmat Xliff: since almost everything in Raku is lexical, what "main symbol table" are you thinking about
m: dd +CORE::.keys 14:31
camelia 688
Xliff MasterDuke: Thanks!
Xliff MasterDuke++, lizmat++! 14:36
tbrowder in 15:06
Geth doc: aa58e749e7 | (Mike Swierczek)++ | doc/Language/py-nutshell.pod6
Add tuple section for Python to Raku page.

This is to help users coming from any language with Tuples find a page listing an equivalent Raku feature.
15:40
doc: 9e8e24d737 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | doc/Language/py-nutshell.pod6
Merge pull request #3445 from Michael-S/master

Add tuple section for Python to Raku page.
linkable6 Link: docs.raku.org/language/py-nutshell
Geth doc: uzluisf++ created pull request #3447:
Clarify description of reduce sub/method for Any and List
16:03
doc: Michael-S++ created pull request #3448:
Attempt to add 'case statements' to indexing
16:06
Geth doc: fc7c71647c | (Mike Swierczek)++ | doc/Language/haskell-to-p6.pod6
Add section on tail call optimization/elimination.

Someone coming from Haskell, Common Lisp, and several other functional languages might want to know if Raku supports tail call optimization.
I can't find any recent detailed discussions on it, but my understanding is that it's not in the Raku language spec or in the Rakudo implementation.
16:43
linkable6 Link: docs.raku.org/language/haskell-to-p6
doc: c700b4c29b | (Mike Swierczek)++ | doc/Language/haskell-to-p6.pod6
Removed redundant headings.
doc: e187844423 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | doc/Language/haskell-to-p6.pod6
Merge pull request #3446 from Michael-S/no_tail_call_optimization_elimination

Add section on tail call optimization/elimination.
holli__ can i somehow hint to GENERATE-USAGE to exclude a main candidate from the description? 17:00
i have one multi in which i catch bad argzuments and i don't want that to appear in the USAGE 17:01
ctilmes holli___: is hidden-from-USAGE 17:09
docs.raku.org/language/create-cli#...from-USAGE
cpan-raku New module released to CPAN! FastCGI::NativeCall (0.0.7) by 03JSTOWE 17:17
mahafyi hello. i felt Raku community should have some successful application here -> www.mozilla.org/builders :) 18:37
cpan-raku New module released to CPAN! MongoDB (0.43.10.2) by 03MARTIMM
holli__ ctilmes: ty 19:42
tellable6 holli__, I'll pass your message to ctilmes
guifa_ o/ 21:41
holli__ m: class foo { method bar { 1 }; submethod TWEAK { next } }; say foo.new.bar for 1..3 23:06
camelia ( no output )
holli__ that's kinda surprising 23:07
lucs m: my %h = :42.23foo; print %h.perl; 23:22
camelia 5===SORRY!5=== Error while compiling <tmp>
Malformed radix number
at <tmp>:1
------> 3my %h = :427⏏5.23foo; print %h.perl;
expecting any of:
number in radix notation
lucs m: my %h = :42foo; print %h.perl;
camelia {:foo(42)}
lucs That's the craziest notation :)