🦋 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:01 reportable6 joined 01:10 evalable6 left, linkable6 left 01:11 evalable6 joined 01:12 linkable6 joined 04:45 squashable6 left, linkable6 left, nativecallable6 left, notable6 left, quotable6 left, unicodable6 left, reportable6 left, bloatable6 left, sourceable6 left, greppable6 left, bisectable6 left, releasable6 left, committable6 left, statisfiable6 left, benchable6 left, evalable6 left, tellable6 left, coverable6 left, shareable6 left, statisfiable6 joined 04:46 unicodable6 joined, evalable6 joined, linkable6 joined, coverable6 joined, committable6 joined, squashable6 joined 04:47 bisectable6 joined, tellable6 joined, shareable6 joined, bloatable6 joined, notable6 joined, nativecallable6 joined, reportable6 joined, greppable6 joined, benchable6 joined, releasable6 joined 04:48 quotable6 joined, sourceable6 joined 05:48 squashable6 left, bisectable6 left, linkable6 left, bloatable6 left, sourceable6 left, releasable6 left, quotable6 left, evalable6 left, greppable6 left, benchable6 left, unicodable6 left, coverable6 left, nativecallable6 left, statisfiable6 left, reportable6 left, committable6 left, notable6 left, benchable6 joined 05:49 reportable6 joined, committable6 joined, sourceable6 joined, releasable6 joined 05:50 bloatable6 joined, squashable6 joined, nativecallable6 joined, statisfiable6 joined, quotable6 joined, notable6 joined, unicodable6 joined 05:51 greppable6 joined, linkable6 joined, bisectable6 joined, evalable6 joined, coverable6 joined 06:00 reportable6 left 06:01 reportable6 joined 06:21 kjp left 06:25 kjp joined 07:13 kjp left, kjp joined 07:45 sena_kun joined 08:45 linkable6 left, evalable6 left 08:48 linkable6 joined, evalable6 joined
Geth rakudo/main: 26d9a2ef9b | (Elizabeth Mattijsen)++ | 4 files
RakuAST: add pod declarator support for parameters

Implemented at the RakuAST class level (deparsing, .raku + tests). This was rather more involved due to Raku's syntax, so this had to be hacked into the Signature deparsing.
lizmat I think I got all of the pod declarator cases covered now
09:53 linkable6 left, evalable6 left 09:54 linkable6 joined, evalable6 joined
nine nqp::istype($!type.IMPL-TARGET-TYPE, RakuAST::Type::Definedness) 10:02
There's a lot about types in a compiler...
lizmat nine: you're saying I should check all classes doing RakuAST::Type::Definedness for declarator pod ? 10:08
nine No, no, no, that's from my work on parameter checks 10:09
I just found it funny how often the word "type" can fit into such little code :)
lizmat typical :-) 10:16
timo1 type, type, type, type, eggs, bacon, and type 10:35
10:55 linkable6 left, evalable6 left 10:56 linkable6 joined 10:57 evalable6 joined 12:00 reportable6 left 12:02 reportable6 joined
Geth rakudo/main: cecba5a4c5 | (Elizabeth Mattijsen)++ | 5 files
RakuAST: allow doc blocks in statement lists

It is now possible to put RakuAST::Doc::Blocks in statement lists, and still have them EVAL correctly, as if they're not there. This is achieved by checking all of the statement list logic for doc blocks and omitting them for further handling.
... (10 more lines)
13:52 evalable6 left, bisectable6 left, reportable6 left, nativecallable6 left, coverable6 left, statisfiable6 left, sourceable6 left, squashable6 left, releasable6 left, committable6 left, notable6 left, shareable6 left, bloatable6 left, linkable6 left, quotable6 left, benchable6 left, greppable6 left, tellable6 left, unicodable6 left, committable6 joined, squashable6 joined 13:53 benchable6 joined, unicodable6 joined, greppable6 joined, bloatable6 joined, quotable6 joined, coverable6 joined, evalable6 joined, bisectable6 joined 13:54 statisfiable6 joined, releasable6 joined, nativecallable6 joined, linkable6 joined, shareable6 joined, reportable6 joined, sourceable6 joined 13:55 tellable6 joined, notable6 joined 16:09 tellable6 left, reportable6 left, sourceable6 left, unicodable6 left, nativecallable6 left, quotable6 left, committable6 left, shareable6 left, squashable6 left, bloatable6 left, benchable6 left 16:10 bloatable6 joined, sourceable6 joined, unicodable6 joined 16:11 shareable6 joined, tellable6 joined, squashable6 joined, reportable6 joined 16:12 committable6 joined, benchable6 joined, quotable6 joined, nativecallable6 joined
Geth rakudo/main: e42ecff09f | (Elizabeth Mattijsen)++ | 5 files
RakuAST: some class renaming

RakuAST::Doc::Block -> RakuAST::Doc::Formatted RakuAST::Doc::Basic -> RakuAST::Doc::Block
This makes more sense semantically.
rakudo/main: 349050372f | (Elizabeth Mattijsen)++ | 6 files
RakuAST: remove some trailing whitespace
nine lizmat: main build seems broken: Could not build C3 linearization: ambiguous hierarchy 16:56
lizmat run configure ?
nine Ah, indeed! 16:58
lizmat *phew*
Geth rakudo/main: 4 commits pushed by (Stefan Seifert)++ 17:01
lizmat 748! :-) 17:11
17:33 linkable6 left, evalable6 left
Geth rakudo/main: 83f2cb8f2b | (Elizabeth Mattijsen)++ | src/Raku/ast/statements.rakumod
RakuAST: make setting up $!labels a bit more sane

Before, $!labels could be uninitialized, but then that would need to be checked in a lot of places. Now, just put an nqp::list in there if nothing was specified yet. In the end this should be at least neutral on number of allocations.
17:35 linkable6 joined, evalable6 joined 18:00 reportable6 left 18:02 reportable6 joined
nine nine@sphinx:~/rakudo (main =)> rakudo -e 'multi rt107638(int $a) { "ok" }; multi rt107638(Str $a where 1) { }; rt107638(1)' 18:05
nine@sphinx:~/rakudo (main =)> rakudo --optimize=0 -e 'multi rt107638(int $a) { "ok" }; multi rt107638(Str $a where 1) { }; rt107638(1)'
Cannot resolve caller rt107638(1); none of these signatures matches:
I think I've looked at this before... was there a verdict on whether that test is actually correct? I thought multis are a lot stricter about native vs. boxed types. Apparently the optimizer makes them more lenient if the value is a literal. 18:06
lizmat I would expect an ambiguous dispatch for that case, actually ? 18:09
nine m: class Foo { multi method rt107638(int $a) { "ok" }; multi method rt107638(Str $a where 1) { } }; Foo.rt107638(1) 18:13
camelia Cannot resolve caller rt107638((Foo): 1); none of these signatures matches:
(Foo: int $a, *%_)
(Foo: Str $a where { ... }, *%_)
in block <unit> at <tmp> line 1
nine It only works for multi subs because for those the optimizer tries to find a matching multi candidate and dispatch to that directly. And it's more lenient than the real binder. 18:14
But roast commit f8c706da4a7f594c58ddfd697bd0bf79cdcc704d indicates that this is indeed the desired behavior. 18:17
18:18 linkable6 left, linkable6 joined
nine And rakudo commit 1c0ed61a44420bba728b3da6567e830637c09613 confirms that 18:19
Now I wonder if this is something, that should be handled by the AST classes directly, or if it will make a comeback as "optimization". The work itself would look like something you'd find in an optimizer, but the goal is certainly not just an optimization. 18:23
lizmat well, there are more cases like that. Like doing a QuotedRegex.new with only str literals. Maybe it should return a StrLiteral instead immediately ? 18:25
but I guess that would make manipulation harder :-(
nine But that _is_ just an optimization, isn't it?
lizmat yeah, but suppose the QuotedRegex is from an .AST call, and you'd like to change it before it is getting codegenned 18:26
nine So that is definitely something for a separate optimization pass.
lizmat m: say Q|"foo"|.AST.statements.head.expression 18:27
camelia RakuAST::QuotedString.new(
segments => (
nine What I don't like is that currently we require that optimization to correctly compile a Raku program.
lizmat yeah, that is something that shouldn't be necessary
Geth rakudo/main: d3b58a3487 | (Elizabeth Mattijsen)++ | 3 files
RakuAST: renamed StatementList.push -> add-statement

The .push is way too general, and in similar cases in other classes, the method to add stuff is always named "add-foo". So it seemed appropriate to do that for this case as well.
lizmat m: sub a() { 42; LEAVE say "hi" }; say a # should really be 42 18:37
camelia WARNINGS for <tmp>:
Useless use of constant integer 42 in sink context (line 1)
nine What's the syntax for calling a method of the base class in NQP?
lizmat "the base class" ??
nine Or rather a base class' method
RakuAST::PointyBlock::PRODUCE-META-OBJECT wants to call RakuAST::Block::PRODUCE-META-OBJECT 18:38
18:40 guifa_ joined
lizmat nine: I think you're out of luck there :-( 18:40
nextsame and friends are HLL constructs, aren't they? 18:41
nine yes
18:43 guifa left
nine self.IMPL-PRODUCE-META-OBJECT it is then 18:46
lizmat explain?
nine A second name for that method 18:47
19:54 squashable6 left 19:55 squashable6 joined 20:05 japhb left 20:06 japhb joined 21:11 squashable6 left, bloatable6 left, tellable6 left, quotable6 left, unicodable6 left, linkable6 left, sourceable6 left, shareable6 left, releasable6 left, notable6 left, reportable6 left, benchable6 left, statisfiable6 left, bisectable6 left, nativecallable6 left, committable6 left, greppable6 left, releasable6 joined, committable6 joined, quotable6 joined 21:12 squashable6 joined, nativecallable6 joined, tellable6 joined, unicodable6 joined 21:13 shareable6 joined, statisfiable6 joined, benchable6 joined, reportable6 joined, linkable6 joined, bloatable6 joined 21:14 notable6 joined, greppable6 joined, bisectable6 joined, sourceable6 joined 21:45 sena_kun left
ugexe can it be called by its full name? like self.ParentClass::method-name(...)? I 21:51
lizmat afaik, that's also a HLL construct 21:59
it's not called NQP for nothing :-)
sleep& 22:11
22:45 linkable6 left, evalable6 left 22:46 evalable6 joined 22:48 linkable6 joined