Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2013-09-20

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:07 Util r: sub g (*@n) { my @z = grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
00:07 camelia rakudo f86a1a: OUTPUT«"997"␤»
00:07 Util r: sub g (*@n) {         grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
00:07 camelia rakudo f86a1a: OUTPUT«Nil␤»
00:08 Util Why is the assignment to @z needed?
00:09 diakopter Util: over-eager optimization? :)
00:10 Util diakopter: Hmmm. Perhaps. Looking at the code, do you think that the assignment *should* be able to be left out?
00:11 diakopter r: sub g (*@n) { [grep *.Int.is-prime, ((9,7,3,1) X~ @n)] }; say 7.&g.&g.[0].perl;
00:11 camelia rakudo f86a1a: OUTPUT«Cannot convert string to number: trailing characters after number in '997⏏ 37 17' (indicated by ⏏)␤  in method Int at src/gen/CORE.setting:12017␤  in method Int at src/gen/CORE.setting:5627␤  in sub g at /tmp/FKN26RfGSC:1␤  in block  at /tmp/FKN26RfGSC:1␤␤…»
00:11 diakopter I can't win
00:12 Psyche^_ joined #perl6
00:12 fridim__ joined #perl6
00:14 Util diakopter: Thanks for trying. It is of little consequence at the moment; I have the workaround :)
00:18 diakopter r: sub g (*@n) { my @a = grep({ say $^a; $^a.Int.is-prime}, ((9,7,3,1) X~ @n)) }; say 7.&g.&g.[0].perl;
00:18 camelia rakudo f86a1a: OUTPUT«97␤77␤37␤17␤997␤937␤917␤797␤737␤717␤397␤337␤317␤197␤137␤117␤"997"␤»
00:18 diakopter r: sub g (*@n) { grep({ say $^a; $^a.Int.is-prime}, ((9,7,3,1) X~ @n)) }; say 7.&g.&g.[0].perl;
00:18 camelia rakudo f86a1a: OUTPUT«97␤77␤37␤17␤Nil␤»
00:19 diakopter n: sub g (*@n) { my @a = grep({ say $^a; $^a.Int.is-prime}, ((9,7,3,1) X~ @n)) }; say 7.&g.&g.[0].perl;
00:19 camelia niecza v24-95-ga6d4c5f: OUTPUT«Potential difficulties:â�¤  @a is declared but not used at /tmp/gCMbFieXFt line 1:â�¤------> [32msub g (*@n) { my [33mâ��[31m@a = grep({ say $^a; $^a.Int.is-prime}, [0mâ�¤â�¤97â�¤77â�¤37â�¤17â�¤997â�¤937â�¤917â�¤797â�¤737â�¤717â�¤397â�¤337â�¤317â�¤197â�¤137â�¤117â�¤"997"â�¤â€¦Â»
00:19 diakopter n: sub g (*@n) { grep({ say $^a; $^a.Int.is-prime}, ((9,7,3,1) X~ @n)) }; say 7.&g.&g.[0].perl;
00:19 camelia niecza v24-95-ga6d4c5f: OUTPUT«97␤77␤37␤17␤997␤937␤917␤797␤737␤717␤397␤337␤317␤197␤137␤117␤"997"␤»
00:19 diakopter rakudobug of some sort
00:19 diakopter I'd wager
00:28 Mouq joined #perl6
00:35 timotimo what's the magic document i have to put in to turn "timotimo" in the release announcement into "Timo Paulssen"? ;)
00:36 Mouq \.tell masak? :)
00:38 wsri joined #perl6
00:49 BenGoldberg joined #perl6
00:51 krokite joined #perl6
00:55 jnap joined #perl6
01:06 timotimo anyway, congrats on the succesful release
01:19 _sri joined #perl6
01:32 BenGoldberg Does parrot use LibTomMath for our Int type?
01:32 BenGoldberg (Or at least, Rakudo on Parrot)?
01:33 berekuk joined #perl6
01:33 diakopter BenGoldberg: I think so
01:33 BenGoldberg I was looking a the code for LibTomMath's stringification, and noticed something fairly silly
01:34 BenGoldberg When converting a number to base 10, for example, it repeatedly divides by 10, using the remainder of each division as an output digit.
01:35 BenGoldberg Division is of course slow (in general; not just LTM)
01:37 BenGoldberg The *faster* way to convert to base 10 is to convert to base 10000 (using big number divisions), then use C builtin % and / to convert each base 10000 digit into four base 10 digits.
01:38 diakopter how sure are you? :)
01:38 BenGoldberg If I can replace four big number division with a single big number division... very sure :)
01:39 BenGoldberg The number of big number division we can avoid depends on what we can fit into a bn_digit
01:41 BenGoldberg If bn_digit is 16 bits, then we can reduce the number of big number divides by a factor of 4.  If bn_digit is 32 bits, then we can reduce the number of big number divides by a factor of 8 (or 9?)
01:43 diakopter curious, moarvm is collecting 600,000 objects during global destruction
01:47 diakopter (after allocating 100,000 in each of 4 threads.. and doing 9 gc runs.. and the whole process is still taking only 100ms)
01:49 diakopter curious... oh.
01:49 diakopter heh.
01:49 benabik joined #perl6
02:03 lue diakopter: ww?
02:08 d^_^b joined #perl6
02:11 BenGoldberg Here's a bit of (untested) code with the speedup I mentioned: http://codepad.org/BG7s5gqJ
02:12 BenGoldberg D'oh... don't read that code, I just realized it's got a really silly bug in it.
02:12 BenGoldberg (fixing...)
02:19 BenGoldberg Ok, http://codepad.org/0BaJ94Aj should be better
02:22 BenGoldberg Err, still wrong, since I made a silly assumption about how many bits libtommath uses (when it's got 32 bit ints, it uses 28 bits!  So I've got to look at DIGIT_BIT to get this right)... fixing
02:26 jnap joined #perl6
02:50 BenGoldberg Ok, this time for sure ;) ... http://codepad.org/7OZhuiT1
02:52 BenGoldberg This time, the first occasion a big int is stringified, it will calculate the largest power of ten that is smaller than MP_DIGIT_MAX.
02:55 BenGoldberg It is still, of course, untested, but even so, you should be able to get the idea of what it's doing
02:55 JimmyZ It'd be better to submit a pull request and add an performance test/result comment there :P
02:56 BenGoldberg How do I do that?
02:58 JimmyZ and an request  to https://github.com/libtom/libtommath also ?
02:59 JimmyZ BenGoldberg: https://help.github.com/articles/creating-a-pull-request
03:01 * BenGoldberg is reading.... :)
03:04 preflex_ joined #perl6
03:05 BenGoldberg Does parrot use it's own branch of libtommath, or should I make a branch from github/libtom/libtommath ?
03:06 diakopter I don't understand the question
03:08 BenGoldberg According to the creating-a-pull-request help doc, the first thing I have to do is make my own branch of the repository
03:09 JimmyZ BenGoldberg: parrot doesn't use, nqp use
03:10 JimmyZ BenGoldberg: Just try it :P
03:11 BenGoldberg So I should make a branch from  https://github.com/libtom/libtommath ?
03:11 denysonique joined #perl6
03:14 JimmyZ BenGoldberg: you open a file like https://github.com/joyent/libuv/blob/master/src/inet.c, you will see "Edit", just click it
03:50 perigrin joined #perl6
04:02 preflex joined #perl6
04:02 SmokeMachine joined #perl6
04:24 SamuraiJack_ joined #perl6
05:15 DarthGandalf joined #perl6
05:17 BenGoldberg .tell JimmyZ Thank you very much! :)
05:17 yoleaux BenGoldberg: I'll pass your message to JimmyZ.
05:17 BenGoldberg .tell JimmyZ Here's the result of branching and making a pull request: https://github.com/BenGoldberg1/libtommath/commit/49642b6dbb2d86cf3f1e93f501faad17bdf8c31a
05:17 yoleaux BenGoldberg: I'll pass your message to JimmyZ.
05:17 BenGoldberg g'night now
05:18 atroxaper joined #perl6
05:19 sizz joined #perl6
05:21 diakopter BenGoldberg: "I have not tested or benchmarked this code, but I know that the basic idea is sound."
05:21 diakopter that's unlikely to instill much confidence in someone who's considering pulling your pull request to try it for themselves
05:25 denysonique joined #perl6
05:40 TimToady n: sub g (*@n) {         grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
05:40 camelia niecza v24-95-ga6d4c5f: OUTPUT«"997"␤»
05:49 benabik joined #perl6
05:49 TimToady r: sub g (*@n) {         grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
05:49 camelia rakudo f86a1a: OUTPUT«Nil␤»
05:49 TimToady r: sub g (*@n) { return grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
05:49 camelia rakudo f86a1a: OUTPUT«Nil␤»
05:50 TimToady r: sub g (*@n) { @(grep *.Int.is-prime, ((9,7,3,1) X~ @n)); }; say 7.&g.&g.[0].perl;
05:50 camelia rakudo f86a1a: OUTPUT«Nil␤»
05:52 diakopter TimToady: I tried list() too
05:52 TimToady r: sub g (*@n) { eager grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
05:52 camelia rakudo f86a1a: OUTPUT«"997"␤»
05:53 TimToady I guess it's just too darn lazy :)
05:54 TimToady r: sub g (@n) { grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say 7.&g.&g.[0].perl;
05:54 camelia rakudo f86a1a: OUTPUT«Nominal type check failed for parameter '@n'; expected Positional but got Int instead␤  in sub g at /tmp/OKtMuYguKY:1␤  in block  at /tmp/OKtMuYguKY:1␤␤»
05:54 TimToady r: sub g (@n) { grep *.Int.is-prime, ((9,7,3,1) X~ @n); }; say [7].&g.&g.[0].perl;
05:54 camelia rakudo f86a1a: OUTPUT«Nil␤»
05:54 TimToady r: sub g (@n) { [grep *.Int.is-prime, ((9,7,3,1) X~ @n)]; }; say [7].&g.&g.[0].perl;
05:54 camelia rakudo f86a1a: OUTPUT«"997"␤»
05:55 diakopter hey, I tried that
05:55 diakopter but it didn'tn work then
05:55 [Sno] joined #perl6
05:55 diakopter oh. [7]
05:55 TimToady and no slurpy
05:57 TimToady but yeah, probably a bug since niecza handles it fine
06:05 rindolf joined #perl6
06:11 sjohnson TimToady: hi, looks like a late night for you!
06:11 sjohnson (either that or I've hit PgUp too many times..)
06:14 varna joined #perl6
06:18 corecatcher good morning
06:18 diakopter corecatcher: hi
06:21 corecatcher the tutorial slides from last weekend are great, thanks for sharing
06:27 mberends timotimo: I think your git user friendly name goes in ~/.gitconfig
06:31 TimToady sjohnson: eh, it's not even tomorrow yet
06:31 * TimToady doesn't usually collapse until about midnight
06:31 sjohnson TimToady: I like this line of thinking.  actually, I only mentioned it because I should also be in bed soon, and I wanted to project the blame on someone!
06:32 * sjohnson is guilty
06:32 sjohnson I got busted, in front of exactly 200 perl 6 irc subscribes.  How will I tell this to my family & friends...
06:33 TimToady just mention it in your will
06:36 xinming joined #perl6
06:56 dmol joined #perl6
06:58 FROGGS joined #perl6
06:59 atroxaper joined #perl6
07:13 iSlug joined #perl6
07:15 hoelzro good morning #perl6
07:18 sqirrel joined #perl6
07:18 kaleem joined #perl6
07:22 zakharyas joined #perl6
07:24 jimmy_ joined #perl6
07:33 daxim joined #perl6
07:42 dmol joined #perl6
07:48 donaldh joined #perl6
07:57 FROGGS morning hoelzro
07:57 hoelzro morgen FROGGS
08:01 fhelmberger joined #perl6
08:23 domidumont joined #perl6
08:24 stevan__ joined #perl6
08:30 trnh joined #perl6
08:37 tadzik heh. At a conference I'm on, people next to me just said "have you ever met a compiler engineer? They're not really normal people" :D
08:39 mberends :D
08:42 hoelzro heh
08:46 cosimo tadzik: where are you?
08:47 tadzik cosimo: onGameStart 2013
08:47 tadzik it's mostly about HTML5, JS and games
08:48 tadzik completely different world
08:48 tadzik folks say things like "wow, JS must be the first language ever in which you can do EVERYTHING"
08:48 tadzik (regarding Nyan Cat built in JS source code which animated itself)
08:49 * hoelzro waits for a JS OS
08:50 nwc10 yes, the interrupt handlers are going to be something to behold
08:50 * mberends is trying to port the RaNIW exercises to JSish
08:51 cosimo tadzik: programming is like fashion, someone said
08:51 tadzik cosimo: in a way that creators of it look weird? :)
08:52 daxim_ joined #perl6
08:54 cosimo tadzik: in the way old things are forgotten, and come back as "new" all the time in cycles
08:55 sorear joined #perl6
08:56 JimmyZ joined #perl6
08:58 genehack joined #perl6
08:59 tadzik oh yes
09:00 tadzik the "write once, run everywhere" mantr
09:00 tadzik a
09:00 tadzik even here, people say "you remember what java said 10 years ago? HTML5 says the same and it's just as false" :)
09:01 tadzik and it's hilarous when you look at it from a perspective
09:01 tadzik for instance, "we choose HTML5 so we can write once, run everywhere, and all the platforms"
09:02 huf it's also funny when all that knowledge and experience we have about windowing toolkits has gone out the window as soon as we come to html5...
09:02 tadzik few slides later, few minutes later: "we abandoned the idea of an iOS port, because it was too time-consuming, and we just settled for android"
09:02 tadzik just wait until someone implements gtk/qt/whatever in html5
09:03 huf tadzik: also, you know how it's not cool to make your own GUI app wildly different from whatever the desktop theme looks/feels like?
09:03 tadzik istr gnome people already did that
09:03 tadzik huf: oh yes I do
09:03 huf why dont webdesigners know that? :)
09:03 huf i'd *love* it if all websites looked exactly the same
09:03 tadzik well, I don't see at as a problem
09:03 tadzik I do treat web as an entirely different beast
09:04 huf i treat it as two beasts
09:04 tadzik I hate it when a webapp tries to look like a desktop app
09:04 huf one displays hyperlinked pages, that's the old web (the part that works well)
09:04 tadzik because it always fails miserably in the attempt
09:04 huf and there's the webapp world, which ... ugh
09:04 tadzik for example, new JIRA thinks it's funny to pop-up a window to enter a bug resolution comment
09:04 huf tadzik: didnt mean look like a desktop app. just look like each other, a common look&feel
09:04 tadzik it looks like a window, but you can't move it
09:04 tadzik I sometimes move it around with javascript console
09:05 huf ah yes, overlays
09:05 tadzik huf: isn't that what HTML was supposed to be about?
09:05 tadzik so everyone can have their own CSS and make websites look as one wants to
09:05 tadzik shame that it never happened
09:05 huf well yes.
09:05 tadzik because everyone wanted to look distinct
09:05 huf pixelpushers :)
09:05 huf also that
09:05 tadzik now they're emulating desktop on web
09:05 tadzik and they will end up adjusting to users preferences
09:06 tadzik finally! :D
09:06 huf :)
09:06 tadzik (or so I hope
09:06 tadzik )
09:06 huf yes, but with +1million loc
09:06 huf and it'll be buggier and slower and contain more xml, you know that :)
09:06 tadzik I hope I'll never need to care
09:06 huf i should get out of webby bs :)
09:06 huf or at least make _websites_, not webapps :)
09:07 tadzik heh
09:09 masak good antenoon, #perl6
09:11 masak timotimo: [backlog] you're probably looking for the user.name config option in ~/.gitconfig
09:13 masak oh, mberends++ already replied that.
09:14 masak <tadzik> folks say things like "wow, JS must be the first language ever in which you can do EVERYTHING
09:14 masak I dub this feature of a language... "Nyan Cat completeness"
09:17 masak tadzik: hm, I don't understand the complaint about CSS. in my book, the CSS dream of ultimate styling freedom came true.
09:17 masak with maybe two caveats.
09:18 masak (1) people don't use it much. it's fairly restricted to power users. but it's there.
09:19 masak (2) some aspects of CSS are *insane*, such as the float semantics, which is probably the prime cause of human suffering in the web dev world. the cause seems to be de-facto standardization.
09:20 huf i'd say the "width isnt width" thing with the boxmodel is delicious too :)
09:20 daxim_ float is only so widely used becaused display:table-* don't work in ie6
09:26 tadzik masak: well, I guess I sort of expected to have "one stylesheet to style them all"
09:26 tadzik as in, "I want them all to be yellow on black"
09:27 tadzik which never quite works in the general case, in my experience
09:27 FROGGS that would be like having a perl compiler that compiles your program like I want to have it
09:28 masak tadzik: I find it interesting that *all three* of CSS, JS, and HTML have gotten successful "wrapper" languages recently.
09:28 masak tadzik: I think something like SCSS or LESS addresses what you want.
09:30 sqirrel joined #perl6
09:31 tadzik FROGGS: I don't think so. I see it more like reindenting someone else's code with my own .perltidyrc
09:32 FROGGS but but... yellow on black?!
09:32 tadzik I love that!
09:32 tadzik on grey, more like, but yeah
09:33 tadzik masak: I'll look at those
09:42 daxim_ http://search.cpan.org/dist/CSS-LESS/ freshly released
09:48 SHODAN joined #perl6
09:55 denis_boyun joined #perl6
09:55 domidumont joined #perl6
09:55 masak hypothetically... what would it take for 'perl Configure.pl' to be replaced by something non-p5?
09:55 masak I'm not suggesting we do this, and definitely not now.
09:56 masak but as part of dog-fooding, it's an interesting "what if" to think about.
09:56 masak there are inherent bootstrapping problems in replacing it with a p6 script.
09:57 dmol joined #perl6
09:57 nwc10 masak: you'd either need to find a way to translate it to something that runs natively on the platform
09:57 nwc10 (so a shell script on Unix, a batch file (or better) on Win32, DCL on VMS when you get there)
09:58 masak I guess that's doable.
09:58 nwc10 or, potentially, more interesting, convert it to a C program
09:58 masak yeah.
09:58 * masak looks at Configure.pl
09:58 nwc10 or, thirdly, try to go for a minimal MoarMV config that builds on ANSI C plus "not much"
09:58 tadzik do we have a dependency on a C compiler when running on JVM?
09:58 nwc10 and ship bytecode that runs atop that
09:58 nwc10 and bytecode that runs atop JVM
09:59 nwc10 tadzik: good point
09:59 nwc10 I think it's more "how do you bootstrap the VM" and then ship prebuilt "binaries" for each VM
09:59 masak how about implementing it... in NQP?
10:00 nwc10 yes, that should work.
10:00 masak that suddenly strikes me as the "platform-independent" option.
10:00 masak because you need the NQP dependency anyway.
10:00 masak I'm glad we had this talk :)
10:00 nwc10 it pushes the problem one level lower
10:00 nwc10 how does NQP re-write its Configure.pl
10:00 masak that's a later problem.
10:00 masak NQP needs binaries to bootstrap anyway.
10:00 nwc10 which I think in turn is "compile it to the native language for each VM targeted"
10:01 masak so it's not even really a problem.
10:01 masak just run the NQP's Configure with stage0 :)
10:01 nwc10 at which point seems that you push most of Configure.pl into Configure.nqp
10:01 nwc10 with a wrapper (or wrappers) to get you to NQP
10:01 JimmyZ o.O(replace Configure.pl by lua script with a mini lua)
10:03 JimmyZ yeah, there is minilua.c file in lua
10:15 masak lunch &
10:15 pmurias joined #perl6
10:15 pmurias hi
10:18 varna left #perl6
10:21 darutoko joined #perl6
10:23 darutoko is there a CPAN for perl6?
10:24 pmurias there is modules.perl6.org
10:25 nwc10 the P in CPAN is Perl, not Perl 5. But I don't think that many people are uploading Perl 6 code to it
10:25 nwc10 (yet)
10:25 nwc10 PAUSE is definately only Perl 5 currently. But PAUSE != CPAN
10:25 nwc10 er, the PAUSE uploader is the (easy) gateway to CPAN. The PAUSE index is what I meant by "Perl 5"
10:27 darutoko I mean CPAM module
10:29 nwc10 aha, an installer
10:29 nwc10 I think it's "panda", but someone else will hopefully answer better
10:30 darutoko thank you
10:30 darutoko another question, is there a module like LWP::UserAgent?
10:31 nwc10 that I don't know. Hopefully someone else does
10:35 FROGGS I can only see LWP::Simple, but this could be a good pattern to port LWP from Perl 5 over to Perl 6
10:35 JimmyZ or use v5 in v6
10:36 FROGGS nah, this will take a while to do that right
10:38 darutoko can you help me to install Panda?
10:39 domidumont joined #perl6
10:39 darutoko docs says to test: You will need a recent TAP::Harness (3.x)
10:39 darutoko I don't see this module in modules.perl6.org
10:40 FROGGS darutoko: can you point me to the docs that say that?
10:41 darutoko FROGGS, https://github.com/tadzik/panda/#running-tests
10:41 dalek nqp: 87be08f | (Tobias Leich)++ | src/vm/parrot/ops/nqp_bigint.ops:
10:41 dalek nqp: s/mp_toradix_n/mp_toradix/, (Ben Goldberg)++
10:41 dalek nqp: review: https://github.com/perl6/nqp/commit/87be08ffbe
10:41 FROGGS ahh
10:41 pmurias darutoko: I suppose it needs the perl5 TAP::Harness
10:41 FROGGS darutoko: pmurias is right
10:42 FROGGS it is just about having a prove binary, which comes from Perl 5
10:42 darutoko oh
10:42 darutoko ok, thank you
10:55 darutoko agh
10:55 darutoko test failed :(
10:55 tadzik which test?
10:55 darutoko all exept 1
10:56 darutoko http://paste.org.ru/?r9cyrs
10:56 tadzik oh my
10:56 tadzik what rakudo version is that?
10:56 darutoko This is perl6 version 2013.05 built on parrot 5.3.0 revision 0
10:57 tadzik is there an easy way to update it on your box?
10:57 tadzik panda usually targets the latest compiler releaes
10:57 darutoko shure
10:57 tadzik aweosme
10:57 darutoko it my desctop :)
10:57 darutoko *desktop
10:57 tadzik I should add git tags to panda, so on 2013.05 you can checkout panda 2013.05
10:58 darutoko damn there is no .msi for 08
10:59 tadzik ouch
11:00 tadzik 06, maybe?
11:00 tadzik I think I introduced these changes around june
11:00 darutoko http://rakudo.org/downloads/star/
11:00 tadzik or maybe try checking out aa8e2283c83c6041e535ae342d573d5e46c56ad7 in panda
11:00 darutoko 2013.05 and 2013.08
11:00 tadzik that should work on 2013.05
11:01 denis_boyun joined #perl6
11:01 darutoko ok
11:01 tadzik star is not release every month
11:02 darutoko so it is no point to even try p6 on windows?
11:07 berekuk joined #perl6
11:09 tadzik why not?
11:09 tadzik what I mean is, while the compiler has monthly releases, Star doesn't
11:10 darutoko so many problems and I even didn't start anything to do
11:10 tadzik btw, if you installed Star, panda is already there
11:10 tadzik the point of star is shipping usable modules with it
11:10 tadzik lunch &
11:11 darutoko damn, you right :)
11:13 tadzik actually, not lunch :)
11:15 darutoko agh, it wants git
11:15 darutoko screw it
11:19 tadzik :(
11:19 tadzik yeah, it uses git to fetch stuff
11:19 tadzik you can download them manually and install them from directories too
11:20 darutoko I hate make on windows
11:23 lizmat good *, #perl6!
11:23 colomon \o
11:24 tadzik darutoko: what can I do to make panda more usable for you?
11:24 lizmat too bad all of my Set/Bag work didn't make it to the release announcement
11:24 lizmat :-)
11:25 darutoko tadzik, its not you, its all together
11:26 * lizmat continues on getting [] and {} method to sub migration
11:26 darutoko tadzik, I'll try it later on virtual machine with Ubuntu
11:26 darutoko thank you
11:26 tadzik I mean the general stuff, like "don't rely on git"
11:26 tadzik anything, really
11:27 lizmat it turns out that the current adverb implementation assumes the silent absorption of unused named parameetrs
11:27 lizmat need to refactor this greatly now  :-(
11:27 lizmat but in the end, it should mean faster [] and {} access
11:28 tadzik I wonder if we could set up small VMs for people to try out perl 6
11:29 mberends good idea, as long as there is server space and bandwidth for the downloads
11:30 darutoko you can put it on torrent
11:30 darutoko like piratebay
11:30 mberends I'd be happy to help build and maintain some VirtualBox images
11:36 pernatiy joined #perl6
11:37 sqirrel joined #perl6
12:04 iSlug joined #perl6
12:04 * lizmat just realises that the [] and {} adverb handling is now identical, save for the "at_key" and "at_pos" naming
12:05 hoelzro if one wanted to add a keyword to Perl 6 (ex. binary_grammar MyGrammar { ... }), would that require the use of a slang?
12:05 hoelzro or is there another way to go about it?
12:06 lizmat do you want that keyword to be available everywhere at all time, or just in a lexical context ?
12:07 hoelzro lexical
12:07 hoelzro I had a (few) cool idea(s)
12:11 lizmat wouldn't that just be a infix:<binary_grammar> ?
12:11 lizmat *prefix
12:12 timotimo i don't think so
12:14 FROGGS it is not a prefix
12:15 FROGGS hoelzro: you want to create a knowhow I think, look at the RaNIW material
12:15 hoelzro FROGGS: I figured it would take a knowhow, but I didn't know if knowhows automatically created new keywords for their definition
12:16 timotimo i think they do
12:17 hoelzro sweet
12:19 * lizmat wonders how much would break if at_key and at_pos would be renamed to "at"
12:21 FROGGS hoelzro: in the exercises page 14 and 15
12:21 hoelzro nice
12:21 hoelzro thanks!
12:21 FROGGS and in the book thingy section 6model
12:22 FROGGS you would have to create a statement:<binary_grammar> I think
12:22 FROGGS like there is a statement:sym<grammar>
12:23 hoelzro FROGGS: but that requires modifying the Perl 6 grammar itself, doesn't it?
12:28 timotimo finally i have a big teacup. now i can take over the world^Wday
12:29 hoelzro ugh
12:29 FROGGS hoelzro: no, you could declare it lexically, but you would have to mix-in the action method also
12:29 hoelzro rhetorical question #1: why does the Linux OOM killer suck so hard?
12:29 timotimo huh, that's hard :o
12:29 hoelzro rhetorical question #2: why does Parrot use all my memory?
12:30 FROGGS r: multi statement:<hurz>() { }; hurz A { }
12:30 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/A2Nxca2XFPâ�¤Cannot add tokens of category 'statement'â�¤at /tmp/A2Nxca2XFP:1â�¤------> [32mmulti statement:<hurz>[33mâ��[31m() { }; hurz A { }[0mâ�¤    expecting any of:â�¤        colon pairâ�¤        quote word…»
12:30 FROGGS :/
12:30 FROGGS r: multi package_declarator:<hurz>() { }; hurz A { }
12:30 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/cU1DfZJi7xâ�¤Cannot add tokens of category 'package_declarator'â�¤at /tmp/cU1DfZJi7x:1â�¤------> [32mmulti package_declarator:<hurz>[33mâ��[31m() { }; hurz A { }[0mâ�¤    expecting any of:â�¤        colon pairâ�¤ …»
12:31 FROGGS r: multi package_declarator:<hurz> { }; hurz A { }
12:31 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/i7AEUxpdf5â�¤Cannot add tokens of category 'package_declarator'â�¤at /tmp/i7AEUxpdf5:1â�¤------> [32mmulti package_declarator:<hurz> [33mâ��[31m{ }; hurz A { }[0mâ�¤    expecting any of:â�¤        colon pairâ�¤   …»
12:31 FROGGS damn
12:31 hoelzro I think
12:31 hoelzro that jnthn said something about having to use the meta objects by hand to create new classes/whatever
12:31 hoelzro at least for now
12:32 nwc10 lizmat: if at_key and at_pos are both called at, does that cause problems for an aggregate that can offer both keyed and positional access?
12:32 lizmat argh, yes
12:32 lizmat that was the reason
12:32 * lizmat suddenly recalls having this discussion with jnthn
12:32 hoelzro class LuaTable { ... } # ;)
12:35 lichtkind joined #perl6
12:37 lichtkind cant find in synopses syntax to resolve role attribute and method name collisions
12:37 lichtkind no matter how hard i looked
12:37 hoelzro I thought you have to define the method yourself?
12:38 tadzik that's what I recall
12:38 lichtkind yes but there has to be commands like rename and reject
12:38 lichtkind to do it
12:38 lichtkind cant find syntax on them
12:38 tadzik doesn't ring a bell
12:38 timotimo there's no syntax, i believe. you just define them, no?
12:38 timotimo in the class you're mixing into
12:39 lichtkind of course you need a syntax
12:39 cono joined #perl6
12:39 lichtkind becasue we dont want mixins but traits
12:39 lichtkind larry explained lengthy why mixins are bad
12:39 lichtkind but there has to be a syntax to resolve conflicts
12:40 lichtkind just read the papers on traits
12:40 timotimo r: role ConA { method foo { say "conA" } }; role ConB { method foo { say "conB" } }; class yoink does ConA does ConB { method foo { ConA::foo() } }
12:40 camelia rakudo f86a1a: ( no output )
12:40 timotimo or something like that?
12:40 timotimo r: role ConA { method foo { say "conA" } }; role ConB { method foo { say "conB" } }; class yoink does ConA does ConB { method foo { ConA::foo() } }; yoink.new().foo()
12:40 camelia rakudo f86a1a: OUTPUT«Could not find symbol '&foo'␤  in method <anon> at src/gen/CORE.setting:12026␤  in any  at src/gen/Metamodel.nqp:2671␤  in any find_method_fallback at src/gen/Metamodel.nqp:2659␤  in any find_method at src/gen/Metamodel.nqp:946␤  in method foo at /tmp/Qg4wJ4uTa…»
12:40 FROGGS lichtkind: if a class does two roles which have the same method, you need to create that method in your class, and do a dispatch to the right one
12:40 timotimo hm.
12:41 lichtkind FROGGS: thanks
12:41 lizmat yes, that was mentioned at the RaNIW
12:41 FROGGS timotimo: that is a sub call
12:41 timotimo of course it is! :)
12:41 lichtkind FROGGS: ant with conflicting attributes?
12:41 timotimo r: role ConA { method foo { say "conA" } }; role ConB { method foo { say "conB" } }; class yoink does ConA does ConB { method foo { self.ConA::foo() } }; yoink.new().foo() # maybe like this?
12:41 camelia rakudo f86a1a: OUTPUT«conA␤»
12:42 timotimo cool
12:42 FROGGS lichtkind: what do you mean by conflicting? if they are multi, there are no conflicts, and if they are onlys, it doesnt matter if they have different signatures
12:43 lichtkind thanks a lot i wouldnt find that on my own
12:43 lichtkind when different roles a class consumes define same attribute
12:43 FROGGS you're welcome :o)
12:43 timotimo r: role ConA { method foo { say "conA" } }; role ConB { method foo { say "conB" } }; class yoink does ConA does ConB {}; yoink.new().foo() # what does the error look like?
12:43 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤Method 'foo' must be resolved by class yoink because it exists in multiple roles (ConB, ConA)␤»
12:43 FROGGS lichtkind: ahh
12:43 cono conO!
12:43 timotimo "resolved" doesn't really follow the "tell the user exactly what to do to fix it" rule
12:44 FROGGS lichtkind: I'm not sure how this is handled, or will be handled
12:44 lichtkind sounds like a whie spot :)
12:44 FROGGS lichtkind: I just know that rakudo and spec currently differ at that point
12:44 lichtkind have nag $larry
12:44 timotimo same as above; the attributes are private to the roles and you can reach the attribute accessors like i did above
12:45 lichtkind cool thanks
12:45 FROGGS timotimo: but I think this is meant to change
12:45 FROGGS bbl
12:45 timotimo r: role ConA { has $.foo = "ConA" }; role ConB { has $.foo = "conB" }; class yoink does ConA does ConB { method foo { self.ConA::foo } }; my $y = yoink.new(); say $y.foo; $y.foo = "hi"; say $y.foo;
12:45 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤Attribute '$!foo' conflicts in role composition␤»
12:46 timotimo oh, interesting
12:46 timotimo i must have misremembered.
12:48 timotimo it really was a good idea to get a bigger cup for my tea
12:49 berekuk joined #perl6
12:54 geekosaur joined #perl6
12:55 pmurias tadzik: re setting up small VMs, wouldn't create a install-everything-for-rakudo installer for windows be a better use of time?
12:58 nwc10 dear lazyIRC, can you tell me where the Fine Manual is about "how do I read a file that is in UTF-16?" or "a file that is in ISO-8859-1?"
12:59 JimmyZ pmurias: for windows: http://rakudo.org/downloads/star/rakudo-star-2013.05.msi
13:01 daxim_ "first you port Encode.pm or libiconv…"
13:01 nwc10 if the answer is "there isn't a design yet", that's also interesting and a fair answer
13:01 timotimo it would be cool to have a few example files in weird encodings on the evalbot to play around with
13:02 timotimo though, if you give me a minute i can come up with something ...
13:02 jnap joined #perl6
13:03 pmurias nwc10: you want to read a file in ISO-8859-1 from Perl6?
13:04 nwc10 no, I want to know what the design is
13:06 pmurias on the nqp level you first nqp::setencoding($fh,'iso-8859-1') on the file handle, and then nqp::readallfh($fh)
13:06 hoelzro hmm
13:06 hoelzro I'm thinking of writing an "Intro to Perl 6 in 6 minutes" post/document/thing
13:07 hoelzro any ideas on what sort of things are quick to cover, but are cool?
13:07 hoelzro say 'Hello World!' is nice, but not exactly eye-catching
13:07 JimmyZ [\+]
13:07 pmurias who is the audience?
13:07 hoelzro people who know next to nothing about Perl 6
13:07 hoelzro not necessarily Perl 5 programmers, even
13:07 masak hoelzro: multi subs.
13:08 hoelzro oh, nice!
13:08 masak hoelzro: nwc10 recently pointed out that they have a really nice reach, and are intuitive.
13:08 * hoelzro <3 multi subs
13:08 masak and it's easy-ish to find nice demos for them.
13:08 hoelzro indeed
13:08 masak r: multi infix:<+>("PHP", "the Web") { "security vulnerabilities" }; say "PHP" + "the Web"
13:09 camelia rakudo f86a1a: OUTPUT«security vulnerabilities␤»
13:09 * masak grins
13:09 arnsholt =D
13:09 masak even silly ones.
13:09 hoelzro r: sub infix:<< <3 >>(Str $agent, Str $object) { say "$agent loves $object!" } 'Rob' <3 'Perl 6'
13:09 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/mygTg3ljl1â�¤Two terms in a rowâ�¤at /tmp/mygTg3ljl1:1â�¤------> [32mobject) { say "$agent loves $object!" } [33mâ��[31m'Rob' <3 'Perl 6'[0mâ�¤    expecting any of:â�¤        postfixâ�¤        statement endâ�¤      â€¦Â»
13:09 hoelzro curses
13:09 hoelzro r: sub infix:<< <3 >>(Str $agent, Str $object) { say "$agent loves $object!" }; 'Rob' <3 'Perl 6'
13:09 camelia rakudo f86a1a: OUTPUT«Rob loves Perl 6!␤»
13:09 hoelzro hehe
13:09 arnsholt Multi subs are awesome
13:09 hoelzro that's totally going in there =)
13:09 masak yes, but don't put a "say" in an operator, please :)
13:09 arnsholt I keep wanting them in various places just about all the time...
13:10 hoelzro ok, noted =)
13:10 ajr joined #perl6
13:10 arnsholt What, you don't think side effects in operators are a good idea? ^_^
13:11 masak let's just say they should be kept to a minimum :)
13:12 hoelzro anything else I should cover?
13:12 * hoelzro will probably combine the <3 operator and multi subs
13:12 hoelzro I'm trying to make it my personal mission to improve doc.perl6.org
13:12 hoelzro improving the look *and* the content
13:13 masak hoelzro: personally I like role composition and method conflict resolution a lot.
13:13 masak hoelzro: the standard example there being DrunkenGymnast.go-to-bar
13:13 hoelzro that's a nice feature, but I don't know if it belongs in "6 minute Perl 6"
13:13 hoelzro hmm
13:13 masak right. maybe not.
13:13 hoelzro I do like that example, though =)
13:13 masak :)
13:14 masak it can be explained in a minute or so.
13:14 hoelzro I was very strongly motivated by http://stevelosh.com/blog/2013/09/teach-dont-tell/
13:14 masak DrunkenGymnast does Drunk does Gymnast
13:14 hoelzro I want a *very* quick tutorial that gets people hooked
13:15 hoelzro basically, I want to distill the feelings I got over the workshop weekend into an HTML document =)
13:15 lizmat hoelzro++
13:15 masak looks like a really nice post.
13:15 masak will read it.
13:16 timotimo there needs to be some design put into an example file in an example encoding... hmm
13:16 hoelzro what are the valid characters that can follow 'sub infix:'? just <, <<, and guillemets?
13:17 timotimo i think [' ... '] as well
13:17 timotimo and i believe spaces are allowed after the < and <<
13:17 hoelzro r: sub infix:[ <3 ]('Rob', 'Perl 6') returns Bool { True }
13:17 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/JneoskI1Haâ�¤Unable to parse expression in quote words; couldn't find final '>'â�¤at /tmp/JneoskI1Ha:1â�¤------> [32m]('Rob', 'Perl 6') returns Bool { True }[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        â€¦Â»
13:17 hoelzro =(
13:17 timotimo r: infix:<< <3 >>(1) { }
13:17 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/qzxDAFdBuzâ�¤Unexpected block in infix position (two terms in a row, or previous statement missing semicolon?)â�¤at /tmp/qzxDAFdBuz:1â�¤------> [32minfix:<< <3 >>(1) [33mâ��[31m{ }[0mâ�¤    expecting any of:â�¤ …»
13:17 hoelzro maybe because the "operator" begins with <
13:17 timotimo r: infix:['<3'](1) { }
13:17 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/Tb30qQWaXJâ�¤Unexpected block in infix position (two terms in a row, or previous statement missing semicolon?)â�¤at /tmp/Tb30qQWaXJ:1â�¤------> [32minfix:['<3'](1) [33mâ��[31m{ }[0mâ�¤    expecting any of:â�¤   …»
13:17 xinming joined #perl6
13:17 hoelzro << >> works
13:17 * lizmat just realizes that the at_key/at_pos/at argument hasn't been applied to .exists and .delete
13:18 timotimo r: multi infix:<< <3 >>(1) { }
13:18 camelia rakudo f86a1a: ( no output )
13:18 timotimo that's better.
13:18 lizmat and that therefore we will need a .exists_key|pos and .delete_key|pos  :-(
13:19 masak hoelzro: another very nice feature of multi subs: you can supply literal parameters, like 0, instead of writing them like Int $n where { $n == 0 }
13:20 lizmat .tell jnthn the fact that we can't make a generic 'at' instead of .at_key and .at_pos (because an object might do both)
13:20 yoleaux lizmat: I'll pass your message to jnthn.
13:20 masak r: multi fib(0) { 1 }; multi fib(1) { 1 }; multi fib(Int $n) { fib($n-1) + fib($n-2) }; say fib 5
13:20 camelia rakudo f86a1a: OUTPUT«8␤»
13:20 hoelzro masak: I intend to demo that =)
13:20 lizmat .tell jnthn doesn't that mean that we should separate .exists into .exists_key / .exists_pos as well
13:20 yoleaux lizmat: I'll pass your message to jnthn.
13:20 masak hoelzro: ooh, ooh! Rat!
13:20 hoelzro hmm
13:21 hoelzro masak: care to provide a good example?
13:21 lizmat .tell jnthn and .delete into .delete_key and .delete_pos ?
13:21 yoleaux lizmat: I'll pass your message to jnthn.
13:21 masak r: my $x = 1000 / 3; say $x * 3
13:21 camelia rakudo f86a1a: OUTPUT«1000␤»
13:21 masak hoelzro: note, exact reply. not 999.9994 or something like that.
13:21 masak hoelzro: in general, with just +-*/, you don't lose precision.
13:21 hoelzro hmm
13:21 masak r: .say for 0, 0.1 ... 1.0
13:21 camelia rakudo f86a1a: OUTPUT«0␤0.1␤0.2␤0.3␤0.4␤0.5␤0.6␤0.7␤0.8␤0.9␤1␤»
13:22 masak very important for things like currencies.
13:22 hoelzro hmm
13:22 hoelzro it's handy
13:23 pmurias hoelzro: re the teach-dont-tell despite the article mocking the use of tests as documentation I find them really usefull for that
13:24 hoelzro pmurias: I agree, but I understand his point
13:24 benabik joined #perl6
13:24 hoelzro I wouldn't ask something to learn Perl 6 by reading roast
13:25 hoelzro or get started using Perl 6 by reading roast
13:25 hoelzro but I consult roast often for idiomatic useage
13:25 hoelzro *usage
13:26 hoelzro I think I found http://jacobian.org/writing/great-documentation/ especially useful
13:26 hoelzro and I found that via the first article =)
13:26 pmurias I really liked smartlinks (which displayed tests together with the documentation)
13:27 hoelzro don't the syn documents have that?
13:27 hoelzro I think that's very handy
13:27 hoelzro but I consider tests to be on the same level at reference documentation
13:27 hoelzro they're good if you have an idea what you're looking for
13:28 tadzik pmurias: maybe. I just don't have a faintest idea how to make things work on windows :)
13:28 tadzik also, what I really meant about the VMs was to set up servers that people can ssh to
13:29 tadzik but your interpretation was much better :)
13:46 lizmat tadzik: a server you can ssh to the same as feather ?
13:49 timotimo oh, togetherJS could be a nice fit for a "try perl6" kind of website
13:50 hoelzro timotimo: I had a similar thought
13:50 hoelzro we need a JS environment, though =/
13:50 tokuhirom joined #perl6
13:51 masak I hear someone is working on that.
13:51 masak pmurias++
13:51 hoelzro ;)
13:51 yoleaux joined #perl6
13:51 timotimo well, for my version of the try perl6 thing, we'd need JS anyway
13:51 fridim__ joined #perl6
13:51 simcop2387 joined #perl6
13:51 timotimo because that's what i built it in
13:52 hoelzro ooo
13:52 hoelzro thing I think I should add to the 6 minute tutorial: Whatever
13:52 hoelzro Whatever is cool.
13:52 timotimo show the newbies whatever is cool.
13:53 masak I confess to being so used to Perl 6 that I don't immediately remember what's so cool about Whatever :)
13:54 lizmat r: class A does Positional does Associative {}   # so *can* we have a class that does both [] and {} ?
13:54 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤Method 'of' must be resolved by class A because it exists in multiple roles (Associative, Positional)␤»
13:54 masak usually it just means "infinity" or "the length of the list" or "the default thing".
13:54 masak lizmat: yes, if you provide your own 'of' method in A.
13:55 lizmat which means that either you will have {} or [], right ?
13:55 masak r: class A does Positional does Associative { method of { "disambiguated!" } }
13:55 camelia rakudo f86a1a: ( no output )
13:55 lizmat masak: but not both ?
13:55 masak lizmat: I don't see why that would necessarily follow.
13:55 masak "of" refers to the type of the elements, no?
13:55 tadzik lizmat: yeah, something like this
13:55 masak says nothing of {} vs []
13:57 hoelzro hmm
13:57 hoelzro :title<Foo Bar> # <-- what's the value here? 'Foo Bar' or ['Foo', 'Bar']?
13:59 xenoterracide joined #perl6
14:00 timotimo the latter
14:01 timotimo r: say (:title<Foo Bar>).perl
14:01 camelia rakudo f86a1a: OUTPUT«"title" => $("Foo", "Bar")␤»
14:01 timotimo well, not exactly the latter
14:01 hoelzro oh, ok
14:01 hoelzro I thought I found a bug
14:03 dalek rakudo/method2sub: e7542c8 | (Elizabeth Mattijsen)++ | src/core/ (3 files):
14:03 dalek rakudo/method2sub: Handle all [] and {} adverb handling in SLICE_ONE and SLICE_MORE
14:03 dalek rakudo/method2sub:
14:03 dalek rakudo/method2sub: Adapt the postcircumfix candidates to call these subs with the appropriate
14:03 dalek rakudo/method2sub: parameters.  Please note that these subs are used for both [] and {}, as their
14:03 dalek rakudo/method2sub: handling is basically the same.
14:03 dalek rakudo/method2sub:
14:03 dalek rakudo/method2sub: This unfortunately dies during compilation again.  Working on that.
14:03 dalek rakudo/method2sub: review: https://github.com/rakudo/rakudo/commit/e7542c8033
14:08 skids joined #perl6
14:10 benabik joined #perl6
14:13 pmurias isn't a danger of putting too much cool stuff in the tutorial make Perl6 like a really crazy language?
14:13 lizmat well, yes and no
14:13 hoelzro pmurias: that's why I'm only putting in *some* of the cool stuff )
14:13 hoelzro =)
14:14 FROGGS the sane stuff please :o)
14:14 hoelzro it's just to demonstrate the power of the language
14:14 masak it all depends on who is the target of the tutorial.
14:14 hoelzro I don't intend to introduce slangs or grammars
14:14 lizmat in my 5 to 6 nuggets series lightning talks, I've tried to stay as close to Perl 5 as possible initially, and take it from there
14:14 hoelzro ...yet.
14:14 hoelzro the target is someone who knows how to program
14:14 hoelzro but of no particular background
14:15 hoelzro I'm thinking of making a "Perl 6 for (Perl 5 || Python || Java || Scalar || etc) programmers" as well
14:15 hoelzro but first things first =)
14:15 hoelzro it's simply to make other programmers think "holy crap, this language is really cool."
14:15 timotimo bioperl6 comes with its own makefile that sets the target to jar :/
14:16 timotimo interestingly, when using ufo and make, i get a different error from the smoker
14:16 tadzik huh
14:17 timotimo there seems to be files missing or something?
14:17 timotimo i was hoping there'd be a simple fix :P
14:17 pmurias hoelzro: I'm afraid of crossing the line between "holy crap, this language is really cool." and "wtf, this language is really crazy"
14:17 fhelmberger_ joined #perl6
14:18 hoelzro pmurias: I understand
14:18 hoelzro that's why I need help writing it =)
14:18 hoelzro if we don't show it off *at all*, it'll just be the language no one cares about, or no one's heard about
14:19 hoelzro I feel like a lot of the Perl 5 community is starting to come around on Perl 6
14:19 hoelzro but I'd like programmers from other communities to look at Perl 6 and find it alluring as well
14:21 timotimo it's alturing all right
14:22 diakopter hoelzro: I hesitate because so much is still unpresentable
14:23 hoelzro diakopter: could you clarify?
14:24 diakopter we all know early adopters are masochists with too much time on their hands, or simply contrarians
14:24 masak contrarians? am not!
14:26 diakopter but pragmatists juggling priorities and investments have entirely different stsndards of adoption
14:26 hoelzro hmm
14:27 hoelzro I suppose I'm thinking about this documentation for the future, when people start to look at Perl 6 with a more pragmatic mindset
14:27 diakopter around here, early sdopters become stakeholders, or leave
14:27 hoelzro I also look at it as my way to knocking something off of the "Perl 6 doesn't have X" list
14:28 diakopter because of the huge time investment required
14:29 diakopter to become acclimated and encultured
14:30 thou joined #perl6
14:30 masak the challenge with all tutorial-like artifacts is having them survive down the years :)
14:30 hoelzro true
14:30 masak in a form which is still useful and not misleading five years later.
14:30 diakopter "hmm, these look like the sort of people I want to spend much of my screen time with"
14:32 darutoko joined #perl6
14:32 diakopter don't give away training wheels when there's only 6 feet of road constructed
14:33 masak well, #perl6 has always been about flood-filling.
14:33 masak working on several approaches at once.
14:33 nwc10 hoelzro: couple of suggestions, neither of which may work
14:33 hummeleB1 joined #perl6
14:33 timotimo i have no idea how to read kcachegrind :|
14:33 nwc10 1) take entries from the Perl FAQ (ie Perl 5), and produce much nicer shorter answers in perl 6
14:34 nwc10 2) take recipies from the Perl Cookbook, and provide a Perl 6 example
14:34 hoelzro hmm
14:34 hoelzro I like that
14:34 hoelzro I'll put those in my notes
14:34 iSlug joined #perl6
14:34 berekuk joined #perl6
14:34 hoelzro but I understand what diakopter is saying
14:34 nwc10 yes
14:34 hoelzro so maybe I should focus on improving the more in-depth conceptual documentation
14:34 nwc10 yes, that might be better in the short term
14:35 nwc10 also, I think that "concurrency" and "NFG" are going to be longer term winners (over the current competition for mindshare)
14:35 timotimo hoelzro: there was a perl6 advent entry about perl5 to perl6 which i liked a lot a long time ago
14:35 nwc10 so examples which show how they are easy (once they work well) I hope will go down
14:35 nwc10 go down well
14:35 nwc10 [to be clear :-)]
14:36 hoelzro timotimo: are you referring to http://perlgeek.de/en/article/5-to-6?
14:36 ajr joined #perl6
14:37 timotimo no
14:37 diakopter nfg is just nfc + a space-optimized (and access-time complexity-optimized!) storage format..
14:38 * masak thought about https://perl6advent.wordpress.com/2011/12/23/day-23-idiomatic-perl-6/
14:38 timotimo i think i've found my next good optimization target
14:38 diakopter and I'm not convinced of the value beyond that
14:38 timotimo http://perl6advent.wordpress.com/2011/12/23/day-23-idiomatic-perl-6/ - i was refering to this article
14:38 timotimo Util++
14:39 diakopter mm days 23
14:39 diakopter er heh
14:40 colomon joined #perl6
14:40 diakopter nwc10: what's the selling points of nfg to the programmer who knows what nfc is
14:41 diakopter *what're
14:42 JimmyZ r: say 'g' - 'c'
14:42 nwc10 NFC doesn't get you to easy 1-1 for all the base character + accent combinations that don't have a single code point. So you still have to explicitly code to avoid splitting graphemes
14:42 hummeleB1 joined #perl6
14:42 JimmyZ rn: say 'g' - 'c'
14:42 timotimo can i refer to some kind of database to figure out if an nqp:: op has a certain return type?
14:42 camelia rakudo f86a1a: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏g' (indicated by ⏏)␤  in method Numeric at src/gen/CORE.setting:12019␤  in sub infix:<-> at src/gen/CORE.setting:4112␤  in sub infix:<-> at src/gen/CORE.setting:4110␤  in s…»
14:42 camelia niecza v24-95-ga6d4c5f: OUTPUT«Unhandled exception: Cannot parse number: g␤  at /home/p6eval/niecza/lib/CORE.setting line 1536 (die @ 5) ␤  at /home/p6eval/niecza/lib/CORE.setting line 3745 (ANON @ 10) ␤  at /home/p6eval/niecza/lib/CORE.setting line 3747 (NumSyntax.str2num @ 5) ␤  a…»
14:42 camelia ..rakudo f86a1a: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏g' (indicated by ⏏)␤  in method Numeric at src/gen/CORE.setting:12019␤  in sub infix:<-> at src/gen/CORE.setting:4112␤  in sub infix:<-> at src/gen/CORE.setting:4110␤  in s…»
14:43 timotimo like, can i get from "add_i" to "returns low-level int"?
14:43 hummeleB1 joined #perl6
14:43 nwc10 diakopter: but you're right. It's not an obviously easy sell
14:43 nwc10 Unless you've already hit the problem
14:43 FROGGS timotimo: doesnt it have a .returns?
14:43 diakopter nwc10: but how often does someone encounter that
14:44 diakopter what editors let you make such constructs
14:44 nwc10 I'm sure Tom Christiansen thinks he encounters it daily. But I don't know about mortals
14:44 nwc10 yes, I don't know.
14:45 timotimo FROGGS: it seems the .returns isn't set for QAST::Op(:op('add_i')) at optimize time; but i also don't know how to figure that out without a complete rebuild
14:46 timotimo i stumbled upon a line in reify where a < was not directly resolved to the correct candidate, going through the proto instead
14:46 timotimo it was between a my int $foo and nqp::elems(...)-
14:47 timotimo which really ought to have dispatched directly to the native implementation
14:47 ajr_ @hoelzro and timitimo - it sounds as though you are thinking about some of the same problems as I am; given the enormous mountain of Perl 6, how can I start climbing it without the path being washed away under my feet?
14:47 timotimo oh, me?
14:48 timotimo i just try to be one of the people who build the path to make sure my feet only get wet when i explicitly want them to :P
14:48 diakopter it's less of a mountain and more of an asteroid belt
14:49 diakopter (the entire orbit)
14:49 ajr_ Would one of the mailing lists be a better forum for discussing this?
14:50 diakopter someday it'll be a planet
14:50 ajr_ Someday, I'll be dead.
14:50 diakopter lolz
14:52 lizmat cycling & dinner&
15:02 timotimo huh. doesn't seem like the .returns(1) helps inline the <
15:02 timotimo or at least i can't see a difference in the --target=optimize
15:02 timotimo what does an inlined call look like there?
15:04 sqirrel joined #perl6
15:06 FROGGS timotimo: shouldn't it be .returns(int) ?
15:06 timotimo i don't think you can do that
15:06 timotimo but i'll try, thanks
15:06 FROGGS wait a sec
15:07 timotimo perhaps i was confusing the primspec thing?
15:07 timotimo you're right
15:07 FROGGS $qastcomp.as_post(QAST::Op.new(
15:07 FROGGS :op('callmethod'), :name('get_lex_type'), :returns(int),
15:07 FROGGS $op[0], $op[1]
15:07 FROGGS ))
15:08 timotimo i'm in the optimizer, where i need to .returns(self.find_lexical('int'))
15:08 ajr_ joined #perl6
15:09 hoelzro /me .oO( I'm )
15:09 hoelzro damn, my macro didn't work =/
15:09 timotimo hehe
15:09 * hoelzro .oO( I'm in the optimizer, optimizing your codez? )
15:10 timotimo that kind of describes my activity in perl6land ...
15:10 masak :)
15:10 timotimo i'm glad people are not raging at me for premature optimizations all over the place
15:10 hoelzro I'm pretty sure they're not premature at this point =)
15:12 masak "premature" doesn't refer to how far the project as a whole has taken so far :P
15:12 masak s/far/long/
15:12 timotimo hehe.
15:13 timotimo my little first attempt is apparently not helping the compile-time inliner do its job
15:15 pmurias timotimo: what is your next target?
15:16 * pmurias had a scrolled back irc buffer
15:17 dmol joined #perl6
15:17 hoelzro /me .oO( I'm in the optimizer, optimizing your codez? )
15:17 hoelzro dammit
15:17 * hoelzro forgets the whole damn thing
15:18 timotimo you have a little command that wraps your text in /me .o( and )?
15:18 hoelzro mhmm
15:18 hoelzro I fixed it...sort of.
15:20 * hoelzro .oO( I think I fixed it )
15:20 pmurias timotimo: nqp/src/vm/parrot/QAST/Operations.nqp - has the return info for some ops
15:20 hoelzro \o/
15:20 PerlJam hoelzro: shouldn't that be just .oO( I fixed it )   ;-)
15:20 hoelzro fair enough =)
15:21 masak PerlJam: so, you're saying thinking is a monad? :P
15:22 PerlJam masak: how else are we to program our brains?
15:23 timotimo pmurias: the most important question is: does the optimizer understand that info?
15:23 timotimo for elems there's just the 'IP' string and :inlinable(1)
15:23 masak PerlJam: with my luck, my brain is running on UnsafeIO :P
15:24 pmurias timotimo: it takes an object (P) and returns an int (I)
15:24 timotimo yes, i know :)
15:24 timotimo does the optimizer see that bit of info?
15:24 timotimo oh, also, that's a non-native int?
15:25 pmurias non-native one, I think it's a parroty one
15:25 timotimo mhm
15:26 pmurias so it's a native one
15:26 pmurias timotimo: I don't think such info is exposed to the optimizer by a clear interface
15:27 timotimo that would be good for the core setting, i think
15:27 timotimo because that's where lots of nqp:: is used
15:29 dalek rakudo-js: bd19383 | (Pawel Murias)++ | runtime.js:
15:29 dalek rakudo-js: Implement isle_s. Add to string conversions.
15:29 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/bd19383f1d
15:29 dalek rakudo-js: 977fcc8 | (Pawel Murias)++ | Makefile:
15:29 dalek rakudo-js: Fix the order of nqp-compiler.js dependencies.
15:29 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/977fcc8fd3
15:29 dalek rakudo-js: 7045249 | (Pawel Murias)++ | run_tests:
15:29 dalek rakudo-js: Avoid running nqp/t/nqp/19-readline.txt as a test.
15:29 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/7045249dd1
15:29 dalek rakudo-js: 6f2af2c | (Pawel Murias)++ | / (2 files):
15:29 dalek rakudo-js: Take the lexical scope from the correct module when loading the setting multiple times.
15:29 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/6f2af2c341
15:29 dalek rakudo-js: 081f5b0 | (Pawel Murias)++ | / (6 files):
15:29 dalek rakudo-js: Add a ModuleLoader written partially in nqp that does globals merging.
15:29 dalek rakudo-js:
15:29 dalek rakudo-js: That makes standalone nqp pass all tests up to 31.
15:29 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/081f5b0dae
15:29 denis_boyun joined #perl6
15:29 timotimo very cool! :)
15:30 TimToady pmurias++ for persistence
15:31 colomon pmurias++ indeed!
15:32 dylanwh joined #perl6
15:33 geekosaur joined #perl6
15:33 daxim_ pmurias, README.markdown =~ s/    nqp install/    npm install/g
15:36 pmurias daxim_: thanks
15:38 araujo joined #perl6
15:39 timotimo it may be enough to teach QAST::Operations to annotate "returns" everywhere.
15:40 timotimo also, it seems like that may already be the case
15:41 timotimo yes, the return types are already annotated to the ops by Operations
15:41 timotimo in that case there must be something stopping the inliner from seeing that, or alternatively from compiling it down to the most efficient form
15:43 * diakopter is to the point of fighting actual gc bugs
15:43 timotimo in what backend?
15:44 diakopter nwc10: turns out a global destruction phase is enormously helpful for revealing all the things your gc miss
15:44 diakopter missed
15:44 diakopter (if you didn't have one prior)
15:45 TimToady much like sink context is really great for figuring out when you're throwing away side effects
15:45 diakopter and now that it's actually running every time..... o_O
15:45 TimToady er, non-side-effects
15:46 dalek rakudo-js: 8055716 | (Pawel Murias)++ | README.markdown:
15:46 dalek rakudo-js: We install node modules using npm instead of nqp ;). daxim++
15:46 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/80557160b0
15:47 TimToady r: +42; 43;
15:47 camelia rakudo f86a1a: OUTPUT«WARNINGS:␤Useless use of "+" in expression "+42" in sink context (line 1)␤»
15:47 TimToady r: 42; 43;
15:47 camelia rakudo f86a1a: OUTPUT«WARNINGS:␤Useless use of constant integer 42 in sink context (line 1)␤»
15:48 TimToady that is how a majority of precedence errors are caught, actually....
15:48 masak nice.
15:48 TimToady and why sink context is not going away
15:49 * masak .oO( we're certainly not pouring sink context down the... oh wait )
15:51 diakopter the problem with flooding algorithms is... glug glug glug ___
15:52 TimToady btw, we finally heard back from tchrist, who only got his basement flooded, though two people drowned really close to his house
15:55 * masak likes refactors where the number of deletions are > 2x the number of insertions
15:56 masak it's interesting. the refactor commits themselves are nice when they delete a lot. *after* a refactor, things are the nicest when it's all insertions and no deletions.
15:56 * diakopter deletes masak temporarily
15:57 TimToady my current feeling on lift is that it's probably going away in favor of something more explicit to declare what has to be copied from the caller (if it's not identical), some kind of implicit parameter roughly equivalent to &infix:<+> = CALLER::<&infix:<+>>
15:59 TimToady and kinda fitting in with the notion of macros with mixed normal and ASTish args
16:00 TimToady only in this case the strange arg is not AST, but an implicit ref to the caller's lexpad
16:01 TimToady sort of a shortcut for COMPILING thingies
16:02 TimToady haven't made up my mind whether they should be declared on the proto or on/in the multis yet
16:03 TimToady much like we've discussed having an AST token marker like ¤ or some such, we could have a token marker that implied it was from COMPILING
16:03 TimToady but then the compiler would have to hoist that info up to the proto to be available at the right time
16:06 * masak listens, and thinks
16:09 TimToady since protos are nearly always inlined, it's the right place to do the work just before dispatch, if work is needed
16:09 dalek Perlito/replito: 171ea16 | (Flavio S. Glock)++ | / (3 files):
16:09 dalek Perlito/replito: Perlito5 - js - next/redo/return in term position
16:09 dalek Perlito/replito: review: https://github.com/fglock/Perlito/commit/171ea166c3
16:09 dalek Perlito/replito: c701f67 | (Flavio S. Glock)++ | / (4 files):
16:09 dalek Perlito/replito: Perlito5 - grammar - alfanumeric quoting delimiters
16:09 dalek Perlito/replito: review: https://github.com/fglock/Perlito/commit/c701f67a20
16:09 dalek Perlito/replito: 9f2a707 | (Flavio S. Glock)++ | t5/01-perlito/030-num.t:
16:09 dalek Perlito/replito: Perlito5 - grammar - tests
16:09 dalek Perlito/replito: review: https://github.com/fglock/Perlito/commit/9f2a707f26
16:09 dalek Perlito/replito: 657299a | (Flavio S. Glock)++ | / (3 files):
16:09 dalek Perlito/replito: Perlito5 - grammar - format() tweak
16:09 dalek Perlito/replito: review: https://github.com/fglock/Perlito/commit/657299a41e
16:09 dalek Perlito/replito: 0164c28 | (Stanislaw Pusep)++ | / (7 files):
16:09 dalek Perlito/replito: Merge branch 'master' into replito
16:09 dalek Perlito/replito: review: https://github.com/fglock/Perlito/commit/0164c28f72
16:10 TimToady there's also something funky in the current model about redispatching to the same candidate list, when we know we really want the concrete semantics after conversion
16:10 TimToady though perhaps it's the right way to think of it when type inference can weed out the abstract candidates
16:11 * TimToady is also wonder how much we'd gain from duplicating some of the hotpath method code into functions for well-known types
16:11 TimToady *ders
16:11 TimToady *dering even
16:12 timotimo "replito", eh?
16:12 TimToady kinda silly to do method dispatch for indexing into native arrays of known shape, for instance
16:26 iSlug joined #perl6
16:36 spider-mario joined #perl6
16:36 daxim_ http://www.reddit.com/r/perl/comments/1mlaqi/rakudo_and_nqp_internals_2_day_workshop/ccbr5k1  # "Do you think all of that potential flexibility in the language would make it susceptible to The Lisp Curse?"
16:38 kaleem joined #perl6
16:38 masak wow, a reddit thread about one of Edument's courses. that's... a weird feeling.
16:38 masak but in a good way, I think. :)
16:39 masak by the way, I think there's a gigantic under-usage of NQP so far as a compiler development toolchain.
16:39 masak maybe the availability of this course (and the weekend itself, of course) will change that balance a bit.
16:43 TimToady hoelzro: your <3 example should output ❤ or some such to demo Unicode :)
16:43 abelfourier_ joined #perl6
16:47 abelfourier_ left #perl6
16:47 arnsholt masak: Yeah, I've been wanting to come back to my Prolog project on a modern NQP
16:49 arnsholt Especially now that I'm more familiar with the internals, some things like the grammar may end up a bit simpler to implement
16:50 timotimo arnsholt: do you want to have a look at why Algorithm::Viterbi is failing its tests? It can be made compile by removing the type constraint on the slurpy arg (which is not really sensible to have, aiui) and then there decode method returns [Any] :(
16:51 timotimo (but no pressure, i don't need to use it, iwas just looking at the smoker)
16:51 arnsholt I'll give it a look later tonight. I've got some hacking time scheduled =)
16:52 timotimo (i don't even know what viterbi does :P )
16:52 arnsholt It's a simple HMM decoder
16:52 timotimo oh, markov
16:52 arnsholt Hidden Markov Models is a class of statistical model, quite common in NLP and bioinformatics
16:53 timotimo yes, i know about it
16:53 arnsholt "The guts tormented implementers made
16:53 arnsholt =D
16:54 wsri joined #perl6
16:55 masak the tormenting made the guts pretty. :)
16:55 masak at least relatively speaking.
16:56 * arnsholt is sad he didn't make it to RaNIW
16:56 masak r: my @l = 1 .. 100; @l[5 .. *] = Nil; say @l.perl
16:56 camelia rakudo f86a1a: OUTPUT«Array.new(1, 2, 3, 4, 5, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, A…»
16:56 masak how do I truncate a list in Perl 6?
16:57 masak er, an array.
16:58 timotimo : my @l = 1 .. 100; @l[5 .. *] = []; say @l.perl
16:58 timotimo r: my @l = 1 .. 100; @l[5 .. *] = []; say @l.perl
16:58 camelia rakudo f86a1a: OUTPUT«Array.new(1, 2, 3, 4, 5, [], Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, Any, An…»
16:58 timotimo even worse :D
16:58 TimToady er, splice?
16:59 TimToady r: my @l = 1..100; @l.end = 5; say @l
16:59 camelia rakudo f86a1a: OUTPUT«Cannot modify an immutable value␤  in block  at /tmp/_274Q2bvf2:1␤␤»
16:59 apejens joined #perl6
16:59 TimToady heh
16:59 TimToady r: my @l = 1..100; @l.splice(5); say @l
16:59 camelia rakudo f86a1a: OUTPUT«1 2 3 4 5␤»
17:00 TimToady masak: ^^
17:01 masak ah, 'course. :)
17:01 masak TimToady++
17:05 masak r: my @l = 1..100; @l.splice(5, *, "something borrowed", "something blue"); say @l
17:05 camelia rakudo f86a1a: OUTPUT«Cannot call 'Real'; none of these signatures match:␤:(Mu:U \v: Mu *%_)␤  in method Real at src/gen/CORE.setting:929␤  in sub infix:<<> at src/gen/CORE.setting:4167␤  in sub infix:<<> at src/gen/CORE.setting:4165␤  in method splice at src/gen/CORE.setting:7869␤ …»
17:05 masak splice I am dissapoint.
17:05 * masak submits rakudobug
17:05 masak r: my @l = 1..100; @l.splice(5, 100, "something borrowed", "something blue"); say @l
17:05 camelia rakudo f86a1a: OUTPUT«1 2 3 4 5 something borrowed something blue␤»
17:06 masak if * isn't spec'd to work in that place, it clearly should be :)
17:07 * TimToady plays a voluntary on his pipe organ
17:08 * diakopter undeletes masak
17:10 jeff_s1 joined #perl6
17:15 ajr joined #perl6
17:15 domidumont joined #perl6
17:17 timotimo holy ⊂Δℝ∂ℕ
17:17 timotimo masak: how would you like a 2x faster ufo?
17:19 arnsholt That sounds very interesting. How'd you get it sped up?
17:19 timotimo i figured out that the longest time is spent in dependencies
17:19 timotimo and then i replaced matching against every line (gather for $file.lines()) with a slurp + comb
17:21 rindolf joined #perl6
17:21 masak timotimo: ooh
17:21 arnsholt Reading the slides from RaNIW, I'm reminded of the perl6/nqpbook repository
17:21 timotimo i'm preparing a patch
17:22 arnsholt These slides would make a good starting point for an NQP book, I think
17:23 timotimo people already said that :)
17:23 arnsholt I missed that (not being at the workshop, presumably)
17:24 lizmat back from dinner, off to Elysium&
17:24 timotimo masak: https://gist.github.com/timo/27238331623f70f69455
17:24 timotimo gotta run now
17:26 dalek ufo: 18a5e5a | (Timo Paulssen)++ | bin/ufo:
17:26 dalek ufo: speed up dependency calculation by a whole lot.
17:26 dalek ufo: review: https://github.com/masak/ufo/commit/18a5e5a1fa
17:26 masak timotimo: applied; thanks.
17:35 sqirrel joined #perl6
17:35 hoelzro TimToady: I thought I could also create an operator with a Unicode heart, but maybe that's overkill =)
17:36 TimToady well, hipsters relate to <3
17:36 hoelzro heh
17:36 TimToady one kinda wants to show both
17:36 TimToady and in particular, <3 as an operator demonstrates longest token matching
17:36 timotimo ^ is begin of line right?
17:37 TimToady ^ is beg of string
17:37 TimToady ^^ is beg of line
17:37 timotimo otherwise the speedup would be caused by skipping all but the first line
17:37 timotimo dang, that was a dumb optimisation
17:38 timotimo can you look if it is still faster with ^^?
17:38 btyler joined #perl6
17:38 masak nope. :)
17:38 masak reverting commit.
17:39 timotimo otherwise please let us pretend that never happened
17:39 timotimo mind force pushing the previous commit over that? :s
17:39 dalek ufo: 60bb438 | masak++ | bin/ufo:
17:39 dalek ufo: Revert "speed up dependency calculation by a whole lot."
17:39 dalek ufo:
17:39 dalek ufo: Turns out it shouldn't have been ^ but ^^. The merits of the optimization are
17:39 dalek ufo: therefore slightly suspect.
17:39 dalek ufo:
17:39 dalek ufo: This reverts commit 18a5e5a1fa77a58abcf39e0aa008a11cd28e5b94.
17:39 dalek ufo: review: https://github.com/masak/ufo/commit/60bb438ec0
17:39 masak timotimo: yes, I mind :)
17:40 timotimo nooooo my failure to grasp basic regex is on display for all to see!
17:40 masak better pile a bunch of commits on top of it, then...
17:40 benabik Hm.  Apple "updated" /usr/bin/gcc to clang.  I'm sure this will cause no problems anywhere.
17:41 timotimo quickly invent new features forbufo!
17:41 TimToady benabik: do you mean that when you run /usr/bin/gcc it actually gets you clang?
17:41 timotimo benabik, apple does what everybody wants
17:42 benabik TimToady: `gcc -v` gives me "Apple LLVM version 5.0 (clang-500.2.76) (based on LLVM 3.3svn)"
17:42 timotimo or rather, what apple does, everybody wants
17:42 benabik This is apparently a "feature" of XCode 5.
17:42 TimToady benabik: does it run in a gcc emulation mode?
17:42 geekosaur llvm-gcc is gone as of xcode 5
17:42 tba joined #perl6
17:43 benabik TimToady: No idea.
17:43 benabik geekosaur: "Funny" that `man gcc` still says its llvm-gcc.
17:44 geekosaur people have also been noticing that installing xcode5 doesn't autoremove the old command line tools, whereas older versions tend to at least disable them
17:44 timotimo glad i thought to SK
17:44 timotimo ask about my change...
17:45 stevan_ joined #perl6
17:46 stevan__ joined #perl6
17:46 TimToady .u ᔉ
17:46 yoleaux U+1509 CANADIAN SYLLABICS MOOSE-CREE SK [Lo] (ᔉ)
17:47 * sjohnson wonders when unicode trollface will appear...
17:48 TimToady .u ????
17:48 yoleaux U+1F42A DROMEDARY CAMEL [So] (????)
17:50 sjohnson .u trollface
17:50 yoleaux No characters found
17:50 sjohnson =(
17:50 benabik .u troll
17:50 yoleaux U+1F68E TROLLEYBUS [So] (????)
17:51 benabik All aboard the Trolly-bus.
17:51 GlitchMr sjohnson, copyright
17:51 TimToady .u ????
17:51 yoleaux U+1F385 FATHER CHRISTMAS [So] (????)
17:52 TimToady .u ????
17:52 yoleaux U+1F479 JAPANESE OGRE [So] (????)
17:52 sjohnson ... if they have those...
17:54 TimToady still no butterfly
17:54 GlitchMr Carlos Ramirez would sue Unicode if they would add Trollface to Unicode.
17:55 TimToady well, unless you count 蝶
17:59 GlitchMr .u 蝶
17:59 yoleaux No characters found
18:01 GlitchMr It's butterfly, isn't it?
18:01 GlitchMr I would rather expect something like "troll" instead.
18:01 GlitchMr Or invalid Unicode character.
18:02 diakopter .u roll
18:02 yoleaux U+1F3A2 ROLLER COASTER [So] (????)
18:02 yoleaux U+1F5DE ROLLED-UP NEWSPAPER [So] (????)
18:02 diakopter .u cinnamon
18:02 yoleaux No characters found
18:02 GlitchMr .u perl
18:02 yoleaux No characters found
18:02 diakopter .u masak
18:02 yoleaux No characters found
18:02 diakopter .u toad
18:02 yoleaux ...
18:02 GlitchMr lolmasak
18:02 diakopter .u toad
18:02 yoleaux ...
18:02 GlitchMr ...
18:02 benabik ... ?
18:02 diakopter .u foad
18:02 yoleaux No characters found
18:02 GlitchMr .u what
18:02 yoleaux ...
18:02 GlitchMr .u ...
18:02 yoleaux U+002E FULL STOP [Po] (.)
18:02 timotimo no .u
18:02 diakopter .u .u
18:02 yoleaux U+002E FULL STOP [Po] (.)
18:02 yoleaux U+0075 LATIN SMALL LETTER U [Ll] (u)
18:03 diakopter .u yoleaux
18:03 yoleaux No characters found
18:03 diakopter .u character
18:03 yoleaux U+0009 CHARACTER TABULATION [Cc] (␉)
18:03 yoleaux U+0088 CHARACTER TABULATION SET [Cc] (<control>)
18:03 yoleaux U+0089 CHARACTER TABULATION WITH JUSTIFICATION [Cc] (<control>)
18:03 GlitchMr .u a
18:03 yoleaux U+0061 LATIN SMALL LETTER A [Ll] (a)
18:03 GlitchMr .u small
18:03 yoleaux U+0061 LATIN SMALL LETTER A [Ll] (a)
18:03 yoleaux U+0062 LATIN SMALL LETTER B [Ll] (b)
18:03 yoleaux U+0063 LATIN SMALL LETTER C [Ll] (c)
18:03 TimToady ahem
18:03 GlitchMr U+0064 LATIN SMALL LETTER D [Ll] (d)
18:03 benabik You can use privmsg to play "poke the bot".
18:04 TimToady besides, tormenting unicode is more fun than tormenting the bot
18:05 sjohnson **COMPUTING**
18:05 diakopter .u blood
18:05 yoleaux U+2F8E KANGXI RADICAL BLOOD [So] (⾎)
18:05 diakopter .u bik
18:05 sjohnson .u marijuana
18:05 yoleaux U+1F459 BIKINI [So] (????)
18:05 yoleaux No characters found
18:05 diakopter oops.
18:05 sjohnson you'd think there'd be a pot-leaf by now...
18:05 diakopter .u 420
18:05 yoleaux No characters found
18:05 GlitchMr .u nothing
18:05 yoleaux No characters found
18:05 GlitchMr .u mu
18:05 yoleaux U+00D7 MULTIPLICATION SIGN [Sm] (×)
18:05 yoleaux U+039C GREEK CAPITAL LETTER MU [Lu] (Μ)
18:05 yoleaux U+03BC GREEK SMALL LETTER MU [Ll] (μ)
18:06 GlitchMr μ is new Mu in Perl 6!
18:06 GlitchMr s/720/6/
18:07 TimToady well, no, Mu is really 無
18:07 GlitchMr .u 無
18:07 yoleaux No characters found
18:07 GlitchMr Of course I know.
18:08 GlitchMr .u moo
18:08 yoleaux U+14A8 CANADIAN SYLLABICS MOO [Lo] (ᒨ)
18:08 yoleaux U+14A9 CANADIAN SYLLABICS Y-CREE MOO [Lo] (ᒩ)
18:08 yoleaux U+1509 CANADIAN SYLLABICS MOOSE-CREE SK [Lo] (ᔉ)
18:09 GlitchMr Alternatively, it's U+14A8.
18:11 TimToady no, moo is 牟
18:11 TimToady note the cow radical on the bottom
18:11 sjohnson cow!
18:11 GlitchMr .u 牟
18:11 yoleaux No characters found
18:12 sjohnson TimToady: you seem to have a lot of clout.  do you think a unicode comission could be persuaded to add a character in?
18:12 corecatcher what bottom? (of that char)
18:13 GlitchMr Unicode? Why? Everybody needs 27 characters anyway (a-z, and space).
18:13 TimToady u cow
18:13 TimToady .u cow
18:13 yoleaux U+2EA7 CJK RADICAL COW [So] (⺧)
18:13 yoleaux U+2F5C KANGXI RADICAL COW [So] (⽜)
18:13 yoleaux U+1008C LINEAR B IDEOGRAM B109F COW [Lo] (????)
18:13 masak corecatcher: the bottom four(ish) strokes.
18:13 TimToady that part
18:13 GlitchMr who uses these unicode characters anyway when you can talk just using spaces and letters
18:13 TimToady
18:14 benabik Radio has taught me you only need ..---
18:14 geekosaur ob http://en.wikipedia.org/wiki/Whitespace_(programming_language)
18:14 GlitchMr But don't we already use 0s and 1s.
18:14 flussence joined #perl6
18:14 TimToady besides, those *are* letters :)
18:15 TimToady r: say "無" ~~ /\w/
18:15 camelia rakudo f86a1a: OUTPUT«「無」␤␤»
18:15 TimToady r: say so "無" ~~ /\w/
18:15 camelia rakudo f86a1a: OUTPUT«True␤»
18:15 GlitchMr r: sub infix:[""]($a, $b) { $a ~ $b }; say "hello" "world"
18:15 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤No such method 'ast' for invocant of type 'NQPMu'␤»
18:16 GlitchMr NQPMu? Great errors.
18:16 GlitchMr n: sub infix:[""]($a, $b) { $a ~ $b }; say "hello" "world"
18:16 camelia niecza v24-95-ga6d4c5f: OUTPUT«helloworld␤»
18:16 ajr joined #perl6
18:16 GlitchMr http://www.stroustrup.com/whitespace98.pdf
18:16 GlitchMr Why Perl 6 allows overwriting almost any operator other than whitespace?
18:16 TimToady std: sub infix:[""]($a, $b) { $a ~ $b }; say "hello" "world"
18:16 FROGGS joined #perl6
18:16 camelia std 7c17586: OUTPUT«[31m===[0mSORRY![31m===[0m�Null operator is not allowed at /tmp/28HOvVCczV line 1:�------> [32msub infix:[""][33m�[31m($a, $b) { $a ~ $b }; say "hello" "world[0m�Parse failed�FAILED 00:00 42m�»
18:17 GlitchMr Yeah, I know it's an error.
18:17 GlitchMr I mean, I checked it one year ago or something.
18:17 masak whitespace isn't an operator.
18:17 GlitchMr Nice to see Rakudo sort of fixing it (but error should be better).
18:17 TimToady it screws up the self-clocking
18:18 masak well, except in slangs, like Regex... hm.
18:18 TimToady where, you'll note, people are always getting unexpected results instead of errors
18:19 masak that's because "failure is not an option" in regex land.
18:19 GlitchMr In awk, nothing is concatenation. Why Perl 6 cannot have it as concatenation if you really want (and have huge failures when code would accidentally trigger TTIAR).
18:19 masak in the sense that the worst that can happen is that the regex doesn't match.
18:19 TimToady n: / 'a' 1 .. 3 /
18:19 camelia niecza v24-95-ga6d4c5f: ( no output )
18:19 TimToady std: / 'a' 1 .. 3 /
18:19 camelia std 7c17586: OUTPUT«ok 00:00 42m␤»
18:19 TimToady oops
18:20 TimToady n: / 'a' ** 1 .. 3 /
18:20 camelia niecza v24-95-ga6d4c5f: OUTPUT«[31m===[0mSORRY![31m===[0m��Spaces not allowed in bare range at /tmp/bZTzAZqS0b line 1:�------> [32m/ 'a' ** 1 ..[33m�[31m 3 /[0m��Parse failed��»
18:20 TimToady that's trying to dwimmily make up for a term vs operator confusion, but it can result in a WAT
18:21 GlitchMr r: class LyingStr #`(on the floor) { method Str { die "no" } }; my LyingStr $str .= new; say "abc" =~ / $str /
18:21 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/InmL1g64EY�Unsupported use of =~ to do pattern matching; in Perl 6 please use ~~�at /tmp/InmL1g64EY:1�------> [32m}; my LyingStr $str .= new; say "abc" =~[33m�[31m / $str /[0m�»
18:21 GlitchMr r: class LyingStr #`(on the floor) { method Str { die "no" } }; my LyingStr $str .= new; say "abc" ~~ / $str /
18:21 camelia rakudo f86a1a: OUTPUT«no␤  in method Str at /tmp/MQiFSSAHxG:1␤  in block  at src/gen/CORE.setting:12294␤  in method reify at src/gen/CORE.setting:7357␤  in method reify at src/gen/CORE.setting:7252␤  in method gimme at src/gen/CORE.setting:7675␤  in method sink at src/gen/CORE.setti…»
18:21 GlitchMr Failure is an option.
18:21 * masak tries to picture a regex slang without juxtaposition as an operator
18:21 masak GlitchMr: way to completely miss my point.
18:21 TimToady comma maybe
18:22 masak well, I imagine one'd end up with something that looks like nested function calls.
18:22 GlitchMr It's runtime error.
18:22 masak or combinators.
18:22 sjohnson .u tank
18:22 yoleaux No characters found
18:22 sjohnson 点 (tank)
18:22 TimToady masak: no, the worst is that it matches the wrong way
18:22 GlitchMr No, the worst is that the regex engine will trigger undefined behavior, and format your hard drive.
18:23 TimToady well, that's just a bug :)
18:25 TimToady sjohnson: that would be a four-legged tank
18:26 sjohnson TimToady: ah, no wonder I couldn't find it on .u
18:26 flussence 点 (U+70B9 HORSEBACK ARCHER)
18:28 flussence .oO( right next to U+70BB PERCUSSIVE MAINTENANCE and U+70BD SLIDESHOW PRESENTATION )
18:28 TimToady 覀 flying tank with two guns
18:28 masak sjohnson: the current meaning of that characer is "dot" or "speck".
18:29 GlitchMr .u undef
18:29 yoleaux No characters found
18:29 GlitchMr .u beha
18:29 yoleaux No characters found
18:29 masak TimToady: clearly that's a monster from Space Invaders.
18:29 GlitchMr .u c
18:29 yoleaux U+0063 LATIN SMALL LETTER C [Ll] (c)
18:30 GlitchMr .u ≠
18:30 yoleaux U+2260 NOT EQUAL TO [Sm] (≠)
18:30 GlitchMr .u π
18:30 yoleaux U+03C0 GREEK SMALL LETTER PI [Ll] (π)
18:34 iSlug joined #perl6
18:36 sjohnson masak: tank is cuter!
18:37 spider-mario joined #perl6
18:39 masak sjohnson: yeah... in the same way я is "cuter" as a reverse R. unless, you know, you read Cyrillic, in which case it's mostly annoying. :)
18:39 masak I guess I'm a bit too invested in the actual meanings of the hanzi to see then as mere icons at this point.
18:40 masak that said, at one point I collected hanzi that looked like telephone poles. :)
18:41 arnsholt I have a similar relationship to misuse of Greek and Cyrillic characters in movie posters and the like
18:41 arnsholt I can read them, but there's that niggling "but that's wrong!" dissonance
18:42 geekosaur same
18:43 masak arnsholt: my first reading is almost always the actual sounds of the characters. which, needless to say, seldom works.
18:43 masak arnsholt: I generally don't enjoy graphic embellishments that rely on the reader's ignorance.
18:44 EvanTeitelman joined #perl6
18:50 spider-mario joined #perl6
18:55 stevan_ joined #perl6
18:58 lue hello world o/
18:58 arnsholt Heh. The OPP is "mildly terrifying"
18:59 arnsholt The PIR version was really terrifying =)
19:01 TimToady well, it's really almost a standard OPP, except it has to concepts like list associativity too
19:02 TimToady and most OPPs do the minimum for a given language, rather than trying to stay extensible in the face of new precedence levels or conflicting assiciativities on unaries
19:02 TimToady *assoc
19:04 TimToady I dunno whether anyone has talked about list associativity before; I was ignoring the literature when I came up with that...
19:05 masak TimToady: Python has chaining operators, but it doesn't have a name for that kind of associativity.
19:05 TimToady seems like too useful a concept not to have been invented before...
19:05 TimToady well, chaining is another one, but lots of languages do that
19:06 masak oh? I wasn't aware.
19:06 masak I only know of Perl 6 and Python.
19:06 TimToady well, at least they accept the mathish comparisons
19:06 SamuraiJack_ joined #perl6
19:06 TimToady in the case of Icon, they fake it by separating the concept of success from the return value
19:07 TimToady but I always thought that was a fairly user-unfriendly way to do it
19:09 benabik joined #perl6
19:10 TimToady BCPL apparently had it
19:11 geekosaur it's not actually separated from the return value; it's a distinct return value, but &fail is a little too eager for direct use :)
19:13 stevan_ joined #perl6
19:14 masak to be honest, I use chained comparisons a lot less than I thought I would.
19:15 masak when you see the feature on paper the first time, the tendency is to go "ooh, that's nice; yes, of course it should work that way".
19:15 masak and when I use it, it's rather nice.
19:15 masak but the advantages aren't as great as I imagined. nor are the occasions for using chaining.
19:15 TimToady well, some of its use has been usurped by ~~ $range
19:15 masak aye.
19:16 TimToady esp since ranges can exclude either endpoint
19:16 TimToady and usually the range data comes in paired up already somehow
19:17 TimToady so <= < would have to split it up
19:17 TimToady nevertheless, 0 <= $n < $max is a very normal thing to see
19:18 TimToady and makes the mathematicians feel slightly welcome
19:18 TimToady oh, Mathematica is another chaining language, I guess
19:19 GlitchMr r: 3 ~~ ^3
19:19 camelia rakudo f86a1a: ( no output )
19:19 GlitchMr r: say 3 ~~ ^3
19:19 camelia rakudo f86a1a: OUTPUT«False␤»
19:19 GlitchMr r: say 0 ~~ ^3
19:19 camelia rakudo f86a1a: OUTPUT«True␤»
19:19 GlitchMr r: say 0.5 ~~ ^3
19:19 camelia rakudo f86a1a: OUTPUT«True␤»
19:19 GlitchMr I probably codegolfed too much.
19:20 TimToady chaining also means we can have reductions like [<]
19:21 GlitchMr And there is Ruby, where you can say (0...3) === 3 (with odd order of operations, === isn't associative in Ruby).
19:22 TimToady well, Perl 6 has refrained from borrowing lots of half-though-out features from lots of languages...
19:22 TimToady *thought
19:23 TimToady we have plenty of our own half-thought-out ideas :)
19:23 GlitchMr === is mostly like ~~ in Perl 6, except it accepts operators in different order.
19:23 GlitchMr irb(main):001:0> String === "abc"
19:23 GlitchMr => true
19:23 TimToady yes, well, that makes an endweight problem
19:24 TimToady most patterns are longer than the things they're matching against
19:24 GlitchMr Yeah, the triple equals operator in Ruby annoys me.
19:24 * TimToady kinda wishes that xx were in the opposite order
19:25 TimToady (sometimes)
19:26 TimToady and kinda wishes that regex quantifiers came in the front
19:26 arnsholt I guess the Lispers would appreaciate prefix notation =)
19:26 arnsholt Modulo spelling
19:27 masak TimToady: I guess technically you could have reductions without having (syntactically explicit) chaining.
19:27 masak but having both is more consistent, of course.
19:27 TimToady well, we'd have to give up our pseudo-syntactic definition
19:27 TimToady which is of great pedagogical value
19:28 masak TimToady: just use Rxx ;)
19:28 TimToady upon occasion I have :)
19:28 GlitchMr I think that === in Ruby only considers (by default, you can overload operators in Ruby) ranges, regular expressions, and classes specifically, otherwise standard == is used (which works like eqv in Perl 6).
19:28 TimToady R/ pops up on RC with some regularity :)
19:29 GlitchMr The reason for the strange order is that in Ruby you can only overload first argument. So they to introduce such hack (why not accepts method, or something).
19:29 TimToady the problem with Ruby is not that everything is an object, but that everything is single dispatch :)
19:30 TimToady and trying to rescue lexical scoping of language tweaks by changing mro on the fly is just a recipe for disaster, I think
19:31 GlitchMr Lexical scope in Ruby (and CoffeeScript which copied it) is a joke.
19:31 GlitchMr Adding irrelevant variable declaration in scope above changes the scope of variable declared in function.
19:32 * TimToady is very glad that p6 finally settled on completely isolating function dispatch from method dispatch
19:32 TimToady except insofar as method dispatch is really function dispatch if you scratch it hard enough
19:32 GlitchMr In my opinion, either declarations should be used, or assignments in scopes should ALWAYS declare new variable.
19:33 GlitchMr (I personally prefer declarations)
19:33 TimToady there's a reason Perl has short declarators :)
19:33 TimToady not as short as C, admittedly :)
19:33 GlitchMr With something you type often, even "var" in JavaScript annoys me.
19:34 GlitchMr But it's better than no declarations.
19:35 TimToady you're preaching to the choir, or in this case, singing to the preacher
19:36 GlitchMr And I find it annoying that CoffeeScript actually considers lack of variable declarations a feature.
19:36 GlitchMr http://coffeescript.org/#lexical-scope
19:36 GlitchMr Their advice to avoid problems: "be careful".
19:37 GlitchMr And there is C#, which does have declarations, and you cannot shadow variables. int variable; { int variable; } is compile time error.
19:37 TimToady .u ????
19:37 yoleaux U+1F4A4 SLEEPING SYMBOL [So] (????)
19:38 zwut00 joined #perl6
19:39 masak GlitchMr: implicitly declared variables is a language design feature I'm kinda surprised people don't dislike more. it's really not a good idea.
19:40 benabik joined #perl6
19:40 masak GlitchMr: I like the journey that Perl has taken there, from completely non-strict, to recommending 'my'.
19:40 GlitchMr I actually would really want CoffeeScript with 'my'.
19:40 GlitchMr I really like CoffeeScript, but the scoping is just broken.
19:42 * hoelzro prefers explicit declaration
19:42 GlitchMr Also, I wonder why many languages that don't have to compilers cannot detect undeclared variables.
19:42 GlitchMr I like how Perl can tell me about undeclared variable compile time.
19:42 GlitchMr In Python, I have to wait until code explodes.
19:43 masak yes, that's what this is all about.
19:43 huf i think it's a result of DWIM gone horrible :)
19:43 huf the intentions are supposedly good, but .. oh well
19:43 masak aye. the corresponding WAT is logical bugs.
19:44 masak and typos going unnoticed.
19:44 GlitchMr ~ $ python -c 'if False: wat'\n'else: print("wat?")'
19:44 GlitchMr wat?
19:44 GlitchMr I don't think declarations are needed to detect such error.
19:45 GlitchMr Python already knows declared builtins, and wat is not a builtin.
19:45 GlitchMr Yet, the problem doesn't appear, because wat is in "if False".
19:45 stevan_ joined #perl6
19:46 lue What if I modify the grammar of Perl 6 so the sigil of a variable does a  my  declaration of the name if it doesn't exist before continuing? >:)
19:46 GlitchMr lue, why you want to remove feature that helps detecting bugs.
19:46 masak lue: all is fair if you predeclare.
19:46 GlitchMr Also, I think it's possible according to Perl 6 specification, by using 'no strict'.
19:46 masak lue: just don't expect me to use your module :)
19:47 masak ...which is still on by default in -e, IIRC.
19:47 masak (by spec, I mean)
19:47 GlitchMr I actually use -Mstrict for oneliners.
19:48 masak me too, most of the time.
19:48 GlitchMr I have a shell function declared that automatically prepends -Mstrict and -w, if Perl is ran with -e or -E flag.
19:48 lue .oO(Bonus points: Make a doubling of the sigil an  our  declaration.  $a = 5  is  my $a = 5  and  $$a = 42  is  our $a = 42. I think I just came up with use Perl6::Corrupted)
19:49 GlitchMr Double sigil would be confusing for Perl 5 users.
19:50 lue OK... how about a sigil suffix? $a$ = 42 is our $a = 42 :D
19:50 timotimo and add a twigil $ for good measure
19:50 GlitchMr I think macro could do it.
19:51 lue The problem with all my module ideas, they always end up requiring slangs :/
19:51 GlitchMr r: sub postfix:<$>($variable) { quasi { our {{{$variable}}} } }
19:51 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/9dg2x_dQa4â�¤Malformed ourâ�¤at /tmp/9dg2x_dQa4:1â�¤------> [32mub postfix:<$>($variable) { quasi { our [33mâ��[31m{{{$variable}}} } }[0mâ�¤    expecting any of:â�¤        scoped declaratorâ�¤Â»
19:51 GlitchMr Or not
19:51 GlitchMr I cannot use our in quasi?
19:51 lue GlitchMr: try "macro" instead of "sub"
19:52 GlitchMr oh
19:52 * lue should perhaps finish reading the NQP slides, and then perhaps someday implement slangs
19:52 GlitchMr r: macro postfix:<$>($variable) { quasi { our $::({{{$variable}}}) } }
19:52 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/9xQL9r1LTw�Cannot declare a variable by indirect name (use a hash instead?)�at /tmp/9xQL9r1LTw:1�------> [32mable) { quasi { our $::({{{$variable}}})[33m�[31m } }[0m�»
19:53 timotimo marcos aren't easy :(
19:53 lue r: macro postfix:<$>($variable) { quasi { our ${{{$variable}}} } }
19:53 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/FNBKwaANDF�Unsupported use of ${{{$variable}; in Perl 6 please use $({{$variable)�at /tmp/FNBKwaANDF:1�------> [32m($variable) { quasi { our ${{{$variable}[33m�[31m}} } }[0m�»
19:53 timotimo haha, wat :D
19:53 GlitchMr $({{$variable)
19:53 GlitchMr Great hints!
19:53 GlitchMr I've a feeling that parsing went wrong.
19:53 GlitchMr std: macro postfix:<$>($variable) { quasi { our ${{{$variable}}} } }
19:53 camelia std 7c17586: OUTPUT«ok 00:01 54m␤»
19:53 GlitchMr wat?
19:53 lue $({{$var) ‽ o.o
19:54 lue r: macro postfix:<$>($variable) { quasi { our $({{$variable) } }
19:54 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/iFbPqZAaPKâ�¤Unable to parse expression in block; couldn't find final '}'â�¤at /tmp/iFbPqZAaPK:1â�¤------> [32m>($variable) { quasi { our $({{$variable[33mâ��[31m) } }[0mâ�¤    expecting any of:â�¤        postfi…»
19:54 GlitchMr std: macro postfix:<$>($variable) is rw { quasi { $::({{{$variable}}}) } }
19:54 camelia std 7c17586: OUTPUT«ok 00:01 58m␤»
19:54 GlitchMr std: macro postfix:<$>($variable) is rw { quasi { $::({{{$variable}}}) } }; $lol$ = 42;
19:54 camelia std 7c17586: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable $lol is not predeclared at /tmp/IN7lOGZR6S line 1:�------> [32m rw { quasi { $::({{{$variable}}}) } }; [33m�[31m$lol$ = 42;[0m�Check failed�FAILED 00:01 59m�»
19:56 lue r: macro postfix:<$>($variable) { quasi { our {{{$variable}}} } }
19:56 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmM9yRYIIbâ�¤Malformed ourâ�¤at /tmp/tmM9yRYIIb:1â�¤------> [32mro postfix:<$>($variable) { quasi { our [33mâ��[31m{{{$variable}}} } }[0mâ�¤    expecting any of:â�¤        scoped declaratorâ�¤Â»
19:57 GlitchMr std: macro postfix:<$>($variable) { quasi { our {{{$variable}}} } }
19:57 camelia std 7c17586: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Malformed our at /tmp/FcNzAYfP_n line 1:â�¤------> [32mro postfix:<$>($variable) { quasi { our [33mâ��[31m{{{$variable}}} } }[0mâ�¤    expecting any of:â�¤      nameâ�¤   scoped declaratorâ�¤Parse failedâ�¤FAILED 00:01 52mâ�¤Â»
19:58 lue r: macro postfix:<$>($variable) { quasi { {{{our $variable}}} } }; $lol$ = 42; say $lol; # so close :)
19:58 camelia rakudo f86a1a: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tiv2uxomqTâ�¤Variable '$lol' is not declaredâ�¤at /tmp/tiv2uxomqT:1â�¤------> [32m{ quasi { {{{our $variable}}} } }; $lol$[33mâ��[31m = 42; say $lol; # so close :)[0mâ�¤    expecting any of:â�¤        postfixâ�¤â€¦Â»
19:58 ksh joined #perl6
20:02 masak lue: that won't fly -- the parser still wants the variable to be declared at the point it sees it.
20:02 masak I think eventually you will be able to inject variables into a scope the way you want.
20:03 masak but it definitely doesn't work in Rakudo at this point.
20:03 lue .oO(And this is where slangs come in handy)
20:04 GlitchMr r: sub infix:[/\$\w+\$/] { say "Test" }; $aaaa$
20:04 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤No such method 'ast' for invocant of type 'NQPMu'␤»
20:04 GlitchMr r: sub infix:[/\$\w+\$/] { say "Test" };
20:04 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤No such method 'ast' for invocant of type 'NQPMu'␤»
20:11 masak no, you can't use [] after infix:
20:12 nwc10 diakopter: :-)
20:16 lue r: sub infix:["@"] ($a, $b) { "$a@$b" }; say "me"@"server"
20:16 camelia rakudo f86a1a: OUTPUT«===SORRY!===␤No such method 'ast' for invocant of type 'NQPMu'␤»
20:16 lue std: sub infix:["@"] ($a, $b) { "$a@$b" }; say "me"@"server"
20:16 camelia std 7c17586: OUTPUT«ok 00:00 48m␤»
20:16 lue std and some of the operator listings in S03 seem to disagree, masak
20:18 masak I may be mistaken.
20:18 masak anyway, feel free to file the LTA error message as a rakudobug.
20:19 lue (although I *am* suspect of using a regex in that position)
20:21 lue It's interesting, but I feel that kind of stuff is already covered by macros and slangs.
20:22 diakopter nwc10: :)
20:26 cjwelborn joined #perl6
20:28 gtodd joined #perl6
20:37 benabik (reading the internals slides)  Does QAST::Regex really expect a lexical $ ?  Or does it expect $/ or $_ ?
20:37 benabik (Day 2, slide 75)
20:39 benabik Ah.  The markdown has $¢
20:41 dalek perl6-roast-data: 6ecfdae | coke++ | / (5 files):
20:41 dalek perl6-roast-data: today (automated commit)
20:41 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/6ecfdaec88
20:41 lue benabik: hadn't gotten there yet. Thanks for the unintentional heads-up :)
20:42 * benabik also submitted an issue.  :-)
20:45 benabik Erm.  "Greedy matching (\d+:), Frugal (\d+?), Ratchet (\d+:)"  Either the first or last is wrong, I think?
20:47 benabik <?alpha> compiles into a zerowidth sub rule of 'ws'?
20:47 lue I don't recall if there was a special token for greedy matching. : definitely makes me think of ratchet as opposed to greediness. (I'm not an expert though)
20:48 diakopter benabik: yeah the first should be ! instead of :
20:49 diakopter In normal regexes, use *:, +:, or ?: to prevent any backtracking into the quantifier. If you want to explicitly backtrack, append either a ? or a ! to the quantifier. The ? forces frugal matching as usual, while the ! forces greedy matching.
20:57 diakopter =======
20:57 ssutch joined #perl6
21:01 krokite joined #perl6
21:05 berekuk joined #perl6
21:10 cognominal joined #perl6
21:12 dalek rakudo/nom: 9658746 | duff++ | docs/release_guide.pod:
21:12 dalek rakudo/nom: minor rewording/reorg
21:12 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/96587469a9
21:12 dalek rakudo/nom: c5ba782 | duff++ | docs/release_guide.pod:
21:12 dalek rakudo/nom: de-emphasize Parrot somewhat
21:12 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c5ba7828aa
21:13 dalek rakudo/method2sub: aea0349 | (Elizabeth Mattijsen)++ | src/core/ (3 files):
21:13 dalek rakudo/method2sub: Some small tweaks, not enough to solve the compilation problem though :-(
21:13 dalek rakudo/method2sub: review: https://github.com/rakudo/rakudo/commit/aea0349680
21:26 Teratogen joined #perl6
21:29 lizmat fg
21:29 diakopter bg
21:34 pmurias joined #perl6
21:34 lizmat ww
21:35 geekosaur .oO ( you disown %1 ? )
21:41 Rotwang1 joined #perl6
21:51 dalek rakudo-js: 62a46b4 | (Pawel Murias)++ | nqp-compiler.nqp:
21:51 dalek rakudo-js: Pass test 51, replace commented out code to create the compilee_list for multis with something we can handle.
21:51 dalek rakudo-js: review: https://github.com/pmurias/rakudo-js/commit/62a46b4489
21:51 colomon joined #perl6
22:06 dalek rakudo/method2sub: 25398b8 | (Elizabeth Mattijsen)++ | src/core/ (2 files):
22:06 dalek rakudo/method2sub: Use "is parcel" everywhere: fixed some ambiguous is rw/is parcel usage
22:06 dalek rakudo/method2sub: review: https://github.com/rakudo/rakudo/commit/25398b8066
22:08 lizmat method2sub branch still fails to compile: https://gist.github.com/lizmat/6644568
22:08 lizmat giving up for now
22:08 lizmat gnight #perl6!
22:10 crocket joined #perl6
22:10 crocket Is perl6 still being change?
22:10 crocket Is perl6 still being changed?
22:11 lue If I understand correctly, most of the design is stable by this point, but there's still quite a few areas that need some additional brainpower behind them.
22:16 crocket lue : Is perl6 ready for production use?
22:16 crocket Or for personal use?
22:16 pmurias personal use?
22:17 crocket pmurias, I personally maintain softwares.
22:18 crocket Things that don't have to scale.
22:18 lue I wouldn't quite say production use yet (I'm not involved enough to make an informed response, so I'll default to "be weary" for now), but you can definitely use it at home for personal scripts.
22:19 diakopter haha weary
22:19 diakopter wary, too
22:19 lue (Again, the guys who actually do intense work on Perl 6 would be more helpful in telling you what Perl 6 (and particularly Rakudo) is fine for at this point.)
22:20 lue diakopter: I think I probably meant wary instead of weary. You mentioning that made me realize I probably am not using wary when I should be, stupid similar spellings and pronunciations. :)
22:20 diakopter :D
22:21 diakopter crocket: perl 6 is ready for early adopters to toy around with
22:21 lue .oO(Also not helping is that wary and weary have almost-identical meanings in my head.)
22:21 diakopter plenty of things could be discovered to work well and be relied upon
22:22 diakopter but generally if you try any particular thing, it probably won't work
22:22 benabik lue: You're wary when you're weary?
22:23 lue benabik: rather weary when I'm wary :)  /me also realized here he probably needs to look up "wary" soon
22:23 benabik lue: weary = tired, wary = cautious.
22:24 ssutch joined #perl6
22:25 lue One very rough and somewhat inaccurate guide to what works in Perl 6 is to look at which Synopsis the feature is described. The higher the S-number, the more likely it's not fully stabilized.
22:26 lue benabik: I think my mind essentially says "When you need to be wary, you'll be weary trying to figure out what passes your suspicions."
22:29 diakopter heh. Synopsis-fatigue
22:29 diakopter synopsebot: help
22:29 synopsebot diakopter: Sorry, this bot has no interactive help.
22:30 diakopter synopsebot: die?
22:30 diakopter synopsebot: restart
22:30 diakopter synopsebot: S6666
22:30 diakopter synopsebot: S6666:6666
22:30 synopsebot diakopter: Link: http://perlcabal.org/syn/S6666.html#line_6666
22:30 lue (so "wary" connotes to me a kind of caution that occurs when you're "tired of all this crap". That connotation probably happened because of the similar spelling and pronunciation in the first place. :D)
22:31 TimToady there is an overtone of "been burned before"
22:31 benabik denotations and connotations of those words are definitely more nuanced than I stated.  :-D
22:32 diakopter gun-shy
22:32 TimToady but "beware" doesn't seem to carry the same overtone, quite
22:32 TimToady well, maybe for the speaker :)
22:32 lue .oO(Why does connotation have no particular connotation for me, yet denotation has a particular denotation?)
22:32 geekosaur wary from aware, which does suggest "aware of past encounters"
22:33 geekosaur whereas *be*ware suggests no (or suspected no) existing awareness
22:33 lue Long story short: Advising someone to "be wary" is the same as advising them to "be weary" in my mind. :)
22:34 geekosaur see, but to me weariness suggests potential lack of awareness due to tiredness...
22:34 TimToady to me it's almost the opposite; you have to be in a state of heightened alertness to be ware
22:35 lue Maybe I'll just invent the word wæry and be done with.
22:35 lue s/\./ it./
22:36 geekosaur (and then of course there's worry...)
22:36 TimToady well, we don't reject you as a person just because your brane works funny...
22:37 lue My 'brane is yours too, according to the theory.
22:37 TimToady Mmm
22:38 lue So: my advice is to be wæry with some of the less-developed features of Perl 6 for now.
22:39 BenGoldberg joined #perl6
22:39 BenGoldberg .ud perl
22:39 yoleaux pur'-el (n)  1. Computer programming language used mostly by male virgins, between the ages of 17 and 35, who are also well versed in the Lord Of The Rings stories.Pratical Extraction and Reporting La
22:41 crocket diakopter, I'm sad.
22:41 diakopter crocket: sad?
22:41 TimToady there are antidepressants for that...
22:41 lue I don't think it's very pratical to consult Urban Dictionary ;)
22:42 crocket yoleaux, male virgins? ha
22:42 crocket diakopter, Perl6 is not ready for its prime time.
22:42 crocket perl5? I don't know.
22:43 diakopter perl5 is past its prime :P
22:43 TimToady crocket: Perl 6's prime time will be for the next few decades, we hope.
22:43 masak 'night, #perl6
22:43 TimToady o/
22:43 lue good ♞, masak o/
22:44 BenGoldberg Why is perl6 not ready for it's prime time?
22:45 TimToady mostly, just not fast enough yet
22:46 lue JVM's fine, so long as you don't mind the startup. And I hear MoarVM is eventually supposed to be really fast (at least when compared to the Norwegian Blue)
22:46 BenGoldberg Norwegian Blue?
22:46 TimToady shh, it's sleeping
22:47 crocket Is MoarVM competing with ParrotVM?
22:47 TimToady in a friendly, duel-to-the-death sort of way
22:47 corecatcher Duel of the fates?
22:48 crocket TimToady, That's a contradiction
22:48 lue It all depends on what we can get from the Notlob pet shop.
22:48 BenGoldberg Once MoarVM is capable of running Rakudo, ParrotVM will probably die.
22:48 * corecatcher tries with jnthn's INIFile grammar
22:48 TimToady crocket: nonsense, you've obviously never read The Three Musketeers
22:49 TimToady or Steven Brust, for that matter...
22:49 corecatcher .. but I'm having problems on iterating over the match object after it all parsed fine, doing sth like my $sections := $m.ast; but nqp complains about a not-iterable
22:49 diakopter BenGoldberg: well, that's a sensitive topic; plenty of people have mixed feelings about it, and lots of time and money and emotions invested and friendships lost
22:50 diakopter (and gained)
22:51 crocket Why is perl6 taking so long to take off? Are people building the next large hedron collider?
22:51 crocket hadron
22:51 TimToady well, it's little like fusion, y'see, except we have more hope of breakeven
22:52 diakopter TimToady: we need to add more adamantium to the mix
22:52 lue .oO(If TimToady threw enough coffee mugs at Perl 5 to kill it for good, perhaps more people would be over here at the moment...)
22:52 diakopter sigh.
22:53 TimToady we're not in the business of telling people what not to use
22:53 lue "If" lacking the connotation of "If only", of course. I was only making a logical (if somewhat surreal) statement.
22:53 TimToady the only way Perl 6 will ever succeed is by being a darn sight better than anthing else around
22:54 TimToady lue: we already have enough people that want to fight, and sufficient problem keeping them docile
22:54 lue Being a 3m-wide butterfly helps in the visibility department. :)
22:55 lue TimToady: yeah, I didn't mean that statement the way it came out. (This error I noticed quite soon after too :/)
22:56 lue (specifically the air of contempt for P5 was not meant. Stupid text, lacking proper emotional cues...)
22:56 TimToady having a 3m-wide butterfly as a mascot is just one of the ways that Perl 6 can be better, sure :)
22:56 crocket hmm
22:56 TimToady but we'd like it to be better in most of the technical ways as well
22:56 crocket Is perl6 planned to become the best language in the contemporary time?
22:56 * corecatcher finally got it working while you had your discourse!
22:57 TimToady it already is, except for the running fast part :)
22:57 crocket I'm not sure how it is.
22:57 crocket Is it even better than clojure?
22:57 TimToady yup :)
22:57 * lue just fell into the habit again of imagining VM bytecodes becoming instruction sets of Actual CPUs™, this time MoarVM
22:57 TimToady but we're known to be prejudiced in the matter
22:58 crocket TimToady : Let me see after 5~10 years.
22:58 lue Well, for example, perl6 -e 'say "Hello World!"' takes about 4 seconds, using Parrot as the VM.
22:59 * lue &
22:59 EvanTeitelman joined #perl6
23:00 TimToady crocket: so you define "better" as "popular"?  :P
23:01 * TimToady was kinda hoping "better" referred to something slightly more fundamental...
23:01 crocket TimToady : clojure is not popular.
23:01 TimToady well, it's got more press at the moment, anyhoo
23:01 crocket Clojure's main goals are beauty and practicality.
23:01 crocket It's a functional concurrent lisp.
23:02 TimToady whereas ours are practicality and beauty
23:02 TimToady whereas we're function and concurrent without the lisp part :)
23:02 TimToady well, lisp syntax, anyway
23:02 crocket TimToady : I'm not sure how perl6 is functional.
23:03 TimToady how do you define it?
23:05 crocket I can't now.
23:05 TimToady Perl 6 is certainly functional in pretty much all the respects that Lisp is
23:05 crocket perl5?
23:05 TimToady to a lesser extent, but it's certainly easy to do higher-order programming in perl 5
23:05 TimToady not as easy as in perl6
23:06 TimToady if you're thinking more in terms of pattern matching of function signatures, then http://rosettacode.org/wiki/Pattern_matching#Perl_6 stands up pretty closely to Haskell
23:06 crocket TimToady : When will perl6 be ready for general purposes?
23:07 crocket 10 years?
23:07 TimToady it's ready for most of them now, as long as one of your general purposes is not speed
23:07 TimToady see http://rosettacode.org/wiki/Category:Perl_6 for 625 examples of that
23:08 TimToady and we're working on the speed part...
23:09 TimToady "10 years" means nothing in isolation
23:10 crocket TimToady : When will it be fast enougH?
23:10 crocket At least, it should be faster than python.
23:10 diakopter soon enough?
23:10 TimToady it's fast enough already, except when it isn't
23:10 TimToady we would like to get faster than python, sure
23:11 TimToady might take another year or so
23:11 diakopter "so"== x3-4
23:12 TimToady and when you say "python", which one are you referring to?
23:12 TimToady they all have different characteristics
23:12 crocket Does perl6 have IDE or emacs support?
23:12 crocket TimToady : I mean Cython.
23:12 crocket Or jython?
23:13 crocket PyPy is just out of question.
23:14 TimToady there's a syntax mode for emacs, though most of us here use vim's perl6 mode
23:14 TimToady the Padre IDE did a proof of concept that worked pretty well
23:14 crocket Why vim?
23:14 crocket No reason?'
23:15 TimToady because my pinky finger is too arthritic to use emacs anymore
23:15 TimToady plus I already have several other religions to maintain my allegiance to :)
23:16 diakopter "most of us here use vim".. well, jnthn & I use Notepad++, and not_gerd uses Notepad2
23:16 TimToady why is PyPy out of the question?
23:16 TimToady we've certainly entertained the notion of targetting it someday as one of our backends
23:17 crocket TimToady : PyPy is slow.
23:18 * TimToady has heard otherwise lately, but maybe it's just hype :)
23:18 diakopter crocket: what's slow about it?
23:18 crocket diakopter, PyPy runs on python.
23:18 crocket Cython runs on native platform.
23:18 crocket Jython runs on JVM.
23:19 diakopter hmmm http://speed.pypy.org/
23:20 diakopter crocket: PyPy's JIT doesn't compile to python :P
23:20 araujo joined #perl6
23:20 crocket hmm
23:20 araujo joined #perl6
23:20 TimToady there are many meanings of "on", but that's not one of them in this case
23:20 crocket diakopter, Do you mean only compiler is slower?
23:21 diakopter I didn't know the compiler was slower?
23:21 diakopter is it?
23:22 TimToady I seem to recall that PyPy achieves jit-ness by adding type annotations to Python, so that's also a problem for Pyfolk culturally
23:23 TimToady whereas native type annotations are built-in to Perl 6 from the getgo
23:26 skids joined #perl6
23:36 fridim__ joined #perl6
23:41 krokite joined #perl6
23:50 zamolxes joined #perl6
23:59 crocket TimToady : What's so special about type annotation?

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo