🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). This channel is logged for the purpose of keeping a history about its development | evalbot usage: 'm: say 3;' or /msg camelia m: ... | Log inspection is getting closer to beta. If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 25 August 2021.
atweiden_air-- yes, combining Signature literals, e.g. 00:00
my Signature:D $sig-a = :(Str :param($)); my Signature:D $sig-b = :(Str :param($)); my Signature:D $sig-c = $sig-a + $sig-b;
or maybe 00:02
my Signature:D $sig-a = :(Str :param($));
my Signature:D $sig-b = :(Str :other($), |c where $sig-a);
use case is for cmdline argument parsing
atweiden_air-- where cmd1 has sig1, cmd2 has sig1+sig2 00:03
atweiden_air-- if cmd1 has a long list of optional flags, it’s a lot of code to duplicate 00:04
atweiden_air-- but if a Signature literal can be added to dynamically, or combined with another, then that might be a clean way of handling arg parsing 00:05
drakonis hm, i see. 00:07
that would be quite nice. 00:11
SmokeMachine m: my $s1 = :($a); my $s2 = :($b); say Signature.new: :params(|$s1.params, |$s2.params) # atweiden_air— the only way I could find 00:12
camelia ($a, $b --> Mu)
SmokeMachine m: my $s1 = :($a); my $s2 = :($b); say Signature.new(:params(|$s1.params, |$s2.params)) ~~ \(42, 13) 00:15
camelia False
SmokeMachine 01:15 <SmokeMachine> m: my $s1 = :($a, :$b!); my $s2 = :($c, $d = 42); say Signature.new(:params(|$s1.params, |$s2.params)) 00:17
m: my $s1 = :($a, :$b!); my $s2 = :($c, $d = 42); say Signature.new(:params(|$s1.params, |$s2.params))
camelia ($a, :$b!, $c, $d = 42 --> Mu)
SmokeMachine m: my $s1 = :($a, :$b!); my $s2 = :($c, $d = 42); say Signature.new(:params(|$s1.params, |$s2.params)).WHAT 00:18
camelia (Signature)
atweiden_air-- m: my $sig-a = :(:a($)); my $sig-b = :(:b($)); my Signature $sig-c .= new(:params(|$sig-a.params, |$sig-b.params)); multi sub a('c', |c where $sig-c) { 'c' }; multi sub a('a') { 'a' }; a('a'); a('c'); 00:24
camelia (signal SEGV)
ugexe maybe we should turn our CI systems off and just save the electricity 00:26
they also dont fit well with a commit to master workflow 00:28
atweiden_air-- can one use raku macros yet to plainly paste syntax? 00:31
just need the ability to copy/paste in optional args
e.g. `macro opts-base() { quote {Str :opt1($)} }; macro opts-aux() { quote {Str :opt2($)} }` 00:32
moon-child drakonis: why would you need tco to implement a stack machine? 00:49
drakonis mostly so i can do some recursive constructs 00:58
inside the stack machine, that is 00:59
might try to build something similar to factor or forth
moon-child you would like to build a threaded interpreter? 01:13
drakonis hmm 01:56
idk, sure?
moon-child well, yes or no? And if yes, why? 02:08
anyway: you could do something like cps, but where you _return_ continuations to a main loop, which repeatedly calls them
cf: my &f = ...; loop { &f = f() }
drakonis hm, i'll look into it 02:13
guifa futhark-lang.org <-- saw the language name, got excited for writing code with Unicode ᚠᚢᚦᚨᚱᚲ-y goodness, then got disappointed when it wasn't that 02:39
Geth ecosystem: a21deed99c | (Lucien Grondin)++ (committed using GitHub Web editor) | META.list
Update META.list

adding Ed25519 entry
05:10
grondilu oh I forgot I had rights on this repo. I hope it's fine. 05:11
atweiden_air-- m: class ABC { has $.abc }; ABC.new(:xyasfdadsf) 06:13
camelia ( no output )
atweiden_air-- is there a way to make this fail, without writing a custom new/BUILD?
guifa atweiden_air--: no, default new / BUILD ignore unknown named parameters/attributes 06:22
but you could make it easier by writing a trait 06:23
trait could install a custom new that balks at unknown ones
CIAvash There are modules for that: raku.land/github:ufobat/StrictClass raku.land/github:tadzik/ClassX::St...onstructor 06:30
atweiden_air-- CIAvash: tvm 06:37
Nemokosch I remember grondilu from the ephemeral miniconf I think <:cameliathink:897316667653247057> 08:35
grondilu nah you must have me confused with someone else. I don't even know what the ephemeral miniconf is. 09:50
<@297037173541175296> nah you must have me confused with someone else. I don't even know what the ephemeral miniconf is. 09:52
Nemokosch hm, then why are you so familiar 😄 10:00
lizmat weekly: blog.perl-academy.de/2022-04-06-be...kshop-2022 10:06
notable6 lizmat, Noted! (weekly)
moon-child m: say 1 10:28
camelia 1
Geth doc: 0a7a2e5215 | (Elizabeth Mattijsen)++ | doc/Language/variables.pod6
Add $*RAT-OVERFLOW lemma to runtime variables

