Camelia, the Perl 6 bug

IRC log for #perl6, 2009-05-11

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:04 skids rakudo: not(True).perl.say; not(8).perl.say; abs(-4).perl.say
00:04 p6eval rakudo a27bbb: OUTPUT«Bool::True␤8␤-4␤»
00:06 nacho_ joined #perl6
00:06 jnthn Precedence. Sometimes it's surprises you. :-)
00:07 jnthn rakudo: (not(True)).perl.say; (not(8)).perl.say; (abs(-4)).perl.say
00:07 p6eval rakudo a27bbb: OUTPUT«Bool::False␤Bool::False␤4␤»
00:07 jnthn Hmm. Actually I'm a tad surprised to. I wonder if Rakudo is right there. :-S
00:08 jnthn If there was a space after the function name, for sure it'd be right...but without it...hmm.
00:09 skids S03: "In term position, any identifier followed immediately by a parenthesized expression is always parsed as a term representing a function call even if that identifier also has a prefix meaning, so you never have to worry about precedence in that case."
00:09 sri_kraih joined #perl6
00:10 skids S03: "not($x) + 1         # means (not $x) + 1"
00:14 jnthn Hmm. In that case probably file rakudobug.
00:14 hercynium joined #perl6
00:14 skids hrm.
00:14 skids rakudo: (not(2) + 1).perl.say; (abs(-4) + 1).perl.say
00:15 p6eval rakudo a27bbb: OUTPUT«Bool::False␤3␤»
00:15 skids so not works in this case but not abs...
00:16 skids ah because they are at different levels.
00:17 jnthn rakudo: say abs(-5) + 7;
00:17 p6eval rakudo a27bbb: OUTPUT«2␤»
00:17 jnthn rakudo: say abs(-5) + -7;
00:17 p6eval rakudo a27bbb: OUTPUT«12␤»
00:17 jnthn fail
00:22 * jnthn -> sleep
00:29 japhb_ joined #perl6
00:31 bacek__ joined #perl6
00:46 wknight8111 joined #perl6
01:04 amoc joined #perl6
01:06 sri_kraih_ joined #perl6
01:31 s1n pmichaud: coming to the p6m meeting?
01:38 kimtaro joined #perl6
01:58 sri_kraih joined #perl6
02:03 LadyLunacy joined #perl6
02:06 sri_kraih__ joined #perl6
02:34 wayland76 joined #perl6
02:58 nihiliad joined #perl6
03:01 Maghnus_ joined #perl6
03:25 amoc^ joined #perl6
03:40 orafu joined #perl6
03:58 amoc joined #perl6
04:00 iblechbot joined #perl6
04:14 kate21de joined #perl6
04:17 amoc joined #perl6
04:22 betterworld joined #perl6
04:58 sri_kraih joined #perl6
04:58 orafu joined #perl6
05:08 justatheory joined #perl6
05:27 sri_kraih_ joined #perl6
05:32 Helios joined #perl6
05:39 Helios joined #perl6
05:39 sri_kraih__ joined #perl6
05:57 Tene http://pleasedieinafire.net:8080/ -- I threw this together in about 20 minutes while waiting for my plane.
05:59 Tene ... it should stop crashing now... hopefully.
06:29 sri_kraih joined #perl6
06:55 Infinoid Tene++
07:11 DemoFreak joined #perl6
07:27 meppl joined #perl6
07:29 sri_kraih_ joined #perl6
07:41 mberends joined #perl6
07:46 Grrrr joined #perl6
07:47 eternaleye joined #perl6
07:47 estrabd_ joined #perl6
07:57 pugs_svn r26766 | azawawi++ | [S:H:P6] version 0.55 contains the latest STD and various minor fixes
08:00 mj41 I found s1n blog post ... http://s1n.dyndns.org/index​.php/2009/05/11/sub-method/
08:02 moritz_ well, if you can't wrap your head around the object model, no amount of DWIMiness will save you.
08:07 jferrero joined #perl6
08:15 jferrero joined #perl6
08:31 H1N1[S] joined #Perl6
08:32 Matt-W Morning
08:33 patmat hello :)
08:33 moritz_ oh hai
08:36 Matt-W On Saturday I had an afternoon of sitting around watching other people rehearse for a concert
08:36 Matt-W So I took my laptop
08:36 Matt-W No sooner do I fire up vim and start writing some Perl 6 than I trip over what's either a bug in Rakudo or a bug in my brain
08:36 Matt-W Guess what the concert venue doesn't have!
08:36 mberends a brain?
08:37 Matt-W open wifi
08:37 Matt-W very frustrating
08:37 mberends of course not, concerts are hifi
08:37 Matt-W the problem is: if I declare a role with two variants of a multi method, then compose that into a class and try to override one or both of them, I get ambiguous dispatch errors between the role and the object's version of the method
08:37 moritz_ lol
08:38 Matt-W overriding multis from a base class does, however, work correctly
08:38 Matt-W so is this what roles are supposed to do, or is this wrong?
08:38 Matt-W and I should really be looking in RT to see if this is known
08:38 moritz_ let's hilight jnthn, maybe he knows
08:38 Matt-W it feels wrong that you don't seem to be able to override multis from a role, because you can override ordinary methods
08:39 Matt-W I think it's seeing them as equally valid candidates instead of an override
08:39 Matt-W Although it did lead me to using a base class instead of a role. I'm not really sure yet when to use which sort of thing
08:42 jnthn morning
08:43 mberends O   AI
08:44 jnthn H H
08:45 mberends :)
08:45 jnthn Role composition is flattening by definition, which means that the semantics you get are essentially as if the methods had been defined in the class itself.
08:46 jnthn And what you're seeing is just the fall-out of that.
08:46 jnthn It's an interesting edge-case though.
08:49 rjc joined #perl6
08:52 moritz_ sombody should add jnthn's use.perl.org journal to plantetsix
08:53 jnthn It isn't on there already?
08:53 jnthn Wow. :-)
08:54 moritz_ speaking of blogs... is there still a rakudo.org blog somewhere? and if yes, is it in use?
08:56 Matt-W jnthn: hmm that's very surprising to me
08:56 Matt-W Well, I'm kind of surprised and also not surprised
08:57 moritz_ classes and inheritance have to be good for *something* :-)
08:57 jnthn Matt-W: I guess I can argue it both ways...
08:58 jnthn Matt-W: Think it's one to hand off to the language design side and I'll get Rakudo to do what comes back. :-)
08:58 Matt-W jnthn: I think you may be right
08:58 Matt-W use TimToady;
08:59 jnthn Indeed.
08:59 * Matt-W -> a meeting
08:59 * jnthn -> coffee machine
09:00 masak joined #perl6
09:00 mberends good $tea-time, masak
09:01 mberends seen Tene's blogserver?
09:01 masak mberends: I'm having a bit of an interesting experience recalibrating my sleep cycle...
09:01 masak mberends: no, I still need to backlog.
09:02 mberends heh
09:03 masak mberends: Tene msg'd me via zarah, saying that he did a blog app speed-run too. but he says 'remind me to post it somwhere', and that was 12 h ago.
09:04 * masak backlogs
09:04 mberends refactoring HTTP::Daemon is interesting... it gets so close to the Perl 5 original that I've written to Gisle Aas, developer of libwww-perl (LWP), about making a more complete Perl 6 version of the entire suite.
09:04 jferrero joined #perl6
09:05 masak sounds interesting indeed.
09:06 mberends Gisle also homes at Gitorious, which had some significant functionality upgrades in the weekend, with probable consequences for a few bits of proto.
09:11 moritz_ what's the advantage of gitorious over github?
09:11 * moritz_ curious
09:12 jnthn .oO( That gitorious rhymes with glorious? )
09:13 mberends moritz_: nothing significant, I myself became curious after mentions by ruoso++. There are a few more such sites, it seemed a good idea to let proto work with them all.
09:13 clintongormley joined #perl6
09:14 mberends down the line, my expectation is that CPAN will yield to DPAN (Distributed, Decentralised) and that involves spanning may repository environments.
09:14 masak DPAN++
09:14 moritz_ as long as it doesn't become DarkPAN
09:15 masak what is that, by the way?
09:15 mberends anything you make it ;)
09:15 moritz_ modules and scripts not hosted on CPAN, but floating around on the internet somewhere
09:16 masak ah.
09:16 masak well, technically we're already a part of that.
09:16 moritz_ because there's no cpan for Perl 6, right
09:17 mberends moritz_: yes, maintaining a catalog of what's OK (fsvo OK) is the DPAN challenge
09:17 moritz_ I had this idea of a Perl 6 CPAN that doesn't actually host the projects by default
09:18 moritz_ but rather checks out remote repos, renders the docs, indexes them etc.
09:18 mberends like Napster?
09:18 * moritz_ never used napster
09:18 masak mberends: I almost don't see how a catalog squares with the D in DPAN... I think we talked about that outside the mausoleum, though.
09:18 * mberends denies even knowing about napster
09:19 * masak didn't even hear the word napster
09:19 jnthn Wasn't that the thing we pirated music with last millenium?
09:19 mberends it never happened
09:19 masak nope.
09:21 mberends the DPAN idea is to link to remote repos, like moritz_ says, but also to avoid hijacking, trojans etc, hence a database for package search and authentication.
09:22 masak mberends: is the database centralized?
09:22 mberends no, decentralized like git repos.
09:22 Fuad joined #perl6
09:23 masak mberends: hm. I guess it's not worse than having an old mirror as the default mirror...
09:23 Fuad Hi folks
09:23 * mberends imagines tying it together with SHA string and perl6 glue
09:23 masak I mean, as long as the nodes update from each other frequently, we're fine.
09:23 masak Fuad: o/
09:23 moritz_ what's wrong with a centralized database?
09:24 moritz_ (as long as there can be many of them)
09:24 mberends Fuad: are you chatting on company time, you bad boy?
09:24 masak moritz_: was that a joke? :)
09:24 Fuad mberends:Hey:)
09:24 Fuad im at office now
09:25 Fuad today i havent much work,most of them i have already done
09:25 Fuad so decided join here
09:25 moritz_ mberends: not really
09:25 Fuad masak:howdy dude
09:26 masak Fuad: oh hai, dude.
09:26 * Fuad greets moritz_ and jnthn
09:26 masak &
09:27 mberends moritz_: there does need to be some central responsibility for package approval, so that perl users know they can trust the future installer utilities.
09:27 moritz_ mberends: agreed
09:28 mberends in addition though, peer-to-peer module publishing (semi DarkPAN) would useful to reduce bottlenecks.
09:28 wollmers joined #perl6
09:29 moritz_ we could add trust graphs like pgp
09:29 mberends why is there so little Rakudo software on CPAN?
09:29 mberends moritz_: yes, i like those schemes
09:30 moritz_ however it's much more complicated than current CPAN
09:34 Matt-W mberends: Because there's not much Rakudo software around?
09:34 moritz_ because CPAN is perl 5 only
09:35 Matt-W That too
09:45 masak mberends, moritz_, Matt-W: to be fair, szabgab did some experiments in putting Perl 6 software on CPAN. but I seem to recall it wasn't all that easy.
09:45 Matt-W I think CPAN for Perl 6 does need some different assumptions
09:46 masak "every complex system that works evolved from a simple system that worked."
09:47 masak I'm not sure I quoted that correctly. or who said it.
09:47 Matt-W I'm not sure that's necessarily true in all cases
09:47 Matt-W But it's probably true in the best cases
09:56 masak Matt-W: it's certainly true of living organisms.
10:01 masak oh! now that prefix:<=> is deprecated, do things like 'my $a =42' work again?
10:01 masak rakudo: my $a =42;
10:01 p6eval rakudo a27bbb:  ( no output )
10:02 masak rakudo: my $a =42; say $a;
10:02 p6eval rakudo a27bbb: OUTPUT«42␤»
10:02 masak \o/
10:02 jnthn Another nice fallout... :-)
10:04 LadyLuna1y joined #perl6
10:04 masak I see from the backlog that you successfully submitted rakudobugs without me. :)
10:07 Matt-W that's not a nice fallout
10:07 Matt-W can't be encouraging people not to put whitespace around their infix operators
10:08 masak Matt-W: ok, sir, your task when macros and grammar mods land is obviously to create an 'überstrict' module.
10:09 jnthn Matt-W: It's helpful for obsfucation. Duh!
10:09 jnthn ;-)
10:23 Matt-W Obfuscation is not helpful though
10:23 Matt-W masak: okay :)
10:24 Matt-W masak: Should write one that requires use of 'please' like INTERCAL, too
10:25 jnthn Matt-W: What, you mean http://www.jnthn.net/code/co06.pl has some issues?
10:25 masak oh, definitely.
10:28 masak jnthn: that's so... obfuscated.
10:28 masak joined #perl6
10:29 jnthn masak: It actually isn't all Perl though. It contains the bytecode for a small bytecode itnerpreter, written there inside the obsfucation, and an encoded strings heap too. The bytecode in there runs on the interpreter and outputs a Christmas caro.
10:29 jnthn *carol
10:30 masak ok, wow.
10:31 Matt-W that is
10:31 Matt-W well
10:32 Matt-W I don't know if I should admire that you can actually do something like that, or be horrified by its sheer denseness
10:32 Matt-W Ultimately I just look at it and feel stupid
10:33 jnthn Matt-W: I try and be a little less dense in my Rakudo commits. :-)
10:33 moritz_ having a syntax hilighter helps immensely when looking at such obfus
10:33 Matt-W I can appreciate obfus as an intellectual exercise
10:34 Matt-W I just don't do it :)
10:34 moritz_ the most interesting part seems to be the sub __ which is at the end of file
10:34 Matt-W jnthn: your rakudo commits are generally very readable :)
10:37 PhatEddy joined #perl6
10:41 donaldh joined #perl6
10:43 wollmers std: "a" . "b";
10:43 p6eval std 26766: OUTPUT«##### PARSE FAILED #####␤Obsolete use of . to concatenate strings; in Perl 6 please use ~ instead at /tmp/EtJUuAMIPP line 1:␤------> [32m"a" . [31m"b";[0m␤FAILED 00:04 35m␤»
10:43 wollmers std: "a"."b";
10:43 p6eval std 26766: OUTPUT«ok 00:04 35m␤»
10:43 wollmers std: "a" .= "b";
10:43 p6eval std 26766: OUTPUT«Potential difficulties:␤  Possible obsolete use of .= as append operator; in Perl 6 please use ~= instead at /tmp/6QCU4mfZtE line 1:␤------> [32m"a" .= [31m"b";[0m␤ok 00:04 36m␤»
10:44 moritz_ note that the alst one actually parsed, but emitted a warning
10:48 wollmers rakudo dies on all, but 'dies_ok "a"."b"' wouldn't be a reliable test.
10:48 masak you'd need dies_ok { "a"."b" }
10:49 moritz_ rakudo: use Test; plan 2; dies_ok { "a"."b" }; lives_ok { "a".codes }
10:49 p6eval rakudo a27bbb: OUTPUT«1..2␤ok 1 - ␤not ok 2 - ␤# Looks like you failed 1 tests of 2␤»
10:51 jnthn (.codes not implemented)
10:52 wollmers Method 'codes' not found for invocant of class 'Str'
10:52 moritz_ rakudo: use Test; plan 2; dies_ok { "a"."b" }; lives_ok { "a"."chars" }
10:52 p6eval rakudo a27bbb: OUTPUT«1..2␤ok 1 - ␤ok 2 - ␤»
10:52 moritz_ that's what I wanted to do :-)
10:52 Matt-W Oh so you can call methods using strings
10:52 moritz_ that's a pity, because current .chars is actually doing what .codes should
10:53 wollmers Graphemes still seem to be not implemented
10:53 masak http://perlmonks.org/?node_id=763217 # do contextual vars still have + as a twigil?
10:54 jnthn no, unified with globals
10:54 * masak thought so
10:54 masak sometimes the distributedness of various helpful Perl 6 documentation can be problematic.
10:54 jnthn moritz_: Really? Ouch. :-(
10:55 * jnthn still hasn't figured graphs into his mental model of how unicode works yet
10:55 moritz_ masak: already answered
10:55 pugs_svn r26767 | moritz++ | [docs] remove + twigil form Perl6::Perl5::Differences
10:55 moritz_ masak: and that doc lives in the pugs repo
10:55 masak moritz_++
10:55 masak moritz_: indeed.
10:58 wollmers jnthn: from my POV (point of view) it's unspecced what graphemes should be.
10:59 moritz_ wollmers: the Unicode people have a pretty good idea about that, and Tom Christiansen quoted that in a recent mail to p5p
10:59 moritz_ maybe rip that off for Perl 6 spec?
10:59 jnthn I only understand that chars and codes differ in that there exist codepoints that combine to make some characters, though I'm hazy on if that's the same concept I've heard of as "combinding characters".
11:00 * moritz_ should write up something about that
11:00 wollmers There is already a reference in Parrat to Unicode 'Grapheme Clusters'
11:00 wollmers *Parrot
11:01 * masak switches locations
11:01 wollmers moritz_: what's p5p? Link?
11:02 moritz_ wollmers: perl 5 porters, the perl 5 development mailing list
11:02 moritz_ http://www.perlfoundation.org/​perl5/index.cgi?perl5_porters
11:05 moritz_ http://groups.google.com/group/perl.perl5.porter​s/browse_thread/thread/4c04eb11c962e417/340a8657​cb52a9d7?lnk=gst&amp;q=tom+christiansen+unicode+\X#340a8657cb52a9d7 though it seems to be missing the first post
11:10 wollmers moritz_: Thx, but this is about 'width' (a Unicode property) which is different from length
11:12 moritz_ wollmers: \X is designed to match one grapheme (though poorly implemented)
11:12 moritz_ the question is if we want that same definition for Perl 6
11:14 wollmers http://docs.parrot.org/parrot/latest/​html/docs/pdds/pdd28_strings.pod.html -> Grapheme
11:14 frew|work joined #perl6
11:15 moritz_ that reads as if Parrot's Grapheme is the same as a Unicode grapheme cluster
11:17 wollmers http://unicode.org/reports/tr2​9/#Grapheme_Cluster_Boundaries
11:17 moritz_ and it would be *very* helpful if Perl 6 and Parrot could agree on what a Grapheme is
11:20 donaldh joined #perl6
11:22 masak joined #perl6
11:25 wollmers moritz_: Exactly.
11:28 eternaleye joined #perl6
11:29 meehav joined #perl6
11:29 amoc joined #perl6
11:35 LylePerl joined #perl6
11:36 kane_ joined #perl6
11:42 kane_ joined #perl6
11:42 * masak digs into P2T1A
11:43 masak there are 20 items there.
11:43 eternaleye joined #perl6
11:43 moritz_ and how many days to go?
11:43 masak if I spend 10 minutes on each, I can be done in 200 minutes.
11:43 masak moritz_: I think the 22nd was some kind of deadline.
11:43 masak (for me, that is.)
11:44 masak 200 minutes is too long a time for a hackathonic effort, I think.
11:44 masak I'll split the task in half and do one half today.
11:45 masak it's 13:45 now. I'll keep going until 15:15, and see how far I get. will try to break off each item after 10 minutes.
11:45 moritz_ masak++ # micro self-management
11:46 masak :)
11:51 pugs_svn r26768 | masak++ | [u4x] added Pair.pod
11:52 moritz_ that was before 13:55 - first success :-)
11:53 masak I'm ahead.
11:53 masak just encountered first dilemma, though.
11:53 masak do I put .subst in Str or in Any?
11:53 * masak goes with Any for now
11:54 moritz_ heh, Pair.pod was cheating
11:54 masak moritz_: I guess :)
11:55 masak it's all I feel I need right now.
11:55 masak I even listed all the methods. :)
11:55 Matt-W Oooh u4x
11:56 Matt-W Hmm
11:56 Matt-W I'm not sure about this Pod thing really
11:56 Matt-W Shouldn't u4x documentation be in a semantic format?
11:57 masak Matt-W: that's what I'm here to find out
11:57 moritz_ Pod is supposed to be semantic
11:57 moritz_ at least partially
11:57 moritz_ though we might have to augment it with additional meta data
11:57 masak I was hoping Pod could be sufficiently semantic for my purpoises.
11:57 masak moritz_: aye.
11:58 masak suggestions welcome, especially hypnotic suggestions.
11:58 Matt-W It seems to me that if we're documenting classes and methods then we should be able to say things like =class and =method
11:58 moritz_ Matt-W: that's actually a nice idea for Pod
11:58 moritz_ IMHO
11:59 moritz_ but it might come with problems...
11:59 * moritz_ will try to think a bit more about that later today
11:59 Matt-W I've been struggling with Pod in Form
12:00 Matt-W It's really no better than POD
12:00 Matt-W (for documenting an API)
12:01 moritz_ that's why we had that discussion about doc strings
12:01 Matt-W I wasn't aware of that
12:02 masak (discussion about doc strings)++
12:02 moritz_ http://www.nntp.perl.org/group/perl.​perl6.language/2009/05/msg31507.html
12:04 * Matt-W reads
12:07 pugs_svn r26769 | masak++ | [u4x] documentation for .subst
12:07 masak that was a tough one. didn't get full coverage, and I'm a bit behind now.
12:07 masak oh, feel free to fix my commits in any way you see fit.
12:07 masak there are no pumpkins involved at this stage.
12:09 Matt-W they all got made into pies
12:10 masak Matt-W: hah, bu tyou missed the proto pumpkin. it's right here on my desk. :)
12:10 masak s/bu t/but /
12:12 Matt-W I didn't say *I* did the pie-making
12:14 pugs_svn r26770 | masak++ | [u4x] added constants True and False
12:16 payload joined #perl6
12:18 aindilis joined #perl6
12:20 masak slurp has a parameter $enc with default "Unicode".
12:20 masak did we decide to say "Unicode" rather than "UTF-8"?
12:20 masak (the former isn't technically an encoding)
12:22 pugs_svn r26771 | masak++ | [u4x] added slurp
12:23 moritz_ masak: see S16 or S32-IO for what "Unicode" means
12:23 masak moritz_: I'll take that as a "yes".
12:23 masak don't have time to check right now. :)
12:23 moritz_ (ie guessing UTF-8/UTF-16{LE,BE} based on BOM)
12:24 masak aha.
12:26 pugs_svn r26772 | masak++ | [u4x] added length
12:36 pugs_svn r26773 | masak++ | [u4x] added if
12:39 pugs_svn r26774 | moritz++ | [S12] there's no .values method in Junction
12:44 pugs_svn r26775 | masak++ | [u4x] added subset
12:51 pugs_svn r26776 | masak++ | [u4x] added continue
12:55 masak When is using LAST { x() } not equivalent to just putting 'x()' after a loop?
12:56 Matt-W When you break out of a loop early and the LAST block doesn't execute? (guessing)
12:56 riffraff joined #perl6
12:57 masak Matt-W: I thought LAST blocks were called no matter the type of loop termination.
12:58 * masak thinks of a case where putting code after a loop isn't an option
12:58 masak let's see if someone else guesses it.
12:58 pugs_svn r26777 | masak++ | [u4x] added LAST
13:00 jnthn When you want to use what the loop evaluates to as the return value.
13:00 masak oh, nice one.
13:00 sylware joined #perl6
13:00 masak that was not the same as my (contrived) example.
13:01 Matt-W Also, I suppose, when you want the structure of the code to show clearly that something's going to run after the loop finishes, no matter what happens
13:01 sylware Hi, is there some doc on the C interface of embedded perl6?
13:02 masak Matt-W: aye, but then putting it afterwards is still an option.
13:02 pugs_svn r26778 | masak++ | [u4x] added $.
13:03 Matt-W masak: yes, but LAST {} has a nice 'I'm part of the loop' feel to it
13:03 jnthn sylware: For Rakudo, I think best is see docs for embedding Parrot.
13:03 jnthn sylware: And then after that you can load perl6.pbc through the Parrot embedding API.
13:04 nihiliad joined #perl6
13:04 jnthn And then shouldn't be too hard beyond there... Also see Inline::Rakudo on CPAN where somebody already did this, I think.
13:04 masak Matt-W: aye, your example is good; I should add something like that to the LAST documentation of u4x.
13:04 sylware jnthn: parrot callback (from perl6 code) are easy to deal with?
13:04 masak the hard part is thinking up good examples.
13:05 Matt-W yeah good examples are really hard
13:05 Matt-W my Perl 5 slides for work are full of total nonsense
13:05 Matt-W the object-oriented example is a monotonically-increasing counter
13:06 jnthn sylware: Not sure, I'm afraid...didn't try that.
13:06 Matt-W which I then provided a teaser implementation of in Perl 6 which fits easily on one slide, where the Perl 5 one certainly doesn't :)
13:06 jnthn sylware: There's a good chance I or others can help if you try and run into difficulties though.
13:07 sylware jnthn: well, I do not even know where to start...
13:08 pugs_svn r26779 | masak++ | [u4x] added the @ sigil
13:11 payload joined #perl6
13:12 * masak found moritz_++' C<^> twigil documentation
13:12 jnthn sylware: http://docs.parrot.org/parrot/l​atest/html/docs/embed.pod.html
13:13 pugs_svn r26780 | masak++ | [u4x] added ^ twigil
13:13 pugs_svn r26780 | masak++ |
13:13 pugs_svn r26780 | masak++ | Documentation stolen and adapted from syntactic-elements.pod by moritz++.
13:13 sylware jnthn: I'm currently reading it :)
13:14 masak I think I'll stop here. I've done 12 out of 20 items in 90 minutes.
13:14 masak the sprint has raised many questions that I think I'll turn to now.
13:15 masak moritz_: I really liked the line '=for STD twigil:sym<^>'
13:16 cognominal joined #perl6
13:19 sylware jnthn: ok, with parrot and perl6 code... how I would build a perl6 hash and pass it to some perl6 sub as an argument?
13:19 sylware (from C)
13:20 DietCoke joined #perl6
13:20 masak I think it'd be a good idea to structure the u4x docs after the STD grammatical categories: http://perlcabal.org/syn/S02​.html#Grammatical_Categories
13:20 DietCoke http://news.perlfoundation.org/2009/0​5/2009q2_grant_proposal_perl_6_p.html - there's a proposal for some perl6 documentation work that has no community feedback on it.
13:21 sylware jnthn: in theory, I should have a "formal" specification which maps perl6 date types to parrot data types
13:21 sylware do you know where I can find this?
13:22 jnthn sylware: I don't think that exists.
13:22 jnthn sylware: At least, I've never seen it.
13:22 sylware jnthn: it has to exist, since that defines the mapping perl6<->parrot.
13:23 jnthn You can probably construct a Parrot Hash PMC and pass that in.
13:23 jnthn Rakudo can probably handle that OK.
13:23 jnthn (And if not, it needs to learn how to, otherwse we'll have wider interop issues.)
13:24 nsh joined #perl6
13:25 sylware jnthn: yes, but the idea is to have the full blow written specs. Because I asked for a basic example, but at the end, it may require way more complexe data type, or even fiddling with perl context for a parrot callback.
13:26 sylware In order to build proper parrot structs to deal with perl6 code, I would need that mapping.
13:26 sylware I'm scared, that the answer would be, that specification is the code!
13:27 jnthn The answer is more that embedding Rakudo just hasn't been thought about that much yet.
13:27 TheActualCoke Are we talking about HLL interop!? oooh, goodie.
13:27 sylware jnthn: hu? Is this not a base requirement??
13:28 jnthn Yes, of course. So are many other things that haven't been worked out yet though. :-)
13:28 sylware (aka interop with "others" inside a process)
13:28 sylware jnthn: allright
13:28 jnthn Rakudo just isn't that complete yet, and there's been relatively little demand yet on the embedding front.
13:29 jnthn I think Inline::Rakudo on CPAN probably has got furthest down this road.
13:30 donaldh left #perl6
13:30 masak @seen lichtkind
13:30 lambdabot I saw lichtkind leaving #perl6 7m 13d 13h 2m 29s ago, and .
13:31 TheActualCoke and then?
13:31 sylware jnthn: ok. Since parrot 1 is out and perl6 specs quite stable we could expect a mapping (or even an C API) very soon (cannot use duke nukem forever analogy :) )
13:33 sylware (I understand that a C API specific for each languages supported by parrot would be the cleanest option. But waiting, a formal and updated document about that "mapping" would suffice for while
13:35 jnthn Depends what you mean by very soon...and also if there's someone motivated to work on this very soon.
13:35 donaldh joined #perl6
13:36 PerlJam sylware: whyfor do you ask?  Do you have some project where you would like to mix languages in this manner?  Maybe you could start on the specs.
13:36 mizioumt joined #perl6
13:36 jnthn Indeed, the specs will likely come as a result of someone who wants to embed helping to create them...
13:37 jnthn Or they will happen sooner if someone makes a start and then solicits input.
13:37 PerlJam yep.
13:39 sylware Well, the idea is to make many coders working in the same process, since they would use different languages, VMs (actually the one they like). The only requirement would be to interoperate with the other, the least common factor being C.
13:39 kimtaro joined #perl6
13:42 TheActualCoke sylware: C+PIR
13:42 sylware TheActualCoke: PIR?
13:42 TheActualCoke the assembly language parrot uses.
13:44 Tene masak: bin/omgblog.pl in web
13:44 masak Tene++
13:44 Tene 20 minutes at the airport before my flight.  I was surprised.
13:44 TheActualCoke http://docs.parrot.org/parrot/latest/html/​docs/pdds/draft/pdd31_hll_interop.pod.html
13:44 sylware TheActualCoke: perl6<->PIR would be reasonable as interop with C
13:44 sylware ?
13:45 sylware TheActualCoke: ok, having a look at the doc...
13:45 masak Tene: me too! it looks like more than 20 minutes of code.
13:45 masak but maybe you write faster than I do.
13:45 Tene jnthn: I ran into an awkward bug last night...
13:46 PerlJam masak: It probably helps if you already have a design in your head and all writing is "only" implementation  :)
13:46 Tene although... lemme check...
13:46 TheActualCoke sylware: for the most part, though dynamic opcodes and PMCs make it possible to invoke C.
13:46 masak PerlJam: true.
13:46 masak LolDispatch++
13:47 masak it makes perfect sense that a blog that uses LolDispatch is called OmgBlog :)
13:48 sylware TheActualCoke: actually since C is the father of All... the glue between languages and VMs, would be C. Then I looking more to a C written orchestra lead, then C calling perl6/parrot code instead of the opposit
13:49 PerlJam masak: you wrote Tags.pm right?
13:49 masak PerlJam: no, Tene++ did.
13:49 PerlJam ah.
13:49 TheActualCoke VMs /multiple/ ?
13:50 TheActualCoke if this not just a parrot thing, then I can't help. =-)
13:50 PerlJam Tene: then I've been meaning to ask you a question ...  why?  :-)  I mean, I can think of some reasons myself, but I want "the original" reasons.
13:50 Tene PerlJam: why what?
13:50 PerlJam Tene: Why write Tags.pm?
13:50 sylware TheActualCoke: multiple, meaning parrot VMs and "others".
13:50 Tene PerlJam: because I wanted to use it.
13:51 sylware (in order to please all our coders :) )
13:51 Tene I'm not sure I get the question.  Still waking up.  :)
13:51 jnthn Tene: Bug being? (will be able to focus on Rakudo stuff in ~ 10-15 minutes)
13:51 masak Tene: speaking of Tags.pm: when I do 'say show { html }', I get '<html/>', but when I do 'say show { html {} }'. bug or feature?
13:52 masak oops, in the latter case I get '<html'.
13:52 TheActualCoke sylware: ok. that document is a first pass at interoperation in a single parrot interpreter.
13:52 Tene jnthn: I used a sub trait handler to stuff a block into an array.  When I then tried to return something from the block, it crashes parrot because of the signature typechecking on the end of the block.
13:52 PerlJam Tene: okay, longer story ... one of the things that bugs me about RoR is how everything is shoehorned into ruby; you want to do some javascript, write some ruby instead; you want do templating, write some ruby instead; etc.   Tags.pm struck me as heading that way for perl6 as wel.
13:53 Tene masak: bug.
13:53 PerlJam Tene: I'm just wondering why you would choose to replace html with perl
13:53 * masak submits it as an issue in github/web
13:53 pmurias joined #perl6
13:53 Tene PerlJam: Because I'm much more comfortable with perl, especially for small tasks.
13:54 sylware TheActualCoke: I see that... the thing is "that biding" document should be extended to deal also with "things" ouside a parrot VM.
13:54 sylware TheActualCoke: but that is the start of the road
13:54 sylware (looooooong)
13:55 Tene The target audience of Tags is a small (maybe single person) team, all who use perl.  It's internded to be an alternative, not a mandatory or exclusive choice.
13:55 TheActualCoke sylware: from parrot's perspective, that's probably the embedding API.
13:55 TheActualCoke http://docs.parrot.org/parrot/latest/html​/docs/pdds/draft/pdd10_embedding.pod.html
13:56 Tene PerlJam: Also, writing perl instead of javascript can have some significant advantages.  Jifty, for example, does that, and they're able to to automatically detect capabilities of the client, and render in place with AJAX if the client supports it, or fall back to an HTTP refresh if the clien thas javascript disabled or doesn't support it.
13:56 Tene for example.
13:56 TheActualCoke (also http://docs.parrot.org/parrot/latest/html/​docs/pdds/draft/pdd11_extending.pod.html)
13:57 Tene You can use all of the fancy javascript magic, and still be confident that your page will render in elinks, or on a mobile browser without javascript.
13:57 PerlJam Tene: okay ... curiousity satisfied  :)
13:57 Tene :)
13:57 Tene But, mostly, because I wanted to use it personally.
13:58 PerlJam Tene++ -- scratching itches    :-)
13:58 Tene Because when I'm writing a little bit of code, I'd much rather deal with perl instead of some awkward showhorned template language.
13:59 Tene When I want to iterate over some data structure to generate a list, I don't want to manually concatenate strings, or interpolate a ton of generated variables into inline text.
13:59 Tene ul { for 1..10 { li :id<$_> "item $_" } }
13:59 sylware TheActualCoke: yes, that's the thing for parrot. But if you add the langage semantic (for instance perl context etc...), you would need specs which define perl semantic mapping to parrot embedded interface.
14:00 Tene It's hardly appropriate for a larger situation where you need templates, etc. for most companies.
14:00 Tene Your designer likely doesn't speak perl, but many do speak template languages.
14:00 PacoLinux joined #perl6
14:01 Tene It's also a response to restricted, limited template languages, like django's.
14:02 Tene Django's template language frustrates me every time I use it.
14:02 masak Tene: the thing that most often bites me in Tags is putting commas in the right places, like after named pairs. but I guess that's Perl 6's fault, not yours. :)
14:02 Tene ... i can stop speaking now.  You said it was answered.  :)
14:02 nsh- joined #perl6
14:02 Tene yes, that bites me in several places in Perl 6.
14:03 PerlJam me too (though I always chalked it up to how infrequently I write perl 6)
14:03 masak for some reason, I expect named params not to need commas.
14:04 masak I don't know why.
14:04 Tene well, because they look clearly delimited already
14:04 moritz_ because they're not a list, in the usual sense
14:04 masak hm. perhaps.
14:05 Tene std: foo( :a<1> :b<2> )
14:05 p6eval std 26780: OUTPUT«Undeclared routine:␤   foo used at 1 ␤ok 00:02 35m␤»
14:05 masak I wonder if it'd be possible to modify the Perl 6 grammar not to need commas before/after named arguments...
14:05 masak std: sub foo() {}; foo( :a<1> :b<2> )
14:05 p6eval std 26780: OUTPUT«ok 00:02 36m␤»
14:05 masak that's... odd.
14:05 Tene important to separate them from positionals, because look at:
14:05 moritz_ it might be parsed as an adverb to the <1> subscript
14:05 Tene foo(1..10 :by<2>)
14:05 Tene foo(1..10, :by<2>)
14:05 moritz_ (the second one)
14:06 moritz_ what Tene said
14:06 masak rakudo: sub foo() {}; foo( :a<1> :b<2> )
14:06 p6eval rakudo a27bbb: OUTPUT«Statement not terminated properly at line 1, near "( :a<1> :b"␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
14:06 * masak submits rakudobug
14:06 masak ...which might as well be a STD-bug, mind you.
14:06 moritz_ masak: I don't think it's a bug
14:06 masak it's a bug somewhere.
14:06 moritz_ masak: it might just by not-yet-implemented adverbs in rakudo
14:06 moritz_ masak: for which we already have a ticket
14:06 masak oh.
14:07 masak hrm.
14:07 Tene okay, srsly, need to get to work.
14:07 * masak wonders what the STD expression deparses to
14:07 Tene have fun today guys.  seeya
14:07 jnthn Tene: Catch me later with a code example of the problem you ran into.
14:07 masak Tene: will you blog about your ombblog thing?
14:08 ruoso joined #perl6
14:08 jnthn sylware: Parrot's language inter-op is more about ability to do certain operations than it is about mappings of one type to another.
14:09 Tene masak: yes
14:09 masak excellent.
14:09 ruoso Hello!
14:09 jnthn hi ruoso
14:09 * ruoso back after a long and deserved weekend
14:10 jnthn :-)
14:10 ruoso do we have context variables already ;) ?
14:10 sylware jnthn: http://docs.parrot.org/parrot/latest/html​/docs/pdds/draft/pdd10_embedding.pod.html missing the HLL semantics mapping
14:10 sylware to parrot embedded API
14:10 pmurias ruoso: hi
14:10 Tene jnthn: paste coming up...
14:10 ruoso hi pmurias
14:11 Tene jnthn: also, this is a very very low priority.  I can work around it by using implicit return.
14:11 jnthn Tene: Sure, but I'm interested to see what it is.
14:11 jnthn sylware: What do you mean by "HLL semantics mapping"?
14:12 pmurias ruoso: p6opaque is sort of working
14:13 ruoso cool
14:14 Tene jnthn: http://gist.github.com/109986
14:14 pmurias ruoso: how should we deal with a test which hangs?
14:14 sylware jnthn: HLL (High Level Language) running on parrot have different semantics (i.e. perl context would not exist in other high level langage), but code from an embedded perspective would call parrot code and configure the call to fit the semantics of the called parrot HLL.
14:15 Tene jnthn: be warned that ever since we added .annotate lines to --target=pir, the PIR line number reported will be a lie.
14:16 ruoso pmurias, what do you mean by "hangs"?
14:16 pmurias loops infitely
14:17 ruoso well... we could have a timer when running the tests
14:17 jnthn sylware: One of the aims of Parrot is that there's a common set of calling conventions, so you shouldn't need to "configure the call", as it were.
14:17 jnthn Not quite sure what you mean by "perl context" either.
14:17 jnthn Tene: thanks
14:18 * masak submits rakuodbug
14:18 Tene jnthn: he means want()
14:18 kimtaro_ joined #perl6
14:19 jnthn Oh. There Is No want(). :-)
14:19 sylware jnthn: for instance, I call a perl sub which behave differently in scalar context than in list context , I should from an embedded point of view be able to call that sub in the expected context.
14:19 pmurias ruoso: going through failing tests and fixing them is what i should be doing?
14:19 jnthn Well, it's probably dead anyways...
14:20 TheActualCoke left #perl6
14:20 ruoso pmurias, do we have prototypehow already?
14:20 masak sylware: we should have an FAQ for this one. :)
14:20 pmurias ruoso: yes
14:20 masak sylware: we decided to scrap want() in Perl 6 because (a) nobody knows quite how to implement it, and (b) there are other, saner means of doing it in Perl 6.
14:20 pmurias you can look at make test in re-mildew to see what's working
14:20 jnthn masak: You just put what I was going to say but better. :-)
14:21 ruoso pmurias, cool... so I think it's just making all tests to work
14:21 masak sylware: for example, you could equip the returned value with the appropriate conversion methods to List, Item, Bool etc.
14:21 jnthn ruoso: (just making all the tests work) we're working on that issue in Rakudo too. ;-)
14:21 ruoso heh
14:21 sylware masak: well, I could? How do I know how the perl6 stuff is mapped to parrot stuff?
14:22 ruoso pmichaud, btw... were you able to make contextual variables work?
14:22 masak sylware: that's an open-ended question.
14:22 masak sylware: maybe read Rakudo source?
14:22 sylware :D
14:22 sylware As I said, it's exactly what I was scared of...
14:23 jnthn It's not only open ended, but we also don't actually know all of the answers yet.
14:23 sylware It has to exists a biding document between an HLL semantics with parrot embedded API
14:23 PerlJam sylware: why scared?  Until someone actually *needs* it, there's no point in speccing the thing.
14:24 PerlJam otherwise you spec to imagined requirements rather than actual ones.
14:24 pmurias sylware: parrots source is well documented
14:24 sylware That's not the issue
14:24 ruoso pmurias, I think you forgot to add prototypehow to svn
14:26 jnthn OK...Rakudo time! :-)
14:26 * jnthn creates a branch so he can start breaking stuff
14:26 skids joined #perl6
14:26 pugs_svn r26781 | pmurias++ | [re-smop] p6opaque is registered in lexical prelude
14:26 pugs_svn r26781 | pmurias++ | in the RI DSL the init section is after the prototypes are created
14:26 PerlJam jnthn: what, in particular, are you going to break today?
14:27 pugs_svn r26782 | pmurias++ | [re-smop] the prototype RI delegates ^!CREATE
14:27 pugs_svn r26783 | pmurias++ | fix bug in accessors
14:27 pugs_svn r26784 | pmurias++ | minor cleanup
14:27 jnthn PerlJam: .wrap and .unwrap
14:27 PerlJam jnthn: cool.
14:27 ruoso pmurias, hmmm where is PrototypeHOW?
14:27 pugs_svn r26785 | pmurias++ | [re-smop] ported over PrototypeHOW, fixed some leftovers in p6opaque
14:27 pugs_svn r26786 | pmurias++ | [re-mildew] fixed test
14:27 ruoso ah
14:27 ruoso ;)
14:27 jnthn PerlJam: I need to refactor how callnext etc work.
14:27 pmurias ruoso: forgot to git-svn dcommit
14:28 sylware pmurias: The issue is the existence of a "close" to formal document which maps HLL semantics to parrot embedded API. For instance, specs of perl6 semantics mapping to parrot embedded API.
14:28 jnthn PerlJam: And get it working with the candidate-listy object case.
14:28 jnthn And then re-work wrap and un-wrap to work the same way.
14:29 ruoso pmurias, hmm... pureprototypehow shouldn't be inside p6opaque module...
14:29 [particle]1 joined #perl6
14:29 pmurias ruoso: where should it live?
14:29 ruoso pmurias, in the OO module
14:29 sylware pmurias: then you would have the same document for each of http://www.parrot.org/languages
14:29 ruoso because it doesn't really depend on the p6opaque
14:30 ruoso other RI could use prototypehow
14:30 moritz_ rakudo: sub a($x) { say "1: $x}; &a.wrap(s{ay "2"; nextsame}); a(3)
14:30 p6eval rakudo a27bbb: OUTPUT«say requires an argument at line 1, near " \"1: $x}; "␤␤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)␤»
14:30 moritz_ rakudo: sub a($x) { say "1: $x" }; &a.wrap({say "2"; nextsame}); a(3)
14:30 p6eval rakudo a27bbb: OUTPUT«2␤Could not find non-existent sub nextsame␤current instr.: '_block39' pc 354 (EVAL_17:149)␤»
14:30 moritz_ rakudo: sub a($x) { say "1: $x" }; &a.wrap({say "2"; nextwith(4)}); a(3)
14:30 p6eval rakudo a27bbb: OUTPUT«2␤Could not find non-existent sub nextwith␤current instr.: '_block39' pc 361 (EVAL_17:151)␤»
14:30 jnthn moritz_: Ah, it's only callsame and callwith that are done, I think.
14:31 moritz_ rakudo: sub a($x) { say "1: $x" }; &a.wrap({say "2"; callwith(4)}); a(3)
14:31 p6eval rakudo a27bbb: OUTPUT«2␤1: 4␤»
14:31 moritz_ rakudo: sub a($x) { say "1: $x" }; &a.wrap({say "2: $x"; callwith(4)}); a(3)
14:31 p6eval rakudo a27bbb: OUTPUT«Scope not found for PAST::Var '$x' in ␤current instr.: 'parrot;PCT;HLLCompiler;panic' pc 146 (src/PCT/HLLCompiler.pir:105)␤»
14:31 pmurias sylware: i'm not a parrot guy
14:31 moritz_ rakudo: sub a($x) { say "1: $x" }; &a.wrap(-> $x {say "2: $x"; callwith(4)}); a(3)
14:31 p6eval rakudo a27bbb: OUTPUT«2: 3␤1: 4␤»
14:31 pmurias and the smop embedding api is likely to be hugely different from the parrot one
14:32 AzureStone joined #perl6
14:33 jnthn sylware: I would individual languages will end up with a "how to embed this language" document with comments specific to that language, yes.
14:33 jnthn *I would imagine...
14:33 moritz_ sylware: for more parrot guys try #parrot on irc.perl.org
14:34 sylware jnthn: yes, that is the goal
14:34 sylware jnthn: thx
14:34 rjc joined #perl6
14:34 jnthn sylware: However it's going to essentially be built on top of the Parrot embedding API, and I'd hope embedding different languages didn't end up looking so different.
14:35 sylware jnthn: just a matter of semantics generalization
14:36 sylware jnthn: we may be able to factor out some semantics mapping to parrot embedded API.
14:36 sylware jnthn: A HLL implementation should not be allowed to be told "ready" if such a document does not exist.
14:37 * sylware is being too despotic... sorry
14:37 moritz_ we can't tell implementations what they call themselves
14:37 jnthn sylware: Heh. Rakudo is a long way from claiming readiness for embedding. :-)
14:37 moritz_ parrot is free software
14:37 jnthn Even though it's been done to some degree...
14:38 PerlJam sylware: again, *need* must come first.  It's perfectly fine for implementations to omit things that aren't needed and still be ready for general use.
14:38 jnthn Well, depending on how you define "long" anyway.
14:39 PerlJam and "embedding"  :)
14:39 jnthn Aye.
14:39 sylware PerlJam: I defined the use case above
14:39 moritz_ and "general". and "fine".
14:40 jnthn Even when we hit a point where Rakudo in terms of implementing Perl 6 is pretty decent, there's very possibly going to be a bunch of extra tasks we need to do for improving interoperability with other languages on Parrot.
14:40 PerlJam sylware: coming up with a use case doesn't establish need.  People actually trying to do it does  :)
14:40 sylware PerlJam: interop in a process with "others", with probably C glue
14:40 pmurias doing interop between parrot language via C doesn't seem a sane idea
14:42 moritz_ sanity is overrated :-)
14:42 sylware pmurias: the other only options would need a language/VM independant middleware for that
14:42 sylware Since the father of all is C.
14:42 masak I had a thought the other day. I'm not sure a 6.0.0 release would benefit the Perl 6 community.
14:43 moritz_ keep it forever alpha?
14:43 masak something like that.
14:43 PerlJam masak: why?
14:43 ruoso sylware, Parrot will probably interoperate languages, not runtiems
14:44 ruoso it seems you're trying to interoperate runtimes
14:44 sylware yes.
14:44 moritz_ masak: that depends on what your goals for Perl 6 are
14:44 alester joined #perl6
14:44 ruoso that's not the regular plan in Parrot
14:44 ruoso sylware, usually you want to reimplement the language as a parrot HL
14:44 ruoso HLL
14:44 masak PerlJam: for one thing, it'd keep away two kinds of people: (1) those who complain about it taking so long to be released, (2) those who had certain expectations for the release, and might see them not coming to be.
14:44 moritz_ masak: to gain many (module) contributers, it needs some publicity
14:44 sylware Because, my pythons coders will use their VM, perl5 coders the libperl, perl6... parrot, C coders, C etc etc...
14:45 masak moritz_: we can keep releasing better and better Rakudo releases.
14:45 sylware lua squirrel etc etc...
14:45 sylware (even java)
14:45 sylware (different java VMs)
14:45 moritz_ masak: aye, but there won't be any corporate adoptions without something declared "stable", and that's where the big bugs are
14:45 pmurias sylware: interop between parrot languages and parrot and other VM is a different thing
14:46 masak moritz_: you're probably right.
14:46 ruoso sylware, that is the SMOP vision of interoperability, not parrots
14:46 sylware pmurias: Well I was talking about the "grand" interop in a process.
14:46 sylware ruoso: what is SMOP?
14:46 PerlJam moritz_: "big bugs?"  some kind of freudian slip there?  :-)
14:47 moritz_ masak: but I see your point
14:47 ruoso smop is an alternative runtime implementation for Perl 6
14:47 moritz_ PerlJam: :-)
14:47 moritz_ in Franconia we pronounce ck and g very similar
14:47 ruoso sylware, http://www.perlfoundation.org/perl6/index.cgi?smop
14:47 moritz_ likewise d and t
14:47 PerlJam sure. sure.  I believe you  ;)
14:47 sylware ruoso: so how the perl6 smop code will interoperate with perl6 parrot code?
14:48 pmurias transparently :)
14:48 ruoso sylware, Perl 6 is a spec
14:48 PerlJam ruoso: yeah!  how will it work? Tell me the future!  ;)
14:48 ruoso Parrot has one Perl 6 implementation, which is rakudo
14:48 ruoso SMOP has another, which is mildew
14:48 ruoso Perl 6 code should be able to run in both runtimes
14:48 pmichaud Good morning, #perl6
14:48 masak pmichaud: o/
14:49 ruoso good morning, pmichaud
14:49 jnthn morning, pmichaud
14:49 pmichaud (backlogging)
14:49 PerlJam greets pm
14:49 ruoso the major difference in terms of major view over things between Parrot and SMOP is that Parrot is going to interoperate languages on top of the same VM
14:49 ruoso and SMOP tries to interoperate runtimes
14:50 sylware ruoso: ok then, if I want perl6 coders interoperate with other things in the same process, they will have to use the SMOP implementation
14:50 sylware ?
14:51 ruoso if you mean different runtimes, SMOP targets that
14:51 pmurias shopping&
14:51 ruoso parrot is a VM that tries to replace the native runtime of the foreign languages
14:51 ruoso which is something very common this days...
14:52 ruoso i.e. ironpython... jruby... etc
14:52 sylware ruoso: So embeded smop maps the semantics of perl6 to a C API?
14:52 ruoso sylware, yes
14:52 sylware Has SMOP other language implementation than perl6?
14:53 pmurias sylware: smop has initial perl5 interop
14:54 sylware SMOP seems more promising than parrot for the embedded world then.
14:55 ruoso depends what you want to do, I guess...
14:55 sylware ruoso: see above
14:55 ruoso SMOP won't be able to implement ACL on memory access, for instance
14:55 pugs_svn r26787 | moritz++ | [u4x] small clarification in ambient-subs.pod
14:56 masak moritz_: thanks. fwiw, I think all those files will be restructured somehow. I just have to think about it a little first.
14:58 moritz_ masak: IMHO we need 1) files that explain syntax (including declarations, control flow etc), 2) built-ins (True, False, classes, subs) 3) glossary...
14:58 masak aye.
14:58 moritz_ and maybe separate docs that explain concepts (like Unicode level, scoping) and tutorials
14:58 pugs_svn r26788 | pmurias++ | [re-smop] moved prototypehow to s1p-oo
14:59 masak the structure should not only be logical for humans, but easily navigable for grok, as well.
14:59 masak moritz_: yes, TODO has a list of such separate docs.
14:59 moritz_ that's why I proposed it that way :-)
14:59 moritz_ talk &
14:59 pmichaud (context variables) -- not yet, will like do that shortly.  Ended up spending most of the day working on house and Mother's Day tasks.
15:06 fridim joined #perl6
15:18 exodist joined #perl6
15:20 donaldh joined #perl6
15:23 masak mberends: I'm thinking of implementing uninstall, so we can finally remove the 'not implemented below this point' message in the README. does this sound sane?: loop through all installed projects, checking whether any of them has a deps.proto file which lists the project to be uninstalled, and if so, halt.
15:26 mberends yes, under the current design 'uninstall' becomes rmdir. no recursion, definitely.
15:26 mberends dependency recursion, that is
15:27 masak thing is, I don't see that dependency recursion is needed in the uninstall case.
15:27 masak only direct dependencies matter anyway.
15:29 mberends in Debian, auto-installed dependencies are flagged as 'able to be deleted', because nothing else needs them. That's a bit tall for us, though.
15:29 masak aye. entia etc.
15:29 masak "it's just a model." :)
15:32 eternaleye joined #perl6
15:33 masak mberends: oh, it's slightly more involved than I though.
15:33 masak mberends: let's assume project A deps on project B. then I should be able to go './proto uninstall A B' without proto objecting.
15:34 masak i.e. it shouldn't iterate over those installed projects passed as to be uninstalled.
15:34 masak problem solved. :)
15:36 mberends :)
15:37 masak wow, this is quickly turning into Nice Method of the Day.
15:43 masak mberends: by the way, I can think of one WTOP that proto fails to live up to at present: it has a lib/ with .pm modules in it, but no build system. :)
15:43 masak (yes, I'm using the pumpkin)
15:46 Psyche^ joined #perl6
15:47 masak jnthn: actually, when a one-param method is called as a one-param sub, the error issued is not very clear: "too few arguments passed (1) - 2 params expected"
15:48 jnthn masak: The other param expected is self.
15:48 masak I know. :)
15:48 jnthn What would be a clearer message?
15:48 masak just saying that it doesn't exactly help in clarifying the sub/method thing.
15:48 masak a clearer message would be "did you mean to call this method with an invocant?:
15:48 masak s/:/"/
15:49 jnthn Hmm. Probably do-able-ish.
15:49 jnthn Though the error comes from Parrot rather than Rakudo, so hmm.
15:49 jnthn Maybe in some future sig-binding refactor we can improve it though.
15:49 masak on behalf of s1n, \o/
15:51 skids "too few arguments passed(1) - invocant and 1 other parameter expected"
15:52 masak better, if not ideal, IMO.
15:54 simcop2387-vnc joined #perl6
15:55 * skids ponders example code in S04 "lift" section
15:56 skids might be crufty
15:58 dalek rakudo: 526bf42 | pmichaud++ | docs/spectest-progress.csv:
15:58 dalek rakudo: spectest-progress.csv update: 387 files, 11180 passing, 0 failing
15:58 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/5​26bf427a060cb34616c5a3732b7b51eb54f18b0
15:59 jnthn If I have a branch locally, say named foo, and I want to push it onto github
15:59 jnthn Is it just git push origin branchname ?
15:59 jnthn er, s/branchname/foo/ :-)
15:59 jnthn or s/, say named foo,// ;-)
16:01 pmichaud git push origin foo   # I think.
16:01 masak rakudo: { say @_.perl }.(1,2,3)
16:01 pmichaud that sounds familiar to me, at any rate.
16:01 p6eval rakudo 526bf4: OUTPUT«[2, 3]␤»
16:02 masak could someone please clarify the above output for me? :)
16:02 jnthn Thank it's done the right thing
16:02 masak sure, but why?
16:02 pmichaud that's a bit underspecced.  But the 1 is going into $_.
16:02 jnthn masak: I was talking about my git push :-)
16:03 masak aha.
16:03 masak pmichaud: ok.
16:03 masak pmichaud: feels a bit... weird.
16:03 pmichaud masak: yes, but the counter-point (last it was discussed) is that there's not really a way to make a signature that dtrt
16:03 jnthn Aye, feels weird to me too...does @_ not imply a signature?
16:03 pmichaud sure, @_ implies a signature
16:03 pmichaud the signature of the block ends up being    -> $_, *@_ { ... }
16:04 pmichaud because blocks that don't have a signature end up with a $_
16:04 masak I see.
16:04 masak how would I specify a block with just -> *@_ ?
16:04 * masak thinks he just answered his own question
16:04 pmichaud -> *@_ { ... }
16:04 jnthn pmichaud: I can't quite tie those two together? "@_ implies a signature" but since it has a signature why is it ending up with $_ ?
16:05 pmichaud jnthn: what would you expect from:     { say .perl, @_.perl; }
16:05 khatar joined #perl6
16:05 pmichaud there's also related discussion last Friday about when @_ makes a signature
16:06 jnthn I kinda expected $_ would be not a parameter in that case since @_ implies a signature.
16:06 pmichaud we've recently decided to change the spec so that @_ generates a signature only when placeholders are present (or something like that)
16:06 pmichaud otherwise it's basically impossible for an inner block to ever access an outer @_
16:06 jnthn Oh, hmm. That is a problem.
16:06 jnthn Yeah, I hadn't thought of that one.
16:06 pmichaud (looking up #perl6 reference)
16:06 jnthn That's very ouch.
16:08 pmichaud http://irclog.perlgeek.de/​perl6/2009-05-06#i_1124322
16:09 pmichaud right.  @_ should only generate a slurpy when placeholders are present.
16:09 pmichaud (Currently we always do it.)
16:09 jnthn OK.
16:09 pmichaud I was going to fix that on Wednesday but had to do $otherjob stuff instead.
16:09 skids Weird that's almost the same issue I was looking at in S04 lift. (cue Twilight Zone music)
16:10 * jnthn has first cut of callwith() working that calls up the class hierarchy.
16:11 skids In the S04 there are named subs expecting to put a raw type in the Sig and get the value from it in $_
16:12 jnthn Well, calls over a candidate list in fact. :-)
16:13 * jnthn takes a break for a little bit
16:17 iblechbot joined #perl6
16:19 VX joined #perl6
16:19 pmichaud also icky:   { if 1 { say @_ };  say $^a; }     # which block gets the @_ ?
16:20 pmichaud I'm going to vote "neither" for now.
16:21 masak going swimming &
16:25 ruoso pmichaud, if is not a topicalizer, is it?\
16:25 ruoso I'd guess @_ is valid for the whole outer block
16:26 pmichaud sure, but detecting that situation is a pain.
16:26 pmichaud at the time that we process { say @_ }, we don't know if any of its outer blocks have placholders yet.
16:27 * ruoso considers this implicit @_ to be weird anyway
16:27 skids S04 has "multi infix:<eq> (Whatever, Any $b) { -> $a { lift $a eq $b } }"
16:28 pmichaud that looks like a typo to me.
16:28 pmichaud oh wait, it's not.
16:29 pmichaud But I don't see that the value is in $_
16:29 pmichaud the Whatever argument doesn't get bound to anything.
16:29 justatheory joined #perl6
16:29 skids That's what I thought, it looked wrong, and didn't work in rakudo either (with a normal sub name)
16:30 pmichaud 'lift' is unimplemented in rakudo right now.
16:30 skids Right but getting the Whatever value didn't work.
16:30 pmichaud how do you mean "getting the Whatever value didn't work"?
16:30 skids Wasn't anywhere
16:30 pmichaud It's not supposed to be.  As I said, it's unbound.
16:31 eternaleye joined #perl6
16:31 skids sub foo (Whatever, Str $a) { $_.say; @_.perl.say;}
16:31 pmichaud in that case, $_ is uninitialized.
16:31 skids Right, why I pointed that S04 section out.
16:31 ruoso pmichaud, one other issue I'd like to do for Faz would be to have custom package_declarators and routine_declarators
16:31 pmichaud I don't understand.
16:31 ruoso is that at all possible in rakudo today?
16:31 pmichaud ruoso: not yet, alas.
16:32 skids The examples in S04 would be wrong, then, correct?
16:32 pmichaud when we do more STD-like parsing, probably.
16:32 pmichaud skids: the examples in S04 are correct.  What you think they do isn't.
16:32 ruoso pmichaud, and the easiest way to work around would be... to write a translator from this DSL to Perl 6?
16:32 pmichaud (unless the example you just gave is from S04)
16:32 pmichaud ruoso: that'd be my guess at the moment.
16:32 skids The infix:<eq> example is
16:33 ruoso pmichaud, sorrry for being such a boring guy... but do you have any idea on how far we are from having the context variables working?
16:34 pmichaud ruoso: it's not too far, I just have to find ~2 uninterrupted hours.
16:34 ruoso cool
16:34 pmichaud (maybe less, ~2 is a conservative estimate)
16:34 * ruoso waiting for that to rewrite masak's Yarn using Faz
16:35 pmichaud skids:  the infix:<eq> example doesn't use $_
16:35 skids So it's returning a closure then?
16:35 pmichaud yes.
16:35 skids Ah, OK.  I thought it was evaluating in place.
16:35 pmichaud * eq 'foo'   would result in a closure.
16:36 skids BTW, other than parsing is anything blocking implementing ops in perl6?
16:37 pmichaud parsing is the big issue.
16:37 pmichaud other than that... I can't really think of anything.
16:37 pmichaud If we have
16:38 pmichaud my $x = -> { };   $x();    # what is the return value?  Nil?
16:41 * [particle]1 suspects Nil
16:43 TimToady @tell masak no, 'augment' only requires MONKEY_PATCHING when you're modifying something global, and a sublanguage is by definition lexically scoped
16:43 lambdabot Consider it noted.
16:44 kidd joined #perl6
16:45 payload joined #perl6
16:55 abra joined #perl6
16:59 jhorwitz joined #perl6
17:04 ilogger2 joined #perl6
17:11 payload1 joined #perl6
17:13 cdarroch joined #perl6
17:18 lichtkind joined #perl6
17:19 VX left #perl6
17:20 VX joined #perl6
17:23 justatheory Somebody check TimToady's forhead for imprints! http://james-iry.blogspot.com/2009/05/​brief-incomplete-and-mostly-wrong.html
17:24 lichtkind is there anybody who likes to be interviewed?
17:24 justatheory lichtkind: Don't ask questions.
17:25 Patterner Can I lie?
17:25 lichtkind justatheory: .... just do it?
17:26 justatheory /kick lichtkind
17:26 lichtkind i dont understand
17:26 justatheory That's the spirit!
17:26 * justatheory is feeling punky today
17:27 lichtkind justatheory: thats fine as long you can handle the feedback
17:33 jnthn hi lichtkind :-)
17:33 lichtkind jnthn: hello my victim :)
17:33 jnthn oh noes...what?!
17:34 lichtkind jnthn: just some question, if you bahve i release you soon :)
17:34 lichtkind jnthn: how is rakudo?
17:34 Eevee justatheory: ha, love the description of C#
17:34 [particle]- rakudo is dead. long live pugs!
17:35 jnthn OK but no questions about the incident involving the bacon and the plastic explosive...
17:35 Eevee or C♯
17:35 justatheory Eevee: yah
17:35 lichtkind jnthn: i don't get this joke but it makes me curious
17:35 jnthn lichtkind: Rakudo is coming along nicely.
17:36 jnthn lichtkind: Don't think the next release will gain as many passing tests as the last one, but that was kinda hard to beat. :-)
17:36 rjc joined #perl6
17:36 lichtkind jnthn: im finishing my tutorial now and moritz_++ had a tutorial on german leading CS magazine, there was perl 6 on the front page :)
17:37 jnthn Yes, I saw this magazine - somebody at Vienna.pm showed me.
17:37 jnthn Exciting!
17:37 lichtkind yes
17:38 mizioumt1 joined #perl6
17:43 mizioumt2 joined #perl6
17:44 lichtkind jnthn: do we see each other in lissabon?
17:44 jnthn lichtkind: I'll be there. Will you?
17:45 lichtkind jnthn: i confirmed my accepted talk so i better will be there
17:46 jnthn nice :-)
17:49 lichtkind jnthn: its completely not about perl :)
17:52 ruoso @tell pmurias I solved the infinite loops in the tests... I guess we are really close to have everything working...
17:52 lambdabot Consider it noted.
17:54 pugs_svn r26789 | ruoso++ | [mildew] t/recursion.t passes... the test was wrong, actually..
17:55 payload joined #perl6
17:56 Fuad joined #perl6
17:57 pugs_svn r26790 | wollmers++ | [t/spec] added tests
17:57 lichtkind ruoso: ping?
17:57 ruoso lichtkind, pong!
17:57 frodwith joined #perl6
17:58 mikehh joined #perl6
18:09 LadyLuna1y joined #perl6
18:10 Fuad left #perl6
18:22 ejs joined #perl6
18:24 pyrimidine joined #perl6
18:29 japhb joined #perl6
18:35 payload1 joined #perl6
18:35 M_o_C joined #perl6
18:38 d joined #Perl6
18:42 skids rakudo: my $a; my sub f () { return { $^a; "OH NOES".say } }; $a = f(); $a.perl.say; $a(1).say
18:42 p6eval rakudo 526bf4: OUTPUT«{ ... }␤OH NOES␤1␤»
18:43 skids rakudo: my $a; my sub f () { { $^a; "OH NOES".say } }; $a = f(); $a.perl.say; $a(1).say
18:43 p6eval rakudo 526bf4: OUTPUT«too few arguments passed (0) - 1 params expected␤current instr.: '_block27' pc 310 (EVAL_21:125)␤»
18:46 H1N1[S] joined #Perl6
18:58 stepnem joined #perl6
18:58 aindilis joined #perl6
19:00 * jnthn back from nom
19:01 nemstep left #perl6
19:19 pugs_svn r26791 | ruoso++ | [mildew] one more sanity test pass...
19:21 donaldh joined #perl6
19:23 bbkr joined #perl6
19:24 simcop2387 joined #perl6
19:24 bbkr hi. does rakudo has something like Test::Simple already available or do i have to write my own?
19:26 mberends bbkr: the Test.pm in the Rakudo root directory is fine for most testing.
19:27 mberends it's more than just Simple :)
19:27 TimToady hmm, thinking about testing syntax, without going the whole :ok<message> route, we could, with currently defined syntax, say:
19:27 lambdabot TimToady: You have 1 new message. '/msg lambdabot @messages' to read it.
19:27 TimToady OK $foo, &[==], $bar, "message";
19:28 bbkr mberends: indeed, thanks
19:28 TimToady @messages
19:28 lambdabot literal said 1d 8h 2m 48s ago: STD.pm line 2234 doesn't make much sense. $> == $() ?
19:28 TimToady @clear
19:28 lambdabot Messages cleared.
19:28 TimToady literal: yes, that was a copy/paste error
19:32 [particle]- TimToady: last friday, you added "+        token backslash:std<\Y> { YY };" to S02
19:33 [particle]- i expected to see backslash:sym<Y>
19:33 [particle]- am i missing something?
19:37 TimToady no
19:37 TimToady feel free to fix
19:40 jnthn Appears t\spec\S02-magicals\env.t is epic fail on Win32. :-(
19:40 jnthn '.' is not recognized as an internal or external command,
19:44 bbkr I just started to play with grammars. the following example is not working, what am i doing wrong here? ./perl6 -e 'grammar X { token TOP { .* } }; print "abc" ~~ X;'
19:44 jnthn bbkr: That does a type check.
19:44 jnthn bbkr: You probably want .parse
19:45 jnthn rakudo: grammar X { token TOP { .* } }; print X.parse("abc")
19:45 p6eval rakudo 526bf4: OUTPUT«abc»
19:45 bbkr i'm using http://perlgeek.de/blog-en/perl-​5-to-6/20-a-grammar-for-xml.html as a tutorial.
19:45 jnthn Ah, OK. The ~~ X syntax is out of date by some months, I'm afraid.
19:45 bbkr .parse works, thanks
19:45 [particle]- .* isn't going to work well on a token, no backtracking
19:46 [particle]- s/on/in/
19:46 jnthn moritz_: See above, maybe you'd be able to update. :-)
19:55 pugs_svn r26792 | wollmers++ | [t/spec] added tests
19:57 minazo joined #perl6
20:00 simcop2387-vnc joined #perl6
20:02 bbkr ok, I have my simple grammar ready. but i noticed something like that: token x { aaa { say "I captured aaa" } } is not parsing. is this correct way to execute some code on token match?
20:02 jnthn bbkr: It's correct Perl 6, but not yet supported in Rakudo.
20:02 bbkr S05 says {} is used to execute code inside regexps
20:02 bbkr ah, ok. thanks
20:03 jnthn bbkr: One possible option is to associate an actions class with the grammar.
20:03 bbkr any example how to do that?
20:03 jnthn That is, a class whose method names match your token/rule/regex names. And then just put {*} in the regex where you want to call said method.
20:03 jnthn Surely somewhere though I can't think off one off the top of my head...
20:04 jnthn bbkr: ah, found one
20:04 jnthn http://alledora.co.uk/wordpr​ess/archives/2009/03/23/377
20:04 jnthn Looks like a good write-up
20:04 bbkr BTW: P6 grammar is lovely :) i wrote huge project in EYapp and it was messy when project grew up. grammars in P6 are just the solution :)
20:05 jnthn Note that it uses parsefile instead of parse, but you should be able to use .parse just fine.
20:05 bbkr just what i needed. thanks.
20:09 * jnthn settles down to re-write .wrap and .unwrap
20:09 pugs_svn r26793 | wollmers++ | [t/spec] added grapheme tests
20:12 pmichaud jnthn: ping
20:13 jnthn pmichaud: pong
20:13 jnthn pmichaud: if it's not about wrap/unwrap, can you ask me in 10 mins? I'd really like to get this code down while it's in my head...
20:13 pmichaud it can wait
20:13 jnthn thanks
20:14 pmichaud I think I know the answer anyway.
20:20 jnthn pmichaud: OK, now is fine. Just wanted to write the implementation while it made sense to me. :-)
20:21 pmichaud in actions.pm,  type_declarator makes a call to '.ACCEPTS'   while make_anon_subtype calls 'infix:~~'.  Is there a reason for them being different?
20:21 pmichaud (I think the answer is 'no')
20:22 jnthn No.
20:22 pmichaud okay.
20:22 jnthn Probably do ACCEPTS for both.
20:22 pmichaud I've refactored them into one.
20:22 jnthn It saves a dispatch.
20:22 pmichaud Because otherwise the two are largely identical.
20:22 jnthn That's fine. :-)
20:22 pmichaud I'm doing a couple of other refactors so that I can get @_ and %_ working properly.
20:22 jnthn OK. So long as nothing breaks, it's all good. :-)
20:22 pmichaud also eliminating about 50-60 lines of code in the process. :-)
20:24 jnthn pmichaud++
20:24 jnthn No doubt improving mantainability too.
20:25 jnthn I've got some diffs in a branch but I don't think they'll conflict with anything you're touching.
20:27 * moritz_ updates the blog
20:27 jnthn moritz++
20:38 lichtkind joined #perl6
20:44 pyrimidine joined #perl6
20:48 jferrero joined #perl6
21:09 jaye joined #perl6
21:18 nbrown joined #perl6
21:20 fridim joined #perl6
21:25 jnthn Gah! 15 minutes of debugging all because I can't spell the word candidate...
21:26 pugs_svn r26794 | moritz++ | [t/spec] unfudge a test for Rakudo
21:26 moritz_ jnthn: that happens to me every now and then... I usually start the search function in my editor to hilight all occurences of the word, and see if it's missing one
21:27 moritz_ that's pretty handy in vim; just place the curser over it, and type * or #
21:27 jnthn moritz_: Turns out I'd copy-pasted the mis-spelling over a few files, so it was consistently mis-spelt, then when I re-wrote .wrap I managed to spell it right...
21:27 moritz_ ;-)
21:29 pmichaud in t/spec/S12-subset/subtypes.t, there's a test to verify that $_ in a block is readonly.  Why is it readonly?
21:29 pmichaud i.e., is it specced somewhere that it's to be readonly ?
21:30 jnthn Certainly if it was a place-holder parameter it should be. I'm not so sure that holds for $_ though.
21:30 pmichaud normally $_ in a block is rw
21:30 jnthn Yeah.
21:30 jnthn I'm leaning against the test on this one.
21:30 moritz_ unless it's bound to something non-modifiable, no?
21:30 jnthn Unless there's something more to it...
21:31 moritz_ my $x := 3; $x++ # should that die?
21:31 pmichaud sure, but in the test case it's not listed as non-modifiable
21:31 pmichaud subset SoWrong of Str where { $_ = "fail" }
21:31 pmichaud my SoWrong $x;
21:31 jnthn Ah
21:31 jnthn I'd change the test to $^epic = "fail"
21:32 pmichaud I'm happy with that.
21:32 moritz_ +1
21:32 jnthn oh, damm, I forgot that you can un-wrap out of order...
21:32 jnthn Or at least, the test seems to think you should be able to...
21:33 * jnthn checks the spec
21:37 jnthn hmm. spec seems to suggest out-of-order unwrapping is OK. :-|
21:37 pugs_svn r26795 | moritz++ | [docs] clean up Perl6::Perl5::Differences a bit
21:39 Whiteknight joined #perl6
21:39 pugs_svn r26796 | pmichaud++ | [t/spec]: Change readonly test to use placeholder parameter.
21:42 meppl good night
21:56 dduncan joined #perl6
22:00 dduncan left #perl6
22:07 VX joined #perl6
22:12 lichtkind_ joined #perl6
22:18 LadyLunacy joined #perl6
22:29 nsh joined #perl6
22:42 dalek rakudo: 2b685ac | pmichaud++ | src/parser/actions.pm:
22:42 dalek rakudo: Refactor subtype handling to eliminate redundant code.
22:42 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/2​b685ac6e214e96c1d0c883af3db7f1cd573f0a5
22:42 dalek rakudo: 6fc9344 | pmichaud++ | src/parser/actions.pm:
22:42 dalek rakudo: Refactor implicit $_ as parameter on blocks.  As a bonus, such
22:42 dalek rakudo: blocks now properly respond to .signature (where they didn't before).
22:42 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/6​fc93444f6bd44b634a3f71ebf2c505d88900d09
22:42 dalek rakudo: 4e9e1e3 | pmichaud++ | src/parser/actions.pm:
22:42 dalek rakudo: Refactor make_anon_subtype to re-use standard closure functions.
22:42 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/4​e9e1e33894f0d118901bba0b2cfc8f908e2c82b
22:42 pmichaud I like deleting code.  :-)
22:43 jnthn How much you managed to eliminate?
22:44 pmichaud 98 lines.
22:44 jnthn Nice.
22:44 pmichaud and    my $x = { .say };   $x.signature      # now works
22:44 jnthn :-)
22:46 jnthn I think I'm about there wiht my branch now.
22:48 jnthn Running make spectest now and then provided all is passing I can merge back in.
22:50 jnthn Basically the branch ripped out callwith and callsame, re-wrote them in terms of candidate lists, added nextwith and nextsame, then re-did .wrap and .unwrap so that they basically boil down to unshifting stuff onto and deleting stuff from a candidate list.
22:51 jnthn However, there's plenty of magical fluff around that.
22:51 jnthn This also means that $x.@candidates() not only works, but allows you to do callsame, callwith, nextsame and nextwith too. :-)
22:54 pmichaud \o/
22:55 jnthn The next refactor will hurt a little more.
22:56 jnthn In theory I need the refactors to get p6opaque in place; in reality I can cheat a bit if needed.
22:57 jnthn pmichaud: I've been pondering the "type object methods just do an extra check on the invocant" thing.
22:57 jnthn pmichaud: It's a neat idea in many ways, apart from...
22:57 pmichaud yes...
22:57 jnthn a) It would seem to imply ACCEPTS becomes a multi...and that everyone has to declare it multi.
22:57 skids joined #perl6
22:57 jnthn When they override it.
22:58 pmichaud Hmmm.  I'm not so sure that's a showstopper.
22:58 jnthn b) While it may fit into Rakudo OK, where we do have type-check-y stuff, not quite so sure how it's going to fit into P6object.
22:59 pmichaud In P6object, I don't expect anyone to be overloading ACCEPTS.
23:00 pmichaud I.e., it should really act like a type-object-only method.
23:01 jnthn OK.
23:02 jnthn I'll have to dig back in to the p6object refactors I started and see how far I can get.
23:02 pmichaud Indeed, in P6object now, .ACCEPTS is only available for protoobjects (I think).
23:04 jnthn *nod*
23:06 pmichaud From a P6object perspective, the way to test .does or .isa is by doing the equivalent   of $obj.^does  or $obj.^isa
23:06 pmichaud so I'm not sure that P6object itself needs to provide an .ACCEPTS
23:06 jnthn Aye, we can shuffle that into Rakudo I'd guess.
23:07 jnthn Unless anything else relies on it but I think not.
23:08 pmichaud I don't remember exactly why we stuck .ACCEPTS into P6object in the first place (but I do remember I went to move it and decided it was best not moved)
23:09 jnthn Heh, I don't remember either.
23:10 minazo left #perl6
23:14 Eevee joined #perl6
23:15 aindilis joined #perl6
23:16 jnthn OK, so...how to merge my branch back into master... :-)
23:21 donaldh joined #perl6
23:24 pmichaud I'm guessing   "git rebase origin master"   and then if everything goes well "git push origin master
23:25 pmichaud but that is a guess.  I've only done one or two branch merges.
23:26 pmichaud time for dinner here
23:26 pmichaud bbl
23:35 jnthn Figured it all out and pushed. :-)
23:39 frew|wor1 joined #perl6
23:39 dalek joined #perl6
23:48 hercynium joined #perl6
23:59 bacek__ joined #perl6

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

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs