[00:03] *** Doc_Holliwould left
[00:05] *** neshpion left
[00:06] *** neshpion joined
[00:11] *** gnufr33dom joined
[00:23] *** wamba left
[00:46] *** squashable6 left
[00:47] *** squashable6 joined
[01:39] *** mowcat left
[02:21] *** JRaspass left
[02:39] *** kvw_5_ joined
[02:42] *** kvw_5 left
[03:04] *** Manifest0 left
[03:06] *** Manifest0 joined
[03:23] *** neshpion left
[03:29] *** vike left
[03:32] *** vike joined
[03:42] *** shlomif2 is now known as rindolf

[03:45] *** leont left
[03:49] *** neshpion joined
[03:52] *** neshpion left
[03:52] *** neshpion joined
[03:57] *** neshpion left
[03:58] *** neshpion joined
[04:00] *** vike left
[04:30] *** epony left
[04:31] *** vike joined
[04:59] *** epony joined
[05:24] *** gnufr33dom left
[05:54] *** parabolize left
[06:04] *** gnufr33dom joined
[06:15] *** neshpion left
[06:24] *** kaiwulf left
[06:56] *** Doc_Holliwould joined
[07:05] *** orinthe7 joined
[07:08] *** orinthe left
[07:09] *** orinthe joined
[07:10] *** orinthe7 left
[07:45] *** gnufr33dom left
[08:00] *** berber44 joined
[08:03] *** Doc_Holliwood joined
[08:04] *** Doc_Holliwould left
[08:11] *** aborazmeh joined
[08:45] *** xinming_ left
[08:47] *** xinming_ joined
[08:58] *** pecastro joined
[09:35] *** wamba joined
[09:39] *** aborazmeh left
[09:52] *** kerframil left
[09:56] *** aborazmeh joined
[09:57] *** aborazmeh left
[10:00] *** aborazmeh joined
[10:17] *** Sgeo left
[10:26] *** berber44 left
[10:29] *** cetjs2 left
[10:32] *** Doc_Holliwood left
[10:37] *** aborazmeh left
[10:42] *** cetjs2 joined
[10:43] *** cetjs2 left
[10:59] *** lizmat left
[11:01] *** lizmat joined
[11:14] *** aborazmeh joined
[11:40] *** aborazmeh left
[11:45] *** aborazmeh joined
[11:55] *** squashable6 left
[11:56] *** squashable6 joined
[12:09] *** gnufr33dom joined
[12:15] *** berber44 joined
[12:19] *** leont joined
[12:22] *** berber44 left
[12:32] *** aborazmeh left
[12:51] *** cetjs2 joined
[13:05] *** patrickb joined
[13:22] *** mowcat joined
[13:26] *** wamba left
[13:30] <gfldex> lolibloggedalittle: https://gfldex.wordpress.com/2021/02/28/undocumented-escape-hatch/

