»ö« 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:04 telex left, skrshn joined 00:05 skrshn left 00:06 telex joined 00:08 pnu left 00:09 kanishka left, jnap left, TEttinger left 00:10 kent\n left, pnu joined, jnap joined, kanishka joined 00:12 kent\n joined, TEttinger joined, leont left 00:13 Spot__ left, Spot__ joined, ugexe left 00:15 pnu left, mrsolo left, mrsolo joined 00:16 BuildTheRobots left, caasih left, BuildTheRobots joined, kent\n left, caasih joined 00:17 pnu joined 00:19 kent\n joined 00:23 ugexe joined 00:24 vendethiel left 00:25 vendethiel joined
ugexe install of perl6 module from jdv's metacpan clone: gist.github.com/ugexe/9f382c8595226aa9bae0 00:25
00:39 labster left
ZoffixWin w00t! awesome :D 00:42
00:42 wamba joined 00:45 krakan left, pnu left, vendethiel left 00:46 pnu joined, 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
AlexDaniel “Internal error: zeroed target thread ID in work pass” hmm 01:13
geekosaur we already have a few reports of that? 01:20
AlexDaniel geekosaur: ah, ok then 01:30
I just ran it again and it worked. Weird thing 01:31
01:32 labster left, spider-mario left 01:35 cdg joined, labster joined 01:36 vendethiel left
ugexe i get them randomly too. usually related to run() 01:40
01:42 lichtkind_ left 01:47 ZoffixWin left 01:49 isBEKaml left, pierrot left 01:50 pierrot joined 01:55 vendethiel joined
ely-se .tell masak I started working on the type concatenative thing again, got the arity part of type inference working now: gist.github.com/rightfold/9e9ba03a...js-L38-L53 01:55
yoleaux ely-se: I'll pass your message to masak.
ely-se .botsnack
yoleaux :D
01:59 pierrot_ joined 02:00 pierrot left 02:02 sortiz joined, xpen joined
ely-se .tell masak well, to some extent :p 02:04
yoleaux 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
timotimo here's a fun bug for you: 02:56
m: my Int:D @foo; say @foo[1]
camelia rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block <unit> at /tmp/iofmqLuglf line 1␤␤»
timotimo whoever wants to can file that in RT
02:58 azawawi joined
azawawi good morning #perl6 02:58
pasteboard.co/1dCMZs5g.png # More image effects implemented 02:59
AlexDaniel azawawi: nice. What's the module? 03:09
03:09 cdg left, kid51_ joined
azawawi github.com/azawawi/perl6-magickwan...ffects.pl6 # MagickWand 03:10
03:10 vendethiel left 03:12 kid51 left, kid51_ is now known as kid51
AlexDaniel azawawi++ 03:12
azawawi: thanks
azawawi thx
AlexDaniel azawawi: what is $o in in $o.cleanup example? 03:13
in README.md
was it meant to be $wand ?
azawawi think of it as a handle to an image 03:14
or multiple images
because you could for example add multiple images and then create an animated gif 03:15
or an AVI or MP4 movie via ffmpeg
it is really a powerful api 03:16
03:16 ely-se left
AlexDaniel azawawi: I'm not sure if I'm folliwing it. Should the example actually show something that does not compile? 03:17
or perhaps consider adding a comment like # $o is a handle to some image 03:18
azawawi sure i will update it
github.com/azawawi/perl6-magickwan...-hello.pl6
i will add a user guide after finishing 02-effects.pl6 03:19
github.com/azawawi/perl6-magickwand/issues/1
03:20 raiph joined
AlexDaniel azawawi: why nobody made it earlier? 03:22
:)
azawawi AlexDaniel: i see what you mean... yes $o.cleanup should be $wand.cleanup
AlexDaniel: help is welcome :) 03:24
AlexDaniel: i started this project like 10 days ago
AlexDaniel 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:26
03:27 kid51 left
MadcapJake Anyone interested in joining (i.e., helping grow) the Perl 6 Slack community? Get an invite here: perl6.bestforever.com/ 03:28
azawawi im learning imagemagick as i wrap more OO sugar around it :)
MadcapJake: what's that?
MadcapJake: and hi :)
MadcapJake hi!
It's a new communication tool that some other languages/devs use: slack.com 03:29
llfourn m: say :("foo") ~~ :("bar") 03:30
camelia rakudo-moar a5fe34: OUTPUT«True␤»
llfourn :S
MadcapJake 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
03:31 keusej left
AlexDaniel 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
Hotkeys is there a hash type in which order matters?
MadcapJake 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
plus current evalbot is written in Perl 5 :) 03:33
AlexDaniel MadcapJake: that would mean rewriting camelia, which is probably not cool
azawawi MadcapJake: joined 03:34
03:34 noganex_ joined
MadcapJake azawawi++ 03:34
03:36 danzulla joined
MadcapJake 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:36
03:37 noganex left
danzulla oh perl6 is actually working nowadays? 03:37
sortiz timotimo, The bug reduces to "<Type>:U.gist" or "<Type>:D.gist", will give a try.
MadcapJake o_0
danzulla i used to learn perl5 with chatbots, years ago. i loved it.
MadcapJake it might be slow, but won't know unless i try xD
AlexDaniel danzulla: by “actually working” you mean? 03:38
danzulla i got rakudo and some CPAN stuff that claimed to implement perl6. it never seemed to be "official"
AlexDaniel danzulla: because to me it was “actually working” for a few years now
danzulla but i might have been just a stupid slave to perl online marketing
MadcapJake danzulla: have you used panda yet? 03:39
danzulla nope
what's panda?
MadcapJake oh then you are definitely out of date
panda is the current defacto module installer for rakudo
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
danzulla did you guys write anything meaningful in perl6? i'd love to take a look.
MadcapJake modules.perl6.org/ 03:41
danzulla hah
03:41 Sgeo_ joined
Juerd danzulla: Yes, I write several kinds of one-off scripts in Perl 6 now. Mostly just to figure out how everything works. 03:41
danzulla: Eventually I expect to use Perl 6 in production, and I want to get to know the language well before that :) 03:42
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
danzulla It'd be interesting to see some Perl6 job offerings.
03:43 Sgeo left
Juerd 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
danzulla @Juerd: Is Perl6 JIT or is there an Ahead of Time compiler as in Google Go already?
Or is somebody working on it?
That's what I really like about Go. 03:45
Juerd danzulla: I'm not familiar with the details but I believe Perl 6 has a JIT.
AlexDaniel it has JIT, but a bunch of optimizations are done without JIT :) 03:46
danzulla @Juerd: Seems like you have some experience with Perl6 on VMs. Which is useful.
Juerd danzulla: Not really, I've only used Perl 6 on my own computer so far
AlexDaniel 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
e.g. getting things to work correctly
Juerd Or getting things to work at all :)
Good night everyone :) 03:48
z &
03:56 spags joined 04:00 spags left
sortiz m: Int:D.gist 04:03
camelia rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block <unit> at /tmp/3vJXmqV_i_ line 1␤␤»
04:06 M-eternaleye left, M-eternaleye joined 04:07 cdg joined
llfourn sortiz: mmm probably worth RTing 04:07
04:08 M-eternaleye is now known as eternaleye, Zero_Dogg left
geekosaur I thought that was in response to the earlier RT 04:08
llfourn I havae no idea
sortiz llfourn, I have a proposed patch, PRing :)
04:09 Zero_Dogg joined, Zero_Dogg left, Zero_Dogg joined
llfourn sortiz: nice! 04:09
geekosaur mm, no, that was in here, not an RT
so it probably should be
danzulla, brrt has been working on JIT for moarvm
sortiz llfourn, Now in PR#701 04:12
llfourn sortiz: you might want to write a test or two like is Str:D.gist,'Str:D' in roast 04:13
04:15 yqt left
sortiz llfourn, I'll search for the proper place. 04:15
skids 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
Hotkeys is there a better way to write this i.imgur.com/85ap9tV.png
04:17 psy_ left
Hotkeys er 04:17
pretend that's a hash
typo
llfourn skids: same as usual just push to your roast branch 04:18
your roast fork*
skids Last time I tried that I think it auto-merged the PR when I made it. Maybe I a miremembering. 04:19
llfourn sortiz: I think S04-declrations/smiley.t is a good place
skids m: if 42 -> $a { say $a }
camelia rakudo-moar a5fe34: OUTPUT«42␤»
skids Hotkeys: ^^
llfourn skids: well I have write and I do it all the time :) github.com/perl6/roast/pull/100
skids Maybe I'll try again sometime with something harmless 04:22
04:22 SCHAAP137 left
llfourn after googling it looks like there is no automerging feature maybe someone just had a trigger merge finger 04:24
04:26 raiph left
Hotkeys skids: I decided to do it this way, is this reasonable i.imgur.com/GEk2H4i.png 04:26
skids 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:29
Hotkeys 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
formatted right -> isn't a tree
04:34 labster joined
Hotkeys er 04:34
is a tree
04:46 BenGoldberg left
Hotkeys any idea what might be going on here i.imgur.com/mPWbcd1.png 04:50
I feel like one of the signatures totally matches 04:51
skids The signature :(Hash %h) means a Hash of Hashes. 04:53
04:53 xpen left
Hotkeys oh 04:53
how do I do a hash of anythings
skids Do you really care that it is a Hash, or will any Associative do?
Hotkeys multi yaml2qtree (Hash %h) { ... } is what the declaration looks like 04:54
I assumed it meant it took a hash
skids just :(%h) will take any Associative, which is probably good enough.
Hotkeys ah
geekosaur % already means hash (or at leasr Associative)
Hotkeys okay
great thanks, all is working now 04:56
skids (Note that Array @a is also an Array of Arrays)
Hotkeys Right I did that too 05:00
i.imgur.com/BRQOTE5.png woo
it isn't much 05:01
but it's the first thing I've actually used perl 6 for besides various programming puzzles etc.
skids congrats :-)
05:03 danzulla left 05:04 p_p_r left 05:05 vendethiel joined
llfourn does anyone know what this nqp::scwbenable() means? 05:09
skids I am guessing "serialization context write barrier"
llfourn skids: thanks. What's a write barrier? 05:10
skids It's a mechanism to keep data syncronized between threads.
llfourn ah ok. I guess that's all I need to know :) 05:11
Hotkeys skids: yep you're right 05:12
just did a quick scouring of the repo
first to figure out the wb and then the sc 05:13
05:28 vendethiel left 05:32 CurtisOvidPoe joined 05:34 skids left 05:40 Cabanossi left, pochi_ joined, jameslen_ joined 05:41 sQuEE joined, Gruber joined 05:42 Cabanossi joined, colomon_ joined 05:43 cognominal left 05:44 labster1 joined, cognominal joined, ilmari_ joined, labster1 left 05:45 kst` joined, Quom joined, perigrin_ joined, zostay_ joined, Jonis_ joined, bhm joined, Rotwang_ joined, Ulti_ joined, cosimo joined, hoelzro_ joined, jojotus_ joined, broquain1 joined, nowan_ joined 05:46 cdg left 05:47 xpen joined, edenc_ joined 05:48 gensym_ joined, roguelazer_ joined, musca` joined 05:49 labster left, nowan left, sQuEE` left, jojotus left, jameslenz left, avenj left, roguelazer left, flaviusb left, zostay left, colomon left, gensym left, pochi left, huggable left, Rotwang left, mtj_ left, moznion left, cosimo_ left, Ulti left, bhm_ left, Mouq left, musca left, hoelzro left, edenc left, Grrrr left, skarn left, ilmari left, Jonis left, perigrin left, simcop2387 left, kst left, broquaint left 05:50 roguelazer_ is now known as roguelazer, gensym_ is now known as gensym, colomon_ is now known as colomon 05:51 moznion joined 05:56 simcop2387 joined, mtj_ joined
azawawi pasteboard.co/1dOtczQb.png # like 95% of the effects done in Perl 6 :) 05:58
05:59 flaviusb joined, cibs left 06:09 azawawi left, protium joined 06:12 khw left 06:18 cdg joined 06:19 skarn joined 06:25 cdg left
AlexDaniel m: my @l; if True { my @l.push: 42 } 06:27
camelia ( no output )
AlexDaniel just had this in my code…
now I'm wondering, how does it work? 06:28
m: my @l; if True { my @l.push: 42; say @l }; say @l
camelia rakudo-moar a5fe34: OUTPUT«[42]␤[]␤»
AlexDaniel so I can decleare variables like this??
declare* 06:29
m: my @l.push: 42; say @l
camelia rakudo-moar a5fe34: OUTPUT«[42]␤»
llfourn apparently!
AlexDaniel O_o 06:30
06:30 nakiro joined 06:32 sno left
AlexDaniel what's the practical use for this? 06:32
06:35 sjoshi joined
AlexDaniel “Error in `/home/alex/.rakudobrew/moar-nom/install/bin/moar': double free or corruption (fasttop): 0xec9d8eb0” – woops! 06:38
06:44 _Gustaf_ joined 06:48 _Gustaf__ joined 06:51 _Gustaf_ left 06:53 protium left
sortiz AlexDaniel, A declaration is a term and can be used as such: 06:56
m: say: class A { has $.a; }.new(:a<3>).a
camelia ( no output )
06:57 dolmen joined 07:06 CIAvash joined 07:09 Sgeo_ left, CurtisOvidPoe left, kanishka left 07:11 dolmen left 07:15 cibs joined
[Tux] test 22.663 07:17
test-t 12.419
07:21 milwaukee joined
milwaukee o/ all, I must be doing something seriously wrong cause I've run into something I can't find anything about online. 07:24
~/.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:25
07:36 domidumont joined 07:39 ggoebel15 left 07:40 domidumont left, domidumont joined 07:44 firstdayonthejob joined 07:45 FROGGS joined
FROGGS o/ 07:46
07:48 milwaukee left 07:50 avenj joined
FROGGS donaldh++ # rakudo/pull/697 07:53
07:59 domidumont left, domidumont joined 08:02 abraxxa joined 08:03 ggoebel15 joined 08:07 ecocode joined 08:08 kurahaupo joined
ecocode hi. Which module should I use to read/write to a serial device ? I need to be able to specify parity/baudrate.. 08:10
kurahaupo listens intently, wanting an answer to the same question. posix-something.tcsetattr perhaps? 08:12
08:12 AlexDaniel left
cosimo I should think about porting Device::Modem to perl6 perhaps :) 08:13
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, araujo_ left 08:58 kurahaupo_ joined
ecocode cosimo: that would help me :) 08:59
porting Device::SerialPort would be sufficient though 09:01
masak good antenoon, #perl6 09:02
yoleaux 01:55Z <ely-se> masak: I started working on the type concatenative thing again, got the arity part of type inference working now: gist.github.com/rightfold/9e9ba03a...js-L38-L53
02:04Z <ely-se> masak: well, to some extent :p
09:02 kurahaupo left
masak ely-se: wow, cool 09:02
cosimo ecocode: of course, Device::SerialPort does the real work there. How could I forget? :)
ecocode I've checked Device::SerialPort and there is some XS code envolved :/ 09:03
09:03 jferrero_ left
cosimo ecocode: yeah, not the easiest beast to deal with 09:04
ecocode I wish I had the knowledge to port it
RabidGravy ecocode, gwan do it, saves me from doing it 09:06
ecocode 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
hmmm.. Device::SerialPort isn't listed on github.com/perl6/perl6-most-wanted...modules.md ! 09:08
09:08 kurahaupo_ left
RabidGravy 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:09
09:11 dakkar_ joined
RabidGravy still, not too difficult if one is sufficiently motivated 09:11
ecocode :)
09:14 spebern joined, wamba joined, spebern left 09:15 lizmat left 09:23 espadrine_ joined 09:30 Perleone_ joined 09:35 crux left, crux joined 09:43 pmurias joined 09:44 khagan_ joined 09:48 |Tux| left 09:49 kjs_ joined 09:52 vendethiel joined, pierrot joined 09:53 pierrot_ left 09:54 zakharyas joined, |Tux| joined 09:55 burnersk left 09:56 lnrdo_ joined 09:57 lnrdo_ left 09:58 lnrdo_ joined, burnersk joined 10:00 lnrdo_ left 10:02 yeahnoob left
pmurias hi 10:06
my JavaScript backend for Rakudo grant application is up for community review: [Act: 1] 10:07
news.perlfoundation.org/2016/02/ian...plica.html
10:08 espadrine_ is now known as espadrine
llfourn pmurias: another one? 10:08
arnsholt No, another compiler 10:09
AFAIK pmurias has been working on a JS backend for NQP only so far
FROGGS "Improve the JavaScript backend from handling NQP (Not Quite Perl) to full Perl 6." 10:11
El_Che can someone point to the latest rakudo rc?
llfourn anyway ++ from me, I wasn't sure because I thought I saw one like this a month ago
FROGGS El_Che: rakudo.org/downloads/rakudo/ 10:13
El_Che ah, ok, I was under the impression that there was a RC2 10:17
10:19 zakharyas left 10:21 sortiz left 10:23 pmurias left
FROGGS El_Che: I did a rakudo star RC2 10:25
10:27 pmurias joined
pmurias llfourn: you might have seen a pre-submission draft of the grant proposal ;) 10:28
llfourn pmurias: ah that explains it. Anyway this time I will read it. pmurias++ 10:29
10:34 domidumont left, nebuchadnezzar left, matt_ left, eiro left 10:39 fireartist joined 10:42 domidumont joined, nebuchadnezzar joined, matt_ joined, eiro joined 10:45 rindolf left 10:55 vendethiel left 10:57 vendethiel joined 11:01 leont joined, iH2O joined, lnrdo_ joined
iH2O great room lol 11:02
11:06 lnrdo_ left
iH2O :) 11:08
11:13 nowan_ left 11:14 nowan joined 11:16 rurban joined, rurban left 11:18 bowtie_ left 11:19 lnrdo_ joined, bowtie joined, bowtie is now known as Guest55981 11:23 lokien_ joined 11:26 Skarsnik joined, Skarsnik left 11:29 kaare__ joined 11:32 lnrdo_ left 11:39 donaldh joined 11:40 vendethiel left
RabidGravy What is "No concretization found for Foo" trying to tell me? 11:47
El_Che my $p = run 'false'; say $p.exitcode; $p = run 'false', :out; say $p.exitcode 11:48
damn
m: my $p = run 'false'; say $p.exitcode; $p = run 'false', :out; say $p.exitcode
camelia 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 <unit> at /tmp/OHwB4sTs5s line 1␤␤»
El_Che ok
it output 1 and 0
donaldh pwd
moritz El_Che: at the very least you must close $p.out
donaldh ahem
El_Che moritz: sure, if you like explosions 11:49
11:49 vendethiel joined
El_Che $p = run 'false', :out; $p.out.close -> boom 11:49
The spawned process exited unsuccessfully (exit code: 1)
11:51 iH2O left
El_Che that seems to be by design, but it results in a chicken-and-egg problem: no way to check the exitcode 11:51
11:52 ely-se joined
ely-se hello world 11:52
11:53 xpen left
jnthn ely-se: And if you try $p.out.close, then look at $p.exitcode? 11:54
oops
El_Che: ^^
El_Che jnthn: boom
jnthn The try fails to catch the exception?
El_Che now building rc1, but I don't think it has changed
in summary: an run fail (non zero) will: 11:55
- closing out: boom
- checking exitcode without closing out == 0
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)
jnthn El_Che: You still don't seem to have tried why I suggested. 11:57
*what
El_Che ok, rereading what you wrote
RabidGravy it does fail irrespective of a try 11:58
jnthn OK, that's very odd.
What is $p.out.close doing that's not catchable?!
RabidGravy the Pipe seems otherwise okay 11:59
El_Che because p6 is still lacking modules, shelling out will be pretty common in the beginning. Hence my whining :)
12:00 kid51 joined
nine nine@sunshine:~> perl6 -e 'my $p = run "false", :out; $p.out.close; CATCH { default { say "cought" } }' 12:01
cought 12:02
Looks fine to me?
jnthn nine: Does this work for you: `my $p = run "false", :out; try $p.out.close; say $p.exitcode`
El_Che nine: my point is not that it isn't catchable. But that the exitcode is lost
12:02 Guest55981 left
RabidGravy the Proc status is set by .close from the return from nqp::closefh_i which appears to crap out in some uncatchable way 12:04
leont is confused, why would it need to throw an exception 12:05
jnthn RabidGravy: Yeah, managed to reproduce that here too
Very odd
12:05 bowtie_ joined
RabidGravy and closefh_i is a straight up moar op so I'll stop looking there 12:08
12:09 Skarsnik joined
Skarsnik Hello 12:09
El_Che \o/ (for the reproducible part) 12:10
12:10 vendethiel left 12:17 cognominal left 12:18 cognominal joined, cognominal left
Skarsnik When changing somehting in src/core/ I have to make again? 12:24
FROGGS Skarsnik: just 'make install' 12:25
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:26
Skarsnik I am changing how Usage display stuff for main. Like put the slurpy at the end instead of before the positionnal 12:27
FROGGS yeah, just make install 12:28
Skarsnik because foo --a --b [...slurpy] hello bar
make no sense
12:31 rindolf joined
Skarsnik 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
12:32 perlawhirl joined
moritz either makes sense 12:32
and either is better than random ordering 12:33
Skarsnik I should look at the spec x)
perlawhirl 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
12:35 st_iron joined
perlawhirl thats how i've worked around it. 12:35
st_iron hi
Skarsnik whelp there is nothing x)
gfldex m: say "Hi st_iron!" 12:39
camelia rakudo-moar a5fe34: OUTPUT«Hi st_iron!␤»
Skarsnik ah interesting Pod error? sub MAIN( $hello #= the hello arg the doc get attached to MAIN and not hello 12:40
st_iron m: say "Greetings!"
camelia rakudo-moar a5fe34: OUTPUT«Greetings!␤»
jnthn Skarsnik: What if you put the , after $hello ? 12:41
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:42
Skarsnik sub MAIN( $hello, #= the hello arg do the same 12:43
If I put on the next line it work
it just surprised me x) 12:44
Usage: testmain.p6 [--all] [--define-enum=<Str>] <header-file> [<gccoptions> ...] Ok that definitly better at least 12:45
jnthn 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:48
12:51 kjs_ left
Skarsnik hm, how I can keep a hash (or some an eqv) that keep an ordered based on insertion? 12:52
and my english is aweful today 12:55
12:55 kjs_ joined 12:58 cognominal joined
st_iron maybe a stupid idea, but you can put keys in an array 13:00
that's ordered
Skarsnik Yes, actually I can maybe use a array of Pair
13:02 juu joined
Skarsnik 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
camelia 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, wamba left 13:16 flaviusb joined 13:20 kid51 left 13:21 milwaukee joined
hoelzro_ 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
hoelzro has a look 13:24
Skarsnik odd? 13:25
That how the full usage is generated, by using the WHY x) 13:26
13:26 flaviusb left 13:27 [Coke]_ is now known as [Coke]
[Coke] . 13:27
13:29 dolmen joined, flaviusb joined
hoelzro it'd odd that the doc is attaching to MAIN, I mean 13:30
13:30 lizmat joined
gfldex m: my Int:D @a; say @a[0]; 13:30
camelia rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block <unit> at /tmp/b1rcL3md69 line 1␤␤»
gfldex m: try { my Int:D @a; say @a[0]; CATCH { default { say .^name } } }
camelia rakudo-moar a5fe34: OUTPUT«X::Method::NotFound␤»
gfldex that's LTA 13:31
moritz 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
moritz m: say Int:D 13:37
camelia rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block <unit> at /tmp/yr9QJdyGgl line 1␤␤»
moritz golf'd
Skarsnik m: say Int:D.^shortname 13:38
camelia rakudo-moar a5fe34: OUTPUT«Method 'shortname' not found for invocant of class 'Perl6::Metamodel::DefiniteHOW'␤ in block <unit> at /tmp/mhK2uAmgB4 line 1␤␤»
gfldex that still leaves the question how autovivication works with Arrays that don't like undefined values. 13:39
13:39 vendethiel joined
FROGGS gfldex: there should be an exception talking about a missing initializer I guess 13:40
13:40 lnrdo joined, Actualeyes left
gfldex .tell TimToady please have a look at irclog.perlgeek.de/perl6/2016-02-01#i_11972281 13:41
yoleaux gfldex: I'll pass your message to TimToady.
FROGGS there wont be autoviv, because the constructor of the desired type might require some options
[Coke] just skims scrollback 13:43
hoelzro oh, duh. 13:44
Skarsnik's bug isn't actually a bug at all
#= attaches to the first declaration on the most recent line to contain a declaration 13:45
in sub MAIN($hello,
MAIN is the first decl on the line
gfldex is there a 6.d wishlist? 13:47
moritz you mean, besides ponies?
dalek kudo/2016.01-preparation: 8dff411 | (Andy Weidenbaum)++ | tools/lib/NQP/Configure.pm:
fix parse_revision subroutine regex

  - compare release candidate versions, e.g. 2016.01-RC1
  - use extended p5 regex for readability
  - quiet warnings when regex captures undefined
13:48
kudo/2016.01-preparation: fb743c6 | coke++ | docs/announce/2016.01.md:
Thank author of last minute commit
13:49 nebuchadnezzar left
[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
13:51 kjs_ left
[Coke] (of course, it's only got a relatively tiny community on it.) 13:51
13:53 SCHAAP137 joined 13:54 wamba joined
[Coke] gfldex: no, there is not, but there are already people asking how they can submit their wishlist items. 13:58
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
jnthn We could have an RT meta-ticket for the wishlist
13:59 Actualeyes joined
jnthn (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)
or an R... what jnthn said.
14:00 milwaukee left
jnthn I also found that using a gist as a request for input worked fairly well 14:00
gfldex 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
[Coke] Oh. jnthn, we also need to add a version field to the basic info. 14:01
(on RT)
We can add 6.c/6.d for now? Anyone think we need other values, or that it's not worth adding? 14:03
jnthn [Coke]: What's the purpose of it?
(Just want to make sure we're not confusing compiler/language version.)
[Coke] I guess if everything is in the same binary, not much?
jnthn Aye. Having a way to tag tickets with compiler backend/version otoh may help. 14:04
We already have backend iirc
[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"
jnthn *nod*
[Coke] jnthn: platform, tag, vm
jnthn is busily working on said verioning/release notes, btw :) 14:05
14:05 skids joined 14:06 cdg joined
tadzik ...am I the only one who completely missed the news about possible gravitation waves discovery? 14:08
nine err....no?
tadzik oh, goood :) 14:09
geekosaur ...nope
nine Well ok, I've read about rumors. But those come and go
[Coke] jnthn: we can always use [**] in a subject line. Or just close more tickets, I guess. :) 14:10
14:11 perlpilot joined, molaf joined 14:17 pmurias left 14:22 perlawhirl left 14:25 st_iron left, st_iron joined, st_iron left 14:28 ZoffixW joined
ZoffixW 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;
camelia rakudo-moar a5fe34: OUTPUT«abc␤(abc)␤»
ZoffixW m: 'ABC'.lc.say; 'ABC'.map({slip .lc}).Slip.say;
camelia rakudo-moar a5fe34: OUTPUT«abc␤(abc)␤»
hoelzro m: role R { has $!thing }; class C does R { method foo { $!thing = 17 } }; C.new.foo 14:29
camelia ( no output )
ZoffixW hm, I guess hyper op can do it
m: 'ABC'.lc.say; 'ABC'.map({.lc})».say;
camelia rakudo-moar a5fe34: OUTPUT«abc␤abc␤»
ZoffixW never mind :P
hoelzro ↑ should classes be able to access a private attribute declared by a role they consume?
moritz hoelzro: yes 14:30
hoelzro ah, ok; I just couldn't find that in S12
moritz it was a long matter of dispute
jnthn 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
moritz there was a time when rakudo would disallow it, but declaring the same private attribute again in the class would lead to collision
hoelzro ahhhh
that makes sense
thanks all(<moritz jnthn>)!
14:32 raiph joined 14:35 nebuchadnezzar joined
ZoffixW hm 14:37
m: 'ABC'.&( -> ($self, $who = 'Anonymous') {"Know your $self, $who!"} ).say;
camelia rakudo-moar a5fe34: OUTPUT«Too few positionals passed; expected 1 or 2 arguments but got 0 in sub-signature␤ in block <unit> at /tmp/TyrxGz_0G7 line 1␤␤»
ZoffixW m: 'ABC'.&("Know your $self!").say;
camelia 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;␤»
ZoffixW m: 'ABC'.&("Know your " ~ *).say; 14:38
camelia rakudo-moar a5fe34: OUTPUT«Know your ABC␤»
ZoffixW Is there a way to shove in a signature in such a construct somehow?
gfldex m: 'ABC'.&(-> Str $s {"Know your " ~ $s}).say; 14:39
camelia rakudo-moar a5fe34: OUTPUT«Know your ABC␤»
gfldex ZoffixW: i just pointyed you in the right direction
ZoffixW gfldex, ah, thanks. I had one too many sets of parens. 14:40
m: 'ABC'.&( -> $self, $who = 'Anonymous' {"Know your $self, $who!"} )('Zoffix').say;
camelia rakudo-moar a5fe34: OUTPUT«Know your ABC, Zoffix!␤»
ZoffixW 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
Zero_Dogg 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:00
15:01 xpen left
gfldex Zero_Dogg: NYI 15:01
Skarsnik hoelzro, Oh ok, It's just confusing
hoelzro, maybe it should warn?
jnthn Zero_Dogg: Not built in (at least not for now); probably quite easy to do through a subclass though 15:03
Zero_Dogg 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:05
Juerd 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
gfldex m: my %h where { say .^name; True }; %h<a> = 1;
camelia rakudo-moar a5fe34: OUTPUT«Mu␤Mu␤Int␤Int␤Int␤»
Juerd Wha, that 'where' gets executed 5 times? 15:08
15:08 rindolf left
Skarsnik duh 15:08
gfldex i'm not surprised because i wrote an advent post :)
Zero_Dogg 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
Juerd Zero_Dogg: Making a class is not much work or code in Perl 6 :)
moritz Zero_Dogg: classes aren't very verbose
jnthn Especially when you can has ($.a, $.b, $.c) 15:10
moritz Zero_Dogg: in fact 800 lines is *way* beyond the point where I'd start to use classes
Juerd 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
camelia rakudo-moar a5fe34: OUTPUT«Foo.new(bar => 1, baz => 2, quux => 3, xyzzy => 4)␤»
moritz (to the degree that such things can be measured in lines of code)
Zero_Dogg 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
Juerd Zero_Dogg: In Perl 5 you had to do a lot of things manually, or pull in a module from CPAN.
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 ;)
Zero_Dogg Juerd: woah, not even my own new method, it's like magic ;) 15:12
Juerd That!
Zero_Dogg guess this is as good a time as any to learn more about perl6 classes then, thanks!
FROGGS ... magic and unicorns all the way down!
Zero_Dogg haha
Juerd Zero_Dogg: Okay, see you in 10 minutes then :)
Zero_Dogg Juerd: hehe :p 15:13
arnsholt To a first approximation, Perl 6 OO is similar to Moose OO
Juerd No, really, if you're going to learn only class stuff, not roles, 10 minutes is probably what it takes.
Zero_Dogg nod, I've used Moose a lot, from what little I've looked at perl6 classes, they are quite familiar
Juerd 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
RabidGravy and roles only take a few seconds more ;) 15:14
arnsholt Which isn't surprising, given that a lot of Moose is inspired by Perl 6 (and related MOP-based OO-systems)
Juerd I think I understand roles, but I haven't yet used them.
15:14 nakiro left
Juerd My brain's still too much in isa-land. 15:14
Zero_Dogg 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
Skarsnik Nobody working on a websocket async client? (could be useful if we want a slack module probably)
Juerd I like most things too. And the few things I don't like yet, are being worked on :)
gfldex m: subset StrictKeys of Str where * eq <I dont need no stinking class>; my %h{StrictKeys}; %h<I> = 1; 15:16
camelia rakudo-moar a5fe34: OUTPUT«Type check failed in binding key; expected StrictKeys but got Str␤ in block <unit> at /tmp/YM3P9fxrGW line 1␤␤»
Juerd 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.
RabidGravy I did find a quirk with role composition today
Juerd gfldex: any(<...>)? 15:17
gfldex m: subset StrictKeys of Str where * eq any(<I dont need no stinking class>); my %h{StrictKeys}; %h<I> = 1; %h<stinking> = 2; say 'alive'; %h<false> = 3; 15:18
camelia rakudo-moar a5fe34: OUTPUT«alive␤Type check failed in binding key; expected StrictKeys but got Str␤ in block <unit> at /tmp/_x4QFwHksq line 1␤␤»
gfldex Juerd: indeed
Zero_Dogg: see ^^^
nine 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
camelia 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<EOL>␤ expecting any of:␤ sing…»
nine The class example is actually shorter!
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;
camelia rakudo-moar a5fe34: OUTPUT«alive␤Method 'false' not found for invocant of class 'Foo'␤ in block <unit> at /tmp/xPvdrV7crf line 1␤␤»
nine And gives better error messages ;)
jnthn 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
ZoffixW 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 }; ?
gfldex ZoffixW: no, private attributes are also optimiser food 15:24
jnthn No, it's not sugar at all really
Juerd jnthn: I'm not sure where this would go. I'd like to reconnect things like MQTT::Client or your Stomp::Client... 15:25
ZoffixW m: class Foo { method !foo is rw { state $foo }; method bar { self!foo }; }; my $o = Foo.new; $o.bar = 42; say $o.bar
camelia rakudo-moar a5fe34: OUTPUT«Cannot modify an immutable Any␤ in block <unit> at /tmp/OQhdmnFWLj line 1␤␤»
Juerd jnthn: So the supplies I have in the main program are made in modules
ZoffixW 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
camelia rakudo-moar a5fe34: OUTPUT«42␤72␤»
ZoffixW neat :D
Juerd But knowing that phasers exist in 'whenever' is useful. I might be able to figure something out :)
ZoffixW: You can do this in Perl 5 with lvalue methods, but that induces headaches :) 15:27
jnthn ZoffixW: Yes, but note that state variables are not per instance!
ZoffixW Ahhh 15:28
15:28 AlexDaniel joined
jnthn 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
15:29 risou is now known as risou_awy, risou_awy is now known as risou
jnthn Juerd: We may end up with a pattern where modules provide hooks for async "middleware" though 15:29
To allow a sub that takes a supply and returns another supply to be plugged in at strategic points. 15:30
Juerd 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 :)
Although the protocol has ping, so I could just use that ;) 15:31
Zero_Dogg gfldex: haha, thanks
15:32 adu joined
ugexe 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:33
otherwise, maybe some sort of option for wrappers to override the displayed path? 15:34
15:36 sena_kun joined 15:38 domidumont left
nine 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
sena_kun 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:40
15:41 musiKk joined
ugexe whats the techinical reasons it doesnt work now? i assume absolute paths, but then why use absolute paths? 15:42
Skarsnik The path is compiled within the module?
sena_kun, that a weird usage, checking if not default is not enought? 15:43
jnthn 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
jnthn m: sub foo(|c, $a, $b = 42) { say c.list.elems }; foo(1); foo(1,2) 15:43
camelia 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…»
jnthn ah
m: sub foo($a, |c, $b = 42) { say c.list.elems }; foo(1); foo(1,2) 15:44
MadcapJake sena_kun: no explicit feature, i believe. however you could make it a named param, then do «$param.defined ?? $param !! "<default-value>"»
camelia 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 …»
jnthn Oh, unpack...
15:44 domidumont joined
jnthn m: sub foo(|c ($a, $b = 42)) { say c.list.elems }; foo(1); foo(1,2) 15:44
camelia rakudo-moar a5fe34: OUTPUT«1␤2␤»
jnthn That'll do it
But yeah, it's generally a "design smell" to want to do it.
sena_kun MadcapJake, it's a bit sad. Anyway, it's really rare feature to use, so it's not a problem, I suppose. 15:45
nine ugexe: yes, the precomped file contains the full path to the source file (available as $?FILE). Usually, you will want the full path there.
MadcapJake 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
sena_kun 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
AlexDaniel ZoffixW: huggable is dead! 15:47
RabidGravy 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)
camelia rakudo-moar a5fe34: OUTPUT«got default␤not default␤»
jnthn Cute!
Skarsnik x) 15:49
AlexDaniel El_Che: I'm reading through the backlog, it seems like you've stumbled upon this: rt.perl.org/Public/Bug/Display.html?id=125757
sena_kun RabidGravy, seems legal and readable.
ZoffixW 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
ZoffixW huggable, Bag 15:51
huggable ZoffixW, class Bag [Immutable collection of distinct objects with integer weights]: doc.perl6.org/type/Bag
15:52 FROGGS left
MadcapJake RabidGravy: that's neat! 15:56
RabidGravy or crack-addled
15:58 adu left
gregf_ m: role Foo { }; class Bar { method baz($a,$b = ( 1 but Foo)){ print $b; } }; Bar.new.baz(1) 15:59
camelia rakudo-moar a5fe34: OUTPUT«1»
ZoffixW New blog post exploring some of shortcuts in Perl 6: blogs.perl.org/users/zoffix_znet/20...art-1.html
16:00 ecocode left
geekosaur ZoffixW, sounds like it got netsplit and never recovered 16:00
[01 05:49] * huggable has quit (*.net *.split)
(timestamp is utc)
ZoffixW geekosaur, ah, *phew*. Then that should be easy to fix
ZoffixW is hoping threads like these to have Perl 6 in them by 2018: 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
ZoffixW 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 www.bbc.com/news/health-35459054 16:12
16:12 kurahaupo joined 16:14 khw joined 16:18 ZoffixW left
nemo Zero_Dogg: well. it is a rather short thread 16:24
hoelzro Skarsnik: it's definitely weird; I wouldn't be against a warning
16:26 BenGoldberg joined 16:29 pi4 left, pi4 joined
MadcapJake added an svg badge generator: perl6.bestforever.com/badge.svg 16:31
AlexDaniel MadcapJake: what does it mean? 16:35
16:35 Zero_Dogg left 16:36 Zero_Dogg joined
Skarsnik MadcapJake, you managed to host image with baillador? x) 16:36
AlexDaniel Skarsnik: that's svg 16:37
Skarsnik: which is still text :)
Skarsnik Oh yeah, that cheating
tadzik hahah
cheating is technique!
Skarsnik I should patch my Gumbo module to offer svg parsing x) 16:38
not sure how useful it can be
16:39 FROGGS joined
AlexDaniel Skarsnik: thank you again for Gumbo :) 16:40
Skarsnik 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
16:41 ZoffixW joined
ZoffixW MadcapJake, Why? Are you having issues with that? "Skarsnik MadcapJake, you managed to host image with baillador? x)" 16:41
AlexDaniel ZoffixW: yeah, last time we couldn't figure out how to do that 16:42
Skarsnik Me? No, but I think MadcapJake did not find how to provide binary content
ZoffixW You just send appropriate content type and write the image. Here's my use of MIME::Type for CSS/JS files: github.com/zoffixznet/p6high.xtati...te.pl6#L50 O 16:43
s/O$/I'm sure it works for images and any other files too/;
16:43 pecastro left
AlexDaniel ZoffixW: CSS/JS files are not binary 16:43
ZoffixW Lemme try with images :) 1 sec
AlexDaniel yeah, try it
16:44 perl6newbee joined 16:45 vendethiel joined
ZoffixW (still installing Bailador... more secs) :) 16:46
16:46 rarara left
AlexDaniel By the way, generating svgs with perl6 is fun: files.progarm.org/both.svg (hover over pins to highlight the net) 16:48
Skarsnik it's confusing, what is that? 16:50
FROGGS looks like a mainboard without pci slots
though these five-pin-ground-thingies are weird 16:51
ohh, is this a raspi?
hmmm, no, it has a volume switch 16:52
AlexDaniel 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
FROGGS it might be a phone
MadcapJake AlexDaniel: it's a generated badge showing the current total users on Perl 6 slack and the number active currently
FROGGS hehe 16:53
MadcapJake Skarsnik: yep I did! Bailador works great! As long as I don't have to serve anything that isn't text xD
AlexDaniel 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
ZoffixW Ahhh "Type check failed in assignment to $output; expected Str but got Buf" 16:54
MadcapJake 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
AlexDaniel oh, and it's both sides of the board at the same time. E.g. here's just the top side: files.progarm.org/top.svg 16:55
MadcapJake 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
AlexDaniel FROGGS++ for figuring it out immediately :) 16:55
16:56 dmaiocchi joined
FROGGS :o) 16:56
MadcapJake m: 'a+b'.trans( '+' => '%2b' ).say # why does this just replace with the first char? 16:58
camelia rakudo-moar a5fe34: OUTPUT«a%b␤»
16:58 dolmen left
AlexDaniel 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
RabidGravy MadcapJake, because that's what trans does
FROGGS ahh, interesting
AlexDaniel too bad it was just a one-time throwaway script
RabidGravy if you want what you want it's subst
MadcapJake RabidGravy: the example in the docs says otherwise 17:00
AlexDaniel I didn't even feel like posting it on github because I don't think that someone will ever face exactly the same problem…
MadcapJake doc.perl6.org/routine/trans#class_Str
it shows someone replacing `<` with `&lt;`
m: 'say $x<b> && $y<a>'.trans( '<' => '&lt;', '>' => '&gt;' ).say 17:01
camelia rakudo-moar a5fe34: OUTPUT«say $x&b& && $y&a&␤»
ZoffixW AlexDaniel, MadcapJake xtatik.org:3000/public/pics/camelia.png 17:02
:)
MadcapJake ZoffixW: O_O how?!
RabidGravy: either the docs are completely off on how trans should work or there is a bug 17:03
ZoffixW lol.. I had to modify PSGI
MadcapJake, remove "Str" from this line: github.com/supernovus/perl6-psgi/b...GI.pm6#L18
RabidGravy Nope it's the docs
MadcapJake haha nice! You should submit a PR for that! 17:04
ZoffixW Then it doesn't choke when you give it a buf. And you just slurp it up and send with :bin as in here: github.com/zoffixznet/p6high.xtati...te.pl6#L57
ZoffixW submits an Issue
MadcapJake ZoffixW: the comment above the multi specifically says it can be an array,str, or buf
ZoffixW heh
AlexDaniel ZoffixW: ISSUE? Submit a pull request!! 17:05
MadcapJake RabidGravy: this was added only 25 days ago, are you positive?
gfldex: are you around? 17:06
gfldex partly
MadcapJake the trans docs you merged, show a use of trans replacing one char `<` with `&lt;`, is that actually accurate?
ZoffixW 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: github.com/supernovus/perl6-psgi/issues/6
But it's by supernovus :/ They don't check github much, I noticed. 17:07
gfldex MadcapJake: i have to check
RabidGravy 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*
ZoffixW The name suggests it'd work like Perl 5's tr///, which does operate on single chars.
MadcapJake RabidGravy: design.perl6.org/S05.html#Transliteration shows it being used as shown in the docs, so i think it's a goof
gfldex m: my $str = 'say $x<b> && $y<a>'; $str.=trans( '<' => '&lt;' ); dd $str
camelia rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\&b> \&\& \$y\&a>"␤»
gfldex MadcapJake: seams not to work that well 17:09
ZoffixW m: 'say $x<b> && $y<a>'.trans( '<>' => '[]' ).say
camelia rakudo-moar a5fe34: OUTPUT«say $x[b] && $y[a]␤»
17:09 raiph left
RabidGravy but why wouldn't you use subst for that 17:09
ZoffixW Because you can do multiple chars :)
m: 'zoomba'.trans( 'a..b' => 'A..B' ).say 17:10
camelia rakudo-moar a5fe34: OUTPUT«zoomBA␤»
gfldex m: my $str = 'say $x<b> && $y<a>'; $str.=trans( [ '<' , '>' , '&' ] => [ '&lt;', '&gt;', '&amp;' ]); dd $str
camelia rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\&lt;b\&gt; \&amp;\&amp; \$y\&lt;a\&gt;"␤»
RabidGravy yeah I know how it works
ZoffixW 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.
leont Did IO.e start caching recently?
MadcapJake RabidGravy: that would require multiple subst calls otherwise
ZoffixW m: 'zoomba'.trans( 'a..z' => 'A..Z' ).say 17:11
camelia rakudo-moar a5fe34: OUTPUT«ZOOMBA␤»
ZoffixW -_-
gfldex m: my $str = 'say $x<b> && $y<a>'; $str.=trans( ['a'..'y'] => ['A'..'z'] ); dd $str
camelia rakudo-moar a5fe34: OUTPUT«Str $str = "SAY \$X<B> \&\& \$Y<A>"␤»
17:12 ZoffixW left
gfldex m: my $str = 'say $x<b> && $y<a>'; $str.=trans( '<' => '&lt;', '>' => '&gt;' ); dd $str 17:12
camelia rakudo-moar a5fe34: OUTPUT«Str $str = "say \$x\&b\& \&\& \$y\&a\&"␤»
RabidGravy yeah, if the from is a string of 1 char then it gets changed to 1 char
flussence leont: recently on what timescale? I remember someone complaining and something changing around christmas-time...
RabidGravy other uses are possible
gfldex not overly consitent 17:13
leont I was more thinking about January
I forgot on which version my code worked, but on a more recent rakudo it doesn't anymore
gfldex anyway, the docs must describe behaviour that actually works
leont Not saying this is a bad change, just surprised 17:14
RabidGravy to be honest i thought it had always done it 17:15
flussence 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
dalek c: 444f8c0 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Str.pod:
fix trans for Pairs and list of Pairs
17:20
leont That would make more sense, yes
MadcapJake so trans isn't supposed to work that way? I thought the design docs showed it like that too. 17:23
gfldex 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:24
17:25 psy_ joined 17:27 vendethiel left 17:28 ZoffixW joined
CIAvash 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
ZoffixW m: for ^3 { when 0 { say "Almost there!" }; when 1 { say "There!!!" }; .say } 17:34
camelia rakudo-moar a5fe34: OUTPUT«Almost there!␤There!!!␤2␤»
ZoffixW m: for ^3 { say "Almost there!" when 0; say "There!!!" when 1; .say }
camelia rakudo-moar a5fe34: OUTPUT«Almost there!␤0␤There!!!␤1␤2␤»
ZoffixW Is this difference supposed to be there? ^ Postfix form doesn't short-curcuit the block 17:35
"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
awwaiid hah
17:38 Actualeyes left 17:39 vendethiel joined, 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, dakkar_ left 17:59 Relsak joined 18:00 vendethiel left 18:01 sena_kun left 18:02 firstdayonthejob joined 18:08 wamba left, vendethiel joined 18:10 eiro left 18:11 khw joined 18:16 eiro joined 18:22 espadrine left, addison_ joined
MadcapJake 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, LLamaRider left
perlpilot MadcapJake: if you capture them, sure. 18:34
MadcapJake nothing like JS's arguments object? 18:37
nine MadcapJake: what exactly are you trying to do? 18:39
18:40 vendethiel joined
Hotkeys m: sub foo ($x, $y, $z) { say @_; }; say foo(1,2,4) 18:41
camelia 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␤»
Hotkeys Darn
Thought I'd give it a shot
MadcapJake 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:42
perlpilot m: sub foo( |c ( $this, @that) ) { say "this($this), that({@that}), all({c})" }; foo "this", <other stuff>; 18:43
camelia rakudo-moar a5fe34: OUTPUT«this(this), that(other stuff), all(this other stuff)␤»
MadcapJake cool! thanks! 18:44
gfldex you could also wrap the sub in question 18:45
18:46 spider-mario joined
perlpilot 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:46
18:47 musiKk joined
gfldex that may make the optimiser unhappy 18:47
18:50 psy_ joined 18:54 cpage_ left 18:55 cpage_ joined, araujo joined 18:56 araujo left, araujo joined, araujo left, araujo joined
retupmoca .botsnack 18:57
yoleaux :D
18:59 circ-user-zCdXs joined, circ-user-zCdXs left, circ-user-bFgx6 joined
[Coke] m: ("z".ord+1).chr.say 19:00
camelia rakudo-moar a5fe34: OUTPUT«{␤»
19:00 musiKk left 19:01 cpage_ left
leont I get a "Could not find Shell::Command" from travis, even though I declare a test-demands on it :-s 19:01
depends
geekosaur maybe thecapture can be gotten from caller/callframe? (granting that some of that is NYI) 19:02
19:02 ecocode joined 19:03 ecocode left
[Coke] is our travis stuff smart enough for test-depends? 19:03
19:04 eiro left 19:05 ecocode joined
ecocode hi.. Where can I find docs about 'repr' ? 19:06
and more generally: is there something like perl6doc ? 19:07
perlpilot ecocode: I'm not sure that we have "docs" per se for repr
ecocode: there's p6doc
[Coke] ecocode: something like it, yes, but it's not as functional yet as what you expect from p5 19:08
docs.perl6.org
MadcapJake 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)
[Coke] ecocode: docs.perl6.org/language/nativecall
MadcapJake I thought having a base pm file with a bunch of 'use' statements would work, but it doesn't seem to 19:09
19:09 domidumont joined
[Coke] MadcapJake: the p6 style is more to have one thing per file at the moment. 19:10
ecocode OK. thanks for the info (and especially p6doc :) )
19:10 eiro joined
ugexe MadcapJake: see TAP::Harness 19:10
ecocode has someone made an epub or pdf from the docs on docs.perl6.org ?
MadcapJake [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:12
19:14 FROGGS[mobile] joined 19:17 circ-user-bFgx6 left, domidumont left, domidumont joined, cdg left 19:18 ecocode left 19:19 musiKk joined 19:21 rindolf joined, domidumont left, eiro left, matt_ left 19:22 perl6newbee left
[Coke] MadcapJake: that seems... reasonable. 19:23
perlpilot 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.
[Coke] no works?
ah, perlpilot++ 19:24
19:25 musiKk left 19:29 cognominal left 19:32 domidumont joined, eiro joined, matt_ joined 19:33 tmtowtdi joined 19:34 frobisher joined, dha left, frobisher is now known as dha
MadcapJake perlpilot: how would i re-export them? 19:35
I tried doing «require Sub::Module ('exported-sub', 'another-exported-sub')» but it said Sub::Module didn't export anyting. o_O 19:38
perlpilot 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, edenc left, edenc joined
perlpilot MadcapJake: for now, you can provide an EXPORT sub that returns what you want exported. 19:39
MadcapJake: See the top of github.com/perlpilot/p6-Test-Class.../Class.pm6 for an example. 19:40
MadcapJake cool thanks! I don't know if my perl6 wizardy level is high enough to implement the NYI :EXPORT adverb :( 19:41
wizardry*
perlpilot MadcapJake: This is how you learn :) 19:44
flussence 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:45
perlpilot flussence: maybe it's sent to FD #3 :) 19:46
19:47 cpage_ joined
perlpilot um ... looking at the code, it seems to be sent to stderr normally though 19:47
19:48 dmaiocchi joined
perlpilot work & 19:48
flussence 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:49
and that's a «note» line, so should be stderr... 19:51
19:56 wamba joined
geekosaur gets lost looking for stderr redirections 19:58
(the easiest way to accomplish that is the equivalent of freopen("/dev/tty", "w+", stderr))
also when I went looking for stagestats I landed in nqp code, no "note" commands visible... 20:01
nine "note" is a Perl 6 sub. In NQP it's nqp::say(nqp::getstderr(), ...) 20:02
nqp::saysf(nqp::getstderr(), ...)
Darn... it's nqp::sayfh(nqp::getstderr(), ...) 20:03
geekosaur yep
that was my point
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
geekosaur suddenly wonders if this might be libuv being "helpful" 20:07
flussence hm, that was my gut feeling too 20:08
dmaiocchi hi all, i want to make a rpm package for perl6 20:11
:)
flussence you might want to wait for 2016.01 then, last months was broken for almost everyone that tried to package it
should be arriving this week, if we're lucky 20:12
dmaiocchi ok, thx 20:13
was some nice conference @fossdem, so they motivated to help also perl6 20:14
:)
20:14 dolmen joined
dha flussence - what are the chances of us being lucky? :-) 20:15
20:16 darutoko left
flussence no idea, I'll admit I haven't been paying much attention this month, kinda worn out with it all... 20:16
dha 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
AlexDaniel m: say [~] ‘hello world’.ords».succ».chr 20:21
camelia rakudo-moar a5fe34: OUTPUT«ifmmp!xpsme␤»
moritz rot1
20:22 marmay joined
geekosaur well, aside from the fact that rotN ignores non-alphabetic (and non-ASCII range) 20:22
lizmat m: say [~] ‘hello world’.comb>>.succ # rot1 20:23
camelia rakudo-moar a5fe34: OUTPUT«ifmmp xpsme␤»
AlexDaniel lizmat: I don't think that it works
lizmat m: ‘hello world’.comb>>.succ.join.say # functionally
camelia rakudo-moar a5fe34: OUTPUT«ifmmp xpsme␤»
AlexDaniel m: say [~] ‘az’.comb».succ
camelia rakudo-moar a5fe34: OUTPUT«baa␤»
lizmat ah, AlexDaniel: good point 20:24
.oO( bad spectest )
m: say [~] ‘az’.ords».succ».chr 20:25
camelia rakudo-moar a5fe34: OUTPUT«b{␤»
lizmat AlexDaniel : ^^^ not really rot1 either
AlexDaniel lizmat: it's unicode-aware rot1 :D
lizmat AlexDaniel : :-)
AlexDaniel though this is a lie and it will actually break 20:26
lizmat is tired and goes to bed
20:26 dmaiocchi left
MadcapJake Made clojurish thread-first/thread-last operators: github.com/MadcapJake/Op-Thread/bl.../010-use.t 20:27
20:28 musiKk joined
MadcapJake I can't seem to get the texas-style thread-first operator (->>) to work as intended though 20:28
jdv79 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
dha 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.
jdv79 i guess. is installing from source and using panda too hard? 20:32
idk if everyone needs r*
MadcapJake yes 20:33
Hotkeys I haven't bothered with r* in a while because something always breaks
I just install what I need
20:34 yqt joined 20:35 sevvie joined
dha 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
MadcapJake 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)
dha Hotkeys - yeah, I just get whatever's on github. *shrug*
I'm *guessing* that Jim wants to minimize time devoted to setup issues so we can concentrate on actually learning the language. 20:40
MadcapJake also, have any of you tried installing rakudo to /usr?
Hotkeys I just use rakudobrew 20:42
I update like once a week or whenever I can be bothered
MadcapJake 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
mst MadcapJake: which is precisely what rakudobrew is for 20:45
MadcapJake: .rakudobrew is merely *a* location to put it in
jdv79 dha: maybe we should have some shell accts setup before hand. idk.
mst MadcapJake: mine isn't
dha Yeah, idk either... I'm looking to be helpful if possible, but... not really my show. 20:46
MadcapJake but you can rakudobrew place everything in the /usr dirs?
jdv79 at least there'll be ok beer
dha Yes. :-) 20:47
mst MadcapJake: I wouldn't do that
MadcapJake: I'd create an independent tree of files, so everything is neatly boxed up, ala NiXOS
MadcapJake: and if I then wanted to, symlink from /usr/bin
MadcapJake right but they want things to *look* like a set of /usr dirs
20:48 ecocode left
MadcapJake $build_dir/usr/bin, $build_dir/usr/share, etc. unfortunately if this independent tree gets moved, perl6 bin fails 20:49
mst oh, yes, if you want DESTDIR and PREFIX to be different you have to do it more by hand
flussence got a gentoo ebuild working you could crib from 20:50
dalek c: 37e7816 | (Zoffix Znet)++ | doc/Language/unicode_texas.pod:
Clarify ⁺⁻¯

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
MadcapJake 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
mst MadcapJake: don't remember, hence saying 'crib from flussence'
20:53 FROGGS[mobile]2 joined, FROGGS[mobile] left
MadcapJake mst: ok, i'm checking it out now, thanks for the reference! 20:53
20:55 kaare__ left 20:59 marmay left 21:00 JustThisGuy_ joined 21:01 nowan left, nchambers left, nchambers joined, cdg joined 21:02 ely-se joined 21:05 kst` is now known as kst
AlexDaniel “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 :)
m: sub foo($x) { say $x }; $_ = 42; .&foo 21:12
camelia rakudo-moar a5fe34: OUTPUT«42␤»
ugexe @arr>>.&foo
JustThisGuy_ 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: rnc.veritablesoftware.com/foo.gdbm. The script is here: pastebin.com/3aCB7pHD. The module is here: pastebin.com/H1UavFqQ. The output is here: pastebin.com/gvMBUKG5. 21:13
Skarsnik JustThisGuy_, you should try gist.github.com it alow to put multiple file 21:16
JustThisGuy_ 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?
Skarsnik: Thanks for the tip. I don't currently have a github account, sadly. 21:17
RabidGravy I actually started the same thing, I stopped working on it github.com/jonathanstowe/p6-GDBM 21:19
Skarsnik what are the c signatures?
RabidGravy but in your case it's returning a type object because the native sub is returning null 21:20
21:22 addison_ left
JustThisGuy_ Sorry, I was putting it together in gist.github.com: gist.github.com/JustThisGuyAZ/2a32...3025710201 21:24
Skarsnik I want to kill the guy that write minixml... the api is aweful node = mxmlFindElement(tree, tree,NULL,NULL, NULL,MXML_DESCEND) ....
JustThisGuy_ Just a sec... I'll add the C signatures to the gist.
Thanks RabidGravy! I'll take a look at what you have when I get a chance. 21:26
21:26 addison_ joined
Skarsnik RabidGravy, did callback to native sub work in function arg btw? 21:27
*do 21:28
RabidGravy Skarsnik, yeah seemed to, there's a good example somewhere of someone made an expat binding which is all about the callbacks 21:29
JustThisGuy_ Skarsnik, I added gdbm.h to the gist: gist.github.com/JustThisGuyAZ/2a32...3025710201
21:30 azawawi joined
azawawi hi 21:30
JustThisGuy_ 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
21:32 sno left
Skarsnik JustThisGuy_, GDBM_FILE is a Pointer not a struct. You probably want to use Pointer for it 21:32
class is rw make all the attribute is rw 21:33
JustThisGuy_ Good catch. Thanks!
21:33 hankache joined
JustThisGuy_ So it's redundant to make the attributes "is rw" if the class "is rw"? Right? 21:34
Skarsnik yes
JustThisGuy_ K, good to know.
RabidGravy yeah, I don't know why I made both rw for Datum 21:35
azawawi what's the best strategy for POD documentation in your opinion ... inline pod or at the top or end of a file?
JustThisGuy_ You can never have too much rw! :)
RabidGravy azawawi, I keep changing my mind
21:35 nowan joined
azawawi is reading Audio::Sndfile code to learn more :) 21:36
hankache evening #perl6
dha azawawi - My gut reaction is that that would be context-dependent.
RabidGravy wahah!
Skarsnik azawawi, get back at Pg Array!
azawawi Skarsnik: no :)
JustThisGuy_ 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!
Skarsnik I was hopping someone fix to have Array in the hash returned and not Array of Array x) 21:37
21:38 JustThisGuy_ left
azawawi RabidGravy: so what did you end up with? :) 21:38
RabidGravy 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
azawawi also i hear that a lot while reading module reviews... Perl-ish API design. What makes an API Perlish in your opinion?
RabidGravy I don't really know, but I know it when I see it ;-) 21:42
21:42 musiKk left
Skarsnik lol 21:42
RabidGravy and I think Perl 6-ish is probably different to Perl 5-ish given we have multis and stuff
hankache I propose we instead of saying Perl 6-ish we say 6xy 21:43
azawawi what about positional vs named arguments? and using hyphens in method names? 21:44
Skarsnik Oh yeah that x)
azawawi starts writing POD documentation for MagickWand
Skarsnik providing at key/pos on container?
hankache "that module is Perl 6-ish" becomes "that module is 6xy" 21:45
RabidGravy always use hyphens in method-names 21:46
azawawi also using named parameters and sensible default values 21:47
RabidGravy 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:50
21:51 laz78 left
RabidGravy not always defaults, sometimes a multi which calls the one with the most arguments with the defaults 21:52
21:52 addison_ left
azawawi RabidGravy: cool thanks for the input 21:55
21:55 skids left 21:57 Relsak left
tony-o_ . 21:58
22:00 addison_ joined 22:01 laz78 joined, hankache left, sno joined 22:06 dmaiocchi joined 22:10 dmaiocchi left 22:12 donaldh_ joined 22:16 donaldh_ left, donaldh35 joined 22:18 donaldh left 22:22 donaldh35 left, donaldh35 joined, dha left, donaldh35 left 22:23 ZoffixWin joined, donaldh joined 22:29 donaldh left
azawawi github.com/JoelBesada/activate-power-mode # Pure editing fun in atom... Makes me wanna hit space and ENTER harder :) 22:29
ZoffixWin :)
Hotkeys lol 22:31
ZoffixWin Goes well with www.youtube.com/watch?v=AQ3-R5XB098
ZoffixWin is power hax0r now
azawawi im thinking of re-writing farabi6 as an atom plugin :) 22:35
ZoffixWin What's that?
azawawi github.com/azawawi/farabi6
22:37 rindolf left
azawawi ZoffixWin: it was something like this p6weekly.files.wordpress.com/2014/...wgmvwh.png :) 22:38
ZoffixWin k 22:39
azawawi starts writing pod-preview for atom (like atom.io/packages/markdown-preview) :) 22:42
22:47 dolmen left 22:50 FROGGS[mobile]2 left 22:53 vendethiel left 22:57 vendethiel joined
Skarsnik damn that nice 23:01
ZoffixWin Oh damn. I have that installed but didn't even know it existed :) I was using online previewers :) azawawi++ 23:02
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, skids joined, Herby_ joined
Herby_ Afternoon, everyone! 23:25
yoleaux 31 Jan 2016 10:37Z <CIAvash> Herby_: Is this what you want? my $var = 42; given $var { when * < 50 { say "it's less than 50" } }
Herby_ o/
Knowing this crowd, I'm suspecting we have one or two Vim experts 23:28
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'
timotimo i think you :g/some_regex_you_like/d to make that happen
23:29 RabidGravy left
timotimo however, i don't know how to invert the regex non-manually 23:29
oh
easy
:g!/pattern/d 23:30
alternatively, you can just :v/pattern/d, which is just short for :g!/pattern/d
Herby_ hmmm
timotimo 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
Herby_ you're the man :)
timotimo eh. sometimes
Herby_ 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
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
then figure out the write-to-excel part
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:34
23:41 vendethiel left
AlexDaniel Herby_: what about trying some random tool to convert PDF to text file? 23:42
Herby_: and then manipulating it to get it completely right 23:43
Herby_ i was looking at that too. wasn't sure how much more it would give me than '
'copy all + paste'
23:50 cpage_ joined
Herby_ .tell CIAvash That was it, thanks! 23:50
yoleaux Herby_: I'll pass your message to CIAvash.
23:50 firstdayonthejob left 23:52 vendethiel joined 23:58 spider-mario left
timotimo at some point i used a pdf-to-text tool to extract a bunch of data out of a pdf 23:59