Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2013-05-08

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:00 diakopter r: q.chars
00:00 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
00:00 sorear it's a sorry message.
00:00 TimToady something tells me the quote nibbler is emitting UTF-32
00:00 sorear you have a syntax error.
00:00 sorear r: sub bob($x) { say $x.perl }; bob q
00:00 camelia rakudo 37c762: OUTPUT«""␤»
00:01 sorear r: say eval('q').perl
00:01 camelia rakudo 37c762: OUTPUT«""␤»
00:01 sorear rn: say q.foo.
00:01 camelia rakudo 37c762, niecza v24-42-g69a3432: OUTPUT«foo␤»
00:01 sorear rn: say q'foo
00:01 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
00:01 camelia ..niecza v24-42-g69a3432: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤Undeclared routine:â�¤     'q'foo' used at line 1â�¤â�¤Unhandled exception: Check failedâ�¤â�¤  at /home/p6eval/niecza/boot/lib/CORE.setting line 1443 (die @ 5) â�¤  at /home/p6eval/niecza/src/STD.pm6 line 1147 (P6.comp_unit @ 37) â�¤  at /ho…
00:01 TimToady r: say eval("q\0").perl
00:01 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
00:01 sorear seems to be a problem more generally with unterminated quotes
00:02 TimToady yes, the quote nibbler
00:02 TimToady but it's also treating bare q as if there a '' after it
00:03 TimToady r: s//
00:03 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Null regex not allowedâ�¤at /tmp/Z_f4cWG7C5:1â�¤------> [32ms/[33mâ��[31m/[0mâ�¤Malformed replacement part; couldn't find final $stopâ�¤at /tmp/Z_f4cWG7C5:1â�¤------> [32ms//[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤ …
00:03 TimToady hah
00:03 TimToady r: s/foo/
00:03 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Malformed replacement part; couldn't find final $stopâ�¤at /tmp/YlzEITAi1w:1â�¤------> [32ms/foo/[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤        infix stopper…
00:03 sorear r: s
00:03 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Null regex not allowedâ�¤at /tmp/OuHiP8bqr2:1â�¤------> [32ms[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
00:03 sorear r: tr
00:03 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Undeclared routine:â�¤    tr used at line 1â�¤â�¤Â»
00:03 TimToady bare s is doing the s'' trick, I guess
00:04 sorear r: s'
00:04 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Confusedâ�¤at /tmp/dmvHHdi6PW:1â�¤------> [32ms'[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
00:04 sorear but s doesn't/shouldn't be using the quote nibbler at all
00:04 TimToady I don't mean '' literally, just that somehow it returns a null stirng
00:04 sorear regexes aren't strings
00:04 sorear r: tr'
00:04 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Two terms in a rowâ�¤at /tmp/bsdcaydyTt:1â�¤------> [32mtr[33mâ��[31m'[0mâ�¤    expecting any of:â�¤        argument listâ�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤        statement endâ�¤        statement modifierâ�¤   …
00:04 sorear umm.
00:05 TimToady tr() ''   is what it's thinking
00:05 TimToady r: m
00:05 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Null regex not allowedâ�¤at /tmp/gcTXEPreuE:1â�¤------> [32mm[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
00:06 * TimToady wonders if rakudo is cheating on regex and doing a two-pass algo somehow
00:07 TimToady but maybe it switches to regex grammar after finding the opener
00:07 TimToady the opener finder could be shared with quotes and regex
00:08 TimToady apparently tr doesn't use the same one though, or backtracks out to do tr as a sub instead
00:08 TimToady r: tr//bar/
00:08 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Two terms in a rowâ�¤at /tmp/KLjvqh8NUE:1â�¤------> [32mtr//bar/[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        argument listâ�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤Â»
00:08 TimToady r: tr/foo/bar/
00:08 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Two terms in a rowâ�¤at /tmp/9nXfyVD1qo:1â�¤------> [32mtr/foo/bar/[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        argument listâ�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤Â»
00:08 TimToady that's just borken parsing, I guess
00:09 TimToady r: tr/foo/bar/;
00:09 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Bogus statementâ�¤at /tmp/EF0Uf9C8Kl:1â�¤------> [32mtr/foo/bar/[33mâ��[31m;[0mâ�¤    expecting any of:â�¤        argument listâ�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤        prefix or termâ�¤        prefix or meta-…
00:09 * diakopter is in the enviable? position of having followed this parser rabbit hole a few times before while braindead fuzzing, but unfortunately doesn't remember where it leads still
00:09 TimToady I guess rakudo doesn't really attempt to parse tr/// yet
00:13 diakopter r: my \tr::tr = tr::tr/tr::tr!tr::eval!!::-7'
00:13 camelia rakudo 37c762: OUTPUT«===SORRY!===␤Method 'ast' not found for invocant of class 'NQPMu'␤»
00:14 diakopter rakudo: you're an NQPMu
00:14 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Undeclared name:â�¤    NQPMu used at line 1â�¤Undeclared routines:â�¤    an used at line 1â�¤    you're used at line 1â�¤â�¤Â»
00:14 TimToady .oO("This is the Cosmic All.  What are you doing here?!?")
00:15 TimToady (message from Dungeon Definition Language if you ended up in the room that contains all other rooms)
00:15 diakopter .oO("why do you look so much like me^W I do?")
00:18 grondilu_ joined #perl6
00:19 TimToady Why are you so much taller than him?  <-- normal English, and why it's 'than me', not 'than I'
00:20 jercos_ joined #perl6
00:20 TimToady "People who are taller than I should duck"  <- bogus
00:21 rom1504 joined #perl6
00:21 TimToady "People who are taller than me should duck."  <- perfectly fine
00:21 drbean joined #perl6
00:22 sorear than me, than I am - both fie
00:23 labster "Ducks who are taller than me are mutants."
00:24 * diakopter apologizes to #perl6 for tormenting TimToady with an allusion to a knock-down,throw-down on Sunday
00:24 diakopter er
00:25 diakopter knock-around,throw-back?
00:25 labster I got 500 blog hits yesterday?  Oh, I see, someone posted it on /r/programming
00:25 diakopter knock-along,throw-behind?
00:26 labster anyone want to answer this question:  http://www.reddit.com/r/programming/comments/1duvou/porting_a_module_to_perl_6/  TBH finding easy-level docs is something I struggle with too.
00:27 diakopter "pull requests welcome?"
00:27 * diakopter quacks
00:30 cognominal I think the nqp::clone is useless here. What do you think?   https://github.com/perl6/nqp/blob/master/src/NQP/Actions.nqp#L1334
00:30 [Coke] I for one would love it if nqp had a tcl like uplevel. For probably the only one, though.
00:31 cognominal it seems to have been pasted from another zone that did a pop so the clone there was justified.
00:40 cognominal btw, I duck
00:40 cognominal being taller than TimToady
00:40 TimToady I just grouse
00:41 TimToady (from a sign in a low doorway in an English castle: Duck, or grouse.)
00:42 cognominal each time I consult a dictionnary to understand TimToady, I see how he exploits language polysemy
00:43 cognominal * how much
00:43 cognominal how, I don't know
00:44 TimToady well, I didn't make that one up.
00:46 TimToady but yes, if there's any way to misunderstand something intentionally, I'll usually do so :)
00:46 cognominal That made work difficult for people who had to translate programming Perl
00:47 cognominal linguistic puns rarely survive translation.
00:47 cognominal translate "traduttore traduttore" in French or English
00:48 cognominal oops
00:48 cognominal I meant Traduttore, traditore
00:48 TimToady that will traduce a traditional translator
00:49 cognominal :)
00:54 * [Coke] leaves his traduce in the upright and locked position.
00:54 stevan_ joined #perl6
01:07 anuby joined #perl6
01:17 cognominal removing the nqp::clone did not break anything so I submit a pull request :  https://github.com/perl6/nqp/pull/97
01:18 FROGGS_ joined #perl6
01:21 MrMeek joined #perl6
01:32 stevan_ joined #perl6
01:34 gdey_ joined #perl6
01:35 [Coke] Do we have any docs on kcachegrind specificaly on rakudo --profile output?
01:38 [Coke] ah. step 1: turn off cycle detection.
01:41 [Coke] anyone know what '3 is ?
01:42 [Coke] (it's one of the highest cost functions - 0x<something>:'3
01:42 flussence those are usually anonymous function things...
01:43 colomon n: my @var = <a b ab c>; my $aref = \@var; say 'a0' ~~ m/$aref[0]/
01:43 camelia niecza v24-42-g69a3432: OUTPUT«Potential difficulties:â�¤  Apparent subscript will be treated as regex at /tmp/_TqEMWffQt line 1:â�¤------> [32m>; my $aref = \@var; say 'a0' ~~ m/$aref[33mâ��[31m[0]/[0mâ�¤â�¤Falseâ�¤Â»
01:44 flussence (if you've got the address there, gdb *might* produce useful info on it...)
01:47 [Coke] flussence: I'm not in gdb, though?
01:48 colomon r: my @var = <a b ab c>; my $aref = \@var; say 'a0' ~~ m/$aref[0]/
01:48 camelia rakudo 37c762: OUTPUT«Potential difficulties:â�¤    Apparent subscript will be treated as regexâ�¤    at /tmp/UVYJQD_Dm5:1â�¤    ------> [32m>; my $aref = \@var; say 'a0' ~~ m/$aref[33mâ��[31m[0]/[0mâ�¤Falseâ�¤Â»
01:48 flussence oh, um, not much else I can think of that'd be useful then
01:50 colomon nr: my @var = <a b ab c>; my $aref = \@var; say 'a b ab c0' ~~ m/$aref[0]/
01:50 camelia rakudo 37c762: OUTPUT«Potential difficulties:â�¤    Apparent subscript will be treated as regexâ�¤    at /tmp/e9H1oMM9Eu:1â�¤    ------> [32maref = \@var; say 'a b ab c0' ~~ m/$aref[33mâ��[31m[0]/[0mâ�¤ï½¢a b ab c0ï½£â�¤â�¤Â»
01:50 camelia ..niecza v24-42-g69a3432: OUTPUT«Potential difficulties:â�¤  Apparent subscript will be treated as regex at /tmp/CaRuBey9D9 line 1:â�¤------> [32maref = \@var; say 'a b ab c0' ~~ m/$aref[33mâ��[31m[0]/[0mâ�¤â�¤Falseâ�¤Â»
01:57 [Coke] so, infix:<<> is listed as the highest # for Self in this profile. No clue which of those it is. caller list is a bunch of "1", "reify'1", "gimme'1", with no source. *sadface*
02:01 hypolin joined #perl6
02:02 [Coke] (adding CORE.setting via the kcachegrind menu has no effect)
02:03 TimToady nr: my @var = <a b ab c>; my $aref = \@var; say $aref.Str
02:03 camelia rakudo 37c762: OUTPUT«a b ab c␤»
02:03 camelia ..niecza v24-42-g69a3432: OUTPUT«Capture()<instance>␤»
02:03 TimToady nr: my @var = <a b ab c>; my $aref = @var; say $aref.Str
02:03 camelia rakudo 37c762, niecza v24-42-g69a3432: OUTPUT«a b ab c␤»
02:03 TimToady colomon: that's the difference
02:04 TimToady the \ doesn't make a ref like in P5, and they disagree on how to stringify a Capture
02:05 [Coke] if I drill down a bit, I can see time in my code spends a lot of time in eager, even though I'm not calling eager directly. (part of for loops)
02:05 lustlife joined #perl6
02:05 colomon TimToady++
02:11 colomon TimToady: do you have thoughts on what Set.ACCEPTS should do?
02:21 kurahaupo joined #perl6
02:27 flussence colomon: does that do anything currently? my naive guess if I read code using it, having never used any Set stuff, would be «$lhs subset-of $set»
02:28 flussence (which seems like a reasonably useful default to me, but again I've never used it...)
02:28 colomon flussence: doesn't do anything in Niecza, dunno about Rakudo
02:29 grondilu_ Will we ever simulate a biological organism in Perl6?  http://phys.org/news/2013-05-digital-life-openworm-source.html
02:29 colomon subset was my instinctive notion as well.
02:30 colomon but it doesn't seem very consistent with Hash's behavior.
02:30 colomon (Which I didn't know when I first thought subset.)
02:30 quietfanatic I would assume Set.ACCEPTS would test for element-hood rather than subset-hood
02:31 quietfanatic or I guess it could do both depending on the argument
02:32 sorear if I were reading code like given $set { ... when set(2,5) { ... } ... } - I think the least surprising behavior would be exact, order-and-duplicate insensitive comparison (of the key set for hashes)
02:32 colomon Set's subset behavior is to promote Scalars to a set containing the scalar.
02:33 sorear Set.ACCEPTS shouldn't test element-hood because we already have any-junctions for that.
02:33 flussence good point
02:33 colomon and if you want to do Set subset, there already are a slew of subset operators.
02:35 sorear so I'm thinking something like Set($lhs) === self
02:37 colomon === doesn't actually do that, does it?
02:38 colomon infix:<eqv> is supposed to, but that's NYI in Niecza.
02:39 colomon but yeah, quibbles aside that seems the natural extension of the Hash behavior
02:42 xenoterracide joined #perl6
02:42 sorear colomon: for immutable types like Set, === and eqv are supposed to be the same
02:43 colomon sorear: ah
02:50 leprevost joined #perl6
02:54 skids joined #perl6
03:00 xenoterracide http://privatepaste.com/6efc3e03bc why would I have done this this way?
03:01 xenoterracide oops
03:01 xenoterracide wrong channel
03:09 mikemol joined #perl6
03:14 Pleiades` joined #perl6
03:15 thou joined #perl6
03:32 [Coke] #perl6++
03:43 preflex_ joined #perl6
03:54 sorear any reason in particular?
04:01 [Coke] when my perl6 is broke, y'all help me fix it with a minimum of snark and vinegar.
04:21 lue joined #perl6
04:32 berekuk joined #perl6
04:51 dmol joined #perl6
04:53 Util Coke: New band name: Minimum Vinegar
05:07 moritz pmichaud: indeed I have
05:07 moritz labster: you now have a commit bit. Welcome to the team!
05:07 Psyche^ joined #perl6
05:09 theEXA joined #perl6
05:18 satyavvd joined #perl6
05:55 frdmn joined #perl6
06:04 skids joined #perl6
06:23 Timbus|Away joined #perl6
06:30 FROGGS joined #perl6
06:40 TimToady prn: my @pascal := [1], -> @p { [0, @p Z+ @p, 0] } ... *; .say for @pascal[2,4...*];
06:40 diakopter rpn
06:41 camelia rakudo 37c762, niecza v24-42-g69a3432: OUTPUT«(timeout)»
06:41 camelia ..pugs: OUTPUT«*** ␤    Unexpected ";"␤    at /tmp/xgTCTmr8JB line 1, column 52␤»
06:41 diakopter oh heh.
06:42 TimToady prn: my @pascal := [1], -> @p { [0, @p Z+ @p, 0] } ... *; .say for @pascal;
06:43 camelia niecza v24-42-g69a3432: OUTPUT«(timeout)1␤1 1␤1 2 1␤1 3 3 1␤1 4 6 4 1␤1 5 10 10 5 1␤1 6 15 20 15 6 1␤1 7 21 35 35 21 7 1␤1 8 28 56 70 56 28 8 1␤1 9 36 84 126 126 84 36 9 1␤1 10 45 120 210 252 210 120 45 10 1␤1 11 55 165 330 462 462 330 165 55 11 1␤1 12 66 220 495 792 924 792 495 220 66 …
06:43 camelia ..rakudo 37c762: OUTPUT«(timeout)1␤1 1␤1 2 1␤1 3 3 1␤1 4 6 4 1␤1 5 10 10 5 1␤1 6 15 20 15 6 1␤1 7 21 35 35 21 7 1␤1 8 28 56 70 56 28 8 1␤1 9 36 84 126 126 84 36 9 1␤1 10 45 120 210 252 210 120 45 10 1␤1 11 55 165 330 462 462 330 165 55 11 1␤1 12 66 220 495 792 924 792 495 220 66 12 1␤1 13…
06:43 camelia ..pugs: OUTPUT«*** ␤    Unexpected ";"␤    at /tmp/2h84mJCKSA line 1, column 52␤»
06:44 * TimToady expected @pascal[2,4...*] to hand the lazy subscript when embedded in a lazy list
06:47 GlitchMr rpn: 2 2 + say
06:47 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Two terms in a rowâ�¤at /tmp/0FTwjtHp1t:1â�¤------> [32m2 [33mâ��[31m2 + say[0mâ�¤    expecting any of:â�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤        statement endâ�¤        statement modifierâ�¤        statement m…
06:47 camelia ..pugs: OUTPUT«*** ␤    Unexpected "2"␤    expecting operator␤    at /tmp/VL3Ilh1CiZ line 1, column 3␤»
06:47 camelia ..niecza v24-42-g69a3432: OUTPUT«[31m===[0mSORRY![31m===[0m��Two terms in a row at /tmp/p2PQM3Lb3n line 1:�------> [32m2 [33m�[31m2 + say[0m��Parse failed��»
06:50 domidumont joined #perl6
06:52 TimToady makes it harder to write http://rosettacode.org/wiki/Catalan_numbers/Pascal%27s_triangle#Perl_6 without lazy subscripting
06:56 labster moritz: thanks!
06:56 labster .oO ( You are now a member of Team Rakudo.  Here's your commit bit and jersey )
06:58 sqirrel joined #perl6
06:58 TimToady on RC we're now in 7th place, 4 ahead of Ruby, and 6 behind D
06:58 moritz TimToady++
06:59 TimToady well, the competition is fun, but flushing out bugs and missing features is the real point...
07:00 FROGGS morning
07:00 sorear o/
07:00 TimToady it's AM here too, barely :)
07:01 sorear inded.
07:01 labster Oh, it is morning now.  Good morning!
07:01 lizmat morning #perl6
07:01 yoleaux 7 May 2013 14:16Z <pmichaud> lizmat: (Hash2.new multimethod fail)   the problem appears to be that Rakudo's Hash.new method isn't declared 'multi'.
07:07 sorear o/
07:07 kaleem joined #perl6
07:10 Khisanth joined #perl6
07:23 domidumont joined #perl6
07:23 kivutar joined #perl6
07:27 FROGGS if I can do this:
07:27 FROGGS nr: package Foo { { our @x }; say @Foo::x.WHAT }
07:27 camelia rakudo 37c762: OUTPUT«(Any)␤»
07:27 camelia ..niecza v24-42-g69a3432: OUTPUT«(Array)␤»
07:27 FROGGS shoudn't be x reported here?
07:27 FROGGS nr: package Foo { { our @x }; say Foo:: }
07:27 camelia niecza v24-42-g69a3432: OUTPUT«Stash.new(...)␤»
07:27 camelia ..rakudo 37c762: OUTPUT«().hash␤»
07:27 FROGGS nr: package Foo { { our @x }; say Foo.WHO } # test
07:27 camelia niecza v24-42-g69a3432: OUTPUT«Stash.new(...)␤»
07:27 camelia ..rakudo 37c762: OUTPUT«().hash␤»
07:29 moritz nr: package Foo { { our @x }; say Foo::.keys }
07:29 camelia niecza v24-42-g69a3432: OUTPUT«0␤»
07:29 camelia ..rakudo 37c762: OUTPUT«␤»
07:29 moritz nr: package Foo { { our @x }; say Foo.WHO.keys }
07:29 camelia niecza v24-42-g69a3432: OUTPUT«0␤»
07:29 camelia ..rakudo 37c762: OUTPUT«␤»
07:30 FROGGS I mean, that rakudo doesnt do it is clear to me... but I just want to confirm that I should see it theoretically
07:30 moritz yes, it should
07:31 FROGGS k, thanks
07:40 daxim joined #perl6
07:43 census joined #perl6
07:45 daxim http://xkcd.com/1209/  # title says encoding, but that's a font construction or rendering problem.  rmunroe, I am disappoint.
07:53 daxim I am informed that a skywriter is an airplane writing with smoke, not pulling a banner as I imagined, and thus there is no font as such.  still not an encoding problem
08:01 lizmat on the rakudo/parrot performance bit:  I noticed that at least on OS X, "1 while 1" on Perl 5 uses only 1 core 100%
08:01 lizmat whereas rakudo/parrot switches between 2 cores continuously
08:02 lizmat (effectively doing about 50% on 2 cores on average)
08:02 moritz wouldn't it finish much earlier if it used more cores? :-)
08:02 lizmat while discussing this at the Amsterdam.pm meeting
08:02 lizmat it was suggested that this might be an indication of some bad CPU pipelining
08:03 lizmat and that that would also badly affect performance
08:03 lizmat so I was wondering whether we see this also on rakudo/jvm
08:04 lizmat if we don't, we can forget about it, as it is apparently a parrot issue
08:04 fhelmberger joined #perl6
08:04 lizmat if we do, then maybe we should have this somehow in the back of our minds
08:04 timotimo at least on linux and windows you can restrict a process to a subset of  your cores. you could just try running the parrot/perl6 process once without restriction and once with and run a simple benchmark and see if there's any benefit
08:05 timotimo i would think: almost no benefit at all
08:05 sorear maybe it makes lots of blocking syscalls
08:06 moritz like malloc?
08:06 sorear page faults maybe.  does 1 while 1 still leak memory?
08:06 lizmat doesn't seem to leak memory...
08:06 * lizmat checks
08:06 kresike joined #perl6
08:06 kresike hello all you happy perl6 people
08:06 moritz sorear: doesn't seem to leak, no
08:07 sorear sleep&
08:08 Chillance joined #perl6
08:09 lizmat running for a few minutes now, steady at 182.8 MB real memory
08:09 lizmat morning kresike!
08:11 berekuk joined #perl6
08:11 kresike lizmat, o/
08:11 timotimo .o(am i in the wrong to think that that's actually a lot?)
08:37 rhr joined #perl6
08:41 lizmat timotimo: perl5 runs at 1.2MB real memory for the same code
08:41 nwc10 timotimo: seems a lot. Does it include all of Rakudo in memory too?
08:42 lizmat those long startup times must come from somewhere  :-)
08:44 nwc10 long startup times - you ain't seen nothin' yet :-/
08:48 jnthn morning, #perl6
08:49 nwc10 jnthn: morning
08:49 nwc10 I was going to report a bug/regression/wibble in nqp-jvm, but sort of there isn't
08:50 nwc10 a) it hasn't regressed on t/nqp/67-container.t because that is a new test
08:50 nwc10 b) it does correctly now report when it can't open a file (which it didn't seem to on the older revision I checked)
08:50 nwc10 c) t/nqp/24-module.t didn't even run before.
08:50 nwc10 However, it's output is Less Than Awesome:
08:51 nwc10 [nicholas@dromedary-001 nqp]$ ./nqp t/nqp/24-module.t
08:51 nwc10 1..3
08:51 nwc10 ok 1
08:51 nwc10 ok 1
08:51 nwc10 ok 3
08:51 nwc10 Gah. its output. No '. Brainfart.
08:51 jnthn Yeah. I fixed what I thought was the problem there. Which fixed my *actual* blocker over in the Rakudo work, but still got that test wrong. I ain't sure why.
08:52 jnthn You should find t/qregex and t/p5regex fail much less now also.
08:53 timotimo i wonder if jakudo will run at less than 180 MB of real memory usage for something as simple as "1 while 1"
08:53 timotimo my intuition says it should be doable, but no word on wether it will happen "on its own"
08:54 nwc10 timotimo: it might well make Parrot's memory drop too. (Yes, this is optimism, but)
08:54 nwc10 given the different (and better?) toolchain for debugging, it may well let people find ways to optimise memory
08:55 nwc10 IIRC pmichaud had said that there are things that he thought that the compiler hangs on to long after it it no longer access them
08:56 jnthn Also, a bunch of speed/memory trade-offs have gone the "speed" way.
08:56 lizmat juerd at the Amsterdam.pm (jokingly) suggested that "1 while 1" should be reduced by Perl 6 to "sleep *"
08:57 lizmat which would put Perl 6 at the top of the most efficient implementation of "1 while 1" :-)
08:57 moritz or more generally, side-effect-free infinite loops in sink context :-)
08:58 nwc10 that's kind of like tweaking the C compiler to recongnise SPEC benchmarks and output "different" code
08:58 nwc10 or what I'm told that car manufacturers do to get the best official mileage figures, to the extent of programming the car to recognise the test cycle
08:59 tadzik seen LylePerl
08:59 tadzik yoleaux: seen LylePerl?
08:59 tadzik gah
08:59 labster .seen LylePerl
08:59 yoleaux I haven't seen LylePerl around.
08:59 tadzik oh, thanks labster
09:00 nwc10 .seen yoleaux
09:00 yoleaux I'm right here.
09:01 lizmat r: sleep *
09:01 camelia rakudo 37c762: OUTPUT«Cannot call 'Numeric'; none of these signatures match:␤:(Mu:U \v: Mu *%_)␤  in method Numeric at src/gen/CORE.setting:865␤  in sub infix:<==> at src/gen/CORE.setting:3008␤  in sub infix:<==> at src/gen/CORE.setting:3006␤  in method ACCEPTS at src/gen/CORE.setting:2…
09:01 lizmat r: sleep Inf
09:01 tadzik . o O ( timeout )
09:01 camelia rakudo 37c762: OUTPUT«(timeout)»
09:02 labster (this might take a while)
09:03 nwc10 nqp-jvm running 1 while 1
09:03 nwc10 23226 nicholas  20   0 7765m  97m 9.9m S 100.1  0.4   0:12.10 java
09:03 daxim_ joined #perl6
09:03 d4l3k_ joined #perl6
09:03 nwc10 nqp on parrot running 1 while 1
09:03 nwc10 23593 nicholas  20   0  178m  40m 5108 R 99.8  0.2   0:05.69 nqp
09:04 jnthn .oO( now somebody tell me what the numbers mean... :) )
09:04 labster Well, I started writing the follow up blog post, and it turned into two posts.  Incidentally, that File::Spec post got 500 hits off of reddit, which well, surprised me.
09:04 nwc10 bigger figure is "VIRT", smaller is "RES"
09:04 nwc10 -smallest is "SHR"
09:04 arnsholt What're the corresponding JVM numbers?
09:04 berekuk joined #perl6
09:05 nwc10 you mean NQP-JVM (which I pasted first), or write-the-code-as-Java?
09:05 labster http://blog.brentlaabs.com/2013/05/how-to-start-hacking-on-rakudo-perl-6.html < practical details on how to set up your own branch of rakudo and test it
09:05 arnsholt Oh derp. Missed it above the join notices. Sorry
09:06 labster http://blog.brentlaabs.com/2013/05/implementing-iopath-in-rakudo.html < me demonstrating how bad I am at programming, and how much I like the sound of myself typing.
09:06 nwc10 no problem. wasn't sure if you had, or you were asking the other question
09:06 lizmat labster++ for blog post!
09:08 moritz labster++
09:08 moritz we should add that blog to planetsix
09:08 moritz or whatever is going to replace planetsix
09:09 labster it's on the planeteria one already. But the rendering of <code> in a paragraph is awful.
09:09 cognominal__ joined #perl6
09:10 betterwo1ld joined #perl6
09:10 smash_ joined #perl6
09:11 sciurius1 joined #perl6
09:11 s0rear joined #perl6
09:12 ingyfoo joined #perl6
09:12 labster also labster-- for writing too much in the second post.  I just can't bring myself to do enough editing in a blog post.
09:12 tadzik1 joined #perl6
09:12 _jaldhar joined #perl6
09:12 woolfy1 joined #perl6
09:13 BooK_ joined #perl6
09:13 huf__ joined #perl6
09:14 Util_ joined #perl6
09:14 kshannon_ joined #perl6
09:15 GlitchMr joined #perl6
09:16 GlitchMr r: q.what?
09:18 lizmat r: 1
09:18 FROGGS camelia is gone
09:18 * lizmat wonders whether she killed Camelia with "sleep Inf"
09:18 jnthn No, netsplit.
09:19 lizmat ah  *phew*
09:19 cooper- joined #perl6
09:20 mtk joined #perl6
09:21 hugme joined #perl6
09:25 masak antenoon, #perl6
09:26 moritz an, ma<tab>
09:26 masak an, ma<tab>
09:26 lizmat masak!
09:26 jnthn o/ masak
09:27 sizz_ joined #perl6
09:27 domidumont joined #perl6
09:33 camelia joined #perl6
09:36 lizmat rL q.what?
09:36 lizmat r: q.what?
09:36 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
09:36 bonsaikitten joined #perl6
09:38 jnthn ...
09:38 lizmat just repeating what GlitchMr was doing before Camelia went AWOL
09:38 jnthn .oO( Encoded strings considered not so great after all... )
09:39 GlitchMr r: 'qwerty
09:39 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Unable to parse expression in single quotes; couldn't find final "'"â�¤at /tmp/8q1qI8XzUU:1â�¤------> [32m'qwerty[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤     …
09:39 GlitchMr r: q<<qwerty> >
09:39 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Couldn't find terminator >>â�¤at /tmp/FxHrhWY8Gv:1â�¤------> [32mq<<qwerty> >[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
09:39 GlitchMr r: q<<qwerty
09:39 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Couldn't find terminator >>â�¤at /tmp/00CQdNTq8B:1â�¤------> [32mq<<qwerty[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
09:39 GlitchMr huh?
09:39 GlitchMr r: q!qwerty
09:39 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
09:40 masak GlitchMr: why do you say "huh?"? what's surprising?
09:40 masak looks perfectly legit to me.
09:40 jnthn masak: That it only fucks up some of the errors when they seem like cases of the same thing.
09:40 GlitchMr r: q<qwert
09:40 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Couldn't find terminator >â�¤at /tmp/PL_lROjfkC:1â�¤------> [32mq<qwert[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or meta-prefixâ�¤Â»
09:41 GlitchMr r: qw!abc
09:41 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
09:41 GlitchMr r: qw'abc
09:41 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
09:41 masak hm -- better collect the cases where it fails, and try to find what sets them apart...
09:41 GlitchMr ok, so it's quotelike keyword with delimiter that isn't a paren.
09:42 jnthn afaict, some string operations in Parrot, when they get strings that are of different encodings, do the Wrong Thing and/or mislabel the encoding of the produced string.
09:43 lizmat r: sub so-q { True }; say so-q
09:43 camelia rakudo 37c762: OUTPUT«False␤»
09:44 lizmat just another in the category "why do we allow - as a identifier character:
09:44 lizmat "
09:45 GlitchMr Because "-" looks nicely.
09:47 lizmat so what was the reasoning behind allowing "-" as an identifier?  Making it easier for beginners?  Or people coming over from XSLT ?
09:47 GlitchMr I like "-".
09:47 lizmat *identifier character
09:47 * lizmat too
09:47 GlitchMr The - character looks more nicely than _.
09:48 GlitchMr $some-variable is better than $some_variable.
09:48 lizmat but that doesn't mean it brings a world of hurt because "-" is also an operator
09:48 GlitchMr This is parsing problem.
09:48 GlitchMr Perl 6 is for humans, not parsers.
09:48 jnthn lizmat: Perl 6 gives you a *lot* of incentives to put whitespace around your infixes anyway, not just this one.
09:48 GlitchMr Besides, "-" isn't that hard to parse.
09:49 GlitchMr There are things that are worse than that.
09:49 lizmat r: my $a=5; say $a-1
09:49 camelia rakudo 37c762: OUTPUT«4␤»
09:49 lizmat here no spaces are needed
09:50 GlitchMr I would say it's a bug.
09:50 masak GlitchMr: of course not.
09:50 jnthn lizmat: I said incentive, not demand.
09:50 lizmat jnthn: indeed
09:50 masak GlitchMr: try to not sound so cock-sure about things you don't know ;)
09:50 GlitchMr But perhaps I mistake \w.
09:50 lizmat r: my $a=5; my $a-i=6; say $a-i
09:50 camelia rakudo 37c762: OUTPUT«6␤»
09:51 masak indeed.
09:51 masak the parsing rules here are fairly unambiguous.
09:51 lizmat r: my $a=5; my $a-i=6; say $a-1
09:51 camelia rakudo 37c762: OUTPUT«4␤»
09:51 masak r: my $a--b = 5
09:51 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix = instead�at /tmp/9ApiLogr1Y:1�------> [32mmy $a--b =[33m�[31m 5[0m�»
09:51 jnthn It's the same rule that means you can't write
09:51 jnthn r: my $1a;
09:51 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0m�Cannot declare a numeric variable�at /tmp/y68p3sZsiB:1�------> [32mmy $1[33m�[31ma;[0m�»
09:51 GlitchMr r: my \b = 42; my $a = 50; my $a-b = 1; say $a-b;
09:51 camelia rakudo 37c762: OUTPUT«1␤»
09:51 * nwc10 can't work out how to compile `1 while 1` from NQP to a Java bytecode file that runs as the main program
09:52 GlitchMr r: my \b = 42; my $a = 50; my $a-b = 1; say $a-b();
09:52 camelia rakudo 37c762: OUTPUT«No such method 'postcircumfix:<( )>' for invocant of type 'Int'␤  in block  at /tmp/Qj2URe5PWM:1␤␤»
09:52 GlitchMr r: my \b = 42; my $a = 50; my $a-b = 1; say $a-(b);
09:52 camelia rakudo 37c762: OUTPUT«8␤»
09:52 jnthn nwc10: --target=classfile --javaclass=Foo --output=Foo.class
09:53 GlitchMr r: my $A-004 = 'Hello, world!'
09:53 camelia rakudo 37c762: OUTPUT«Potential difficulties:â�¤    Leading 0 does not indicate octal in Perl 6; please use 0o04 if you mean thatâ�¤    at /tmp/hsFYwBSQGN:1â�¤    ------> [32mmy $A-004[33mâ��[31m = 'Hello, world!'[0mâ�¤    Leading 0 does not indicate octal in Perl 6; please use 0o04 if you me…
09:53 nwc10 Exception in thread "main" java.lang.NoClassDefFoundError: org/perl6/nqp/runtime/CompilationUnit
09:53 nwc10 ...
09:53 nwc10 ... 13 more
09:53 lizmat GlitchMr: must be alpha around "-"
09:53 jnthn nwc10: Did you just try to run it with java Foo ?
09:54 nwc10 yep
09:54 nwc10 how did you guess? Was about to say that
09:54 jnthn nwc10: You need the various classpath flags as well, like the ones nqp.sh passes.
09:54 FROGGS r: my $a=5; my $a-1=6; say $a-1
09:54 camelia rakudo 37c762: OUTPUT«Potential difficulties:â�¤    Redeclaration of symbol $aâ�¤    at /tmp/HSff8T7qyr:1â�¤    ------> [32mmy $a=5; my $a[33mâ��[31m-1=6; say $a-1[0mâ�¤Cannot modify an immutable valueâ�¤  in block  at /tmp/HSff8T7qyr:1â�¤â�¤Â»
09:54 FROGGS k
09:54 lizmat r: my $_-_=6; say $_-_
09:54 camelia rakudo 37c762: OUTPUT«6␤»
09:54 jnthn nwc10: I just recognize the error ;)
09:54 GlitchMr r: __halt_compiler();
09:54 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Undeclared name:â�¤    __halt_compiler used at line 1â�¤â�¤Â»
09:54 nwc10 aha.
09:55 GlitchMr r: <?php __halt_compiler();
09:55 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Unable to parse expression in quote words; couldn't find final '>'â�¤at /tmp/RzN9_UZUnB:1â�¤------> [32m<?php __halt_compiler();[33mâ��[31m<EOL>[0mâ�¤    expecting any of:â�¤        statement listâ�¤        prefix or termâ�¤        prefix or me…
09:55 nwc10 Righto, so compiled `1 while 1` without needing to load the compiler:
09:55 nwc10 PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
09:55 nwc10 10356 nicholas  20   0 7765m  69m 9.9m S 100.1  0.3   0:14.19 java
09:55 FROGGS GlitchMr: you are doing strange things... O.o
09:55 nwc10 contrast with running it as -e, so NQP compiler loaded:
09:55 nwc10 10572 nicholas  20   0 7765m 100m 9.9m S 100.1  0.4   0:09.21 java
09:56 GlitchMr r: ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
09:56 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix > instead�at /tmp/H5nGo5t_8i:1�------> [32m++++++++++[>[33m�[31m+++++++>++++++++++>+++>+<<<<-]>++.>+.+++[0m�»
09:56 GlitchMr std: ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
09:56 camelia std b33d8e0: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix > instead at /tmp/3YmOyLgBeW line 1:�------> [32m++++++++++[[33m�[31m>+++++++>++++++++++>+++>+<<<<-]>++.>+.++[0m�Parse failed�FAILED 00:00 43m�»
09:56 lizmat nwc10: so 31MB for NQP ?
09:56 nwc10 it looks like that
09:57 GlitchMr r: ,+[-.,+]
09:57 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix , instead�at /tmp/r82XyaEANJ:1�------> [32m,[33m�[31m+[-.,+][0m�»
09:58 GlitchMr r: (aBA@?>=<;:9876543210/.-,JH)('&%$#"!~}|{zy\J6utsrqponmlkjihgJ%dcba`_^]\[ZYXWVUTSRQPONMLKJIHGF('C%$$^K~<;4987654321a/.-,\*)
09:58 camelia rakudo 37c762: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Two terms in a rowâ�¤at /tmp/mTmydytEMV:1â�¤------> [32m(aBA[33mâ��[31m@?>=<;:9876543210/.-,JH)('&%$#"!~}|{zy\J[0mâ�¤    expecting any of:â�¤        argument listâ�¤        postfixâ�¤        infix stopperâ�¤        infix or meta-infixâ�¤        sta…
09:58 GlitchMr ok
10:01 arlinius joined #perl6
10:04 FROGGS lizmat: I cant confirm that `1 while 1 ` uses more than one core
10:05 FROGGS not as a perl6 on-liner, not as a nqp one-liner, not in the repl
10:05 FROGGS one*
10:06 FROGGS yeah, and nqp takes 35MiB ram when rakudo takes 215MiB
10:10 jnthn A Java program that just contains while (true) { } weighs in at 10MB - and that's when you already compiled it, so there's no compiler in memory.
10:12 nwc10 is that after the JIT has figured out that there's a hot loop, and used more RAM to optimise it? :-)
10:12 FROGGS jnthn: do you wanna know what perl5 takes?
10:12 FROGGS 348kiB
10:13 FROGGS feels like there are centuries between 5 and 6 when there are just decades
10:13 jnthn FROGGS: Now load Moose, RegExp::Grammars, File::Spec, etc etc. ;)
10:13 FROGGS no, not installed :P
10:13 FROGGS (moose)
10:14 nwc10 perl 1 takes 420K
10:15 FROGGS nwc10: you have a running perl1 ?
10:15 vardan joined #perl6
10:15 nwc10 I built one
10:15 FROGGS are you going to backport moose?
10:15 FROGGS (joke)
10:16 nwc10 would be tricky with OO
10:17 nwc10 perl 4 on the same machine (and also i386) is 516K
10:17 nwc10 I don't think that I have an i386 perl 5 handy
10:18 FROGGS okay, perl -MMoose -MRegexp::Grammars -MFile::Spec -e '1 while 1' takes already 13MiB
10:19 FROGGS ohh what the, my remmina (a remote desktop client) needs 221MiB just for the try icon O.o
10:19 nwc10 I remember when emacs was big.
10:25 vardan joined #perl6
10:25 vardan Hi
10:26 FROGGS hi vardan
10:29 vardan Could you please help me to build rakudo under Red Hat linux
10:30 FROGGS hmm, should be fairly easy
10:30 FROGGS what do you wanna do? install/build rakudo star (the one with modules) or the compiler only?
10:31 vardan I need build
10:31 FROGGS build what?
10:32 moritz vardan: there are build instructions both on the rakudo website and in the rakudo source tree
10:32 moritz vardan: did you follow them?
10:32 vardan build perl 6
10:32 masak vardan: well, if you have git, you can simply go to https://github.com/rakudo/rakudo and then follow the instructions in INSTALL.txt
10:33 vardan No, but I'll now
10:33 vardan tanks for support
10:33 FROGGS you are welcome
10:34 FROGGS vardan: what is your native language ooc?
10:34 masak we're here to help, so keep the questions coming ;)
10:41 masak or leave without warning, that's OK too.
10:42 FROGGS -.-
10:42 FROGGS lunch&
10:43 donaldh joined #perl6
10:54 GlitchMr r: say ~/regexp/
10:54 camelia rakudo 37c762: OUTPUT«␤»
10:56 GlitchMr rn: my $regexp = /abc/; 'dabce' ~~ / d $regexp e / # I know, you should use <$regexp>
10:56 camelia rakudo 37c762, niecza v24-42-g69a3432:  ( no output )
10:56 GlitchMr rn: my $regexp = /abc/; say 'dabce' ~~ / d $regexp e / ?? True !! False # I know, you should use <$regexp>
10:56 camelia rakudo 37c762, niecza v24-42-g69a3432: OUTPUT«True␤»
10:56 GlitchMr rn: my $regexp = /abc/; say 'dabce' ~~ / d <$regexp> e / ?? True !! False # I know, you should use <$regexp>
10:56 masak GlitchMr: so... why don't you use <$regexp>...?
10:56 camelia rakudo 37c762, niecza v24-42-g69a3432: OUTPUT«True␤»
10:57 GlitchMr I was wondering what would happen if I would forget to.
10:57 GlitchMr I have noticed that in specs that it should be stringified instead (why).
11:02 masak GlitchMr: because of a known insecurity in Perl 5.
11:04 masak GlitchMr: see "two-level interpolation is problematic" in http://www.perl6.org/archive/doc/design/apo/A05.html
11:13 spider-mario joined #perl6
11:20 fhelmberger joined #perl6
11:37 sqirrel joined #perl6
11:40 Khisanth joined #perl6
11:52 saxx joined #perl6
11:59 Khisanth joined #perl6
12:17 bluescreen10 joined #perl6
12:21 Util_ TimToady++ # for RC 7th place
12:27 cognominal__ Util_?
12:27 Khisanth joined #perl6
12:28 Util_ cognominal__: http://irclog.perlgeek.de/perl6/2013-05-08#i_7033535
12:29 Util_ cognominal__: RC == RosettaCode.org
12:29 cognominal__ ok, thx
12:30 cognominal__ nice to have a big presence in Rosetta Code and Rosalind.
12:31 rindolf joined #perl6
12:34 krunen joined #perl6
12:34 cognominal__ I notice that NFA code is very modular. We probably could adapt it to get a version that match 2 bits characters to match codons. The slowing down for and-ing to get chars would be offsetted by a better use of cache. That would be a big win to show off in rosalind
12:35 cognominal__ I forgot what is the Perl 6 operator for bit and-ing
12:36 jnthn +&
12:36 masak mnemonic: "math and" :)
12:37 cognominal__ masak++ jnthn++
12:37 Util_ cognominal__: S03 says +& is "numeric bitwise and", ~& is "buffer bitwise and".
12:37 lizmat but anything with  buffer is NYI in rakudo, right?
12:38 masak r: say "foo".encode("utf-8").^name
12:38 jnthn Rakudo has some basic Buf support.
12:38 camelia rakudo 37c762: OUTPUT«Buf␤»
12:38 jnthn It's not perfect, but it certainly exists.
12:40 lizmat ah, ok
12:40 lizmat small question: in rakudo's README it says "perl Configure.pl --gen-parrot --gen-nqp"
12:40 lizmat in labster++ blog post, he says: "perl Configure.pl --gen-parrot"
12:41 lizmat the latter also seems to fetch nqp as expected?
12:41 lizmat maybe the README is a bit overcomplete ?
12:41 lizmat or is there a good reason to always say "--gen-nqp" as well ?
12:42 lizmat if so, maybe labster would need to correct his blog post?
12:42 lizmat blogpost: http://blog.brentlaabs.com/2013/05/how-to-start-hacking-on-rakudo-perl-6.html
12:42 cognominal__ Will Perl 6 provide support to add unicode subscripts or superscripts at the end of an identifier?  http://en.wikipedia.org/wiki/Unicode_subscripts_and_superscripts
12:43 lizmat .u upper
12:43 yoleaux U+0374 GREEK NUMERAL SIGN [Lm] (ʹ)
12:43 yoleaux U+05C4 HEBREW MARK UPPER DOT [Mn] (◌ׄ)
12:43 yoleaux U+2196 NORTH WEST ARROW [So] (↖)
12:43 kivutar joined #perl6
12:43 cognominal__ there is an unicode uperscripts and subscripts block
12:44 masak lizmat: I dunno, I always --gen-parrot and skip the other flag.
12:44 masak lizmat: I *suspect* that the one implies the other.
12:44 cognominal__ Next, people will ask for matrices :)
12:44 masak but I'm not good at reading Makefile.
12:44 krunen joined #perl6
12:45 lizmat me neither, but if --gen-parrot implies --gen-nqp, then it wouldn't be necessary in the README
12:47 masak correct.
12:48 jnthn --gen-parrot implies --gen-nqp iirc
12:49 lizmat ok, let me then make that my first pull request  :-)
12:50 cognominal__ lizmat++
12:50 jnthn We'll need to revisit this lot at some point soon anyways.
12:50 lizmat yup, with --gen-jvm I guess ?
12:51 jnthn Initially it'll be perl ConfigureJVM.pl, but I suspect at YAPC::NA we can discuss what we actually want.
12:52 jnthn Even if very basic JVM support of some kind is in the next compiler release, we'll be a bit off a Star that can do JVM, which is when we really want to have something nicer in place.
12:55 jac50 joined #perl6
12:55 lizmat r: class Dog:auth<cpan:JRANDOM>:ver<1.2.1> { }; say Dog.HOW.WHAT
12:55 camelia rakudo 37c762: OUTPUT«(Perl6::Metamodel::ClassHOW)␤»
12:55 tadzik r: say Q.WHO
12:55 camelia rakudo 37c762: OUTPUT«â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€Sâ�€â�€â�€Oâ�€â�€â�€Râ�€â�€â�€Râ�€â�€â�€Yâ�€â�€â�€!â�€â�€â�€â�€â�€â�€[â�€â�€â�€3â�€â�€â�€1â�€â�€â�€mâ�€â�€â�€=â�€â�€â�€=â�€â�€â�€=â�€â�€â�€â�€â�€â�€[â�€â�€â�€0â�€â�€â�€mâ�€â�€â�€â�¤â�€â�€â�€Câ�€â�€â�€oâ�€â�€â�€uâ�€â�€â�€lâ�€â�€â�€dâ�€â�€â�€nâ�€â�€â�€'â�€â�€â�€tâ�€â�€â�€ â�€â�€â�€fâ
12:56 tadzik wat
12:56 lizmat I assume if we want tosupport the auth, ver and name data, I would need to hack that into Perl6::Metamodel::ClassHOW, right?
12:56 tadzik lizmat: you may want to see how Perl6::Metamodel::Documentation works
12:56 tadzik this may be a similar thing
12:57 tadzik btw, PLPW schedule is online :)
12:57 tadzik criticism welcome
12:58 lizmat tadzik: src/Perl6/Metamodel/Documenting.nqp ?
12:58 tadzik lizmat: sounds about right
12:58 jnthn tadzik: I don't see it?
12:58 tadzik jnthn: not on http://act.yapc.eu/plpw2013/schedule ?
12:59 jnthn tadzik: yeahbut I don't see a link to it
12:59 lizmat there is no link to it
12:59 lizmat :-)
12:59 tadzik curious
12:59 jnthn oh, that page says "The schedule is not ready to be seen."
12:59 lizmat "The schedule is not ready to be seen."
12:59 tadzik LIES
12:59 tadzik hrm
12:59 lizmat jnthn beats me every time
12:59 tadzik show_schedule = 0
12:59 jnthn tadzik: I'd like to criticise the schedule for not being avaiable :P
12:59 tadzik show_schedule = 0
12:59 tadzik well, that could explain it...
13:01 ajr joined #perl6
13:02 tadzik and of course my university wifi blocks svn
13:02 nwc10 tadzik: even DAV over https?
13:02 tadzik surely I'm not supposed to do anything but watching youtube here
13:02 tadzik nwc10: that I didn't try
13:02 nwc10 ah OK
13:03 nwc10 it's just that I remember a (reasonable) grumble from a colleague at a job years ago about how the world seems to be reinventing wheels. At that point, re-implementing TCP-based protocols atop HTTP
13:03 nwc10 mostly driven by an arms-race to the one up on firewalls
13:05 kivutar joined #perl6
13:06 jnthn Yes, to say it's an application protocol, an awful lot chose to use HTTP as a transport...
13:06 jnthn .oO( SOAP = Screwing Other Application Protocol )
13:08 SmokeMachine joined #perl6
13:12 tadzik lizmat, jnthn: the schedule should be online now
13:12 lizmat indeed, it is
13:12 jnthn yay, I don't have to speak early in th emorning \o/
13:19 lizmat pull request posted  (my 1st!)  :-)
13:21 dalek rakudo/nom: 782dec0 | (Elizabeth Mattijsen)++ | README:
13:21 dalek rakudo/nom: Remove --gen-nqp from config instructions
13:21 dalek rakudo/nom:
13:21 dalek rakudo/nom: It appears that --gen-nqp is implied in --gen-parrot.
13:21 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/782dec0df7
13:21 dalek rakudo/nom: fe70494 | (Tobias Leich)++ | README:
13:21 dalek rakudo/nom: Merge pull request #136 from lizmat/nom
13:21 dalek rakudo/nom:
13:21 dalek rakudo/nom: Remove --gen-nqp from config instructions
13:21 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fe70494c39
13:21 lizmat FROGGS++
13:22 lizmat back to the drawing board for some more serious stuff
13:22 FROGGS well, I just clicked that shiny button :o)
13:22 FROGGS have fun
13:23 lizmat I will, that's why I'm doing this ;-)
13:23 MrMeek-afk joined #perl6
13:23 PacoAir joined #perl6
13:26 gcole joined #perl6
13:33 daniel-s joined #perl6
13:43 kaleem joined #perl6
13:48 skids joined #perl6
13:49 lizmat is there a quick way to get changes to e.g. src/core/Hash.pm to be seen by rakudo?
13:49 arlinius joined #perl6
13:50 jnthn lizmat: Typically you can try things out with augment or similar tricks in a seprate file.
13:51 lizmat I tried that yesterday: in that particular case the method I tried to supply another multi for, was not specified as multi
13:51 diakopter lizmat: is the spreadsheet misbehaving for you too?
13:51 lizmat diakopter: checking
13:52 jnthn lizmat: Well, in that case you're kinda out of luck and just need to edit the real thing :)
13:52 diakopter I had to shift-reload a few times to makeit appear
13:52 lizmat seems ok
13:52 lizmat jnthn: indeed…. but do I have to do a "make" after that?
13:52 lizmat seems so…  :-(
13:53 jnthn Yes.
13:54 kbenson joined #perl6
13:55 PerlJam lizmat: What were you adding to Hash?  Could you use a derived class as a proxy for testing purposes?
13:56 lizmat I'm trying to get Hash.new to complain about extraneous named parameters, like Niecza
13:56 lizmat n: my Hash $h .= new( a => 1 ); $h
13:56 camelia niecza v24-42-g69a3432: OUTPUT«Unhandled exception: Excess arguments to Hash.new, unused named a␤  at /home/p6eval/niecza/lib/CORE.setting line 0 (Hash.new @ 1) ␤  at /tmp/Vjgpj3D_bJ line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4329 (ANON @ 3) ␤  at /home/p6eval…
14:01 markov left #perl6
14:02 stevan__ joined #perl6
14:02 * [Coke] notes that you don't need the 1 in #?pugs 1 skip 'reason' (but can see pedagogically why you'd specify it)
14:02 [Coke] (from brent laabs article)
14:03 [Coke] lizmat: if you need a multi for testing that isn't already multi, then I'd make it multi, do the slow rebuild, and then still do your iterative testing with augment.
14:04 lizmat [Coke]: ack, will keep that in mind in the future
14:05 FROGGS joined #perl6
14:05 lizmat meanwhile, my first test worked ;=-)
14:05 lizmat $ mp6 -e 'my Hash $h .= new( a => 1 )'
14:05 lizmat Named parameters found
14:05 lizmat no on to refinement
14:05 lizmat *now
14:05 diakopter lizmat: it's not always clear whether "ack" means "I acknowledge", "augh!," or some combination/superposition/ambiguity :)
14:06 lizmat when I say "ack" I mean I acknowledge
14:06 lizmat would 'k' be better ?
14:06 hoelzro ack means the grep alternative! ;)
14:07 masak I think 'ACK' (all-caps) is fairly unambiguous.
14:07 diakopter well yes, even in "augh" there's very much an "I acknowledge"
14:07 diakopter so my question was poor
14:07 alester Whenever someone says "ack" it clicks my IRC client.
14:08 [Coke] clearly augh! should be spelled ARGLEBARGLE.
14:08 diakopter s/question/idle musing/ :/
14:08 ajr joined #perl6
14:08 lizmat alester: why would "ack" click your IRC client?
14:09 alester Because I have my IRC client set to look for mentions of "ack" and "alester" and "petdance" and a few other things.
14:09 * lizmat is opposing the urge to say "ack" a lot of times   :-)
14:09 alester Knock yourself out, lizmat
14:10 lizmat k
14:10 diakopter smack back tack slack pack rack lack thwack wrack stack plack
14:10 kivutar joined #perl6
14:10 lizmat and not a single " ack " in that
14:11 [Coke] Ash perl durbatulûk, ash nazg gimbatul; Ash perl thrakatulûk agh burzum-ishi krimpatul.
14:11 [Coke] dammit. missed one.
14:11 masak why's it suddenly so cold in here?
14:12 lizmat not sure, masack
14:12 masak I see whack you did there.
14:13 diakopter e​ack
14:13 PerlJam It's funny how memes get started sometimes.
14:13 PerlJam (other times, it's not so funny ;)
14:14 * diakopter looks in the infrared clog to see whether the zero-width space made it in there
14:15 diakopter it did!
14:16 diakopter alester: sm​ack b​ack t​ack sl​ack p​ack r​ack l​ack thw​ack wr​ack st​ack pl​ack
14:16 diakopter or does it just click max once per line
14:16 masak that probably just turned into one... right.
14:17 alester diakopter: It only clicked that once because of "alester"
14:17 diakopter d'oh
14:17 * lizmat suspect alester is using ack to match ack
14:17 lizmat suspects
14:26 diakopter is anyone looking for a somewhat mundane but easy and incredibly helpful task for Perl 6 [sortof programming, sortof not]
14:26 diakopter don't say anything if you are, and are willing to devote 100% of your life to it
14:27 diakopter awesome!
14:27 FROGGS diakopter: there is a perl6-most-wanted
14:27 FROGGS maybe there is something for you?
14:27 diakopter hrm
14:34 FROGGS_ joined #perl6
14:35 diakopter FROGGS_: I was asking for help, not volunteering. I'm already about 99**99**99**99**99 percent overcommitted
14:37 masak I'd like to remind everyone that exponentiation is right-associative.
14:37 masak not that it matters in this case :P
14:38 diakopter it matters :P
14:38 lizmat jnthn: when looking at Hash.pm, I see these 2 multi methods:
14:38 lizmat multi method delete( @keys) { @keys.map({ self.delete($^key) }) }
14:38 lizmat multi method delete(*@keys) { @keys.map({ self.delete($^key) }) }
14:38 lizmat wouldn't the *@keys version be enough?
14:39 colomon rn: sub foo(*@a) { say @a.perl; }; foo(1,2,3); foo([1,2,3])
14:39 camelia niecza v24-42-g69a3432: OUTPUT«(1, 2, 3).list␤([1, 2, 3], ).list␤»
14:39 camelia ..rakudo fe7049: OUTPUT«Array.new(1, 2, 3)␤Array.new([1, 2, 3])␤»
14:39 diakopter masak:
14:39 diakopter rn: say 4**4**4 == (4**4)**4
14:39 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«False␤»
14:39 colomon lizmat: not the same
14:39 masak diakopter: oh, of course.
14:39 masak it matters because exponentiation is not commutative.
14:41 lizmat so, now I got this: $ mp6 -e 'my Hash $h .= new( b => 2, a => 1 ); say $h'
14:41 lizmat Excess arguments to Hash.new, unused named a, b
14:41 lizmat should I add a spectest for it also, before I put in a pull request?
14:41 jnthn lizmat: Wait, should we not, like, use them?
14:42 lizmat well, perhaps:
14:42 jnthn I mean, if I do Hash.new(a => 1, b => 2) it's fairly clear what I want, I think... :)
14:42 lizmat but it was my impression that named parameters in these cases are "reserved" for additional flags
14:42 lizmat if we allow this, then we can never add a flag to the creation of a hash
14:42 masak correct.
14:43 colomon rn: sub foo(*@a) { say @a.perl; }; foo(1,2,3); foo([1,2,3], :excess-named("blue"))
14:43 jnthn True. But I don't like that we're special-casing the new method of hash to complain when nothing else does.
14:43 camelia niecza v24-42-g69a3432: OUTPUT«(1, 2, 3).list␤Unhandled exception: Excess arguments to foo, unused named excess-named␤  at /tmp/qVKm3sXQ1d line 0 (foo @ 1) ␤  at /tmp/qVKm3sXQ1d line 1 (mainline @ 6) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4329 (ANON @ 3) ␤  at /home/p6eval/niec…
14:43 camelia ..rakudo fe7049: OUTPUT«Array.new(1, 2, 3)␤Unexpected named parameter 'excess-named' passed␤  in sub foo at /tmp/DaKMGCrk7C:1␤  in block  at /tmp/DaKMGCrk7C:1␤␤»
14:44 jnthn In fact, doing so is openly hostile to the whole interface consistency thing.
14:44 jnthn Now nobody can subclass Hash, write a new that takes extra named args, and nextsame to the candidate in Hash.new.
14:45 lizmat well, if we would accept the named parameters as key/value pairs
14:46 jnthn Well, yeah, adding an error for when we get named parameters is the worst of both worlds, I suspect.
14:46 lizmat then in that case those named args would wind up in the hash with "nextsame"
14:46 lizmat I was inspired by niecza
14:46 lizmat :-)
14:47 lizmat personally, I think a subclassed "new" would need to eat its own parameters, wouldn't it?
14:47 jnthn Yeah but Niecza doesn't give that error because Hash.new is doing anything special.
14:47 jnthn It does it 'cus it doesn't implement the interface consistency bit of S12, afaik.
14:47 lizmat because you can't know whether that parameter hasn't got a meaning in a superclass
14:48 FROGGS_ diakopter: ahh, sorry, got you wrong
14:48 lizmat jnthn: so you would rather have "Hash.new(a => 1, b => 2) " to Just Work ?
14:49 * lizmat is not trying to be hostile, but to avoid pitfalls for migrating Perl 5 programmers
14:49 jnthn lizmat: I think we should either do that or just have the same behavior as any other new method (which is ignore extra names)
14:49 jnthn Of course, we may decide that isn't a good idea for new methods in general :)
14:50 jnthn (pitfalls) Hash.new(...) is not the most idiomatic of ways to make a hash in 5 or 6. :)
14:50 lizmat it is in a way, if you're coming from Bag and Set
14:50 jnthn Hm, true.
14:50 jnthn Well, maybve true
14:51 jnthn I'd probably write set(...) over Set.new(...)
14:51 moritz fwiw, I want all core types to be constructable via .new
14:51 moritz because otherwise subclassing is hard
14:51 jnthn moritz: I agree fully with that.
14:51 jnthn moritz: It's just to what degree constructors are special by type.
14:51 jnthn r: say Int.new(42)
14:51 camelia rakudo fe7049: OUTPUT«Default constructor for 'Int' only takes named arguments␤  in method new at src/gen/CORE.setting:731␤  in method new at src/gen/CORE.setting:726␤  in block  at /tmp/ATpEkSEd3_:1␤␤»
14:52 jnthn Hm, that one ain't :)
14:52 moritz if you want to subclass Int, should be able to say  my class FooInt is Int { } and have FooInt.new(42) creae a FooInt for you
14:53 thou joined #perl6
14:53 lizmat rn: my $h= hash( a => 1, b => 2, :lc); say $h
14:54 camelia niecza v24-42-g69a3432: OUTPUT«{"a" => 1, "b" => 2, "lc" => Bool::True}␤»
14:54 camelia ..rakudo fe7049: OUTPUT«("a" => 1, "b" => 2, "lc" => Bool::True).hash␤»
14:54 jnthn lizmat: I'm all for trying to remove traps people may fall in to, fwiw, I just wary about patching one case of a more general problem.
14:54 lizmat I understand
14:55 lizmat if anything, I see this as a nice exercise in my committing patches to rakudo workflow
14:56 lizmat but indeed, I see this as a more general problem as well
14:56 lizmat would be nice if you could specify with "nextsame" which keys to remove from the named parameters, e.g.
14:57 jnthn lizmat: callsame(...) lets you control exactly what is passed.
14:57 PerlJam isn't that nextwith?
14:57 lizmat so you wouldn't have to go through creating a clone of the named parameters without the ones you don't want to pass on
14:57 jnthn no, wait
14:57 jnthn nextwith
14:57 jnthn grr :)
14:57 jnthn PerlJam++
14:58 lizmat indeed: nextsame is parameterless at the moment, afaik
14:59 PerlJam r: my class MyHash is Hash { };  my MyHash $h .= new; $h.WHAT;
14:59 camelia rakudo fe7049: OUTPUT«Type check failed in assignment to '$h'; expected 'MyHash' but got 'Hash'␤  in method dispatch:<.=> at src/gen/CORE.setting:1057␤  in block  at /tmp/_8QbUTvVZI:1␤␤»
14:59 PerlJam r: my class MyArray is Array { };  my MyArray $a .= new; $a.WHAT;
14:59 camelia rakudo fe7049: OUTPUT«Cannot look up attributes in a type object␤current instr.: 'gimme' pc 285305 (src/gen/CORE.setting.pir:125270) (src/gen/CORE.setting:6051)␤called from Sub 'sink' pc 294412 (src/gen/CORE.setting.pir:128913) (src/gen/CORE.setting:6359)␤called from Sub 'MAIN' pc 381 (…
14:59 PerlJam Hmm.
14:59 PerlJam r: my class MyInt is Int { };  my MyInt $i .= new; $i.WHAT
15:00 camelia rakudo fe7049:  ( no output )
15:00 PerlJam r: my class MyInt is Int { };  my MyInt $i .= new; say $i.WHAT
15:00 camelia rakudo fe7049: OUTPUT«(MyInt)␤»
15:00 PerlJam ah, well, at least that one did as I expected :)
15:02 lizmat I guess nextsame and friends are still in need of a refactor, as I see pir:: code in there
15:02 ajr joined #perl6
15:02 lizmat or will jnthn's jvm code merge show us that?
15:03 jnthn jvm-support already got rid of some of the PIR there, iirc
15:04 lizmat anyway, I think Hash.new is special in the sense that it creates hashes
15:04 lizmat whereas other .new just use hashes
15:04 lizmat and as such may warrant a special handling
15:05 census joined #perl6
15:08 shinobicl joined #perl6
15:14 PerlJam lizmat: maybe.  You're just looking for a place to pin "other behavior" onto a hash, right?  (out-of-hash-band data)
15:15 masak it could be hurtful for someone who subclasses Hash, and expects to be able to pass named parameters into it.
15:15 lizmat PerlJam: not really
15:15 lizmat well, as long as the subclass "eats" its named parameters, there shouldn't be a problem
15:16 masak actually, to be it's *not* clear that `Hash.new( a => 1, b => 2 )` wants to populate the hash -- though the names of the named parameters certainly lean towards that conclusion.
15:16 masak but I have internalized the rules for passing parameters, so I guess I'm a bit biased.
15:16 TimToady we don't have an "eating" mechanism yet, though we've thought about it
15:17 lizmat to me, the most sense would make it if you could specify the keys to be removed from the named parameters with "nextsame"
15:17 lizmat something like "nextsame :remove('lc')"
15:17 TimToady building is not done with nextsame
15:18 TimToady it's the BUILD submethods that would remove args
15:18 markov joined #perl6
15:18 TimToady but then, removing is wrong too
15:18 TimToady what you really want is an "I've been used" flag, and a check that everything was used at least once
15:19 lizmat true
15:19 TimToady but a parent/child class could use the same argument
15:19 lizmat the most important thing is not to be silent about spelling errors in named parameters
15:20 TimToady when we start making closing/finalizing decisions and CHECK time, we can do more checks staticly
15:20 TimToady rather than slowing down construction every time
15:20 lizmat because that reduces the trust in the language
15:21 lizmat I don't think it can always be at CHECK time
15:21 TimToady no, but it might be a 95% solution
15:21 TimToady I know, let's add a last access time to every value :)
15:22 lizmat hehe… at least it won't go to disk
15:22 xinming joined #perl6
15:23 jnthn TimToady: Think is that it relies on people writing "use oo ..." pragma, which I dunno how much will happen. :)
15:23 jnthn *Thing
15:24 TimToady if the defaults are right, it'll happen by default :)
15:24 jnthn True, we could default differently :)
15:24 TimToady the default is for classes to close/finalize
15:24 TimToady unless something requests them to stay open
15:24 jnthn Oh?
15:24 TimToady it's been that way for donkey's years
15:24 jnthn S12: "Classes are open and non-final by default"
15:25 lizmat and then there's "use soft" ?
15:25 jnthn Though it goes on to say " but may easily be closed or finalized not by themselves but by the entire application, provided nobody issued an explicit compile-time request that the class stay open or non-final."
15:25 TimToady Hmm, I think the oo pragma is probably contradicting other parts of the spec...
15:26 moritz lizmat: iirc 'use soft' is about compile-time lookup of subroutines
15:26 jnthn use soft's practical upshot is mostly about .wrap.
15:26 lizmat yup, indeed
15:26 jnthn I'm not sure what "by the entire app" means here
15:27 lizmat anything between "main" and "exit" ?
15:27 jnthn I mean, if somebody is pre-compiling a module, in that case the module is the "top level" thing, so can it consider any classes that are mentioned closed?
15:27 TimToady it's not being executed though
15:28 TimToady no, module precompilation is not CHECK time in my head
15:28 TimToady why p5 has a UNITCHECK too
15:28 jnthn CHECK happens before the optimizer runs
15:28 jnthn And the optimizer had better run before we spit out the compiled code.
15:28 jnthn That's how I've had it, anyways...
15:28 TimToady but in any case CHECK can know whether it's just precompiling or not
15:28 * lizmat has to go afk for a few hours
15:31 TimToady ah, S12:2187 says the optimizer is allowed to assume oo when it thinks it can get away with it
15:31 TimToady so the oo is not required, in fact
15:33 * jnthn wonders how to know if we can get away with it ;)
15:34 moritz we just *think* we can get away with it, always
15:34 moritz then we have met the requirement :-)
15:35 jnthn # I think this will be fine
15:35 jnthn return YesOptimizeAllTheThings;
15:35 moritz exactly
15:35 TimToady You can always get away with cheating until you're caught.  :)
15:35 jnthn There's already an RT where I got caught somewhere in the optimizer :)
15:36 jnthn (Does a multi inlining that a sufficiently nasty big of mixing in can invalidate...)
15:36 TimToady so how does it currently check to see if MAIN should be run?
15:36 jnthn (Aaprt from if you did it at compile time it's too late...)
15:37 SamuraiJack joined #perl6
15:37 jnthn if !$*W.is_precompilation_mode && +@*MODULES == 0 && $unit.symbol('&MAIN') {
15:37 jnthn Where @*MODULES is the stack of modules we're in the process of loading.
15:38 jnthn So if it's empty, we're in the top level.
15:38 TimToady presumably CHECK can se the same thing (except for the need for &MAIN)
15:38 TimToady *see
15:39 TimToady precomp is not allowed to make app-wide assumptions unless they can be backed out
15:39 jnthn Right, but at the moment the optimizer tends to only influence things in the compilation unit being compiled, not any others loaded.
15:40 TimToady just sayin' we hope to do better than that someday, and the specs are tilted that way
15:40 jnthn I mean, it can inline stuff *from* another compilation unit.
15:40 jnthn I've generally thought much beyond that will boil down to JIT-time things, though.
15:40 jnthn Which is what I've mostly seen the "use oo" related stuff as useful for aiding.
15:41 jnthn So it feels like an odd peg to hang named-arg-use checking on. :)
15:41 TimToady the main place where you have to be careful is with super-apps that do application-like plugins
15:42 TimToady since you never know what might be plugged in next
15:42 TimToady so you can't make assumptions about what the next plug-in will ned
15:42 TimToady *eed
15:43 TimToady however, a sane approach might be to treat those as separate interpreters, at the cost of some duplication, so each can optimize separately
15:43 TimToady that would be a memory vs speed tradeoff again
15:45 * TimToady wonders how hard it would be to set up the named arg pairs with a bit that flips when it's been fetched
15:46 TimToady then the end of BUILDALL could just scan for False bits
15:46 jnthn At the moment, *%args is just a hash
15:47 moritz TimToady: in most settings that aren't the perl 5 VM, sneaking an extra bit in isn't easy
15:47 jnthn And it's hard to track things with a call into a user-defined BUILD.
15:48 moritz especially if we expect to compile higher-level-ish stuff like javascript
15:48 TimToady which is why you'd attach it to FETCH or some such
15:48 ingy joined #perl6
15:48 moritz *compile to
15:49 moritz and then you call foreign code, and all your guess about what has been used are off
15:49 moritz *guesses
15:50 TimToady something still has to look at the value if it's going to get into the foreign code
15:50 TimToady at worst, it just marks things read that it shouldn't
15:51 TimToady which is no worse than we do now
15:52 TimToady here's another approach
15:53 TimToady define a bitmap in the Capture where each arg knows its original position, and the binder sets the correct used bit
15:53 TimToady or maybe with bits inverted, so you can check the result against 0
15:58 TimToady I guess the problem there is that you'd have to store a position where before we just had a bit
15:58 TimToady or lookup the name again
15:59 * TimToady wants a hash whose fetcher steals unused low pointer bits...
15:59 TimToady GC, what's that?  :)
16:00 TimToady lizmat: anyway, it's a tough problem, and one we've been thinking about for a long time now...
16:01 TimToady here's another heavyhanded approach; keep the original array, and a copy; delete from the copy, and fallback to the original if you're already deleted the copy
16:02 TimToady the copy should be empty by the end of BUILDALL
16:02 jnthn TimToady: The tricky bit I don't quite see yet is how calling a user-defined BUILD will mark things as used.
16:03 jnthn Short of introspection, which is usual a bad sign. :)
16:08 TimToady well, the most obvious place to do it is in the value fetcher; since named args are weird anyway, they could use a separate type from normal hashes
16:08 TimToady the hard problem is knowing where to store the resulting "I've been used" bit
16:10 TimToady could also attach to key lookup instead of value lookup
16:10 TimToady would have the same result from the standpoint of arg checking
16:11 TimToady and if it's a different type, it could mixin storage as needed on VMs that don't allow normal hashes extra bits
16:12 * TimToady wonders, in a related vein, where the performance crossover between using a hash and a linear list of named args is...
16:13 * TimToady would not be surprised if a linear list was usually faster
16:13 TimToady (see Oberon)
16:13 jnthn I've been a little tempated to do that for the JVM port.
16:14 jnthn It doesn't actually build a hash each time though
16:14 TimToady still, you have to hash the key
16:14 jnthn It always passes named things positional-ish, and the names are associated with a callsite object.
16:14 jnthn Yeah.
16:14 jnthn So anyway, names don't get passed per call. We only go building up a hash if it's a flattening thing.
16:14 ajr joined #perl6
16:14 TimToady though hash keys can also be precomputed with sufficiently advance magic
16:16 [Coke] So, given my blind fumbling with --profile yesterday, any pointers on making my rakudo code go fasterE?
16:20 * [Coke] hurls https://gist.github.com/coke/5541613 for some ugly sample code.
16:24 jnthn [Coke]: Unpackability to tie-break a multi-dispatch is not very highly optimized yet, but otoh shouldn't be too bad.
16:27 [Coke] pretty sure that combine code was on RC. ;)
16:28 zby_home_ joined #perl6
16:28 [Coke] I was tempted briefly to harcode the combinatorics for 2-3... oh. I could hard code the positions of the combinatorics once and then iterate by array position...
16:28 [Coke] er, *calculate them once.
16:35 shinobicl left #perl6
16:36 [Coke] urk. too much javascript? I just wrote "function ..."
16:47 [Coke] Ok. instead of combining things directly, if I cache combinations of the few positional combinations I have to make, it shaves 7s off a 19s runtime.
16:47 gdey joined #perl6
16:52 TimToady [Coke]: see also http://rosettacode.org/wiki/Deal_cards_for_FreeCell#Perl_6 if you want to use Unicode card glyphs
16:55 TimToady but yeah, this is why I decided combinations should be built-in, because it's hard to code efficiently in a high-level language, so we want some grotty low-level code to do it, in lieu of the ability to write grotty low-level code in Perl 6 eventually
16:55 bluescreen10 joined #perl6
16:56 TimToady .oO( the C subset of Perl 6 :)
16:56 TimToady integer combinations might be faster done in Buf types these days
16:57 djanatyn joined #perl6
17:00 TimToady and integer combinations are a reordering slice away from combinations of anything else
17:05 TimToady a combine routine might also be faster using => lists to avoid copying
17:05 dmol joined #perl6
17:11 [Coke] TimToady: I can't even cut and paste whatever those images are into this channel to see what they are.
17:12 [Coke] (I get a board of what might be card backs.)
17:13 [Coke] probably due to a pasteo of  constant CardBlock = '????'.ord;
17:24 TimToady you're probably just getting rectangles from missing glyphs, which happen to resemble card backs :)
17:25 TimToady the real card back (used there in that line you quoted) has a filled rectangle inside the outer rectangle
17:29 ajr joined #perl6
17:33 diakopter TimToady: I need a font for "Perl 6" for the yapc t-shirt, or do you want just the insect
17:39 [Coke] Source Code Pro!
17:40 arnsholt A simple sans-serif like Helvetica perhaps?
17:41 jnthn Comic Sans!
17:41 [Coke] ... I'll allow it.
17:42 diakopter O_O
17:42 masak almost feels appropriate Ö=
17:42 masak :)
17:42 jnthn Oh no, I should stop making jokes like this...first we got #masakism, now we get comic sans on a conf t-shirt :P
17:44 timotimo is that the polish perl workshop t-shirt?
17:44 flussence .oO( I've always been fond of Inconsolata at large pt-sizes... )
17:44 timotimo also, i would recommend "Comic Jens" as a free-er alternative to comic sans
17:44 [Coke] .. that sounds like a font in search of a problem.
17:46 * geekosaur thinks it just souns like a font problem
17:47 geekosaur or problem font
17:47 diakopter Comic Sans is *sans* what?! I mean, serifs would just look silly.
17:47 jnthn .oO( I shot the serif... )
17:48 berekuk joined #perl6
17:49 timotimo being sans is a lifestyle choice.
17:50 diakopter TimToady: oh, and I need a 1-bit color version of Camelia.  white printing on blue shirt.
17:50 diakopter unless anyone else has any bright ideas for something perl6-y to put on the shirt
17:51 geekosaur .oO { that's sansible }
17:52 FROGGS_ that was the shirt of the german perl workshop this year: http://i.imgur.com/29xRJPC.gif
17:53 FROGGS diakopter: what about "$*Perl6" ?
17:54 FROGGS and camelia a the bottom
17:55 timotimo "look, we still have sigils!"
17:59 FROGGS and you could even in smaller letter under the camelie: .WHERE = 'Austin'\n.WHO = ...
18:00 diakopter there isn't much space already
18:01 diakopter the letters would just be dots
18:01 diakopter we're talking like 1.5" x 3" total real estate
18:02 TimToady you want a level Camelia or an angled one?  white-on-blue will take some work
18:03 diakopter well, do you even want Camelia?
18:03 diakopter it's a very small space
18:03 TimToady you're the one said you wanted Camelia!
18:04 masak FROGGS: looks like they drove a stake through the onion's chest.
18:04 diakopter the hot potato is in your court
18:04 * TimToady tends to just let hot potatoes land on the floor
18:06 masak so *that's* why Perl has hashes!
18:07 masak :P
18:14 geekosaur that'd be more why it has globs, and why those are represented with splats...
18:17 diakopter TimToady: I guess in white-on-navy the P and 6 in Camelia would be pretty distinct
18:18 timotimo FROGGS: i may not bethe typical target-audience-member, but i prefer more graphics, less text TBH
18:19 timotimo to me, the specific date range - for instance - is way too much for a tshirt i would enjoy wearing
18:22 donaldh joined #perl6
18:23 TimToady diakopter: hard part is getting the outline in white, if you don't want to reverse light/dark
18:24 SmokeMachine joined #perl6
18:25 donaldh_ joined #perl6
18:31 diakopter I need something to submit by next Sunday
18:31 diakopter *this Sunday
18:32 FROGGS masak: should be the (famous) berlins tv-tower
18:32 FROGGS berlin*
18:33 masak oh, ok.
18:33 FROGGS timotimo: same for me but I got outvoted :o(
18:36 dalek nqp/rak-jvm-support: 591cd61 | (Donald Hunter)++ | / (6 files):
18:36 dalek nqp/rak-jvm-support: Switched readlineintfh to use JLine ConsoleReader
18:36 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/591cd61e48
18:36 dalek nqp/rak-jvm-support: cb93f41 | (Donald Hunter)++ | tools/build/Makefile-JVM.in:
18:36 dalek nqp/rak-jvm-support: Fixed whitespace typo in install target.
18:36 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/cb93f41304
18:36 dalek nqp/rak-jvm-support: 211d54c | (Donald Hunter)++ | tools/build/install-jvm-runner.pl:
18:36 dalek nqp/rak-jvm-support: Fixed runner generator to include jline jar.
18:36 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/211d54c5de
18:36 dalek nqp/rak-jvm-support: f99d3db | jnthn++ | / (7 files):
18:36 dalek nqp/rak-jvm-support: Merge branch 'repl' of https://github.com/donaldh/nqp into rak-jvm-support
18:36 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/f99d3dbc07
18:36 jnthn aww, it lost a commit
18:37 jnthn There was one more.
18:38 FROGGS (Donald Hunter)++ # here we go
18:39 jnthn no, it was by me :P
18:40 diakopter https://github.com/perl6/nqp/commit/a5942d50d3d6e301301371e042d1c68793d6c99f
18:40 donaldh jnthn: There's a matching pull request for rakudo/jvm-support
18:40 yoleaux 7 May 2013 23:27Z <jnthn> donaldh: thanks for the PR; I need to tweak it a bit before I can apply it, as it seems spaces instead of tabs got into the Makefile and the .bat needs updating as well as the .sh runner. Otherwise seems fine...will get to it tomorrow
18:40 dalek rakudo/jvm-support: 9c60c91 | (Donald Hunter)++ | tools/build/Makefile-JVM.in:
18:40 dalek rakudo/jvm-support: Add jline jar and missing cleanups.
18:40 dalek rakudo/jvm-support: review: https://github.com/rakudo/rakudo/commit/9c60c918aa
18:40 dalek rakudo/jvm-support: f513db4 | (Donald Hunter)++ | / (2 files):
18:40 dalek rakudo/jvm-support: Fixes for --with-nqp=... removed hardcoded install-jvm
18:40 dalek rakudo/jvm-support: review: https://github.com/rakudo/rakudo/commit/f513db4136
18:41 jnthn donaldh: Noticed you caught the tab/space thing yourself :)
18:41 donaldh Yep
18:41 donaldh Grr. Eclipse being too clever.
18:42 grondilu joined #perl6
18:42 frdmn joined #perl6
18:42 grondilu rn: say my Int $ = "4";
18:42 camelia rakudo fe7049: OUTPUT«Type check failed in assignment to '$'; expected 'Int' but got 'Str'␤  in block  at /tmp/jDWygnMVVc:1␤␤»
18:42 camelia ..niecza v24-42-g69a3432: OUTPUT«Unhandled exception: Nominal type check failed for scalar store; got Str, needed Int or subtype␤  at /tmp/e70sRrtMhM line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4329 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4330 …
18:43 grondilu shouldn't a conversion be made automatically?
18:43 jnthn No
18:43 jnthn It's a type constraint.
18:43 grondilu :/
18:44 japhb_ joined #perl6
18:44 FROGGS ohh
18:44 [Coke] r: say my Int $ = "4".Int;
18:44 camelia rakudo fe7049: OUTPUT«4␤»
18:44 FROGGS jnthn++
18:45 grondilu But if I want to read an integer from stdin, then I have to do:  my Int $ = get.Int;  That's annoying.
18:45 masak grondilu: you don't expect a conversion to be made automatically when you try to assign an Employee object to a variable typed as Subscription. so why with Str and Int?
18:46 timotimo grondilu: try +get
18:46 grondilu rn: say my Int $ = +"4";
18:46 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«4␤»
18:46 grondilu timotimo: good idea.  It's much less bothersome.
18:49 grondilu also, get xx $someInt  is not parsed correctly.  Rakudo complains about the function xx not existing.  I have to write get() xx $someInt.   Shouldn't get xx $someInt be parsed as such?
18:49 masak heh, I remember submitting tickets and being generally noisy to make prefix:<+> produce the narrowest type possible, so that typing it Int there would work :)
18:49 masak grondilu: no, because 'get' is a listop.
18:50 masak grondilu: and so the parser expects a term, not an infix.
18:51 timotimo right, compare with get 1024 which would be get(1024)
18:51 masak put differently, 'get xx $someInt' is short for 'get( xx $someInt )'
18:53 FROGGS if there was a xx prefix it will do the wrong thing silently
18:55 masak r: sub prefix:<xx>($) { "the wrong thing silently" }; say xx 42
18:55 camelia rakudo fe7049: OUTPUT«the wrong thing silently␤»
19:02 kst` joined #perl6
19:06 TimToady diakopter: first whack at white-on-blue Camelia: http://wall.org/~larry/cameliawb.png
19:06 diakopter like
19:07 TimToady don't know if trying for shading would help at all
19:07 diakopter but.. it's purple
19:07 TimToady it's "blue 2" to LibreDraw
19:08 lizmat not a color you would expect with Chromakey
19:08 diakopter I didn't *think* I was colorblind...
19:08 diakopter I'd send you a screenshot, but ..... *giggle*
19:09 TimToady anyway, you'd probably want that part transparent for actual printing
19:09 donaldh joined #perl6
19:10 lizmat rn: my $s= set( a => 1, b => 0 ); say $s
19:10 camelia rakudo fe7049: OUTPUT«2 unexpected named parameters passed (a, b)␤  in sub set at src/gen/CORE.setting:13063␤  in block  at /tmp/I_EuAWUac3:1␤␤»
19:10 camelia ..niecza v24-42-g69a3432: OUTPUT«Unhandled exception: Excess arguments to set, unused named a, b␤  at /home/p6eval/niecza/lib/CORE.setting line 0 (set @ 1) ␤  at /tmp/cHLsGLCQ34 line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4329 (ANON @ 3) ␤  at /home/p6eval/niecza…
19:11 lizmat it wasn't me, I didn't do it
19:11 [Coke] is it me, or does that image have 3 colors?
19:11 diakopter O_O
19:11 diakopter oh yes, there's a black arc
19:12 diakopter well, and a gray TM
19:14 lizmat rn: my $s= Set.new( a => 1, b => 0 ); say $s
19:14 camelia rakudo fe7049: OUTPUT«set()␤»
19:14 camelia ..niecza v24-42-g69a3432: OUTPUT«Unhandled exception: Excess arguments to Set.new, unused named a, b␤  at /home/p6eval/niecza/lib/CORE.setting line 0 (Set.new @ 1) ␤  at /tmp/t83smByPIU line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4329 (ANON @ 3) ␤  at /home/p6eva…
19:14 lizmat I'm not sure I understand the difference between set() and Set.new  :-(
19:19 moritz wow, mysql does funny things
19:19 moritz SELECT DATE('2012-06-14') - DATE('2005-02-26');
19:19 moritz 70388
19:20 moritz r: say 20120614 - 20050226
19:20 camelia rakudo fe7049: OUTPUT«70388␤»
19:22 diakopter moritz: try DATEDIFF('2012-06-14 23:59:59', '2005-02-26');
19:22 moritz diakopter: I found that too; was just curious what it actually did
19:22 * lizmat always used TO_DAYS()
19:22 grondilu rn: my Bag $bag .= new: <foo foo bar>; for $bag.keys X $bag.keys -> $a, $b { say $a, $b }
19:22 lizmat if I remember correctly
19:22 camelia rakudo fe7049:  ( no output )
19:22 camelia ..niecza v24-42-g69a3432: OUTPUT«foofoo␤foobar␤barfoo␤barbar␤»
19:23 TimToady new version really in 2 colors
19:24 grondilu should I report this bug?
19:24 moritz r: my Bag $bag .= new: <foo foo bar>; say $bag.keys.perl
19:24 camelia rakudo fe7049: OUTPUT«("foo", "bar").list␤»
19:25 moritz grondilu: yes please
19:25 * grondilu does it
19:26 PerlJam moritz: but why were you asking mysql about dates when you have a perfectly good Perl 6 compiler you could ask?   ;)
19:26 lizmat rn: my $s= set( ( a => 1, b => 0 ) ); say $s
19:26 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«set(a, b)␤»
19:26 moritz PerlJam: because the IR Clogs use mysql as a backend, not Perl 6 :-)
19:27 moritz PerlJam: but I did cross-check with rakudo's Date :-)
19:28 TimToady diakopter: anyway, original is in .odg, so can export in any convenient format; lemme know if you want it tilted
19:29 PerlJam That's my primary usage of Rakudo I think.   I tend to run little snippets ... sometimes I'm testing Perl 6 stuff, but many times I'm actually using the REPL for it's computing ability in one way or another.
19:29 dalek nqp/rak-jvm-support: 199e8b6 | jnthn++ | / (2 files):
19:29 dalek nqp/rak-jvm-support: Prepare for some extra :decl(...) possibilities.
19:29 dalek nqp/rak-jvm-support:
19:29 dalek nqp/rak-jvm-support: These will cover things that today require code generation or are not
19:29 dalek nqp/rak-jvm-support: available at NQP level, but probably should be. It will allow Perl 6's
19:29 dalek nqp/rak-jvm-support: custom lexpad type to be eliminated in favor of the shared NQP one, as
19:29 dalek nqp/rak-jvm-support: well as simplifying code generation for certain constructs and giving
19:29 dalek nqp/rak-jvm-support: us a freer hand in how we compile time. Mostly, this just documents
19:29 dalek nqp/rak-jvm-support: the new things.
19:29 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/199e8b6e8b
19:32 * lizmat feels stupid for not being able to find where set() is specced
19:33 lizmat S02:1419 ?
19:34 TimToady yes
19:35 lizmat S32/Containers:1102 states: "A C<Set> responds to hash operators as if it were a C<Hash of True>."
19:35 lizmat somehow that doesn't feel right with including "b" in the set with this:
19:35 lizmat my $s= set( ( a => 1, b => 0 ) ); say $s
19:36 lizmat set(a, b)
19:36 lizmat I would have expected: set(a)
19:36 PerlJam r: my $s = set( a => 1, b => Nil ); say $a;
19:36 camelia rakudo fe7049: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Variable '$a' is not declaredâ�¤at /tmp/YCgWYxN6hs:1â�¤------> [32mmy $s = set( a => 1, b => Nil ); say $a[33mâ��[31m;[0mâ�¤    expecting any of:â�¤        postfixâ�¤Â»
19:36 PerlJam r: my $s = set( a => 1, b => Nil ); say $s;
19:36 camelia rakudo fe7049: OUTPUT«2 unexpected named parameters passed (a, b)␤  in sub set at src/gen/CORE.setting:13063␤  in block  at /tmp/sEn4GBfuEl:1␤␤»
19:37 PerlJam r: my $s = set( (a => 1, b => Nil) ); say $s;
19:37 camelia rakudo fe7049: OUTPUT«set(a, b)␤»
19:37 PerlJam r: my $s = set( (a => 1, b => ) ); say $s;
19:37 camelia rakudo fe7049: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix => instead�at /tmp/C4lmoSdnVs:1�------> [32mmy $s = set( (a => 1, b => [33m�[31m) ); say $s;[0m�»
19:37 PerlJam r: my $s = set( (a => 1, b => False ) ); say $s;
19:37 camelia rakudo fe7049: OUTPUT«set(a, b)␤»
19:37 * PerlJam fails at using the bot today
19:37 moritz r: say set( 'a', 'b')
19:37 camelia rakudo fe7049: OUTPUT«set(a, b)␤»
19:37 TimToady it's assuming that anything with keys came from another set, where you'd never get a False value becuase they're autodeleting
19:38 donaldh joined #perl6
19:38 TimToady nr: my $s = set( set(1,2) ); say $s.perl
19:38 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«set("1", "2")␤»
19:39 TimToady but that should probably not flatten there
19:39 lizmat rn: my %h= ( a => 1, b => 0 ); my $s= set(%h); say $s
19:39 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«set(a, b)␤»
19:39 TimToady nr: my $s = set( set(1,2).item ); say $s.perl
19:39 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«set("1", "2")␤»
19:39 TimToady that should *definitely* not flatten with .item
19:40 TimToady so I'd say it should be ripping out the whole pair/hash recognition thing in any case
19:40 TimToady otherwise we can't have a set of sets
19:41 moritz so sets don't make the assumptions that elements are strings?
19:41 TimToady shouldn't
19:42 thou joined #perl6
19:42 TimToady nr: my $s = set(1,2); say set($s).perl
19:42 camelia rakudo fe7049, niecza v24-42-g69a3432: OUTPUT«set("1", "2")␤»
19:42 lizmat S32/Containers:1112 "Regardless of their behavior as hashes, Sets and Bags do not flatten in list context." I assume?
19:42 TimToady yes
19:43 TimToady for that reason
19:43 TimToady so current implementations are a bit spec-rotted :)
19:43 lizmat but what would "keys" give on the outer set() of sets?
19:44 TimToady it would give the inner set as the key
19:44 moritz a list of sets
19:44 lizmat duh, of course
19:45 lizmat and the value would be True?
19:45 * TimToady doesn't recall whether anyone has bothered to implement object-keyed hashes yet...
19:45 * lizmat is pretty that hasn't happened yet
19:45 lizmat *sure
19:45 moritz TimToady: rakudo does them, iirc
19:45 TimToady .oO(sure pretty?)
19:46 jnthn r: my %h{Any}; %h{2} = 'two'; say %h.keys[0].WHAT
19:46 camelia rakudo fe7049: OUTPUT«(Int)␤»
19:46 moritz r: my %h{Any}; %h{1} = 2; say %h.keys[0].^name
19:46 camelia rakudo fe7049: OUTPUT«Int␤»
19:46 moritz oh, jnthn++ was faster
19:46 * jnthn bovvad :P
19:46 jnthn I think the Set code may have been borrowed from Niecza, which iirc doesn't do object-keyd hashes.
19:47 lizmat r: my %h= ( set(<a b>) => 1 ); say %h
19:47 camelia rakudo fe7049: OUTPUT«("a b" => 1).hash␤»
19:47 jnthn So it may not be too hard to update them to use them in Rakudo.
19:47 lizmat is this an artefact of the gist ?
19:48 jnthn lizmat: No, string keys are the default.
19:48 jnthn r: my %h{Mu} = ( set(<a b>) => 1 ); say %h
19:48 camelia rakudo fe7049: OUTPUT«(set("a", "b") => 1).hash␤»
19:48 TimToady sets need to be taught to default to Any instead
19:48 TimToady or Mu
19:48 TimToady if you want junctions as set elements :)
19:49 TimToady that seems likely to lead to a world of hurt, however...
19:49 jnthn May just be chaning "has %!elems;" to has %!elems{Any};
19:49 jnthn *changing
19:49 TimToady too easy, hasta be harder
19:49 jnthn yeah, that probably hits bootstrap issues :P
19:49 TimToady vicarious suffering, and all that
19:50 * jnthn is in the middle of de-Parroting another chunk of Rakudo at the moment, but could look at it in a bit if nobody beats him to it :)
19:50 * TimToady should eat lunch an hour ago instead of blue-printing Camelia
19:51 lizmat Tardis is out of order :-(
19:51 arnsholt jnthn: Now that $dayjob is less crazy, I'm wondering: How much of my semi-completed 6modelisation work of NQP/Parrot has been done by you in the meantime?
19:53 * tadzik grins at YE2013 tag cloud
19:53 tadzik "perl perl5 perl6 perl7"
19:53 donaldh jnthn: Any thoughts about source level debugging in nqp/jvm, i.e. what pieces are missing and whether it's an approachable piece of work?
19:53 * masak , just for fun, tries spectesting a ' has %!elems{Any};' change
19:54 lizmat jnthn: vm/parrot/guts/bind.c lines 1036 through 1061 seem to be in violation of S12 (just like my proposal to fix Hash.new)
19:54 masak tadzik: good news is no-one is all excited about perl4 any more :P
19:54 lizmat willing to cut it out for you and spectest that
19:55 masak let the spectesting begin!
19:55 tadzik masak: well, "Submit talk", here I come :P
19:55 moritz experimental new design for http://irclog.perlgeek.de/perl6/
19:56 moritz please tell me if it makes sense to you, and if you like it
19:56 tadzik did we just click it all at once?
19:56 ck2 joined #perl6
19:56 tadzik doesn't load here :)
19:56 jnthn lizmat: I...don't think it is.
19:56 jnthn lizmat: What bit of S12?
19:56 tadzik moritz: the darker the more active?
19:57 lizmat jnthn: me is checking the exact location
19:57 jnthn arnsholt: Not loads; I've mostly been working on the things we need for Rakudo. I did much of the HLL related changes, though...
19:57 masak tadzik: I dare you to submit a perl4 talk! :D
19:57 jnthn donaldh: The most immediately obvious missing piece is getting the line numbers stored.
19:58 donaldh In the generated .class es
19:58 moritz tadzik: yes. (At least that was the idea; I now think I accidentally reveresed the colors :-)
19:58 jnthn donaldh: Yes.
19:59 jnthn donaldh: I'm guessing asm must have a way to do that side of things.
19:59 donaldh jnthn: Yep, I think so.
19:59 jnthn donaldh: The other piece is getting the QAST -> JAST phase to stash the info somewhere.
19:59 lizmat jnthn: http://irclog.perlgeek.de/perl6/2013-05-08#i_7035348
19:59 arnsholt jnthn: Cool. I'll probably start off trying to get more of that in place then. I've seen some talk of list speedups. Is that QRPA (or something similar to that) being created for nqp::list instead of RPA?
20:00 moritz yes, at least for $!storage in List (iirc)
20:00 jnthn donaldh: Once that's in I guess the backtrace printing can be updated to include the info too... :)
20:01 jnthn lizmat: I'm not sure I see the issue. I was saying that Rakudo got things right.
20:01 donaldh jnthn: yep I wondered if there was still QAST transform work to be done. I'll take a look at it.
20:01 jnthn donaldh: lemme give you a few pointers...
20:01 lizmat r: my $s= set( a => 1); say $s
20:01 camelia rakudo fe7049: OUTPUT«Unexpected named parameter 'a' passed␤  in sub set at src/gen/CORE.setting:13063␤  in block  at /tmp/y28aZn06vw:1␤␤»
20:01 tadzik masak: I'm considering submitting "Perl Workshop for Dummies"
20:02 donaldh jnthn:  much appreciated
20:02 tadzik but I'll probably wait to see how it turns out on plpw
20:02 masak tadzik: sounds nice :)
20:02 lizmat jnthn: I would expect that to fail silently
20:02 tadzik http://act.yapc.eu/plpw2013/talk/4813 that one
20:03 lizmat jnthn: or am I missing something here?
20:04 jnthn lizmat: moment, lemme look the things up for donaldh++ first... :)
20:04 lizmat okidoki!
20:04 * jnthn needs more pairs of hands to type on more keyboards...
20:04 masak tadzik: s/Do'h/D'oh/
20:04 jnthn donaldh: The QAST nodes sometimes have a .node set. You can see some places it's used around https://github.com/perl6/nqp/blob/master/src/vm/parrot/QAST/Compiler.nqp#L618
20:05 lizmat masak: duh!
20:05 tadzik masak: Do'h. Fixed
20:05 jnthn donaldh: The way it's done here is that PIRT::Node got a .node method also. YOu could instead just have a JAST::Annotation however
20:06 masak tadzik: ;)
20:06 bluescreen100 joined #perl6
20:06 masak or should I say "he'h".
20:06 tadzik h'eh
20:06 moritz h'e'h
20:06 jnthn donaldh: https://github.com/perl6/nqp/blob/master/src/vm/parrot/QAST/PIRT.nqp#L287 shows how $!node can be used in order to obtain a line number.
20:07 * TimToady suddenly feels like he's in a fantasy novel...
20:07 moritz r: sub h'e'h() { say "d'o'h" }; h'e'h
20:07 camelia rakudo fe7049: OUTPUT«d'o'h␤»
20:07 jnthn donaldh: It does a little work to try and avoid duplicate generations.
20:07 TimToady P'erl 6
20:07 jnthn donaldh: er, repetitions of the same line number, I mean.
20:07 donaldh jnthn: Yep, I'll check to see if asm already covers that case.
20:08 jnthn donaldh: Anyway, the critical pieces are that QAST nodes may have a .node (not all of 'em, by any means) and that HLL::Compiler.lineof can use that to produce a line number. :)
20:09 jnthn donaldh: There's only one file per compilation unit so that's easy to handle :)
20:09 donaldh jnthn: Great, that gives me an idea of where to start :-)
20:09 bruges joined #perl6
20:10 jnthn lizmat: iiuc, the confusion may be that the rules for methods and subs are different.
20:10 jnthn lizmat: Methods that are not in an "is hidden" class get an extra *%_ parameter by default.
20:10 lizmat jnthn: that might well be
20:10 jnthn lizmat: Subs do not.
20:10 jnthn lizmat: That code path in the binder is not hit for methods because thee is a *%_ which noms all the left-over nameds.
20:11 jnthn *there
20:11 jnthn lizmat: It's there for subs, blocks, etc.
20:11 jnthn Or methods marked "is hidden"
20:11 jnthn er, methods *in classes* marked "is hidden", I meant.
20:11 lizmat so, that's why set() complains, and Set.new is silent
20:11 jnthn *nod*
20:12 lizmat feels like an implementation artefact to me  :-(
20:12 lizmat but if that's the way it is supposed to be, I'll stop nagging  :-)
20:14 jnthn lizmat: Well, I'm only saying "the current implementation's handling of leftover nameds matches the spec as far as I know", not "set and Set.new are doing the right things" :)
20:14 lizmat fair enough  :-)
20:15 lizmat I'll make an issue for it, so (Any) can think / respond to it
20:15 lizmat I guess there aren't that many builtins that take named parameters
20:33 [Coke] http://irclog.perlgeek.de/perl6/ is hanging for me, btw.
20:35 lizmat ditto
20:41 lizmat working again now
20:46 * lizmat will sleep a night before starting a new issue&
20:51 masak 'night, lizmat
20:51 [Coke] http://irclog.perlgeek.de/perl6/ is still hanging for me.
21:18 SmokeMachine joined #perl6
21:54 labster ^ That URL takes a long time to load.  But I do like the calendar view.
21:54 * labster clicks a random log from 2005
21:55 labster "I think File::Spec's behavior could accomplished with Roles"
21:55 masak 'night, #perl6
21:55 labster o.O
21:55 labster night masak
21:56 kurahaupo joined #perl6
22:14 dalek nqp/rak-jvm-support: c088706 | jnthn++ | src/vm/parrot/pmc/nqplex (2 files):
22:14 dalek nqp/rak-jvm-support: Start updating NQPLexPad/NQPLexInfo.
22:14 dalek nqp/rak-jvm-support:
22:14 dalek nqp/rak-jvm-support: This gives them the ability to handle containers; state vars still to
22:14 dalek nqp/rak-jvm-support: come.
22:14 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/c088706a6f
22:14 dalek nqp/rak-jvm-support: c6a5294 | jnthn++ | src/vm/parrot/QAST/Compiler.nqp:
22:14 dalek nqp/rak-jvm-support: Compile QAST::Var decl static/contvar/statevar.
22:14 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/c6a52947f5
22:14 dalek nqp/rak-jvm-support: c088706 | jnthn++ | src/vm/parrot/pmc/nqplex (2 files):
22:14 dalek nqp/rak-jvm-support: Start updating NQPLexPad/NQPLexInfo.
22:14 dalek nqp/rak-jvm-support:
22:14 dalek nqp/rak-jvm-support: This gives them the ability to handle containers; state vars still to
22:14 dalek nqp/rak-jvm-support: come.
22:14 dalek nqp/rak-jvm-support: review: https://github.com/perl6/nqp/commit/c088706a6f
22:14 dalek nqp/rak-jvm-support: c6a5294 | jnthn++ | src/vm/parrot/QAST/Compiler.nqp:
22:14 jnthn huh, why'd it report 'em twice...
22:16 timotimo (and then stop in the middle)
22:55 itz_ joined #perl6
22:59 jnthn Almost there with getting rid of the Perl6LexPad/Perl6LexInfo PMCs completely. Should be able to get that bit out of the way tomorrow and move on to the next challenge in the porting. :)
23:02 skids joined #perl6
23:02 labster sounds great
23:11 [Coke] jnthn++
23:18 jnthn 'night o/
23:25 [Coke] rakudo makes me write better code because if I did it the wrong way it woudl be waaaay too slow. :P
23:40 MrMeek joined #perl6

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

Perl 6 | Reference Documentation | Rakudo