Camelia, the Perl 6 bug

IRC log for #perl6, 2009-04-29

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs

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

All times shown according to UTC.

Time Nick Message
00:00 jnthn I seem to remember that I started taking us in that direction - creating a PMCProxy object at the point the PMC's vtable was built.
00:00 jnthn IIRC allison then felt we shouldn't be creating all of those PMCs up front but instead should create them on-demand.
00:00 pmichaud it's okay with me if it's done at the point where it's first needed... but mro really shouldn't be a list of names.
00:01 jnthn yeahbut we gotta know the list of parents in terms of _something_
00:01 pmichaud where does mro come from in the first palce?
00:01 pmichaud *place?
00:01 jnthn And it can't be in terms of class objects if we...y'know...ain't creating them.
00:02 jnthn Look at any .c file generated from a .pmc file
00:02 jnthn And grep for VTABLE_push_string(interp, mro
00:03 pmichaud I presume it's more interesting for a PMC that actually has parents :-)
00:03 jnthn yes ;-)
00:04 pmichaud okay, here's what really doesn't make sense then.
00:04 pmichaud Capture PMC doesn't have any parents.
00:04 pmichaud so we shouldn't even be in that loop to begin with.
00:05 pmichaud or we're looping on something _other_ than the Capture PMC
00:05 jnthn I suspect the latter.
00:05 pmichaud looks like Hash.
00:06 jnthn What has Hash as a parent...
00:06 pmichaud so.... let me throw Hash into the mix
00:06 pmichaud or Maping
00:06 jnthn Oh, lots of things.
00:06 jnthn Yeah, try that.
00:07 jnthn oh, we'll need a few other bits to throw taht in.
00:08 pmichaud lots of dependencies for those
00:08 jnthn yeah
00:08 jnthn 'cus you pull in the whole parametric role fun.
00:09 pmichaud which means we need the dynops
00:09 jnthn Oh?
00:09 jnthn Maybe
00:09 pmichaud because we need guts.pir
00:09 jnthn Ah, yes.
00:10 pmichaud it gets kinda ugly from there.
00:11 japhb jnthn: sorry to interrupt.  I saw a commit that you worked on constant decls.  Did you get 'constant foo is export' working also?
00:11 jnthn japhb: No, not is export just yet.
00:11 jnthn But otherwise constant is working.
00:11 jnthn Or should be working enough.
00:11 jnthn Will do export later in the week, all being well.
00:12 pmichaud trying to add Hash into the small example doesn't seem like a fruitful path at the moment.
00:12 japhb jnthn: OK, cool, thanks!
00:13 jnthn pmichaud: Sure. Though I wonder if sticking a Hash entry in the namespace is enough?
00:13 jnthn Just faking something up
00:13 pmichaud I've just been using the PAST::Op protoobject :-)
00:14 japhb What is the current easiest way in Rakudo to insert a file (textually) into the currently compiling file? (I'm looking for the equivalent of cpp #include, more or less)
00:14 pmichaud since Hash ends up being a protoobject :-)
00:14 jnthn Syre
00:14 pmichaud japhb: require ?
00:14 jnthn require isn't so much textual though?
00:14 pmichaud I don't think there's a textual include in Perl 6.
00:14 cspencer rakudo: my @a = <a b c d>; say @a.exists(*-5)
00:14 jnthn Aye, me either...and I suspect that's what japhb is really needing.
00:15 japhb pmichaud: What jnthn said.
00:15 p6eval rakudo c76d8d: OUTPUT«Use of uninitialized value␤0␤»
00:15 jnthn japhb: I suspect for now you can't do stuff in modules until is export is in place.
00:15 japhb But thanks, I had also forgotten that require was working.  :-)
00:15 jnthn is export for constants, that is
00:16 cspencer rakudo: my @a = <a b c d>; say @a.exists(*-4)
00:16 p6eval rakudo c76d8d: OUTPUT«Use of uninitialized value␤1␤»
00:17 jnthn pmichaud: Getting quite tired (late here and still catching up on sleep) so 'fraid I'll have to leave this bug hunting for now.
00:17 pmichaud jnthn: no problem, I will have to leave also.
00:17 pmichaud But at least we've identified the loop.
00:18 jnthn Sure.
00:18 jnthn And fixed some stuff that was making us fail earlier.
00:19 pmichaud a-ha!
00:19 pmichaud nopaste coming!
00:19 pmichaud http://nopaste.snit.ch/16433   # now with segfaults!
00:20 pmichaud and if I comment out the include of Capture.pir, it doesn't segfault.
00:20 pmichaud *this* is something we can work with.
00:20 pmichaud Later.  Or tomorrow.
00:21 pmichaud Or maybe Tene++ can pick it up.
00:21 jnthn Excellent.
00:21 jnthn OK, posted Rakudo day report at http://use.perl.org/~Jonath​anWorthington/journal/38888
00:21 jnthn and now, sleep time
00:21 jnthn night
00:22 pmichaud I'm a little surprised that -G exposed the bug more readily.
00:22 pmichaud jnthn: bug in rakudo report
00:22 pmichaud my $x = 42; # ok
00:22 pmichaud should be
00:22 pmichaud my answer $x = 42;
00:23 jnthn oops
00:23 jnthn fixed, thanks!
00:24 pmichaud dynnertyme here  :-)
00:24 jnthn enjoy!
00:24 jnthn cu
00:25 Tene I can look at it after Miscellaneous Events with the girlfriend.
00:30 hercynium joined #perl6
00:32 meteorjay joined #perl6
00:41 japhb rakudo: eval "say 'foo'"
00:41 p6eval rakudo c76d8d: OUTPUT«foo␤»
00:41 japhb rakudo: "say 'foo'".eval
00:42 p6eval rakudo c76d8d: OUTPUT«Method 'eval' not found for invocant of class 'Str'␤current instr.: 'parrot;P6metaclass;dispatch' pc 662 (src/classes/ClassHOW.pir:171)␤»
00:42 japhb std: "say 'foo'".eval
00:42 p6eval std 26545: OUTPUT«ok 00:04 35m␤»
01:08 eternaleye joined #perl6
01:22 ispy_ joined #perl6
01:52 ispy_ left #perl6
01:56 alanhaggai joined #perl6
02:00 PhatEddy left #perl6
02:03 nihiliad joined #perl6
02:23 cognominal joined #perl6
02:31 meppl joined #perl6
02:33 bacek_ joined #perl6
02:55 pmichaud Tene, jnthn:  http://nopaste.snit.ch/16436
02:55 pmichaud a very small, simple test case leading to a segfault with .HLL
02:55 pmichaud Remove the .HLL line and it runs just fine.
02:55 Tene Nice.
02:57 pmichaud and yes, it goes into an infinite loop.
03:00 FurnaceBoy joined #perl6
03:05 Tene Yeah, it's capture.pmc:550
03:06 pmichaud I wonder if there's some other way we can get to the proxy object.
03:06 pmichaud or the Capture PMC
03:06 pmichaud (the classobj)
03:07 Tene can list() get_global [parrot;Capture] ?
03:07 pmichaud yes, that's what I'm wondering.
03:08 Tene want me to try?
03:09 pmichaud sure
03:09 pmichaud I'll have to take a break in a moment.
03:11 meppuru joined #perl6
03:12 pmichaud looks to me like    Parrot_get_namespace_keyed_str(INTERP, root_ns, 'Capture')
03:12 pmichaud er, no.
03:12 pmichaud hmm.
03:13 pmichaud looks to me like    Parrot_get_namespace_keyed_str(INTERP, root_ns, 'parrot')
03:13 pmichaud and then after that 'Capture'
03:13 pmichaud unless there's an easy way to build a key
03:14 jaye joined #perl6
03:17 pmichaud it's also possible that the whole PObj_is_object_TEST(self) conditional can be avoided now.
03:18 pmichaud that may be left-over from earlier versions of parrot where such subclassing had to be explicitly tested and worked around
03:18 pmichaud so it might be worth checking other PMCs that have methods and see how/if they handle it.
03:18 Tene can I put decl in an if{} in C89?
03:20 Tene then Parrot_oo_get_class(INTERP, namespace);
03:22 Tene It works.
03:22 Tene I'm testing it now
03:26 pmichaud might be nice to only do the ns lookups inside the if()
03:26 pmichaud since they aren't used outside
03:26 Tene Can I declare ns in the if{} ?
03:26 Tene in C89?
03:26 pmichaud sure -- there are other declarations there
03:26 Tene ... wow
03:26 pmichaud -            STRING *classname = CONST_STRING(INTERP, "Capture");
03:27 Tene Thank you.
03:27 pmichaud that's a declaration.
03:27 pmichaud but the declarations all have to be at the beginning
03:27 pmichaud so you can't have the two   ns = Parrot...   statements followed by another declaration
03:27 Tene except... unless I mix that entire thing into one line, I need to declare all of them, and then do the lookups...
03:27 Tene so twice the lines.
03:27 pmichaud no
03:28 pmichaud just a sec
03:28 Tene anyway, all tests pass
03:37 orafu joined #perl6
04:09 eternaleye_ joined #perl6
04:47 hercynium joined #perl6
04:51 alester joined #perl6
04:55 mberends joined #perl6
05:15 rewt joined #perl6
05:16 wayland76 joined #perl6
05:27 eternaleye_ (re threads) You know, the most elegant solution might be to get these Peng Li and Steve Zdancewic people hooked on Perl 6 and let them help hammer out the spec.
05:28 eternaleye_ (the ones who wrote the Unify paper)
05:29 masak joined #perl6
05:29 masak good morning, parsercamels.
05:31 wayland76 eternaleye_: Where do they hang out?
05:31 lambdabot wayland76: You have 3 new messages. '/msg lambdabot @messages' to read them.
05:31 eternaleye_ wayland76: I dunno. I'm gonna try and track them down.
05:34 wayland76 http://www.cis.upenn.edu/~stevez/
05:35 mberends masak: good morn, I think there may be some sockets test (unix only) working soon based on forking in a little shell script.
05:36 masak mberends: good morrow. that sounds nice indeed.
05:36 Tene do we have fork in parrot?
05:38 Tene Looks like no.
05:38 wayland76 (and just a minute ago, when I said "Where do they hang out", I was thinking of the quote from the Connecticut Yankee where Sandy say " 'Where do they hang out?' Verily, it trippeth from the tongue with lightess and...." (I forget the rest, and even lightness may be wrong)
05:39 japhb joined #perl6
05:42 mberends joined #perl6
05:45 alanhaggai joined #perl6
05:54 masak std: UnknownType
05:54 p6eval std 26545: OUTPUT«Undeclared name:␤      UnknownType used at 1 ␤ok 00:02 35m␤»
05:54 masak std: KitchenSink
05:54 p6eval std 26545: OUTPUT«ok 00:02 35m␤»
05:54 masak std: class KitchenSink {}
05:55 p6eval std 26545: OUTPUT«ok 00:02 35m␤»
05:55 masak std: class Int {}
05:55 p6eval std 26545: OUTPUT«ok 00:02 35m␤»
05:55 masak TimToady: any reason it doesn't warn for those last two?
05:58 Tene masak: I have many tests passing in rakudo in the hll branch.
05:58 Tene A few failures... but mostly passes.
05:58 Tene I can probably merge it soon.
05:59 masak Tene: hm, that was the blocker for things like playing around with Hitomi and PCT, right?
05:59 Tene kinda, potentially.
06:00 Tene It meant that no other HLL could use Perl 6 code.
06:00 cognominal_ joined #perl6
06:01 Tene pmichaud, jnthn: i have rakudo passing many tests in the hll branch.  Still a few failures left.
06:01 masak Tene: what causes the failures?
06:02 Tene Dunno yet!  It's a mystery!
06:02 Tene :)
06:02 masak :)
06:03 Tene I expect some of them are from unfudged tests in master
06:03 masak well, try merging then.
06:04 Tene success!
06:04 Tene building again...
06:07 wayland76 I'm working with POE (on P5) at the moment, and I've noticed that NFA is supposed to be a drop-in replacement for Session, but it isn't.  I'm hoping this will improve in P6
06:07 Tene wayland76: I've started work on a poe-alike in perl 6.
06:07 wayland76 Tene: Yeah, I'm backlogging, and that's why I mentioned it :)
06:08 Tene wayland76: I'd love some help on it, or even just feedback, once I get it more fleshed out.
06:08 wayland76 I suspect you're probably not doing NFA yet, but I thought I'd mention it in case you need to design Session to suit that somehow
06:08 Tene Thanks. :)
06:08 wayland76 Tene: I'd love to after I get a working Rakudo RPM, but I'm not doing any other P6 work until then :)
06:09 Tene wayland76: very important work... thank you for doing it.
06:09 wayland76 And I don't expect to get the time to work on that for at least another week
06:12 pugs_svn r26546 | masak++ | [u4x/TODO] added statement prefix 'lift'
06:12 pugs_svn r26546 | masak++ |
06:12 pugs_svn r26546 | masak++ | [u4x] removed line-ending spaces
06:12 pugs_svn r26546 | masak++ |
06:12 pugs_svn r26546 | masak++ | [u4x] s/data/documentation/
06:12 pugs_svn r26546 | masak++ |
06:12 pugs_svn r26546 | masak++ | The latter is more informative, IMHO. *Everything* in a computer is data.
06:12 wayland76 Tene: Am I right in presuming that you saw the recent S17/threads discussion and had at least some grasp of its relevance to your POE model?
06:13 wayland76 masak: I hadn't thought of that way of getting extra karma before :o)
06:13 Tene i didn't see it.
06:13 Tene perl6-language?
06:15 masak wayland76: sorry about that. it's the way git lays out commit comments. :/
06:15 wayland76 masak: Note clown face after last comment to show I was being silly :)
06:16 Tene wayland76: where was it?
06:16 masak wayland76: aye.
06:16 masak wayland76: I thought I would actually save y'all some noise by squashing three commits.
06:17 wayland joined #perl6
06:17 wayland Argh; server died again
06:18 Tene wayland: where was the S17 discussion?
06:18 wayland Tene, not p6l, but IRC backlog.  I'l find the link when my server comes back up (about 5 minutes unless it's too cold; then double that)
06:18 pugs_svn r26547 | azawawi++ | Upgraded dependencies of YAML::Syck to 1.07 and Moose to 0.76.
06:18 Tene ah
06:18 wayland No, I'll do it now.  Wait a few minutes
06:19 Tene no hurry
06:20 wayland Well, I can't do much else until the server comes back up
06:20 wayland It's my NFS server, and I'm planning on replacing it, but until then, I have to keep it warm
06:20 wayland I think the keyboard IO chip is faulty
06:21 alanhaggai_ joined #perl6
06:21 wayland http://irclog.perlgeek.de/​perl6/2009-04-28#i_1099607
06:22 wayland There and following for a while.  Threading talk continues until 12:39
06:23 wayland ...with a few final comments at 13:37
06:26 wayland (Tene -- actual effect on what you're doing may be minimal, but it'll give you some idea of what people are thinking)
06:28 sri_kraih joined #perl6
06:28 eternaleye_ wayland76: Hm, neither of them seemed to have visited the #haskell channel prior to making that paper, so I can't track them down that way. Best option for contact seems to be locating Steve Z, who seems to have been Peng Li's thesis advisor. He's faculty, and therefore has a upenn email address.
06:28 Matt-W jnthn++ - better type error messages helping me track down a problem in Form with much less hair loss
06:30 moritz_ rakudo: my Str $x; $x = 4;
06:30 p6eval rakudo c76d8d: OUTPUT«Type mismatch in assignment; expected something matching type Str() but got something of type Int()␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
06:30 wayland eternaleye_, he also has a Facebook
06:30 eternaleye_ That works.
06:30 masak jnthn: cool.
06:30 moritz_ wohoo
06:31 wayland I just googled Steve Zdancewic, and his Facebook was 3rd on the list
06:31 masak jnthn: I know it's specced to be "Str()" and "Int()", but does it have to be there? it feels redundant somehow...
06:31 masak jnthn: yes, I'm never satisfied :)
06:33 eternaleye_ wayland: Now we just need to get him and Peng Li hooked on Perl 6.
06:34 wayland eternaleye_: I don't think it's going to happen, but don't let me dissuade you from trying :)
06:35 wayland Btw, he seems to be supervising more than one student.
06:37 wayland Also, it seems like Tene is working on one facet of it, so I'm not as worried as I was; it may end up not needing to be specced at all (much like Form.pm)
06:37 moritz_ reddit++ # I put a non-working reddit widget on my blog (relative vs. absolute URL), and one of the reddit admins saw that and wrote me a mail about it
06:37 wayland That's kinda cool
06:37 wayland76 Yay, real keyboard again :)
06:39 agentzh joined #perl6
06:46 jhuni joined #perl6
06:47 iblechbot joined #perl6
06:47 Tene ... oops.  I was going to work on my PCT presentation tonight.
06:47 Tene Instead I spent the whole night on rakudo.
06:49 masak Tene, moritz: any insights into Match tree traversal?
06:49 moritz_ masak: yes
06:49 ejs joined #perl6
06:49 moritz_ thought not very good ones
06:50 moritz_ I'll get you two links, just a sec...
06:50 DemoFreak joined #perl6
06:51 moritz_ masak: here <http://nopaste.snit.ch/16420> I tried a different approach, and wrote down how it didn't work. pmichaud's answer: http://nopaste.snit.ch/16427
06:51 masak excellent, thanks.
06:53 * moritz_ slaps forehead
06:53 moritz_ I know what's wrong
06:53 masak even better. :)
06:53 moritz_ .chunks thinks that .from and .to are zero-based
06:53 moritz_ but of course they are based on self.from
06:54 masak ah.
06:54 moritz_ rakudo: '   foo' ~~ /.*?<ident>/; say $/<ident>.chunks.perl
06:54 p6eval rakudo c76d8d: OUTPUT«["~" => "foo"]␤»
06:55 moritz_ rakudo: '   foo' ~~ /.*?(.(.)+)/; say $0.chunks.perl
06:55 p6eval rakudo c76d8d: OUTPUT«["~" => " ", 0 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => " ",␤ text => " ",␤ from => 1,␤ to   => 2,␤), 1 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => " ",␤ text =>
06:55 p6eval .." "...
06:56 moritz_ rakudo: '   foo' ~~ /.*?f(.(.)+)/; say $0.chunks.perl
06:56 p6eval rakudo c76d8d: OUTPUT«["~" => "oo", 0 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "o",␤ text => "o",␤ from => 5,␤ to   => 6,␤)]␤»
06:56 moritz_ see, it produces two three 'o's altogether
06:56 ejs joined #perl6
06:56 moritz_ although all o's should add up to 2
06:57 masak I don't follow yet, but that's because I'm a bit disctracted right now.
06:57 moritz_ rakudo: '   foo' ~~ /.*?f(.(.))/; say $0.chunks.perl
06:57 p6eval rakudo c76d8d: OUTPUT«["~" => "oo", 0 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "o",␤ text => "o",␤ from => 5,␤ to   => 6,␤)]␤»
06:57 masak is it a bug? :)
06:57 moritz_ sure
06:57 * masak submits rakudobug
06:59 moritz_ title '.chunks doesn't work on submatchs' </humblesuggestion>
06:59 masak fine.
07:03 pugs_svn r26548 | moritz++ | [t/spec] tests .caps and .chunks on submatches
07:03 moritz_ tests are in t/spec/S05-capture/caps.t
07:05 moritz_ ... and a fix is currently being tested
07:05 moritz_ man, why does it take so long to compile the setting? </sigh>
07:07 masak moritz_: you keep giving all these closing tags... where do you open them? :P
07:08 Jedai joined #perl6
07:08 moritz_ masak: in a paralllel universe, of course
07:08 * masak should have seen that one coming
07:08 masak moritz_: I'd like to see an XML parser that handles that.
07:09 masak "Error: no corresponding opening tag, exhausted parallel universes."
07:09 moritz_ masak: give me a quantum computer and port Perl 6 to it, and I'll do that ;-)
07:10 masak quantum computing ♥ Perl 6.
07:10 masak (and yes, I've studied the former enough to know that's the case.)
07:11 moritz_ and yes, I've studied the later enough to know that's the case ;-)
07:11 masak if we can only keep the idea of junctions pure until we get commercial quantum computing...
07:11 japhb_ joined #perl6
07:12 masak "You did that in O(1) !? but... how?" "Well, this junctive construct sends things off to the QPU..."
07:12 moritz_ you know that you can do primality test with junctions?
07:12 masak aye.
07:13 masak talk about "disruptive tech" right there.
07:13 moritz_ for 2..6 -> $x { say ?(none(2..$x) * any(2..$x) == $x) }
07:13 moritz_ rakudo: for 2..6 -> $x { say ?(none(2..$x) * any(2..$x) == $x) }
07:13 p6eval rakudo c76d8d: OUTPUT«1␤1␤0␤1␤0␤»
07:14 masak nice.
07:14 moritz_ it's such a cool application of autothreading that I couldn't resist adding it to the test suite ;-)
07:14 masak :P
07:15 masak relatedly, this article is sometimes a source of inspiration for me: https://c2.com/cgi/wiki?PimcPiflPire
07:16 moritz_ afk
07:21 zostay joined #perl6
07:28 moritz_ rakudo: '   foo' ~~ /.*?f(.(.))/; say $0.chunks.perl
07:28 p6eval rakudo c76d8d: OUTPUT«["~" => "oo", 0 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "o",␤ text => "o",␤ from => 5,␤ to   => 6,␤)]␤»
07:29 moritz_ not updated yet
07:31 * masak realizes that lazy lists make pimc pifl pire less necessary, if not less impossible
07:32 masak um, scratch that. I just saw the Fermat example.
07:32 masak man.
07:36 moritz_ rakudo: '   foo' ~~ /.*?f(.(.))/; say $0.chunks.perl
07:36 p6eval rakudo 654500: OUTPUT«["~" => "o", 0 => Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "o",␤ text => "o",␤ from => 5,␤ to   => 6,␤)]␤»
07:38 azawawi joined #perl6
07:38 azawawi hello
07:39 szabgab olleh
07:39 masak ehllo
07:39 moritz_ rakudo: say 'hello'.split('').pick(*)
07:39 p6eval rakudo 654500: OUTPUT«llohe␤»
07:39 masak :)
07:44 wayland76 Nice.  I didn't know * could be used that way :)
07:44 masak it can be used in whatever way you like. :)
07:45 wayland76 rakudo: pony(*)
07:45 p6eval rakudo 654500: OUTPUT«Could not find non-existent sub pony␤current instr.: '_block14' pc 66 (EVAL_16:44)␤»
07:45 wayland76 Hmm.  Lets try something simpler
07:45 wayland76 rakudo: money(*)
07:45 p6eval rakudo 654500: OUTPUT«Could not find non-existent sub money␤current instr.: '_block14' pc 66 (EVAL_16:44)␤»
07:45 wayland76 I guess not :)
07:47 wayland76 rakudo: class Christmas { * }
07:47 p6eval rakudo 654500:  ( no output )
07:47 wayland76 Oh, wait, I see...
07:47 masak when Perl 6 is out, Christmas will be whatever.
07:48 wayland76 rakudo: use Wishful_Thinking; class Christmas { * }
07:48 p6eval rakudo 654500: OUTPUT«Can't find ./Wishful_Thinking in @INC␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
07:48 masak Rakudo doesn't work on wishful thinking. :)
07:49 wayland76 Well, it was worth a go :)
07:49 wayland76 rakudo: use things_Even_if_theyre_written
07:49 p6eval rakudo 654500: OUTPUT«Can't find ./things_Even_if_theyre_written in @INC␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
07:50 wayland76 There we go.  Successful error message golf, anyway :)
07:51 broquaint joined #perl6
07:52 moritz_ masak: http://nopaste.snit.ch/16441 there you go.
07:52 masak moritz_++
07:53 * masak tries locally
07:53 moritz_ masak: needs the newest rakudo
07:54 masak ah, Match.pm changed. thanks.
07:54 masak living on the edge.
07:55 wayland76 Cool.  Where's the action class idea specced?
07:56 moritz_ yes, I've closed the .chunks ticket
07:56 moritz_ wayland76: I don't think it's really specced yet... one of my TODO items
07:56 moritz_ wayland76: but it's used extensively in PCT based compilers
07:56 Matt-W Morning
07:56 wayland76 Oh, ok
07:56 wayland76 Is there a reason it's separate from the grammar?
07:57 wayland76 o/
07:57 Matt-W So you can have another set of actions for the same grammar, I would have thought
07:58 moritz_ yes
07:58 moritz_ or none at all
07:58 wayland76 Ah, of course
07:59 moritz_ speaking of which, my JSON grammar now produces the corret data structure for '{ "a" =>  1}'
07:59 wayland76 I was wondering if there was some way of integrating Form.pm with grammars, so that you could create an AST tree, and then output from it something semantically equivalent to the original
07:59 wayland76 And it looks like this will be how :)
07:59 moritz_ string escapes aren't done yet, so "a\t' won't work
08:00 moritz_ and it needs many more tests
08:00 moritz_ but since pmichaud++ fixed a segfault that was blocking me, it's very, very nice hacking
08:00 wayland76 I think this also means that I'll need less monkey patching to make Tree work :)
08:05 wayland76 Btw, can we do aspect-oriented programming?
08:06 moritz_ is there any paradigm we can't? :-)
08:06 moritz_ (except purity, perhaps)
08:07 wayland76 Well, I know we can, but is there a better way to do it than what you did in your class there? :)
08:07 wayland76 By "Better", I mean, more automatic, less code involved
08:07 moritz_ hey
08:07 moritz_ you could try
08:08 moritz_ you could try to use 'handles' to do it
08:09 wayland76 Oh, yeah, that would be cool, I think.
08:09 wayland76 (Well, I know it would, if it works like we want it to :) )
08:09 moritz_ class A { method h($/, @*params) { code from $h here } }; class Actions { has A $h TOP => 'h', FOO => 'h', ...;}
08:11 wayland76 Does this still work?  class A { method h($/, @*params) { code from $h here } }; class Actions { has A $h handles *; }
08:11 wayland76 ...and then just override the ones you want to?
08:11 masak rakudo: if 1 {} elsif 2 {}
08:11 p6eval rakudo 654500:  ( no output )
08:11 masak rakudo: if 1 {} elseif 2 {}
08:12 p6eval rakudo 654500: OUTPUT«Statement not terminated properly at line 1, near "elseif 2 {"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
08:12 * masak submits a rakudobug about a nicer error message for that one
08:12 wayland76 if 1 {} else if 2 {}
08:13 wayland76 rakudo: if 1 {} else if 2 {}
08:13 p6eval rakudo 654500: OUTPUT«Statement not terminated properly at line 1, near "else if 2 "␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
08:13 Matt-W wayland76: please explain 'integrate Form.pm with grammars'
08:13 masak yes, let's include that one too.
08:14 wayland76 Well, that's the thing -- I wanted to figure out some way to glue them together ("integrate" was probably poorly chosen), but I hadn't got further than thinking about it before I was sidetracked :)
08:15 Matt-W I'm not sure what you'd be wanting to achieve
08:15 wayland76 Have a look at Moritz' nopaste from a few lines before I made that statement (if you haven't already) --
08:16 wayland76 Matt-W: Neither am I, but it sounds like the sort of thing that some instinct tells me will be useful.
08:16 wayland76 Ah, I know
08:16 moritz_ wayland76: you mean in terms of implementation? or exposing a grammar based API?
08:16 wayland76 XML to JSON converter
08:17 pugs_svn r26549 | szabgab++ | smartlink updates
08:17 wayland76 Have a grammar for each, and an action class for each.  Then parse a document of each, and output the AST via the action class (which uses Form.pm); presto -- auto conversion
08:18 wayland76 Well, I'm assuming here that an action class can be applied to an AST, rather than passed to parse(), but it'd work either way
08:18 Matt-W Hmm
08:18 Matt-W Form's use case is quite different
08:18 Matt-W What you need is some sort of generic framework for converting ASTs into string representations of themselves
08:18 wayland76 Yeah, I know.  Maybe I should suggest FormAlike.pm :)
08:18 Matt-W backwards actions
08:19 wayland76 Yes, yes, exactly
08:19 Matt-W Form could provide some of the mechanism, but you're better off looking at some sort of layout combinator library
08:19 Matt-W There's a good one in Haskell
08:19 wayland76 But we already have printf, pack, and Form.pm doing the same thing for different specialised domains
08:19 wayland76 So maybe something general that does all 3 of those, plus the tree outputting thing
08:20 wayland76 ok, do I google "layout combinator"?
08:20 Matt-W I'll find it
08:20 Matt-W We may need to see if we can unify this stuff
08:20 Matt-W But it might nto be possible without breaking the simple stuff
08:21 wayland76 Well, I should warn you, I'm not planning on working on it within the next month, so there's no pressure from my direction.
08:22 Matt-W good
08:22 Matt-W I want to make Form work as specced first :)
08:22 masak wayland76: I've heard jnthn talking about something along the lines of a backwards Perl 6 grammar. you might want to discuss with him too.
08:22 Matt-W http://haskell.org/ghc/docs/latest/html/libr​aries/pretty/Text-PrettyPrint-HughesPJ.html <- that's the API reference, with a link to a paper about it
08:23 wayland76 ok, thanks.  jnthn may well get to it before I do :)
08:25 masak rakudo: class A { sub bar() { return 42 }; method foo() { say bar; say eval("bar") } }; A.new.foo
08:25 p6eval rakudo 654500: OUTPUT«42␤␤»
08:26 azawawi moritz_: regarding http://nopaste.snit.ch/16441 ; std seems to complain about it.
08:26 masak is this kosher behaviour? or is it a known bug? or did I just discover something?
08:27 moritz_ azawawi: what does it complain about?
08:27 wayland76 masak: What did you expect it to do?
08:27 moritz_ masak: I think it should print 42 again
08:27 azawawi moritz_: make [~] gather { ... }
08:27 masak moritz_: do you know if it's reported?
08:27 moritz_ masak: don't think so
08:27 moritz_ azawawi: so what's wrong with that?
08:27 * masak submits rakudobug, just in case
08:27 wayland76 rakudo: class A { sub bar() { return 42 }; sub otherbar() { return 43 }; method foo() { say bar; say eval("otherbar") } }; A.new.foo
08:27 p6eval rakudo 654500: OUTPUT«42␤␤»
08:28 azawawi moritz_: let me check it again via tryfile...
08:28 wayland76 rakudo: class A { sub bar() { return 42 }; sub otherbar() { return 43 }; method foo() { say bar; say eval("say otherbar") } }; A.new.foo
08:28 p6eval rakudo 654500: OUTPUT«42␤␤»
08:28 masak rakudo: sub bar() { return 12 }; class A { sub bar() { return 42 }; method foo() { say bar; say eval("bar") } }; A.new.foo
08:28 p6eval rakudo 654500: OUTPUT«42␤12␤»
08:29 moritz_ rakudo: class A { sub bar() { return 42 }; method foo() { say bar; say eval("bar"); say "error: $!" } }; A.new.foo
08:29 masak for some reason the eval resets to the outer namespace.
08:29 p6eval rakudo 654500: OUTPUT«42␤␤error: Could not find non-existent sub bar␤»
08:29 wayland76 Good idea :)
08:29 wayland76 rakudo: class A { sub bar() { return 42 }; sub otherbar() { return 43 }; method foo() { say bar; say eval("A::otherbar") } }; A.new.foo
08:29 p6eval rakudo 654500: OUTPUT«42␤43␤»
08:31 moritz_ ok, eval doesn't pick up outer namespaces
08:33 pasteling "azawawi" at 212.38.130.254 pasted "std complaints..." (13 lines, 304B) at http://sial.org/pbot/36268
08:34 azawawi moritz_: same thing; std does not parse it...
08:34 moritz_ azawawi: well, I don't bother for now
08:36 azawawi moritz_: so is it an STD parsing bug?
08:37 moritz_ azawawi: I don't know
08:37 moritz_ as I said, I don't bother for now
08:37 azawawi moritz_: thx :)
08:37 moritz_ masak wants a working example, I gave him one :-)
08:38 masak azawawi: I don't see anything syntactically wrong with 'make [~] gather { ... }'
08:38 masak azawawi: if STD.pm has problems with that, it can talk to me about it.
08:38 azawawi masak: all i wanted is to see it in Padre Perl6 outline view :)
08:39 masak azawawi: I'm sure you'll be able to make the appropriate changes locally.
08:39 azawawi masak: im checking if it is a whitespace problem...
08:40 pugs_svn r26550 | szabgab++ | improved liniking from X<> tags
08:40 azawawi masak: yup, whitespace bug!
08:42 hanekomu joined #perl6
08:42 masak azawawi: good catch.
08:42 masak azawawi: is the problem with STD.pm or Rakudo, would you say?
08:43 azawawi masak: i think std...
08:44 azawawi masak: for $/.chunks{ needs 2 spaces after chunks to work...
08:45 pugs_svn r26551 | szabgab++ | adding smartlinks and X<> tags
08:45 masak sounds very much like a bug.
08:46 azawawi masak: needs one space to be exact...
08:50 masak moritz_: ok. I went with your latest paste, and made it react correctly on 'pe:if' attributes. http://gist.github.com/103668
08:51 masak moritz_: two things: (1) I'd like to reproduce the <ol> tag but with the 'pe:if' attribute removed. how do I do that?
08:51 azawawi TimToady: STD needs a space after $/.chunks (line 32) to parse http://nopaste.snit.ch/16441
08:54 moritz_ masak: you could try to extend $h to accept an optional $exclude parameter, and then prefix the take() with 'unless $exclude && $exclude eq .key' or so...
08:54 masak moritz_: (2) at this point, actions again feel wrong, being bottom-up, whereas a template works top-down. I think your idea was to put some special objects in the match tree, representing if and for directives. did I get that right? these could then be iterated upon. but then I again have the problem of traversing a Match tree, something which I haven't succeeded in doing yet.
08:54 masak moritz_: interesting idea. will try.
08:55 moritz_ masak: well, if you want to do it top down, you can always make() lists of chunks, not strings...
08:55 masak moritz_: this is the part I still feel very uncertain about.
08:55 moritz_ masak: and then you traverse $/.ast, which is just a tree made of lists
08:56 moritz_ not a match tree
08:56 masak ok.
08:56 moritz_ the problem with buttom is that you run into trouble with things like if $variable { $do_soemthing_with_variable }
08:57 masak yes.
08:57 masak that's my point.
08:57 moritz_ if it's done buttom up, and immediately cast into strings, you don't have $variable available
08:57 moritz_ s/buttom/bottom-up/
08:57 masak well,
08:58 masak variables are another of those things that should be cast into special objects in the match tree.
08:58 moritz_ so remove the [~]
08:58 moritz_ in $h
08:58 moritz_ and you're mostly done
08:58 masak so we have: if and for directives, and variables.
08:58 * masak is re-inventing PAST
08:59 moritz_ indeed :-)
09:00 masak I picture Hitomi, the real one, eventually being built on top of PAST somehow.
09:00 masak with custom PAST Node types. pmichaud++ for the idea.
09:01 moritz_ masak: well, PAST is not Perl 6, it's PCT
09:01 moritz_ masak: you're on your best way to tying Web.pm to Rakudo
09:01 masak moritz_: well, perhaps.
09:02 masak moritz_: that doesn't bother me very much.
09:02 * moritz_ doesn't like that
09:02 masak moritz_: let's aim for making Hitomi two-modal then.
09:02 moritz_ masak: it bothers me, because pugs showed us that implementations can die, even if they seem very lively while you code from them
09:02 masak moritz_: one mode that does things slowly, in pure Perl 6.
09:02 moritz_ s/from/for/
09:03 masak moritz_: one mode that precompiles down into fast PIR.
09:03 masak I think we'll want something like that anyway.
09:04 masak moritz_: what worries me is speed. here I am trying to replace a working templating system (HTML::Template) with one that does advanced tricks with XML, and essentially trades speed for purity.
09:04 moritz_ ok
09:05 masak moritz_: if I could get a purity boost _and_ a speed boost, that'd be awesome.
09:06 masak when it comes down to it, a template is just a bunch of loops, conditionals and variable accesses. that can be compiled down directly to PIR, and many of the checks and casts and stuff done in Rakudo can be thrown away.
09:06 masak => fast
09:25 agentzh joined #perl6
09:30 masak moritz_: so, Hitomi will be a two-implementation project. making both implementations pass the same test suite will hopefully keep them from drifting away from each other.
09:31 moritz_ masak: same as with Perl 6 :-)
09:31 masak aye, a nice bit of symmetry there. :)
09:31 moritz_ fractals :-)
09:31 masak November is also dual-impl, but it doesn't do the test suite thing.
09:32 moritz_ the combinations explode exponentially :-)
09:33 masak no wonder performance goes south. :P
09:53 wayland "bimodal" is the word you want :)
09:54 arnsholt std: <a b c>>>.uc;
09:54 p6eval std 26551: OUTPUT«ok 00:05 42m␤»
09:54 wayland rakudo: <abc>>>.uc
09:54 p6eval rakudo 654500: OUTPUT«Statement not terminated properly at line 1, near ">>.uc"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
09:54 wayland oops :)
09:54 wayland rakudo: <a b c>>>.uc;
09:54 p6eval rakudo 654500: OUTPUT«Statement not terminated properly at line 1, near ">>.uc;"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
09:54 arnsholt I tested it in rakudo first (doesn't work)
09:55 amoc joined #perl6
09:55 arnsholt But it's a fun construct. Replaces some tedious map expressions
09:55 riffraff joined #perl6
09:55 wayland Great :)
09:56 wayland I think it's going to take me months to stop thinking like a P5 programmer :)
09:57 arnsholt Months? Years!
09:57 wayland Calvin (&Hobbes) once suggested that life should have a cover charge, to keep the riffraff out :)  But we don't want that here
09:57 wayland arnsholt: agreed :)
09:58 wayland (for those who missed it, riffraff just joined the channel)
09:58 arnsholt Calvin and Hobbes are fun. I especially like that they're named after philosophers
09:59 wayland I have the 3-volume boxed set.  That has almost everything except the fun comments in the 10th anniversary edition
09:59 arnsholt Cool
10:00 wayland For some reason, Larry Wall reminds me of Bill Watterson
10:00 jnthn ahojte
10:00 wayland hail jnthn!
10:00 wayland I presume that's slovak for "Ahoy"?
10:01 arnsholt Argh. For some reason I can't get rakudo to call my ancestor's implementation of an overloaded method
10:02 wayland Most of my ancestors were born before computers :).  My classes' ancestors, OTOH...
10:03 jnthn wayland: It's "hi", but to many people.
10:03 wayland arnsholt: What does it do, error, or fail silently...?
10:03 jnthn wayland: If it's just to one person it'd be just "ahoj" :-)
10:03 wayland Right
10:04 wayland But would it be more formality-suitable, as in "hello"?
10:04 jnthn No, ahoj[te]? is informal.
10:04 wayland ok
10:04 jnthn More formal is like "dobry den"
10:05 wayland den = day?
10:05 jnthn yes, dobry = good
10:05 wayland ok
10:06 mberends similar to Croatian 'dobor dan' :)
10:06 jnthn mberends: Yes.
10:06 wayland Doesn't one of the Germanic languages also have den=day?
10:06 hanekomu in vienna, some younger people use a kind of slang: "das ist dobre" to mean "this is good"
10:07 mberends NL=dag, DE=tag
10:07 hanekomu but not widely used; maybe not widely understood
10:07 wayland mberends, guess I'm wrong then, unless it's Scandinavian, which I doubt
10:09 wayland hanekomu: is that 2 German words and one Slovak?  (I'm monolingual English here, so I know nothing; sorry :) )
10:10 jnthn wayland: yes
10:10 wayland76 ok.  Well, maybe I know something then.  But not much :)
10:10 jnthn das ist = that is (or similar, my German ist nicht dobre ;-))
10:10 Matt-W precisely that, actually :)
10:11 mberends hanekomu: the 'dobre' might also have slipped in from Slovenia
10:11 Matt-W my German's pretty awful, but I remember the basics
10:11 hanekomu wayland: yes, "das ist" = "that is", dobre comes from Slovenia or Slovakia
10:12 wayland76 The closest I get is a dobro en.wikipedia.org/wiki/Dobro :)
10:12 wayland76 "Das ist dobre" has a certain alliteration to it :)
10:12 hanekomu actually, come to think of it, i personally have only heard it said in this office, where the programmers have a rather earthy humour :)
10:13 jnthn These things have to start somewhere... ;-)
10:15 mberends Slovenian slang for "excellent" borrows English to make "full dobor" :)
10:15 mberends they sound quite funny saying it
10:15 arnsholt wayland: Depends on how I do it. callwith, callsame, nextsame and nextwith all fail (looks like rakudo doesn't implement that yet)
10:17 jnthn arnsholt: No, not yet. May, all being well. :-)
10:17 arnsholt Saying Grammar.parse(@_, |%_) fails because that makes the invocant in Grammar.parse the Grammar protoobject, not my class
10:18 arnsholt I've tried some variations on self.$stuff, but none of them seem to work either
10:18 wayland76 Is there a way arnsholt can call his ancestor method?
10:18 jnthn grammar Foo { ... }; Foo.parse(...) ?
10:18 jnthn wayland: From where? Within a subclass?
10:19 jnthn You can do tricks with the meta-class.
10:19 wayland76 jnthn: I think that's what he wants -- hopefully he'll address the question
10:20 jnthn rakudo: class A { method x { say 1 } }; class B is A { method x { say 2 } }; my $x = B.new; $x.x; A.^dispatch($x, "x");
10:20 p6eval rakudo 654500: OUTPUT«2␤Could not locate a method 'B()<0xb6a06fc0>' to invoke on class 'A'.␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
10:20 arnsholt I've got a grammar, and I'd like its parse() to set the action class automatically before handing control over to the real parse() in Grammar
10:21 jnthn rakudo: class A { method x { say 1 } }; class B is A { method x { say 2 } }; my $x = B.new; $x.x; A.^dispatch("x", $x);
10:21 p6eval rakudo 654500: OUTPUT«2␤too many arguments passed (3) - 1 params expected␤current instr.: 'parrot;A;x' pc 171 (EVAL_24:73)␤»
10:21 jnthn gah, I should actually go look at the signature...
10:22 Matt-W Calling your parent class' version of the method you're in the middle of overriding should be fairly simple, shouldn't it?
10:22 jnthn Matt-W: Sure, when we get the things in place to do that.
10:22 wayland76 Matt-W: yes, but not implemented, if I understand correctly
10:22 Matt-W Ahah
10:23 jnthn rakudo: class A { method x { say 1 } }; class B is A { method x { say 2 } }; my $x = B.new; $x.x; A.HOW.dispatch($x, "x");
10:23 p6eval rakudo 654500: OUTPUT«2␤1␤»
10:23 jnthn That one.
10:23 * jnthn needs coffee
10:32 Matt-W So that says get me A's metaclass, and tell it to find method x and call that with $x as the invocant
10:32 Matt-W ?
10:33 jnthn Matt-W: Yes.
10:33 Matt-W And so of course it finds A's x, because it only knows about that
10:33 jnthn Right.
10:33 Matt-W Looking forward to the proper syntax for that :)
10:34 Matt-W And I love the new type mismatch errors
10:34 jnthn Implementing it is in my next Hague Grant application...
10:34 jnthn http://news.perlfoundation.org/2009/0​4/hague_perl_6_grant_request_tra.html for anyone interested in commenting, btw
10:34 Matt-W I haven't fixed it yet, but it gave me a much better idea of a bug in Form once it started complaining about Ints and Strs
10:35 jnthn Great. masak++ for asking for them
10:37 Matt-W That looks like a great grant
10:37 Matt-W Serious improvements to Rakudo
10:37 Matt-W I always get a good feeling about people wanting to pull hacks out of things and implement it properly
10:41 cognominal joined #perl6
10:41 arnsholt Hmm. Calling Grammar.HOW.dispatch(self, "parse") in my grammar's parse() gets me a deep recursion error
10:44 jnthn :-S
10:44 jnthn arnsholt: Reduce and file rakudobug, if you can.
10:46 arnsholt I'll try to remember that this evening. Unfortunately I have some schoolwork that desperately needs my attention =)
10:46 wayland76 Sacrelige!  Rakudo takes precedence over everything!  :)
10:47 wayland76 (which is why I'm currently writing P5 code unrelated to P6)
10:48 arnsholt Heh
10:50 * jnthn is doing $other_day_job and just encountered a 400+ line stored procedure.
10:50 wayland76 SQL?
10:50 jnthn Yes.
10:52 wayland76 Sounds like it needs plperl :)
10:54 jnthn MS SQL server. ;-)
10:55 Matt-W Ouch
10:55 * Matt-W is writing up horrible forms requesting permission to use open source software we've been using for years, because some lawyer's decided we need to.
10:56 jnthn MS SQL Server ain't so bad IMO.
10:56 jnthn Granted I didn't play with many DBMS, but after MySQL it's an improvement.
10:57 Matt-W It's certainly more capable
10:57 baest jnthn: well, almost anything is nice after MySQL :) PostgreSQL is really nice
10:57 Matt-W The only thing that stops people writing 400+ line stored procedures in MySQL is it not supporting them
10:57 SamB Matt-W: are they brain-dead ?
10:57 SamB the lawyers, I mean
10:57 Matt-W SamB: I think they're trained in the Microsoft Way
10:58 SamB the permission is already there
10:58 SamB you should have insisted that they read it
10:58 Matt-W Also they don't understand how these things work
10:58 wayland__ joined #perl6
10:58 Matt-W And some of them think all open source is GPL
10:59 Matt-W One day I'll work for a more enlightened company...
10:59 SamB still, you shouldn't let them bully you like that!
10:59 Matt-W Oh for now I just waste my time doing that
10:59 Matt-W And use it as an excuse when they demand to know why bugs aren't being fixed
10:59 Matt-W Let my management turn up the heat on theirs
10:59 Matt-W Although my management tend to just say 'oh yes we need to do that'
10:59 SamB :-(
11:00 Matt-W On the bright side... it's lunchtime!
11:00 SamB no, breakfast!
11:00 wayland76 9pm here :)
11:00 SamB 7am here
11:04 payload joined #perl6
11:12 Whiteknight joined #perl6
11:14 iblechbot joined #perl6
11:17 wayland joined #perl6
11:43 ruoso joined #perl6
11:47 ruoso Hello!
11:47 moritz_ hi there
11:53 wayland o/ hi and goodnight
12:07 sri_kraih joined #perl6
12:22 abra joined #perl6
12:32 amoc joined #perl6
12:47 synthetic joined #perl6
12:48 synthetic left #perl6
12:49 synthetic joined #perl6
12:53 alanhaggai joined #perl6
12:53 smtms joined #perl6
12:56 PhatEddy joined #perl6
13:01 pmichaud Good morning #perl6
13:02 moritz_ good day
13:03 PhatEddy TimToady: if you are still interested and are around we have all parties needed to discuss where to put those ticket tests ...
13:04 PerlJam good morning pmichaud
13:04 pmichaud it's still a little early in TimToady.tz
13:06 jnthn morning pmichaud
13:06 Matt-W hi pmichaud
13:08 TimToady well, except my current tz is somewhere rather east of here.  :)
13:08 TimToady effective tz, not actual tz
13:09 PerlJam you live in the land of the rising sun if only in your mind?
13:09 PhatEddy good morning everyone
13:10 Matt-W Time zone, apparently, is just a state of mind
13:10 TimToady compared to my usual schedule, I running about EDT at the moment
13:10 TimToady went to bed at 9:00 last night, usually 12:00
13:11 synthetic Good morning everybody
13:13 synthetic I've been checking out rakudo lately and am impressed by it's feature completeness, but wondering why it's so slow. Is this due to parrot or is it just rakudo itself being pretty unoptimized currently? Hope some of the internals hackers could share some thoughts on that
13:13 pmichaud synthetic: it's a combination of things
13:13 pmichaud synthetic: parsing is still on the slow side, we know how to fix that
13:14 moritz_ basically rakudo contains no optimizations
13:14 moritz_ except multi dispatch caching
13:14 pmichaud synthetic: execution speed is slow on the Parrot side -- some things which used to be fast were slowed down quite a bit with recent changes to Parrot, and I'm not sure when that will take place
13:15 pmichaud but overall we've been focusing on feature completeness more than execution speed (more)
13:15 pmichaud that's likely important, because as we add more features we often discover that any optimizations we might have spent time implementing would be invalidated by a later feature revision
13:15 synthetic so you're still confident that perl6 is gonna be one of the faster "agile" languages out there? Because this was one of the original goals of the implementation if got that correctly
13:15 pmichaud I'm confident that we can make it much faster than it is today, yes.
13:16 synthetic hehe
13:16 pmichaud "one of the faster 'agile' languages" will depend on how someone wants to measure speed
13:16 synthetic I believe in you
13:16 TimToady we've been planning for speed in providing the needed information to the optimizer, but nobody's written the optimizer yet. :)
13:16 moritz_ I'm pretty sure that we'll never beat Perl 5 in terms of compilation speed
13:17 pmichaud otoh, we have more opportunities for pre-compilation :-)
13:17 Matt-W I can live with that if we can run fast
13:17 TimToady probably not, but p5's compiler is mad
13:17 PerlJam perl6 will do things that are nigh impossible in other languages.  For these things, that it can do them at all is amazing, so speed doesn't so much matter.  :)
13:17 TimToady we plan to be disruptive in many ways, so there are some things that will take a hit
13:17 TimToady and one of them is short-term performance
13:17 moritz_ Matt-W has a point - rakudo can precompile modules today, which perl5 can't
13:18 synthetic absolutely, perl6 is going to be one of if not THE most beautiful and compact languages of all time imho
13:18 PerlJam moritz_: sure it can!
13:18 Matt-W Form's tests run massively faster if I precompile Test.pm
13:18 Matt-W and all the Form modules
13:18 moritz_ PerlJam: how?
13:18 PerlJam moritz_: sure ... make me figure out how to do it again ...  :-)
13:19 moritz_ PerlJam: afaict there was a mechanism to dump and reload bytecode, but it was slower than compiling again
13:19 * moritz_ is most interested to find out about it
13:19 synthetic does static typing help in going for performance? I'm wondering beacuse as I understand it type-checking is done completely at runtime!? Or can the JIT use that information in a good way?
13:19 jnthn fwiw, part of the dispatch work I'm planning for May should win us some speedups.
13:20 PerlJam I haven't tried it in about 8 or so years.   I tried compiling several .pm to .pmc to see if it was an improvement.  I'm pretty sure it wasn't or I would have remembered how to do it.
13:20 jnthn synthetic: I expect that we'll be able to use the type information do eliminate a bunch of runtime checks, once we have an optimizer.
13:20 jnthn As well as give more compile time errors about stuff that will innevitably fail at runtime.
13:21 skids joined #perl6
13:22 PerlJam moritz_: in any case ... I can precompile modules  ... with PAR  ;-)
13:22 pmichaud jnthn: oooh,  Tene's patch in r38395 looks really good to me.  Tene++
13:22 moritz_ PerlJam: which makes startup even slower :)
13:23 pugs_svn r26552 | szabgab++ | create index of both X<> and C<> tags in the synopsis
13:23 DemoFreak joined #perl6
13:24 PhatEddy TimToady emailed some concerns yesterday evening about including RT ticket tests in the spec hierarchy ...
13:24 jnthn pmichaud: Nice :-)
13:24 jnthn pmichaud: So does .HLL work now? ;-)
13:24 pmichaud jnthn: from scrollback it appears that Tene got it mostly working, yes.
13:25 pmichaud PhatEddy: url or message id?
13:25 pugs_svn r26553 | ruoso++ | [re-smop] start of p6opaque... missing the DESTROYALL part...
13:25 TimToady well, I just noticed first that some Q:PIR had snuck into the t/spec, and of course STD doesn't like that
13:25 pmichaud I totally agree, Q:PIR doesn't belong in spec.
13:25 TimToady but there are also t/spec/ticket files
13:26 TimToady where ticket seems to be RT specific
13:26 TimToady if it's considered a temporary I don't know where to put this in the spec directory
13:26 PhatEddy all of the things you mention are scheduled for removal as of now ...
13:26 TimToady that's okay, but we already have an unclassified dir, I think
13:26 pmichaud I think there's an unclassified dir in t/ -- not sure about t/spec/
13:27 pmichaud I hadn't noticed t/spec/ticket/
13:27 pmichaud looking
13:27 PhatEddy the things in the spec/ticket directory have now been integrated into the actual spec tests ...
13:27 TimToady yeah, it's t/xx-unclassified
13:27 PhatEddy is that integration a problem?
13:27 TimToady *uncategoriezed
13:27 * moritz_ prefers integration
13:27 TimToady bleah
13:27 TimToady need coffee
13:28 synthetic Would it make sense to have something like a NativeInt type, in addition to the regular Int? Where you would say: "I don't want any overflow checking and the kind of safeties that make Numbers slowish in interpreted languages normally! I know what I'm doing, just make it fast!"
13:28 moritz_ we already have too many test files
13:28 pmichaud synthetic:  "int"
13:28 moritz_ synthetic: we have, it's called 'int'
13:28 pmichaud synthetic: my int $a = 3;
13:28 synthetic 'int' as opsed to 'Int'?
13:28 pmichaud synthetic: yes.  Also "num", "bool", etc.
13:28 synthetic ah nice
13:28 PerlJam synthetic: aye, lowercase types are "native"
13:29 synthetic getting more exited about perl6 every day ;)
13:30 synthetic read an article in he german CT last month, from moritz. Seems like it'S slowly getting real ;)
13:30 Matt-W Oh it is
13:30 Matt-W Sometimes I forget most people don't know it
13:30 PerlJam I think it's fairly real already.
13:31 PerlJam Real enough for a web server for instance.  :)
13:31 abra joined #perl6
13:31 pmichaud No, it's vaporware.  I'm pretty sure I've read that somewhere.
13:31 PerlJam pmichaud: don't believe everything you read on wikipedia
13:31 synthetic hehe, I have, but didn't believe for a second ;)
13:32 synthetic good things take time
13:32 pmichaud PerlJam: oh, it wasn't on wikipedia.  I think it was in the San Diego Union-Tribune
13:32 pmichaud and use.perl, and digg, and slashdot :-)
13:32 pmichaud oh, and reddit.
13:32 Matt-W There was an amazing discussion on LinkedIn about it
13:32 Matt-W In which someone claimed Perl 6 has abandoned being Perl
13:32 TimToady PhatEddy: to me, 'integration' means testing holistically, which doesn't really mean 'miscellaneous' or 'unclassified'
13:33 pmichaud ah, I must have missed the LinkedIn discussion.
13:33 Matt-W because it's not based on regular expressions anymore
13:33 PerlJam Matt-W: what does that even mean?
13:33 PerlJam perl 5 isn't "based on regular expressions" either :)
13:33 pmichaud that means someone hasn't been looking very closely at Perl 6.
13:33 PhatEddy TimToady: unfortunately I don't understand the matter at that level of sophistication
13:33 pmichaud Given that its parser is heavily based on regular expressions far more than anything else :-)
13:34 moritz_ synthetic: actually there are two more Perl 6 articles to come (both in iX)
13:34 PhatEddy TimToady: I just meant that all the tests are now in existing spec test files
13:34 Matt-W PerlJam: The best I could comprehend, he thought Perl 5 was based on regexps like Haskell is based on the lambda calculus
13:34 PhatEddy TimToady: and the spec/ticket files can all be removed without loss of tests
13:34 literal Matt-W: odd, one might argue that Perl 6 is more based on regular expressions (at least as Perl 6 understands them)
13:34 Matt-W PerlJam: Which, I know, makes no sense at all
13:35 literal what with the Perl 6 grammar and all
13:35 Matt-W Mmm
13:35 synthetic moritz_: we get them on the job so I'll definitely not miss them
13:35 Matt-W I explained what was really going on
13:35 moritz_ PhatEddy: then remove them
13:35 Matt-W I'm not sure it was worth the effort, but now maybe at least one more person knows what's being done here
13:35 PerlJam literal: so ... perl 5 is like perl6's illiterate younger brother?  :)
13:35 literal something like that
13:36 skids pmichaud: what's the disposition of inplace string ops in Parrot?  I see various meanderings about getting rid of them.
13:36 literal I think TimToady usually refers to Perl as female, though :)
13:36 TimToady moritz: but if the tickets are things that need to go into the spec somewhere...
13:36 PerlJam literal: like timezone, gender is a state of mind  :)
13:37 pugs_svn r26554 | szabgab++ | add some X<> tags
13:38 TimToady I can see a use for a holding area in t/spec that is not rt specific
13:38 eric256 joined #perl6
13:38 TimToady then people who don't have rakudo access can work on moving the tests
13:38 moritz_ TimToady: they are in the spec tests already
13:38 TimToady course, if rakudo wants to keep the rt tests around anyway
13:39 TimToady ah, okay
13:39 TimToady just part of spec that rakudo turns off?
13:39 moritz_ probably fudged
13:39 TimToady gotcha
13:39 TimToady in that case, yes, they don't need to be there
13:40 TimToady ah, missed what PhatEddy said above, sorry for the confusion
13:40 moritz_ I keep t/spec/integration around for things that I can't figure out where to put them
13:41 moritz_ or things that aren't specced, but are common sense
13:41 TimToady I read that as "testing the integration", not as things needing to be integrated
13:41 moritz_ well, for example it tests the integration between 'if' and modules
13:42 moritz_ the spec doesn't say "an 'if' statement also works in modules", but we test for it nonetheless
13:42 TimToady I will at least admit that "integration" sounds classier than "miscellaneous" :P
13:42 moritz_ [particle]++ for the name
13:42 PhatEddy Just quickly - there is no place for the PIR test to go for the moment afaik - so in that one case I just plan to tack it on to the ticket - OK?
13:42 TimToady but if it means that, I'm okay with it
13:42 moritz_ PhatEddy: OK
13:43 TimToady backlogging, so don't say anything interesting :)
13:46 pugs_svn r26555 | ron++ | removing ticket/ directory.  tests now part of regular spec tests
13:49 TimToady @tell masak I just need to implement the warning on class redefinition with a tuit of some sort
13:49 lambdabot Consider it noted.
13:50 pmichaud PhatEddy: PIR tests can go into Rakudo's test dir
13:50 pmichaud can I see the Q:PIR test in question?
13:50 TimToady t/spec/S12-class/basic.t
13:51 pmichaud oh, that test definitely does not belong in t/spec
13:51 pmichaud it's clearly testing something about Rakudo, not about Perl 6
13:51 TimToady we all have our little mental aberrations :)
13:52 pmichaud I'm not certain that the original ticket is actually a bug.
13:52 pmichaud it really speaks more to Parrot design than Rakudo design, anyway.
13:53 azawawi joined #perl6
13:53 azawawi hi
13:54 pmichaud at the moment I think I'm going to declare RT #60496 "not a bug" and let it slide for now.  We don't currently make any guarantees that Rakudo objects play nicely with Parrot 'isa' opcodes.
13:54 pugs_svn r26556 | szabgab++ | add links to syn index
13:54 PhatEddy The ticket seems to ask whether parrot class isa should work like Perl 6 class isa.  It might be sort of nice if it did but not necessary ...
13:55 pmichaud I agree it would be nice if it does.  Eventually it hopefully will.  But Parrot vtables don't map cleanly to Perl 6's methods.
13:55 pmichaud We currently have to do lots of vtable-specific workarounds.
13:59 Matt-W Didn't I see something about that in jnthn's Hague Grant proposal?
14:00 pmichaud I didn't see anything about it
14:01 wollmers joined #perl6
14:01 jnthn Only that method dispatch will layer better on top of Parrot.
14:01 zamolxes joined #perl6
14:02 alester joined #perl6
14:02 pugs_svn r26557 | pmichaud++ | [t/spec]:  Remove Rakudo/Parrot-specific test.
14:02 eric256 when you do a perl6 -v, where does the revision number come from? and shouldn't it list the git SHA-1 ?
14:03 pmichaud currently the revision number is coming from Parrot.
14:03 pmichaud Yes, it should be something more useful.
14:03 pmichaud I'm open for patches or other suggestions.  :-)
14:03 wollmers TimToady: I agree with moritz, that something like integration tests - cross specs - are necessary.
14:03 TimToady wasn't arguing with that
14:04 pmichaud I don't know how to get the git SHA-1 into the code.
14:04 eric256 ahh okay, i was just reading http://wincent.com/a/about/wincent/webl​og/archives/2007/07/build_numbers_i.php and it kind of recommends using (data "+y-%j") in addittion to the SHA-1, that would make it easier to look at too builds of perl6 and at least see which is newer
14:04 * eric256 goes to look
14:04 wollmers But at the moment the tests are incomplete and partly - more or less - in the wrong place.
14:05 moritz_ pmichaud: git log --pretty=format:%h|head -n1
14:05 moritz_ or %H if you want the full hash
14:05 pmichaud moritz_: that gets me the hash, yes -- how do I get that into the compiled code?  ;-)
14:06 pmichaud I guess I need to make it part of gen_builtins.pir or some other generated file.
14:06 TimToady I also am not arguing with integration/ being used for misc pre-classified tests, as long as it's culturally understood
14:06 moritz_ pmichaud: yes, something like that
14:07 pmichaud we'll be refactoring src/gen_builtins.pir soon, so perhaps I can make it part of that.
14:07 pmichaud There's also the tricky issue that not everyone gets Rakudo via git.
14:07 moritz_ pmichaud: `git log -1 --pretty=format:%h' actually
14:07 moritz_ hurm.
14:07 PerlJam write the SHA1 to a file in the tarball.
14:07 wollmers TimToady: We can put a note into README
14:08 pmichaud PerlJam: sure, but then we need to know when to read the SHA1 from the tarball and when to get it from git.
14:08 pmichaud s/tarball/file/
14:08 azawawi TimToady: STD needs a space after $/.chunks (line 32) to parse http://nopaste.snit.ch/16441. Any ideas why it is not parsing it?
14:08 PerlJam always get it from the file and make the build process regen the file each time.  :)
14:08 pmichaud azawawi: Rakudo misparses that.
14:09 pmichaud azawawi: without the space, the brace would be a postcircumfix brace (like on a hash)
14:09 pmichaud the space is required to be valid Perl 6.
14:09 azawawi pmichaud: thx...
14:10 wollmers Ciao, servus to all - have to catch my train from Vienna to Erlangen.
14:10 moritz_ wollmers: have fun...
14:10 moritz_ wollmers: if you told me that earlier, we could have met in Erlangen :-)
14:10 pmichaud PerlJam: which "build process"?
14:11 moritz_ I'll be there from Fr to Sun
14:11 pmichaud PerlJam: you mean the Makefile should regen the file?
14:11 pmichaud PerlJam: or Configure.pl?
14:11 pmichaud PerlJam: or ... ?
14:11 TimToady wayland76: actually, .wrap was aimed squarely at AOP
14:12 pmichaud "was"?  ;-)
14:12 wollmers moritz_: I am from Vienna, but live in Erlangen since 2007. But this WE I will be in Albstadt.
14:13 moritz_ wollmers: ok, we have to meet some time - I'm in Erlangen roughly twice a month
14:14 TimToady azawawi: yes, what pmichaud said
14:14 TimToady wayland76: NOT what pmichaud said. :)
14:14 szabgab http://perlcabal.org/syn/index_C.html and http://perlcabal.org/syn/index_X.html
14:16 szabgab pls check them out and let me know which way to improve them
14:18 moritz_ szabgab: some links occur multiple times under the same bullet point
14:18 pmichaud szabgab: some of the titles have < > in them that probably need conversion to &lt; &gt;
14:18 moritz_ szabgab: it would be nicer to remove duplicates
14:18 TimToady a lot of the early S* have bullets where they ought to have headings, I expect
14:19 TimToady yowser
14:19 TimToady std: if 1 {} elseif 2 {}
14:19 p6eval std 26557: OUTPUT«##### PARSE FAILED #####␤Statements must be separated with semicolon at /tmp/DnBx1H8YRq line 1:␤------> [32mif 1 {} else[31mif 2 {}[0m␤    expecting spacey␤FAILED 00:02 35m␤»
14:19 TimToady there's a bogus message...
14:19 pmichaud looks like 'else' needs a >> or a <.nofun> or something
14:20 PerlJam pm: Hmm. As long as you don't put the .git dir in the tarball, you can use the presence of the .git to determine if you've got a tarball or a clone.  for a tarball, use the value in the file, for a clone, regen the file at Configure.pl time.
14:20 TimToady well, that's what "spacey" is supposed to be looking for
14:20 pmichaud PerlJam: does Windows use ".git" for its subdir?
14:20 TimToady but it must have backtracked and decided "else" is starting a new statement
14:20 jnthn pmichaud: yes
14:21 pmichaud the tarballs definitely don't get ".git".  No need to include the entire history of Rakudo in the tarball :-)
14:21 TimToady at least it's pretty clear *where* it failed
14:21 jnthn (expecting spacey)++
14:21 pmichaud I was thinking of testing explicitly for "elseif" and issuing a message.
14:21 pmichaud since that's a common typo.
14:22 pmichaud maybe  "else if" as well.
14:22 jnthn And common in other languages.
14:22 jnthn As is else if
14:22 TimToady else if is more informative
14:22 jnthn Perl always felt like the odd one ut to me with using elsif
14:22 TimToady std: if 1 {} else if 2 {}
14:22 p6eval std 26557: OUTPUT«##### PARSE FAILED #####␤Malformed block at /tmp/jZ9w8tiLdI line 1:␤------> [32mif 1 {} else [31mif 2 {}[0m␤    expecting parameterized block␤FAILED 00:02 35m␤»
14:22 moritz_ that is also confusing.
14:23 TimToady troo
14:23 moritz_ it's not a malformed block, it's not a block where a block is expected
14:23 pmichaud I think "use 'elsif'"  would be more helpful there.
14:23 TimToady pot, kettle :P
14:24 PerlJam or change the language def to make "elseif" and "else if" forms equivalent to "elsif"   ;)
14:26 iblechbot joined #perl6
14:26 jnthn Indeed! That Perl 5 only lets you write elsif is a clear violation of TMTOWTDI.
14:26 jnthn ;-)
14:26 TimToady every time we add more tokens, the parser is going to slow down more, so there's a tradeoff between perfect error messages and performance, unless we can do an elseif check lazily after it has failed already
14:27 pmichaud in this case, it would only slow down after parsing 'if', yes?
14:27 TimToady yes
14:27 pmichaud as opposed to the general case where we introduce a slowdown on every term or something like that.
14:27 TimToady well, but also we have to recompile STD.pmc every time, currently
14:27 TimToady and it gets longer
14:27 TimToady but precompilation will fix that, mostly
14:27 pmichaud it's a reasonable consideration, I agree.
14:31 moritz_ that's why I suggested a more general (but still helpful) error message
14:36 pugs_svn r26558 | szabgab++ | remove duplicate links from index_X.html pages
14:37 justatheory joined #perl6
14:42 ejs left #perl6
14:43 sri_kraih_ joined #perl6
14:47 ejs joined #perl6
14:49 pugs_svn r26559 | lwall++ | [STD] be clearer about else\s*if and missing blocks
14:52 nihiliad joined #perl6
14:53 masak joined #perl6
14:57 PhatEddy left #perl6
15:01 km2 joined #perl6
15:02 ejs1 joined #perl6
15:03 pugs_svn r26560 | szabgab++ | smartlinks: by default hide snippets
15:03 Psyche^ joined #perl6
15:04 Tene pmichaud: we could ask git to write out the revision ID, date of the commit, or whatever else you want to a file when it's checked out.
15:04 Tene pmichaud: I can set that up if you want.
15:04 pmichaud ooh, that would be nice.
15:04 Tene Just tell me what information you want
15:05 Tene pmichaud: the hll branch is up to date with master and passes most of the tests.  Lemme nopaste the test summary report...
15:06 pmichaud have git write src/builtins/revision.pir
15:06 pmichaud in that, have it do
15:06 pmichaud .const str RAKUDO_REVISION "<value>"
15:06 pmichaud er
15:06 pmichaud .const string RAKUDO_REVISION "<value>"
15:07 [particle] joined #perl6
15:07 [particle] left #perl6
15:07 pmichaud Tene: (test summary)  that's quite a few failures... but I suspect it's due to hll branch being from an older version of Rakudo
15:08 pmichaud my approach would be to start migrating some of the changes from hll back into master, but leave things running in 'parrot'
15:08 Tene pmichaud: no, I pulled the updates from master.
15:08 [particle] joined #perl6
15:08 Tene I tried running a few of those tests directly, and they segfaulted partway through.
15:09 pmichaud brb
15:10 pmichaud back
15:11 pmichaud it seems to me as though we _ought_ to be able to make changes to trunk, and simply switch .HLL on/off to try things out
15:11 Tene pmichaud: there are several files that currently have mixed Perl6 and parrot content
15:12 pmichaud hmm.  Perhaps we should refactor those.
15:12 Tene and ClassHOW.pir currently needs to grab some items from the perl6 HLL namespace
15:12 Tene 9or needs better refactor, as discussed in its header POD
15:13 pmichaud I guess what would help is seeing a diff of the hll branch from master
15:13 exodist joined #perl6
15:14 moritz_ git diff master
15:15 PerlJam Tene: how do you tell git to create a file on clone?
15:15 pmichaud wouldn't it need to also update the file on 'pull' ?
15:15 PerlJam that too.
15:15 PerlJam AFAIK, when you clone a repo, you don't get the hooks in your clone.
15:16 Tene PerlJam: you can set a filter that can intercept and modify the contents when git is updating the file.
15:16 pmichaud +    info = get_root_global ['parrot'], 'Hash'
15:16 pmichaud that looks wrong to me.
15:16 pmichaud I think it should be   get_root_namespace
15:17 Tene PerlJam: you can also set an attribute on a file telling git to do keyword expansion on a file when you export an archive with git-archive
15:17 PerlJam Tene: Oh!  I know about that, but I blocked it out because I associate it with trying to do the equivalent of $Id$ and such from RCS/CVS
15:17 PerlJam yes, evil keyword expansion
15:17 Tene PerlJam: there's something specific for $id$
15:17 Tene and there's something else for generic filtering
15:18 pmurias joined #perl6
15:20 pmichaud Tene:  The call to "!fixup_routine_type" is probably better done with a subid anyway.
15:20 Tene Sure, okay.  I didn't know what to do there.
15:20 pmichaud that eliminates the need for the 'perl6' lookup in ClassHOW.pir
15:20 PerlJam git attributes.   I still don't think I get how they'll be applied on clone or fetch.   But it gives me something to look at .
15:24 pmichaud Okay.  All of the places where   new 'Hash'   was converted to get_root_global  need to be using get_root_namespace instead.
15:25 Tene I'd really prefer the output of 'git describe' instead
15:25 Tene Hmm... maybe during the build process.
15:26 Tene pmichaud: how does "<most-recent tag>-<numbe of commits since that tag>-<short git id>" look to you?
15:26 Tene i.e.
15:26 Tene 2009-04-45-g7d37176
15:26 pmichaud 2009-04-45 looks too much like a date.
15:26 pmichaud maybe commas or colons or semis or something?
15:26 moritz_ 2009-04:45:g7d37176
15:26 Tene That's what you get for using dates as tags. ;)
15:27 Tene yeah, I'll play around with it.
15:27 [particle] get rid of the dash
15:27 pmichaud dates often make the best tag.  It's real easy to say "how old is the 2009-04 release", it's much harder to say "when was Rakudo #3 released"?
15:27 Tene pmichaud: yes, I know.  i was teasing. :)
15:28 pmichaud and, of course, everyone knows exactly when Parrot 1.9 will be coming out, right?  ;-)
15:29 pmichaud one potential problem with "most-recent-tag" is that when I build the tarball I might not have tagged it yet.
15:30 pmichaud I suppose we could build the tarball twice -- once for testing and then again for the official one.
15:30 PerlJam pm: how do you build the tarball?
15:30 pmichaud pj:  "make release VERSION=2009-04"
15:30 PerlJam you could have the makefile tag it for you.
15:30 pmichaud see also   docs/release_guide.pod
15:31 pmichaud PerlJam: we generally want to make a "test tarball" to make sure the tarball is correct before tagging anything.
15:31 pmichaud i.e., we should only tag *after* we've verified that the tarball is correct, builds properly, etc.
15:31 M_o_C joined #perl6
15:32 moritz_ pmichaud: tagging can be easily reverted, unless you've pushed it
15:32 pmichaud even so, I'm not sure I see a huge benefit to auto-tagging.
15:32 pmichaud We also tag the release names.
15:32 moritz_ ok
15:32 pmichaud at some point it might end up being  "make release VERSION=2009-04 NAME=Bratislava"
15:32 PerlJam pmichaud: mediate the tagging with an environment variable.    :)
15:33 pmichaud but that's *really* low priority at the moment.
15:33 eMaX joined #perl6
15:33 pmichaud i.e., the current 'make a release' process isn't terribly onerous or broken, so I don't see a strong need to introduce more things to worry about.
15:33 eMaX moin
15:33 eMaX moritz_, cool article series in IX tnx for that
15:34 moritz_ eMaX: is the May issue out already?
15:34 eMaX yes got it today
15:35 moritz_ cool
15:35 pmichaud moritz++
15:36 moritz_ I'm going to submit the last one (on regexes and grammars) tonight or tomorrow
15:36 pmichaud oh, that reminds me -- I need to make my yapc::eu talk submissions.
15:38 jnthn oh noes, I forgot about that too...
15:38 pmichaud anyone doing the "cool stuff in Perl 6" talk?
15:38 jnthn I'm not sure what to talk about.
15:38 pmichaud aka  "The Perl 6 Express"?  ;-)
15:38 jnthn Dare I submit a talk about a Perl 6 module I didn't write yet?
15:39 jnthn Well, I could give a talk like that there...
15:39 pmichaud jnthn:  why not?  I submitted talks about a compiler I hadn't written yet :-)
15:39 jnthn I pondered submitting one on roles...
15:39 jnthn hehe!
15:39 moritz_ "role plays"
15:40 pmichaud I'm planning to submit a regexes/grammars talk, unless someone else wants to do that.
15:40 pmichaud a talk on roles would be excellent.
15:40 pmichaud I think it's often a good idea for there to be an introductory Perl 6 talk aimed at P5 programmers
15:41 pmichaud as in "here's cool stuff you can do in Perl 6 today"
15:41 masak so far, I've submitted two talk proposals. one on Web.pm, one on grammars and rules.
15:41 lambdabot masak: You have 1 new message. '/msg lambdabot @messages' to read it.
15:41 masak ooh, a message!
15:41 masak @messages
15:41 lambdabot TimToady said 1h 52m 14s ago: I just need to implement the warning on class redefinition with a tuit of some sort
15:42 literal what's the difference between roles/traits and mixins?
15:42 masak TimToady: ah.
15:42 pmichaud masak: if you're doing grammars and rules, I won't step on that talk then.
15:42 masak literal: compile time and run time, respectively.
15:42 masak pmichaud: well, supposing it gets accepted.
15:42 pmichaud masak: I'm sure that some talk on regexes and grammars will be accepted.
15:43 literal masak: but in Perl 6, a trait is compile time while role is runtime?
15:43 mberends I'm willing to talk about P6 for P5 programmers if nobody else does.
15:43 masak pmichaud: I think I'll focus on whole parser examples, picking them apart and showing the neat stuff.
15:43 masak mberends: nice!
15:44 pmichaud I have so many things I _can_ talk about, so I prefer not to take the stage away from others who might give talks.
15:44 masak literal: no, I think the reverse is the case.
15:44 literal ok
15:46 PerlJam pm: talk about how there's going to be an alpha "production release" of rakudo by the end of the year  ;)
15:46 pmichaud pj:  that sounds like a lightning talk.  :-)
15:46 moritz_ or a general rakudo roadmap/vision talk
15:46 pmichaud already submitting that one   "Hacking Rakudo Perl"
15:46 TimToady traits are applied at compile time, roles are applied at either compile or run time
15:47 moritz_ another nice lightning talk woudl be the "the #perl6 eco system"
15:47 pmichaud oooh, I like that.
15:47 pmichaud I still think I'd like to put together a lightning talk about "the waterbed theory of Perl 6 pain"
15:47 moritz_ lol
15:47 masak :)
15:48 masak "pain is pushed towards the implementers"
15:48 PerlJam pm: the waterbed is really filled with acid, so watch where you push and how hard?
15:48 jnthn <picture of tormented implementers>
15:48 masak o_O
15:48 pmichaud pj:  well, in some sense our goal is going to be to cut a hole in the waterbed to let the pain out :-)
15:48 jnthn OK, I will submit one on roles, and Grammar::Generate;
15:48 jnthn (that is total two talks)
15:48 pmichaud I'll submit "Hacking Rakudo Perl", and a "blank slot"
15:49 TimToady "vicarious suffering" is the theological term
15:49 pmichaud where I'll let the organizers choose a topic
15:49 pmichaud I wish more of my suffering was vicarious.  :-)
15:50 PerlJam pmichaud: all you have to do is find more people to delegate to.
15:50 pmichaud s/more people/some masochists/   # ??
15:50 TimToady vicars :)
15:51 PerlJam one of the criticisms I've heard about rakudo is that it's tied to parrot and that parrot is somehow broken.  (I've heard this a few times, but never with any specifics)   I wonder if this is another "perl is dead" meme on the rise.
15:52 TimToady maybe we need to start a "perl is undead" meme
15:52 jradzuweit joined #perl6
15:52 jhorwitz joined #perl6
15:53 TimToady vampiric suffering...
15:53 PerlJam "zombie perl" sounds like a good title for a talk :)
15:53 [particle] about pugs?
15:53 pmichaud "We the implementors will bear any burden, pay any price, to meet the Perl 6 vision.  We shall conduct ourselves so that a thousand years from now, when Perl 6 is finally released, people will look back and say 'This was their finest hour.'"    (Okay, did I mix too many speeches in that? ;-)
15:53 PerlJam lol
15:53 diakopter Perl skipped Christmas and went straight to Easter
15:53 TimToady what about "Ask not..."
15:53 pmichaud I learned to "Ask not..." a long time ago.
15:54 TimToady but still, a pastiche would be a great lightning talk
15:54 [particle] p5p and p6p are one community separated only by a common language.
15:55 * [particle] mixes in more quotes
15:55 pmichaud okay, Perl 6 quotes is my lightning talk for the year :-)
15:55 pmichaud with special emphasis on pain management :-)
15:56 pmichaud unless I come up with yet another really cool technical hack like LOLPAST :-)
15:56 jnthn PerlJam: Parrot sure ain't perfect, but it's hardly like there aren't people improving it and it's not like the Rakudo devs are incapable of fixing it either.
15:56 literal are you guys talking about the YAPC::EU on August 3rd?
15:56 jnthn And it ain't, well, *that* bad.
15:57 pmichaud literal: yes.  Call for presentations ends tomorrow.
15:57 TimToady if it ain't broke, unbork it...
15:57 Tene pmichaud: a solution that only works when you generate your tar with git-archive wouldn't be good enough, right?
15:57 [particle] parrot is the worst virtual machine for perl 6, except all the others.
15:57 pmichaud Tene: I'm more interested in something that works when people do git-checkouts.
15:58 Tene right, okay.
15:58 pmichaud generating the tar is low-volume, and doesn't affect anyone but the person generating the tar.
15:58 pmichaud so I don't care if that's automatically built.
15:58 pmichaud indeed, in some sense the "make release" target can override whatever git does.
15:58 * masak wouldn't mind seeing more vicars in Perl 6 development
15:59 TimToady we'll settle for suckers who might develop into vicars
15:59 Tene okay, I can get the id in like: "$Id: 035c8abedeb532b38bf9ed1399e054896bca9e20 $"
15:59 Tene which would need to be trimmed before printing
16:00 pmichaud Tene:  that's fine.
16:00 pmichaud trimming is easy.
16:00 pmichaud as is any other sort of manipulation we might want to do.
16:02 Tene include it from gen_builtins.pir ?
16:03 pmichaud sure.
16:03 Tene oh, that happens automatically.
16:03 pmichaud or even if it just generates the file, I can put the include in
16:03 pmichaud right now I'm primarily interested in getting the id generated.
16:04 Tene pushed
16:05 Tene you might need to rm it and then git checkout src/builtins/revision.pir this time, as the gitattributes file came down in the same commit
16:06 PerlJam ls
16:06 PerlJam oops
16:06 ejs joined #perl6
16:06 pmichaud oops:  command not found
16:06 Tene ... huh
16:06 Tene That's totally not what we want at all
16:07 Tene that shows the git id of the blob that holds that file
16:07 Tene not what we want at all. :)
16:07 PerlJam Tene: and it *only* works on checkout, not on clone or fetch.  (AFAICT)
16:10 eric256 i haven't backlogged yet, but wouldn't it make the most since to do the git at make/compile time?  that way if i checkoutone version, modify it and then make, i'll have a different revisino number than anyone else?
16:11 * PerlJam gets the feeling that the bang/buck ratio is only decreasing.
16:11 pmichaud eric256: we have to handle the case where someone didn't obtain rakudo via 'git'.  (But PerlJam's "check for .git directory" works for that.)
16:12 pmichaud eric256: and you're probably describing where someone checks out a version, modifies it, commits, and then builds
16:12 eric256 PerlJam: it definitly sounds more difficult than i was expecting ;)
16:12 eric256 pmichaud: thats exactly what i was describing ;)
16:13 Tene okay, really need to get to work now, srsly
16:19 [particle] cute overload: https://www.getmiro.com/adopt/
16:26 Umeaboy joined #perl6
16:31 mberends @tell masak nice quick intro: http://developer.apple.com/tools/rubyonrails.html
16:31 lambdabot Consider it noted.
16:38 ZuLuuuuuu joined #perl6
17:00 alanhaggai joined #perl6
17:23 kidd joined #perl6
17:27 alanhaggai joined #perl6
17:30 pugs_svn r26561 | lwall++ | [multidimensional.t] typo in plan
17:34 eMaX joined #perl6
17:34 eMaX re
17:35 eMaX moritz_, is it possible to have these articles electronically?
17:44 pugs_svn r26562 | lwall++ | [t] junctional types not currently allowed before param var
17:45 pugs_svn r26563 | lwall++ | [STD] combine fulltypename with typename
17:47 moritz_ eMaX: no, I had to assign the copyright to Heise
17:47 moritz_ eMaX: and if they don't put it online, I can't
17:47 moritz_ eMaX: but of course you can write them a mail and ask if they'd publish it
17:56 barney joined #perl6
18:03 japhb joined #perl6
18:12 eMaX joined #perl6
18:20 ruoso joined #perl6
18:21 iblechbot joined #perl6
18:23 amoc joined #perl6
18:43 clkao joined #perl6
18:45 hcchien joined #perl6
18:46 pugs_svn r26564 | lwall++ | [STD] hack in duplicate checking for typenames
18:48 clkao_ joined #perl6
18:51 hcchien joined #perl6
18:51 TimToady @tell masak interestingly, now that I actually implemented the warning, class Int {} is not a redef of CORE::Int; it just hides it
18:51 lambdabot Consider it noted.
18:51 jnthn TimToady: ...does that apply to all core classes? And why?
18:52 eMaX joined #perl6
18:52 jnthn Is CORE::Int actually lexical and a lexical import? And if so, does defining a class Int { ... } both install it in the namespace and the lexpad?
18:53 pmichaud afaik, all "core" items are actually lexical.
18:54 TimToady if you say class Int, it defaults to our, which adds Int to both MyCurrentPackage and MyCurrentLexpad
18:54 jnthn OK, I wasn't aware of the second bit.
18:55 TimToady but doesn't intersect with any outer definition
18:55 TimToady if you say my class you only get the lexical
18:55 jnthn So basically most class lookups are lexical?
18:55 TimToady yes
18:55 moritz_ rakudo: say (hash ( 2 => 3 )).WHAT
18:55 TimToady even ones starting GLOBAL::
18:55 [particle] my class lookups are lexical
18:55 p6eval rakudo 5646df: OUTPUT«Hash()␤»
18:55 pmichaud in general, most name lookups are lexical, I think.
18:56 LylePerl joined #perl6
18:56 [particle] our class lookups are lexical { ... }
18:56 TimToady and (pretty much) all the package names visible to your scope are visible via their lexical aliases
18:56 [particle] std: our class lookups are lexical { ... }
18:57 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Malformed our␤Malformed class␤Unable to parse class definition at /tmp/slmj9TJDIM line 1:␤------> [32mour class lookups [31mare lexical { ... }[0m␤    expecting trait␤FAILED 00:02 56m␤»
18:57 pmichaud all(our base is :belong<us>)
18:57 [particle] ah, i thought there was an 'are' alias for 'is'
18:57 [particle] std: our class lookups is lexical { ... }
18:57 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
18:58 moritz_ std: our class stuff is weird { ... }
18:58 TimToady std: class Int {}
18:58 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
18:58 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
18:58 TimToady std: class Int {}; class Int {}
18:58 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name Int redeclared at /tmp/2DtZFMSQ03 line 1:␤------> [32mclass Int {}; class Int[31m {}[0m␤  Name Int redeclared at /tmp/2DtZFMSQ03 line 1:␤------> [32mclass Int {}; class Int[31m {}[0m␤ok 00:02 35m␤»
18:58 TimToady std: class CORE::Int {}
18:58 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name Int redeclared at /tmp/COdLncinab line 1:␤------> [32mclass CORE::Int[31m {}[0m␤ok 00:02 35m␤»
18:58 moritz_ if we warn twice it's more effective.
18:58 moritz_ if we warn twice it's more effective.
18:59 hcchien joined #perl6
18:59 TimToady warns once for the package conflict and once for the lexical
18:59 jnthn TimToady: GLOBAL doesn't imply namespace even?
18:59 TimToady std: my class Int {}; my class Int {};
18:59 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name Int redeclared at /tmp/6T3DCGnL8A line 1:␤------> [32mmy class Int {}; my class Int[31m {};[0m␤ok 00:02 35m␤»
19:00 TimToady see, only one
19:00 TimToady should probably say which symbol table the conflict was in...
19:00 jnthn Is CORE::Int thus Int in the namespace CORE?
19:00 TimToady or anywhere inside it
19:00 jnthn And it's imported lexically as Int by default?
19:00 TimToady remember that the Setting is *outside* of everything lexically
19:00 clkao joined #perl6
19:00 TimToady no importing is necessary
19:01 pmichaud jnthn: we run inside the setting's lexical scope.
19:01 jnthn OK, but class CORE::Int { } puts Int into the lexical scope?
19:01 pmichaud so CORE::Int is Int in the CORE namespace, and it's "imported" into the setting.
19:01 pmichaud i.e., it appears in the setting as lexical "Int"
19:02 jnthn oh, so some importing needed after all....
19:02 TimToady only if Int is declared outside of CORE
19:02 zamolxes joined #perl6
19:02 pmichaud I'm not sure I follow that last statement.
19:03 TimToady CORE can define things inline in its lexical scope if it wants to
19:03 TimToady if CORE says 'my class Int' there's no importing necessary into Int
19:03 TimToady s/Int/CORE
19:03 pmichaud sure, but then the Setting is lexically nested inside of CORE?
19:04 TimToady CORE *is* the outermost setting
19:04 TimToady no nesting
19:04 pmichaud okay.
19:04 pmichaud how do we get to GLOBAL, then?
19:04 TimToady CORE::GLOBAL
19:04 pmichaud got it.
19:04 pmichaud and GLOBAL isn't really at the "root" of our package space
19:05 TimToady depends on how you define "package"
19:05 pmichaud so if a p6 program does:   class Int { ... }    it really becomes  CORE::GLOBAL::Int
19:05 TimToady but note that CORE::PROCESS is also not in GLOBAL
19:05 TimToady only if they do it in the main program
19:06 TimToady that is, where GLOBAL is the current package
19:06 pmichaud right.
19:06 pmichaud (I meant in "main", didn't make it explicit)
19:06 keta joined #perl6
19:06 TimToady anyway, you can see how most of these names fit together in CORE.pad
19:07 pmichaud so, could one do...    class Int is CORE::Int { ... }    ?
19:07 TimToady which is presumably a representation of (part of) the compiled output of CORE.pm
19:07 TimToady which isn't there yet
19:07 TimToady that would derive from CORE::Int, presumably
19:08 pmichaud it would be a lexical/package form of augmenting Int?
19:08 TimToady yes
19:08 pmichaud as opposed to "augment", which does monkeypatching?  Cool.
19:08 pmichaud I think I actually start to understand some of this.  :-|
19:08 TimToady std: augment Foo {}
19:08 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Malformed augment␤In "augment" declaration, typename Foo must be predeclared (or marked as declarative with :: prefix) at /tmp/wqV5oLcr7i line 1:␤------> [32maugment Foo[31m {}[0m␤FAILED 00:02 35m␤»
19:08 TimToady std: augment Int {}
19:08 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Malformed augment at /tmp/B8sChRTiLR line 1:␤------> [32maugment Int [31m{}[0m␤    expecting any of:␤    multi_declarator␤ typename␤FAILED 00:02 35m␤»
19:09 TimToady std: augment class Int {}
19:09 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
19:09 TimToady std: augment class Foo {}
19:09 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Malformed augment␤Malformed class␤Can't augment a non-existent type at /tmp/ZSDkYTsszC line 1:␤------> [32maugment class [31mFoo {}[0m␤    expecting name␤FAILED 00:02 35m␤»
19:09 TimToady that's more like it
19:09 TimToady std: supersede class Foo {}
19:09 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Malformed supersede␤Malformed class␤Can't supersede a non-existent type at /tmp/X6n0imRGPN line 1:␤------> [32msupersede class [31mFoo {}[0m␤    expecting name␤FAILED 00:02 35m␤»
19:09 TimToady std: supersede class Int {}
19:09 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
19:09 moritz_ std: augment role Int { }
19:09 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
19:10 jnthn That'd not pass the semantic checker. :-)
19:10 TimToady doesn't do the semantic check
19:11 TimToady std: constant foo = 42; augment subset foo {}
19:11 p6eval std 26564: OUTPUT«##### PARSE FAILED #####␤Unexpected block in infix position (two terms in a row, or previous statement missing semicolon?) at /tmp/1rLvag7hb2 line 1:␤------> [32mconstant foo = 42; augment subset foo [31m{}[0m␤    expecting any of:␤  infix or meta-infix␤      infix stopper␤
19:11 p6eval ..standard...
19:11 PerlJam TimToady: heh!  I was just typing that up
19:11 TimToady std: constant foo = 42; augment subset foo where {}
19:11 p6eval std 26564: OUTPUT«ok 00:02 35m␤»
19:13 TimToady std: enum Foo <bar baz>; supersede subset baz where 42;
19:13 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name bar redeclared at /tmp/cIkCjQqLoC line 1:␤------> [32menum Foo <bar baz>[31m; supersede subset baz where 42;[0m␤  Name baz redeclared at /tmp/cIkCjQqLoC line 1:␤------> [32menum Foo <bar baz>[31m; supersede subset baz where 42;[0m␤ok 00:02
19:13 p6eval ..35m␤»
19:13 TimToady ooh, a bug
19:14 TimToady std: enum A <b c>
19:14 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name b redeclared at /tmp/0gBmPos8rr line 0:␤------> [32m[31m[0m␤  Name c redeclared at /tmp/0gBmPos8rr line 0:␤------> [32m[31m[0m␤ok 00:02 35m␤»
19:14 TimToady cool
19:15 TimToady std: role Foo[::T] {...}
19:15 p6eval std 26564: OUTPUT«ok 00:02 37m␤»
19:15 TimToady std: role Foo[::T] {...}; role Bar[::T] {...}
19:15 p6eval std 26564: OUTPUT«Potential difficulties:␤  Name T redeclared at /tmp/tU8HpoN4bA line 1:␤------> [32mrole Foo[::T] {...}; role Bar[::T[31m] {...}[0m␤ok 00:02 37m␤»
19:15 TimToady another buglet
19:16 moritz_ is there anything implemented in rakudo that lets me convert a hex string to a number?
19:16 moritz_ ie "FF" -> 255
19:17 moritz_ s/ie/eg/
19:17 pmichaud rakudo:  say +":16<ff>"
19:17 TimToady yes, ord()  :P
19:17 p6eval rakudo 5646df: OUTPUT«255␤»
19:17 pmichaud rakudo:  my $x = 'ff';   say :16($x);
19:17 p6eval rakudo 5646df: OUTPUT«255␤»
19:17 TimToady rakudo: my $x = 'ff'; say :16($x)
19:17 p6eval rakudo 5646df: OUTPUT«255␤»
19:18 TimToady looks like that works too
19:18 pmichaud s1n++
19:19 PerlJam moritz_: URL decoding?
19:19 moritz_ PerlJam: JSON decoding
19:19 pmichaud Fargo, North Decoding.
19:20 pmichaud (nm.)
19:20 TimToady keep trying
19:20 TimToady or better yet, don't
19:20 moritz_ ;-)
19:23 mikehh_ joined #perl6
19:23 * [particle] steals pmichaud's dakoda ring
19:23 [particle] speling--
19:24 * jnthn loves the smell of garlic bread cooking
19:24 * jnthn -> dinner, back in a bit
19:24 TimToady FNORD is actually short for Fargo, North Dakota
19:24 TimToady which is why neither of them are really there
19:25 moritz_ if <foo>* matches zero times in a regex, should $<foo> be an empty array? or undef?
19:25 moritz_ rakudo: '' ~~ m/<ident>*/ && say $<ident>.WHAT
19:26 p6eval rakudo 5646df: OUTPUT«Failure()␤»
19:26 TimToady should probably just be Nil
19:27 moritz_ but why? then $<ident> is false even though the rule match
19:27 TimToady it's also funny to ask what it matches if the pattern matches multiple times
19:28 pmichaud well, $/ could be true even if $<ident> is false.
19:28 pmichaud you're really asking for two different things.
19:28 moritz_ not quite
19:28 moritz_ when the top level regex matches the empty string, $/ is true
19:28 moritz_ when <ident>* matches the empty string, $<ident> is false
19:29 pmichaud But I don't think of <ident>* as "matching" the empty string.
19:29 pmichaud in the sense that it matched zero times.
19:29 pmichaud which means "no matches"
19:29 moritz_ why not?
19:29 TimToady it returns a Nil
19:29 TimToady it's not matching a string in any case
19:29 TimToady suppose
19:29 TimToady [ <ident> xxx ]* /
19:30 TimToady er, with a / on the front
19:30 TimToady it can match 0 or more idents, but they aren't even contiguous
19:30 TimToady so you can't argue that $<ident> should return the string convered
19:30 TimToady *coverd
19:30 TimToady *
19:31 TimToady (not that the pattern makes sense...)
19:31 moritz_ i think I see your point
19:31 TimToady $<ident> is known statically to return a list of some sort
19:31 TimToady but that list might be Nil
19:31 moritz_ ok
19:31 TimToady question is, suppose it matches 2 idents
19:32 TimToady does $<ident> then match *either* of them?
19:32 [particle] especially if <ident> has subrules with alternations
19:32 TimToady as if you said @$<ident>
19:32 moritz_ why should $<ident> match *anything*? it's not a regex
19:32 TimToady arrays do literal disjunctive match
19:32 TimToady same as < a b c >
19:32 moritz_ ah, inside the regex
19:33 TimToady so @ident could match any of a list of idents
19:33 moritz_ I was thinking about closure all the tiime
19:33 TimToady should $ident work the same?
19:33 TimToady if it happens to be a list?
19:33 moritz_ do you mean $<ident>?
19:34 moritz_ if yes, sounds sane
19:34 moritz_ if not, you lost me ;-)
19:34 TimToady I meant any scalar variable containing a list
19:34 TimToady including $<ident>
19:34 moritz_ ok
19:34 TimToady we already look at $foo to see if it's a Regex
19:34 moritz_ sounds sane, but I haven't put much thought into it
19:34 TimToady and if not, treat as a string
19:35 TimToady so we could special-case other types too
19:35 moritz_ "smart interpolation"
19:35 TimToady alternately, we could force people to say @$foo if they mean it
19:35 moritz_ speaking of which... is interpolation of hashes still in S05?
19:35 TimToady since the disjunction is a bit surprising if they don't expect it
19:35 TimToady which goes without saying...
19:36 pmichaud :-)
19:36 TimToady um, I'm not terribly interested in regex hashes these days
19:36 pmichaud me neither :-)
19:36 TimToady we should probably just reserve them
19:36 pmichaud +1
19:36 moritz_ +1
19:37 moritz_ rakudo: '' ~~ m/<ident>*/ && say $/.perl
19:38 p6eval rakudo 5646df: OUTPUT«Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "",␤ text => "",␤ from => 0,␤ to   => 0,␤)␤»
19:38 moritz_ rakudo: 'a' ~~ m/a<ident>*/ && say $/.perl
19:38 p6eval rakudo 5646df: OUTPUT«Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "a",␤ text => "a",␤ from => 0,␤ to   => 1,␤)␤»
19:38 Gothmog_ joined #perl6
19:39 moritz_ rakudo: 'ab' ~~ m/a<ident>*<foo=ident>/ && say $/.perl
19:39 p6eval rakudo 5646df: OUTPUT«Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ ast  => "ab",␤ text => "ab",␤ from => 0,␤ to   => 2,␤ named => {␤  'foo' => Match.new(␤    ast  => "b",␤    text => "b",␤    from => 1,␤    to   => 2,␤   ),␤ },␤)␤»
19:40 pugs_svn r26565 | lwall++ | [S05] reserve hash notation
19:42 literal hm, :16<ff> interpolates? as part f what? :scalar?
19:42 literal rakudo: say Q:scalar/:16<ff>/
19:43 p6eval rakudo 5646df: OUTPUT«Colons cannot be used as delimiters in quoting constructs at line 1, near ":scalar/:1"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
19:43 literal rakudo: say Q :scalar / foo :16<ff> bar /
19:43 p6eval rakudo 5646df: OUTPUT«Colons cannot be used as delimiters in quoting constructs at line 1, near ":scalar / "␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
19:45 pmichaud rakudo only understands a few of the adverbial quoting modifiers
19:45 pmichaud that said, :16<ff> doesn't interpolate.
19:46 pmichaud +":16<ff>" isn't interpolation, it's numification.
19:46 pmichaud rakudo:   say ":16<ff>";
19:46 p6eval rakudo 5646df: OUTPUT«:16<ff>␤»
19:46 pmichaud rakudo:   say +":16<ff>";
19:46 p6eval rakudo 5646df: OUTPUT«255␤»
19:46 literal oh, I see
19:46 pmichaud rakudo:   say +":16<ff> bottles of beer on the wall";
19:46 p6eval rakudo 5646df: OUTPUT«255␤»
19:57 jnthn rakudo: say "{+":16<ff>"} bottles of beer ont he wall";
19:57 p6eval rakudo 5646df: OUTPUT«255 bottles of beer ont he wall␤»
19:57 jnthn nice, plenty spare for me...
20:00 pmichaud rakudo:   say "{:16<ff>} bottles of beer on the wall";
20:00 p6eval rakudo 5646df: OUTPUT«255 bottles of beer on the wall␤»
20:00 TimToady phone
20:01 FurnaceBoy joined #perl6
20:10 ispy_ joined #perl6
20:15 meppl good night
20:18 hercynium joined #perl6
20:37 arnsholt pmichaud: You mentioned that you had a patch for double quoted strings in regexes the other day. Does that handle variable interpolation?
20:41 angoladon joined #perl6
20:45 Umeaboy left #perl6
20:46 angoladon left #perl6
20:53 pmichaud arnsholt: no.  (also we don't even handle bare scalars in regexes yet)
20:53 pmichaud I'm not sure what it would take/require to get double-quoted strings to do that.
20:54 ejs1 joined #perl6
20:55 pugs_svn r26566 | moritz++ | [t/spec] correctet test for .chunks on submatches
20:55 pugs_svn r26567 | moritz++ | [t/spec] tests for RT #62838
20:56 bacek joined #perl6
21:00 pugs_svn r26568 | moritz++ | [t/spec] tests for RT #65096, autothreading over Array parameters
21:02 arnsholt pmichaud: Yeah, I've been juggling that problem about in my head lately
21:03 jnthn At the very least, emiting a find_lex for 'em and setting the outer properly, I'd guess.
21:04 arnsholt The fact that double quotes should inherit interpolation semantics from the enclosing language makes it even more interesting
21:07 Limbic_Region joined #perl6
21:07 TimToady in the long run, you have to do it like STD does...
21:08 arnsholt Which means I should probably go look at STD.pm
21:08 arnsholt Be right back =)
21:08 TimToady yeah, sure
21:10 [particle] there you go, scaring off contributors again....
21:13 arnsholt Not scaring off. To be entirely honest, I quite like grammars actually
21:14 * moritz_ too
21:14 moritz_ but they are a bit tricky, at time
21:14 moritz_ s
21:15 TimToady especially this one, when it comes to polymorphic quoting languages passed down through regexen
21:15 pugs_svn r26569 | moritz++ | [t/spec] tests for make() in action stubs
21:15 TimToady the important thing to note is $*LANG
21:17 pmichaud in the case of PGE and Rakudo, we need Rakudo to override PGE's default double-quote rule and instead make a call to the double-quote parsing routine inside of Rakudo's grammar
21:17 pmichaud and after it's parsed, return it back as something that PGE can then convert to code to evaluate the double-quoted string at runtime and perform a match on the result
21:18 Tene pmichaud: did you notice a difference in spectest speed in the .HLL branch?
21:18 Tene or was it just my imagination?
21:18 pmichaud Tene: haven't gotten quite that far yet.  Still trying to get rakudo to build.
21:18 pmichaud I don't know.  Was your imagination faster or slower?
21:18 arnsholt Yeah, that's the direction my brain was headed as well. PGE has to be given the information needed to parse double quoted strings, closures and the like
21:18 Tene it seemed like hll branch was slower.
21:19 Tene BUT, it was late at night.
21:19 pmichaud I think I might expect that.
21:20 moritz_ rakudo: say eval 'module A { if 3 { 5 } else { 6 } }'
21:20 p6eval rakudo 39e45d: OUTPUT«_block34␤»
21:20 pmichaud merging this back to trunk (and getting it to work) is proving to be a pain
21:20 moritz_ rakudo: say eval 'module A { if 3 { 5 } else { 6 } }'.WHAT
21:20 p6eval rakudo 39e45d: OUTPUT«␤»
21:20 moritz_ huh?
21:20 moritz_ any idea what's going on here?
21:20 Tene moritz_: it returned the module.
21:20 Tene which is a block
21:21 moritz_ hm
21:21 moritz_ ok
21:21 jnthn rakudo: say (eval 'module A { if 3 { 5 } else { 6 } }').WHAT
21:21 p6eval rakudo 39e45d: OUTPUT«Code()␤»
21:21 PerlJam rakudo:  say eval "string".WHAT   # is what you asked for the first time.
21:21 p6eval rakudo 39e45d: OUTPUT«␤»
21:21 Tene rakudo; my $x = eval 'module A { 1 }'; say $x()
21:21 PerlJam rakudo: "string".WHAT.say
21:21 p6eval rakudo 39e45d: OUTPUT«Str()␤»
21:21 pmichaud rakudo:  "string".WHAT.eval.say
21:22 p6eval rakudo 39e45d: OUTPUT«Method 'eval' not found for invocant of class ''␤current instr.: 'parrot;P6metaclass;dispatch' pc 662 (src/classes/ClassHOW.pir:171)␤»
21:22 Tene rakudo: my $x = eval 'module A { 1 }'; say $x()
21:22 p6eval rakudo 39e45d: OUTPUT«1␤»
21:22 Tene see?
21:23 pmichaud I think it'll be easier for me to make modifications to master going forward than to try to backpatch them in from the hll branch and wonder what's breaking.
21:23 pmichaud (and why)
21:26 jnthn (scheduling) I will do my other catch-up Rakudo Day this week on Friday. (not tomorrow...too many distractions...)
21:27 pugs_svn r26570 | moritz++ | [t/spec] tests for "if" and "eval" iin packages, RT #64072 and RT #65238
21:28 Tene pmichaud: okay, I will get branch merged into master
21:29 pmichaud Tene: I still think it's easier to go the other way.
21:29 pmichaud working on it now.
21:29 Tene oh, "it will be easier"
21:29 Tene I misread.
21:30 TimToady rakudo: "string".WHAT.perl.eval.say
21:30 p6eval rakudo 39e45d: OUTPUT«Method 'eval' not found for invocant of class 'String'␤current instr.: 'parrot;P6metaclass;dispatch' pc 662 (src/classes/ClassHOW.pir:171)␤»
21:31 pmichaud at some point I think we had decided .eval wouldn't be a method on Any.
21:31 TimToady rakudo: "string".WHAT.perl.say
21:31 p6eval rakudo 39e45d: OUTPUT«Str()␤»
21:31 pmichaud (we can of course switch back)
21:31 moritz_ pmichaud: re my grammar/actions methods from last night, I've fixed .chunks a few hours ago, and prepared a small demo for masak
21:31 TimToady .perl of a protoobject probably *shouldn't* have the ()
21:32 pmichaud moritz_: excellent.  Are things working better now?
21:32 moritz_ yes.
21:32 TimToady unless we guarantee that .() on a protoobject returns the protoobject itself
21:32 pmichaud I agree, shouldn't have the ().
21:32 pmichaud rakudobug.
21:32 jnthn Agree.
21:32 jnthn And the type errors will be nicer as a result. ;-)
21:32 PerlJam speaking of which ... how do I get the class name without the () now?
21:32 pmichaud jnthn: oh, the type errors use .perl ?
21:32 moritz_ the problem was that when I wrote .chunks, I didn't have in mind that on sub matches .from and .to aren't aligned with the start of the string
21:33 pmichaud moritz_: I guessed that was the case :-)
21:33 jnthn pmichaud: aye
21:33 pmichaud cool.
21:33 pmichaud PerlJam:  class name w/o () is .perl, probably
21:34 jnthn rakudo: sub foo(Int @x) { }; my Str @a = <a b c>; foo@a)
21:34 p6eval rakudo 39e45d: OUTPUT«Statement not terminated properly at line 1, near "@a)"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
21:34 jnthn rakudo: sub foo(Int @x) { }; my Str @a = <a b c>; foo(@a)
21:34 p6eval rakudo 39e45d: OUTPUT«Parameter type check failed; expected something matching Positional[Int()] but got something of type Array() for @x in call to foo␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
21:34 jnthn Once Array is parametric, it should report Array[Int]
21:34 jnthn I think.
21:34 jnthn :-)
21:35 PerlJam rakudo: class X {}; my $x = X.new; $x.perl.say;
21:35 p6eval rakudo 39e45d: OUTPUT«X.new()␤»
21:35 PerlJam no, that appears to be worse :)
21:35 [particle] rakudo: class X {}; my X $x .= new; $x.perl.print
21:35 p6eval rakudo 39e45d: OUTPUT«X.new()»
21:37 moritz_ PerlJam: X.WHAT.perl should do it
21:37 moritz_ PerlJam: but does not, as per bug above
21:37 moritz_ so, did anybody submit that?
21:37 pmichaud actually, X.perl is sufficient
21:38 pmichaud since X is already a protoobject
21:38 moritz_ right
21:38 pmichaud I'll submit.
21:39 pmichaud submitted.
21:41 [particle] you mean 'masaked'.
21:41 [particle] much like when a ticket is done and awaiting tests, it's 'moritzed'.
21:42 moritz_ ;-)
21:42 * jnthn is glad he picked a vowelless nick so it can't be turned into a catchy-sounding verb.
21:43 pmichaud I suspect that it's not far from "jnthn" to "hackathon"
21:43 moritz_ jnthnd?
21:43 pmichaud masaked can be "submitting blog post with no verbs"
21:43 [particle] when someone submits a grant report and request at the same time, it's 'jnthning'
21:43 pmichaud jnthnd can be "submitting blog post with no vowels"
21:43 Tene edit distance of 6
21:44 Tene between jnthn and hackathon
21:44 jnthn [particle]: It wasn't exactly at the same time. There were approx 2 minutes between the two.
21:44 moritz_ pmichaud: sbmittng blg pst wth n vwls?
21:44 pmichaud *submttng
21:44 pmichaud *sbmttng
21:44 moritz_ arg!
21:44 jnthn ts hrd t wrt wtht vwls.
21:45 Tene try wrtng n hbrw
21:45 pmichaud $blog_post .= subst( /<[aeiou]>/, '')
21:45 PerlJam nt f y dsbl thm n y kybrd
21:45 jnthn hbrw r rbc
21:45 [particle] shouldn't that be missing every other y?
21:45 moritz_ M N R BLGPST TNG R VWLS!
21:46 [particle] hrmm, a vowelless lolcode variant...
21:46 PerlJam [particle]: no, but s:2nd/y/yr/
21:47 [particle] M N YR CD, TN YR VWLS!
21:47 PerlJam [particle]: honestly, I see very little difference without the vowels  ;)
21:48 moritz_ code vs. blogpost
21:48 payload joined #perl6
21:48 moritz_ or did you mean difference between normal lolspeak and vwllss?
21:48 PerlJam aye
21:49 jnthn CN HZ CHZBRGR?
21:49 [particle] MGWTF?
21:49 jnthn kplzthnx
21:50 jnthn .oO( OH HAI doesn't work out too well without vowels )
21:51 PerlJam jnthn: it just become a new meme
21:51 jnthn Well, #perl6 creating a new meme makes a change from 4chan...
21:52 moritz_ H H?
21:53 PerlJam H H!
21:55 pmichaud In http://wiki.github.com/rakudo/​rakudo/steps-to-create-a-patch , didn't we determine that using git send-email wouldn't play well with RT headers?
21:56 moritz_ we did
21:56 moritz_ which is why I wrote the mail-patch branch
21:56 pmichaud can we fix the instructions there somehow?
21:56 pmichaud or update them, or whatever?
21:56 pmichaud I'm not sure how to do that.
21:56 pmichaud (I'm not sure what it should be updated to)
21:57 pmichaud (I know how to update the wiki page :-)
21:57 PerlJam Does rakudo grok class data?
21:57 moritz_ just change it to "write a mail to rakudobug@perl.org and attach that file"
21:58 moritz_ until I've got the mail script sorted out
21:58 Tene moritz_: we have sockets in rakudo now... we could write a little script to send mail.
21:58 Tene :)
21:59 pmichaud updated.  moritz++
21:59 moritz_ ... unless we want to report broken sockets
21:59 moritz_ and might I add that sockets aren't tested atm?
21:59 moritz_ and I can't see how I could test them...
21:59 moritz_ qx would help
22:00 moritz_ or non-blocking sockets
22:00 Tene if we had fork, it would help...
22:00 moritz_ fork. on windows. I don't even want to think about that
22:00 Tene can has fork opcode in parrot?
22:00 Tene no?
22:01 Tene is windows non-forkable?
22:01 moritz_ afaict windows doesn't come with work.
22:01 moritz_ s/work/fork/
22:01 jnthn I often find windows pretty forked.
22:01 moritz_ ;-)
22:01 jnthn ;-)
22:01 moritz_ perl 5 emulates fork() with threads.
22:01 japhb moritz_: I think your original spelling was correct
22:01 jnthn But now, it's process model doesn't really do forking as such.
22:01 jnthn *no
22:02 moritz_ japhb: ;-)
22:02 kane_ joined #perl6
22:02 mberends I'm trying to finish a sockets test script that runs a few bash & lines to fork into client and server processes. Tricky.
22:04 PerlJam rakudo: class X { my $.x = 5; method foo { $.x++ }; }; my $x = X.new; $x.foo; say X.x;
22:04 p6eval rakudo 96de99: OUTPUT«Cannot assign to readonly variable.␤current instr.: 'die' pc 17704 (src/builtins/control.pir:225)␤»
22:04 PerlJam That should work, right?
22:05 moritz_ no
22:05 PerlJam por que no?
22:05 moritz_ with $!x inside the method it should work
22:05 moritz_ $.x means "use the accessor"
22:05 moritz_ and that is read-only
22:05 pmichaud $.x is a read-only accessor
22:05 moritz_ another Perl 6 FAQ entry.
22:09 PerlJam I don't know why I was thinking that $.x made things rw.  That's an odd thing to just suddenly get stuck in your head.
22:09 eric256 left #perl6
22:09 Tene is there a reason that it defaults to ro?
22:09 moritz_ it's not that odd. You declare '$.x', then you expect that you can modify that somehow
22:10 moritz_ Tene: sanity ;-)
22:10 Tene i've always felt that that's a kind of sketchy decision to require 'is rw' instead of 'is ro'.
22:10 Tene moritz_: explain?
22:10 pmichaud generally we should explicitly give permission for external agents to modify the value.
22:11 pmichaud instead of assuming they modify the value and having to explicitly close it off.
22:11 moritz_ Tene: same reason why you use lexical variables - to protect your data from being changed accidentally
22:11 Tene that's what $! vs $. is for, in my mind.
22:11 pmichaud that's different.
22:11 pmichaud $. says "give me an accessor"
22:11 pmichaud $! says "don't provide an accessor
22:12 Tene Exactly.
22:12 Tene so you're already saying "I want to share this with the world'.
22:12 pmichaud but an accessor doesn't have to default to being a rw accessor.
22:13 moritz_ actually they don't, in most programming languages
22:13 pmichaud sharing something with the world doesn't mean "I want to let the world modify it" :-)
22:13 Tene "i want to share, but only kinda" is a middle ground that I don't think I'd see very often.
22:13 pmichaud actually, providing read-only accessors is the more common case, to my mind.
22:13 pmichaud well, perhaps not.
22:13 Tene BUT, sure, my programming style or experience or whatever might be unusual.  I make no claims to normality.
22:13 Tene :)
22:13 moritz_ Tene: for the user there's no difference between a method and a ro-accessor...
22:14 pmichaud anyway, I'm find with saying "is rw"  as opposed to "is readonly"
22:14 moritz_ Tene: so it's much easier for the programmer to change the implementation later on without changing the interface if it's ro
22:14 Tene OK
22:30 wknight8111 joined #perl6
22:32 justatheory_ joined #perl6
22:48 skids joined #perl6
22:52 fridim_ joined #perl6
22:55 ben joined #perl6
23:04 rocket_guatemala joined #perl6
23:07 rocket_guatemala hey, I saw the camelia logo on the http://perl6-projects.org/ site and I thought of doing another interpretation, i have uploaded it on http://www.flickr.com/photo​s/58912287@N00/3487448432/, comments are welcomed
23:09 fridim_ what about http://www.ardensgames.com/www_root_i​sbentu/en/images/perl_logo_270x87.png   ? :)
23:11 rocket_guatemala I tried to get the same spirit of this one, http://svn.pugscode.org/pugs/misc/camelia.svg
23:12 fridim_ yes, horrible
23:13 rocket_guatemala :)
23:50 km2 joined #perl6

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

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs