»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
00:02 kurahaupo_ left, BenGoldberg joined, kurahaupo__ joined 00:05 wamba joined, lmmx left 00:06 revere left 00:07 lmmx joined 00:08 revere joined 00:12 lmmx left, lmmx joined 00:15 bjz left 00:16 bjz joined 00:20 mr_ron joined 00:21 pmurias left 00:41 Ben_Goldberg joined, BenGoldberg left, Ben_Goldberg is now known as BenGoldberg 00:44 BenGoldberg left, bjz left 00:45 cpage_ left 00:46 bjz joined, BenGoldberg joined, agentzh joined 00:48 cdg left 00:49 ChoHag left 00:50 agentzh left 00:54 kurahaupo_ joined, kurahaupo_ left 00:55 kurahaupo_ joined, kurahaupo__ left 00:56 bjz left, espadrine_ left, TeamBlast left, kurahaupo__ joined 00:58 ocbtec left 00:59 TeamBlast joined 01:00 kurahaupo_ left 01:02 cpage_ joined 01:04 bjz joined 01:11 BenGoldberg left 01:15 bpmedley left 01:30 wamba left 01:35 cale2 joined 01:49 agentzh joined 01:56 mr_ron left 01:57 bpmedley joined 02:03 NeuralAnomaly_ left, NeuralAnomaly_ joined, ChanServ sets mode: +v NeuralAnomaly_
brokenchicken .tell faraco If you wish to be listed as something other than faraco in future Rakudo releases, please add yourself to github.com/rakudo/rakudo/blob/nom/CREDITS 02:05
yoleaux brokenchicken: I'll pass your message to faraco.
cale2 Hey what do you guys think of Haskell? Ever tried to learn? 02:06
brokenchicken One of earlier Perl 6 compilers was written in Haskell
And many people who know it point out Perl 6's FP suckiness 02:07
:)
cale2 I knew about Pugs. But it seems like Audrey (was that who wrote it?) was one of the few that actually worked in Haskell 02:08
brokenchicken I think she's the one who started it yeah
geekosaur several of us know Haskell... but not as well as Audrey. (I've lost count of the number of times I've hit the Pugs source and bounced) 02:10
cale2 I'd love to talk with her about her experiences in both worlds
Because she must have thought Haskell wasn't as fun as Perl6 since the whole "optimised for fun" thing came around that time :D 02:11
geekosaur: you're literally in the haskell room with me. Are you an imposter? 02:12
geekosaur ?
cale2 geekosaur: There's a person with your name in #haskell 02:14
geekosaur yes, that would be me. is there some rule I'm only allowed to be in one channel at a time? 02:15
TimToady cale2: what is this, tribalism of some sort?
yoleaux 20 Jan 2017 08:48Z <AlexDaniel> TimToady: so is this supposed to warn? 'hello' [&say] 'world'
20 Jan 2017 08:48Z <AlexDaniel> TimToady: github.com/rakudo/rakudo/commit/acece7b2f7 (#00007997)
geekosaur (in fact I started hanging out in here and in #haskell in 2006, several months apart)
cale2 geekosaur: I'm just joking. I figured everyone else in the haskell channel knew the language. 02:16
TimToady We need people who live in one village all their lives, and we need people who go from village to village exchanging good things. That's anthropology. 02:17
cale2 I don't really know the culture of IRC yet. For example, I never knew freenode and mozilla were different IRC networks altogether
02:18 cpage_ left
cale2 TimToady: That's a good thought to have. It produces utterly wild things like this: github.com/timo/ADT 02:19
geekosaur sadlyI think my only contribution to perl6 was, in attempting to implement the file test ops in pugs, causing their syntax to get changed from p5's -X to adverbial :X --- and in asking aquestion about how -s was to work, kicking the legs out from under the original smart match implementation
:)
brokenchicken :) 02:20
TimToady we're officially okay with not knowing things here, at least temporarily, as long as it doesn't veer off into "what you know that ain't so", like some politicians I could name...
02:20 hartenfels joined 02:22 cpage_ joined 02:31 mr_ron joined
cale2 I know there is argument destructuring in p6, but what about matching of specific values that are passed in? 02:39
multi one(1) { true }; multi one(x) { false }; 02:40
brokenchicken That works too 02:42
For Str a Numerics
*and 02:43
but it's really sugar for adding a `where` clause and with it you can match whatever you want
m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $ .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 31337 02:44
camelia rakudo-moar 121e5e: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Malformed parameter␤at <tmp>:1␤------> 3! awesome num!" }; multi good-num (Int $7⏏5 .is-prime) { say "tis good!" }; multi g␤ expecting any of:␤ constraint␤»
brokenchicken m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $ where .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 31337
camelia rakudo-moar 121e5e: OUTPUT«tis good!␤»
brokenchicken m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $ where .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 2
camelia rakudo-moar 121e5e: OUTPUT«w00t! awesome num!␤»
brokenchicken m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $ where .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 42
camelia rakudo-moar 121e5e: OUTPUT«meh␤»
brokenchicken See also perl6advent.wordpress.com/2016/12/...6-subsets/ 02:45
And perl6.party/post/Perl-6-Types--Made-for-Humans 02:46
02:48 ilbot3 joined
cale2 m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $x where x.is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 3 02:48
camelia rakudo-moar 121e5e: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Undeclared routine:␤ x used at line 1␤␤»
cale2 m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int $_ where .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 3
camelia rakudo-moar 121e5e: OUTPUT«tis good!␤»
cale2 So you don't need the underscore in the special placeholder variable anymore
02:51 lmmx left
brokenchicken $ is an anon var 02:52
m: for ^10 { say $++; $++ andthen .is-prime andthen .say; '|'.say } 02:53
camelia rakudo-moar 096cee: OUTPUT«0␤False␤|␤1␤False␤|␤2␤True␤|␤3␤True␤|␤4␤False␤|␤5␤True␤|␤6␤False␤|␤7␤True␤|␤8␤False␤|␤9␤False␤|␤»
MasterDuke m: multi good-num (2) { say "w00t! awesome num!" }; multi good-num (Int where .is-prime) { say "tis good!" }; multi good-num (Numeric) { say "meh" }; good-num 3
camelia rakudo-moar 096cee: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Cannot do non-typename cases of type_constraint yet␤at <tmp>:1␤------> 3" }; multi good-num (Int where .is-prime7⏏5) { say "tis good!" }; multi good-num (N␤»
MasterDuke i've never actually seen that ^^^ error message before
cale2 I thought $_ was the anon var 02:55
maybe I'm thinking of something else
brokenchicken It's a topic variable
02:56 NeuralAnomaly_ left, NeuralAnomaly_ joined, ChanServ sets mode: +v NeuralAnomaly_ 02:57 NeuralAnomaly_ left
cale2 Is kyclark in here? 02:57
02:58 NeuralAnomaly_ joined, ChanServ sets mode: +v NeuralAnomaly_
cale2 Just realized instead of teaching OOP in his book, he could have made DNA a subset of Str that only includes ACGT, for example 02:58
MasterDuke he's here sometimes 02:59
brokenchicken That'd be pretty damn slow
MasterDuke .seen kyclark
yoleaux I saw kyclark 9 Dec 2016 20:20Z in #perl6: <kyclark> But my boss says that my book should be able to count for my master’s thesis. Doubleplusgood! I will keep working on it.
cale2 Oh wait, but maybe a subset is the same thing as a class that inherets
02:59 zacts joined
brokenchicken Nope. You can't even instantiate a subset 02:59
02:59 parv joined, NeuralAnomaly_ left
cale2 class DNA { is Str } === subset DNA of Str where blablabla 02:59
what are the pros and cons there
Ah, I see 03:00
03:00 NeuralAnomaly left
cale2 But a subset is still a Type or it still creates a Type Object 03:00
03:02 NeuralAnomaly joined, ChanServ sets mode: +v NeuralAnomaly
MasterDuke m: my subset DNA of Str where /^<[ACGT]>+$/; say DNA.WHAT; 03:03
camelia rakudo-moar 096cee: OUTPUT«(DNA)␤»
brokenchicken m: subset Foo where 42; dd Foo.HOW; dd Int.HOW
camelia rakudo-moar 096cee: OUTPUT«Perl6::Metamodel::SubsetHOW.new␤Perl6::Metamodel::ClassHOW.new␤»
cale2 m: class Foo {}; dd Foo.HOW; 03:04
camelia rakudo-moar 096cee: OUTPUT«Perl6::Metamodel::ClassHOW.new␤»
03:04 agentzh left 03:05 BenGoldberg joined 03:07 agentzh joined 03:12 NeuralAnomaly left
cale2 I recently got a cat. She's just discovered things moving on my computer screen. The letters appearing as I type. The mouse moving. It's great 03:19
03:21 kurahaupo_ joined
brokenchicken Mine just lies in wait at the entrance to my room so she could harass me for food when I get up to pee: i.imgur.com/pz1AGFJ.jpg 03:23
03:24 kurahaupo__ left
TEttinger cale2: I have one cat who's only truly happy when he's in a tent-like structure in an unused bed, and another cat who can't get enough of the mouse cursor on a computer or tennis balls on the TV 03:25
thankfully, no claws used on the screen 03:26
cale2 brokenchicken: You have a lovely cow.
TEttinger that's a rorschach test cat, quite patterned
cale2 TEttinger: I let mine punch the screens sometimes. She never uses her claws, so I don't mind
03:27 kurahaupo_ left 03:43 parv left
cale2 m: subset Int-Str of Cool where $ %% 2 or $ ~~ "cale"; my Int-Str $thing = 4; 03:45
camelia rakudo-moar 8b94fa: OUTPUT«Use of uninitialized value of type Any in numeric context␤ in any accepts_type at gen/moar/Metamodel.nqp line 3444␤»
03:45 NeuralAnomaly joined, ChanServ sets mode: +v NeuralAnomaly
cale2 strange error. don't know. 03:45
brokenchicken It's not an error, it's a warning. 03:46
And that `where` clause makes no sense
m: subset Int-Str of Cool where $_ %% 2 or $_ ~~ "cale"; my Int-Str $thing = 4; 03:47
camelia ( no output )
cale2 So you need the $_ in a where clause, but not as an anonymous var 03:49
brokenchicken Not "need" but can use :) 03:50
m: subset Int-Str of Cool where -> $woot { $woot %% 2 or $woot ~~ "cale" }; my Int-Str $thing = 4;
camelia ( no output )
geekosaur anonymous vars are something else. a Whatever could also be used but only if it only occurs once
03:50 noganex_ joined
cale2 m: subset Int-Str of Cool where $_ %% 2 or $_ ~~ "cale"; my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2 03:50
camelia rakudo-moar be6dc6: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5caleeee' (indicated by ⏏)␤ in any accepts_type at gen/moar/Metamodel.nqp line 3444␤ in block <unit> at <tmp> line 1␤␤Actually thrown at:␤ in any …»
brokenchicken The where stuff gets thunked and so $_ has the arg given to it when the thing being checked is smartmatched against it 03:51
geekosaur probably something like $^a should work as well
brokenchicken prolly'll need a block
03:51 mr-foobar left
brokenchicken m: subset Int-Str of Cool where $^z %% 2 or $^z ~~ "cale"; my Int-Str $thing = 4; 03:51
camelia rakudo-moar be6dc6: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Cannot use placeholder parameter $^z outside of a sub or block␤at <tmp>:1␤------> 3subset Int-Str of Cool where $^z7⏏5 %% 2 or $^z ~~ "cale"; my Int-Str $thin␤»
brokenchicken mhm
m: subset Int-Str of Cool where { $^z %% 2 or $^z ~~ "cale" }; my Int-Str $thing = 4;
camelia ( no output )
cale2 Yeah, ok. So the where clauses won't work so great with Cool types
brokenchicken ? What do you mean? 03:52
cale2 If you assign a string, it fails on the first %% check because that operator expects a number
geekosaur reorder it
brokenchicken Sure, but that has little to do with where clauses :)
m: subset Int-Str of Cool where try { $_ %% 2 } or $_ ~~ "cale"; my Int-Str $thing = 4; my Int-Str $thing2 = "cale"; 03:53
camelia rakudo-moar be6dc6: OUTPUT«Use of uninitialized value of type Any in numeric context␤ in block at <tmp> line 1␤Use of uninitialized value of type Any in numeric context␤ in block at <tmp> line 1␤»
brokenchicken screw you
geekosaur if you request it as a number it will try to convert; test the strings first. ("or" will shortcircuit)
cale2 I guess you could put the first check inside of a try-catch lol
right
geekosaur m: subset Int-Str of Cool where $_ ~~ "cale" or $_ %% 2; my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«WARNINGS for <tmp>:␤Useless use of "%%" in expression "$_ %% 2" in sink context (line 1)␤Use of uninitialized value of type Any in numeric context␤ in block <unit> at <tmp> line 1␤Type check failed in assignment to $thing; expected Int-Str but got…»
geekosaur mm, block foo
or at leats parens; "or" is very low precedence 03:54
03:54 noganex left
geekosaur m: subset Int-Str of Cool where ($_ ~~ "cale" or $_ %% 2); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2 03:54
camelia rakudo-moar be6dc6: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5caleeee' (indicated by ⏏)␤ in any accepts_type at gen/moar/Metamodel.nqp line 3444␤ in block <unit> at <tmp> line 1␤␤Actually thrown at:␤ in any …»
brokenchicken heh
cale2 "Useless use of %%" That's a bit negative sounding haha
geekosaur that seems wrong
cale2 It's USELESS
geekosaur or is or not shortcircuiting any more?
brokenchicken m: subset Int-Str of Cool where ($_ ~~ "cale" or $_ %% 2 or False); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5caleeee' (indicated by ⏏)␤ in any accepts_type at gen/moar/Metamodel.nqp line 3444␤ in block <unit> at <tmp> line 1␤␤Actually thrown at:␤ in any …»
brokenchicken geekosaur: it got no reason to shortcurcuit 03:55
geekosaur uhhhhh
brokenchicken Now... it sucks "blah" %% 2 doesn't end up with a Failure :/
m: $ = "foo" %% 2;
camelia rakudo-moar be6dc6: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5foo' (indicated by ⏏)␤ in block <unit> at <tmp> line 1␤␤Actually thrown at:␤ in block <unit> at <tmp> line 1␤␤»
brokenchicken m: subset Int-Str of Cool where ($_ ~~ "cale" or try $_ %% 2); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«Use of uninitialized value of type Any in numeric context␤ in code at <tmp> line 1␤Use of uninitialized value of type Any in numeric context␤ in code at <tmp> line 1␤4␤caleeee␤»
geekosaur m: say so "caleeee" ~~ "cale" 03:56
camelia rakudo-moar be6dc6: OUTPUT«False␤»
brokenchicken whatchutalkingaboot...
m: subset Int-Str of Cool where { $^x ~~ "cale" or try $x %% 2 }; my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«Type check failed in assignment to $thing2; expected Int-Str but got Str ("caleeee")␤ in block <unit> at <tmp> line 1␤␤»
geekosaur wait, why was this using ~~ with a Str?
m: subset Int-Str of Cool where ($_ ~~ /cale/ or $_ %% 2); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2 03:57
camelia rakudo-moar be6dc6: OUTPUT«4␤caleeee␤»
brokenchicken TIMTOADY eh? :)
Oh is that what it was meant to be checking for? :)
geekosaur although p5-sense wants that to have coerced to regex :p
brokenchicken heh'
03:57 mr-foobar joined
geekosaur (yes, I know) 03:57
brokenchicken s: &infix:<%%>, \("x", 2)
SourceBaby brokenchicken, Sauce is at github.com/rakudo/rakudo/blob/8b94...ic.pm#L218
cale2 smart matcher does work fine with strings though, right? 03:58
brokenchicken I guess it makes sense that it throws 'cause we're using the thing as a value
cale2: yes
m: subset Int-Str of Cool (where $_ eq "cale" or .Numeric andthen $_ %% 2); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2 04:00
camelia rakudo-moar be6dc6: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Two terms in a row␤at <tmp>:1␤------> 3subset Int-Str of Cool7⏏5 (where $_ eq "cale" or .Numeric andthen␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ …»
brokenchicken m: subset Int-Str of Cool where ($_ eq "cale" or .Numeric andthen $_ %% 2); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«WARNINGS for <tmp>:␤Useless use of "%%" in expression "$_ %% 2" in sink context (line 1)␤Type check failed in assignment to $thing2; expected Int-Str but got Str ("caleeee")␤ in block <unit> at <tmp> line 1␤␤»
brokenchicken :S
uselessuseofuselessues 04:01
m: subset Int-Str of Cool where ($_ eq "cale" or .Numeric andthen $_ %% 2 or False); my Int-Str $thing = 4; my Int-Str $thing2 = "caleeee"; say $thing; say $thing2
camelia rakudo-moar be6dc6: OUTPUT«Type check failed in assignment to $thing2; expected Int-Str but got Str ("caleeee")␤ in block <unit> at <tmp> line 1␤␤»
cale2 Interesting blog post: www.thegrumpyprogrammer.com/2014/07...mming.html 04:03
brokenchicken It's also interesting to see the mention of 64-bit being the norm RIGHT after the previous statemtn that Moorse law is unstoppable :) 04:06
04:09 matiaslina joined 04:10 cale2 left
brokenchicken m: say 183 - 26 04:10
camelia rakudo-moar be6dc6: OUTPUT«157␤»
brokenchicken pretty dam' big changelog this release
brokenchicken hopes for an even bigger one next month, now that we got two new core members :P 04:13
04:19 brokenchicken left 04:20 BenGoldberg left 04:21 brokenchicken joined, brokenchicken left, brokenchicken joined 04:22 kyan left 04:29 NeuralAnomaly left 04:30 NeuralAnomaly joined, ChanServ sets mode: +v NeuralAnomaly 04:31 jdmmmmm joined 04:35 AlexDaniel joined
AlexDaniel . 04:35
04:36 Todd joined, japh-com joined
Todd I am trying to install "inline" into perl6 for windows 7. I downladed clone and ran panda from its dirctory 04:36
C:\Drivers\Perl\Inline\Inline-Perl5-master>panda --notests --force install . ==> Installing Inline::Perl5 from a local directory '.' ==> Fetching Inline::Perl5 ==> Building Inline::Perl5 'nmake' is not recognized as an internal or external command, operable program or batch file. The spawned process exited unsuccessfully (exit code: 1) in method build at C:\Drivers\Perl\Inline\Inline-Perl5-master\.panda-work\148 973317_1/Build.pm line
'nmake' is not recognized 04:37
how do I fix this?
araraloren You should use visual stduio tools command prompt 04:38
Todd I have used it before, but I can't figure out what it is called now. What is it called? 04:40
04:40 japh-com left
Todd Git-cmd by chance? 04:41
araraloren You can find a batch file `vscarsall.bat`, before you run panda run it
in mcirosoft visual stduio installation directory 04:42
such as `Program Files (x86)\Microsoft Visual Studio 14.0\VC`
04:42 faraco joined
Todd no such animal 04:43
same problem when run from git-cmd
what I thought I used before was git-cmd
araraloren Did you have VS201X installation ?
git-cmd ?
04:44 parv joined
Todd where? 04:45
araraloren So, do you have a complier in your pc ? 04:47
s/complier/compiler/ 04:48
Todd No and I thought panda didn't need one ??? 04:49
geekosaur for nmake I suspect you need go.microsoft.com/fwlink/?LinkId=69...lcid=0x409
(visual studio community edition) 04:50
araraloren Todd, panda didn't need that, Inline::Perl5 need that
Todd I am installing it 04:52
It says it need 7GB. Is that normal? 04:53
araraloren Yeah, you can make a custom install 04:54
geekosaur I think there might be a command line tools also, that's a full IDE 04:55
araraloren Actually it is existed
Todd I think at this point it would be better for me to switch back to Perl 5. There will be other things to code in 6 in the future
araraloren Windows sdks privides that tools, maybe 04:56
Todd Mainly becasue I have to role this out acros multiple computers and can't have a YUGE installation proceedure
araraloren Use Perl6 under linux should have more comfortable ..
Todd I don't care for Windows much, but if I want to feed myself, I am stuck with it 04:57
araraloren Yeah .. 04:58
Todd Thank you guys for the help! bye bye 05:00
05:00 Todd left 05:03 abruanese left
[Coke] yawns. 05:06
araraloren I think the new version rakudo install become faster .. 05:09
brokenchicken yup 05:12
05:12 itcharlie joined 05:19 matiaslina left 05:23 parv left 05:26 bjz left 05:31 Cabanossi left 05:32 kurahaupo__ joined 05:34 Cabanossi joined, mr_ron left
[Coke] upgrades to 2017.01… 05:44
05:48 bjz joined, cognominal left
[Coke] man, making docs is still really slow. :| 06:02
Geth oc: 388a1d8098 | (Will "Coke" Coleda)++ | highlights/highlight-file.coffee
Remove debug output
06:04
06:05 geekosaur left 06:06 geekosaur joined, kurahaupo__ left 06:08 labster1 joined 06:09 labster left, labster1 left 06:12 labster joined 06:13 mr_ron joined
[Coke] does does use sass while perl6.org does not? 06:13
*does docs
06:20 hartenfels left
[Coke] m: say chr(39) 06:21
camelia rakudo-moar 0c8929: OUTPUT«'␤»
06:45 TimToady joined
faraco m: say Int 'cow'; 06:45
camelia rakudo-moar 0c8929: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Two terms in a row␤at <tmp>:1␤------> 3say Int7⏏5 'cow';␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ statement end␤ statement modifier␤ …»
yoleaux 02:05Z <brokenchicken> faraco: If you wish to be listed as something other than faraco in future Rakudo releases, please add yourself to github.com/rakudo/rakudo/blob/nom/CREDITS
faraco .ask brokenchicken "Oh, thanks for mentioning that!" 06:48
yoleaux faraco: I'll pass your message to brokenchicken.
06:57 CIAvash joined 07:11 jdmmmmm left 07:23 mr_ron left 07:27 itcharlie left 07:53 Tonik joined 08:17 bjz left 08:29 bjz joined 08:33 labster left 08:34 labster joined 08:52 darutoko joined 08:58 pecastro joined 09:08 rindolf joined 09:14 faraco left 09:17 rindolf left 09:19 RabidGravy joined 09:20 TimToady left 09:21 aborazmeh joined, aborazmeh left, aborazmeh joined 09:22 TimToady joined 09:27 rindolf joined 09:34 ChoHag joined 09:39 faraco joined
faraco hi 09:40
RabidGravy morning 09:42
faraco :D
09:43 faraco left 10:05 labster left 10:08 mr_ron joined 10:22 faraco joined
faraco Hmm, why, 'ufo' still included in Task::Star installation? 10:22
Isn't it deprecated?
10:23 espadrine_ joined 10:27 MrMebelMan joined
MrMebelMan Hi! 10:27
faraco Afternoon. 10:28
timotimo aye, it is 10:29
should probably be thrown out :)
faraco and, does anything else (core) depends on ufo? I gonna made a pr to task-star, if okay. 10:33
oh nevermind 10:34
zoffix opened an issue about Task::Star - github.com/tadzik/Task-Star/issues/13
10:38 Actualeyes left
RabidGravy mind you I've probably still got modules that mention it in their README 10:39
timotimo nothing depends on it, aye
potentially, yeah
we have all-modules for that
RabidGravy simply because I haven't got round to updating them
timotimo yup, there's a whole lot of 'em 10:40
gist.github.com/timo/2a04435099e22...b8d67dd3f6 10:41
you definitely do lead the bunch 10:42
faraco erm, so there is Getopt::Long, but..the documentation is just. Erm. Any alternative for, *right now*? 10:43
timotimo :( 10:47
10:48 parv joined
timotimo there's Getopt::std which doesn't give you long options 10:48
RabidGravy well, apparently 23 of my modules mention "ufo" in their README 10:49
timotimo yup.
faraco timotimo: thanks!
timotimo that happens when you copy-paste the same readme over all your projects :)
RabidGravy maybe I'll spend some time fixing that today
timotimo why not let someone write a script that goes through all modules in my list and makes pullrequests? 10:50
i.e. pop open an editor for each, in turn, and go
actually ...
10:50 agentzh left
timotimo gimme just a sec 10:50
RabidGravy for mine it's probably a sign that the README needs some love and also the META.info needs renaming to META6.json 10:52
10:52 wamba joined
timotimo fails to figure out how to insert text at the beginning of a line in sed without using s/ 10:53
10:54 bjz left
RabidGravy I've been using sed forever and I still have to look things up when it's more complex than s//// 10:54
timotimo ugh, i hate not knowing what i have to backslash and what not 10:55
i'll just use perl6 instead
gist.githubusercontent.com/timo/2a...tfile1.txt 10:58
they're not clickable, though. just a moment :)
hack.p6c.org/~timo/readmes_with_ufo.html 11:01
knowk yourself out. a few lines are missing, though
11:02 Actualeyes joined
timotimo ah, a few lines there don't have a user in front of the module name 11:02
faraco still not understand advance regex.
timotimo p6-Linux-Fuser and p6-Linux-Cpuinfo 11:03
... "knowk your self out" m)
moritz faraco: who ever does? :-) 11:04
RabidGravy I'm going in with gist.github.com/jonathanstowe/56a9...53c8ab1502
timotimo moritz: got an idea why those two modules in your all-modules repo don't have a github user in their path? 11:05
RabidGravy: if you have permissions for that, sure
RabidGravy just my modules
so yeah I have permission
faraco moritz: I feel bad. Using both Perl and Perl 6, also grep and sed. Yet, only know how to use s/blah/ploof/g, and any other simple construct of regex. :'( 11:06
but hey, I'm getting there.
moritz timotimo: no idea :( 11:07
timotimo moritz: is it time for another update of the repo? :) 11:08
last commit on 17 sep 2016
11:09 domidumont joined
moritz timotimo: as soon as the fix for github.com/ingydotnet/git-subrepo/issues/225 is merged, yes 11:09
11:11 azawawi joined
azawawi Hi 11:11
11:11 Tonik left
faraco hi 11:12
timotimo oh!
right, that was A Thing 11:13
azawawi github.com/apple/swift/blob/master...nifesto.md # swift 4 string processing goal to be better than Perl
timotimo i see there has been a branch for you. cool!
huh.
"better at string processing than perl!"
that's the wrong perl to try to be better than
faraco hah 11:14
11:14 domidumont left
moritz timotimo: i'm trying to update perl6-all-modules with the branch now 11:14
faraco++ got PR #1000 on Rakudo! 11:15
azawawi Let them try lol
11:15 domidumont joined, lukaramu joined
azawawi Swift API is a mess 11:15
Objective c all over 11:16
faraco what
timotimo we should look if they do anything better than us and then improve our stuff by stealing their best shit
BBL
faraco Oh, the exact #1000. I just realized.
azawawi Well their defer block is cool. It is like leave 11:17
Consider me an undercover swift agent working for perl6 lol 11:20
Swift main problem is their API is not swifty enough 11:21
faraco Caught you red handed. :P
azawawi But apple is known for forcing change on their developer base and succeeding 11:22
They forced named parameters and then introduced a workaround around it by adding a underscore and then a space 11:26
Now most swift code is littered with lonely underscores 11:27
11:31 azawawi left 11:33 Actualeyes left 11:34 mr_ron left 11:35 ChoHag left, lukiramu joined 11:37 bjz joined 11:38 lukaramu left 11:39 Actualeyes joined 11:45 kalkin- joined
kalkin- hi #perl6 11:46
XMPP provides different auth mechanism via SASL. The server tells me the supported mechanisms it can use. The current Net::XMPP library implements only one method (PLAIN). What would be the most perlish way to extend it to be future proof for any new mechanisms, while not hardcoding them in Net::XMPP? 11:48
My first thought would be doing dependency injection and provide my custom auth mechanisms during initialization 11:49
11:49 faraco left
kalkin- Another Idea would be to provide a custom role MyAuth and do in my client Net::XMPP does MyAuth and overwrite this way the Net::XMPP auth mehtod (which currently doesn't exists, but can be patched) 11:50
A third way would be to provide during initialization an hash consisting of AUTH-MECHANISM => MyAuthRouting() 11:51
RabidGravy runtime application of the role, probably keyed on the name provided in the Auth header 11:56
I've done something similar in some code, I'll have a look in a bit after I've finished with these READMEs 11:57
kalkin- RabidGravy: “runtime application of the role” ← I understand that, but I'm not sure what you mean by → keyed on the same name … How do I do this with a role? (Btw no rush, I like the async nature of IRC ☺ ) 11:59
11:59 aborazmeh left
RabidGravy well 12:01
I think something like "role FooAuth does AuthMethod is auth-name('foo") { ... }" and when the server presents the Auth header with "foo" as a supported auth method you look for the AuthMethods you have which have an auth-name of "foo" 12:02
pr something 12:03
kalkin- RabidGravy: Why is it better then AuthMethod role having just a method auth-name which returns 'foo'? (I'm not arguing, just asking for better understanding of perl6) 12:04
RabidGravy I'm not sure it is better, it's just how I would do it :) 12:05
kalkin- hmm, on the other hand this way it's explicit in the code 12:06
RabidGravy it feels to me that it is meta-information about the auth type and should really be in the Meta Object rather than in the implementation
and that the auth framework should take care of the actual identification however it sees fit
kalkin- I see, thank you for your explanation 12:07
I think I need to refresh my memory on the “is” keyword.
kalkin- is going back to reading docs
RabidGravy an alternative to the above would be to parameterize the AuthMethod role with the nane which may be clearer 12:08
i.e. "role FooAuth does AuthMethod["foo"] { }"
some people get confused when "is" is repurposed for a trait application other than inheritance 12:09
timotimo when you have the "is auth-name" trait, you can register them globally 12:12
if you just hvae a .auth-name method, you'll have to rely on some code finding your role for you and calling that method
kalkin- timotimo: how would I list all is auth-name traits?
Should I iteratare over all available modules in CUR for that? 12:13
timotimo have a package-scoped hash and implement the auth-name trait to stuff it in there
or something like that, yeah
RabidGravy yeah, I'm using a similar technique in Sofa for defining "methods" to rest paths
kalkin- timotimo: I didn't want to provide it in Net::XMPP package, but wanted people to provide them from outside
so search in CUR 12:14
timotimo of course
yeah, search in CUR would be best unless you're fine with users of your package also pulling in the other auth mechanisms so they register themselves
.o( though i wonder how it interplays with precompilation when every module stuffs a class of their own into that array )
RabidGravy right that's ufo ridded from all of my modules :) 12:16
12:17 hankache joined
timotimo nice 12:17
kalkin- Btw there is no way currently to specify optional dependencies in META6?
timotimo don't think so 12:18
kalkin- K, I haven't found anything in S22 either or in jnthn's META6 package
Thank you both for you help and time
timotimo sure thing 12:19
hankache no syntax highlighting on docs.perl6.org/ :( 12:20
12:20 mr_ron joined, Actualeyes left
hankache que pasa? 12:20
jnthn My...META6 package? 12:22
jnthn wonders if he's being confused with RabidGravy again :)
timotimo right, that's the other jonathan 12:23
he decided to keep his vowels, though
12:34 mr-foobar left 12:42 parv left, bjz_ joined
Woodi hallo #perl6 :) 12:44
12:44 bjz left
Woodi do we have some struct or record type or we need to use hash or class ? 12:44
timotimo when you use a class with "is repr('CStruct')" you get the same in-memory layout as a C Struct 12:46
Woodi nice :) I assume "usage" part is similiar to C :) checking... 12:49
12:49 Actualeyes joined
timotimo it's exactly like a class 12:49
kalkin- jnthn: yes I mixed you up with another jonathan :) 12:50
sorry
Woodi thanx timotimo++ 12:52
Geth oc: f105aa0c09 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Associative.pod6
link to postcircumfix:<{ }>
12:56
oc: f206a48fc0 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Associative.pod6
link to Subscripts
RabidGravy jnthn, it would appear so
but hey you can take the blame if you want 12:57
Geth oc: c6f030cdbd | (Wenzel P. P. Peppmeyer)++ | doc/Type/Associative.pod6
better link is better
12:58
kalkin- is there a way to define a parametized trait? so i can say Md5Auth is sasl-mech('md5')? 12:59
timotimo of course
just take a parameter
RabidGravy re: searching the CUR for things that might implement something (such as an authentication method) can the Distribution object of an installed module have arbitrary attributes
timotimo in your trait_mod:<sasl-mech> 13:00
13:00 holli_ left
RabidGravy so e.g. one could have a "does" attribute in the META6 and that gets stored in the Distribution and then one could have a special CUR implementation that searched those values 13:01
13:01 cdg joined
kalkin- timotimo: ohh, like is export('FOO'), right? 13:02
RabidGravy kalkin-, github.com/jonathanstowe/AccessorF...rFacade.pm has examples of nearly every case you might wish for
timotimo right
13:02 kurahaupo joined
timotimo or is repr('CStruct') 13:02
RabidGravy (they of course are method traits but the same thing applies) 13:03
kalkin- RabidGravy: awesome thanks!
RabidGravy github.com/jonathanstowe/Sofa/blob...fa/Item.pm has a "class trait" 13:04
13:09 smls joined
RabidGravy actually I could pull the stuff that implements that pattern out into a separate module 13:09
smls Am I misremebering, or did `prove t/` use work with Perl 6 .t files if they had an appropriate shebank line? 13:10
timotimo i seem to recall someone at some point saying that prove reads the shebang
smls It doesn't work for me anymore unless I explicitly specify `prove -e perl6 t/` 13:11
timotimo strange
RabidGravy wasn't someone working on a P6 prove? 13:12
kalkin- apropos separate modules On the one hand I don't want to end up with perl6 being the new JS with modules like leftpad, but on the other hand If I have some XMPP::SASL module containing MD5, SHA1, CRAM, wouldn't it make sense to package them as own distributions so people only use the dependencies they really need?
RabidGravy: doesn't zef bring it's own implementation? You can configure it in zef config.json to be used instead of prove
timotimo yeah, we have make spectest6
kalkin- The same issue I had with my License::Software package. I thought about packaging all the license templates on it's own, but then didn't do it just because it's to much effort 13:13
what's perl BP on this? How granular should distributions be? 13:14
RabidGravy It's really difficult to have a hard and fast rule on it 13:16
as in your SASL case, for example, the different modules may bring in a bunch of different dependencies and a strong case could be made for separating 13:17
likewise if there are multiple things where someone is only likely to ever want one then separate might be good 13:18
but otherwise and all other things being equal then they can all be in one distribution 13:19
kalkin- RabidGravy: The dependency issue is a good argument! 13:21
(for splitting in a bunch of modules)
13:21 nowan_ joined, nowan_ left
RabidGravy especially if there are external dependencies (such as a native library) 13:22
13:24 nowan left, nowan_ joined
RabidGravy right let's rename the last of these META.info - no-one install any of my modules for the next half hour okay? 13:25
13:27 abruanese joined
moritz you could copy, then rename in the ecosystem, then delete the old one 13:28
bam, zero downtime rename
13:29 MrMebelMan left
Geth cosystem: 8433f9cfd9 | (Jonathan Stowe)++ | META.list
Rename the last of those to META6
13:33
RabidGravy there
dalek on: 28fe139 | moritz++ | META6.json:
The new hotness in META6.json
13:36
timotimo .json for json 13:37
Geth cosystem: d1d0f906ee | (Moritz Lenz)++ | META.list
Moritz' Module Cleanup

  * move from META.info to META6.json
  * remove two modules that are no longer maintained/relevant