Also sort them in alphabetical order.
10:51
linkable6 Link: docs.raku.org/language/variables
Geth doc: 29a31b53cb | (Elizabeth Mattijsen)++ | doc/Language/variables.pod6
Fix typo

  MasterDuke++
11:12
linkable6 Link: docs.raku.org/language/variables
Geth doc: b95cdedbf8 | (Elizabeth Mattijsen)++ | doc/Type/Rat.pod6
Mention $*RAT-OVERFLOW in the Rat documentation

  mscha++ for nudging
11:46
linkable6 Link: docs.raku.org/type/Rat
melezhik . 12:26
guifa CIAVash: heh, yeah, I guess a role works just fine too in this case 13:06
Geth doc: 469a431464 | Coke++ | 2 files
prefer US english spelling
14:18
doc: c404ac279f | Coke++ | 2 files
new words
lizmat [Coke]++ 14:19
[Coke] lizmat++ for doc updates! 14:20
[Coke] running the script to clean up the wordlist in doc after a long gap, seems like it's faster than I recall. 15:20
[Coke] (it deletes each word one at a time and runs the aspell test for any files that contained that fragment) 15:21
lizmat [Coke]: well, that's one of the things I'm trying to achieve with all of the CUR work atm :-) 15:25
making specifically CLI scripts faster because of faster loading
and faster compiling 15:26
guifa [Coke] that reminds me I need to return to my work with spelling modules 15:37
Someone made a much cleaner version of Hunspell they've called Nuspell 15:40
perryprog oh? 15:44
what's worng with hunspell
guifa did you try reading its code? hahhaa 16:11
It worked, but apparently Nuspell has managed to run about 4x faster with less overhead and better unicode support 16:12
Doing the spell check algorithm is super fast and easy. it's generating the suggestions that's a Hard problem 16:15
Nuspell works off of Hunspell dic/aff files (but doesn't do the part-of-speech stuff, which makes me sad since I was actually relying on that for a project) 16:16
perryprog I always found hunspells suggestions to be super good for libreoffice's dicts 17:24
Geth doc: 9dc7f760f8 | Coke++ | util/clean-spell
add debug output
17:43
doc: a120e1b92b | Coke++ | util/clean-spell
Make grep selection dumber.

Grep and aspell disagree about what a word is; 'compat', for example, isn't found by grep -wli, but is considered a word because it's separated by underscores.
It means we'll have to test more files to be sure we still need the entry, but removes a chance for false positives.
[Coke] was excited that we found some old words we could delete, but they turned out to still be needed. 17:44
Geth doc: 6db9535af1 | Coke++ | xt/pws/words.pws
remove unused word
17:47
[Coke] is there a way to write a regex that is "anything lexigraphically after 'foo'" ? 17:57
japhb [Coke]: Notionally capture what you want to compare, and then have an embedded block that does a "gt" comparison? 17:59
* between the thing you just captured and the word you want to compare to
Umm, that's not counting collation order issues, and though I know someone (samcv?) did work on that, I don't remember what needs to be done to make use of that code. 18:00
[Coke] I can do the capture, but doing the comparison is eluding me. 18:03
I have support in that script to only check words that match a regex, would be nice to use that to say "everything after the last word I know you processed" 18:04
(without having to write a new mechanism in the script, which i can also do)
[Coke] ... but much easier to add the new mechanism in the script. :) 18:08
japhb m: my $words = 'abc foo quux xyzzy'; .say for $words ~~ m:g/ [« \w+ »] <?{ ~$/ gt 'foo' }> /; # [Coke] 18:29
m: my $words = 'abc foo quux xyzzy'; .say for $words ~~ m:g/ [« \w+ »] <?{ ~$/ gt 'foo' }> /; # [Coke] 18:30
camelia 「quux」
「xyzzy」
melezhik .tell p6steve -  I fixed the issue with branches on sparkyci - now _any_ default branch changes will trigger a build ... 19:30
[Coke] Anyone have thoughts on splitting the word lists in doc spell check into not just code snippets & everything else, but language feature names, code snippets, and everything else? 23:10
(it's probably not worth the effort) 23:11