🦋 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.
leont deepmap does recurse 00:00
00:00 reportable6 left 00:01 reportable6 joined
atweiden-air_ leont: i think i get it. so .uc is being applied to each list, not to each list element? 00:02
leont Yeah. Map iterates over all elements of @a, which are lists, and calls .uc on them
atweiden-air_ makes sense 00:03
leont .uc and other stringy methods are defined on lists, and effectively do .Str.uc
00:23 atweiden-air_ left 00:24 atweiden-air_ joined 00:26 atweiden-air_ left 00:27 squashable6 left 00:30 squashable6 joined 00:41 epony joined 00:50 ProperNoun left 00:51 irc_user left
tonyo .seen jjmerelo 00:56
tellable6 tonyo, I saw jjmerelo 2021-05-26T15:37:00Z in #raku: <jmerelo> No changes === good
tonyo wowza.
01:40 habere-et-disper left 01:46 ToddAndMargo joined
ToddAndMargo Windows 11 pro 22H2. 01:52
You guys have been helping me figure out NativeCall and Pointers.  I finally got it figured out.  I just posted an example over on the perl6 mailing list of use of pointers for calling Windows DLL's and for copying data out of structures when given a pointer to the structure.
I get a pointer and length from "GetComputerNameA" and then show how to use the pointers to copy the data pointed to with "memcpy_s".
pastebin.com/ni3J5hvD
Maybe someone would want to clean this up and post it in Raku's example section?
Thank you all for the help!
02:10 derpydoo joined, razetime joined 02:13 human-blip left 02:25 ToddAndMargo left 02:28 derpydoo left 02:38 razetime left 02:46 razetime joined 03:09 Kaiepi left 03:56 jaguart joined 04:27 Sgeo left 04:31 Sgeo joined 05:31 benchable6 left, bisectable6 left, shareable6 left, nativecallable6 left, squashable6 left, notable6 left, statisfiable6 left, reportable6 left, committable6 left, releasable6 left, coverable6 left, tellable6 left, unicodable6 left, greppable6 left, evalable6 left, bloatable6 left, linkable6 left, quotable6 left, sourceable6 left, quotable6 joined, coverable6 joined 05:32 unicodable6 joined, linkable6 joined, evalable6 joined, reportable6 joined, squashable6 joined, squashable6 left 05:33 statisfiable6 joined, releasable6 joined, sourceable6 joined 05:34 tellable6 joined, bisectable6 joined, notable6 joined, greppable6 joined, bloatable6 joined, nativecallable6 joined, benchable6 joined, committable6 joined, shareable6 joined 05:35 squashable6 joined 06:00 reportable6 left 06:01 reportable6 joined 07:01 sourceable6 left, nativecallable6 left, greppable6 left, committable6 left, linkable6 left, bloatable6 left, coverable6 left, tellable6 left, squashable6 left, notable6 left, releasable6 left, benchable6 left, unicodable6 left, quotable6 left, statisfiable6 left, evalable6 left, bisectable6 left, reportable6 left, shareable6 left 07:02 committable6 joined, sourceable6 joined, releasable6 joined, coverable6 joined, benchable6 joined 07:03 nativecallable6 joined, greppable6 joined, shareable6 joined, squashable6 joined, notable6 joined, statisfiable6 joined, unicodable6 joined, bloatable6 joined, reportable6 joined 07:04 evalable6 joined, linkable6 joined, quotable6 joined, bisectable6 joined, tellable6 joined 07:05 lichtkind joined 07:09 grondilu joined
grondilu I was wondering: what's the point of the BEGIN phaser? I mean, shouldn't the compiler compile anything that it can anyway? 07:10
07:25 fishtank joined 07:29 fishtank left 08:29 sourceable6 left, coverable6 left, quotable6 left, squashable6 left, notable6 left, benchable6 left, linkable6 left, tellable6 left, statisfiable6 left, evalable6 left, releasable6 left, bisectable6 left, greppable6 left, bloatable6 left, reportable6 left, nativecallable6 left, unicodable6 left, committable6 left, shareable6 left 08:30 statisfiable6 joined, unicodable6 joined, notable6 joined, bisectable6 joined 08:31 tellable6 joined, greppable6 joined, shareable6 joined, reportable6 joined, releasable6 joined, benchable6 joined, committable6 joined, nativecallable6 joined 08:32 coverable6 joined, squashable6 joined, quotable6 joined, linkable6 joined, bloatable6 joined, evalable6 joined, sourceable6 joined 08:34 grondilu left 08:38 euandreh left
Nemokosch How do you define "what it can"? 08:44
08:54 Sgeo left 09:01 abraxxa joined 09:06 abraxxa left, irc_user joined, abraxxa joined 09:11 discord-raku-bot left, discord-raku-bot joined 09:13 sena_kun joined
I'm sure this is written down somewhere or we have talked about it - but how do array literals work? 09:20
[1] - this is a one-element array 09:21
[<a b c>] - this is a three-element array, despite the List inside
in fact, even [[1, 2]] "auto-flattens" 09:22
I know you can make it a scalar or add a comma, I'm just curious how this is processed
09:29 discord-raku-bot left, discord-raku-bot joined 09:37 Kaiepi joined
Geth advent: d5913364d3 | (Fernando Corrêa)++ | 2 files
Add RedFactory to the list of articles
09:40
advent: 4a1b3daf4f | (Fernando Correa de Oliveira)++ (committed using GitHub Web editor) | raku-advent-2022/articles/RedFactory.md
Update RedFactory.md
09:41
10:06 MoC joined 10:11 tirnanog left 10:35 sena_kun left 10:50 sena_kun joined 10:56 sena_kun left 11:15 irc_user left
grondilu I may be wrong but it shouldn't be too hard to assess whether an expression can be compiled or not. For instance in my implementation of md5 (github.com/grondilu/libdigest-raku...t.rakumod) I have blobs and arrays defined in a BEGIN because they depend only on literals. It occurred to me later that the compiler could figure out by itself that these are constant arrays that could and ma 11:22
Nemokosch in that case, why don't you declare them as constants? 11:23
grondilu I did in previous versions, but it doesn't change the fact that it seemed superfluous to me. 11:24
Nemokosch What I don't know are the technical constraints - but frankly, I don't find the demand completely justified in the first place 11:25
code runs, well, at runtime, as a main rule
even in archmage C++
if you want to run code by the compiler, you indicate that 11:26
sounds sane to me
lizmat grondilu how do you know that Rakudo actually doesn't do that already ? 11:27
ok, looking at the code, that might actually be less than trivial :-) 11:29
grondilu lizmat: I had discussed few weeks ago here about whether it made sense to write `constant $ = Blob.new: some-code(@literal-values);` and I was told it did. Also we made some tests and it was quicker with `constant $ =` 11:30
well, not on first execution but on the next ones, IIRC
Nemokosch I think lizmat meant to say that there might already be optimizations of the kind you are looking for
but it turns out that maybe not? 11:31
if pure functions were strongly indicated in Raku, this could go further, I suppose
lizmat well, for instance: if you write "42 + 666", it will constant fold that to 708
grondilu To make sure I may write a specific test with a very expensive function I suppose.
lizmat and similar cases 11:32
if the static optimizer sees an expression consisting of constant values only, it will fold it
grondilu There is a pure trait that I considered using at some point, but I thought it was simpler to just use a BEGIN phaser
lizmat yeah, using BEGIN makes it easier to reason about as a developer 11:34
grondilu take for instance this : `blob32.new: map &floor ∘ * * 2**32 ∘ &abs ∘ &sin ∘ * + 1, ^64`. Do you think it would be compiled ASAP?
it's all constants and pure functions 11:35
or "constant fold", I'm not familiar with that terminology 11:36
I know I can just use BEGIN, but I like writing short code, and I'll take anything I can get to simplify things. 11:38
lizmat en.wikipedia.org/wiki/Constant_folding 11:40
11:52 euandreh joined 12:00 reportable6 left 12:01 reportable6 joined 12:02 sgrs joined 12:31 sena_kun joined
Geth doc: Kaiepi++ created pull request #4146:
Document Metamodel::Primitives' parameterization cache API
12:56
13:28 zara joined 13:29 zara is now known as holyghost 13:37 habere-et-disper joined
tbrowder i need some help with class introspection, please 13:43
13:43 razetime left
tbrowder i have the attribute list from self.^attributes and want the value of each 13:44
13:45 derpydoo joined
tbrowder i have tried: attr.get_value 13:45
self.attr.get_value 13:46
self.get_value: attr
i have done it successfully in the past but don't remember the syntax 13:47
btw, i think my problem here is the same on Todd has, the docs, just like the *nix man pages, don't show the basic use before jumping into meta land assuming the reader already knows a lot about the subject 13:49
lizmat I believe it is attr.get_value(self) 13:51
m: class A { has $.a = 42 }; say A.^attributes[0].get_value(A.new) # tbrowder 13:52
camelia 42
tbrowder thnx, i used attr.get_value: self 13:56
worked great. THANKS, lizmat
14:22 melezhik joined
melezhik Anton Antonov please see my PR for your modules to migrate to SparrowCI, current builds fail due to absence of sparrow.yaml 14:23
14:25 melezhik left
Anton Antonov <@779471841270038528> Ok, I will do that in the next hour or so... Thanks! 14:26
14:28 melezhik joined, melezhik left
Geth advent: p6steve++ created pull request #104:
add post
14:36
14:40 habere-et-disper left 14:59 mcmillhj joined 15:00 melezhik joined
melezhik . 15:00
15:01 melezhik left 15:03 linkable6 left, linkable6 joined 15:10 Nemokosch joined
Nemokosch bisectable6: say :42z ~~ :42a; 15:10
bisectable6 Nemokosch, Will bisect the whole range automagically because no endpoints were provided, hang tight
tellable6 2022-12-01T13:29:35Z #raku <El_Che> Nemokosch: your wording makes it sound like Greco-Roman wrestling
2022-12-01T21:48:37Z #raku <[Coke]> nemokosch: aspirationally assigned that since you were working on the issue.
bisectable6 Nemokosch, Output on all releases: gist.github.com/5f0db399632d356eef...222175561d 15:11
Nemokosch, Bisecting by output (old=2021.12 new=2022.02) because on both starting points the exit code is 0
Nemokosch, bisect log: gist.github.com/03567ed5811c93feb2...14c079099b
Nemokosch, (2022-01-04) github.com/rakudo/rakudo/commit/02...53bc6f2ff9
Nemokosch, Output on all releases and bisected commits: gist.github.com/ed1f2d431ef660e6b5...09b4f9db79 15:12
15:14 melezhik joined 15:18 melezhik left 15:19 melezhik left 15:20 Nemokosch left 15:33 Nemokosch joined 15:35 Nemokosch1 joined 15:38 Nemokosch left 15:52 abraxxa left 15:58 melezhik joined
melezhik . 15:58
Anton Antonov - I wonder why is raku 2022.06 is faster then 2022.07 when running tests for Raku-Data-Generators - ci.sparrowhub.io/report/1966 ? 15:59
Geth doc: 2colours++ created pull request #4148:
Pair.ACCEPTS documentation fix
Anton Antonov <@779471841270038528> I think it has something to do with the weighted random sampling over Mixes. (Good question!) 16:01
melezhik AA ++ 16:02
Anton Antonov I also, changed the logic of the default selection of random pet names in "Data::Generators", because it seemed slow with very modest sizes (e.g. 4000.) 16:03
melezhik I mean why it is slower for 2022.07 rakudo?
Anton Antonov Maybe the Mix sampling with `roll` was changed in some way between 2022.07 and 2022.06 ? 16:04
<@779471841270038528> It did not occur to me to check what is the speed with older rakudo versions... 16:11
Geth advent: 62314a49a0 | p6steve++ (committed using GitHub Web editor) | raku-advent-2022/authors.md
add post
16:27
advent: 91c0693a7b | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | 2 files
Merge branch 'master' into master
advent: 15a813991d | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | raku-advent-2022/authors.md
Merge pull request #104 from p6steve/master

