🦋 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 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 8 June 2022.
SmokeMachine lizmat: are -A, -B and -C still options to rak?those are being cited on other options’ descriptions 00:23
SmokeMachine lizmat: could —edit optionally receive the editor’s name? 00:25
SmokeMachine lizmat: -o and -h are also being mentioned 00:27
japhb Nemokosch (and general PSA): If you've been having problems with Terminal::LineEditor and certain keymaps, please try again with Terminal::LineEditor 0.0.12. :-) 03:22
lizmat SmokeMachine++ # all fixed now, including being able to mention the editor on the command line 08:18
Nemokosch japhb: nice, thank you 08:46
can confirm that it's typing-friendly now 08:47
I've been thinking about the Raku conference, by the way 08:58
lizmat Nemokosch: a presentation would be cool :-)
tellable6 lizmat, I'll pass your message to Nemokosch
Nemokosch Yes yes... but about what? It has been bugging me for days now 09:00
And I think what really would be the best is a presentation about containers - but I don't think I can just master them in a month
lizmat containers in the sense of my $foo being a container, or more the Docker kind ? 09:13
Nemokosch the first 09:18
I don't think there is much Raku specific about the Docker kind
lizmat you know of my opensource.com posts about containers? 09:20
opensource.com/article/18/8/containers-perl-6 09:22
Nemokosch Not sure
Okay, nice 10:12
Is there anything that doesn't essentially bind to something?
lizmat ? 10:15
don't think so: essentially, it's all built on NQP, and NQP only knows binding
Nemokosch This article is not bad but well, it misses @ % and \ at least 😅 10:27
I read something in the docs that \foo = something and \foo := something are the same 10:29
that is, sigilless variables bind, no matter what
also docs.raku.org/routine/%3C%3E 10:31
"decontainerization operator"
is this not the same as zen-slicing?
Nemokosch m: my $demo = 11; say $demo.VAR.WHAT; say $demo[].VAR.WHAT; say $demo<>.VAR.WHAT; 10:32
camelia (Scalar)
(Int)
(Int)
tellable6 2022-07-17T08:58:58Z #raku <lizmat> Nemokosch: a presentation would be cool :-)
Nemokosch :D
summer Quick question about bad ideas: gist.github.com/Summertime/7d768d9...705b60666c could such a thing be done with raku's type system? 12:26
(and or, any currently existing language?) 12:27
Kaiepi summer, that looks a bit like Rc from rust 12:29
something similar should be doable with a Proxy 12:30
you're gonna have a bad time if you try the mop route. attributes are gorey 12:32
i.e. attribute references are rarely made with Attribute.get_value or set_value internally, so you'd need a slang of some sort 12:34
summer a proxy would fire twice, which would mean either an eager "grab everything" api call, or two api calls 12:37
from my understanding
and yeah its somewhat expected to be gorey, unfortunately. I just wish the docs on the gore didn't go so quickly into "some of this stuff is compiler specific" :sob: 12:38
I would be happy still if I could do something like, user.^needs('attribute') or the such, just as long as the attribute-requesting-code is close to the attribute-using-code 12:40
I'll look into Rc
I guess the shortest worded form of what I'm asking is "can the type system be used to optimise an API call" 12:42
Nemokosch Is Array the data type and Array the container type the same thing? 13:35
lizmat no, containers come in many flavours 13:37
the Proxy class e.g. also provides a container 13:38
Nemokosch what would be a containerless Array, then? 13:39
Nemokosch m: my \bed = <too big>.Array; bed = 'full'; dd bed; 13:41
camelia ["full"]
lizmat m: my @a; @a[0] := 42; @a[0] = 666 # a containerless Array
Nemokosch crazy stuff
camelia Cannot assign to an immutable value
in block <unit> at <tmp> line 1
Nemokosch that's not the array but the element 13:42
lizmat you cannot define a containerless Array you can only make elements containerless 13:43
or define your own Array compatible class
Nemokosch hmm, I mean... I guess you can see why this is causing massive headaches 13:52
data types and container types aren't the same thing but they also aren't orthogonal
I suppose the same thing applies to Hashes as well 13:56
lizmat Nemokosch: yes 14:22
Nemokosch the key part cannot be a Scalar, at least it seems to me 14:23
lizmat indeed 14:36
p6steve i have v1 of the Dan::Polars read_csv ... to_dataset basically functional 14:44
good news is that it will import a csv with 2 million rows in 2mins 14sec 14:46
bad news is this is 3sec for Rust to read the file and 2mins 11sec to import to raku :C (<= note use of Coercion type saddie)
there is probably quite a lot to be done to speed things up ... ideally would be a zero copy from Rust 14:48
I think that means building a Cstruct in Rust that matches a raku (2d) Array
is there any prior art on this -- other modules or in Nativecall maybe? 14:50
(funnily enough a containerless array might be ideal for this to save creating 28 million containers
)
lizmat I guess it could be relatively trivial if you're talking about a native 2d array
what's in the containers? Ints ? 14:51
p6steve hmmm - well this is Polars DataFrames where each column is a typed Series 14:52
SmokeMachine Is it `hyper`ing the CSV lines?
p6steve so I guess can drop each Series (i32, f64 and so on) into a specific raku (1d) Array variant with known native type 14:54
smokemachine: not yet ... hypering is one strategy ... BUT early on in the import I get a zero copy pointer to a CArray(int32) or similar and AFAIK ```my@a = CArray.list``` is the only way to load the array 14:56
smokemachine: only Rust Polars gets to handle the csv file ... it's a Polars Series by the time I start the raku import 14:58
lizmat: where should I look in rakudo / moarvm for the 1d Array layout? 14:59
this is all a bit down and dirty for my skill set 15:00
lizmat good question: it's all hidden in nqp ops I believe
lizmat wouldn't know offhand
nine vrurg might
need to go afk now& 15:01
p6steve tx! - probably needs a bit of digging & speed profiling & maybe an SO question or two 15:27
Nemokosch <> and [] really seem to do the same 16:42
[Coke] lizmat: might I suggest a "-a" alias for --author (which also could stand for "all") 16:50
tellable6 2022-07-16T18:14:26Z #raku <uzl[m]> [Coke]: Could this PR (github.com/Raku/doc/pull/4084) be merged assuming everything is fine? I'm looking to document the other 2022.06 changes wherever I am not out of my depth 😅
[Coke] (^^ for run-tests) 16:52
Geth doc: e95983fc83 | (Luis F. Uceta)++ (committed using GitHub Web editor) | doc/Language/operators.pod6
Make &[max] and &[min] return LHS for ties (#4084)
16:53
linkable6 Link: docs.raku.org/language/operators
[Coke] uzl[m]: done
thundergnat weekly: As of today Rosettacode has 1500 Raku entries: See rosettacode.org/wiki/Rosetta_Code/.../Full_list and rosettacode.org/wiki/Category:Raku 20:18
notable6 thundergnat, Noted! (weekly)
thundergnat Around 3.5 years ago it was 1000 . colabti.org/irclogger/irclogger_lo...11-11#l491 20:20
Only about 50 task entries left undone. Anyone who would like to contribute is more than welcome! rosettacode.org/wiki/Reports:Tasks...ed_in_Raku 20:21
(Of course, new tasks get added all of the time, so it's a moving target.) 20:22