Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2013-03-30

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:01 diakopter r: say q:to('\'');␤'␤
00:01 p6eval rakudo 897636: 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:02 cognominal joined #perl6
00:02 japhb_ .u ALIAS
00:02 yoleaux No characters found
00:03 japhb_ .u SAME
00:03 yoleaux U+05E1 HEBREW LETTER SAMEKH [Lo] (ס)
00:03 yoleaux U+FB41 HEBREW LETTER SAMEKH WITH DAGESH [Lo] (סּ)
00:03 yoleaux U+1084E IMPERIAL ARAMAIC LETTER SAMEKH [Lo] (𐡎)
00:03 diakopter .u BIND
00:03 yoleaux U+0A01 GURMUKHI SIGN ADAK BINDI [Mn] (◌ਁ)
00:03 yoleaux U+0A02 GURMUKHI SIGN BINDI [Mn] (◌ਂ)
00:03 yoleaux U+1BFC BATAK SYMBOL BINDU NA METEK [Po] (᯼)
00:05 pecastro joined #perl6
00:06 FROGGS gnight all (will read backscroll)
00:10 BenGoldberg joined #perl6
00:15 cognominal joined #perl6
00:17 BenGoldberg pugs: say $?OS
00:17 p6eval pugs: OUTPUT«darwin␤»
00:17 BenGoldberg p6: say $?OS
00:17 p6eval niecza v24-35-g5c06e28: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at Niecza.StashCursor.Core (System.String key, Boolean final, Niecza.StashCursor& sc, Niecza.Variable& v, Niecza.Variable bind_to) [0x00000] in <file…
00:17 p6eval ..rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable '$?OS' is not declared�at /tmp/ZZETwDElq3:1�------> [32msay $?OS[33m�[31m<EOL>[0m�    expecting any of:�        postfix�»
00:18 japhb_ p6: say $*OS
00:18 p6eval niecza v24-35-g5c06e28: OUTPUT«Unix␤»
00:18 p6eval ..rakudo 897636: OUTPUT«linux␤»
00:18 japhb_ BenGoldberg, ^^
00:19 BenGoldberg Ahh, I see :)
00:21 BenGoldberg Well, regardless, why does niecza throw a System.NullReferenceException, whereas rakudo complains about $?OS being undeclared?
00:21 BenGoldberg Surely only of those one behaviors is correct, no?
00:22 adu_ ok so apparently <keyword:sym<break>> is equivalent to <keyword> which I don't like
00:22 diakopter BenGoldberg: it appears niecza is dieing during its parsing phase
00:23 diakopter (ungracefully)
00:23 colomon std: say $?OS
00:23 p6eval std 86b102f: OUTPUT«ok 00:00 42m␤»
00:23 BenGoldberg std: say $*OS
00:23 p6eval std 86b102f: OUTPUT«ok 00:00 42m␤»
00:24 japhb_ BenGoldberg, an NRE, like a Java NPE or Parrot NPMCA, is a bug anytime you see it.  A low-level error like that should not be allowed to bubble up to the user.
00:24 japhb_ (Well, not in raw form, at least.)
00:27 BenGoldberg So how do I report the bug?
00:27 diakopter niecza's not fixing bugs like that right now
00:28 cognominal joined #perl6
00:28 diakopter niecza's not being currently developed
00:29 diakopter urp
00:30 benabik joined #perl6
00:31 fildon joined #perl6
00:32 japhb_ r: sub r1($s) { my %*C; %*C{$s} = %*C.elems + 1; r2($s); }; sub r2($s) { return r1($s) unless %*C; r1("c"), r1("d"); say %*C; }; r2("a"); r2("b");
00:32 p6eval rakudo 897636: OUTPUT«maximum recursion depth exceeded␤current instr.: 'print_exception' pc 108115 (src/gen/CORE.setting.pir:48762) (src/gen/CORE.setting:9521)␤called from Sub 'defined' pc 157863 (src/gen/CORE.setting.pir:68905) (src/gen/CORE.setting:720)␤called from Sub '' pc 11528 (sr…
00:33 japhb_ r: sub r1($s) { my %*C; %*C{$s} = %*C.elems + 1; r2(); }; sub r2($s?) { return r1($s) unless %*C; unless $s { r1("c"); r1("d"); }; say %*C; }; r2("a"); r2("b");
00:33 p6eval rakudo 897636: OUTPUT«maximum recursion depth exceeded␤current instr.: 'print_exception' pc 108115 (src/gen/CORE.setting.pir:48762) (src/gen/CORE.setting:9521)␤called from Sub 'at_key' pc 296880 (src/gen/CORE.setting.pir:130376) (src/gen/CORE.setting:6689)␤called from Sub 'at_key' pc 18…
00:34 cognominal__ joined #perl6
00:42 BenGoldberg r: srand( 10 ); say sort { rand }, 1..20
00:42 p6eval rakudo 897636: OUTPUT«17 14 5 3 11 4 16 12 8 19 9 7 20 13 2 1 6 10 15 18␤»
00:42 BenGoldberg std: srand( 10 ); say sort { rand }, 1..20
00:42 p6eval std 86b102f: OUTPUT«ok 00:00 44m␤»
00:43 BenGoldberg std: say 1
00:43 p6eval std 86b102f: OUTPUT«ok 00:00 41m␤»
00:43 japhb_ Gah.  The 'my %*CACHE' thing doesn't work right for mutual recursion to more levels:
00:43 japhb_ r: sub r1($i) { my %*C; %*C{$i} = %*C.elems + 1; r2($i - 1); }; sub r2($i?) { return r1($i) unless %*C; say %*C; r1($i - 1) if $i > 0 }; r2(4); r2(3);
00:43 p6eval rakudo 897636: OUTPUT«("4" => 1).hash␤("2" => 1).hash␤("0" => 1).hash␤("3" => 1).hash␤("1" => 1).hash␤»
00:43 japhb_ Changing to state doesn't help, of course:
00:43 japhb_ r: sub r1($i) {state %*C; %*C{$i} = %*C.elems + 1; r2($i - 1); }; sub r2($i?) { return r1($i) unless %*C; say %*C; r1($i - 1) if $i > 0 }; r2(4); r2(3);
00:43 p6eval rakudo 897636: OUTPUT«("4" => 1).hash␤("4" => 1, "2" => 2).hash␤("4" => 1, "2" => 2, "0" => 3).hash␤("4" => 1, "2" => 2, "0" => 3, "3" => 4).hash␤("4" => 1, "2" => 2, "0" => 3, "3" => 4, "1" => 5).hash␤»
00:44 japhb_ temp gives a strange error:
00:44 japhb_ r: sub r1($i) { temp %*C; %*C{$i} = %*C.elems + 1; r2($i - 1); }; sub r2($i?) { return r1($i) unless %*C; say %*C; r1($i - 1) if $i > 0 }; r2(4); r2(3);
00:44 p6eval rakudo 897636: OUTPUT«Can only use 'temp' on a container␤  in sub prefix:<temp> at src/gen/CORE.setting:12871␤  in sub r1 at /tmp/2OlMhchjQ1:1␤  in sub r2 at /tmp/2OlMhchjQ1:1␤  in block  at /tmp/2OlMhchjQ1:1␤␤»
00:44 japhb_ I'm assuming it means a scalar container there.
00:45 japhb_ Time to go ruminate on it over dinner, I think.
00:46 BenGoldberg r: temp $*C = 1; say $*C
00:46 p6eval rakudo 897636:  ( no output )
00:46 cognominal__ joined #perl6
00:58 raiph lue: thoughts on slang syntax (in response to https://gist.github.com/lue/5241230 ):
01:00 raiph just 1 thought really. might it work well to view an action as a phaser?
01:03 adu_ joined #perl6
01:04 adu_ ok, so it thinks 'main' in 'int main();' is a typedef, and so it never backtracks, so the parse fails
01:04 diakopter rn: temp $_[0]; say "alive" # rakudo exits ungracefully
01:04 p6eval rakudo 897636:  ( no output )
01:04 p6eval ..niecza v24-35-g5c06e28: OUTPUT«alive␤»
01:05 diakopter rn: temp $_; say "alive"
01:05 p6eval rakudo 897636:  ( no output )
01:05 p6eval ..niecza v24-35-g5c06e28: OUTPUT«alive␤»
01:08 BenGoldberg p6: exit 0
01:08 p6eval rakudo 897636, niecza v24-35-g5c06e28:  ( no output )
01:08 BenGoldberg p6: exit 1
01:08 p6eval rakudo 897636, niecza v24-35-g5c06e28:  ( no output )
01:08 cognominal joined #perl6
01:08 adu_ so basically, I'm trying to match "aa" with /a+a/
01:09 BenGoldberg p6: print 'aa' ~~ /a+a/
01:09 p6eval rakudo 897636: OUTPUT«aa»
01:09 p6eval ..niecza v24-35-g5c06e28:  ( no output )
01:11 BenGoldberg Twould be nice if p6eval outputed the exit code of whichever perl6 program it's using
01:12 adu_ BenGoldberg: how do you do that with complicated a's
01:13 BenGoldberg p6: print 'abcabd' ~~ /(ab.)\1/
01:13 p6eval niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��Unsupported use of the 1-based special form '\1' as a backreference; in Perl 6 please use the 0-based variable '$0' instead at /tmp/qaN2BPoJYB line 1:�------> [32mprint 'abcabd' ~~ /(ab.)\1[33m�[31m/[0m��Action method ba…
01:13 p6eval ..rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Unrecognized backslash sequence: '\1'�at /tmp/YoZdB0vQeV:1�------> [32mprint 'abcabd' ~~ /(ab.)\[33m�[31m1/[0m�    expecting any of:�        postfix�        infix stopper�        infix or meta-infix�        prefix or term�        Ã¢â‚¬Â¦
01:13 BenGoldberg p6: print 'abcabd' ~~ /(ab.)$0/
01:13 p6eval rakudo 897636, niecza v24-35-g5c06e28:  ( no output )
01:19 BenGoldberg r: say rx/a+a/
01:19 p6eval rakudo 897636: OUTPUT«␤»
01:20 BenGoldberg n: say rx/a+a/
01:20 p6eval niecza v24-35-g5c06e28: OUTPUT«regex ANON(Any \self) { ... }␤»
01:26 adu_ woot
01:26 adu_ https://gist.github.com/andydude/5274854
01:32 BenGoldberg r: print 'abcabd' ~~ m:p5/(ab.)\1/
01:32 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Unrecognized backslash sequence: '\1'�at /tmp/9vlxQHUtLQ:1�------> [32mprint 'abcabd' ~~ m:p5/(ab.)\[33m�[31m1/[0m�    expecting any of:�        colon pair (restricted)�        infix stopper�»
01:33 BenGoldberg Hmm... both rakudo and niecza die ungracefully when I use $0, and neither supports the :p5 modifier to ask for perl5 regexes.
01:33 drbean joined #perl6
01:35 adu_ hmm
01:36 geekosaur seems to work here in rakudo
01:38 BenGoldberg Which one?
01:38 BenGoldberg p6: print 'abcabd' ~~ m:p5/(ab.)\1/
01:38 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Unrecognized backslash sequence: '\1'�at /tmp/DFB64HTUue:1�------> [32mprint 'abcabd' ~~ m:p5/(ab.)\[33m�[31m1/[0m�    expecting any of:�        colon pair (restricted)�        infix stopper�»
01:38 p6eval ..niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��Unrecognized adverb :p5(1) at /tmp/yCMpej6mpm line 1:�------> [32mprint 'abcabd' ~~ m[33m�[31m:p5/(ab.)\1/[0m��Unsupported use of the 1-based special form '\1' as a backreference; in Perl 6 please use the 0-based variabl…
01:38 geekosaur I didn't try the p5 one
01:38 BenGoldberg p: print 'abcabd' ~~ /(ab.)$0/
01:38 p6eval pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) {␤    unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.20120717/blib6/pugs/perl5/lib';␤    eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;␤}␤'Pugs::Runtime::Match::HsBridge'␤"␤*** Can't locate P…
01:38 BenGoldberg p6: print 'abcabd' ~~ /(ab.)$0/
01:38 p6eval rakudo 897636, niecza v24-35-g5c06e28:  ( no output )
01:39 geekosaur the p6 one worked as it did here. (note that it does not repeat the regex, but the matched string)
01:39 geekosaur p6: print 'abcabd' ~~ /(ab.)**2/
01:39 p6eval rakudo 897636: OUTPUT«abcabd»
01:39 p6eval ..niecza v24-35-g5c06e28: OUTPUT«abc abd»
01:39 BenGoldberg Ahh
01:40 BenGoldberg p: print 'abcabcabd' ~~ /(ab.)$0+/
01:40 p6eval pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) {␤    unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.20120717/blib6/pugs/perl5/lib';␤    eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;␤}␤'Pugs::Runtime::Match::HsBridge'␤"␤*** Can't locate P…
01:40 BenGoldberg p6: print 'abcabcabd' ~~ /(ab.)$0+/
01:40 p6eval niecza v24-35-g5c06e28: OUTPUT«abc»
01:40 p6eval ..rakudo 897636: OUTPUT«abcabc»
01:40 geekosaur pugs doesn;t do any of this, it's ancient
01:40 BenGoldberg I just keep typing p instead of p6 by accident ;)
01:40 cognominal joined #perl6
01:41 geekosaur maybe someday I will have enough haskell chops to not get utterly lost in its source...
01:42 BenGoldberg p6: print 'abcabdabd' ~~ /(ab.)$0+/
01:42 p6eval niecza v24-35-g5c06e28: OUTPUT«abd»
01:42 p6eval ..rakudo 897636: OUTPUT«abdabd»
01:54 cognominal joined #perl6
02:06 lue raiph: action as phaser seems interesting, although it might be a stretch to call it a phaser at that point. (But something phaser-like is an interesting idea)
02:07 lue unless you meant "actions under one phaser" instead of "each action method its own phaser"
02:09 cognominal joined #perl6
02:14 BenGoldberg left #perl6
02:21 lue (then again, it seems actions are phaser-like by nature, but it might still help to think of actions as them)
02:32 FROGGS_ joined #perl6
02:33 rindolf joined #perl6
02:35 adu_ how do I do [1:-1]
02:35 lue r: my @a = 1,2,3; say @a[0..*-1];
02:35 p6eval rakudo 897636: OUTPUT«1 2 3␤»
02:36 adu_ what's *-1 mean?
02:36 lue r: say *.WHAT;
02:36 p6eval rakudo 897636: OUTPUT«(Whatever)␤»
02:36 adu_ r: *
02:36 p6eval rakudo 897636:  ( no output )
02:36 adu_ r: 3; *
02:36 p6eval rakudo 897636: OUTPUT«WARNINGS:␤Useless use of constant integer 3 in sink context (line 1)␤»
02:37 lue it's a Whatever object; in this case, *-1 refers to the last element in the array
02:37 adu_ r: my $x = 3; say *
02:37 p6eval rakudo 897636: OUTPUT«*␤»
02:37 adu_ I don't get it
02:37 lue (*-2 second-to-last, etc.)
02:37 adu_ how is that different from [0..-1]
02:37 sorear adu_: * is a placeholder symbol of type Whatever
02:37 lue The array subscripts substitute the * for the size of the array
02:38 adu_ in this case it stands for the array?
02:38 adu_ ok
02:38 adu_ thanks
02:38 lue r: my @a = 1,2,3; say @a.elems; # the number from @a.elems is what gets put in place of * when you do @a[*-1];
02:38 p6eval rakudo 897636: OUTPUT«3␤»
02:40 labster r: my $a = 'gfoo'; $a ~~ s@gf@f@;
02:40 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable '@f' is not declared�at /tmp/hTstr3dCxL:1�------> [32mmy $a = 'gfoo'; $a ~~ s@gf@f[33m�[31m@;[0m�»
02:43 labster r: my $a = 'gfoo'; $a ~~ s@gf@ f@;
02:43 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Non-declarative sigil is missing its name�at /tmp/HoxY52AaTi:1�------> [32mmy $a = 'gfoo'; $a ~~ s@gf@[33m�[31m f@;[0m�    expecting any of:�        postfix�        infix stopper�        infix or meta-infix�        prefix or term�…
02:43 labster does s/// require slashes now, or is that some sort of LTA error?
02:44 adu_ r: my %h = {a => 'b'}; say %h:exists{'a'}
02:44 p6eval rakudo 897636: OUTPUT«("a" => "b").hash␤»
02:44 adu_ r: my %h = {a => 'b'}; say %h:exists{'c'}
02:44 p6eval rakudo 897636: OUTPUT«("a" => "b").hash␤»
02:44 adu_ r: my %h = {a => 'b'}; say %h{'a'}:exists
02:44 p6eval rakudo 897636: OUTPUT«True␤»
02:44 adu_ r: my %h = {a => 'b'}; say %h{'c'}:exists
02:44 p6eval rakudo 897636: OUTPUT«False␤»
02:46 lue r: my $a = 'gfoo'; $a ~~ s¢gf¢f¢; say $a;
02:46 p6eval rakudo 897636: OUTPUT«foo␤»
02:46 shachaf_ joined #perl6
02:46 cognominal joined #perl6
02:46 shachaf_ joined #perl6
02:46 lue labster: No, but I wouldn't recommend any single characters that have special meaning in regexes :)
02:47 labster r: my $a = 'gfoo'; $a ~~ s★gf★g★;
02:47 p6eval rakudo 897636:  ( no output )
02:47 sorear n: s@gf@f@
02:47 p6eval niecza v24-35-g5c06e28: OUTPUT«Unhandled exception: Unable to resolve method subst in type Any␤  at /tmp/jhKfCZijEV line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4299 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4300 (module-CORE @ 583) ␤  at /home/…
02:47 labster well, that does work better, sure.
02:47 sorear n: ($_ = "helogf") ~~ s@gf@f@; say $_
02:47 p6eval niecza v24-35-g5c06e28: OUTPUT«helof␤»
02:47 sorear rakudobug
02:47 labster niezca++
02:48 labster niecza++ (my spelling)--
02:49 lue A very quick glance shows it's not reported, so if no-one else is doing it, I'll submit it.
02:50 telex joined #perl6
02:51 xinming joined #perl6
02:52 adu_ uh oh
02:52 adu_ "Dynamic variable $*TYPEDEF_CONTEXT not found"
02:58 apejens joined #perl6
02:59 huf joined #perl6
03:01 orafu joined #perl6
03:05 daudibaldr joined #perl6
03:13 preflex_ joined #perl6
03:19 labster thanks lue
03:19 lue you're welcome :)
03:19 labster rn: "foo" ~~ m#f#;
03:19 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Null regex not allowed�at /tmp/555Qc6LXz4:1�------> [32m"foo" ~~ m#f#;[33m�[31m<EOL>[0m�    expecting any of:�        postfix�        infix stopper�        infix or meta-infix�        prefix or term�        prefix or meta-prefix�»…
03:19 p6eval ..niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��No delimiter found at /tmp/BcbpfRkv7o line 1 (EOF):�------> [32m"foo" ~~ m#f#;[33m�[31m<EOL>[0m��Parse failed��»
03:19 lue # now always starts a comment, unless it's inside a string
03:21 labster that makes lots of sense, really.  There's just a lot of old perl5 code which is... well, I don't envy FROGGS trying to figure out the regex situation for use v5;.
03:22 lue It makes the job on syntax highlighters easier too (and anything needing to parse Perl(6), really).
03:26 diakopter .u CLAPPING
03:26 yoleaux U+1F44F CLAPPING HANDS SIGN [So] (👏)
03:26 diakopter .u 270b
03:26 yoleaux U+270B RAISED HAND [So] (✋)
03:27 lue [otoh, it's an effective way to keep those awful Perl 6-ers from trying to run your beautiful Perl 5 code through their interpreters ]
03:29 labster yes.  that exactly.
03:36 armitage81 joined #perl6
03:44 dmol joined #perl6
03:51 labster r: sub foo ($bar :D) { 1; }
03:51 p6eval rakudo 897636: OUTPUT«===SORRY!===␤invoke() not implemented in class 'QAST::Op'␤»
03:54 labster I guess I want Mu:D there.  But definitely LTA error message.
03:54 sorear rakudobug. internal error.
03:57 labster r: sub x ($y :qwerty) { 3; }
03:57 p6eval rakudo 897636: OUTPUT«===SORRY!===␤invoke() not implemented in class 'QAST::Op'␤»
03:57 labster r: sub x ($y qwerty) { 3; }
03:57 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�Missing block�at /tmp/gHtxH4GsMT:1�------> [32msub x ($y [33m�[31mqwerty) { 3; }[0m�    expecting any of:�        statement list�        prefix or term�        prefix or meta-prefix�        new name to be defined�        formal pa…
03:58 labster looks like the colon triggers it.
04:00 * labster submits rakudobug
04:01 daudibaldr left #perl6
04:02 diakopter r: sub foo ($bar:) { }; foo(3)
04:02 p6eval rakudo 897636: OUTPUT«Lexical 'self' not found␤  in sub foo at /tmp/F7HfOSNhH2:1␤  in block  at /tmp/F7HfOSNhH2:1␤␤»
04:02 diakopter probably already submitted...
04:04 labster Didn't see anything.  That error message at least tells you what not to do.
04:05 diakopter r: sub foo ($bar:D{ eat a trout }) { }; foo(3)
04:05 p6eval rakudo 897636: OUTPUT«===SORRY!===␤invoke() not implemented in class 'QAST::Op'␤»
04:09 diakopter WAT.
04:09 diakopter r: sub foo (\self:){ say $_ }; foo(55)
04:09 p6eval rakudo 897636: OUTPUT«(Any)␤»
04:10 diakopter r: sub foo ($_:){ say $_ }; foo(55)
04:10 p6eval rakudo 897636: OUTPUT«Lexical 'self' not found␤  in sub foo at /tmp/Ci48x8gUyb:1␤  in block  at /tmp/Ci48x8gUyb:1␤␤»
04:10 diakopter r: sub foo (\self:){ say self }; foo(55)
04:10 p6eval rakudo 897636: OUTPUT«[31m===[0mSORRY![31m===[0m�'self' used where no object is available�at /tmp/pYzAechRtH:1�------> [32msub foo (\self:){ say [33m�[31mself }; foo(55)[0m�    expecting any of:�        argument list�        prefix or term�        prefix or meta-prefix�»…
04:10 diakopter r: sub foo (\self:){ say eval('self') }; foo(55)
04:10 p6eval rakudo 897636: OUTPUT«55␤»
04:10 diakopter O_O_O
04:13 labster What just happened there!?
04:14 diakopter I grew a third eye, and it opened wide
04:15 lue r: sub foo(\bar:) { say eval('bar') }; foo(42);
04:15 p6eval rakudo 897636: OUTPUT«Lexical 'self' not found␤  in sub foo at /tmp/YPYvtEk7WO:1␤  in block  at /tmp/YPYvtEk7WO:1␤␤»
04:15 lue r: sub foo(\bar:) { say eval('self') }; foo(42);
04:15 diakopter see? :)
04:15 p6eval rakudo 897636: OUTPUT«Lexical 'self' not found␤  in sub foo at /tmp/nO55rgen2v:1␤  in block  at /tmp/nO55rgen2v:1␤␤»
04:16 lue std: sub foo ($bar:) { }; foo(3)
04:16 p6eval std 86b102f: OUTPUT«Potential difficulties:�  $bar is declared but not used at /tmp/UcJok_jRiU line 1:�------> [32msub foo ([33m�[31m$bar:) { }; foo(3)[0m�ok 00:00 44m�»
04:16 labster Oh, once I open my third eye it's completely obvious.
04:17 labster std: sub foo ($bar:) { $bar }; foo(3)
04:17 p6eval std 86b102f: OUTPUT«ok 00:00 45m␤»
04:18 lue n: sub foo ($bar:) { $bar }; say foo(3)
04:18 p6eval niecza v24-35-g5c06e28: OUTPUT«3␤»
04:26 thou joined #perl6
04:44 am0c joined #perl6
04:49 dalek perl6-roast-data: cc74847 | coke++ | / (4 files):
04:49 dalek perl6-roast-data: today (automated commit)
04:49 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/cc7484763a
05:07 dalek Pugs.hs: 522c5c8 | coke++ | t/spectest.data:
05:07 dalek Pugs.hs: run passing testfile
05:07 dalek Pugs.hs: review: https://github.com/perl6/Pugs.hs/commit/522c5c8cab
05:12 dalek rakudo/nom: ba5e04f | coke++ | t/spectest.data:
05:12 dalek rakudo/nom: run test we already pass
05:12 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ba5e04f9d0
05:22 ikrs joined #perl6
05:54 crab2313 joined #perl6
06:04 dmol joined #perl6
06:06 xinming joined #perl6
06:21 thou_ joined #perl6
06:29 thou joined #perl6
06:43 thou_ joined #perl6
06:45 thou joined #perl6
07:05 thou_ joined #perl6
07:15 thou joined #perl6
07:18 thou_ joined #perl6
07:22 thou joined #perl6
07:29 thou joined #perl6
07:29 ikrs does perl6 have a while loop or do you have to use a loop with a last statement?
07:32 ikrs joined #perl6
07:32 thou_ joined #perl6
07:35 sorear ikrs: perl 6 has a lot of while loops
07:35 sorear ikrs: i get the impression you may have tried it and run into a problem?
07:36 sorear r: my $i = 10; while $i { say $i-- }
07:36 p6eval rakudo ba5e04: OUTPUT«10␤9␤8␤7␤6␤5␤4␤3␤2␤1␤»
07:36 sorear ^ correct syntax
07:36 sorear r: my $i = 10; while ($i) { say $i-- } # also correct
07:36 p6eval rakudo ba5e04: OUTPUT«10␤9␤8␤7␤6␤5␤4␤3␤2␤1␤»
07:36 sorear r: my $i = 10; while($i) { say $i-- } # this is wrong
07:36 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Word 'while' interpreted as 'while()' function call; please use whitespace instead of parens�at /tmp/c3T2CNvVYz:1�------> [32mmy $i = 10; while[33m�[31m($i) { say $i-- } # this is wrong[0m�Unexpected block in infix position (two t…
07:37 sorear r: my $i = 10; while ($i){ say $i-- } # so is this
07:37 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Missing block�at /tmp/I6iR0QiI3Q:1�------> [32m 10; while ($i){ say $i-- } # so is this[33m�[31m<EOL>[0m�    expecting any of:�        postfix�        statement end�        statement modifier�        statement modifier loop�      Ã¢â‚¬Â¦
07:37 sorear r: my $i = 10; while ($i) say $i--; # so is this
07:37 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Missing block�at /tmp/5PLEyCl5Xk:1�------> [32mmy $i = 10; while ($i) [33m�[31msay $i--; # so is this[0m�    expecting any of:�        postfix�        infix stopper�        infix or meta-infix�        parameterized block�»…
07:38 ikrs sorear: thanks, don't know what i was doing wrong but that helped
07:38 thou joined #perl6
07:39 sorear this is one of the places where perl 6 relies on whitespace, new people often trip over it
07:39 sorear while( # when you glue the ( to a word, it forces the word to be taken as a function, not a keyword
07:40 sorear while $i{ # when you glue the { to the variable, it forces interpretation as a postfix operator.  perl is now trying to parse a hash index!
07:41 thou_ joined #perl6
07:41 ikrs ah, that makes sense now. i had a similar issue with if statements
07:44 sorear welcome to #perl6, if appropriate
07:47 anant_ joined #perl6
07:48 thou joined #perl6
07:55 thou joined #perl6
08:10 xinming joined #perl6
08:13 thou joined #perl6
08:15 thou_ joined #perl6
08:19 SamuraiJack joined #perl6
08:20 thou joined #perl6
08:22 labster yes, we have a while loop
08:22 labster erm... I was a page up, nvm
08:23 thou_ joined #perl6
08:23 thou joined #perl6
08:36 labster aw lame, 'is cached' doesn't work on methods.  Oh well, a state variable will do the trick.  TIMTOWTDI.
09:10 dalek v5: fbfa1ac | (Tobias Leich)++ | lib/Perl6/P5 (2 files):
09:10 dalek v5: prepare to handle __DATA__ and __END__ blocks
09:10 dalek v5:
09:10 dalek v5: Currently we only capture the content, but this way scripts
09:10 dalek v5: having this term are parseable.
09:10 dalek v5: review: https://github.com/rakudo-p5/v5/commit/fbfa1ac660
09:13 sftp joined #perl6
09:16 anant_ I was reading S02, and under "Type Objects", found this statement "Any type name used as a value is an undefined instance of that type's prototype object". Should it not have been written "Any type name used as a value *refers to the singular instance* of that type's prototype object"?
09:17 FROGGS_ r: say Int.defined
09:17 p6eval rakudo ba5e04: OUTPUT«False␤»
09:17 moritz yes, that would be better
09:18 moritz anant_: if you want to fix it, tell me your github ID, and I can give you commit access
09:20 anant_ anant-sogani
09:22 moritz anant_: welcome to the club. Have the appropriate amount of fun!
09:29 anant_ moritz: Thanks! I'm still confused about the type object though. Why does type object.defined return a FALSE?
09:30 moritz anant_: definedness is just the property that distinguishes types from instances
09:30 moritz named like that for historical reasons, basically
09:30 moritz think of .defined as .is-instance instead, and the confusion goes away (I hope)
09:33 anant_ moritz: oh ok. So, my re-write "... refers to the singular instance of that type's prototype object" is then incorrect
09:34 moritz uhm, why?
09:34 moritz it removes the "undefined", which wasn't wrong
09:34 moritz but IMHO it still makes it clearer that the type object is a singleton
09:38 anant_ moritz: I think removing the "instance" word makes it clearer. Something like "... refers to the type's prototype object"  .. which I hope conveys the singleton idea as well
09:38 sorear either way it's wrong because it implies that the thing returned is something other than the prototype
09:38 sorear modern p6think is that the type *is* the prototype object
09:38 sorear Int used as a term returns the undefined prototype object named "Int"
09:44 rindolf joined #perl6
09:45 woolfy joined #perl6
09:58 _nyuszika7h_ joined #perl6
10:00 _nyuszika7h_ left #perl6
10:01 dalek v5: 197949f | (Tobias Leich)++ | lib/Perl6/P5 (2 files):
10:01 dalek v5: added __LINE__ and __FILE__
10:01 dalek v5: review: https://github.com/rakudo-p5/v5/commit/197949fc5d
10:01 sorear sleep&
10:01 FROGGS_ gnight sorear
10:04 FROGGS_ say $?PACKAGE
10:04 FROGGS_ r: say $?PACKAGE
10:04 p6eval rakudo ba5e04: OUTPUT«(GLOBAL)␤»
10:04 FROGGS_ $ perl6 -e 'print $?PACKAGE'
10:04 FROGGS_ use of uninitialized variable $v of type GLOBAL in string context  in block  at -e:1
10:06 dalek specs: ea0af47 | moritz++ | S02-bits.pod:
10:06 dalek specs: [S02] unconfuse wording about type objects
10:06 dalek specs:
10:06 dalek specs: since a type object is the opposite of an instance, it is confusing to call
10:06 dalek specs: it an instance of soemthing. anant++, sorear++
10:06 dalek specs: review: https://github.com/perl6/specs/commit/ea0af47304
10:07 moritz anant_: I hope this commit makes it less confusing
10:07 renormalist joined #perl6
10:10 anant_ moritz: yes!
10:10 anant_ moritz: thanks for doing the correction so fast!
10:11 masak good forenoon, #perl6
10:13 FROGGS_ hi masak
10:28 araujo joined #perl6
10:28 dalek v5: 206cb36 | (Tobias Leich)++ | lib/Perl6/P5 (2 files):
10:28 dalek v5: add __PACKAGE__, not perfect yet though
10:28 dalek v5: review: https://github.com/rakudo-p5/v5/commit/206cb36ff4
10:35 moritz \o masak, FROGGS_
10:35 moritz masak: how's the t2 review coming along?
10:46 dalek v5: 082a2a3 | (Tobias Leich)++ | lib/Perl6/P5 (2 files):
10:46 dalek v5: implement length()
10:46 dalek v5: review: https://github.com/rakudo-p5/v5/commit/082a2a3433
10:51 kaare__ joined #perl6
10:57 spider-mario joined #perl6
10:58 masak moritz: I'm reviewing now.
11:22 PacoAir joined #perl6
11:28 SamuraiJack_ joined #perl6
11:31 tgt joined #perl6
11:31 census joined #perl6
11:32 pmurias joined #perl6
11:32 pmurias FROGGS_: hi
11:34 FROGGS_ hi pmurias
11:40 pmurias FROGGS_: what should I type in v5 to run the tests?
11:40 pmurias make spectest?
11:40 FROGGS_ right
11:41 FROGGS_ this should always pass
11:43 FROGGS_ pmurias: it passes 6 test files so far
11:44 dalek v5: 8e169cc | (Pawel Murias)++ | README.md:
11:44 dalek v5: Update README.md
11:44 dalek v5: review: https://github.com/rakudo-p5/v5/commit/8e169ccbfd
11:46 pmurias FROGGS_: we don't run perlito tests?
11:48 FROGGS_ not by default, no
11:48 FROGGS_ but we could add them to spectest.data as well
11:53 PacoAir joined #perl6
11:58 PacoAir joined #perl6
12:15 gfldex joined #perl6
12:15 felher joined #perl6
12:16 lizmat FROGGS: with regards to 082a2a3433, I'm not sure we can get away with not implementing "use bytes"
12:17 lizmat within a scope where use bytes is active, "length" is actually number of bytes
12:17 lizmat not number of chars
12:18 lizmat so maybe add a #TODO there ?
12:19 lizmat (even though I know "use bytes" is going to be deprecated / removed in Perl 5.18+, we would still need to support it from older versions)
12:20 anant_ moritz: I rewrote the contents of the 'Type Objects' section to look like this: https://gist.github.com/anant-sogani/5276483
12:21 masak tadzik: I submitted two talks to plpw.
12:23 pmurias FROGGS_: spectests pass here
12:28 lizmat masak: giving any talks at YAPC::NA ?
12:32 tadzik masak: awesome :)
12:33 lizmat tadzik: I have one lightning talk for PLPW, do I need to submit that now already ?
12:33 lizmat (already given at GPW and SPW by the way)
12:34 tadzik lizmat: not neceserilly, but would be great :)
12:34 tadzik also, registering would be great as well :)
12:34 SamuraiJack joined #perl6
12:36 pmurias FROGGS_: should I add perlito tests to roast5?
12:38 lizmat tadzik: done both
12:38 tadzik \o/ lizmat++
12:40 lizmat Ah, I see masak and jnthn are also coming, cool!
12:40 tadzik yep :)
12:40 pmurias tadzik: what's the deadline for submitting talks to PLPW?
12:41 SamuraiJack joined #perl6
12:42 tadzik pmurias: 14th of april
12:42 tadzik as noted in http://act.yapc.eu/plpw2013/news/1006
12:50 lizmat afk&
12:55 lizmat FROGGS: have you seen the ""Perl 5 specification" test suite" target for the QA Hackathon? (http://2013.qa-hackathon.org/qa2013/wiki?node=Hackathon-Targets )
13:13 kivutar joined #perl6
13:13 leprevost joined #perl6
13:22 pmurias FROGGS_: why do we use a Perl6::P5World naming convention instead of Perl5::World?
13:26 lizmat perhaps because it's inheriting from Perl6::World ?
13:26 lizmat which would make the naming more logical ?
13:37 FROGGS_ pmurias: what lizmat said, there id one method we are overriding... and I guess there will be more in future
13:38 FROGGS_ lizmat: about 'use bytes': good point, I can add the feature right away...
13:38 lizmat can you?
13:39 FROGGS_ lizmat: I think so, yes
13:39 lizmat wouldn't that require implementing the hints hash %^H ?
13:40 lizmat and something akin to local() ?
13:40 FROGGS_ I've seen right now that .chars is wrong when we have umlauts in the code and ' use utf8' is missing...
13:40 FROGGS_ so, we need good tests for that
13:40 lizmat so you mean perl 6's .chars is wrong ?
13:41 FROGGS_ lets say it doesn't do the same like perl 5 does
13:41 FROGGS_ perl -e 'print length "äbc"'
13:41 FROGGS_ 4
13:41 crab2313 joined #perl6
13:41 FROGGS_ perl -e 'use utf8; print length "äbc"'
13:41 FROGGS_ 3
13:41 FROGGS_ in perl6 we have utf8 by default
13:42 FROGGS_ but what I wanted to do right now is to call .bytes instead of .chars if 'use bytes' is in use
13:42 FROGGS_ but we have to make a Buf first to do that
13:43 lizmat and how would you know that "use bytes" is in use?
13:43 dwoldrich joined #perl6
13:43 lizmat (as that is lexical)
13:43 moritz same as any other lexical information, really
13:43 lizmat fwiw, I can live with using .chars and a #TODO
13:43 FROGGS_ set a dynamic variable?
13:43 FROGGS_ $*USE_BYTES
13:43 moritz for example
13:44 lizmat and parsing "use bytes" or "no bytes" would set /unset that var at compile time ?
13:44 lizmat that would work in the short term
13:45 moritz why only in the short term?
13:45 moritz it's how we do most lexically changed behavior
13:45 FROGGS_ lizmat: it is the same for Use/no strict
13:45 moritz a dynamic variable in the compiler has the same scope a lexical pragma in the code
13:45 FROGGS_ so you can proper build the ast
13:46 * lizmat wonders whether implementing the hints hash wouldn't be more flexible then
13:47 lizmat as otherwise making caller() work will become very difficult indeed with regards to (caller(N))[10]
13:47 lizmat (aka the hints hash from somewhere down the stack)
13:48 FROGGS_ pmurias: if you put them in a subdir, yes
13:53 fhelmberger joined #perl6
13:53 lizmat FROGGS: but please, please don't let me interrupt the flow of your work…  a #TODO is al I really wanted  :-)
13:53 FROGGS_ lizmat: that's what I did so far
13:54 FROGGS_ the rest is a bit too complicated atm to do that properly for me
14:01 pmurias FROGGS_, lizmat: if a ruby compiler was inheriting from Perl6::World would Perl6::RubyWorld be a good name ? ;)
14:02 FROGGS_ pmurias: yesh!
14:02 lizmat FROGGS: maybe setting up the %^H hash  would be a nice project to sink my teeth into
14:03 FROGGS_ lizmat: go ahead :)
14:03 moritz the hints hash has the advantage of being accessible at run time
14:03 lizmat indeed, and I know that some of TheDamian's modules use that
14:04 lizmat (as shown recently at the SPW)
14:04 lizmat tricky bit with $^H is that each call level has its own version
14:05 lizmat s/call level/subroutine/
14:05 FROGGS_ lizmat: btw, you fiddle something in the grammar, please rerun 'make spectest' before committing
14:05 lizmat ack
14:06 lizmat I wouldn't want to mess up things for other people  :-)
14:06 moritz lizmat: though you know atatically at which point it's used, so you can generated it on demand
14:06 moritz *actually
14:06 moritz erm
14:06 moritz *statically
14:06 moritz is what I wanted to wrote ;-)
14:07 moritz *write
14:07 * moritz should just give up typing
14:07 FROGGS_ it is just that little changes to the grammar can make a single test work, but break everything else (precedence of the tokens and such)
14:08 pmurias lizmat: wouldn't treating %^H as compile time contextual an setting it every time we start a new scope give as Perl5 semantics? like %*LANG?
14:08 lizmat I guess the current sub has an ID that I could use as a key in a hash
14:09 colomon joined #perl6
14:09 lizmat pmurias: I would want to prevent setting it at every new scope
14:10 lizmat but I guess I should say: current scope, rather than current sub
14:10 lizmat so does the current scope have an ID?
14:12 grondilu joined #perl6
14:12 dalek v5: 3a7bddc | (Tobias Leich)++ | lib/ (3 files):
14:12 dalek v5: make simple (really simple) match work
14:12 dalek v5: review: https://github.com/rakudo-p5/v5/commit/3a7bddcc8d
14:12 dalek v5: b9439f2 | (Tobias Leich)++ | lib/Perl6/P5Actions.pm:
14:12 dalek v5: add TODO about "use bytes" for length()
14:12 dalek v5: review: https://github.com/rakudo-p5/v5/commit/b9439f2dcd
14:12 pmurias lizmat: look how %*LANG is implemented
14:12 lizmat ack, I will
14:13 grondilu yet an other Rosalind problem where Perl6 is too slow:  https://gist.github.com/anonymous/5276828    I suspect 'X-' is to blame.
14:14 grondilu it's too bad because it is a nice use-case for perl6:  lots of P6 idioms
14:15 moritz also gather/take tends to be slowish
14:17 lichtkind joined #perl6
14:17 grondilu I'm pretty sure the main issue is X-, though.  I tried with only one protein and it took ages.
14:18 grondilu for those who don't know, the rosalind problem is: http://rosalind.info/problems/prsm/
14:23 pmurias lizmat: also %^H seems to be a BEGIN time thing: http://pastie.org/7178779
14:23 Psyche^ joined #perl6
14:24 pjcj joined #perl6
14:24 lizmat pmurias: yes, but also a runtime thing through (caller(N))[10
14:24 lizmat ]
14:26 pjcj joined #perl6
14:35 lizmat errands&
14:52 grondilu_ joined #perl6
15:00 arnsholt Whoa, Rakudo parsed itself \o/
15:00 tadzik woot
15:01 arnsholt Now I get to dig around in the optimizer =D
15:12 arnsholt Oooh, all the way to codegen now =D
15:13 moritz .oO( all the way to reno )
15:13 arnsholt ^_^
15:20 moritz arnsholt: I want to see commits :-)
15:23 dalek nqp/vmarray-list: 17e5ba6 | (Arne Skjærholt)++ | src/ (3 files):
15:23 dalek nqp/vmarray-list: Add splice to REPROps_Positional and add VTABLE for it to sixmodelobject.pmc.
15:23 dalek nqp/vmarray-list:
15:23 dalek nqp/vmarray-list: Also implements splice in VMArray.c.
15:23 dalek nqp/vmarray-list: review: https://github.com/perl6/nqp/commit/17e5ba6f2d
15:24 dalek rakudo/vmarray-list: 38178b5 | (Arne Skjærholt)++ | src/Perl6/Optimizer.pm:
15:24 dalek rakudo/vmarray-list: A few tweaks to the optimizer to make it work with the changed NQP.
15:24 dalek rakudo/vmarray-list: review: https://github.com/rakudo/rakudo/commit/38178b5ba8
15:24 arnsholt Happy now? =p
15:25 toddr__ joined #perl6
15:26 moritz yes.
15:27 arnsholt MAnaged to avoid killing dalek this time, as well ^_^
15:29 moritz push early! Mind the dalek!
15:40 dalek nqp/vmarray-list: fbe94c9 | (Arne Skjærholt)++ | src/QAST/Operations.nqp:
15:40 dalek nqp/vmarray-list: Make a list into list_s in QAST/Compiler.nqp.
15:40 dalek nqp/vmarray-list: review: https://github.com/perl6/nqp/commit/fbe94c9edc
15:41 toddr__ So I'm curious. Is there a Perl6 bot yet? Is that what dalek is?
15:41 arnsholt moritz++ is working on a logging bot in Perl 6 (ilbot6)
15:44 moritz speaking of which, where has it gone?
15:45 arnsholt You tell us =)
15:45 moritz Malformed UTF-8 string
15:45 moritz in method get at src/gen/CORE.setting:8365
15:45 mtk joined #perl6
15:45 moritz died tonight at 00:51H CET
15:45 ilbot6 joined #perl6
15:49 arnsholt Sounds unfun
15:51 leprevost joined #perl6
16:02 thou joined #perl6
16:02 dalek v5: 4041e53 | (Tobias Leich)++ | t/spectest.data:
16:02 dalek v5: add moore passing tests
16:02 dalek v5: review: https://github.com/rakudo-p5/v5/commit/4041e53fba
16:03 thou_ joined #perl6
16:06 thou joined #perl6
16:11 thou_ joined #perl6
16:17 thou joined #perl6
16:29 dmol joined #perl6
16:31 thou joined #perl6
16:32 kivutar joined #perl6
16:35 * [Coke] yawns and drinks some uninspiring coffee.
16:36 thou joined #perl6
16:37 * moritz trolls perlmonks with a Perl 6 answer: http://www.perlmonks.org/?node_id=1026278
16:38 [Coke] r: say eval("0", :lang<perl5>)
16:38 p6eval rakudo ba5e04: OUTPUT«No compiler available for language 'perl5'␤  in sub eval at src/gen/CORE.setting:598␤  in sub eval at src/gen/CORE.setting:593␤  in block  at /tmp/zGyjPv7O66:1␤␤»
16:39 n0den1te joined #perl6
16:39 dmol joined #perl6
16:40 thou joined #perl6
16:49 * [Coke] ponders a new class of todo/skip tests that count as skips when any in a block fail, but count as passing todo if they all pass.
16:52 dmol joined #perl6
17:01 thou_ joined #perl6
17:05 aindilis joined #perl6
17:06 dmol joined #perl6
17:13 moritz "todip" or "skido"
17:16 dmol joined #perl6
17:19 thou joined #perl6
17:21 thou_ joined #perl6
17:21 n0den1te joined #perl6
17:21 raiph re anant's "real objects" suggestion ( https://gist.github.com/anant-sogani/5276483 ):
17:22 raiph I don't like "real objects"
17:22 raiph I'm guessing s/he considered "instances" but felt an undefined prototype object was an instance. I'd be sorely tempted to go with "instance" regardless.
17:22 raiph Fwiw I think both the following are LTA (less than awesome):
17:22 raiph o "defined" vs "DEFINITE"
17:22 raiph o "prototype" vs "proto" (vs p5 "prototype")
17:23 raiph what about abstract/concrete?
17:23 raiph "Every type has an abstract object associated with it. It is responsible for creating concrete objects of that type, among other things"
17:23 diakopter nqp-jvm: say(nqp::isconcrete(raiph))
17:23 p6eval nqp-jvm: OUTPUT«0␤»
17:25 raiph heh. i'm curious what isconcrete tests
17:25 diakopter jnthn's preferred term is concrete
17:25 diakopter for "instances"
17:25 diakopter "type object" for non-concrete
17:26 adu_ joined #perl6
17:26 adu_ .u 1F4A9
17:26 yoleaux U+1F4A9 PILE OF POO [So] (💩)
17:27 moritz is yoleaux the new phenny?
17:27 adu_ who is phenny?
17:27 diakopter yoleaux: tell diakopter do it
17:27 n0den1te official secretary
17:28 moritz our previous bot who delivered messages and listed Unicode characters
17:28 diakopter you only live eaux
17:28 n0den1te err, adu_: ^^
17:28 adu_ that's not how you spell once
17:30 diakopter but it's an acronum
17:30 diakopter acronym
17:31 adu_ oh I get it eaux is pronounced o
17:31 * diakopter wonders who named it
17:31 adu_ where is it running?
17:32 n0den1te o.O( you only live "unix" ? )
17:32 diakopter heh, see its whois
17:32 dalek ecosystem: 3fbb334 | mrhdias++ | META.list:
17:32 dalek ecosystem: Was added the perl6-IUP module.
17:32 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/3fbb33474b
17:32 dalek ecosystem: a992925 | (Henrique Dias)++ | META.list:
17:32 dalek ecosystem: Merge pull request #24 from mrhdias/master
17:32 dalek ecosystem:
17:32 dalek ecosystem: Add the perl6-IUP module.
17:32 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/a992925862
17:32 adu_ Real Name: "Yoleaux L. Only-Once"
17:32 n0den1te YOLO?
17:32 moritz yolo ono
17:32 diakopter dpk: ?
17:33 adu_ hmm, it's a UK address
17:33 diakopter seems dpk
17:34 adu_ who is dpk?
17:34 diakopter /whois dpk
17:34 dpk ohai
17:34 adu_ David Kendal?
17:34 dpk sbp is not running phenny any more
17:34 dpk that is me
17:34 moritz dpk: thanks for sending in a replacement
17:34 dpk yoleaux is the pseudo-official successor
17:34 adu_ dpk: did you name yoleaux?
17:35 diakopter 'tis a cute name
17:35 moritz yoleaux: tell diakopter foo
17:35 dpk I may have had some hand in its naming
17:35 moritz dpk: is there a chance to get messenging feature back?
17:35 dpk .tell diakopter foo
17:35 yoleaux dpk: I'll pass your message to diakopter.
17:35 dpk reforms
17:35 moritz ok, thanks
17:35 diakopter cool
17:35 yoleaux 17:35Z <dpk> diakopter: foo
17:35 moritz .help
17:35 yoleaux moritz: I'm yoleaux. Type .commands to see what I can do, or see http://dpk.io/yoleaux for a quick guide.
17:35 adu .tell dpk nice name
17:35 yoleaux adu: I'll pass your message to dpk.
17:35 dpk thx
17:35 yoleaux 17:36Z <adu> dpk: nice name
17:36 moritz dpk++
17:36 n0den1te .mangle You only live once
17:36 yoleaux You only live once
17:36 n0den1te .mangle yolo
17:36 yoleaux Iolo
17:37 dpk hehe
17:37 n0den1te dpk: nice work. :)
17:37 n0den1te .mangle perl
17:37 yoleaux pèrl
17:37 dpk thanks
17:37 diakopter dpk: what language(s)/environment is yoleaux
17:37 moritz .tr :de :sv Zimtschnecke
17:37 diakopter oh nm
17:37 yoleaux Zimtschnecke (de → sv)
17:38 * diakopter sees on github
17:38 moritz .rfc 1918
17:38 dpk rubby
17:38 yoleaux RFC 1918 - Address Allocation for Private Internets: http://tools.ietf.org/html/rfc1918
17:38 dpk though I kind of wish I'd used Pythong now
17:39 n0den1te dpk: you too? I spell python as pythong way too many times to count (muscle memory stuck)
17:39 * geekosaur seems to prefer "pythin" for some reason
17:39 dpk Rubby and Pythong
17:39 n0den1te .tr en de "beer"
17:39 yoleaux and the " bear " (nl → en)
17:39 n0den1te heh
17:39 n0den1te .tr :en :de "beer"
17:40 yoleaux "Bier" (en → de)
17:40 moritz .ping
17:40 yoleaux There is no ping command; nor can this be construed as a response.
17:40 moritz :-)
17:40 n0den1te yoleaux!
17:40 yoleaux n0den1te!
17:40 n0den1te that's ping enough for me. :)
17:41 diakopter .command-help . .
17:41 yoleaux diakopter: Sorry, that command doesn't seem to exist!
17:41 diakopter .command-help ' .
17:41 yoleaux diakopter: Sorry, that command doesn't seem to exist!
17:41 adu .tr :ja :en 頑張る
17:41 yoleaux Go (ja → en)
17:41 n0den1te .wa sine curve
17:41 thou joined #perl6
17:41 yoleaux sine curve (English phrase): Definition: noun: the curve of y=sin x; Synonym: sinusoid; Broader terms: undulation: wave
17:42 n0den1te .botsnack
17:42 yoleaux :D
17:42 n0den1te you should not rest now. right...
17:42 n0den1te .botsnack
17:42 yoleaux :D
17:43 adu yoleaux!
17:43 yoleaux adu!
17:43 adu :D
17:43 dmol joined #perl6
17:43 n0den1te .decode <a href="http://perl6.org">perl6</a>
17:43 yoleaux <a href="http://perl6.org">perl6</a>
17:44 n0den1te .ety mango
17:44 yoleaux "1580s, from Portuguese manga, from Malay mangga, from Tamil mankay, from man "mango tree" + kay "fruit." Mango trees were brought from Timor to British gardens in Jamaica and St. Vincent 1793 by Capt. Bligh on his second voyage." — http://etymonline.com/index.php?search=mango
17:45 n0den1te .pick 1, 25, 42
17:45 yoleaux 25
17:45 n0den1te .pick 1, 42, 25
17:45 yoleaux 25
17:46 moritz ♪ underneath the mango tree me honey and me ♫
17:46 diakopter .head perl6.com
17:47 yoleaux diakopter: Sorry, that command (.head) crashed.
17:47 diakopter o_O
17:47 dpk aww man
17:47 n0den1te .head http://perl6.org
17:47 yoleaux 200, text/html; charset=UTF-8, 4507 bytes
17:47 diakopter so the hdd is ruined cuz the head crashed?
17:48 n0den1te moritz: yep, that's part of how I remembered it. but kay isn't fruit. it's "raw" fruit or a vegetable. :)
17:48 n0den1te "raw" as in unripe.
17:49 adu yoleaux should also accept .. for character ranges
17:49 adu http://www.unicode.org/faq/blocks_ranges.html
17:49 diakopter .head i.i
17:49 yoleaux diakopter: Sorry, that command (.head) crashed.
17:49 dpk hmm. yeah, .head needs better error handling
17:49 adu .chars 2200-2210
17:49 yoleaux ∀ ∁ ∂ ∃ ∄ ∅ ∆ ∇ ∈ ∉ ∊ ∋ ∌ ∍ ∎ ∏ ∐
17:49 diakopter .head https://github.com/dpkendal/yoleaux
17:49 yoleaux 200, text/html; charset=utf-8, 41673 bytes
17:49 adu .chars 2200..2210
17:49 yoleaux . 0 1 2
17:50 dpk hehe
17:50 dpk yeah, wil add that
17:50 dpk *will
17:50 diakopter .u CLAPPING
17:50 yoleaux U+1F44F CLAPPING HANDS SIGN [So] (👏)
17:51 adu .u POO
17:51 yoleaux U+1434 CANADIAN SYLLABICS POO [Lo] (ᐴ)
17:51 yoleaux U+1435 CANADIAN SYLLABICS Y-CREE POO [Lo] (ᐵ)
17:51 yoleaux U+A576 VAI SYLLABLE POO [Lo] (ꕶ)
17:51 diakopter .u ASPLODE
17:51 yoleaux No characters found
17:52 adu .u PILE
17:52 diakopter .u No characters found
17:52 yoleaux No characters found
17:52 adu .u PILE
17:52 n0den1te .u goo
17:52 yoleaux U+1F4A9 PILE OF POO [So] (💩)
17:52 yoleaux U+A591 VAI SYLLABLE GOO [Lo] (ê–‘)
17:52 yoleaux U+1F645 FACE WITH NO GOOD GESTURE [So] (🙅)
17:53 dpk haha, nice character name
17:53 diakopter .u olo
17:54 yoleaux No characters found
17:55 adu .u st
17:55 yoleaux U+FB06 LATIN SMALL LIGATURE ST [Ll] (st)
17:56 FROGGS_ .u POO
17:56 yoleaux U+1434 CANADIAN SYLLABICS POO [Lo] (ᐴ)
17:56 yoleaux U+1435 CANADIAN SYLLABICS Y-CREE POO [Lo] (ᐵ)
17:56 yoleaux U+A576 VAI SYLLABLE POO [Lo] (ꕶ)
17:57 n0den1te .mangle poo
17:57 yoleaux bloom
17:57 n0den1te :D
17:59 [Coke] .tw cokefloats
17:59 yoleaux I'm going to #replacereader with #Feedly http://www.replacereader.com/ been using it since the announcement, love it. (@cokefloats)
17:59 [Coke] .tw chromatic-x
17:59 yoleaux [Coke]: Sorry, that command (.tw) crashed.
17:59 diakopter ha
17:59 diakopter .tw quietfanatic
17:59 yoleaux @anocelot Can it do translation too? (@quietfanatic)
18:00 diakopter .tw dpkendal
18:00 yoleaux @splorp Happy birthday, Mr. Hutchinson! Enjoy thy celebrations! (@dpkendal)
18:00 diakopter it doesn't get retweets
18:01 dpk should it?
18:01 diakopter .tw bobobobobobobobo
18:01 yoleaux diakopter: Sorry, that command (.tw) crashed.
18:02 diakopter .tw .tw
18:02 yoleaux diakopter: Sorry, that command (.tw) crashed.
18:02 thou_ joined #perl6
18:02 dpk i thought if you wanted a retweet you should use the id of the tweet, or the name of the account of the person who tweetefd
18:02 pib1979 joined #perl6
18:02 * _sri wonders if perl6 has any features that make it a better language for templates than perl5
18:02 diakopter sgtm
18:02 dpk the .tw command is going to break soon anyway. it still uses Twitter API 1.0
18:03 _sri Template::Mojo seems to still be missing all the interesting features
18:03 dpk it should have broken when they said they'd turn it off, earlier this month. but obviously they haven't actually done that yet
18:03 diakopter is yoleaux live-patchable?
18:03 diakopter does it remember messages across restarts?
18:03 dpk .reload will pick up the latest changes to the command sources
18:03 yoleaux dpk: Reload done (took 1.989s).
18:03 moritz _sri: perl 5 propagates context inwards, which means you have to decide whether to put stuff in scalar or list context.
18:03 dpk yes, it does
18:03 moritz that's not the case with perl 6.
18:03 flussence _sri: as someone heavily OCD about neat-looking output, heredocs and .indent are probably killer features for me
18:04 diakopter dpk: cool :)
18:04 _sri masak: true, that will be really nice
18:04 _sri umm, moritz
18:05 moritz despite popular confusion, masak and me still aren't quite the same person :-)
18:05 _sri i was thinking more about blocks, <% do_stuff begin %>lalala<% end %>
18:05 cooper_ joined #perl6
18:06 _sri in the perl5 version that gets compiled to "do_stuff sub { 'lalala' };"
18:06 _sri a bit magical, ruby and lua are a lot better at it than perl atm
18:09 timotimo r: sub flub(*&a) { a(1) }; flub { say $^a };
18:09 p6eval rakudo ba5e04: OUTPUT«1␤»
18:09 [Coke] r: say StrPos.WHAT
18:09 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Undeclared name:�    StrPos used at line 1��»
18:10 _sri guess in the end all languages with curlies are not very good for templates ;p
18:11 timotimo that's what slangs are for~
18:11 cooper_ joined #perl6
18:16 _sri google doesn't have much information on slangs
18:17 arnsholt Well, it's a very fuzzy part of the spec
18:17 thou joined #perl6
18:17 arnsholt Mostly hypothetical I think
18:17 _sri could it be used to have a version of perl6 with do/end blocks instead of curlies?
18:18 arnsholt Possibly. I think so
18:18 _sri wow, that could be amazing for templates indeed
18:19 arnsholt Why do you need to change the curlies to begin/end for templates though?
18:19 _sri <% do_stuff sub { %>lalala<% } %>
18:19 _sri not cool
18:20 _sri while in ruby you have <% do_stuff do %>lalala<% end %>
18:20 arnsholt In the simple case there, it'd be pretty simple to do the munging in the templating engine, so I assume you can have arbitrarily complex stuff inside the <%%>?
18:21 _sri yes, Mojo::Template in perl5 does it that way
18:21 moritz well, in Perl 6 you could write   <% do-stuff { %> lalala <% } %> # without the 'sub'
18:23 _sri to my knowledge there has been only one successful template engine using curlies, and that is pretty much impossible to highlight outside of visual studio
18:23 _sri (it's Razor btw.)
18:24 arnsholt I can't help but feel that Wadler's law of language design is relevant here, though
18:26 cooper_ joined #perl6
18:26 thou joined #perl6
18:27 cooper_ joined #perl6
18:28 _sri just trying to get an overview of the capabilities of perl6 to plan the mojolicious port
18:29 _sri cargo culting workarounds for perl5 limitations that aren't necessary anymore would be silly
18:30 lue hello world o/
18:43 lue you *might* be able to make the do/end thing happen with macros, but I don't know macros in any way, so I can't help.
18:45 anant_ raiph: Yes, "real object" was bad. Replaced it with "concrete object" (https://gist.github.com/anant-sogani/5276483).
18:46 thou joined #perl6
19:07 thou joined #perl6
19:14 timotimo that IUP thing interests me
19:15 timotimo lue: when "is parsed" hits rakudo, you can totally do that. until then it'll be quite tricky i imagine
19:15 lue yeah (I tried a quick experiment with macros a little while ago to do what I suggested, to no avail)
19:18 timotimo is mrhdias on this channel?
19:19 lue not currently, it seems
19:19 timotimo seen mrhdias
19:19 timotimo is there some bot here that has some kind of syntax for that action?
19:19 timotimo !seen mrhdias
19:19 thou_ joined #perl6
19:20 benabik There was.  Aloha is homeless right now though.
19:21 nobu95 joined #perl6
19:23 lue you could search perlgeek.de's logs by username. IIRC, last occurrences come first.
19:23 nwc10 dear Perl 6, can I have a klorthobot?
19:24 timotimo what is that?
19:25 nwc10 well, I'd like to be able to give it a word of phrase, and it tells me all the advice from Klortho that matches
19:25 nwc10 yes, I know that it *could* be done in Perl 5
19:25 nwc10 but, well, if the first one is written in Perl 6, no-one else will need to bother
19:25 nwc10 and I think it would be popular
19:26 timotimo oh, it's that thing
19:27 timotimo today i'll develop a system utility that will make my life a little bit easier, using perl6
19:27 timotimo and it'll be only one line :P
19:31 timotimo (it disables the touch and gesture inputs on my wacom tablet, because they turn wonky after a couple of minutes of use and interfere with normal usage)
19:35 awwaiid joined #perl6
19:36 arnsholt timotimo: I don't think he's ever been here, unfortunately
19:36 arnsholt Maybe I should suggest it in one of the bug threads
19:38 timotimo sure why not :)
19:40 thou joined #perl6
19:41 p5eval joined #perl6
19:55 rindolf joined #perl6
19:58 adu joined #perl6
19:58 arnsholt Rakudo setting compiled! \o/
19:59 FROGGS_ \o/
19:59 arnsholt Onwards to the restricted one =)
19:59 lue .oO(CORE.setting takes far longer than any other part of the process by far)
19:59 arnsholt Tru dat
20:00 arnsholt I'm hunting compile errors, though =)
20:00 timotimo oh, this is vmarray work again!
20:00 timotimo cool beans
20:02 gcole joined #perl6
20:03 FROGGS_ my tonight's goal: proper support for p5's eval!
20:04 lizmat block or string ?
20:05 FROGGS_ both
20:06 lizmat cool!
20:07 FROGGS_ too many tests use it, so I'm kinda forced to do that next
20:10 timotimo sounds like a good decision
20:11 lizmat meanwhile wrt to use bytes and hints hash
20:11 lizmat I was mixing up $^H and %^H
20:12 lizmat anything that uses $^H, can be replaced by an ad-hoc solution, such as $*USE_BYTES (for use bytes)
20:17 raiph idea: an AST phaser. runs every block exit. modify or generate ast for block. crazy?
20:17 [Coke] perl.org infrastructure required for planetsix is going away; looks like planeteria is a reasonable alternative if we still want a sixplanet.
20:19 raiph (planetsix) i can imagine this being an opportunity to move back towards perl5
20:19 lue raiph: you could accomplish that with existing phasers and macros, methinks
20:20 adu raiph: are you the guy who made libart?
20:20 raiph adu: no
20:21 adu just checking
20:22 adu so what am I doing wrong: "Dynamic variable $*TYPEDEF_CONTEXT not found"
20:24 raiph adu: did you create $*TYPEDEF_CONTEXT? i'm guessing not so that's a bug in a compiler
20:25 adu r: grammar G { my $*CTX = False; token ident { <.alpha> <.alnum>* { $*CTX = True; } }; }; say G.parse('test');
20:25 p6eval rakudo ba5e04: OUTPUT«No such method 'TOP' for invocant of type 'G'␤  in method parse at src/gen/CORE.setting:10953␤  in block  at /tmp/7r61ZidWm3:1␤␤»
20:25 adu r: grammar G { my $*CTX = False; token TOP { <.alpha> <.alnum>* { $*CTX = True; } }; }; say G.parse('test');
20:25 p6eval rakudo ba5e04: OUTPUT«Dynamic variable $*CTX not found␤  in method <anon> at src/gen/CORE.setting:10627␤  in  at src/gen/Metamodel.pm:2501␤  in any find_method_fallback at src/gen/Metamodel.pm:2489␤  in any find_method at src/gen/Metamodel.pm:937␤  in regex TOP at /tmp/4jmZPCstes:1␤  in…
20:26 FROGGS_ r: grammar G { :my $*CTX = False; token TOP { <.alpha> <.alnum>* { $*CTX = True; } }; }; say G.parse('test');
20:26 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Two terms in a row�at /tmp/02kND6AtbZ:1�------> [32mgrammar G { :my [33m�[31m$*CTX = False; token TOP { <.alpha> <.al[0m�    expecting any of:�        pair value�        postfix�        infix stopper�        infix or meta-infix�  Ã¢â‚¬Â¦
20:27 FROGGS_ hmm, looks like I'm mixing up nqp and perl6
20:27 adu FROGGS_: heh
20:27 FROGGS_ r: grammar G { token TOP { :my $*CTX = False; <.alpha> <.alnum>* { $*CTX = True; } }; }; say G.parse('test');
20:27 p6eval rakudo ba5e04: OUTPUT«「test」␤␤»
20:28 FROGGS_ see
20:28 FROGGS_ I'm not mixing up
20:28 FROGGS_ just was the wrong position :o)
20:28 adu so how do I make it available to other regex's
20:28 ikrs joined #perl6
20:28 FROGGS_ adu: it will be available in every token that is "after" TOP
20:28 adu ah
20:29 FROGGS_ like alpha and alnum you used there
20:29 adu ok
20:29 timotimo rather "further down the 'call stack'"
20:29 FROGGS_ yeah
20:29 timotimo (down or up, depending on the direction your stack grows in)
20:29 adu FROGGS_: I'm confused because STD.pm6 puts them above everything
20:29 adu why does it work for STD.pm6 but not for me
20:33 adu r: grammar G { my $*CTX = False; token TOP { <ident> { $*CTX = True; } }; token ident { <.alpha> <.alnum>* <?{ ($*CTX) }> }; }; say G.parse('test');
20:33 p6eval rakudo ba5e04: OUTPUT«#<failed match>␤»
20:34 adu r: grammar G { token TOP { { my $*CTX = True; } <ident> }; token ident { <.alpha> <.alnum>* <?{ ($*CTX) }> }; }; say G.parse('test');
20:34 p6eval rakudo ba5e04: OUTPUT«#<failed match>␤»
20:34 * lizmat was wondering: is there going to be a rakudo star 2013.03 release ?
20:34 adu that should have succeeded
20:37 FROGGS_ r: grammar G { token TOP { :my $*CTX = True; <ident> }; token ident { <.alpha> <.alnum>* <?{ $*CTX }> }; }; say G.parse('test');
20:37 p6eval rakudo ba5e04: OUTPUT«「test」␤ ident => 「test」␤␤»
20:38 FROGGS_ AFAIK {} stops LTM, but since there is just one token... dunno why it doesnt like that
20:38 adu r: grammar G { token TOP { :my $*CTX = True; <ident> }; token ident { <.alpha> <.alnum>* <?{ ($*CTX) }> }; }; say G.parse('test');
20:38 p6eval rakudo ba5e04: OUTPUT«「test」␤ ident => 「test」␤␤»
20:38 adu YEY
20:38 adu LTM?
20:38 FROGGS_ longest token matching
20:38 adu hmm
20:39 FROGGS_ hold on
20:39 FROGGS_ maybe $*CTX is just valid within the block?
20:39 FROGGS_ makes sense to me
20:39 FROGGS_ and since <ident> is not within that block it wont be there
20:39 adu so I have to use :my
20:40 FROGGS_ r: grammar G { token TOP { { :my $*CTX = True; } <ident> }; token ident { <.alpha> <.alnum>* <!{ ($*CTX) }> }; }; say G.parse('test');
20:40 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Two terms in a row�at /tmp/SVauG6ogio:1�------> [32mgrammar G { token TOP { { :my [33m�[31m$*CTX = True; } <ident> }; token ident {[0m�    expecting any of:�        pair value�        postfix�        infix stopper�        infix or…
20:40 FROGGS_ r: grammar G { token TOP { { my $*CTX = True; } <ident> }; token ident { <.alpha> <.alnum>* <!{ ($*CTX) }> }; }; say G.parse('test');
20:40 p6eval rakudo ba5e04: OUTPUT«「test」␤ ident => 「test」␤␤»
20:40 FROGGS_ yes, so that it is seen from the tokens within that token
20:41 FROGGS_ r: { my $x = 7; say $x }
20:41 p6eval rakudo ba5e04: OUTPUT«7␤»
20:41 FROGGS_ r: { { my $x = 7; }; say $x }
20:41 p6eval rakudo ba5e04: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable '$x' is not declared�at /tmp/Obw9BBrsCV:1�------> [32m{ { my $x = 7; }; say $x[33m�[31m }[0m�    expecting any of:�        postfix�»
20:41 FROGGS_ see
20:41 FROGGS_ it's not php :o)
20:41 adu ok
20:44 timotimo lizmat: well, we did have a compiler release already, someone probably was going to make a star release, too
20:44 FROGGS_ pmichaud: said that
20:46 * timotimo can't tell who was going to be the release manager for 03
20:47 FROGGS_ I believe there was none so masak did it
20:48 FROGGS_ r: try { say 1/0 }; say $!.Str.substr(0,10); say "alive"
20:48 p6eval rakudo ba5e04: OUTPUT«Divide by ␤alive␤»
20:49 FROGGS_ I think I'll use that for eval BLOCK
20:49 timotimo divide by alive, eh?
20:50 FROGGS_ :o)
20:50 FROGGS_ it's more like: devide by newline
20:50 timotimo :)
20:54 timotimo can't test my wacom script thingie because apparently i displaced all of my damn microusb cables yet again :(
20:56 diakopter r: my  $x .=Int;
20:56 p6eval rakudo ba5e04: OUTPUT«No such method 'Int' for invocant of type 'Any'␤  in method dispatch:<.=> at src/gen/CORE.setting:1014␤  in block  at /tmp/f4UbDCkwYX:1␤␤»
20:56 diakopter r: my  $x .=WHAT;
20:56 p6eval rakudo ba5e04: OUTPUT«No such method '' for invocant of type 'Any'␤  in method dispatch:<.=> at src/gen/CORE.setting:1014␤  in block  at /tmp/5544WelhAv:1␤␤»
20:56 diakopter o)o
20:59 diakopter ha
20:59 diakopter r: say my $x .=max;
20:59 p6eval rakudo ba5e04: OUTPUT«-Inf␤»
20:59 diakopter r: say my $x .=min;
20:59 p6eval rakudo ba5e04: OUTPUT«Inf␤»
21:00 diakopter hm.
21:00 timotimo oh, that's cute
21:02 thou joined #perl6
21:04 dmol joined #perl6
21:06 dmol joined #perl6
21:07 dalek v5: d3afde4 | (Tobias Leich)++ | lib/Perl6/P5Actions.pm:
21:07 dalek v5: make "eval BLOCK" work, this sets $@
21:07 dalek v5: review: https://github.com/rakudo-p5/v5/commit/d3afde4be1
21:08 FROGGS_ does somebody know how to get the value of an environment var within nqp?
21:09 dmol joined #perl6
21:10 kivutar joined #perl6
21:10 lizmat FROGGS: wrt to +        make QAST::Var.new( :name('$!'), :scope('lexical') )
21:11 lizmat s/\$!/\$@/ ?
21:11 FROGGS_ this $! is Perl 6's variable, $@ later dispatches to $!
21:12 lizmat aha, ok...
21:12 FROGGS_ IMO it is good to keep $!, because:
21:12 FROGGS_ { use v5; eval { 1/0 }; } use v6; say $!
21:13 FROGGS_ something like that
21:13 lizmat but { use v5; eval { 1/0 }; say $@ } would also work, then, right?
21:14 FROGGS_ it does already
21:14 sorear .oO( use 5.010 )
21:14 lizmat ack, gotcha
21:14 lizmat is there a reason you want to emulate 5.10.0 rather than e.g. 5.14.0
21:14 lizmat ?
21:14 FROGGS_ no
21:15 FROGGS_ I just typed in something
21:15 lizmat ok
21:15 FROGGS_ sorear: ?
21:15 lizmat also: I think we can get away with not supporting smart match in p5
21:16 FROGGS_ why? will it be removed?
21:16 lizmat the way I read p5p, is that indeed it will be deprecated and removed at some point
21:16 FROGGS_ sad
21:17 FROGGS_ since we could do it right *g*
21:18 labster It doesn't mean there won't be code with smart match out there.  I've used it in P5 code.
21:18 FROGGS_ me too
21:18 FROGGS_ but just in one project
21:19 lizmat yes, I did as well
21:19 timotimo having almost no clue about P5, what is it that makes smartmatch so bad for p5? is it the lack of object system in stock perl5?
21:19 lizmat but because p5 can't get it right because of lack of a type system
21:21 labster rn: my \m = 'foo'; say m.defined;
21:21 p6eval niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��Regex missing terminator (or semicolon must be quoted?) at /tmp/RoILhePQLs line 1 (EOF):�------> [32mmy \m = 'foo'; say m.defined;[33m�[31m<EOL>[0m��Parse failed��»
21:21 p6eval ..rakudo ba5e04: OUTPUT«���[���3���1���m���=���=���=������[���0���m���S���O���R���R���Y���!������[���3���1���m���=���=���=������[���0���m�������U���n���r���e���c���o���g���n���i���z
21:22 lizmat wrt to smartmatch in p5: https://rt.perl.org/rt3//Public/Bug/Display.html?id=116913
21:22 timotimo whoooops :D
21:22 * labster really needs to stop using regex starters as variable names
21:26 labster that makes me sad.  I've used given/when in P5 code quite a bit.
21:27 FROGGS_ yeah, given/when is quiet nice
21:28 FROGGS_ I mean, I just put regexes and string in when clauses, this should work right, no?
21:30 lue .oO(It does in Perl 6, *cough* *cough*)
21:31 FROGGS_ :o)
21:32 FROGGS_ lue: ya, if we could get XS right, rakudo/perl5 with the sixmodelobjects could release the 5.24 :P
21:33 labster quick, let's ask p5p to all stop what they're doing and start working on rakudo
21:33 lizmat labster: there, you got the right idea
21:34 lue Introducing our latest release of Rakudo Star, named "version 5.24". This is because it now has P5 support, and then goes above and beyond existing versions of the standard Perl 5 compiler.
21:34 lizmat much better then arguing for *weeks* about how to implement subroutine signatures *sugar*
21:34 sorear FROGGS_: in perl 5, "say" is only a keyword if an explicit "use v5.10" or greater is in scope (or "use feature 'say'", but nobody does that)
21:35 FROGGS_ sorear: I do that
21:35 labster I do that
21:35 FROGGS_ hehe
21:36 sorear timotimo: p5 copied the old perl 6 smartmatch that nobody here likes anymore, not the new smartmatch
21:36 FROGGS_ sorear: at some point I'll read the feature lists and will activate these keywords only then
21:36 timotimo oh, i'm not perl6-old enough to know what the old smartmatch was like
21:37 * lue is almost tempted to respond with "look at Perl 5" :)
21:37 sorear timotimo: There was this crazy idea that smartmatch should be symmetrical.  /oo/ ~~ "foobar"
21:37 sorear when ("foobar") { # matches "foobar", also matches rx/oo/
21:38 lue gah. No wonder they want to get rid of it from P5.
21:38 timotimo oh, that's weird
21:39 lizmat what is?
21:39 FROGGS_ mathw: \o/
21:39 mathw hi
21:39 mathw :)
21:40 adu what does this mean: "Cannot call 'Real'; none of these signatures match: :(Mu:U \v: Mu *%_)"
21:40 lichtkind FROGGS_: thanks again for help @ gpw
21:40 FROGGS_ lichtkind: thanks for your talk :o)
21:40 lizmat yeah, it was really good!
21:41 lichtkind thank you
21:41 FROGGS_ mathw: have you seen? there is already some perl5<->perl6 work going on
21:41 lichtkind i hope th eversion in kiev will be better
21:42 adu oops, it means I was using [] instead of {}
21:42 lizmat lichtkind: practice makes perfect!
21:42 mathw FROGGS_: such as?
21:42 mathw FROGGS_: I'm a little out of touch at the moment, been busy.
21:42 FROGGS_ mathw: https://github.com/rakudo-p5/v5
21:42 FROGGS_ perl 5 blocks (and pure perl 5 modules) within perl 6 code
21:43 mathw oh
21:43 mathw ooh
21:43 mathw ooooooh
21:43 FROGGS_ I'm not working at blizkost though
21:43 lizmat indeed: rakudo-p5 does not require a standard perl 5 lib
21:43 mathw perl 6 grammar mutability ftw
21:44 FROGGS_ ohh yeah, it is pretty awesome
21:44 FROGGS_ (hard for code highlighters though)
21:44 mathw Perl never was easy for highlighting
21:44 lizmat those on the bleeding edge always suffer  :-)
21:44 mathw even when there was only one language in each file
21:44 adu mathw: lol
21:45 lichtkind mathw: as author of an editor you got my proof perl has the hardest highlighting of all :)
21:45 mathw Well I read some things a few years back about how you can't parse Perl 5 properly without at least partially executing it
21:45 timotimo at this point, it would be swell if one could pepper the sourcecode with hints for the highlighter
21:45 mathw Which is a bit tricky in an editor
21:46 timotimo "i know you think this is inside the quote, but the quote has long ended. you are now inside a block. please highlight my code again?"
21:46 mathw I was writing a load of Lisp a couple of months back, highlighting that's fairly easy :)
21:46 timotimo mathw: yeah, but there isn't terribly much info to be gleaned from the highlighting IMO
21:46 adu mathw: unless you have to include racket
21:47 adu mathw: or scribble
21:47 mathw timotimo: true... not much info in Lisp syntax at all
21:47 timotimo one can say that's a good or bad thing. a matter of taste, clearly
21:47 mathw although my biggest issue with Lisp is the dynamic typing, the syntax is quite easy to deal with really
21:49 pmurias joined #perl6
21:50 adu ok, I think the only thing I have left to do is escape-sequence, then I can upload my C11 grammar
21:50 FROGGS_ cool
21:50 mathw need to do some more Perl 6 again soon
21:50 timotimo C11? is that like C++11, but without the ++?
21:51 pmurias if I have token version { $<vstr>=[<vnum>+ % '.' '+'?] } parse '5.16' how do I extract the '5'?
21:51 adu timotimo: no, C11 is the latest C standard, C++11 is the latest C++ standard, completely different beasts
21:51 timotimo mhm
21:51 adu it was easier when the latest was C99 and C++03
21:52 timotimo r: token version { $<vstr>=[<vnum>+ % '.' '+'?] }; "5.16" ~~ &version; say $<vstr>;
21:52 p6eval rakudo ba5e04: OUTPUT«Useless declaration of a has-scoped method in mainline�[31m===[0mSORRY![31m===[0m�Undeclared name:�    &version used at line 1. Did you mean 'Version'?��»
21:52 FROGGS_ pmurias: should be $<vnum>[0].ast
21:52 timotimo oh, hmm.
21:52 adu I wonder if I should use gnu's cpp instead of trying to do it myself...
21:58 arnsholt adu: If you wanna do stuff with C, I think the LLVM libs are your best bet
21:58 adu arnsholt: I've looked into it, their XML format sucks
21:59 adu and if I'm going to have to write my own thing, then I'd rather do it in Perl6 instead of C++
22:00 mathw mmm
22:00 mathw Spirit is good, but Perl 6 grammars are better
22:00 adu mathw: indeed
22:01 adu spirit is boost/C++ which I hate
22:01 arnsholt adu: I haven't tried the XML stuff, but libclang looked reasonable from what little I looked at it
22:01 adu the ONLY runner up I've found anywhere to Perl6 grammars is ANTLR
22:01 arnsholt It's C, not Perl 6 though. Upside is, you don't have to parse at all, just munge the AST
22:02 adu libclang isn't C it's C++
22:03 adu arnsholt: again, I've looked into it, and I've done more in a couple days with Perl6 than I could have in a couple months with libclang, because that's how long I tried to use libclang
22:03 arnsholt The guts are C++, AFAIK, but there's a perfectly serviceable C API
22:03 arnsholt Fair 'nuff. Just figured I mention it
22:04 adu all I'm trying to do is get an XML dump of C/C++ code
22:07 adu I've also tried GCCXML, which does just that, but the XML format sucks
22:08 FROGGS_ XML always sucks
22:08 adu true
22:09 adu but it's quite powerful, being able to transform structures without knowing what they're made of
22:15 arnsholt What do you want the XML for, OOC?
22:19 adu a long project
22:20 adu I've been working on it for the past 20 years, and probably for the next 70 years
22:20 arnsholt Fair 'nuff =)
22:21 arnsholt I wanted to extract typedefs and stuff from header files
22:21 adu to document the equivalencies of different things
22:21 arnsholt But ATM I'm sidetracked on (yet another) yak shave =)
22:23 adu yak?
22:23 colomon joined #perl6
22:25 arnsholt http://www.catb.org/jargon/html/Y/yak-shaving.html
22:25 pmurias if a module emulates an old api how can it determine which api version it is imported as?
22:25 arnsholt I've got a couple of yaks pushed on my stack, to be honest =)
22:26 mathw FROGGS_: my new job have got me lined up to write two giant XSLTs soon. One targetting HTML, the other XSL-FO (which I don't know yet). That'll be fun!
22:27 adu arnsholt: for example, andmap: http://docs.racket-lang.org/reference/pairs.html#%28def._%28%28lib._racket%2Fprivate%2Fmap..rkt%29._andmap%29%29 and predicate_on_list: http://www.openmath.org/cd/fns2.xhtml#predicate_on_list are not equivalent, but can both be used to implement nary comparison
22:27 FROGGS_ :o)
22:28 adu arnsholt: are you calling my project a yak shave?
22:28 arnsholt And you want to compare code for equivalence?
22:28 adu arnsholt: eventually
22:28 arnsholt adu: No, no! I'm calling -my- project a yak shave
22:29 arnsholt In fact I'm shaving a yak, to better shave another yak to do what I started out doing
22:29 arnsholt Although, that top-level task may be best considered atrophied and I've just changed primary focus
22:29 arnsholt For comparing code for equivalence, I assume you're familiar with Rice's theorem?
22:30 adu arnsholt: and to be precise, sub predicate_on_list(&proc, @list) { return and_map(&proc, most(@list), rest(@list)); }
22:32 [Coke] http://planeteria.org/perl6/ is starting to get perl 6 content.
22:33 adu arnsholt: nope
22:36 adu arnsholt: I just read the wikipedia article on Rice's theorem, and it's about classification, not equivalences
22:38 arnsholt Well, one of the things that follow from it is that you can't (in the general case, anyways) prove equivalence of two arbitrary pieces of code
22:38 arnsholt Which is why things like static analysis and optimisation are so hard: there are only special cases
22:38 adu arnsholt: I've heard that before
22:39 adu arnsholt: I didn't know what it was called
22:39 adu arnsholt: but I don't care, I'm doing it
22:39 adu that's like saying oh, parsing languages won't work, because we might get syntax errors
22:39 adu so we might as well not build a compiler...
22:43 * lizmat is calling it an early night to accommodate for DST starting this night (in Europe)
22:45 [Coke] I'm going to take this opportunity to cull some of the feeds in the sixplanet.
22:47 dalek v5: a351fdc | (Tobias Leich)++ | lib/Perl6/P5 (2 files):
22:47 dalek v5: make "eval EXPR" und "eval" work
22:47 dalek v5: review: https://github.com/rakudo-p5/v5/commit/a351fdcea7
22:48 timotimo very cool :)
22:48 masak lizmat: yes, I'm giving talks at YAPC::NA. \o/ (I hope)
22:50 lizmat masak: do you know of any perl 6 related talks that should be given at YAPC::NA, but are not currently submitted ?
22:50 lizmat s/should be given/you think should be given/
22:51 * FROGGS_ wishes to see a talk about perl6 on android
22:52 lizmat that would be cool
22:52 timotimo is that a thing already?
22:54 masak lizmat: I know diakopter++ has been coordinating a lot, and from what I've seen of the program, it looks very promising.
22:57 timotimo masak: for my ADT module, do you think with a macro i can cause the classes to be available "at compile time" for things like multiple dispatch? i couldn't do it with a BEGIN block. (or perhaps it would have had to be something else than BEGIN? to be "at compile time"?)
22:58 cognominal joined #perl6
22:59 arnsholt BEGIN is compile-time
23:00 arnsholt INIT is the one that's similar to Perl 5 BEGIN, IIRC
23:00 timotimo i need to try that out again.
23:00 timotimo isn't there also CHECK time?
23:00 arnsholt And CHECK, yeah
23:04 masak timotimo: macros are conceptually at BEGIN time, yes.
23:05 dalek specs: 59052ef | chansen++ | S32-setting-library/Temporal.pod:
23:05 dalek specs: Renamed weekday-of-month to day-of-week-in-month
23:05 dalek specs:
23:05 dalek specs: Weekday usually means any day of the week other than a day that occurs in
23:05 dalek specs: the weekend unless the API is constrained by struct tm. Which uses wday.
23:05 dalek specs: review: https://github.com/perl6/specs/commit/59052efdde
23:05 dalek specs: d01495e | (Carl Mäsak)++ | S32-setting-library/Temporal.pod:
23:05 dalek specs: Merge pull request #34 from chansen/master
23:05 dalek specs:
23:05 dalek specs: Renamed weekday-of-month to day-of-week-in-month
23:05 dalek specs: review: https://github.com/perl6/specs/commit/d01495e05b
23:06 dmol joined #perl6
23:06 masak [Coke]: re https://rt.perl.org/rt3/Ticket/Display.html?id=67122 and "is this the right behavior" -- I don't know. I wouldn't mind some discussion here.
23:07 timotimo how do i properly set the Branch type up at compile time when i have my %result = create_adt(...) and i have %result<Branch>?
23:07 timotimo my \Branch := %result<Branch> doesn't seem to help
23:07 masak the two possible behaviors I see are (a) the one exhibited now, "invalid UTF-8 character for UTF-8 encoding", or (b) shouldn't be able to .succ into an invalid character range, and just skip above it.
23:07 timotimo i get "invalid typename in parameter declaration" in that case
23:27 cognominal joined #perl6
23:33 pmurias joined #perl6
23:35 adu https://gist.github.com/andydude/5278826
23:36 adu I'm getting "Type 'ExternalDeclaration' is not declared"
23:36 cognominal joined #perl6
23:37 adu am I doing something wrong?
23:38 masak adu: yes -- referencing a type before declaring it.
23:38 Chillance joined #perl6
23:38 masak std: class A { has B $.b }; class B {}
23:38 p6eval std 86b102f: OUTPUT«[31m===[0mSORRY![31m===[0m�In has declaration, typename 'B' must be predeclared (or marked as declarative with :: prefix) at /tmp/Sli17QBHl9 line 1:�------> [32mclass A { has B[33m�[31m $.b }; class B {}[0m�Malformed has at /tmp/Sli17QBHl9 line 1:�------> [3…
23:45 diakopter rn: class A { has ::B $.b }; class B {}
23:45 p6eval rakudo ba5e04:  ( no output )
23:45 p6eval ..niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��GLOBAL::B does not name any package at /tmp/Mkh51QV3OF line 1:�------> [32mclass A { has ::B[33m�[31m $.b }; class B {}[0m��A type must be provided at /tmp/Mkh51QV3OF line 1:�------> [32mclass A { has ::B[33m�[31m $.b…
23:46 diakopter r: class A { has ::B $.b }; class B {}; print B.new; print A.new.b.new
23:46 p6eval rakudo ba5e04: OUTPUT«B<-905822265>No such method 'new' for invocant of type 'B'␤  in block  at /tmp/TluLYMLqwz:1␤␤»
23:47 diakopter masak: ^^ hmm
23:47 masak :/
23:47 masak that looks wrong.
23:47 masak looks like it's retaining the stub, and not replacing it with the real B.
23:48 * masak submits rakudobug
23:48 diakopter r: class B {}; class A { has B $.b }; print B.new; print A.new.b.new
23:48 p6eval rakudo ba5e04: OUTPUT«B<1785303324>B<1791592750>»
23:48 diakopter r: class B {}; class A { has ::B $.b }; print B.new; print A.new.b.new
23:48 p6eval rakudo ba5e04: OUTPUT«B<-931868390>No such method 'new' for invocant of type 'B'␤  in block  at /tmp/ovh8hRY1hT:1␤␤»
23:48 masak interesting.
23:49 masak so it has nothing to do with forward references. only with ::
23:49 diakopter I suppose so, yes
23:53 diakopter r: my ::A $b; print $b.new
23:53 p6eval rakudo ba5e04: OUTPUT«No such method 'new' for invocant of type 'A'␤  in block  at /tmp/uGlnpdofBU:1␤␤»
23:53 diakopter r: my ::A $b; print $b.^methods
23:53 p6eval rakudo ba5e04: OUTPUT«No such method 'dispatch:<.^>' for invocant of type 'A'␤  in block  at /tmp/A5Yaky5mSc:1␤␤»
23:54 diakopter r: my ::A $b; print $b.WHAT
23:54 p6eval rakudo ba5e04: OUTPUT«Cannot type check against type variable A␤  in any type_check at src/gen/Metamodel.pm:303␤  in method print at src/gen/CORE.setting:7824␤  in sub print at src/gen/CORE.setting:7640␤  in block  at /tmp/XXubY15ovw:1␤␤»

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

Perl 6 | Reference Documentation | Rakudo