01:53 habere-et-disper left 01:57 Manifest0 left 03:30 librasteve_ left 04:44 deadmarshal_ left 05:49 deadmarshal_ joined 11:49 Manifest0 joined 12:30 habere-et-disper joined
habere-et-disper What's the logic behind array indexing appearing to autovivify an array, but hash indexing doesn't ? 12:36
Contrast
m: say ('foo' => 42, 'bar' => 24).[ 0 ]
camelia foo => 42
habere-et-disper with
m: say ('foo' => 42, 'bar' => 24).{ 'foo' }
camelia Type List does not support associative indexing.
in block <unit> at <tmp> line 1
habere-et-disper I know `('foo' => 42, 'bar' => 24).Hash{ 'foo' } works.
lizmat ('foo' => 42, 'bar' => 24) is a List of Pairs 12:44
*not* a hash
dd %('foo' => 42, 'bar' => 24)<foo>
m: dd %('foo' => 42, 'bar' => 24)<foo>
camelia 42
lizmat %() creates a hash 12:45
habere-et-disper It's not an array -- yes -- but you can array index it -- why does hash indexing not do the same magic ? 12:46
ab5tract Because List and Hash are very different implementations.. in JavaScript they are (or at least were) the same (arrays were just numerically keyed hashes) 12:52
But that’s never been the case in Raku
habere-et-disper Thanks ab5tract 13:07
ab5tract Now, theoretically we could do something like define an AT-KEY in List that calls self.Hash.AT-KEY 13:08
but that's probably a lot more complicated than it sounds at first 13:09
I believe that RakuAST and/or macros will make implementing this in user space relatively trivial 13:10
15:12 habere-et-disper left 18:00 librasteve_ joined
tbrowder habere-et-disper: if you are interested in the PDF version of a calendar let me know. i have paused active development at the momoent 21:42
*moment, but my wife loves my old PostScript version so i will be working on it again soon. 21:44