[00:04] *** telex left [00:04] *** skrshn joined [00:05] *** skrshn left [00:06] *** telex joined [00:08] *** pnu left [00:09] *** kanishka left [00:09] *** jnap left [00:09] *** TEttinger left [00:10] *** kent\n left [00:10] *** pnu joined [00:10] *** jnap joined [00:10] *** kanishka joined [00:12] *** kent\n joined [00:12] *** TEttinger joined [00:12] *** leont left [00:13] *** Spot__ left [00:13] *** Spot__ joined [00:13] *** ugexe left [00:15] *** pnu left [00:15] *** mrsolo left [00:15] *** mrsolo joined [00:16] *** BuildTheRobots left [00:16] *** caasih left [00:16] *** BuildTheRobots joined [00:16] *** kent\n left [00:16] *** caasih joined [00:17] *** pnu joined [00:19] *** kent\n joined [00:23] *** ugexe joined [00:24] *** vendethiel left [00:25] *** vendethiel joined [00:25] install of perl6 module from jdv's metacpan clone: https://gist.github.com/ugexe/9f382c8595226aa9bae0 [00:39] *** labster left [00:42] w00t! awesome :D [00:42] *** wamba joined [00:45] *** krakan left [00:45] *** pnu left [00:45] *** vendethiel left [00:46] *** pnu joined [00:46] *** captain-adequate left [00:52] *** vendethiel joined [00:57] *** a3r0 joined [01:02] *** Actualeyes joined [01:04] *** labster joined [01:07] *** krakan joined [01:11] *** yeahnoob joined [01:13] “Internal error: zeroed target thread ID in work pass” hmm [01:20] we already have a few reports of that? [01:30] geekosaur: ah, ok then [01:31] I just ran it again and it worked. Weird thing [01:32] *** labster left [01:32] *** spider-mario left [01:35] *** cdg joined [01:35] *** labster joined [01:36] *** vendethiel left [01:40] i get them randomly too. usually related to run() [01:42] *** lichtkind_ left [01:47] *** ZoffixWin left [01:49] *** isBEKaml left [01:49] *** pierrot left [01:50] *** pierrot joined [01:55] *** vendethiel joined [01:55] .tell masak I started working on the type concatenative thing again, got the arity part of type inference working now: https://gist.github.com/rightfold/9e9ba03a02ea4ac3d60f#file-js-L38-L53 [01:55] ely-se: I'll pass your message to masak. [01:55] .botsnack [01:55] :D [01:59] *** pierrot_ joined [02:00] *** pierrot left [02:02] *** sortiz joined [02:02] *** xpen joined [02:04] .tell masak well, to some extent :p [02:04] ely-se: I'll pass your message to masak. [02:04] *** labster left [02:07] *** BenGoldberg joined [02:08] *** BenGoldberg left [02:09] *** BenGoldberg joined [02:16] *** vendethiel left [02:18] *** wamba left [02:20] *** vendethiel joined [02:31] *** abaugher left [02:33] *** abaugher joined [02:36] *** psy_ joined [02:43] *** vendethiel left [02:47] *** vendethiel joined [02:56] here's a fun bug for you: [02:56] m: my Int:D @foo; say @foo[1] [02:56] rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block at /tmp/iofmqLuglf line 1␤␤» [02:56] whoever wants to can file that in RT [02:58] *** azawawi joined [02:58] good morning #perl6 [02:59] http://pasteboard.co/1dCMZs5g.png # More image effects implemented [03:09] azawawi: nice. What's the module? [03:09] *** cdg left [03:09] *** kid51_ joined [03:10] https://github.com/azawawi/perl6-magickwand/blob/master/examples/02-effects.pl6 # MagickWand [03:10] *** vendethiel left [03:12] *** kid51 left [03:12] *** kid51_ is now known as kid51 [03:12] azawawi++ [03:12] azawawi: thanks [03:12] thx [03:13] azawawi: what is $o in in $o.cleanup example? [03:13] in README.md [03:13] was it meant to be $wand ? [03:14] think of it as a handle to an image [03:14] or multiple images [03:15] because you could for example add multiple images and then create an animated gif [03:15] or an AVI or MP4 movie via ffmpeg [03:16] it is really a powerful api [03:16] *** ely-se left [03:17] azawawi: I'm not sure if I'm folliwing it. Should the example actually show something that does not compile? [03:18] or perhaps consider adding a comment like # $o is a handle to some image [03:18] sure i will update it [03:18] https://github.com/azawawi/perl6-magickwand/blob/master/examples/01-hello.pl6 [03:19] i will add a user guide after finishing 02-effects.pl6 [03:19] https://github.com/azawawi/perl6-magickwand/issues/1 [03:20] *** raiph joined [03:22] azawawi: why nobody made it earlier? [03:22] :) [03:22] AlexDaniel: i see what you mean... yes $o.cleanup should be $wand.cleanup [03:24] AlexDaniel: help is welcome :) [03:24] AlexDaniel: i started this project like 10 days ago [03:26] azawawi: yeah, I see. Well, earlier I was doing that kind of stuff through 「run」 and command line tools, so… as soon as I rewrite my code you'll possibly see some bug reports. But that takes time :) [03:27] *** kid51 left [03:28] Anyone interested in joining (i.e., helping grow) the Perl 6 Slack community? Get an invite here: http://perl6.bestforever.com/ [03:28] im learning imagemagick as i wrap more OO sugar around it :) [03:28] MadcapJake: what's that? [03:28] MadcapJake: and hi :) [03:28] hi! [03:29] It's a new communication tool that some other languages/devs use: https://slack.com [03:30] m: say :("foo") ~~ :("bar") [03:30] rakudo-moar a5fe34: OUTPUT«True␤» [03:30] :S [03:31] I created one for Perl 6 as a community to grow adoption and it really has some cool features (unfortunately no Slack evalbot yet) [03:31] *** keusej left [03:32] MadcapJake: if you bridge it to IRC then perhaps you can filter messages with m: and other commands [03:32] MadcapJake: this way camelia will reply to your bot [03:32] is there a hash type in which order matters? [03:32] AlexDaniel: yeah I can, I'll need to make a bot for that too, so I was thinking making a server app that does both [03:33] plus current evalbot is written in Perl 5 :) [03:33] MadcapJake: that would mean rewriting camelia, which is probably not cool [03:34] MadcapJake: joined [03:34] *** noganex_ joined [03:34] azawawi++ [03:36] *** danzulla joined [03:36] AlexDaniel: yeah it would be, but I was thinking I'd write it in Perl 6 and using supplies and taps. Zoffix wrote an irc bot tutorial that will help too. [03:37] *** noganex left [03:37] oh perl6 is actually working nowadays? [03:37] timotimo, The bug reduces to ":U.gist" or ":D.gist", will give a try. [03:37] o_0 [03:37] i used to learn perl5 with chatbots, years ago. i loved it. [03:37] it might be slow, but won't know unless i try xD [03:38] danzulla: by “actually working” you mean? [03:38] i got rakudo and some CPAN stuff that claimed to implement perl6. it never seemed to be "official" [03:38] danzulla: because to me it was “actually working” for a few years now [03:38] but i might have been just a stupid slave to perl online marketing [03:39] danzulla: have you used panda yet? [03:39] nope [03:39] what's panda? [03:39] oh then you are definitely out of date [03:39] panda is the current defacto module installer for rakudo [03:40] rakudobrew is the easiest method atm to install a full working suite of moarvm,nqp,rakudo,panda,Task::Star (that last one is a collection of useful modules to get you started) [03:40] did you guys write anything meaningful in perl6? i'd love to take a look. [03:41] http://modules.perl6.org/ [03:41] hah [03:41] *** Sgeo_ joined [03:41] danzulla: Yes, I write several kinds of one-off scripts in Perl 6 now. Mostly just to figure out how everything works. [03:42] danzulla: Eventually I expect to use Perl 6 in production, and I want to get to know the language well before that :) [03:43] One issue for me is that we tend to run high traffic web stuff on small and cheap virtual servers, and Perl 6 is still rather memory hungry and slowish. But it's improving. [03:43] It'd be interesting to see some Perl6 job offerings. [03:43] *** Sgeo left [03:44] A simple script taking 300 MB of memory is a problem for me, given that most of the "machines" I work with, have 512 MB of RAM :) [03:44] @Juerd: Is Perl6 JIT or is there an Ahead of Time compiler as in Google Go already? [03:44] Or is somebody working on it? [03:45] That's what I really like about Go. [03:45] danzulla: I'm not familiar with the details but I believe Perl 6 has a JIT. [03:46] it has JIT, but a bunch of optimizations are done without JIT :) [03:46] @Juerd: Seems like you have some experience with Perl6 on VMs. Which is useful. [03:46] danzulla: Not really, I've only used Perl 6 on my own computer so far [03:47] danzulla: that being said, some things are relatively slow right now. 2016 is supposed to be a big year for Perl 6 speed [03:47] danzulla: earlier efforts were focused on other things [03:47] e.g. getting things to work correctly [03:47] Or getting things to work at all :) [03:48] Good night everyone :) [03:48] z & [03:56] *** spags joined [04:00] *** spags left [04:03] m: Int:D.gist [04:03] rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block at /tmp/3vJXmqV_i_ line 1␤␤» [04:06] *** M-eternaleye left [04:06] *** M-eternaleye joined [04:07] *** cdg joined [04:07] sortiz: mmm probably worth RTing [04:08] *** M-eternaleye is now known as eternaleye [04:08] *** Zero_Dogg left [04:08] I thought that was in response to the earlier RT [04:08] * llfourn I havae no idea [04:08] llfourn, I have a proposed patch, PRing :) [04:09] *** Zero_Dogg joined [04:09] *** Zero_Dogg left [04:09] *** Zero_Dogg joined [04:09] sortiz: nice! [04:09] mm, no, that was in here, not an RT [04:09] so it probably should be [04:09] danzulla, brrt has been working on JIT for moarvm [04:12] llfourn, Now in PR#701 [04:13] sortiz: you might want to write a test or two like is Str:D.gist,'Str:D' in roast [04:15] *** yqt left [04:15] llfourn, I'll search for the proper place. [04:17] BTW, anyone know how to send a PR when you have write access? Sometimes I don't want to push roast tests just leave a PR to accompany the rakudo PR. [04:17] is there a better way to write this http://i.imgur.com/85ap9tV.png [04:17] *** psy_ left [04:17] er [04:17] pretend that's a hash [04:17] typo [04:18] skids: same as usual just push to your roast branch [04:18] your roast fork* [04:19] Last time I tried that I think it auto-merged the PR when I made it. Maybe I a miremembering. [04:19] sortiz: I think S04-declrations/smiley.t is a good place [04:19] m: if 42 -> $a { say $a } [04:19] rakudo-moar a5fe34: OUTPUT«42␤» [04:19] Hotkeys: ^^ [04:19] skids: well I have write and I do it all the time :) https://github.com/perl6/roast/pull/100 [04:22] Maybe I'll try again sometime with something harmless [04:22] *** SCHAAP137 left [04:24] after googling it looks like there is no automerging feature maybe someone just had a trigger merge finger [04:26] *** raiph left [04:26] skids: I decided to do it this way, is this reasonable http://i.imgur.com/GEk2H4i.png [04:29] Hotkeys: sure, if die is what you want. You'd use the if block if you anticipate wanting to edit before/after the call to yaml2qtree while still knowing it is defined. [04:30] die is what I want I'd say, this is just a script that takes a yaml file formatted a certain way [04:30] so if it isn't formatted right it might as well die [04:30] formatted right -> isn't a tree [04:34] *** labster joined [04:34] er [04:34] is a tree [04:46] *** BenGoldberg left [04:50] any idea what might be going on here http://i.imgur.com/mPWbcd1.png [04:51] I feel like one of the signatures totally matches [04:53] The signature :(Hash %h) means a Hash of Hashes. [04:53] *** xpen left [04:53] oh [04:53] how do I do a hash of anythings [04:53] Do you really care that it is a Hash, or will any Associative do? [04:54] multi yaml2qtree (Hash %h) { ... } is what the declaration looks like [04:54] I assumed it meant it took a hash [04:54] just :(%h) will take any Associative, which is probably good enough. [04:54] ah [04:54] % already means hash (or at leasr Associative) [04:54] okay [04:56] great thanks, all is working now [04:56] (Note that Array @a is also an Array of Arrays) [05:00] Right I did that too [05:00] http://i.imgur.com/BRQOTE5.png woo [05:01] it isn't much [05:01] but it's the first thing I've actually used perl 6 for besides various programming puzzles etc. [05:01] congrats :-) [05:03] *** danzulla left [05:04] *** p_p_r left [05:05] *** vendethiel joined [05:09] does anyone know what this nqp::scwbenable() means? [05:09] I am guessing "serialization context write barrier" [05:10] skids: thanks. What's a write barrier? [05:10] It's a mechanism to keep data syncronized between threads. [05:11] ah ok. I guess that's all I need to know :) [05:12] skids: yep you're right [05:12] just did a quick scouring of the repo [05:13] first to figure out the wb and then the sc [05:28] *** vendethiel left [05:32] *** CurtisOvidPoe joined [05:34] *** skids left [05:40] *** Cabanossi left [05:40] *** pochi_ joined [05:40] *** jameslen_ joined [05:41] *** sQuEE joined [05:41] *** Gruber joined [05:42] *** Cabanossi joined [05:42] *** colomon_ joined [05:43] *** cognominal left [05:44] *** labster1 joined [05:44] *** cognominal joined [05:44] *** ilmari_ joined [05:44] *** labster1 left [05:45] *** kst` joined [05:45] *** Quom joined [05:45] *** perigrin_ joined [05:45] *** zostay_ joined [05:45] *** Jonis_ joined [05:45] *** bhm joined [05:45] *** Rotwang_ joined [05:45] *** Ulti_ joined [05:45] *** cosimo joined [05:45] *** hoelzro_ joined [05:45] *** jojotus_ joined [05:45] *** broquain1 joined [05:45] *** nowan_ joined [05:46] *** cdg left [05:47] *** xpen joined [05:47] *** edenc_ joined [05:48] *** gensym_ joined [05:48] *** roguelazer_ joined [05:48] *** musca` joined [05:49] *** labster left [05:49] *** nowan left [05:49] *** sQuEE` left [05:49] *** jojotus left [05:49] *** jameslenz left [05:49] *** avenj left [05:49] *** roguelazer left [05:49] *** flaviusb left [05:49] *** zostay left [05:49] *** colomon left [05:49] *** gensym left [05:49] *** pochi left [05:49] *** huggable left [05:49] *** Rotwang left [05:49] *** mtj_ left [05:49] *** moznion left [05:49] *** cosimo_ left [05:49] *** Ulti left [05:49] *** bhm_ left [05:49] *** Mouq left [05:49] *** musca left [05:49] *** hoelzro left [05:49] *** edenc left [05:49] *** Grrrr left [05:49] *** skarn left [05:49] *** ilmari left [05:49] *** Jonis left [05:49] *** perigrin left [05:49] *** simcop2387 left [05:49] *** kst left [05:49] *** broquaint left [05:50] *** roguelazer_ is now known as roguelazer [05:50] *** gensym_ is now known as gensym [05:50] *** colomon_ is now known as colomon [05:51] *** moznion joined [05:56] *** simcop2387 joined [05:56] *** mtj_ joined [05:58] http://pasteboard.co/1dOtczQb.png # like 95% of the effects done in Perl 6 :) [05:59] *** flaviusb joined [05:59] *** cibs left [06:09] *** azawawi left [06:09] *** protium joined [06:12] *** khw left [06:18] *** cdg joined [06:19] *** skarn joined [06:25] *** cdg left [06:27] m: my @l; if True { my @l.push: 42 } [06:27] rakudo-moar a5fe34: ( no output ) [06:27] just had this in my code… [06:28] now I'm wondering, how does it work? [06:28] m: my @l; if True { my @l.push: 42; say @l }; say @l [06:28] rakudo-moar a5fe34: OUTPUT«[42]␤[]␤» [06:28] so I can decleare variables like this?? [06:29] declare* [06:29] m: my @l.push: 42; say @l [06:29] rakudo-moar a5fe34: OUTPUT«[42]␤» [06:29] apparently! [06:30] O_o [06:30] *** nakiro joined [06:32] *** sno left [06:32] what's the practical use for this? [06:35] *** sjoshi joined [06:38] “Error in `/home/alex/.rakudobrew/moar-nom/install/bin/moar': double free or corruption (fasttop): 0xec9d8eb0” – woops! [06:44] *** _Gustaf_ joined [06:48] *** _Gustaf__ joined [06:51] *** _Gustaf_ left [06:53] *** protium left [06:56] AlexDaniel, A declaration is a term and can be used as such: [06:56] m: say: class A { has $.a; }.new(:a<3>).a [06:56] rakudo-moar a5fe34: ( no output ) [06:57] *** dolmen joined [07:06] *** CIAvash joined [07:09] *** Sgeo_ left [07:09] *** CurtisOvidPoe left [07:09] *** kanishka left [07:11] *** dolmen left [07:15] *** cibs joined [07:17] <[Tux]> test 22.663 [07:17] <[Tux]> test-t 12.419 [07:21] *** milwaukee joined [07:24] o/ all, I must be doing something seriously wrong cause I've run into something I can't find anything about online. [07:25] ~/.radukobrew has disappeared from all of my shells. Thunar and Emacs can browse it just fine, but bash and zsh both cannot cd into it for whatever reason. [07:36] *** domidumont joined [07:39] *** ggoebel15 left [07:40] *** domidumont left [07:40] *** domidumont joined [07:44] *** firstdayonthejob joined [07:45] *** FROGGS joined [07:46] o/ [07:48] *** milwaukee left [07:50] *** avenj joined [07:53] donaldh++ # rakudo/pull/697 [07:59] *** domidumont left [07:59] *** domidumont joined [08:02] *** abraxxa joined [08:03] *** ggoebel15 joined [08:07] *** ecocode joined [08:08] *** kurahaupo joined [08:10] hi. Which module should I use to read/write to a serial device ? I need to be able to specify parity/baudrate.. [08:12] * kurahaupo listens intently, wanting an answer to the same question. posix-something.tcsetattr perhaps? [08:12] *** AlexDaniel left [08:13] I should think about porting Device::Modem to perl6 perhaps :) [08:13] *** RabidGravy joined [08:14] *** vendethiel joined [08:15] *** darutoko joined [08:37] *** vendethiel left [08:38] *** firstdayonthejob left [08:39] *** sno joined [08:43] *** rindolf joined [08:47] *** kurahaupo left [08:48] *** kurahaupo joined [08:49] *** kanishka joined [08:50] *** ilmari_ is now known as ilmari [08:56] *** krshn joined [08:56] *** araujo_ left [08:58] *** kurahaupo_ joined [08:59] cosimo: that would help me :) [09:01] porting Device::SerialPort would be sufficient though [09:02] good antenoon, #perl6 [09:02] 01:55Z masak: I started working on the type concatenative thing again, got the arity part of type inference working now: https://gist.github.com/rightfold/9e9ba03a02ea4ac3d60f#file-js-L38-L53 [09:02] 02:04Z masak: well, to some extent :p [09:02] *** kurahaupo left [09:02] ely-se: wow, cool [09:02] ecocode: of course, Device::SerialPort does the real work there. How could I forget? :) [09:03] I've checked Device::SerialPort and there is some XS code envolved :/ [09:03] *** jferrero_ left [09:04] ecocode: yeah, not the easiest beast to deal with [09:04] I wish I had the knowledge to port it [09:06] ecocode, gwan do it, saves me from doing it [09:06] I wrote a perl5 app to scrape info from the net and from custom serial devices. I used anyevent for the event loop, but perl6 promises looks so much nicier to handle async [09:08] hmmm.. Device::SerialPort isn't listed on https://github.com/perl6/perl6-most-wanted/blob/master/most-wanted/modules.md ! [09:08] *** kurahaupo_ left [09:09] a lot of the XS in Device::SerialPort is just a wrapper to deal with certain cross platform issues, however because Perl 6 doesn't have fcntl, ioctl or a raw open there would be more NativeCall code [09:11] *** dakkar_ joined [09:11] still, not too difficult if one is sufficiently motivated [09:11] :) [09:14] *** spebern joined [09:14] *** wamba joined [09:14] *** spebern left [09:15] *** lizmat left [09:23] *** espadrine_ joined [09:30] *** Perleone_ joined [09:35] *** crux left [09:35] *** crux joined [09:43] *** pmurias joined [09:44] *** khagan_ joined [09:48] *** |Tux| left [09:49] *** kjs_ joined [09:52] *** vendethiel joined [09:52] *** pierrot joined [09:53] *** pierrot_ left [09:54] *** zakharyas joined [09:54] *** |Tux| joined [09:55] *** burnersk left [09:56] *** lnrdo_ joined [09:57] *** lnrdo_ left [09:58] *** lnrdo_ joined [09:58] *** burnersk joined [10:00] *** lnrdo_ left [10:02] *** yeahnoob left [10:06] hi [10:07] my JavaScript backend for Rakudo grant application is up for community review: [Act: 1] [10:07] http://news.perlfoundation.org/2016/02/ian-hague-perl-6-grant-applica.html [10:08] *** espadrine_ is now known as espadrine [10:08] pmurias: another one? [10:09] No, another compiler [10:09] AFAIK pmurias has been working on a JS backend for NQP only so far [10:11] "Improve the JavaScript backend from handling NQP (Not Quite Perl) to full Perl 6." [10:11] can someone point to the latest rakudo rc? [10:11] anyway ++ from me, I wasn't sure because I thought I saw one like this a month ago [10:13] El_Che: http://rakudo.org/downloads/rakudo/ [10:17] ah, ok, I was under the impression that there was a RC2 [10:19] *** zakharyas left [10:21] *** sortiz left [10:23] *** pmurias left [10:25] El_Che: I did a rakudo star RC2 [10:27] *** pmurias joined [10:28] llfourn: you might have seen a pre-submission draft of the grant proposal ;) [10:29] pmurias: ah that explains it. Anyway this time I will read it. pmurias++ [10:34] *** domidumont left [10:34] *** nebuchadnezzar left [10:34] *** matt_ left [10:34] *** eiro left [10:39] *** fireartist joined [10:42] *** domidumont joined [10:42] *** nebuchadnezzar joined [10:42] *** matt_ joined [10:42] *** eiro joined [10:45] *** rindolf left [10:55] *** vendethiel left [10:57] *** vendethiel joined [11:01] *** leont joined [11:01] *** iH2O joined [11:01] *** lnrdo_ joined [11:02] great room lol [11:06] *** lnrdo_ left [11:08] :) [11:13] *** nowan_ left [11:14] *** nowan joined [11:16] *** rurban joined [11:16] *** rurban left [11:18] *** bowtie_ left [11:19] *** lnrdo_ joined [11:19] *** bowtie joined [11:19] *** bowtie is now known as Guest55981 [11:23] *** lokien_ joined [11:26] *** Skarsnik joined [11:26] *** Skarsnik left [11:29] *** kaare__ joined [11:32] *** lnrdo_ left [11:39] *** donaldh joined [11:40] *** vendethiel left [11:47] What is "No concretization found for Foo" trying to tell me? [11:48] my $p = run 'false'; say $p.exitcode; $p = run 'false', :out; say $p.exitcode [11:48] damn [11:48] m: my $p = run 'false'; say $p.exitcode; $p = run 'false', :out; say $p.exitcode [11:48] rakudo-moar a5fe34: OUTPUT«run is disallowed in restricted setting␤ in sub restricted at src/RESTRICTED.setting line 1␤ in sub run at src/RESTRICTED.setting line 14␤ in block at /tmp/OHwB4sTs5s line 1␤␤» [11:48] ok [11:48] it output 1 and 0 [11:48] pwd [11:48] El_Che: at the very least you must close $p.out [11:48] * donaldh ahem [11:49] moritz: sure, if you like explosions [11:49] *** vendethiel joined [11:49] $p = run 'false', :out; $p.out.close -> boom [11:49] The spawned process exited unsuccessfully (exit code: 1) [11:51] *** iH2O left [11:51] that seems to be by design, but it results in a chicken-and-egg problem: no way to check the exitcode [11:52] *** ely-se joined [11:52] hello world [11:53] *** xpen left [11:54] ely-se: And if you try $p.out.close, then look at $p.exitcode? [11:54] oops [11:54] El_Che: ^^ [11:54] jnthn: boom [11:54] The try fails to catch the exception? [11:54] now building rc1, but I don't think it has changed [11:55] in summary: an run fail (non zero) will: [11:55] - closing out: boom [11:55] - checking exitcode without closing out == 0 [11:56] of course you can wrap stuff with try-catch blocks, but you will never be able to get the correct exitcode [11:56] (in case the application uses relevant exitcode, pretty common in unix) [11:57] El_Che: You still don't seem to have tried why I suggested. [11:57] *what [11:57] ok, rereading what you wrote [11:58] it does fail irrespective of a try [11:58] OK, that's very odd. [11:58] What is $p.out.close doing that's not catchable?! [11:59] the Pipe seems otherwise okay [11:59] because p6 is still lacking modules, shelling out will be pretty common in the beginning. Hence my whining :) [12:00] *** kid51 joined [12:01] nine@sunshine:~> perl6 -e 'my $p = run "false", :out; $p.out.close; CATCH { default { say "cought" } }' [12:02] cought [12:02] Looks fine to me? [12:02] nine: Does this work for you: `my $p = run "false", :out; try $p.out.close; say $p.exitcode` [12:02] nine: my point is not that it isn't catchable. But that the exitcode is lost [12:02] *** Guest55981 left [12:04] the Proc status is set by .close from the return from nqp::closefh_i which appears to crap out in some uncatchable way [12:05] * leont is confused, why would it need to throw an exception [12:05] RabidGravy: Yeah, managed to reproduce that here too [12:05] Very odd [12:05] *** bowtie_ joined [12:08] and closefh_i is a straight up moar op so I'll stop looking there [12:09] *** Skarsnik joined [12:09] Hello [12:10] \o/ (for the reproducible part) [12:10] *** vendethiel left [12:17] *** cognominal left [12:18] *** cognominal joined [12:18] *** cognominal left [12:24] When changing somehting in src/core/ I have to make again? [12:25] Skarsnik: just 'make install' [12:26] no configure needed, unless you add files to src/, which also means you need to add stuff to the Makefile.in files for moar and jvm [12:27] I am changing how Usage display stuff for main. Like put the slurpy at the end instead of before the positionnal [12:28] yeah, just make install [12:28] because foo --a --b [...slurpy] hello bar [12:28] make no sense [12:31] *** rindolf joined [12:32] Also I want to change the order of display for the arguments help. it use a hash so it's displayed in a 'random' order. should I sort like by alphebetic order or keep the order in MAIN signature? [12:32] *** perlawhirl joined [12:32] either makes sense [12:33] and either is better than random ordering [12:33] I should look at the spec x) [12:35] El_Che: it's not much consolation for proc that exit without sending anything to stderr... but for ones that do, you catch :err and check for output, ie: run('proc', :out, :err); if $proc.err.lines { ... } [12:35] *** st_iron joined [12:35] thats how i've worked around it. [12:35] hi [12:35] whelp there is nothing x) [12:39] m: say "Hi st_iron!" [12:39] rakudo-moar a5fe34: OUTPUT«Hi st_iron!␤» [12:40] ah interesting Pod error? sub MAIN( $hello #= the hello arg the doc get attached to MAIN and not hello [12:40] m: say "Greetings!" [12:40] rakudo-moar a5fe34: OUTPUT«Greetings!␤» [12:41] Skarsnik: What if you put the , after $hello ? [12:42] * jnthn vaguely recalls the attachment code being in the actino run when parameter is reduced, but we won't have considered the parameter full parsed at that point.. [12:43] sub MAIN( $hello, #= the hello arg do the same [12:43] If I put on the next line it work [12:44] it just surprised me x) [12:45] Usage: testmain.p6 [--all] [--define-enum=] [ ...] Ok that definitly better at least [12:48] Skarsnik: Yeah. It may be fixable by moving the attachment logic to param_var. hoelzro is probably the person "in the know" about this :) [12:51] *** kjs_ left [12:52] hm, how I can keep a hash (or some an eqv) that keep an ordered based on insertion? [12:55] and my english is aweful today [12:55] *** kjs_ joined [12:58] *** cognominal joined [13:00] maybe a stupid idea, but you can put keys in an array [13:00] that's ordered [13:00] Yes, actually I can maybe use a array of Pair [13:02] *** juu joined [13:06] m: my @tab; for ^10 {my $k = ("a".."z").pick; @tab.push($k => $_); say $k }; for @tab -> $v { say $v.key, $v.value} [13:06] rakudo-moar a5fe34: OUTPUT«x␤j␤p␤e␤w␤s␤z␤x␤f␤q␤x0␤j1␤p2␤e3␤w4␤s5␤z6␤x7␤f8␤q9␤» [13:07] *** flaviusb left [13:10] *** pierrot left [13:10] *** wamba left [13:16] *** flaviusb joined [13:20] *** kid51 left [13:21] *** milwaukee joined [13:24] Skarsnik: hmm...interesting bug; I'm surprised roast didn't catch that [13:24] jnthn is right; attaching docs to params is a bit odd [13:24] *** hoelzro_ is now known as hoelzro [13:24] * hoelzro has a look [13:25] odd? [13:26] That how the full usage is generated, by using the WHY x) [13:26] *** flaviusb left [13:27] *** [Coke]_ is now known as [Coke] [13:27] <[Coke]> . [13:29] *** dolmen joined [13:29] *** flaviusb joined [13:30] it'd odd that the doc is attaching to MAIN, I mean [13:30] *** lizmat joined [13:30] m: my Int:D @a; say @a[0]; [13:30] rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block at /tmp/b1rcL3md69 line 1␤␤» [13:30] m: try { my Int:D @a; say @a[0]; CATCH { default { say .^name } } } [13:30] rakudo-moar a5fe34: OUTPUT«X::Method::NotFound␤» [13:31] that's LTA [13:37] agreed [13:37] <[Coke]> if I want to cherry pick 8c406bf, do I also need to cherry pick the merge commit? [13:37] *** Sgeo joined [13:37] m: say Int:D [13:37] rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block at /tmp/yr9QJdyGgl line 1␤␤» [13:37] golf'd [13:38] m: say Int:D.^shortname [13:38] rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block at /tmp/mhK2uAmgB4 line 1␤␤» [13:39] that still leaves the question how autovivication works with Arrays that don't like undefined values. [13:39] *** vendethiel joined [13:40] gfldex: there should be an exception talking about a missing initializer I guess [13:40] *** lnrdo joined [13:40] *** Actualeyes left [13:41] .tell TimToady please have a look at http://irclog.perlgeek.de/perl6/2016-02-01#i_11972281 [13:41] gfldex: I'll pass your message to TimToady. [13:41] there wont be autoviv, because the constructor of the desired type might require some options [13:43] * [Coke] just skims scrollback [13:44] oh, duh. [13:44] Skarsnik's bug isn't actually a bug at all [13:45] #= attaches to the first declaration on the most recent line to contain a declaration [13:45] in sub MAIN($hello, [13:45] MAIN is the first decl on the line [13:47] is there a 6.d wishlist? [13:47] you mean, besides ponies? [13:48] rakudo/2016.01-preparation: 8dff411 | (Andy Weidenbaum)++ | tools/lib/NQP/Configure.pm: [13:48] rakudo/2016.01-preparation: fix parse_revision subroutine regex [13:48] rakudo/2016.01-preparation: [13:48] rakudo/2016.01-preparation: - compare release candidate versions, e.g. 2016.01-RC1 [13:48] rakudo/2016.01-preparation: - use extended p5 regex for readability [13:48] rakudo/2016.01-preparation: - quiet warnings when regex captures undefined [13:48] rakudo/2016.01-preparation: review: https://github.com/rakudo/rakudo/commit/8dff4111d4 [13:48] rakudo/2016.01-preparation: fb743c6 | coke++ | docs/announce/2016.01.md: [13:48] rakudo/2016.01-preparation: Thank author of last minute commit [13:48] rakudo/2016.01-preparation: review: https://github.com/rakudo/rakudo/commit/fb743c6a7b [13:49] *** nebuchadnezzar left [13:51] <[Coke]> (computer mediated communication) (irc ugly) this is why I still use an alternative my classmates at RPI came up with 20+ years ago on a daily basis that doesn't even support latin-1, because it's nicer than IRC. [13:51] *** kjs_ left [13:51] <[Coke]> (of course, it's only got a relatively tiny community on it.) [13:53] *** SCHAAP137 joined [13:54] *** wamba joined [13:58] <[Coke]> gfldex: no, there is not, but there are already people asking how they can submit their wishlist items. [13:59] <[Coke]> I think once jnthn++'s notes on how he thinks releases should be done come out, we can put up a workflow of sorts for what might get included in 6.d and what it'll look like before 6.d is actually released. [13:59] We could have an RT meta-ticket for the wishlist [13:59] *** Actualeyes joined [13:59] (Where individual feature requests are RTs) [13:59] <[Coke]> in the meantime, a discussion on the mailing list might work; a pull request if you've alredy got it mapped out (and we will probably have you change it at some point once we figure out what it should look like) [13:59] <[Coke]> or an R... what jnthn said. [14:00] *** milwaukee left [14:00] I also found that using a gist as a request for input worked fairly well [14:00] jnthn: i would prefer a .md in mu on github to keep the wishlist items in one spot. That may help greatly with duplicated items. [14:00] *** vendethiel left [14:01] <[Coke]> Oh. jnthn, we also need to add a version field to the basic info. [14:01] <[Coke]> (on RT) [14:03] <[Coke]> We can add 6.c/6.d for now? Anyone think we need other values, or that it's not worth adding? [14:03] [Coke]: What's the purpose of it? [14:03] (Just want to make sure we're not confusing compiler/language version.) [14:03] <[Coke]> I guess if everything is in the same binary, not much? [14:04] Aye. Having a way to tag tickets with compiler backend/version otoh may help. [14:04] We already have backend iirc [14:04] <[Coke]> but it would give us a way to say "these are issues that need to be fixed in 6.c" vs. "these are for discussion in an upcoming 6.d" [14:04] *nod* [14:04] <[Coke]> jnthn: platform, tag, vm [14:05] * jnthn is busily working on said verioning/release notes, btw :) [14:05] *** skids joined [14:06] *** cdg joined [14:08] ...am I the only one who completely missed the news about possible gravitation waves discovery? [14:08] err....no? [14:09] oh, goood :) [14:09] ...nope [14:09] Well ok, I've read about rumors. But those come and go [14:10] <[Coke]> jnthn: we can always use [**] in a subject line. Or just close more tickets, I guess. :) [14:11] *** perlpilot joined [14:11] *** molaf joined [14:17] *** pmurias left [14:22] *** perlawhirl left [14:25] *** st_iron left [14:25] *** st_iron joined [14:25] *** st_iron left [14:28] *** ZoffixW joined [14:28] Is there a way to unflatten this so that the two say()s are the same? [14:28] m: 'ABC'.lc.say; 'ABC'.map({slip .lc}).say; [14:28] rakudo-moar a5fe34: OUTPUT«abc␤(abc)␤» [14:28] m: 'ABC'.lc.say; 'ABC'.map({slip .lc}).Slip.say; [14:28] rakudo-moar a5fe34: OUTPUT«abc␤(abc)␤» [14:29] m: role R { has $!thing }; class C does R { method foo { $!thing = 17 } }; C.new.foo [14:29] rakudo-moar a5fe34: ( no output ) [14:29] hm, I guess hyper op can do it [14:29] m: 'ABC'.lc.say; 'ABC'.map({.lc})».say; [14:29] rakudo-moar a5fe34: OUTPUT«abc␤abc␤» [14:29] never mind :P [14:29] ↑ should classes be able to access a private attribute declared by a role they consume? [14:30] hoelzro: yes [14:30] ah, ok; I just couldn't find that in S12 [14:30] it was a long matter of dispute [14:31] Well, it's in S14 if anywhere, and falls under the "behaves as if it was declared in the class the role was composed into" rule [14:31] there was a time when rakudo would disallow it, but declaring the same private attribute again in the class would lead to collision [14:31] ahhhh [14:31] that makes sense [14:31] thanks all()! [14:32] *** raiph joined [14:35] *** nebuchadnezzar joined [14:37] hm [14:37] m: 'ABC'.&( -> ($self, $who = 'Anonymous') {"Know your $self, $who!"} ).say; [14:37] rakudo-moar a5fe34: OUTPUT«Too few positionals passed; expected 1 or 2 arguments but got 0 in sub-signature␤ in block at /tmp/TyrxGz_0G7 line 1␤␤» [14:37] m: 'ABC'.&("Know your $self!").say; [14:37] rakudo-moar a5fe34: OUTPUT«5===SORRY!5=== Error while compiling /tmp/FxWr4YZ8Bn␤Variable '$self' is not declared␤at /tmp/FxWr4YZ8Bn:1␤------> 3'ABC'.&("Know your 7⏏5$self!").say;␤» [14:38] m: 'ABC'.&("Know your " ~ *).say; [14:38] rakudo-moar a5fe34: OUTPUT«Know your ABC␤» [14:38] Is there a way to shove in a signature in such a construct somehow? [14:39] m: 'ABC'.&(-> Str $s {"Know your " ~ $s}).say; [14:39] rakudo-moar a5fe34: OUTPUT«Know your ABC␤» [14:39] ZoffixW: i just pointyed you in the right direction [14:40] gfldex, ah, thanks. I had one too many sets of parens. [14:40] m: 'ABC'.&( -> $self, $who = 'Anonymous' {"Know your $self, $who!"} )('Zoffix').say; [14:40] rakudo-moar a5fe34: OUTPUT«Know your ABC, Zoffix!␤» [14:40] gfldex++ [14:42] *** CIAvash left [14:50] *** raiph left [14:51] *** sjoshi left [14:53] *** CIAvash joined [14:55] *** raiph joined [14:56] *** xpen joined [14:59] *** vendethiel joined [15:00] Is there any datatype like a Hash but where the keys are static (ie. you can't add a new key to it after creation) but where the values can be changed? [15:01] *** xpen left [15:01] Zero_Dogg: NYI [15:01] hoelzro, Oh ok, It's just confusing [15:01] hoelzro, maybe it should warn? [15:03] Zero_Dogg: Not built in (at least not for now); probably quite easy to do through a subclass though [15:05] gfldex, jnthn: Thanks. I figured I could subclass or even just implement a simple one myself, but that's overkill for the program I wanted to use it in :) [15:07] Zero_Dogg: Typically, when people want a hash with a fixed set of keys, they want several of those hashes, all with the same structure, and it represents some kind of object. And in those many cases, actual objects are probably better anyway :) [15:07] m: my %h where { say .^name; True }; %h = 1; [15:07] rakudo-moar a5fe34: OUTPUT«Mu␤Mu␤Int␤Int␤Int␤» [15:08] Wha, that 'where' gets executed 5 times? [15:08] *** rindolf left [15:08] duh [15:08] i'm not surprised because i wrote an advent post :) [15:09] Juerd: aye, it might even be better in this case, but it's a simple single-file command-line program, right now resting at around 800 lines of code, not really sure it'd be worth it. I'm just passing a bunch of variables around now, which gets a bit ugly [15:09] Zero_Dogg: Making a class is not much work or code in Perl 6 :) [15:09] Zero_Dogg: classes aren't very verbose [15:10] Especially when you can has ($.a, $.b, $.c) [15:10] Zero_Dogg: in fact 800 lines is *way* beyond the point where I'd start to use classes [15:10] m: class Foo { has $.bar; has $.baz; has $.quux; has $.xyzzy }; my $x = Foo.new(bar => 1, baz => 2, quux => 3, xyzzy => 4); say $x.perl [15:10] rakudo-moar a5fe34: OUTPUT«Foo.new(bar => 1, baz => 2, quux => 3, xyzzy => 4)␤» [15:10] (to the degree that such things can be measured in lines of code) [15:11] moritz, jnthn: Interesting, guess I'll go look at that then. My brain might still be a bit too stuck in perl5-land. [15:11] Zero_Dogg: In Perl 5 you had to do a lot of things manually, or pull in a module from CPAN. [15:11] Zero_Dogg: In Perl 6 you just get very usable objects out of the box. You don't even have to write your own 'new' method ;) [15:12] Juerd: woah, not even my own new method, it's like magic ;) [15:12] That! [15:12] guess this is as good a time as any to learn more about perl6 classes then, thanks! [15:12] ... magic and unicorns all the way down! [15:12] haha [15:12] Zero_Dogg: Okay, see you in 10 minutes then :) [15:13] Juerd: hehe :p [15:13] To a first approximation, Perl 6 OO is similar to Moose OO [15:13] No, really, if you're going to learn only class stuff, not roles, 10 minutes is probably what it takes. [15:13] nod, I've used Moose a lot, from what little I've looked at perl6 classes, they are quite familiar [15:13] If you'd also learn roles, add another 5 minutes if you're already familiar with the concept, or 15 if you need to learn that too ;P [15:14] and roles only take a few seconds more ;) [15:14] Which isn't surprising, given that a lot of Moose is inspired by Perl 6 (and related MOP-based OO-systems) [15:14] I think I understand roles, but I haven't yet used them. [15:14] *** nakiro left [15:14] My brain's still too much in isa-land. [15:15] Juerd: hehe, nice! I'm really liking what I've used of perl6 so far. This one command-line app is my «learning/playing-with-perl6» project [15:15] Nobody working on a websocket async client? (could be useful if we want a slack module probably) [15:15] I like most things too. And the few things I don't like yet, are being worked on :) [15:16] m: subset StrictKeys of Str where * eq ; my %h{StrictKeys}; %h = 1; [15:16] rakudo-moar a5fe34: OUTPUT«Type check failed in binding key; expected StrictKeys but got Str␤ in block at /tmp/YM3P9fxrGW line 1␤␤» [15:16] There are some things that I find hard to figure out. I still don't know how to implement automatic reconnects in a program that uses 'react { ... }' and IO::Socket::Async. [15:16] I did find a quirk with role composition today [15:17] gfldex: any(<...>)? [15:18] m: subset StrictKeys of Str where * eq any(); my %h{StrictKeys}; %h = 1; %h = 2; say 'alive'; %h = 3; [15:18] rakudo-moar a5fe34: OUTPUT«alive␤Type check failed in binding key; expected StrictKeys but got Str␤ in block at /tmp/_x4QFwHksq line 1␤␤» [15:18] Juerd: indeed [15:18] Zero_Dogg: see ^^^ [15:21] m: class Foo { has ($.I, $.dont, $.need, $.no, $.stinking, $.hash) is rw; }; my $f = Foo.new; $f.I = 1; $f.stinking = 1; say "alive"; $f.false = 3;' [15:21] rakudo-moar a5fe34: OUTPUT«5===SORRY!5=== Error while compiling /tmp/kfhw1mbC0Q␤Unable to parse expression in single quotes; couldn't find final "'" ␤at /tmp/kfhw1mbC0Q:1␤------> 3tinking = 1; say "alive"; $f.false = 3;'7⏏5␤ expecting any of:␤ sing…» [15:21] The class example is actually shorter! [15:21] m: class Foo { has ($.I, $.dont, $.need, $.no, $.stinking, $.hash) is rw; }; my $f = Foo.new; $f.I = 1; $f.stinking = 1; say "alive"; $f.false = 3; [15:21] rakudo-moar a5fe34: OUTPUT«alive␤Method 'false' not found for invocant of class 'Foo'␤ in block at /tmp/xPvdrV7crf line 1␤␤» [15:21] And gives better error messages ;) [15:21] Juerd: Something like: sub auto-retap($supply) { supply { sub tap-it-now() { whenever $supply { emit $_; LAST { tap-it-now() }; QUIT { tap-it-now() } } }; tap-it-now() } } [15:23] *** gtodd left [15:23] is $!foo just sugar for my $foo; method !foo is rw { $foo }; ? [15:23] is $!foo just sugar for method !foo is rw { state $foo }; ? [15:24] ZoffixW: no, private attributes are also optimiser food [15:24] No, it's not sugar at all really [15:25] jnthn: I'm not sure where this would go. I'd like to reconnect things like MQTT::Client or your Stomp::Client... [15:25] m: class Foo { method !foo is rw { state $foo }; method bar { self!foo }; }; my $o = Foo.new; $o.bar = 42; say $o.bar [15:25] rakudo-moar a5fe34: OUTPUT«Cannot modify an immutable Any␤ in block at /tmp/OQhdmnFWLj line 1␤␤» [15:25] jnthn: So the supplies I have in the main program are made in modules [15:26] m: class Foo { method !foo is rw { state $foo }; method bar is rw { self!foo }; }; my $o = Foo.new; $o.bar = 42; say $o.bar; $o.bar = 72; say $o.bar [15:26] rakudo-moar a5fe34: OUTPUT«42␤72␤» [15:26] neat :D [15:26] But knowing that phasers exist in 'whenever' is useful. I might be able to figure something out :) [15:27] ZoffixW: You can do this in Perl 5 with lvalue methods, but that induces headaches :) [15:27] ZoffixW: Yes, but note that state variables are not per instance! [15:28] Ahhh [15:28] *** AlexDaniel joined [15:29] Juerd: Provided the module exposes a Supply and does the right thing (e.g. connect again) when it's tapped a second time, it shouldn't matter overly much where in the pipeline it goes. [15:29] *** risou is now known as risou_awy [15:29] *** risou_awy is now known as risou [15:29] Juerd: We may end up with a pattern where modules provide hooks for async "middleware" though [15:30] To allow a sub that takes a supply and returns another supply to be plugged in at strategic points. [15:30] jnthn: Reconnect on retap, that's where I have no idea how to implement it. Currently I haven't even figured out how to tell whether it's still connected even :) [15:31] Although the protocol has ping, so I could just use that ;) [15:31] gfldex: haha, thanks [15:32] *** adu joined [15:33] is it possible for a piece of code to know if was precompiled before it was run? for instance: MAIN_HELPER being able to use it to change the displayed application path (bin/whatever instead of some long absolute sha1 path) [15:34] otherwise, maybe some sort of option for wrappers to override the displayed path? [15:36] *** sena_kun joined [15:38] *** domidumont left [15:39] On my way home from FOSDEM a dug a little into how hard it would be to make it possible to precompile modules and move both source and precomp file to a different directory afterwards, i.e. the distro package use case. [15:39] Looks like it's not impossible but not exactly simple either. [15:40] *** ely-se left [15:40] Is there any way to find out is argument was sent in subroutine by caller or default value was used? Something like this exists in lisp, for example. [15:41] *** musiKk joined [15:42] whats the techinical reasons it doesnt work now? i assume absolute paths, but then why use absolute paths? [15:42] The path is compiled within the module? [15:43] sena_kun, that a weird usage, checking if not default is not enought? [15:43] sena_kun: First, see if the problem isn't better solved by multiple dispatch. :-) But if you really need to do it, then you can also grab the argument capture and look at that. [15:43] *** vendethiel left [15:43] m: sub foo(|c, $a, $b = 42) { say c.list.elems }; foo(1); foo(1,2) [15:43] rakudo-moar a5fe34: OUTPUT«5===SORRY!5=== Error while compiling /tmp/8YTIqET2V3␤Cannot put required parameter $a after variadic parameters␤at /tmp/8YTIqET2V3:1␤------> 3sub foo(|c, $a7⏏5, $b = 42) { say c.list.elems }; foo(1);␤ expecting any of:␤ constr…» [15:43] ah [15:44] m: sub foo($a, |c, $b = 42) { say c.list.elems }; foo(1); foo(1,2) [15:44] sena_kun: no explicit feature, i believe. however you could make it a named param, then do «$param.defined ?? $param !! ""» [15:44] rakudo-moar a5fe34: OUTPUT«5===SORRY!5=== Error while compiling /tmp/4TDi94BmHR␤Cannot put optional positional parameter $b after variadic parameters␤at /tmp/4TDi94BmHR:1␤------> 3sub foo($a, |c, $b = 427⏏5) { say c.list.elems }; foo(1); foo(1,2)␤ expecting any …» [15:44] Oh, unpack... [15:44] *** domidumont joined [15:44] m: sub foo(|c ($a, $b = 42)) { say c.list.elems }; foo(1); foo(1,2) [15:44] rakudo-moar a5fe34: OUTPUT«1␤2␤» [15:44] That'll do it [15:44] But yeah, it's generally a "design smell" to want to do it. [15:45] MadcapJake, it's a bit sad. Anyway, it's really rare feature to use, so it's not a problem, I suppose. [15:45] ugexe: yes, the precomped file contains the full path to the source file (available as $?FILE). Usually, you will want the full path there. [15:45] in CL you'd still need to hinge on the param-supplied-p to do it, so it's gonna add at least a line of code either way [15:45] jnthn, thanks for your code. I'm writing a little temportary patch now, so I assume it'll be replaced by some better design later. [15:46] *** fireartist left [15:47] *** krshn left [15:47] ZoffixW: huggable is dead! [15:48] alternatively [15:48] m: role Default {}; sub foo($a, $b = ( 1 but Default )) { say $b ~~ Default ?? "got default" !! "not default"; }; foo(1); foo(1,2) [15:48] rakudo-moar a5fe34: OUTPUT«got default␤not default␤» [15:48] Cute! [15:49] x) [15:49] El_Che: I'm reading through the backlog, it seems like you've stumbled upon this: https://rt.perl.org/Public/Bug/Display.html?id=125757 [15:49] RabidGravy, seems legal and readable. [15:50] AlexDaniel, weird. The script itself is still running with last message in the debug being a pong response to "[server 2016-02-01T05:37:54.641548Z] PING :leguin.freenode.net" [15:50] * ZoffixW still hasn't had any chance to hack on the IRC stuff [15:50] *** huggable joined [15:51] huggable, Bag [15:51] ZoffixW, class Bag [Immutable collection of distinct objects with integer weights]: http://doc.perl6.org/type/Bag [15:52] *** FROGGS left [15:56] RabidGravy: that's neat! [15:56] or crack-addled [15:58] *** adu left [15:59] m: role Foo { }; class Bar { method baz($a,$b = ( 1 but Foo)){ print $b; } }; Bar.new.baz(1) [15:59] rakudo-moar a5fe34: OUTPUT«1» [15:59] New blog post exploring some of shortcuts in Perl 6: http://blogs.perl.org/users/zoffix_znet/2016/02/perl-6-shortcuts-part-1.html [16:00] *** ecocode left [16:00] ZoffixW, sounds like it got netsplit and never recovered [16:00] [01 05:49] * huggable has quit (*.net *.split) [16:00] (timestamp is utc) [16:00] geekosaur, ah, *phew*. Then that should be easy to fix [16:05] * ZoffixW is hoping threads like these to have Perl 6 in them by 2018: https://news.ycombinator.com/item?id=11012044 [16:05] No match for "Perl" at all ATM. Depressing :/ [16:07] *** _Gustaf__ left [16:08] *** _Gustaf_ joined [16:09] *** musiKk left [16:12] Heh. UK gets approval to genetically modify humans. Illegal to birth them, but still, what a time to be alive :) I guess Gataka will be the next movie after Idiocracy to become a documentary :D http://www.bbc.com/news/health-35459054 [16:12] *** kurahaupo joined [16:14] *** khw joined [16:18] *** ZoffixW left [16:24] Zero_Dogg: well. it is a rather short thread [16:24] Skarsnik: it's definitely weird; I wouldn't be against a warning [16:26] *** BenGoldberg joined [16:29] *** pi4 left [16:29] *** pi4 joined [16:31] added an svg badge generator: perl6.bestforever.com/badge.svg [16:35] MadcapJake: what does it mean? [16:35] *** Zero_Dogg left [16:36] *** Zero_Dogg joined [16:36] MadcapJake, you managed to host image with baillador? x) [16:37] Skarsnik: that's svg [16:37] Skarsnik: which is still text :) [16:37] Oh yeah, that cheating [16:37] hahah [16:37] cheating is technique! [16:38] I should patch my Gumbo module to offer svg parsing x) [16:38] not sure how useful it can be [16:39] *** FROGGS joined [16:40] Skarsnik: thank you again for Gumbo :) [16:41] I needed to parse fimfiction.net with 260kb html page and h:p:x was slow and giving me wrong result... so I needed something else x) [16:41] *** ZoffixW joined [16:41] MadcapJake, Why? Are you having issues with that? "Skarsnik MadcapJake, you managed to host image with baillador? x)" [16:42] ZoffixW: yeah, last time we couldn't figure out how to do that [16:42] Me? No, but I think MadcapJake did not find how to provide binary content [16:43] You just send appropriate content type and write the image. Here's my use of MIME::Type for CSS/JS files: https://github.com/zoffixznet/p6high.xtatik.org/blob/master/site.pl6#L50 O [16:43] s/O$/I'm sure it works for images and any other files too/; [16:43] *** pecastro left [16:43] ZoffixW: CSS/JS files are not binary [16:43] Lemme try with images :) 1 sec [16:43] yeah, try it [16:44] *** perl6newbee joined [16:45] *** vendethiel joined [16:46] (still installing Bailador... more secs) :) [16:46] *** rarara left [16:48] By the way, generating svgs with perl6 is fun: https://files.progarm.org/both.svg (hover over pins to highlight the net) [16:50] it's confusing, what is that? [16:50] looks like a mainboard without pci slots [16:51] though these five-pin-ground-thingies are weird [16:51] ohh, is this a raspi? [16:52] hmmm, no, it has a volume switch [16:52] I think this was some tablet that we had to fix. However, we couldn't find schematic or anything else that would help us to do that. But we managed to find some files that were used for flying probe tests [16:52] it might be a phone [16:52] AlexDaniel: it's a generated badge showing the current total users on Perl 6 slack and the number active currently [16:53] hehe [16:53] Skarsnik: yep I did! Bailador works great! As long as I don't have to serve anything that isn't text xD [16:53] these files were in some weird format, but it was all text, so… Turned out it had enough information (pin locations and nets) to get the work done [16:54] Ahhh "Type check failed in assignment to $output; expected Str but got Buf" [16:54] ZoffixW: i'll check that out, but i tried setting the content type and it would only send a little white box [16:55] *** domidumont left [16:55] oh, and it's both sides of the board at the same time. E.g. here's just the top side: https://files.progarm.org/top.svg [16:55] ZoffixW: yeah it doesn't want to accept a Buf, but I thought that PSGI was supposed to work on IO.handle so I tried just returning the result of an open call, and that's when it just sends a 1 pixel white box :P [16:55] *** pecastro joined [16:55] FROGGS++ for figuring it out immediately :) [16:56] *** dmaiocchi joined [16:56] :o) [16:58] m: 'a+b'.trans( '+' => '%2b' ).say # why does this just replace with the first char? [16:58] rakudo-moar a5fe34: OUTPUT«a%b␤» [16:58] *** dolmen left [16:59] FROGGS: the components are actually fake. The files had information like “these pads belong to this component” but no sizes of the component itself, so I just drew a box around the pins :) otherwise it's just too hard to see what's going on if it's just a bunch of dots [16:59] MadcapJake, because that's what trans does [16:59] ahh, interesting [16:59] too bad it was just a one-time throwaway script [16:59] if you want what you want it's subst [17:00] RabidGravy: the example in the docs says otherwise [17:00] I didn't even feel like posting it on github because I don't think that someone will ever face exactly the same problem… [17:00] http://doc.perl6.org/routine/trans#class_Str [17:00] it shows someone replacing `<` with `<` [17:01] m: 'say $x && $y'.trans( '<' => '<', '>' => '>' ).say [17:01] rakudo-moar a5fe34: OUTPUT«say $x&b& && $y&a&␤» [17:02] AlexDaniel, MadcapJake http://xtatik.org:3000/public/pics/camelia.png [17:02] :) [17:02] ZoffixW: O_O how?! [17:03] RabidGravy: either the docs are completely off on how trans should work or there is a bug [17:03] lol.. I had to modify PSGI [17:03] MadcapJake, remove "Str" from this line: https://github.com/supernovus/perl6-psgi/blob/cb8e26e57bb104a64d89b75ada6d02cdd0949aa4/lib/PSGI.pm6#L18 [17:03] Nope it's the docs [17:04] haha nice! You should submit a PR for that! [17:04] Then it doesn't choke when you give it a buf. And you just slurp it up and send with :bin as in here: https://github.com/zoffixznet/p6high.xtatik.org/blob/master/site.pl6#L57 [17:04] * ZoffixW submits an Issue [17:04] ZoffixW: the comment above the multi specifically says it can be an array,str, or buf [17:04] heh [17:05] ZoffixW: ISSUE? Submit a pull request!! [17:05] RabidGravy: this was added only 25 days ago, are you positive? [17:06] gfldex: are you around? [17:06] partly [17:06] the trans docs you merged, show a use of trans replacing one char `<` with `<`, is that actually accurate? [17:06] AlexDaniel, I'm not familiar with that module. I described what fixes the problem in the Issue and I'll leave it to the author to decide whether the fix is sane: https://github.com/supernovus/perl6-psgi/issues/6 [17:07] But it's by supernovus :/ They don't check github much, I noticed. [17:07] MadcapJake: i have to check [17:08] Well if it's a "bug" then some put it in there very deliberately, " return Rakudo::Internals.TRANSPOSE(self, $from, substr($to,0,1)) if $from.chars == 1;" [17:08] *shrug* [17:08] The name suggests it'd work like Perl 5's tr///, which does operate on single chars. [17:08] RabidGravy: http://design.perl6.org/S05.html#Transliteration shows it being used as shown in the docs, so i think it's a goof [17:08] m: my $str = 'say $x && $y'; $str.=trans( '<' => '<' ); dd $str [17:08] rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\&b> \&\& \$y\&a>"␤» [17:09] MadcapJake: seams not to work that well [17:09] m: 'say $x && $y'.trans( '<>' => '[]' ).say [17:09] rakudo-moar a5fe34: OUTPUT«say $x[b] && $y[a]␤» [17:09] *** raiph left [17:09] but why wouldn't you use subst for that [17:09] Because you can do multiple chars :) [17:10] m: 'zoomba'.trans( 'a..b' => 'A..B' ).say [17:10] rakudo-moar a5fe34: OUTPUT«zoomBA␤» [17:10] m: my $str = 'say $x && $y'; $str.=trans( [ '<' , '>' , '&' ] => [ '<', '>', '&' ]); dd $str [17:10] rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\<b\> \&\& \$y\<a\>"␤» [17:10] yeah I know how it works [17:10] Hm, Perl 5 version lets you use ranges, and much faster than using a regex, which is why you'd ever use it in the first place. [17:10] Did IO.e start caching recently? [17:10] RabidGravy: that would require multiple subst calls otherwise [17:11] m: 'zoomba'.trans( 'a..z' => 'A..Z' ).say [17:11] rakudo-moar a5fe34: OUTPUT«ZOOMBA␤» [17:11] -_- [17:11] m: my $str = 'say $x && $y'; $str.=trans( ['a'..'y'] => ['A'..'z'] ); dd $str [17:11] rakudo-moar a5fe34: OUTPUT«Str $str = "SAY \$X \&\& \$Y"␤» [17:12] *** ZoffixW left [17:12] m: my $str = 'say $x && $y'; $str.=trans( '<' => '<', '>' => '>' ); dd $str [17:12] rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\&b\& \&\& \$y\&a\&"␤» [17:12] yeah, if the from is a string of 1 char then it gets changed to 1 char [17:12] leont: recently on what timescale? I remember someone complaining and something changing around christmas-time... [17:12] other uses are possible [17:13] not overly consitent [17:13] I was more thinking about January [17:13] I forgot on which version my code worked, but on a more recent rakudo it doesn't anymore [17:13] anyway, the docs must describe behaviour that actually works [17:14] Not saying this is a bad change, just surprised [17:15] to be honest i thought it had always done it [17:15] if it were up to me, I would've made the stat result less invisible so it can be scoped like any other variable... [17:16] *** dmaiocchi left [17:19] *** lokien_ left [17:20] doc: 444f8c0 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Str.pod: [17:20] doc: fix trans for Pairs and list of Pairs [17:20] doc: review: https://github.com/perl6/doc/commit/444f8c0b3a [17:20] That would make more sense, yes [17:23] so trans isn't supposed to work that way? I thought the design docs showed it like that too. [17:24] if you think it's a bug you should report it. As long as it doesn't make roast unhappy it's correct. The design docs are design docs, not Written Down Truth. [17:25] *** psy_ joined [17:27] *** vendethiel left [17:28] *** ZoffixW joined [17:31] but the design docs only shows the array version [17:31] "The array version can map one-or-more characters to one-or-more characters" [17:32] *** raiph joined [17:34] m: for ^3 { when 0 { say "Almost there!" }; when 1 { say "There!!!" }; .say } [17:34] rakudo-moar a5fe34: OUTPUT«Almost there!␤There!!!␤2␤» [17:34] m: for ^3 { say "Almost there!" when 0; say "There!!!" when 1; .say } [17:34] rakudo-moar a5fe34: OUTPUT«Almost there!␤0␤There!!!␤1␤2␤» [17:35] Is this difference supposed to be there? ^ Postfix form doesn't short-curcuit the block [17:36] "A when statement will also do this (but a when statement modifier will not.)" [17:36] I guess I should get more used to there being docs for things :P [17:36] hah [17:38] *** Actualeyes left [17:39] *** vendethiel joined [17:39] *** CIAvash left [17:40] *** ZoffixW left [17:45] *** psy_ left [17:49] *** keix joined [17:55] *** perigrin_ is now known as perigrin [17:56] *** khw left [17:57] *** dha joined [17:57] *** dakkar_ left [17:59] *** Relsak joined [18:00] *** vendethiel left [18:01] *** sena_kun left [18:02] *** firstdayonthejob joined [18:08] *** wamba left [18:08] *** vendethiel joined [18:10] *** eiro left [18:11] *** khw joined [18:16] *** eiro joined [18:22] *** espadrine left [18:22] *** addison_ joined [18:24] is there a way to print all arguments provided? [18:24] to a sub/method [18:25] *** Relsak left [18:29] *** vendethiel left [18:31] *** LLamaRider joined [18:31] *** LLamaRider left [18:34] MadcapJake: if you capture them, sure. [18:37] nothing like JS's arguments object? [18:39] MadcapJake: what exactly are you trying to do? [18:40] *** vendethiel joined [18:41] m: sub foo ($x, $y, $z) { say @_; }; say foo(1,2,4) [18:41] rakudo-moar a5fe34: OUTPUT«5===SORRY!5=== Error while compiling /tmp/ZBpG7YaFEW␤Placeholder variable '@_' cannot override existing signature␤at /tmp/ZBpG7YaFEW:1␤------> 3sub7⏏5 foo ($x, $y, $z) { say @_; }; say foo(1␤» [18:41] Darn [18:41] Thought I'd give it a shot [18:42] nine: I just am working on a sub and trying to debug all these positional arg errors; in JS, I'd just print arguments and figure out how things were being provided [18:43] m: sub foo( |c ( $this, @that) ) { say "this($this), that({@that}), all({c})" }; foo "this", ; [18:43] rakudo-moar a5fe34: OUTPUT«this(this), that(other stuff), all(this other stuff)␤» [18:44] cool! thanks! [18:45] you could also wrap the sub in question [18:46] *** spider-mario joined [18:46] maybe we could repurpose _ to be a special capture for the sub/method args but I don't know if that would have any deleterious effects (besides the obvious one of using _ for the name :) [18:47] *** musiKk joined [18:47] that may make the optimiser unhappy [18:50] *** psy_ joined [18:54] *** cpage_ left [18:55] *** cpage_ joined [18:55] *** araujo joined [18:56] *** araujo left [18:56] *** araujo joined [18:56] *** araujo left [18:56] *** araujo joined [18:57] .botsnack [18:57] :D [18:59] *** circ-user-zCdXs joined [18:59] *** circ-user-zCdXs left [18:59] *** circ-user-bFgx6 joined [19:00] <[Coke]> m: ("z".ord+1).chr.say [19:00] rakudo-moar a5fe34: OUTPUT«{␤» [19:00] *** musiKk left [19:01] *** cpage_ left [19:01] I get a "Could not find Shell::Command" from travis, even though I declare a test-demands on it :-s [19:01] depends [19:02] maybe thecapture can be gotten from caller/callframe? (granting that some of that is NYI) [19:02] *** ecocode joined [19:03] *** ecocode left [19:03] <[Coke]> is our travis stuff smart enough for test-depends? [19:04] *** eiro left [19:05] *** ecocode joined [19:06] hi.. Where can I find docs about 'repr' ? [19:07] and more generally: is there something like perl6doc ? [19:07] ecocode: I'm not sure that we have "docs" per se for repr [19:07] ecocode: there's p6doc [19:08] <[Coke]> ecocode: something like it, yes, but it's not as functional yet as what you expect from p5 [19:08] <[Coke]> docs.perl6.org [19:08] how do you provide a group of submodules in one all-inclusive module? (I want there to be choice between using the whole package or just the bit you need) [19:08] <[Coke]> ecocode: http://docs.perl6.org/language/nativecall [19:09] I thought having a base pm file with a bunch of 'use' statements would work, but it doesn't seem to [19:09] *** domidumont joined [19:10] <[Coke]> MadcapJake: the p6 style is more to have one thing per file at the moment. [19:10] OK. thanks for the info (and especially p6doc :) ) [19:10] *** eiro joined [19:10] MadcapJake: see TAP::Harness [19:10] has someone made an epub or pdf from the docs on docs.perl6.org ? [19:12] [Coke]: ok, I do have one module per file, I just wanted to add a module at .. that included all those in the subdir [19:14] *** FROGGS[mobile] joined [19:17] *** circ-user-bFgx6 left [19:17] *** domidumont left [19:17] *** domidumont joined [19:17] *** cdg left [19:18] *** ecocode left [19:19] *** musiKk joined [19:21] *** rindolf joined [19:21] *** domidumont left [19:21] *** eiro left [19:21] *** matt_ left [19:22] *** perl6newbee left [19:23] <[Coke]> MadcapJake: that seems... reasonable. [19:23] MadcapJake: A use statement will only import into the current lexical scope. If you want a file with a bunch of use statements to provide those same routines, you'll need to re-export the symbols. [19:23] <[Coke]> no works? [19:24] <[Coke]> ah, perlpilot++ [19:25] *** musiKk left [19:29] *** cognominal left [19:32] *** domidumont joined [19:32] *** eiro joined [19:32] *** matt_ joined [19:33] *** tmtowtdi joined [19:34] *** frobisher joined [19:34] *** dha left [19:34] *** frobisher is now known as dha [19:35] perlpilot: how would i re-export them? [19:38] I tried doing «require Sub::Module ('exported-sub', 'another-exported-sub')» but it said Sub::Module didn't export anyting. o_O [19:38] MadcapJake: well ... you're *supposed* to be able to say "use Foo :EXPORT;" but that's NYI. (maybe you could champion that :) [19:38] *** edenc_ is now known as edenc [19:38] *** edenc left [19:38] *** edenc joined [19:39] MadcapJake: for now, you can provide an EXPORT sub that returns what you want exported. [19:40] MadcapJake: See the top of https://github.com/perlpilot/p6-Test-Class/blob/master/lib/Test/Class.pm6 for an example. [19:41] cool thanks! I don't know if my perl6 wizardy level is high enough to implement the NYI :EXPORT adverb :( [19:41] wizardry* [19:44] MadcapJake: This is how you learn :) [19:45] I've an odd question: how the heck does --stagestats keep getting printed to my console? It's circumventing both the redirects in the wrapper script I'm using and my *system package manager's* output capture layer! [19:46] flussence: maybe it's sent to FD #3 :) [19:47] *** cpage_ joined [19:47] um ... looking at the code, it seems to be sent to stderr normally though [19:48] *** dmaiocchi joined [19:48] * perlpilot work & [19:49] yeah, I don't get it. I run this script and get a nice big log full of compiler spam, gcc warnings and all... and then my terminal prints the stage stats and an "installed!" line. [19:51] and that's a «note» line, so should be stderr... [19:56] *** wamba joined [19:58] * geekosaur gets lost looking for stderr redirections [19:58] (the easiest way to accomplish that is the equivalent of freopen("/dev/tty", "w+", stderr)) [20:01] also when I went looking for stagestats I landed in nqp code, no "note" commands visible... [20:02] "note" is a Perl 6 sub. In NQP it's nqp::say(nqp::getstderr(), ...) [20:02] nqp::saysf(nqp::getstderr(), ...) [20:03] Darn... it's nqp::sayfh(nqp::getstderr(), ...) [20:03] yep [20:03] that was my point [20:03] there was one mention of stagestats in perl6 code, most of the rest were in nqp/HLL/* [20:06] *** ecocode joined [20:07] *** Relsak joined [20:07] * geekosaur suddenly wonders if this might be libuv being "helpful" [20:08] hm, that was my gut feeling too [20:11] hi all, i want to make a rpm package for perl6 [20:11] :) [20:11] you might want to wait for 2016.01 then, last months was broken for almost everyone that tried to package it [20:12] should be arriving this week, if we're lucky [20:13] ok, thx [20:14] was some nice conference @fossdem, so they motivated to help also perl6 [20:14] :) [20:14] *** dolmen joined [20:15] flussence - what are the chances of us being lucky? :-) [20:16] *** darutoko left [20:16] no idea, I'll admit I haven't been paying much attention this month, kinda worn out with it all... [20:16] I'm actually curious, as NY.pm is having a p6 beginners study group on saturday, and it would be great if those attending could have a relatively up to date release to work with. [20:18] *** lokien_ joined [20:21] m: say [~] ‘hello world’.ords».succ».chr [20:21] rakudo-moar a5fe34: OUTPUT«ifmmp!xpsme␤» [20:21] rot1 [20:22] *** marmay joined [20:22] well, aside from the fact that rotN ignores non-alphabetic (and non-ASCII range) [20:23] m: say [~] ‘hello world’.comb>>.succ # rot1 [20:23] rakudo-moar a5fe34: OUTPUT«ifmmp xpsme␤» [20:23] lizmat: I don't think that it works [20:23] m: ‘hello world’.comb>>.succ.join.say # functionally [20:23] rakudo-moar a5fe34: OUTPUT«ifmmp xpsme␤» [20:23] m: say [~] ‘az’.comb».succ [20:23] rakudo-moar a5fe34: OUTPUT«baa␤» [20:24] ah, AlexDaniel: good point [20:24] .oO( bad spectest ) [20:25] m: say [~] ‘az’.ords».succ».chr [20:25] rakudo-moar a5fe34: OUTPUT«b{␤» [20:25] AlexDaniel : ^^^ not really rot1 either [20:25] lizmat: it's unicode-aware rot1 :D [20:25] AlexDaniel : :-) [20:26] though this is a lie and it will actually break [20:26] * lizmat is tired and goes to bed [20:26] *** dmaiocchi left [20:27] Made clojurish thread-first/thread-last operators: https://github.com/MadcapJake/Op-Thread/blob/master/t/010-use.t [20:28] *** musiKk joined [20:28] I can't seem to get the texas-style thread-first operator (->>) to work as intended though [20:30] FROGGS put out a release candidate a few days ago iirc [20:30] maybe we can use that, dha. i haven't looked myself. [20:30] *** domidumont left [20:31] I'll try to take a look. In this context, it's really about ease of use. [20:31] so an RC may or may not be helpful. [20:32] i guess. is installing from source and using panda too hard? [20:32] idk if everyone needs r* [20:33] yes [20:33] I haven't bothered with r* in a while because something always breaks [20:33] I just install what I need [20:34] *** yqt joined [20:35] *** sevvie joined [20:39] jdv79 - I have no problem with it, but Jim wants to make it as easy as possible for those with no p6 experience at all, I think. r* should give them everything they need in one shot. *shrug* [20:39] my problem is that I'm trying to create builds for heroku and solus, and both of these move the directories of the built files after the whole build process is complete, this renders a bunch of paths broken (I'm not the greatest bashfu artist so maybe i'm going about it wrong) [20:39] Hotkeys - yeah, I just get whatever's on github. *shrug* [20:40] I'm *guessing* that Jim wants to minimize time devoted to setup issues so we can concentrate on actually learning the language. [20:40] also, have any of you tried installing rakudo to /usr? [20:42] I just use rakudobrew [20:42] I update like once a week or whenever I can be bothered [20:43] right rakudobrew is nice but I wouldn't want to use it on a server, i would rather have everything installed neatly in /usr dirs [20:43] and distros like Solus, NixOS want everything neatly boxed up too rather than sitting in a hidden home dir folder [20:43] *** cognominal joined [20:44] *** laz78 joined [20:45] MadcapJake: which is precisely what rakudobrew is for [20:45] MadcapJake: .rakudobrew is merely *a* location to put it in [20:45] dha: maybe we should have some shell accts setup before hand. idk. [20:45] MadcapJake: mine isn't [20:46] Yeah, idk either... I'm looking to be helpful if possible, but... not really my show. [20:46] but you can rakudobrew place everything in the /usr dirs? [20:46] at least there'll be ok beer [20:47] Yes. :-) [20:47] MadcapJake: I wouldn't do that [20:47] MadcapJake: I'd create an independent tree of files, so everything is neatly boxed up, ala NiXOS [20:47] MadcapJake: and if I then wanted to, symlink from /usr/bin [20:47] right but they want things to *look* like a set of /usr dirs [20:48] *** ecocode left [20:49] $build_dir/usr/bin, $build_dir/usr/share, etc. unfortunately if this independent tree gets moved, perl6 bin fails [20:49] oh, yes, if you want DESTDIR and PREFIX to be different you have to do it more by hand [20:50] flussence got a gentoo ebuild working you could crib from [20:51] doc: 37e7816 | (Zoffix Znet)++ | doc/Language/unicode_texas.pod: [20:51] doc: Clarify ⁺⁻¯ [20:51] doc: [20:51] doc: The Texas variants are not 'N/A', they simply require explit numbers fors power: as in 2¯ is 2**-1 and 2**- doesn't work. [20:51] doc: review: https://github.com/perl6/doc/commit/37e7816976 [20:52] mst: which flags would i use for building in a $build_dir and then moving to somewhere else? I'm kind of confused on what the different is between DESTDIR/sysroot/prefix or others. [20:52] MadcapJake: don't remember, hence saying 'crib from flussence' [20:53] *** FROGGS[mobile]2 joined [20:53] *** FROGGS[mobile] left [20:53] mst: ok, i'm checking it out now, thanks for the reference! [20:55] *** kaare__ left [20:59] *** marmay left [21:00] *** JustThisGuy_ joined [21:01] *** nowan left [21:01] *** nchambers left [21:01] *** nchambers joined [21:01] *** cdg joined [21:02] *** ely-se joined [21:05] *** kst` is now known as kst [21:11] “If you have a sub you're dying to call as a method on something, just prefix it with an ampersand.” – O-o-oh! That's how you do it! [21:11] having to write $_ is annoying :) [21:12] m: sub foo($x) { say $x }; $_ = 42; .&foo [21:12] rakudo-moar a5fe34: OUTPUT«42␤» [21:12] @arr>>.&foo [21:13] I'm trying to understand how something works with NativeCall. I'm trying to write a module that binds to GDBM files. The GDBM file is here: http://rnc.veritablesoftware.com/foo.gdbm. The script is here: http://pastebin.com/3aCB7pHD. The module is here: http://pastebin.com/H1UavFqQ. The output is here: http://pastebin.com/gvMBUKG5. [21:16] JustThisGuy_, you should try gist.github.com it alow to put multiple file [21:16] What I don't understand is why "my datum $key_datum = datum.new(dptr => $key, dsize => $key.chars);" gives me a datum instance, and "my datum $content_datum = gdbm_fetch($!dbf, $key_datum);" gives me a datum class. Is the ability to have native subs return objects not implemented, or am I just doing it wrong? [21:17] Skarsnik: Thanks for the tip. I don't currently have a github account, sadly. [21:19] I actually started the same thing, I stopped working on it https://github.com/jonathanstowe/p6-GDBM [21:19] what are the c signatures? [21:20] but in your case it's returning a type object because the native sub is returning null [21:22] *** addison_ left [21:24] Sorry, I was putting it together in gist.github.com: https://gist.github.com/JustThisGuyAZ/2a32ba2ff53025710201 [21:24] I want to kill the guy that write minixml... the api is aweful node = mxmlFindElement(tree, tree,NULL,NULL, NULL,MXML_DESCEND) .... [21:24] Just a sec... I'll add the C signatures to the gist. [21:26] Thanks RabidGravy! I'll take a look at what you have when I get a chance. [21:26] *** addison_ joined [21:27] RabidGravy, did callback to native sub work in function arg btw? [21:28] *do [21:29] Skarsnik, yeah seemed to, there's a good example somewhere of someone made an expat binding which is all about the callbacks [21:29] Skarsnik, I added gdbm.h to the gist: https://gist.github.com/JustThisGuyAZ/2a32ba2ff53025710201 [21:30] *** azawawi joined [21:30] hi [21:32] Another question I have from looking at RabidGravy's code is, what's the difference between making the class "is rw" and making the attributes "is rw"? [21:32] *** sno left [21:32] JustThisGuy_, GDBM_FILE is a Pointer not a struct. You probably want to use Pointer for it [21:33] class is rw make all the attribute is rw [21:33] Good catch. Thanks! [21:33] *** hankache joined [21:34] So it's redundant to make the attributes "is rw" if the class "is rw"? Right? [21:34] yes [21:34] K, good to know. [21:35] yeah, I don't know why I made both rw for Datum [21:35] what's the best strategy for POD documentation in your opinion ... inline pod or at the top or end of a file? [21:35] You can never have too much rw! :) [21:35] azawawi, I keep changing my mind [21:35] *** nowan joined [21:36] * azawawi is reading Audio::Sndfile code to learn more :) [21:36] evening #perl6 [21:36] azawawi - My gut reaction is that that would be context-dependent. [21:36] wahah! [21:36] azawawi, get back at Pg Array! [21:36] Skarsnik: no :) [21:36] So, since RabidGravy said that the native sub worked, I'll take a look at that code and see if I can figure out what I'm doing wrong. Thanks all! [21:37] I was hopping someone fix to have Array in the hash returned and not Array of Array x) [21:38] *** JustThisGuy_ left [21:38] RabidGravy: so what did you end up with? :) [21:40] I've just been sticking it all at the top more recently, it's less ugly, however doing inline makes refactoring to another file easier [21:40] also i hear that a lot while reading module reviews... Perl-ish API design. What makes an API Perlish in your opinion? [21:42] I don't really know, but I know it when I see it ;-) [21:42] *** musiKk left [21:42] lol [21:42] and I think Perl 6-ish is probably different to Perl 5-ish given we have multis and stuff [21:43] I propose we instead of saying Perl 6-ish we say 6xy [21:44] what about positional vs named arguments? and using hyphens in method names? [21:44] Oh yeah that x) [21:44] * azawawi starts writing POD documentation for MagickWand [21:44] providing at key/pos on container? [21:45] "that module is Perl 6-ish" becomes "that module is 6xy" [21:46] always use hyphens in method-names [21:47] also using named parameters and sensible default values [21:50] well it's if there are one or two mandatory arguments then positional, if there are twenty optional then named, there's a happy medium between the two [21:51] *** laz78 left [21:52] not always defaults, sometimes a multi which calls the one with the most arguments with the defaults [21:52] *** addison_ left [21:55] RabidGravy: cool thanks for the input [21:55] *** skids left [21:57] *** Relsak left [21:58] . [22:00] *** addison_ joined [22:01] *** laz78 joined [22:01] *** hankache left [22:01] *** sno joined [22:06] *** dmaiocchi joined [22:10] *** dmaiocchi left [22:12] *** donaldh_ joined [22:16] *** donaldh_ left [22:16] *** donaldh35 joined [22:18] *** donaldh left [22:22] *** donaldh35 left [22:22] *** donaldh35 joined [22:22] *** dha left [22:22] *** donaldh35 left [22:23] *** ZoffixWin joined [22:23] *** donaldh joined [22:29] *** donaldh left [22:29] https://github.com/JoelBesada/activate-power-mode # Pure editing fun in atom... Makes me wanna hit space and ENTER harder :) [22:29] :) [22:31] lol [22:31] Goes well with https://www.youtube.com/watch?v=AQ3-R5XB098 [22:31] * ZoffixWin is power hax0r now [22:35] im thinking of re-writing farabi6 as an atom plugin :) [22:35] What's that? [22:35] https://github.com/azawawi/farabi6 [22:37] *** rindolf left [22:38] ZoffixWin: it was something like this https://p6weekly.files.wordpress.com/2014/10/uwgmvwh.png :) [22:39] k [22:42] * azawawi starts writing pod-preview for atom (like https://atom.io/packages/markdown-preview) :) [22:47] *** dolmen left [22:50] *** FROGGS[mobile]2 left [22:53] *** vendethiel left [22:57] *** vendethiel joined [23:01] damn that nice [23:02] Oh damn. I have that installed but didn't even know it existed :) I was using online previewers :) azawawi++ [23:03] *** ZoffixWin left [23:05] *** FROGGS left [23:06] *** cpage_ left [23:07] *** Skarsnik left [23:09] *** kurahaupo left [23:16] *** sno left [23:17] *** [Sno] joined [23:19] *** lokien_ left [23:22] *** laz78 left [23:25] *** tmtowtdi left [23:25] *** skids joined [23:25] *** Herby_ joined [23:25] Afternoon, everyone! [23:25] 31 Jan 2016 10:37Z Herby_: Is this what you want? my $var = 42; given $var { when * < 50 { say "it's less than 50" } } [23:25] o/ [23:28] Knowing this crowd, I'm suspecting we have one or two Vim experts [23:29] How would I delete all lines in a text file that do not start with a number | letter and a . : ex "1." or "a." [23:29] i'd like to delete all lines that do not match that pattern' [23:29] i think you :g/some_regex_you_like/d to make that happen [23:29] *** RabidGravy left [23:29] however, i don't know how to invert the regex non-manually [23:29] oh [23:29] easy [23:30] :g!/pattern/d [23:30] alternatively, you can just :v/pattern/d, which is just short for :g!/pattern/d [23:30] hmmm [23:31] so like :g!/[a-z0-9]./d maybe you have to backslash parts of that [23:31] seriously, when to backslash and when not to backslash stuff in vim regex ... most difficult thing in my whole life [23:31] you're the man :) [23:31] eh. sometimes [23:32] i got tasked with a mind numbing project at work, trying to think how I can work Perl 6 into it [23:32] I have a 500 page PDF that is full of chapters and test questions. I need to pull out all the test questions and answers, and write it to an excel sheet [23:33] it looks like Perl 6 has a PDF module, not so sure on the excel part [23:33] so now i'm just trying to 'copy all' from the pdf, and weed out everything but the test questions and answers using Vim regex [23:33] then figure out the write-to-excel part [23:34] it would probably be shorter to manually copy/paste everything from the pdf into an excel document, but i can't bring myself to do it [23:41] *** vendethiel left [23:42] Herby_: what about trying some random tool to convert PDF to text file? [23:43] Herby_: and then manipulating it to get it completely right [23:43] i was looking at that too. wasn't sure how much more it would give me than ' [23:43] 'copy all + paste' [23:50] *** cpage_ joined [23:50] .tell CIAvash That was it, thanks! [23:50] Herby_: I'll pass your message to CIAvash. [23:50] *** firstdayonthejob left [23:52] *** vendethiel joined [23:58] *** spider-mario left [23:59] at some point i used a pdf-to-text tool to extract a bunch of data out of a pdf