[13:40] *** JRaspass joined
[13:43] *** aborazmeh joined
[13:45] *** gnufr33dom left
[14:09] *** mowcat left
[14:11] *** lizmat left
[14:12] *** lizmat joined
[14:46] <codesections> gfldex: I don't think that's really _undocumented_ (though I'm sure it could be clearer).  But the docs say that `given` is a statement and, in general, statements don't return a value -- but they *do* return a value when preceded by `do`, when wrapped in parentheses, or when they are the final element in a block. 

[14:47] <codesections> m: sub f() { my $a = 42 }; say f

[14:47] <camelia> rakudo-moar 726a75e24: OUTPUT: «42␤»

[14:51] *** wamba joined
[14:59] *** sxmx left
[15:04] *** kaiwulf joined
[15:13] *** sxmx joined
[15:18] *** parabolize joined
[15:19] *** stoned75 joined
[16:19] *** greppable6 left
[16:19] *** shareable6 left
[16:19] *** sourceable6 left
[16:19] *** releasable6 left
[16:19] *** bisectable6 left
[16:19] *** bloatable6 left
[16:19] *** unicodable6 left
[16:19] *** benchable6 left
[16:19] *** statisfiable6 left
[16:19] *** coverable6 left
[16:19] *** tellable6 left
[16:19] *** evalable6 left
[16:19] *** quotable6 left
[16:19] *** committable6 left
[16:19] *** notable6 left
[16:19] *** nativecallable6 left
[16:19] *** squashable6 left
[16:19] *** linkable6 left
[16:20] *** squashable6 joined
[16:20] *** benchable6 joined
[16:20] *** linkable6 joined
[16:20] *** nativecallable6 joined
[16:20] *** releasable6 joined
[16:20] *** notable6 joined
[16:21] *** bloatable6 joined
[16:21] *** shareable6 joined
[16:21] *** committable6 joined
[16:21] *** quotable6 joined
[16:21] *** bisectable6 joined
[16:21] *** unicodable6 joined
[16:21] *** tellable6 joined
[16:21] *** sourceable6 joined
[16:21] *** statisfiable6 joined
[16:22] *** greppable6 joined
[16:22] *** coverable6 joined
[16:22] *** evalable6 joined
[17:12] *** mowcat joined
[17:15] *** domidumont joined
[17:19] *** gnufr33dom joined
[17:22] *** berber44 joined
[17:27] *** Kaeipi left
[17:29] *** rindolf left
[17:31] *** aborazmeh left
[17:33] <gfldex> codesections: that succeed can return a value is undocumented.

[17:33] *** berber44 left
[17:35] *** aborazmeh joined
[17:41] *** rindolf joined
[17:49] *** brtastic joined
[18:00] *** sena_kun left
[18:07] *** sena_kun joined
[18:18] *** brtastic left
[18:23] *** Bucciarati joined
[18:32] *** domidumont left
[18:34] *** stoned75 left
[18:44] *** stoned75 joined
[18:47] *** Kaiepi joined
[18:48] *** kaiwulf left
[18:51] *** Doc_Holliwood joined
[18:51] *** gnufr33dom left
[19:07] *** sena_kun left
[19:08] *** sena_kun joined
[19:20] *** mowcat left
[19:29] *** mowcat joined
[19:39] *** aluaces left
[19:39] *** aluaces joined
[19:40] *** Sgeo joined
[20:05] <guifa> vrurg: it’s really nice though 

[20:06] <guifa> vrurg: what do you think should be the best approach, though, for role coercion where the role is fully stubbed?  

[20:08] <guifa> For my rewrite of LanguageTag, I was wanting to heed someone’s request for a light version

[20:11] <guifa> so I was thinking doing a role LanguageTaggish with stubbed methods.  Then I’d have my complete concrete implementation as class LanguageTag does LanguageTaggish.  But there’d be a lightway role, role LanguageTag::Light does LanguageTaggish that could be applied to strings that would calculate the methods on the fly (trading creation speed/memory footprint for slower method calls).

[20:12] <guifa> given a signature \(LanguageTaggish() $tag), how do you think I should best handle that circular dependency?  I could probably do the LanguageTaggish and the ::Light in one file, but the purist in me wants them in separate files ha

[20:28] *** lizmat left
[20:30] *** lizmat joined
[20:30] <guifa> codesections: oooh, I just found something potentially dangerous with does vs but

[20:30] <guifa> well, s/dangerous/performance killing

[20:31] <guifa> Role A { method a { ‘a’ } }; my @a; @a.push: ‘foo’ but A for ^100; say @a.tail.WHAT

[20:32] <guifa> m: Role A { method a { ‘a’ } }; my @a; @a.push: ‘foo’ but A for ^100; say @a.tail.WHAT

[20:32] <camelia> rakudo-moar 726a75e24: OUTPUT: «5===SORRY!5===␤Undeclared names:␤    A used at line 1␤    Role used at line 1␤␤Other potential difficulties:␤    Useless declaration of a has-scoped method in mainline (did you mean 'my method a'?)␤    at <tmp>:1␤    ------> 3Role…»

[20:32] <guifa> m: role A { method a { ‘a’ } }; my @a; @a.push: ‘foo’ but A for ^100; say @a.tail.WHAT

[20:32] <camelia> rakudo-moar 726a75e24: OUTPUT: «(Str+{A})␤»

[20:32] *** aborazmeh left
[20:33] <guifa> m: role A { method a { ‘a’ } }; my @a; @a.push: ‘foo’ does A for ^100; say @a.tail.WHAT

[20:33] <camelia> rakudo-moar 726a75e24: OUTPUT: «(Str+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A…»

[20:33] <guifa> even WORSE

[20:34] <guifa> (I’m guessing because strings are valuetypes and roles don’t affect that)

[20:34] <guifa> m: role A { method a { ‘a’ } }; my @a; @a.push: ‘foo’ does A for ^100; say ‘foo’.WHAT

[20:34] <camelia> rakudo-moar 726a75e24: OUTPUT: «(Str+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A}+{A…»

[20:37] <perry> AAAAA

[20:47] *** patrickb left
[20:53] <vrurg> guifa: you're trying to fit too much into too short sentence, perhaps. :) I don't see a circular dependency in your case but rather a clear tree with LanguageTaggish been the root and two branches.

[20:54] <guifa> vrurg: sorry! I’m know for being long-winded

[20:55] *** JRaspass left
[20:55] *** aborazmeh joined
[20:55] <vrurg> so am I, no worries. But this is certainly the opposite case. I either overlooking an important details, or you didn't mention it.

[20:56] <guifa> vrurg: I guess I’m concerned about LanguageTaggish.COERCE.  Since the Taggish role is abstract, it’ll need to apply the Tag::Light role or create a Tag class object

[20:58] *** xinming_ left
[20:59] <vrurg> guifa: why `self.new` in `CORECT` won't work for you? 

[20:59] *** xinming_ joined
[20:59] <guifa> because all of the relevant methods are stubbed, so it wouldn’t be a meaningful coercion

[21:00] <guifa> basically, this is what I have (simplified for only the language part) 

[21:01] <guifa> role Taggish { method language { … } }; role Taggish::Light does Taggish { method language { self.Str.split(‘-‘)[0] }; class Tag does Taggish { has $.language } 

[21:01] <vrurg> Aha, this is what I miss... 

[21:03] <vrurg> Then there is no really good solution. There is no way for COERCE to know what to convert into. I'd stub it too and provide implementations by the consuming classes/roles.

[21:05] <vrurg> But if you imply that by default LanguageTaggish coerces into ::Light then just import it run-time and use as ::('LanguageTaggish::Light').new

[21:05] <guifa> That’s true.  I’m just debating which one I prefer to be the default haha.

[21:06] <guifa> the “Light” is only light by memory footprint so far.  `but` isn’t exactly super fast compared to creating even moderately objects

[21:06] <guifa> moderately complex objects

[21:07] <vrurg> guifa: Actually, stubbing COERCE will not work as LanguageTaggish() would remain non-functional. So, only run-time import remains. 

[21:08] <vrurg> I would probably re-consider the model in a way to avoid LanguageTaggish() altogether. 

[21:09] <guifa> That’s also very fair.  There are a few other language tag models other than BCP47, so I was trying to come up with a way that would conceptually play well with them

[21:10] <guifa> Maybe I could just make the TagLight a class that has a single string attribute (extremely fast to make and coerce back into a Str) instead of a role to apply to a Str

[21:23] *** rindolf left
[21:47] *** wamba left
[22:10] *** aborazmeh left
[22:21] *** aborazmeh joined
[22:33] *** gnufr33dom joined
[22:49] *** neshpion joined
[23:07] *** dogbert11 joined
[23:07] *** xinming_ left
[23:08] *** xinming_ joined
[23:10] *** dogbert17 left
[23:24] *** xinming_ left
[23:25] *** xinming_ joined
[23:29] *** Discipulus left
[23:30] *** aborazmeh left
[23:48] *** kerframil joined
[23:53] *** JRaspass joined
