🦋 Welcome to the IRC channel of the core developers of the Raku Programming Language (raku.org #rakulang). This channel is logged for the purpose of history keeping about its development | evalbot usage: 'm: say 3;' or /msg camelia m: ... | Logs available at irclogs.raku.org/raku-dev/live.html | For MoarVM see #moarvm
Set by lizmat on 8 June 2022.
00:00 reportable6 left 00:03 reportable6 joined 00:17 timo left 00:18 timo joined 00:27 timo left 00:28 timo joined 01:20 MasterDuke joined 02:16 Xliff left 04:18 evalable6 left, linkable6 left 04:19 linkable6 joined, evalable6 joined 06:00 lizmat left, vrurg left, rypervenche left, gfldex left, lucs left, JRaspass left, lucs joined, reportable6 left, gfldex joined, rypervenche joined, JRaspass joined 06:01 vrurg joined, rypervenche left, rypervenche joined, reportable6 joined, lizmat joined 07:24 squashable6 left 07:26 squashable6 joined
Geth rakudo/main: ba7f659c58 | (Elizabeth Mattijsen)++ | src/core.c/RakuAST/Fixups.pm6
RakuAST: don't use named subs for .map/.grep/.first

Nudged by gfldex++
08:51
09:57 quotable6 left, reportable6 left, squashable6 left, bloatable6 left, bisectable6 left, linkable6 left, greppable6 left, statisfiable6 left, unicodable6 left, tellable6 left, evalable6 left, sourceable6 left, releasable6 left, shareable6 left, benchable6 left, notable6 left, nativecallable6 left, coverable6 left, committable6 left, committable6 joined, squashable6 joined, notable6 joined, statisfiable6 joined 09:58 linkable6 joined, bloatable6 joined, unicodable6 joined, releasable6 joined, nativecallable6 joined, coverable6 joined 09:59 evalable6 joined, benchable6 joined, greppable6 joined, shareable6 joined, tellable6 joined, bisectable6 joined, reportable6 joined, sourceable6 joined 10:00 quotable6 joined
gfldex lizmat: While we are at the subject of nudging. I do like .visit-children, but I don't like its name and interface. How about `method gather-children(&taker, :$deep)` ? 10:03
lizmat how about .grep ?
that's already in HEAD
as is .map and .first on RakuAST Nodes 10:04
and a dynamic variable @*LINEAGE that shows all of the ancestry
gfldex I would not expect `.grep` to require a `take`.
lizmat it doesn't 10:05
the .map / .grep / first embed the gather and let the map / grep / first logic do the take
your code just needs to return True/False (in the case of .grep / .first) or the value that you want produced (in the case of .map_ 10:06
gfldex Is there a way to introspect if a Code sports CX::Take? 10:07
lizmat $*CU.map: { .paragraphs.Str if $_ ~~ RakuAST::Doc::Block } would produce all the text from doc blocks
gfldex: you mean, whether there's a 'take' inside? 10:08
gfldex yes 10:09
lizmat something like: 10:10
$*CU.grep: { $_ ~~ RakuAST::Blockoid && .first({ $_ ~~ RakuAST::Call::Name && .name eq 'take' }) } 10:12
gfldex Also, a :$deep flag could indicate that I want .grep/.map/.first to decent into children. 10:13
lizmat yeah, I've been considering something like that, just contemplating the name 10:15
perhaps :depth-first ? 10:24
gfldex `multi method grep(&matcher, :$breadth = True, :$gather = False) {}; multi method grep(&matcher, :$depth = True, :$gather = False) {}; method gather(&taker, *%_) { self.grep(&taker, :gather, |%_) }` 10:43
lizmat: maybe like this ^^^
lizmat what would that bring over the functionality that is already in .map/.grep/.first in HEAD (apart from a :depth-first argument that I'm currently testing 10:46
)
?
Geth rakudo/main: 8099dd3c00 | (Elizabeth Mattijsen)++ | src/core.c/RakuAST/Fixups.pm6
RakuAST: add :depth-first argument to .map/.grep/.first
10:53
lizmat meh just found out that my test result checker didn't catch a regression
213bacbb14fa6b6ca5f7d109e7713dcc802a82fc broke it, so only since 16:00 yesterday *phew* 11:36
11:37 linkable6 left 11:39 linkable6 joined
Geth rakudo/main: 1fd990fb01 | (Elizabeth Mattijsen)++ | src/Raku/ast/doc-block.rakumod
RakuAST: don't let ::Doc::Block descend into ::Doc::Blocks

To fix an issue with production of $=pod that was introduced with 213bacbb14fa6b6ca5f7d109e7713dcc802a82fc . Still not sure whether this is the correct solution, as this feels icky. But it will unbreak the spectests that were broken for now.
11:59
12:00 reportable6 left 12:02 codesections1 joined, reportable6 joined 12:03 codesections left, codesections1 is now known as codesections 12:08 codesections1 joined 12:10 codesections left, codesections1 is now known as codesections 12:12 codesections1 joined 12:14 codesections left 12:15 codesections joined 12:17 codesections1 left 12:18 kurahaupo left 12:20 kurahaupo joined
leont lizmat: If I understand your code correctly, it doesn't make a breadth-first/depth-first distinction, but a pre-order/post-order one 12:22
12:33 codesections1 joined 12:34 codesections left, codesections1 is now known as codesections
lizmat with depth-first, it first visits all of the children before handling the invocant 12:39
that's going deep first, is it not ?
12:57 codesections1 joined 12:59 codesections left, codesections1 is now known as codesections
lizmat and yet another Rakudo Weekly News hits the Net: rakudoweekly.blog/2023/05/29/2023-...t-rolling/ 13:23
13:59 linkable6 left, evalable6 left, linkable6 joined 14:01 evalable6 joined 14:20 Xliff joined
Geth rakudo/main: 6325d10f41 | (Elizabeth Mattijsen)++ | src/Raku/ast/variable-declaration.rakumod
RakUAST: remove some dead code

The check whether it was initialized, is not necessary anymore. And also if it was not initialized, it would have bombed as the indicated method does not exist.
14:28
14:36 codesections1 joined 14:38 codesections left, codesections1 is now known as codesections
leont lizmat: I used to think so too, but apparently not. See en.wikipedia.org/wiki/Depth-first_...rst_search 16:14
Geth rakudo/main: a78234e1c0 | (Elizabeth Mattijsen)++ | 5 files
RakuAST: add support for $=data as described in S26

With RakuAST this became almost trivial to implement, so I did.
This also adds a Pod::Data class, that works both as an Array as well as a Hash. Perhaps this functionality should be made more general, e.g. as a HashArray or Hashray class?
16:32
lizmat leont: well, I don't see a way to provide a different functionality than now offered with :depth-first, other than controlling the calling of .visit-children yourself 16:34
16:38 linkable6 left, evalable6 left, linkable6 joined
leont I don't mean to suggest it's doing the wrong thing, it's just using an incorrect name for the right thing. 16:38
lizmat ok, so depth-first should be called pre-ordered ? 16:39
16:41 evalable6 joined
Geth nqp/main: 4f0c01f7ce | (Elizabeth Mattijsen)++ | tools/templates/MOAR_REVISION
Bump MoarVM to get timo++'s optimization
16:41
leont No, post-order 16:42
Geth rakudo/main: 13b9a6bcd8 | (Elizabeth Mattijsen)++ | tools/templates/NQP_REVISION
Bump NQP to get timo++'s latest MoarVM updates
16:58
rakudo/main: 65dc1204f2 | (Elizabeth Mattijsen)++ | src/Raku/ast/doc-block.rakumod
RakuAST: must keep =data entries in $=pod

To remain compatible with any code that expects to lift =data sections out of $=pod
17:07
18:00 reportable6 left 18:03 reportable6 joined 18:32 codesections1 joined 18:35 codesections left, codesections1 is now known as codesections 20:40 kurahaupo left 20:45 kurahaupo joined