13:41
RabidGravy still more than half have META.info unfortunately 13:44
moritz write a bot that opens pull requests against all those modules to rename them 13:46
RabidGravy I was thinking that
13:56 mr-foobar joined 14:11 bjz_ left 14:12 bjz joined
gfldex i'm working on META6 right now to make travis happy 14:13
RabidGravy what's the matter with travis? 14:14
gfldex travis-ci.org/jonathanstowe/META6
RabidGravy oh that should be just press the restart build button ;-) 14:15
there are a couple like that 14:16
RabidGravy checks
yeah, travis was quicker than I was
gfldex RabidGravy: i found out because I wanted to have META6 does Associative, what works aleady
i will send the PR in a few 14:17
RabidGravy I've just restarted the travis build on that though, it should be fine
gfldex i switched to zef too while I was on it 14:18
RabidGravy ah, no the tests seem to not like the rename :( 14:22
gfldex :-| it stalls in on of the tests
*one
gfldex investigates 14:23
RabidGravy fixed 14:24
well fixed for me anyway, let's see what travis thinks 14:26
14:27 cale2 joined 14:28 hankache left
RabidGravy there, all good 14:35
14:40 lep-delete joined
gfldex i'm struggeling to do a dynamic lookup on attributes. Is there an equivalent to .^loopup for attributes? 14:41
Geth oc: ffb026da50 | (Aleks-Daniel Jakimenko-Aleksejev)++ | doc/Type/Metamodel/ClassHOW.pod6
“faster then” → “faster than”
14:45
moritz gfldex: first you need to get hold of an Attribute object, then you can use get_value 14:53
14:54 pmurias joined
AlexDaniel m: class Foo { has $!x; has $!y }; say Foo.HOW.get_attribute_for_usage(Foo, ‘$!x’) 14:54
camelia rakudo-moar 8a6bfc: OUTPUT«Mu $!x␤»
AlexDaniel that's probably not the proper way
MasterDuke m: class Foo { has $!x; has $!y }; .name.say for Foo.^attributes 14:56
camelia rakudo-moar 8a6bfc: OUTPUT«$!x␤$!y␤»
14:57 Ven joined
pmurias kalkin-: having things like MD5 separated into modules seems better 14:57
people depending on XMPP::SASL just for MD5 doesn't seem good 14:58
RabidGravy gfldex, if you're going to do what I think you are, I would say roll your own and then spin it off into it's own module 14:59
so it keeps it's own internal stash of the attributes from ^attributes (probably only :local) and populates that with the de-sigllled names 15:01
so you have something like "Class::Associative" which is a role that turns any class into an Associative on its "public" attributes and then apply that to META6 and jobs a good 'un 15:02
samcv .
yoleaux 18 Jan 2017 19:11Z <brokenchicken> samcv: I found an atom highlighter bug, the qq:// doesn't get highlighted right :P gist.github.com/zoffixznet/f0eb8ee...b6904fe28b
brokenchicken ... that was a joke 15:03
yoleaux 06:48Z <faraco> brokenchicken: "Oh, thanks for mentioning that!"
samcv .
brokenchicken, can we just call it GraphemeBreakTest.t 6.c-errata and 6.c? i'd perfer them be named the same as their unicode test file names 15:04
or the same + a suffix/prefix
15:05 CIAvash left
brokenchicken samcv: never mind the test file stuff. That's sorted. 15:06
samcv kk
wow those heredocs are pretty intense 15:08
15:11 wamba left
RabidGravy gfldex, actually I'm liking that idea a lot, I have an immediate use for it on something I was going to alter in a backward imcompatible fashion 15:17
15:24 Tonik joined
samcv for some reason I run ./Configure.pl on MoarVM, and when I run ./Configure.pl for nqp it tells me my moar is too old 15:26
15:27 AlexDaniel left
brokenchicken Did you pull all the stuff? Latest nqp wants 2017.01 MoarVM 15:27
samcv yeah I did 15:28
brokenchicken What does git describe give you in moarvm repo?
15:28 bjz left
samcv 2016.12-135-g0c8b770f 15:29
^ is actually me checking out the commit which bumped the version number
MasterDuke did you `pull --tags`?
kalkin- pmurias: I think you are right 15:30
samcv MasterDuke, I have now :) thanks
kalkin- especially because the Crypto Modules will need crypto libraries, which we are missing now
MasterDuke yeah, that bit me so many times it's finally sunk in
kalkin- pmurias: but keep in mind that if you are writing a client, you probably want to support almost all the modules, because different servers advertise different modules 15:31
gfldex RabidGravy: I had problem thanks to the `is json-name` trait but I think I got it now.
cale2 The thing that confuses me the most about any programming language is organization. When/why to use modules/packages/classes 15:43
It doesn't help that Perl6 has modules, packages, classes, units, etc
jdv79 is there any reason the p6 weekly post ends up base64'd on pl6anet.org?
other entries are not 15:44
mst cale2: honestly, perl5 using 'just a package' for all those things wasn't less confusing
cale2 haskell and elixir are nice in that they only have modules and functions
mst also 'unit' is just a syntax thing
not an actual sort of organisation
cale2 mst: I read the docs on packaging in perl6 and it did not help in explaining when to use each one
I guess I just don't understand why you'd want so many different ways to group things 15:45
jdv79 stmuk_: ^^^ ?
mst cale2: there's only really two: modules, and classes 15:48
cale2: those are both types of package
cale2: a class is a thing designed for you to .new() and instantiate objects of
cale2: a module is a bag of subroutines
cale2 mst: there are packages though too
mst cale2: please read what I said again?
cale2 mst: They are types of package (which is a type). Got it. So packages do not exist in perl6. They are like virtual types 15:49
brokenchicken more like placeholders
mst cale2: 'package' is basically 'namespace'
brokenchicken m: package Foo {}; class Foo {} 15:50
camelia ( no output )
brokenchicken m: package Foo {}; role Foo {}
camelia ( no output )
mst cale2: docs.perl6.org/language/packages
cale2: Packages are nested namespaces of named program elements. Modules, classes, grammars, and others are types of packages.
cale2 mst: so because a module is a type of package, you could just use modules within modules within modules and never use the package keyword at all. 15:51
mst I'm not sure I've seen perl6 code that says 'package'
brokenchicken: ?
brokenchicken no idea about this stuff 15:52
mst I mean, have you ever seen a bare package/
brokenchicken Don't remember. I don't really code Perl 6 so almost no experience with it in the wild. 15:53
cale2 m: class Foo {}; say Foo.$?PACKAGE
camelia rakudo-moar 7f245f: OUTPUT«Cannot invoke this object (REPR: Uninstantiable; GLOBAL)␤ in block <unit> at <tmp> line 1␤␤»
mst brokenchicken: except for your small army of bots :P 15:54
brokenchicken yeah, except that :)
b2gills m: class Foo { say $?PACKAGE }; say $?PACKAGE # all variables with a ? twigil are compile time variables 15:56
camelia rakudo-moar 7f245f: OUTPUT«(Foo)␤(GLOBAL)␤»
cale2 "I don't really code Perl 6 so almost no experience with it in the wild." I think a lot of my confusion comes from not knowing the typical usage of things 15:57
I suppose a lot of that would clear up as books get released
brokenchicken cale2: one has already been: deeptext.media/perl6-at-a-glance 15:58
cale2 I saw that one. Print only though :/
brokenchicken mhm
RabidGravy mst, 'package' is used occassionally
cale2 And also, I'm more interested in "let's build like 5 full applications together in perl6" than the tiny example driven stuff 15:59
RabidGravy do feel free to make that then
cale2 Becuase the full applications would clear up packaging confusion, for example :)
RabidGravy: With the questions I've asked, would you really want me to guess my way through something like that? :P 16:00
RabidGravy of course, it's the best way to learn :) 16:01
mst, in places like github.com/jnthn/oo-monitors/blob/...s.pm6#L111 for example
mst ooh, when you really do want 'just a namespace'
RabidGravy yeah 16:02
mst why 'my' on the outer but not the inner? 16:03
also 'use experimental :macros' ... I didn't realise we'd started to get macros?
RabidGravy oh yeah, they've always been there
it's just the implementation isn't settled 16:04
mst ah
fair 'nuff 16:05
brokenchicken cale2: heh, yeah, "5 useless applications that doesn't really teach the language"?
I hated the Catalyst book for that. First 3rd is all about god damn tests and not the actual web framework 16:06
mst err, which one?
brokenchicken prolly old one
It was ages ago before I even knew of Mojolicious
mst there was a packt one, which was insane
and an apress one, which got into writing app code in ch.3 16:07
(IIRC 1 was intro and 2 was installing shit)
cale2 brokenchicken: For me, I'm at the point where I know how to program, but I am garbage at stuff like completing an actual application. So that stuff is actually helpful to me.
But yeah, actually writing tests is so passee.
gfldex I'm trying to implement subscripts with list keys on a custom class and utterly fail. Anybody done this successfully already? 16:08
mst the irony here is that if he's misremembering the way I suspect he is
the 'all about god damn tests' was actually the first chapter that I wrote
cale2 I saw a testing system for elixir where you describe the input and output data, then say how many tests you want, and it just lambasts your function that many times with various tests.
brokenchicken By the cover, I'd say it was the apress one...
mst and was written that way because I wrote the code for real first, then built the chapter around the commit log 16:09
yeah, so, *lots* of people have said that that was one of their favourite things about the book, in that it mirrored real development
brokenchicken hehe :)
mst I can only conclude you haven't learned to write enough tests yet
brokenchicken Well, it's worth noting I was drinking a lot back then :)
mst basically chapter 3 throws together a trivial app 16:10
then chapter 4 I added tests and refactored it to be extensible
but, yeah, mojolicious is way easier to get started with at the cost of being harder to maintain large scale apps in 16:12
cale2 mst: I would probably like your book if I was interested in p5 :) 16:13
mst grins
I'll take that as a compliment
RabidGravy are there tests somewhere for Attribute.get_value/set_value 16:18
16:19 dwarring left
MasterDuke github.com/perl6/roast/blob/master...utes.t#L69 16:20
16:20 mr_ron left
RabidGravy MasterDuke, cheers, it's me being stupid then :) 16:22
16:26 araujo joined 16:28 BenGoldberg joined
RabidGravy it's probably completely obvious but why doesn't gist.github.com/jonathanstowe/d8f5...58a0c0cc22 work how I expect it to? 16:30
in this case Attribute.get_value seems to return True and the set_value doesn't do anything 16:31
MasterDuke gist.github.com/jonathanstowe/d8f5...cthing-L8, '$nane' vs '$name'? 16:32
RabidGravy hahahah 16:33
Really need to get to the opticians
gfldex, with a few refinements and the typo fixed that was what I had in mind :) 16:35
16:35 ChoHag joined 16:37 eater joined
gfldex RabidGravy: did you got `$f<bar baz> = 1, 2;` working? 16:38
RabidGravy oh I haven't tested that it was just a quick PoC
16:38 khw joined
Geth cosystem: 36aa43cfad | (Wenzel P. P. Peppmeyer)++ | META.list
META* -> META6.json
16:40
16:41 mr_ron joined, eater left
RabidGravy gfldex, yes by arranging to have AT-KEY return a Proxy ;-) 16:43
gfldex, like so gist.github.com/jonathanstowe/d8f5...58a0c0cc22 16:45
gfldex RabidGravy: you may be working around a bug 16:47
16:48 agentzh joined
RabidGravy that I have to write software at all is a bug ;-) 16:48
mst RabidGravy: or at least, the fact the computer lets you is 16:50
16:52 x1729 joined 16:53 agentzh left, wamba joined
RabidGravy gfldex, that PR seems to fail it's test :-\ travis-ci.org/jonathanstowe/META6/.../194041113 16:54
16:54 cdg left
RabidGravy I've got shortbread to make anyhow 16:54
16:55 BenGoldberg left 16:56 cdg joined
moritz considers making some more sesame brittle 16:57
gfldex RabidGravy: test works locally. I may have messed up the PR 16:59
17:00 cdg left 17:03 BenGoldberg joined
kalkin- .seen retupmoca 17:04
yoleaux I saw retupmoca 8 Jun 2016 21:09Z in #perl6: <retupmoca> m: say ('a'..'d').rotor(2 => -1).perl;
17:07 x1729 left
gfldex RabidGravy: works for me, no idea what happend with the PR travis-ci.org/gfldex/META6 17:08
17:15 agentzh joined
RabidGravy I'm just cooking, I'll take a more careful look in a bit :) 17:21
cale2 How does vim-perl detect perl6 files? 17:24
It must look for .pm6 .pl6 .p6 endings?
RabidGravy or #!perl6 or "use v6" or as most people do "# vim: ft=perl6" 17:27
moritz m: grammar A { method FAILGOAL($goal, $dba_) { say ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse 'ab' 17:34
camelia rakudo-moar 7f245f: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$dba' is not declared. Did you mean '$dba_'?␤at <tmp>:1␤------> 3od FAILGOAL($goal, $dba_) { say ($goal, 7⏏5$dba).perl }; token TOP { a ~ a b } }; A␤»
moritz m: grammar A { method FAILGOAL($goal, $dba) { say ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse 'ab'
camelia rakudo-moar 7f245f: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Two terms in a row␤at <tmp>:1␤------> 3perl }; token TOP { a ~ a b } }; A.parse7⏏5 'ab'␤ expecting any of:␤ infix␤ infix stopper␤ statement end␤ statement m…»
moritz m: grammar A { method FAILGOAL($goal, $dba) { say ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse: 'ab' 17:35
camelia rakudo-moar 7f245f: OUTPUT«Too few positionals passed; expected 3 arguments but got 2␤ in method FAILGOAL at <tmp> line 1␤ in regex TOP at <tmp> line 1␤ in block <unit> at <tmp> line 1␤␤»
moritz m: grammar A { method FAILGOAL($goal, $dba_) { say ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse: 'ab'
camelia rakudo-moar 7f245f: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$dba' is not declared. Did you mean '$dba_'?␤at <tmp>:1␤------> 3od FAILGOAL($goal, $dba_) { say ($goal, 7⏏5$dba).perl }; token TOP { a ~ a b } }; A␤»
moritz m: grammar A { method FAILGOAL($goal, $dba?) { say ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse: 'ab'
camelia rakudo-moar 7f245f: OUTPUT«("a ", Any)␤P6opaque: no such attribute '$!pos' in type Cursor when trying to get a value␤ in regex TOP at <tmp> line 1␤ in block <unit> at <tmp> line 1␤␤»
moritz man, that took a long time to get right :(
m: grammar A { method FAILGOAL($goal, $dba?) { die ($goal, $dba).perl }; token TOP { a ~ a b } }; A.parse: 'ab'
camelia rakudo-moar 7f245f: OUTPUT«("a ", Any)␤ in method FAILGOAL at <tmp> line 1␤ in regex TOP at <tmp> line 1␤ in block <unit> at <tmp> line 1␤␤»
moritz why is there a space after the "a" in the goal? 17:36
and how do I determine the current cursor position?
m: grammar A { method FAILGOAL($goal, $dba?) { die ($goal, $dba, $¢).perl }; token TOP { a ~ a b } }; A.parse: 'ab'
camelia rakudo-moar 7f245f: OUTPUT«("a ", Any, Nil)␤ in method FAILGOAL at <tmp> line 1␤ in regex TOP at <tmp> line 1␤ in block <unit> at <tmp> line 1␤␤»
17:37 ChoHag left 17:39 ChoHag joined 17:42 lukiramu left
RabidGravy gfldex, it appears to somehow be interfering with the way that JSON::Unmarshal works with the unmarshalled-by trait 17:45
belay that 17:50
17:53 agentzh left 17:57 avuserow joined 18:00 cdg joined 18:01 cdg_ joined 18:02 faraco joined, faraco left, faraco joined, faraco left, smls left, smls joined 18:03 kyan joined, cdg_ left 18:04 cdg_ joined 18:05 cdg left 18:11 brabo joined
RabidGravy gfldex, just in case you don't notice I merged that manually as you'd crossed over with my other fix 18:11
18:13 lukaramu joined
RabidGravy and the reason it confuses JSON::Class is that JSON::Unmarshal will choose the Associative multi rather than the less specufic Mu one 18:16
18:18 agentzh joined 18:24 aindilis left
RabidGravy It would be nice if that could be made to work though 18:31
18:36 BenGoldberg left 18:38 BenGoldberg joined 18:41 ChoHag left 18:43 espadrine_ left 18:50 ChoHag joined, kyan left 18:53 agentzh left 18:56 geekosaur left, espadrine_ joined, agentzh joined 18:57 geekosaur joined 19:08 dugword joined, iH2O joined 19:10 Ven left 19:13 BenGoldberg left 19:15 BenGoldberg joined 19:16 BenGoldberg left 19:18 BenGoldberg joined 19:22 ChoHag left 19:24 rindolf left 19:25 cdg_ left 19:26 rindolf joined, espadrine_ left 19:28 jjido joined 19:32 darutoko left
cale2 I can't even recall all of the times I've sat down to learn golang. Takes willpower I do not have :/ 19:50
Same with Rust to an extent. Once you've written in the shorthand, it's difficult to go back to longhand
mspo ? 19:51
iH2O learn APL its record short
mspo cale2: golang is about as easy as it gets (at least for me)
moritz what you really need to learn a language is a project 19:52
and sufficient motivation to actually do the project
cale2 moritz: that's true. I was thinking of skipping the tutorials and just translating an api wrapper i did in python 19:53
19:53 iH2O left 19:59 jjido left 20:00 alexk joined
alexk m: my int $i = 0; while $i < 10_000_000 { $i++ }; say now - INIT now; 20:01
camelia rakudo-moar 7f245f: OUTPUT«5.1848902␤»
20:02 espadrine_ joined
RabidGravy Yeah, I find that the ability to go from scratch to writing useful programs is definitely a key factor in my continuing to bother with a language 20:05
alexk m: my (int $i, int $nosink) = 0, 0; while $i < 10_000_000 { $nosink = $i++ }; say now - INIT now; 20:06
camelia rakudo-moar 7f245f: OUTPUT«0.0816566␤»
moritz couldn't we skip sinking of expressions that return natives? 20:07
BenGoldberg m: my (int $i, int $nosink) = 0, 0; while $i < 10_000_000 { sink $nosink = $i++ }; say now - INIT now; 20:11
camelia rakudo-moar 7f245f: OUTPUT«7.28699907␤»
BenGoldberg m: my (int $i, Int $nosink) = 0, 0; while $i < 10_000_000 { sink $nosink = $i++ }; say now - INIT now; 20:12
camelia rakudo-moar 7f245f: OUTPUT«7.27952801␤» 20:13
RabidGravy there, made a ridiculous amount of shortbread and "all the vegetables in the fridge and polenta thing" 20:15
and merged gfldex's PR on META6 into the bargain 20:17
alexk m: my int $i = 0; while $i < 10_000_000 { $i++ }; say now - INIT now; 20:18
camelia rakudo-moar 7f245f: OUTPUT«5.1239124␤»
alexk m: my Int $i = 0; while $i < 10_000_000 { $i++ }; say now - INIT now;
camelia rakudo-moar 7f245f: OUTPUT«4.6527934␤»
20:18 eater joined 20:20 jjido joined, pecastro left 20:22 pecastro joined 20:24 cdg joined 20:25 jjido left 20:26 domidumont left 20:28 webstrand joined, jjido joined
gfldex m: my %h = a => { c => 1}, b => { c => 1} ; dd %h<a b>».<c> 20:28
camelia rakudo-moar 7f245f: OUTPUT«(1, 1)␤»
20:28 domidumont joined 20:29 domidumont left 20:41 agentzh left 20:53 bjz joined
smls m: dd ([2, 3], [4, [5, 6]])».Slip 20:53
camelia rakudo-moar 7f245f: OUTPUT«(slip(2, 3), slip(4, $[5, 6]))␤»
smls heh :) 20:54
20:58 agentzh joined 21:09 kyan joined
stmuk_ pl6anet.org/drop/rakudo-star-2017.01-RC0.tar.gz 21:12
21:18 agentzh left 21:26 pecastro left, pecastro joined 21:29 RabidGravy left
brokenchicken
.oO( what's heh? )
21:30
21:31 pierrot joined
cale2 what's the best module for an http client right now? 21:33
brokenchicken buggable: eco HTTP::UserAgent
buggable brokenchicken, HTTP::UserAgent 'Web user agent': github.com/sergot/http-useragent
tadzik yep 21:37
cale2 I often use an API that requires you to paginate your calls. Like it only pulls 100 records at a time, so you have to hit it a lot in a row 21:38
When using Python's requests, I can use `with requests.session() as client:` and then re-use the cookie. It speeds up the requests a great deal 21:39
brokenchicken WWW::Mechanize:from<Perl5> is good for that. I haven't figured out a way to pass it regexes tho 21:40
21:41 RabidGravy joined, zakharyas joined
cale2 Honestly, it's hard to find session persistence in a lot of languages. It seems like only python requests has it built in 21:42
brokenchicken :/
21:42 eaterof joined
brokenchicken Yes, definitely "only python" 21:43
brokenchicken erases WWW::Mechanize from the backlog
21:43 eater left
tadzik reusing cookies is not that uncommon methinks 21:44
iirc good old LWP allows you to do that if you create your own cookiejar explicitely
it's just recreated anew by default
cale2 Well, I should say requests just makes it dumb easy 21:45
21:45 agentzh joined
cale2 I haven't looked at WWW:Mechanize, but perl5 is quite unapproachable as an outsider 21:45
brokenchicken Good thing you use it in Perl 6 then ;) 21:46
tadzik hehe
alexk m: my Int $i = 0; while $i < 10_000_000 { $i++ }; say now - INIT now; 21:47
camelia rakudo-moar 7f245f: OUTPUT«4.5628630␤»
tadzik I found Perl 5 quite easy to handle if you pretty much ignore the docs and just modify the code you find in SYNOPSIS on cpan :P
alexk m: my (Int $i, Int $nosink) = 0, 0; while $i < 10_000_000 { $nosink = $i++ }; say now - INIT now;
camelia rakudo-moar 7f245f: OUTPUT«3.31300213␤»
21:47 cdg left 21:48 cdg joined, bjz left 21:50 bjz joined 21:51 mcafee joined 21:53 alexk left, cdg left
cale2 Wait, could you use Python's requests library in perl6 with inline python? 21:54
21:56 pierrot left 22:00 rindolf left
RabidGravy yes, but that isn't a very good example as their are P6 libraries that do that 22:01
there are rather
22:04 rindolf joined, imcsk8_ left 22:05 imcsk8 joined 22:07 agentzh left 22:09 BinGOs left 22:10 BinGOs joined, BinGOs left, BinGOs joined 22:13 Tonik left 22:16 mcafee left 22:20 BenGoldberg left 22:22 BenGoldberg joined, cdg joined 22:23 curt_ joined
curt_ Docs say END phaser only runs once, but it can run multiple times during precompile of modules 22:27
gist.github.com/CurtTilmes/9f7e5cb...0bc97cdab6
22:34 pierrot joined 22:35 agentzh joined
agentzh any hints on debugging rakudo error messages like "Type check failed in binding to assignval; expected Array[EdgeLang::Stmt] but got Array[EdgeLang::Stmt]..."? 22:36
It's triggered by "use"ing a seemingly unrelated .pm6 module. 22:37
using the latest nom branch of rakudo. 22:38
very strange.
22:40 kyan left 22:42 RabidGravy left 22:44 labster joined 22:48 zakharyas left 22:53 cdg_ joined
agentzh okay, seems like Rakudo gets confused with my EdgeLang::Use module name. 22:53
After renaming this module to EdgeLang::UseStmt, the mysterious typecheck error shown above disappears. ouch! 22:54
geekosaur o.O
rakudobug that one
22:54 cdg left
agentzh geekosaur: i'll try producing a minimal example. 22:55
it's currently part of a big p6 program.
brokenchicken m: say 'Array[EdgeLang::Stmt]'.chars 22:58
camelia rakudo-moar 7f245f: OUTPUT«21␤»
brokenchicken agentzh: does it actually have '...' after it?
I'd be interested in code that produces it; for ticket rt.perl.org/Ticket/Display.html?id=130434 23:00
23:01 kurahaupo left
agentzh brokenchicken: nope. 23:03
brokenchicken: okay, after renaming the EdgeLang::UseStmt module back to EdgeLang::Use, I can no longer reproduce that typecheck error.
weird.
i even tried removing .precomp/ in my previous tests and it did not help.
seems like renaming modules help. 23:04
23:04 cdg_ left
agentzh brokenchicken: I just copied the original text there. 23:04
23:04 cdg joined
agentzh brokenchicken: the original error message copy: gist.github.com/agentzh/d58dc54f63...d031d20b87 23:05
23:06 lmmx joined 23:07 smls left
agentzh brokenchicken: anyway i can no longer reproduce it after renaming EdgeLang::Use to EdgeLang::UseStmt and then back to EdgeLang::Use. 23:07
hmm, seems like memory corruptions or something. 23:09
now the typecheck failure shows up again.
it has nonderterminism. 23:10
should i run valgrind against it?
does rakudo/moarvm have special building flags for valgrind memcheck?
valgrind does not find invalid reads or invalid writes or use of uninitialized values on my side. 23:14
just a lot of definitely lost and possibly lost errors.
23:21 khw left
agentzh okay, got a "Syscall param write(buf) points to uninitialised byte(s)" error from valgrind when running rakudo: gist.github.com/agentzh/752af6b08e...c34f291164 23:25
not sure if it's helpful.
or should i ask in #moarvm instead?
brokenchicken Hm. That gives me a clue at laest. Both yours and the other errors are from the TWEAK method 23:26
oh that one's BUILD but here's TWEAK hmmm
agentzh valgrind takes forever to run. 23:28
the original perl6 finishes in 7+ sec.
so i guess valgrind would need 70+ sec.
agentzh waits.
i prepared a small example and cannot reproduce the issue. 23:29
alas.
just the real thing can.
23:30 vike joined
jnthn fiww, I think the uninitialized bytes issue there is pretty benign; some padding bytes at the end of a buffer are left as junk in a handleful of cases of bytecode generation. Since they never are read, it has no effect. Worth hunting down to quieten valgrind, though 23:31
23:32 cdg left
jnthn The Foo[Bar] didn't match Foo[Bar] issue is likely some kind of type interning failure 23:32
(Which I've no idea how happens, alas.) 23:33
23:33 kyan joined 23:34 lukaramu left
agentzh jnthn: how can i help debugging this issue? 23:34
jnthn agentzh: Golf it down to the smallest example you can 23:35
agentzh now renaming my EdgeLang::Use to EdgeLang::UseStmt no longer helps. still the same error.
jnthn (Which will, I'm afraid, due to the nature of the bug, most likely involve multiple modules)
(Spread across multiple compilation units0
*)
agentzh yeah, if I comment out the line "use EdgeLang::Use;" from EdgeLang::Doc, then the typecheck error in EdgeLang::Doc disappears immediately. 23:36
jnthn Urgh :(
agentzh wondering if it has anything to do in the new Jan release that aims to support multiple version of the same name classes in a single vm. 23:37
maybe some how rakudo treats FanLang::Stmt as two different versions?
due to the loading orders in other classes' units?
agentzh tries the 2012.12 release of rakudo. 23:39
s/2012/2016/
brokenchicken That stuff works only for installed modules AFAUI
agentzh this is a showstopper for me.
brokenchicken the version.
agentzh brokenchicken: okay 23:40
i'm working on a large p6 project estimated 7K+ LOC (excluding comment lines and blank lines). 23:41
currently i'm at 1K+ LOC.
okay, the same error using rakudo 2016.12. 23:44
alas.
okay, i'll just remove the type constraint in that position and keep moving :) 23:45
i guess maybe the type constraint thing is not heavily exercised by most of p6 users yet.
i love it so i tend to use type constraints as much as i can. 23:46
23:46 jdmmmmm joined
dogbert17 brokenchicken, want to help with a performance mystery? 23:49
possible regression 23:50
brokenchicken dogbert17: whatisit? 23:51
dogbert17 check this out
m: gist.github.com/dogbert17/b052a9da...990cdad35f
camelia rakudo-moar 7f245f: OUTPUT«10.0874897␤»
dogbert17 star: gist.github.com/dogbert17/b052a9da...990cdad35f
camelia star-m 2016.10: OUTPUT«5.0909620␤»
dogbert17 odd I'd say 23:52
my only theory is that it might have something to do with lizmat's grep deoptimization 23:53
brokenchicken m: gist.github.com/zoffixznet/592aa34...ff9d37ec3d 23:54
camelia rakudo-moar 7f245f: OUTPUT«0.05319998␤»
brokenchicken star: gist.github.com/zoffixznet/592aa34...ff9d37ec3d 23:55
camelia star-m 2016.10: OUTPUT«0.04814617␤»
brokenchicken Yup. Looks like it's that grep bugfix.
dogbert17 that looks like an improvement :)
brokenchicken m: gist.github.com/zoffixznet/69fb32f...e8145772d3 23:57
camelia rakudo-moar 7f245f: OUTPUT«9.3213457␤»
brokenchicken star: gist.github.com/zoffixznet/69fb32f...e8145772d3
camelia star-m 2016.10: OUTPUT«9.13749140␤»
brokenchicken yup
rewriting to avoid .grep() makes difference disappear 23:58
dogbert17 so it was the grep deopt/bugfix that did it?
23:59 mr_ron left