add post
16:42 Nemokosch1 left 16:57 euandreh left
Geth doc: 86553739de | 2colours++ | doc/Type/Pair.pod6
Closes github.com/Raku/doc/issues/4147.

The description of the Pair ~~ Pair case has been updated to match the specification and contemporary Rakudo.
17:09
doc: 36454bad12 | (Will Coleda)++ (committed using GitHub Web editor) | doc/Type/Pair.pod6
Merge pull request #4148 from 2colours/master

Pair.ACCEPTS documentation fix
linkable6 Link: docs.raku.org/type/Pair
17:13 melezhik left 17:33 MoC left
Geth doc: b97f1c70e9 | (Ben Davies)++ | 2 files
Document Metamodel::Primitives' parameterization cache API

This is *very* handy in MOP-heavy code, but is rather unintuitive.
Adds "parameterizer" and "noop" as words.
17:53
doc: 1c9f10bab1 | (Will Coleda)++ (committed using GitHub Web editor) | 2 files
Merge pull request #4146 from Kaiepi/param-cache

Document Metamodel::Primitives' parameterization cache API
18:00 reportable6 left 18:01 reportable6 joined 18:21 epony left 18:25 sena_kun left 18:29 euandreh joined 18:31 Guest33 joined
tbrowder lizmat: while getting the class introspection syntax correct, i noticed the old pre-kabob-case names again, any thoughts on modernizing all that old stuff? wait for a new version, or just do it? (and same questions ref nqp) 18:35
lizmat A few years ago I asked the same question :-) 18:38
afk& 18:40
19:00 mcmillhj left 19:02 sena_kun joined 19:22 euandreh left 19:34 thisamu joined 20:01 Guest33 left
El_Che hi liz 20:05
Geth doc: 0rir++ created pull request #4151:
Consolidate quietly into statement-prefix.pod6 from control.pod6.
20:07
tbrowder i briefly looked for a rakudo issue ~~ kabob but found nothing...i'll poke around some more 20:18
Nemokosch kebab? 20:20
tbrowder as in var, sub, method names, raku ppl tend to prefer "some-name" instead of "some_name"; saves a keystroke and looks cooler 20:30
name is from look of food chunks on a skewer for cooking 20:31
both i think distinguish *nix ppl from windows ppl 20:33
oh, i used subious alternative spelling, sorry... 20:38
20:38 thisamu left
tbrowder ok, found it (again), @jnthn put that to rest, see closed issue #1292 20:45
21:04 Sgeo joined 21:07 NemokoschKiwi joined
NemokoschKiwi is the undersightable bot also gone? 21:35
21:39 epony joined 21:42 melezhik joined
melezhik ugexe  I would be interested to hear your thoughts in this - github.com/pdf-raku/PDF-Font-Loade...ku/pull/22 21:44
.tell  @dwarring - I would be interested to hear your thoughts in this - github.com/pdf-raku/PDF-Font-Loade...ku/pull/22 21:45
tellable6 melezhik, I cannot recognize this command. See wiki for some examples: github.com/Raku/whateverable/wiki/Tellable
melezhik .tell dwarring - I would be interested to hear your thoughts in this - github.com/pdf-raku/PDF-Font-Loade...ku/pull/22 21:46
tellable6 melezhik, I'll pass your message to dwarring
NemokoschKiwi AlexDaniel: good sir, do you know anything about the resolution of the undersightable bot?
21:52 melezhik left 21:59 NemokoschKiwi left 22:56 sena_kun left 23:22 deoac joined
Geth doc: 2colours++ created pull request #4152:
Altering Online communities section of the community page
23:49