Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2005-04-27

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:00 SamB has joined #perl6
00:01 * SamB continues to wait for darcs to finish applying patches
00:01 Limbic_Region has quit IRC ("leafChat IRC client: http://www.leafdigital.com/Software/leafChat/")
11:23 ilogger starts logging #perl6 at Wed Apr 27 11:23:37 2005
11:23 ilogger has joined #perl6
11:23 gaal how do i discard the return value of a function?
11:24 gaal Couldn't match `GenParser Char st' against `(->) a'
11:24 gaal      Expected type: GenParser Char st
11:24 gaal      Inferred type: (->) a
11:24 gaal i want to call it for it's (gasp!) side effect :)
11:24 Arathorn has left
11:25 * castaway makes an [off] alias..
11:26 Corion Hmmm. Seems like I'm running against a POD parser bug. I'll leave my documentation for the tests as comments then.
11:27 wolverian has quit IRC (Remote closed the connection)
11:27 Corion Hmmm. No, no POD parsing bug, but something triggered by something in my comments. Overeager gobbling, I guess
11:27 broquaint You can't, gaal, it's against the law.
11:27 autrijus gaal: const
11:27 * gaal 's always been the outlaw.
11:27 wolverian has joined #perl6
11:28 Corion ... as soon as I use C<%> somewhere in my comment. I guess it's the quote operator being overeager again ...
11:30 chady is now known as chady_
11:31 Corion Ah. Likely it is because less-than ("<") gets parsed as the beginning of a quoted list. Ugh.
11:32 Corion Whitespace has now officially entered Perl.
11:32 Corion :)
11:32 * broquaint laments the loss of his Haskell book
11:32 Corion $error<e1-9 # is not parsed as what you think.
11:33 Corion $error < e1-9 # is what you think
11:33 broquaint If anyone sees "Haskell: The Craft of Functional Programming, Second Edition" in an second-hand shop in London - it's mine.
11:35 castaway ,)
11:47 bsb has joined #perl6
11:56 gaal parsechelp wanted
11:56 gaal how do i return from my #line-processing rule?
11:57 gaal i want to return something like "nothing further to parse here" (right?)
11:58 jabbot pugs - 2393 - Modulus and division by zero now have te
12:02 Corion has quit IRC (Read error: 131 (Connection reset by peer))
12:03 Corion has joined #perl6
12:04 autrijus gaal: no...
12:04 autrijus you just return a Exp
12:04 gaal that won't compile
12:05 autrijus are you doing it in the same level as ruleBlockDeclaration ?
12:05 autrijus er
12:05 autrijus I mean
12:05 autrijus ruleDocBlock
12:05 autrijus if so, you need to say
12:05 autrijus option emptyExp ruleStatementList
12:05 gaal i added a choice to ruleStatement
12:05 autrijus as your final statement
12:05 broquaint Sorry if this is a dippy question, but where is "App" defined?
12:05 autrijus gaal: you need to add it to ruleStatementList
12:05 autrijus right below ruleDocBlock
12:05 autrijus broquaint: it's defined in AST.hs
12:06 autrijus data Exp = Noop | App !String ![Exp] ![Exp]
12:06 gaal k; what should i then return?
12:06 autrijus gaal: that's all you need to do
12:06 broquaint Marvellous! Thanksm autrijus.
12:06 autrijus option emptyExp ruleStatementList
12:06 autrijus will handle the rest for you
12:06 autrijus no need to say return
12:06 autrijus again, look at how DocBlock does it
12:06 autrijus broquaint: np :)
12:06 gaal looking.
12:07 broquaint Aah, AST.hs makes everything much clearer.
12:08 jabbot pugs - 2394 - Added more encompassing VRef handling to
12:09 Limbic_Region has joined #perl6
12:11 Corion autrijus: Is $error<1e-9 valid Perl6 ? Or should there be whitespace after $error ?
12:13 autrijus Corion: there needs to be a whitespace.
12:13 Corion OK, then it's not a pugsbugs candidate, but a syntax error in tests :)
12:13 Corion ... because Pugs seems to accept $error<1 as long as there never is a matching ">" sign anywhere :)
12:14 gaal oops, the existing $?POSITION is wrong. put this in a file and run it:
12:14 gaal use v6;
12:14 gaal say $?POSITION;
12:14 gaal say $?POSITION;
12:14 gaal say $?POSITION;
12:15 Corion gaal: It's off by one token I think - see the failing test in t/magicals/caller*
12:15 gaal the second two reports are identical.
12:16 gaal this is regardless of my change
12:16 Corion gaal: Oh. That's really weird then ;)
12:17 * Limbic_Region was thinking he could do what he wanted without regexen using junctions but now isn't so sure
12:17 gaal also, i *think* die always reports line 1 as location of error.
12:17 Limbic_Region Without researching junctions, I guessed that all( any(1,2,3) == any(7,3,8) ) would do what he wanted
12:17 Limbic_Region but it doesn't
12:17 Corion gaal: I've seen that, yes.
12:18 Limbic_Region is there a way to find out the values of a junction equality match?
12:18 Corion Limbic_Region: What's that surrounding all() for ?
12:18 Corion Limbic_Region: .values
12:18 jabbot pugs - 2395 - Fixed small (undetected) syntax error in
12:18 Limbic_Region Corion - doesn't work
12:18 Corion ... but that only goes one level deep.
12:18 Limbic_Region at least not in my test cases
12:18 Corion "doesn't work" ?
12:18 gaal position is completely broken, i'm afraid :(
12:19 Corion Limbic_Region: I did some expansion in t/pugsrun/09-*
12:19 Limbic_Region ok - will take a look
12:19 Limbic_Region thanks
12:19 autrijus gaal: ?POSITION is completely broken because the last statement did not carry pos info
12:19 autrijus that is a known issue that will be fixed soon
12:20 gaal "last statement" where?
12:20 Corion gaal: Last statement in the source code :)
12:20 Corion gaal: Add a fourth $?POSITION
12:21 gaal ah, i see what you mean.
12:22 Limbic_Region Corion - still greek to me
12:22 gaal but die is broken regardless: say $?POSITION / die / say $?POSITION; still gives line 1.
12:23 Corion Limbic_Region: my @foo = map { $_.values } any(<foo bar baz>); for @foo -> $x { say $x }
12:23 Limbic_Region basically what I want is not a bool response from any() == any() but rather a match (don't care if it is first, last, all)
12:23 Corion Ah. Don't know if that works.
12:24 Limbic_Region that's why I thought the all( any() == any() ) would be enough context hint to DWIM, but apparently not
12:24 gaal what part of the parser is responsible for comments? i can't see much treatment for them, and my #line patch doesn't work so i'm conjecturing that the directive gets stripped in the lexer or something?
12:25 gaal ah yes: P.commentLine in Lexer.hs
12:29 gaal seems like Rule/Token.hs needs hacking? this is getting a little hairy
12:33 autrijus gaal: I think you can just kill the comment processing
12:33 autrijus gaal: and handle it by yourself
12:34 gaal ah, so if the line doesn't match a #line directive, just ignore it? that does make sense, yes :)
12:34 autrijus yeah :)
12:35 autrijus so in Perl6Def:
12:35 autrijus          , P.commentLine    = "#"
12:35 gaal are there other #directives we might want?
12:35 autrijus becomes
12:35 autrijus ""
12:35 saorge has joined #perl6
12:35 autrijus no idea. prolly not
12:36 gaal all right, can always refactor later.
12:38 alinbsp has joined #perl6
12:39 pupilzeng has quit IRC ("Bye")
12:41 Corion r2395 - http://datenzoo.de/pugs/win2k.html
12:41 Corion changes topic to: pugscode.org <Overview Journal Logs> | smoke/win2k (occasional): http://xrl.us/fqum (25/4542, r2381), Mac OS X (62/4506, r2362), Linux (38/4508, 2381) | pugs.kwiki.org
12:41 Corion changes topic to: pugscode.org <Overview Journal Logs> | smoke/win2k (occasional): http://xrl.us/fqum (25/4542, r2395), Mac OS X (62/4506, r2362), Linux (38/4508, 2381) | pugs.kwiki.org
12:41 nothingmuch ooh how fun!
12:42 nothingmuch i'm getting an oppertunity to learn how to write ms devstudio add-ins!
12:42 castaway woo :)
12:42 * nothingmuch wonders if he starts walking to work what the chances of being hit by a truck are going to be
12:42 * castaway wonders if they're anything like excel add-ins
12:42 Corion nothingmuch: At least you won't be fat when the truck hits you :)
12:43 nothingmuch Corion: =)
12:43 nothingmuch maybe i can squirm out of it
12:43 nothingmuch i need to be able to arbitrary recolor and highlight (bg) of code
12:44 nothingmuch s/of//;
12:44 Corion nothingmuch: Develop on Zaphod maybe :) Colouring is "easy". The "editor" part is what doesn't work though ;)
12:45 nothingmuch what is zaphod?
12:46 Corion nothingmuch: http://zaphod.datenzoo.de - my text editor in JavaScript :)
12:46 castaway ,)
12:46 nothingmuch oh you poor baby
12:46 nothingmuch who made you write an editor in js?!
12:46 Corion Text colouring can be done via CSS.
12:46 Corion nothingmuch: I did this to myself, for fun :)
12:47 Limbic_Region Corion - sent my junction question to p6.l
12:47 * nothingmuch can't edit though
12:47 Corion nothingmuch: You should be able to ...
12:47 Limbic_Region seen stevan
12:47 jabbot Limbic_Region: stevan was seen 19 hours 54 minutes 31 seconds ago
12:47 nothingmuch safari
12:47 nothingmuch that doesn't make sense, I was talking to him later than that
12:47 nothingmuch maybe he shutup in chat
12:48 Corion the bot was offline for 8 hours or so
12:48 nothingmuch ah
12:49 * nothingmuch wonders whether you can do dynamically decided syntax highlighting
12:49 Corion nothingmuch: Not without implementing it in JS
12:49 Corion (or any other programming language)
12:49 nothingmuch Corion: i'm not touching JS, thankyouverymuch
12:50 nothingmuch =)
12:50 Corion nothingmuch: Ah, but JS is a cool language
12:50 broquaint want() has been implemented, right?
12:50 nothingmuch i mean in the ds api
12:50 nothingmuch broquaint: yeah, it returns a string
12:50 Corion broquaint: As a string, yes.
12:50 nothingmuch anyway, /me represses that stuff
12:50 broquaint Groovy, thanks guys.
12:50 nothingmuch i have a bit of time for .wrap
12:51 broquaint Am looking at implementing caller() atm, but the Pugs code is teh scary.
12:51 Corion broquaint: caller() is partly there, as $?POSITION. Broken tho'
12:51 Corion (and $?CALLER::POSITION , and $?CALLER::CALLER::POSITION)
12:51 qmole :)
12:51 Corion ... maybe you can steal from there?
12:52 broquaint Am going to try for the function first then work on the magical vars.
12:52 * nothingmuch knows how it's done
12:52 nothingmuch i can explain the code if you like
12:52 broquaint Well, I wouldn't be adverse to some stealing ;)
12:52 nothingmuch (For CALLER::)
12:52 broquaint Where's CALLER:: implemented atm?
12:52 nothingmuch Evalh.hs
12:53 broquaint Currently I'm poking around Eval.hs to see how other code works/is implemented.
12:53 broquaint Ah, there it is.
12:53 autrijus $?CALLER::SUBNAME
12:54 nothingmuch broquaint: basically while it does is sort of like:
12:54 nothingmuch while(my ($sigil, $fqn) = split(/CALLER::/, $fqn)){ my $context = $context->caller->context };
12:55 nothingmuch and then once you're out of CALLER:: it looks for "$sigil$fqn" inside the "current" context
12:55 nothingmuch context being pad, not eval context
12:55 nothingmuch except that it's not really pad it's more than that
12:56 * broquaint teh 'splode
12:56 castaway ,)
12:56 nothingmuch while(($sigil, $fqn) = split(/CALLER::/, $fqn)){ <pop context>; $fqn = "$sigil:$fqn" };
12:56 * castaway pins up a "Beware: Scary stuff" sign
12:57 broquaint What's $fqn?
12:57 nothingmuch fully qualified name
12:57 castaway fully qualified..
12:57 nothingmuch like '$?CALLER::POSITION'
12:57 broquaint Aha, right.
12:57 castaway (too slow)
12:57 nothingmuch after the loop it's '$?POSITION'
12:57 nothingmuch but with a change of lookup origin, ofcourse
12:58 nothingmuch and, ofcourse, it's not a loop in haskell =)
12:58 broquaint It's recursion, right?
12:58 nothingmuch yes
12:58 broquaint Is this happening around lines 207 - 222?
12:59 nothingmuch in p5:
12:59 nothingmuch i'm translating right now
13:00 broquaint Cool, thanks.
13:01 pupilzeng has joined #perl6
13:03 Aankhen`` has quit IRC (Connection timed out)
13:06 iblechbot has joined #perl6
13:06 Steve_p has quit IRC (Remote closed the connection)
13:08 jabbot pugs - 2396 - * compiler repaired.
13:08 jabbot pugs - 2397 - * fix minor display glitch
13:08 jabbot pugs - 2398 - * return type matching disabled for now
13:08 nothingmuch perlbot nopaste
13:08 perlbot Paste your code here and #<channel> will be able to view it: http://sial.org/pbot/<channel>
13:09 pasteling "nothingmuch" at 212.143.92.226 pasted "findVarRef in p5" (19 lines, 841B) at http://sial.org/pbot/9687
13:09 autrijus Corion: 09-dash-uppercase-c fixed
13:09 nothingmuch enable syntax highlighting, lots of it is comments
13:09 Corion autrijus: Just saw it - smoke already running ;)))
13:09 nothingmuch oh, and i threw in a p6 proto for fun ;-)
13:10 autrijus Corion: r2398? cool
13:10 nothingmuch autrijus: this needs some slight clarification on toGlobal
13:10 autrijus Corion: r2396 was b0rken
13:10 Corion Yep - 2398 just started
13:10 autrijus toGlobal is just
13:10 nothingmuch autrijus: btw, my smoke loop is running stably now
13:11 nothingmuch if you need this stuff and corion is asleep or something, svn up runs every 5 minutes
13:11 nothingmuch and if something is new, a smoke is rerun
13:11 autrijus s/^(\W+)(?<!\*)/$1*/
13:11 autrijus cool.
13:11 autrijus nothingmuch: where is the url again?
13:11 nothingmuch so there is about 20-25 minutes of latency, worst case scenario
13:12 nothingmuch http://nothingmuch.woobling.org/pugs_test_status/
13:12 autrijus danke
13:12 autrijus mind if I put it to pugscode.org?
13:12 nothingmuch prego
13:12 nothingmuch it should be there
13:12 broquaint Cool stuff, thanks, nothingmuch.
13:12 nothingmuch or maybe in the wiki
13:12 autrijus I'll put it to the frontpage
13:12 nothingmuch put the link to the wiki page on the frontpage
13:12 nothingmuch that way people can edit it
13:12 broquaint So implementing caller() wouldn't be unlike implementing a symbol table crawler in p5?
13:13 nothingmuch because there are more platforms than just OSX
13:13 nothingmuch broquaint: exactly, except it's still safe, and somewhat elegant =)
13:13 autrijus jhowitz is not here hmm.
13:14 broquaint Now when I implement I can say things like "Just do" and "Maybe foo" ;)
13:14 nothingmuch autrijus: i will whip up a kwiki page
13:14 autrijus nothingmuch: cool
13:14 nothingmuch anybody want to mine a list of URLs from the backlogs?
13:17 jhorwitz has joined #perl6
13:17 nothingmuch jhorwitz: what's the URL of your smoke?
13:17 autrijus hey jhorwitz!
13:17 nothingmuch http://pugs.kwiki.org/?SmokedPugs
13:17 jhorwitz mornin'
13:18 jabbot pugs - 2399 - Tests: lvalue subroutines and operator o
13:18 jhorwitz nothingmuch: i have yet to start smoking.  :)
13:18 nothingmuch ah
13:19 autrijus jhorwitz: so I repaired the compiler backends
13:19 jhorwitz but i can smoke it on solaris
13:19 nothingmuch did you collect some links?
13:19 autrijus jhorwitz: I seem to recall you want subs in parrot backend?
13:19 jhorwitz it would make my day.  :)
13:20 nothingmuch oh right, that was Jonathan
13:20 nothingmuch sorry!
13:21 jhorwitz np
13:22 nothingmuch what are gaal's URLs?
13:22 Coke_ has joined #perl6
13:22 * Coke_ ~~
13:23 nothingmuch nevermind, found them
13:23 autrijus hey Coke_
13:23 autrijus jhorwitz: now the problem is I have ~zero idea of how to do that
13:24 jhorwitz autrijus: in parrot?
13:24 autrijus yeah
13:24 nothingmuch autrijus: did you add smoke results to the frontpage?
13:24 autrijus nothingmuch: I did
13:24 nothingmuch the wiki or pugscode.org?
13:24 autrijus sub factorial ($x) { $x ?? $x * factorial($x-1) :: 1 }
13:25 nothingmuch oh i see
13:25 autrijus print factorial(10);
13:25 autrijus what should this be in IMC?
13:25 nothingmuch point to http://pugs.kwiki.org/?SmokedPugs instead
13:25 Coke_ do what in parrot?
13:25 Corion r2398 - http://datenzoo.de/pugs/win2k.html - isa.t broke, not.t broke, some other distributed failures
13:25 autrijus Corion: that two lines
13:26 autrijus sub factorial ($x) { $x ?? $x * factorial($x-1) :: 1 }
13:26 autrijus print factorial(10);
13:26 Coke_ you mean Coke? =-)
13:26 jhorwitz autrijus: here's a start: http://www.parrotcode.org/docs/compiler_faq.html
13:26 Coke_ eh, the compiler faq sucks. hang on, I can get you some untested code...
13:27 jhorwitz it does suck, but is there anything else?
13:27 autrijus I mean Coke :)
13:27 Coke_ no. And by all means, read it, yes. patches (and even complaints) welcome.
13:27 * nothingmuch mumbles somehting about autrijus and add
13:28 Coke_ autrijus - are you assuming that the x is an integer, or a PMC? do you care for the purposes of the example?
13:28 autrijus Coke_: all PMCs
13:28 autrijus pugs has no unboxed types
13:29 nothingmuch autrijus: about STM & perl
13:29 autrijus nothingmuch: heh, it's only been 3 minutes
13:29 autrijus and it's up now
13:29 * autrijus mumbles something about nothingmuch and add
13:30 nothingmuch in perl5 when I code defensively i use local, and destructors, and whatever extensively (my talk will discuss this)
13:30 Coke_ nopaste?
13:30 Coke_ (where's a nopaste url for this disc?)
13:31 autrijus perlbot: nopaste
13:31 perlbot Paste your code here and #<channel> will be able to view it: http://sial.org/pbot/<channel>
13:31 autrijus "How do I create nested subroutines?
13:31 autrijus PIR doesn't support nested subroutines. You have to emit subroutines one by one. If lexicals of the outer subroutine are visible inside the nested sub, you have to include the outer pad depth in new_pad opcodes."
13:31 autrijus yow!
13:31 castaway PIR?
13:32 jhorwitz PIR == IMC
13:32 nothingmuch brb
13:32 autrijus so suddently all my envDepth work paid off.
13:33 pasteling "Coke" at 170.3.8.253 pasted "Sample factorial" (23 lines, 319B) at http://sial.org/pbot/9688
13:33 Coke_ I don't have a copy of parrot handy, but that will hopefully work.
13:33 autrijus Coke++
13:33 autrijus Coke++
13:33 autrijus trying to run it
13:33 Coke_ if you give me any errors from parrot, I can debug it remotely. =-)
13:33 autrijus Null PMC access in get_bool()
13:33 Coke_ oh, whoops.
13:33 autrijus bwahaha
13:34 * autrijus is reminded of the same error in Pugs long, long ago
13:34 alinbsp has quit IRC (Read error: 145 (Connection timed out))
13:34 autrijus vCast: Cannot cast Val to VBool
13:34 pasteling "Coke" at 170.3.8.253 pasted "# sub factorial ($x) { $x ?? $" (23 lines, 349B) at http://sial.org/pbot/9689
13:34 * jhorwitz dislikes that error very much
13:34 Coke_ (I was passing in an "int", not an "Integer". so there was no pmc arg for factorial to grab.
13:34 autrijus Null PMC access in set_integer_native()
13:35 Coke_ *sigh*
13:35 Coke_ line?
13:35 autrijus in its infinite wisdom, there is no line number
13:35 Coke_ grumble.
13:35 * castaway grins.
13:35 Coke_ if I had access to a parrot, I could fix this in short order.
13:35 autrijus  $P1 = x
13:35 autrijus  $P1 = $P1 - 1
13:35 autrijus that worked.
13:35 Coke_ ah.
13:36 jhorwitz castaway: witness test-driven programming.  ;-)
13:36 Coke_ Yah, I never remember quite how much sugar IMC provides. =-)
13:36 castaway *g* jhorwitz
13:36 autrijus now it says factorial 10 is 1.
13:36 autrijus fancy that!
13:36 castaway funky
13:36 castaway slightly off there
13:36 Coke_ could be my logic. ^_^
13:36 autrijus Coke_: no.
13:36 autrijus the x pmc is shared apparently
13:36 Coke_ ah.
13:36 autrijus Very Bad.
13:37 Coke_ well, we probably shouldn't be mucking directly with the arg passed into us, eh?
13:37 Coke_ if you add a $P10 = clone x at the beginning of factorial, and then s/x/$P10/ from that point down in the sub, does that work?
13:38 jabbot pugs - 2400 - * some minor work on the Haskell compile
13:38 autrijus still bad.
13:38 autrijus I have this sinking feeling that registers are reused.
13:38 autrijus I'll use local PMCs.
13:39 Coke_ calling the sub should save the register off, I think.
13:39 Coke_ (IMC is supposed to handle all that for you.) (unlike PASM)
13:39 autrijus maximum recursion depth exceeded in file 'x' near line 14
13:40 autrijus hrmph
13:40 autrijus my fault
13:40 autrijus but fixing that yields 1 again
13:40 autrijus I give up :-/
13:40 Coke_ can you post what you've got at the moment?
13:40 Coke_ noooooo
13:40 autrijus alright. give me a min
13:41 autrijus I'll make pugs generate it
13:41 autrijus instead of by our mortal hands
13:42 * Coke_ realizes that he can grab a snapshot of parrot and build it, even if svn isn't working on this box.
13:45 * jhorwitz fixes IMC
13:45 Coke_ ?
13:45 jhorwitz in factorial:
13:46 jhorwitz $P1 = new Integer
13:46 jhorwitz $P2 = new Integer
13:46 autrijus jhorwitz: nopaste!
13:46 jhorwitz doh
13:46 pasteling "jhorwitz" at 216.52.77.2 pasted "factorial IMC" (23 lines, 329B) at http://sial.org/pbot/9690
13:47 autrijus works!
13:47 autrijus jhorwitz++
13:47 nothingmuch back
13:47 nothingmuch anyway, to continue (add my ass):
13:47 Coke_ ah. yah, that'd work in place of cloning. Giving a new target PMC for the value to live in.
13:47 nothingmuch stm's usefulness in try { } catch {}
13:47 nothingmuch try : sterile {
13:47 nothingmuch }
13:48 nothingmuch if any exception is raised *everything* is as it was before
13:48 nothingmuch it's basically atomic { } with a roll back on error
13:48 nothingmuch and a retry on atomic fail
13:48 nothingmuch how easy is that in pugs?
13:48 nothingmuch if we can demo it i think there can be no way to deny it's usefulness
13:49 nothingmuch but sometimes it's hard to force that on people
13:49 nothingmuch (and btw, if you care, as I said: my talk is going to touch this crap in the recipe book part)
13:49 theorbtwo Wow, looks like Big Things are happening in the chan.
13:52 autrijus nothingmuch: it is trivial in pugs
13:52 nothingmuch GHC has builtin STM?
13:52 autrijus nothingmuch: sure.
13:52 castaway yeah, damned if I know which, all gobbeldegook to me :)
13:52 nothingmuch goodness
13:52 autrijus see Control.Concurrent.STM
13:53 autrijus I suggest writing some same STM in ghc just to play with it
13:53 theorbtwo Autrijus, is there any chance of making Eval's fail throw a pugs-level exception?
13:53 autrijus use unsafeIOtoSTM happily
13:53 autrijus theorbtwo: retError does that
13:53 nothingmuch autrijus: i am asking to buy a feature with my paypal subscription:
13:53 nothingmuch when you have free time please add atomic
13:53 autrijus theorbtwo: maybe we need to make Eval a newtype
13:53 autrijus theorbtwo: so that we can redefine its fail
13:54 autrijus nothingmuch: sure
13:54 Coke_ oh, does autrijus do paypal? what's his address? =-)
13:54 autrijus Coke_: pugscode.org
13:54 nothingmuch and allow try { atomic { } } to DWIM
13:54 nothingmuch spec or not
13:54 nothingmuch because i think this stuff is looked down upon too much
13:54 autrijus try { atomic {} }?
13:54 autrijus it's just
13:54 nothingmuch it's these situations where language features (like timely destruction!) *really* save your ass
13:54 autrijus atomic { ... } orElse { #noop }
13:55 nothingmuch autrijus: in perl6 syntax?
13:55 autrijus nothingmuch: in GHC syntax
13:55 nothingmuch i mean add some p6 goodness
13:55 autrijus I'm saying that try{atomic{}} is ambiguous
13:55 autrijus because atomic rollback is not an error
13:55 nothingmuch a try { } catch that will roll back on failure
13:55 nothingmuch no need to temp
13:55 nothingmuch that's what i want
13:56 nothingmuch i want to run some code, and undo all it's effects if it dies
13:56 chady has joined #perl6
13:56 theorbtwo autrijus, I know retError does that, but I was thinking that instead of manually checking for things that will cause GHC to error, we can let GHC error, ad simply do the right thing when it does.
13:56 autrijus got it.
13:56 autrijus theorbtwo: yes, and you do that by redefining "fail"
13:56 nothingmuch lets you be very loose by doing things like
13:56 autrijus as well as MonadError instance
13:56 nothingmuch $account->add($money);
13:56 autrijus theorbtwo: because ContT doesn't do that for is
13:56 autrijus us
13:57 autrijus theorbtwo: we need to switch Eval from a type to a newtype
13:57 nothingmuch $account->recalculate_overdraft(); # error
13:57 castaway transactions, nm?
13:57 theorbtwo OK, think I grok.
13:57 nothingmuch exactly
13:57 autrijus theorbtwo: and add those instances ourselves
13:57 nothingmuch but in p6, with no special features in $account.ref
13:57 castaway sounds fun
13:57 nothingmuch or $account.isa, or whatever
13:57 Coke_ what version is pugs at?
13:57 nothingmuch i know i would kill for it right now, in the stuff i've been doing for the past 6 months or so
13:57 castaway 6.2.1.plussome
13:58 theorbtwo 6.2.1, r2400 even.
13:58 castaway nm, use db transactions ?
13:58 nothingmuch castaway: it's not the same
13:58 nothingmuch and i do
13:58 nothingmuch again, this is what my talk is about
13:58 * castaway figured
13:58 autrijus nothingmuch: Java and C# both have STM libraries now ;)
13:58 nothingmuch how to try to leverage these tools and behaviors, apply KISS, shift complexity
13:58 autrijus it's something that can be retrofitted
13:59 castaway sounds like "everything should be magic" .)
13:59 * Coke_ wonders if autrijus can buy a cup of coffee with coke's donation.
13:59 castaway we'll be lucky to turn up to YAPC at all, atm..
13:59 nothingmuch so that you can make things break correctly when they do
13:59 nothingmuch autrijus: so again, my request is to retrofit it into the design, today
13:59 theorbtwo Magic can be a goodness.
13:59 nothingmuch castaway: magically there's not much magic going on
13:59 theorbtwo Of course, when you know the secrets, it doesn't seem quite so... magical.
13:59 nothingmuch the point is reliability
14:00 nothingmuch autrijus: i'm buying a feature, if you will =)
14:00 nothingmuch is that OK with you?
14:00 castaway hidden magic is good, until something fails, and you try to get a sensible error message from the user ,)
14:00 nothingmuch castaway: exactly
14:01 * castaway is currently having such problems with a QA personage.
14:01 autrijus nothingmuch: I don't really like to do that when the threading model is 5005threads, honestly.
14:01 autrijus nothingmuch: and I have no idea how ithread perl6's model is gonna be.
14:01 nothingmuch heck, i don't care about threads ATM
14:01 autrijus oh!
14:02 nothingmuch i would like to be able to get hypotheticals without declaring them
14:02 autrijus I see what you mean
14:02 autrijus yes.
14:02 mj r2399 - 939/4573 subtests failed, 79.47% okay.   http://test.wikidev.net/Pugs_tests?action=history
14:02 mj see 2311 vs. 2399  -  http://test.wikidev.net/Pugs_tests?tit​le=Pugs_tests&amp;diff=0&amp;oldid=774
14:02 nothingmuch hypothesize on object attributes in code i called
14:02 autrijus single thread transactions
14:02 SM_ax has quit IRC ("ChatZilla 0.9.61 [Mozilla rv:1.7.7/20050420]")
14:02 nothingmuch hypothesize globlas i don't know i'm touching
14:02 nothingmuch etc etc
14:02 autrijus hmm
14:02 nothingmuch i don't think 'let $var' is good enough for reliability
14:02 nothingmuch it's a nice feature, but it only goes so far
14:03 autrijus so we roll back _everything_
14:03 nothingmuch everything to the point before the try
14:03 autrijus except of course bytes already printed
14:03 nothingmuch but copy the reference
14:03 autrijus copy what reference?
14:03 nothingmuch sorry
14:03 nothingmuch not reference
14:03 nothingmuch exception
14:03 Corion has quit IRC (Read error: 113 (No route to host))
14:04 nothingmuch i think we should think about a lexical pragma
14:04 * nothingmuch is slipping on freud
14:04 nothingmuch whether IO is allowed
14:04 nothingmuch as for bytes printed: we can't control that
14:04 nothingmuch to allow users to arrange for perl to throw a fatal error before any really side-effectful op is performed
14:05 nothingmuch but this is not very important now
14:05 nothingmuch IMHO
14:05 theorbtwo nm, wouldn't that have to be a dynamic pragma to be useful?
14:05 nothingmuch theorbtwo: yes, dynamic
14:06 nothingmuch theorbtwo++
14:07 * autrijus thinks some more
14:08 chady has quit IRC ("leaving")
14:08 nothingmuch ofcourse, these things should be nestable too
14:08 nothingmuch but we already have that, right?
14:09 autrijus yup
14:09 autrijus there are an easy way and a hard way
14:09 autrijus the easy but slow way is to save the full continuation
14:09 autrijus up to the nearest delimiter
14:10 autrijus and if things fail
14:10 autrijus we just resume that outer continuation
14:10 autrijus with all the IORefs in the old value
14:10 nothingmuch how is the exception copied?
14:10 autrijus when you resume some continuation you can add whatever symbol to it
14:10 nothingmuch okay
14:10 autrijus basically you dump the Env
14:11 autrijus (as we already do when you do pugscc)
14:11 nothingmuch what's the hard way?
14:11 autrijus the hard way is to use journaling
14:11 autrijus just like in the STM paper
14:11 autrijus it will be massively faster.
14:12 autrijus but then that will not be portable to parrot ;)
14:12 Coke_ note that $P2 = new Integer in that new sample is apparently unnecessary
14:12 nothingmuch do we reimplement journalling for the pugs data types?
14:12 nothingmuch (btw, i think as a prototype it's OK that it's not parrotable for now)
14:12 nothingmuch (i just want to be able to show that this stuff really works. I think p6l is not yet appreciative enough of what haskell has to offer)
14:13 autrijus nothingmuch: well, for a starter, switch all our IORef to TVar
14:13 autrijus nothingmuch: you can do that.
14:13 autrijus want to help? :)
14:13 autrijus just change all IORef to TVar
14:13 nothingmuch yes
14:13 autrijus all newIORef to newTVar
14:13 autrijus read, write too
14:13 autrijus and when you do
14:14 autrijus liftIO $ readIORef ...
14:14 pasteling "Limbic_Region" at 129.33.119.12 pasted "Can someone tell me if this works - I forgot to burn a CD again today :-(" (22 lines, 549B) at http://sial.org/pbot/9692
14:14 autrijus define a liftSTM
14:14 autrijus that does the same thing
14:14 autrijus liftSTM is just
14:14 autrijus liftIO . atomically
14:14 nothingmuch let me read up on STM details first
14:14 autrijus nothingmuch: sure, Control.Concurrent.STM and GHC.Conc
14:14 nothingmuch what is IORef, really? a monadic container?
14:15 Limbic_Region anyone ?
14:15 nothingmuch autrijus: i'm writing this down
14:15 nothingmuch so please continue
14:17 nothingmuch okay, i grokked IORef
14:18 autrijus cool.
14:19 Limbic_Region no one has time to tell me if that code snippet worked?  :-(  I promise to burn a CD tomorrow - I promise
14:19 nothingmuch Limbic_Region: one sec
14:19 autrijus Limbic_Region: ??::
14:20 Limbic_Region thanks
14:20 theorbtwo IORef is a reference to a mutable variable.
14:20 nothingmuch theorbtwo: yah
14:20 pasteling "Limbic_Region" at 129.33.119.12 pasted "Can someone tell me if this works - I forgot to burn a CD again today :-(" (22 lines, 551B) at http://sial.org/pbot/9693
14:20 nothingmuch Limbic_Region: too trigger happy?
14:20 Limbic_Region ternary fix per autrijus - thanks
14:20 autrijus @list not @$list
14:20 nothingmuch ah
14:20 Limbic_Region needs another one too
14:21 autrijus you don't need to write ->{}
14:21 autrijus {} is enough
14:21 pasteling "Limbic_Region" at 129.33.119.12 pasted "Can someone tell me if this works - I forgot to burn a CD again today :-(" (22 lines, 549B) at http://sial.org/pbot/9694
14:21 Limbic_Region autrijus - following examples from tests/examples
14:21 Limbic_Region but that shouldn't prevent it from running though
14:22 * nothingmuch really wants 'is pure'
14:22 nothingmuch subcalls that can remain thunk
14:22 Limbic_Region nothingmuch - did the latest incarnation work?
14:22 theorbtwo nm: is cached is closest.
14:22 nothingmuch still SSHing through things
14:22 nothingmuch theorbtwo: it's not the same, and i don't like 'is cached'
14:22 nothingmuch is pure is a description
14:22 nothingmuch is cached is a request, that implies is pure
14:23 theorbtwo I know.  Thus "closest".
14:23 autrijus is cached is just cached.
14:23 autrijus it doesn't mean it's pure.
14:23 nothingmuch autrijus: well, to sane readers it should
14:24 autrijus still not really.
14:24 nothingmuch &infix:+ is pure
14:24 nothingmuch that's what I meant
14:24 nothingmuch what do you mean then?
14:24 nothingmuch sadly, i don't see what's so hard to "get" about these, that it's such an issue... we can make this distinction internally
14:24 nothingmuch &infix:= is io_free
14:24 autrijus unsafePerformIO has two guarantees
14:24 nothingmuch &say is not pure
14:24 autrijus 1. it doesn't matter _when_ it gets run
14:24 autrijus 2. it doesn't matter _how many times_ it gets run
14:24 autrijus "is pure" means both
14:25 autrijus "is cached" only means 2.
14:25 nothingmuch true
14:25 nothingmuch but i know i'll never say is cached on an impure sub without commenting that that's the desired effect
14:26 nothingmuch also: this distinction is useful for combining data
14:26 nothingmuch junctions should not realy interact with most of the non pure builtins directly
14:26 nothingmuch it rarely makes sense
14:26 nothingmuch pure ops can create new junctions, even lazily
14:27 nothingmuch io_frees shouldd behave like that too, but strict evaluation is guaranteed
14:27 nothingmuch autothreading is an exception to this rule, IMHO
14:27 theorbtwo + isn't neccessarly io-free, though, on two random arguments.
14:27 theorbtwo It is for most arguments, certianly, but not neccessarly all.
14:27 nothingmuch + with MMD in place a more specific + might not be pure
14:28 nothingmuch but the + which takes two numbers is pure
14:28 nothingmuch the coercion of some arbitrary object into a number might be impure
14:29 nothingmuch but that is done before evaluating the actual code which + does: it's in the parameter binding
14:30 theorbtwo That seems like splitting hairs; it's impossible to call a function without doing parameter binding first.
14:30 nothingmuch right, but if parameter building requires no action
14:30 nothingmuch 1 + 1 bind two ints, pure types, into +
14:31 nothingmuch + can stay pure
14:31 nothingmuch it can be optimized at compile time
14:31 nothingmuch since it's pure, and we know the values
14:31 theorbtwo Ah, I see.
14:31 nothingmuch it can be delayed till it's used
14:31 nothingmuch the former policy is already in place in perl5
14:32 nothingmuch if we do sub CONSTANT { 10 * 10 } at compile time
14:32 nothingmuch why not sub FACT_OF_FIVE { 5! }
14:32 nothingmuch where the user defines &infix:! is pure ?
14:32 theorbtwo So infix:+(Int a, Int b) is math_pure, but coerce(COM a) returns Int is not.
14:32 nothingmuch it's actually much simpler once you think about how to implement
14:33 nothingmuch right
14:33 nothingmuch if $obj does Int the methods of that role might or might not be pure
14:33 theorbtwo (However the hell you spell the operation that does implicit coercions.)
14:34 * nothingmuch thinks the p6 design team is too far from the implementation detailas
14:34 nothingmuch most of it is "perl6 will be powerful enough to be the internals of perl 6"
14:35 nothingmuch and if we are doing such ad-hoc lazy list semantics, why not this stuff too?
14:36 nothingmuch i don't see any room for performance benefits or flexibility if lazy lists will interact with impure constructs very early on in their lives
14:36 nothingmuch it's probably going to be more of a bug source than a performance/simplification oriented feature
14:37 nothingmuch why not gather -> is pure { take { } }?
14:37 nothingmuch what if i want to do RCP in a gather block?
14:37 nothingmuch it will time out unless i force flatten the list
14:37 nothingmuch RCP - RPC
14:37 theorbtwo (remote copy is a form of remote procedure call.)
14:38 nothingmuch yeah, it is but i meant something more simple ;-)
14:38 nothingmuch s/simple/generic/
14:39 nothingmuch poll: who else thinks the current lazy list semantics are not very good?
14:39 nothingmuch i would like to know if it's worth bringing up in chat at all
14:40 nothingmuch or whether i'm an uneducated minority
14:40 theorbtwo I suspect you are an educated minority.
14:40 theorbtwo I'm not horribly clear on what the exact semantics are with lazy lists and when their lazyness is colappsed.
14:41 nothingmuch what about autothreading? same opinions?
14:41 nothingmuch appearantly they are flattenned when stuff happens
14:41 theorbtwo Autothreading as it currently exists strikes me as too much of a good thing.
14:41 nothingmuch stuff being anything IOish that could have touched the lazy list
14:41 nothingmuch what about Any|Junction?
14:42 theorbtwo Any|Junction means "please don't autothread, just pass me the whole junction as one object"?
14:43 nothingmuch yup
14:43 nothingmuch i think it should be the default in any case
14:43 nothingmuch and <<$maybe_a_junction_param>> should be a request for autothreading
14:44 nothingmuch and call some_naive_sub(<<$junction>>);
14:44 nothingmuch should also autothread, but from the caller perspective
14:44 nothingmuch basically it's like hyper ops, except that the hyper is oriented around the data, and not the operation
14:44 * nothingmuch suspects that all these 'use junctions' pragma ideas will lead freepan to be 4-5 separate repos
14:44 nothingmuch Class::DBI
14:44 nothingmuch Class::DBI::Junctive
14:45 nothingmuch etc etc
14:45 elmex has joined #perl6
14:45 nothingmuch meaning:
14:45 nothingmuch we will have some styles of writing
14:45 nothingmuch those who are chickenshit and don't want implicit autothreading of possibly impure code
14:46 Limbic_Region out of curiosity - is there a way to get pugs to spit out the line number of an error to troubleshoot better?
14:46 nothingmuch (and main($junction) means that we will have a lot of this)
14:46 nothingmuch those who only use junctions in if($val == 1|2)
14:46 nothingmuch and will use 'no junctions' in their scripts
14:46 nothingmuch and thus give up on much of freepan
14:48 mj has quit IRC ("Miranda IM! Smaller, Faster, Easier. http://miranda-im.org")
14:48 nothingmuch someone? anyone? say i'm an idiot, or that i'm right
14:48 nothingmuch autrijus?
14:49 maclean has joined #perl6
14:50 * nothingmuch *sight* and gives into uncertainty
14:50 nothingmuch s/sight/sighs/
14:50 theorbtwo NM: I suspect most people will avoid junctions like the strange quantum beasties that they are.
14:50 nothingmuch i think they can be very useful when used naively, with these semantics:
14:50 theorbtwo is($foo, 1|2) both succeeding and failing when $foo is 1 gives me the heebie-jeebies.
14:50 nothingmuch builtins that can't eat them die
14:51 nothingmuch anything else gets passed down
14:51 nothingmuch theorbtwo: me too
14:51 nothingmuch shouldn't it mean 'if $foo is eq 1 or $foo is eq 2 then ok'?
14:51 nothingmuch for anything else junctions are composed by default
14:51 maclean can I ask a question about building pugs on osx?
14:51 nothingmuch maclean: sure
14:52 theorbtwo .oO(We might even be able to answer it, but we certianly can't if it remains unasked.)
14:52 maclean I get the 'old' "Unknown pseudo-op: .subsections_via_symbols" problem
14:52 maclean I understand that it's due to gcc version conflicts...
14:52 nothingmuch anyway
14:53 nothingmuch if i have sub avg (@list) { for @list -> $item { $sum += $item }; $item / @list }
14:54 masak question: what's the easiest way today to generate html from kwid?
14:54 masak by hand?
14:54 nothingmuch masak: i think there's some kwid goodness
14:54 nothingmuch if we pass in avg(1, 5, 2|3) we should get back a junction
14:54 nothingmuch avg(1, 5, 2), avg(1, 5, 3)
14:54 nothingmuch look in svn.kwiki.org and freepan
14:54 nothingmuch lots of unreleased stuff
14:54 nothingmuch but i don't know any details
14:54 masak nothingmuch: ok
14:54 nothingmuch anyway, back to junction semantics:
14:54 nothingmuch if the user can parallelize avg, they can request to autothread
14:55 nothingmuch it can be done automatically if avg is pure
14:55 nothingmuch the return value is always a junction
14:55 nothingmuch except where:
14:55 nothingmuch my @blown_up = <<avg(1, 2, $junction)>>;
14:56 nothingmuch in which case expansion is after avg returns, semantically
14:56 maclean hohum, back to ramachandran plots...
14:56 nothingmuch i see no use in usefulness here
14:56 maclean has quit IRC ()
14:56 nothingmuch it takes 4 chars to get cool semantics on SMP, where you know it's safe
14:56 nothingmuch it takes 4 chars to do something unexpected but useful
14:57 nothingmuch theorbtwo: opinion?
14:58 theorbtwo You had me until this last discussion.  I'd expect under normal semantics (IE with no syntatic markers) for avg(1, 5, 2|3) to return 8/3 | 9/3.
14:58 nothingmuch exactly
14:58 nothingmuch when you want that to autothread:
14:58 nothingmuch avg(1, 5, <<2|3>>)
14:58 nothingmuch you still get back a junction, except that execution order is undefined, and possibly parallel
14:59 theorbtwo ...not because avg gets run twice, with different @lists, but becuase it gets run once with three arguments, one of which is 2|3.
14:59 nothingmuch if avg knows it can do that, it can put that in it's prototype:
14:59 nothingmuch sub avg (<<$param>>) {
14:59 nothingmuch eventually it's the += that junctions it up
14:59 nothingmuch theorbtwo: exactly
14:59 nothingmuch when it finds a junction
14:59 nothingmuch it doesn't care, actually
14:59 theorbtwo Exactly.
14:59 nothingmuch only the lowest level builtin primitives actually junction up
14:59 theorbtwo So what's with the syntatic markings of things we don't care about?
15:00 nothingmuch explain please
15:00 nothingmuch (also, this has a huge performance benefit, and makes exceptions consistent
15:00 nothingmuch sub_that_might_die($junction).
15:00 nothingmuch if it's body does verification of state, and then does stuff with it's data
15:01 Limbic_Region Is there something obvious I am missing in how to debug the following error:  unexpected "s", expecting ";" or end of input, NonTerm SourcePos "foo.p6" 4 1
15:01 nothingmuch with autothreading semantics it will have to verify and die for each element of the explosion of the junction
15:01 Limbic_Region what is the 4 1 at the end?
15:01 theorbtwo line four, column one, I think.
15:01 nothingmuch show us foo.p6
15:01 Limbic_Region http://sial.org/pbot/9699
15:02 nothingmuch it's the s of the sub lazy_merge
15:02 Limbic_Region still trying to get that piece of code working - hardburn has been running it giving me the errors and I have been tracking them down and fixing them
15:02 nothingmuch why it happens is hard for me to say
15:03 nothingmuch Limbic_Region: what OS are you using?
15:03 nothingmuch we could arrange for a pugs build
15:03 Limbic_Region nothingmuch - my problem is that I didn't burn a copy of ghc/pugs to bring into work
15:03 Limbic_Region I can't install but I can certainly unzip
15:04 nothingmuch theorbtwo: what did you mean by 'syntatic markings'?
15:04 nothingmuch too big a download?
15:04 nothingmuch so download one of jonathan's builds
15:04 nothingmuch http://www.jwcs.net/~jonathan/perl6/
15:04 theorbtwo nm: <<foo>>
15:04 nothingmuch ah
15:04 nothingmuch that is like flatten
15:05 nothingmuch except it means to explode across threads
15:05 theorbtwo Why not sub foo ($bar is threaded) ?
15:05 Limbic_Region thanks nothingmuch
15:05 nothingmuch could be
15:05 nothingmuch it's just symmetric with >>op<<
15:05 nothingmuch and it looks pretty obvious that it's going out
15:06 autrijus sorry, back.
15:06 autrijus factorial.p6 now compiles to parrot just fine.
15:06 nothingmuch and texas/french quotes are associated heavily with parallelization/aggregation
15:07 * nothingmuch would like to write about this to p6l
15:07 nothingmuch i am ashamed to admit i have no context though
15:07 nothingmuch what I see as wrong seems to have been defined as right before i dabbled with p65
15:07 nnunley has joined #perl6
15:07 nothingmuch gah, can't type today
15:08 nothingmuch also, theorbtwo: what's more readable?
15:08 nothingmuch for (<<@list>>) { }
15:08 nothingmuch or for (all(@list) is threaded) {} ?
15:08 nothingmuch i think both are ok
15:08 theorbtwo for (all(@list) is threaded) {...}
15:08 nothingmuch but that the second is less natural
15:09 theorbtwo 1: The second syntax tells me the combinator that is being applied, the first does not.
15:09 nothingmuch for (<<all(@list)>>) { # same thing
15:09 nothingmuch why are we constructing a junction at all in there, btw?
15:09 * nothingmuch is puzzled
15:09 theorbtwo 2: The first syntax looks like I should pay lots of attention to the <<...>> and is distracting.
15:09 nothingmuch what's a combinator got to do with it in this example?
15:09 theorbtwo Nothing.
15:09 nothingmuch you should pay a lot of attention =)
15:09 theorbtwo Which brings me to 3: What does that have to do with anything?
15:10 nothingmuch i don't know why junctions imply parrallelization in this context
15:10 theorbtwo Aren't we talking about the behavior of a junction as a paremter to a function?
15:10 theorbtwo Where's the function?
15:10 nothingmuch for (all(@list)) { }
15:10 nothingmuch according to s6 or something that's autothreaded
15:10 nothingmuch go explain that to a newbie, eh?
15:10 theorbtwo Huh?
15:10 nothingmuch to me it reads like 'foreach (@list) { }' just with slight rephrasing
15:10 nothingmuch it executes the for block asynchroneously
15:10 theorbtwo I know what it means.
15:11 theorbtwo But why does it do that?
15:11 nothingmuch okay, why should it mean that?
15:11 nothingmuch because it's a junction
15:11 theorbtwo It looks like a for loop over a single value to me.
15:11 nothingmuch and it's being passed to a block-isa-closure
15:11 nothingmuch that also looks like a for loop over a single value to me
15:11 nothingmuch but it's not, it's an iteration of all the items of the array
15:11 nothingmuch in an undefined order
15:11 theorbtwo But it's the block that's magical.
15:11 nothingmuch it's not magical
15:11 nothingmuch it's a plain block
15:11 theorbtwo for (@list) async{} looks cleaner to me.
15:12 nothingmuch for (all(@list)) -> Any|Junction $var { }; # i think this does what we want
15:12 theorbtwo It's a block with a parameter that is bound strangely.
15:12 nothingmuch theorbtwo: why a new thing? i don't see how it's consistent
15:13 theorbtwo I might need an extra pair of curlies there, if async doesn't construct a block, but mearly calls one.
15:13 nothingmuch otoh all(@foo) is threaded is just as clear
15:13 nothingmuch ah, that's explicit threading
15:13 theorbtwo Yes.
15:13 nothingmuch i think it's something entirely different
15:13 nothingmuch it's not 'maybe thread this up'
15:14 nothingmuch has quit IRC ()
15:14 Coke_ has left
15:15 autrijus this now compiles: http://nopaste.snit.ch:8001/2449
15:16 autrijus (to parrot, that is)
15:16 jhorwitz autrijus++
15:16 autrijus :)
15:17 theorbtwo Impressive.
15:17 autrijus committing.
15:17 * jhorwitz is now one giant step closer to mod_pugs..
15:17 castaway oooh
15:18 jabbot pugs - 2401 - * compile subroutines to Parrot.
15:19 autrijus fact.imc: http://nopaste.snit.ch:8001/2450
15:19 jhorwitz woohoo!
15:23 ingy hola
15:23 Limbic_Region is for @foo -> $_ is rw { $_ = 2 }; # supposed to work?
15:23 broquaint is = no-op IIRC
15:23 Limbic_Region nevermind - I just saw it was a todo test
15:23 broquaint Unless ...
15:24 ingy does anyone here know when the hackathon ends and the hotel stay begins?
15:24 Limbic_Region so that means I can't trade a test for a feature?
15:24 Corion has joined #perl6
15:26 * Limbic_Region adds for @foo -> $_ is rw ( ... } to his wishlist and tries to find another piece of p5 code he can translate to p6
15:27 Corion Limbic_Region: I think that "is rw" already works. Or maybe at least parses.
15:29 Limbic_Region not in for blocks Corion
15:29 Limbic_Region It works for subs though (at least it looks like it does)
15:29 Corion Aaah - yes - I was thinking of subroutines, not for blocks
15:30 Limbic_Region and the point of my exercises isn't to work around limitations in Pugs by doing @foo[ $_] = @foo[ $_ ]  2 for 0 .. @foo.end
15:31 Limbic_Region I am trying to show how easy the transition from p5 to p6 is going to be for the benefit of others - so I will wait
15:31 Limbic_Region grr - this like always eats plus symbols
15:31 Limbic_Region @foo[ $_ ] plus 2;
15:32 pupilzeng has quit IRC ("Bye")
15:32 Corion Limbic_Region: Maybe URL-encode your "plus" signs? This sounds like a badly written CGI parser to me ;)
15:33 Corion %20
15:33 Corion D'oh - my irc client is not CGI :)
15:33 Aankhen`` has joined #perl6
15:33 Limbic_Region hmmm \
15:34 theorbtwo BTW, %20 is a non-shortest-form URL encoding of a space, and not a URL encoding of a +.
15:34 * Limbic_Region knew that
15:34 theorbtwo Yeah, I was pointing that out to Corion.
15:35 Corion theorbtwo: I know too. I assume that Limbic~Region can't type plus, because he's chatting through a CGI en-/decoder
15:35 Limbic_Region in any case, there is already a todo test for the feature I want so I will look for more code for now that is already doable with Pugs in its current state
15:35 Corion Limbic_Region: You could port my JavaScript homenode button :)
15:36 theorbtwo Corion: You have a pugs embedded in your browser to be able to execute inline p6?
15:36 theorbtwo Cool!
15:36 Corion theorbtwo: Your hovercraft is full of eels!
15:39 theorbtwo Mein Luftkissenfahrzeug ist voll auf aale?
15:40 theorbtwo s/aale/Aale/, of course.
15:41 Corion "full of" == "voller" :)
15:42 elmex hmm
15:42 Corion Oh. .isa now looks interesting: (mkType "Array") instead of Array
15:42 Corion ... unfortunately that's not Haskell code but the output of say() :)
15:42 frogspit has joined #perl6
15:45 frogspit has quit IRC (Client Quit)
15:46 Limbic_Region http://use.perl.org/~Limbic%20Region/journal/24401 # Fun with Pugs (my journal)
15:46 autrijus Corion: please change the show to showType
15:46 autrijus thanks :)
15:46 Corion :))
15:50 Corion ... I even found out myself which file to change (Prim.hs)! Yay me ;)
15:51 * Corion starts a fresh smoke
15:51 * Corion away
15:58 jabbot pugs - 2402 - Changed type display again, so isa() is
16:03 nothingmuch has joined #perl6
16:04 nothingmuch evening
16:04 theorbtwo It's evening already?
16:05 nothingmuch i think
16:05 nothingmuch i'm going to be an asshole
16:05 Corion The sun is still shining here :)
16:05 nothingmuch you guys are more up north
16:06 nothingmuch here the sun is just starting to go disappear
16:06 nothingmuch anyway: asshole behavior:
16:06 nothingmuch i'll post some quick polls to p6l:
16:06 Corion r2402 - http://datenzoo.de/pugs/win2k.html
16:06 pasteling "jhorwitz" at 216.52.77.2 pasted "Why does this not compile using the parrot backend?" (10 lines, 120B) at http://sial.org/pbot/9700
16:06 nothingmuch "are you happy with autothreading semantics?"
16:06 nothingmuch "are you happy with lazy list semantics"
16:06 nothingmuch etc
16:06 jhorwitz autrijus: check out the paste
16:06 nothingmuch with concise answers
16:07 nothingmuch and i'll try to draft out my ideas, and see which sematics please more people
16:07 nothingmuch and then try to argue
16:07 nothingmuch what do you guys think?
16:08 Corion Ooooo. And a new exmple program now compiles for Parrot. Yay :)
16:08 mj has joined #perl6
16:08 Corion nothingmuch: Language design is not about pleasing people :)
16:08 nothingmuch why not?
16:08 nothingmuch i find it unpleasing to have to write defensively around language misfefatures
16:08 Corion There was an article on how to design gaming worlds, and that what newbies want makes not for good/long lived gaming worlds
16:08 autrijus jhorwitz: fixing that
16:08 nothingmuch it's not about fun
16:09 nothingmuch it's about hard issues
16:09 Corion nothingmuch: You can do it to (re)raise discussion, but don't put any meaning to the numbers.
16:09 nothingmuch it's not really about numbers
16:09 nothingmuch of people
16:09 nothingmuch it's about the number of issues
16:09 Corion ... for example, I suspect that many Perl6 people haven't seen many non-C-like languages.
16:09 Corion nothingmuch: Aaah - these questions are [x] <- check here # style questions
16:10 nothingmuch not really
16:10 justatheory has joined #perl6
16:10 nothingmuch and i think that there are good resolutions for these things
16:10 nothingmuch i have big issues with some behavior
16:10 nothingmuch trying to foresee how i will suffer
16:11 nothingmuch is it clearer now, what my purpose is?
16:12 theorbtwo "I think these semantics are bad, because they make this easy thing hard, and this hard thing impossible.  Aren't these other semantics better?"
16:14 jhorwitz autrijus: string interpolation isn't working either -- try running with parrot once you fix the sub call.
16:14 * jhorwitz wishes he could help more with the haskell side of things...
16:16 nothingmuch theorbtwo: good premise
16:16 nothingmuch jhorwitz: don't underestimate the importance of QA
16:16 nothingmuch jhorwitz++
16:16 mj mj votes for "for @a -> $val is rw {}" too
16:17 autrijus jhorwitz: fixing
16:17 Limbic_Region mj - there is already a todo test for it
16:17 Corion can somebody please look at t/subroutines/lvalue_subroutines.t test number 3 ? It's an eval_ok test, but I think it should be a fails_ok test.
16:17 Limbic_Region IIRC, all todo test at least get looked at before each release
16:17 Corion Limbic_Region: There is no established process, but I comb through them from time to time.
16:18 jhorwitz nothingmuch: i just hate problems i can't fix myself. ;-)
16:18 Corion ... and m*666 does a thorugh(sp?) test on them by s!todo_!!g (resp s!:todo(1)!!g)
16:18 nothingmuch jhorwitz: haskell is not as scary as it looks
16:18 jhorwitz i know -- just haven't had the time to dedicate to it
16:18 Corion jhorwitz: You can get along pretty well with cargo-culting in Haskell
16:19 * jhorwitz goes to lunch
16:19 nothingmuch no! no eat!
16:19 nothingmuch haskell! learn
16:19 Limbic_Region well, I just started learning p6 jhorwitz - Haskell is next on the list
16:19 nothingmuch calories are for weenies
16:19 alinbsp has joined #perl6
16:19 Limbic_Region of course, I will likely start learning Haskell long before I have any proficiency in p6
16:19 alinbsp has quit IRC (Client Quit)
16:20 broquaint has quit IRC ("goto &pub;")
16:20 * theorbtwo sighs.
16:20 theorbtwo I should eat more.
16:20 theorbtwo However, I also want to figure out how to make newtype do my bidding.
16:21 Limbic_Region offer it lots of $$$ ?
16:21 * theorbtwo wishes he had lots of $$$ handy.
16:22 theorbtwo €€€ would come in handy as well.
16:22 Limbic_Region heh - I go sign the papers to put me in debt up the wazoo in less than 4 hrs - I know what you mean theorbtwo
16:23 theorbtwo We actually just restructured some of ours.  Not a hugely lower payment, but every little bit helps.
16:24 Corion At least in .de, interest rates are pretty low at the moment.
16:24 Limbic_Region I am amazed at how many bank type folks (even those that work in the mortgage department) don't understand amortization
16:25 wolverian has quit IRC (Remote closed the connection)
16:25 Limbic_Region You could sense the glazed eyes when I said "making the minimum payment spread over 2 payments a month instead of 1 would reduce the 30 year loan by 6 years"
16:26 wolverian has joined #perl6
16:26 mj for '*.t' in 't' :recursive, :skip_dirs('.svn')   $line =~ s{,\s*\:todo\(1\)}{}g;    $line =~ s{force_todo[^;]+;}{}g;  
16:26 mj Tests results history  ...  http://test.wikidev.net/Pugs_tests?action=history
16:26 Limbic_Region as if to say "if you are only making the minimum payment, how is it going to take less time to pay off the loan"
16:27 Corion Limbic_Region: The bank makes more money if you never amortize and only pay the interest.
16:27 Corion So the employees aren't educated to that fact.
16:27 Corion ... and mathematics is something most people eschew
16:28 Corion (although there are instructive tables)
16:28 jabbot pugs - 2403 - Promoted succeeding todo tests to real t
16:29 Corion Limbic_Region: But are you sure your bank calculates your interest/amortization per day? I imagine they calculate it per month and then it doesn't matter when you actually pay it as long as it's the same amount.
16:30 Limbic_Region [Corion] - yes, it is compounded daily
16:30 Corion Limbic_Region: Then every day counts, indeed.
16:31 Limbic_Region [Corion] - when interest is only calculated monthly, it is still calculated on the average daily balance - so it would still help
16:31 Limbic_Region otherwise you could pay it 1 day early and not get charged for any interest
16:31 Corion Limbic_Region: Not if they don't use the average daily balance but a fixed date.
16:31 mj URL can be usefull for backward compatibility check before release. And for "who broke Pugs" :-)
16:31 * Limbic_Region needs to stop thinking this is the chatterbox
16:31 Limbic_Region mj plus plus
16:32 Corion Limbic_Region: Heh - no, you're thinking of the wrong end of the fence. You have to pay for 30 days accumulated interest on the 1st. If you pay earlier, nobody cares. :)
16:33 * Limbic_Region hasn't ever been involved with a loan like that Corion, but he will take your word for it
16:34 Corion Limbic_Region: I don't know what the lending customs in .us are. Here, you get a fixed mortgage with monthly interest payments due a certain day.
16:34 Limbic_Region oh - there is every type of loan under the sun here
16:34 Limbic_Region for instance - there is an "interest only" loan - who in their right mind would ever take that?
16:35 Corion Limbic_Region: If you plan on winning the lottery ? :)
16:35 * Limbic_Region is going to win the lottery but he doesn't know when
16:36 Corion ... or a business that can deduct the interest but not the payments for the building, and wants to "rent" the building from the bank.
16:36 Corion changes topic to: pugscode.org <Overview Journal Logs> | smoke/win2k (occasional): http://xrl.us/fqum (25/4554, r2403), Mac OS X (62/4506, r2362), Linux (38/4508, 2381) | pugs.kwiki.org
16:37 Limbic_Region I guess one might be looking at a short term investment and hoping that the appreciation in value exceeds that of the interest of the loan of the period of occupency
16:38 Corion Limbic_Region: True - if you plan on reselling quickly, you could take up such a mortgage...
16:38 autrijus er.
16:39 autrijus jhorwitz: how do you concat two PMCs anyway
16:39 Limbic_Region autrijus - give them plenty of alchohol - they will find a way to come together
16:39 autrijus heh.
16:41 Corion In t/data_types/hash_ref.t, a cast error is untrappable by Pugs currently. That is bad, isn't it ? :)
16:42 Corion (there should be no cast error there anyway, but that's beside the matter :) )
16:42 Corion anyway - I need to gather some groceries outside ...
16:42 Corion &
16:44 Limbic_Region do all hash keys need to be quoted now?  so %hash{foo} isn't acceptable?
16:44 theorbtwo %hash{foo} is not.
16:45 Limbic_Region k
16:45 theorbtwo %hash<foo> is, with the <>s doing double duty, both quoting and hash-dereferencing.
16:45 Limbic_Region right
16:45 SamB has quit IRC (Read error: 104 (Connection reset by peer))
16:47 PerlJam theorbtwo: %hash{foo} is fine ... it just means something different ;-)
16:47 Limbic_Region right - foo is expected to be a function right?
16:49 PerlJam I believe so
16:49 PerlJam It might be more like "foo is expected to be a name that we've seen before" though
16:49 nothingmuch what is the name for 'all', 'any' etc? combinators?
16:49 mj IMO, nmake clean doesn't remove src/*.o and src/*.hi
16:49 * Limbic_Region is going to have a hard time transitioning between p5 and p6 thinking though the code itself is easy so far
16:50 Limbic_Region nothingmuch - junctions?
16:50 nothingmuch no, junctions are the result
16:50 nothingmuch i think
16:50 nothingmuch or maybe they are junctions, and junctive values are the result?
16:50 Limbic_Region i see where you are going
16:50 Limbic_Region well, using Q::S - the values are the eigenstates - so I would say junction/value
16:52 nothingmuch okay
16:52 nothingmuch i have a first draft
16:52 nothingmuch http://pugs.kwiki.org/?NothingMuchIsaAsshole
16:52 nothingmuch deals with autothreading
16:53 nothingmuch next i willl handle fp vs oo vs imperative balance
16:53 nothingmuch then lazyness/io
16:53 nothingmuch and then i will poll P6L, and try to see which semantics seem more problematic, mine or the current ones
16:53 Southen[a] has joined #perl6
16:57 Limbic_Region meeting &
16:58 theorbtwo Nice name.
16:58 Southen has quit IRC (Connection timed out)
16:58 * nothingmuch is constantly editing
17:02 theorbtwo I think the example we had before is better -- avg(3, 4, 5|6) # I'm not quite sure what score I got on the last assignment...
17:02 nothingmuch could you edit it? i'm not sure how to distill that
17:03 Corion has quit IRC (Read error: 113 (No route to host))
17:06 SamB has joined #perl6
17:08 jabbot pugs - 2404 - Use "given" (patch by misc)
17:12 dada has joined #perl6
17:13 nothingmuch theorbtwo: are you doing avg? or should i just change it?
17:13 theorbtwo You should do it.
17:14 theorbtwo I don't like changing other people's words.
17:14 nothingmuch what do you think should be different? just the line?
17:14 nothingmuch i usually need help with words =P
17:17 wilx has quit IRC (Read error: 131 (Connection reset by peer))
17:17 Aankh|Clone has joined #perl6
17:17 Corion has joined #perl6
17:18 ingy gugod: ping
17:18 gugod ingy: pong
17:18 nothingmuch gugod: ping2
17:18 nothingmuch did you look at that spork/s5 stuff?
17:18 ingy gugod: where is the mail forwarding on freepan
17:19 osfameron has quit IRC ("Leaving")
17:19 ingy I thought [email@hidden.address] forwarded to ttul
17:19 gugod ingy: freepan.org mail is handled by 0 mail3.zoneedit.com.
17:20 ingy grr
17:20 ingy we can maybe triage freepan when you are here
17:20 * nothingmuch goes to make tea
17:22 nnunley has quit IRC ("home again, home again.")
17:22 castaway tea!
17:22 gugod nothingmuch: yes I did, that looks quite ok
17:23 gugod nothingmuch: except
17:23 gugod nothingmuch: except the -showconf ... I wonder if it's necessary
17:28 Aankhen`` has quit IRC (Read error: 110 (Connection timed out))
17:29 autrijus jhorwitz: all fixed!
17:29 nothingmuch -showconf is something else
17:29 nothingmuch i needed it to be sure of somet stuff
17:30 nothingmuch i think it's helpful to someone just starting to dabble with spork
17:30 nothingmuch to see what parameters are available
17:30 autrijus jhorwitz: factorial, your "hello, world", mandelbrot etc
17:30 CapoeiraB has joined #perl6
17:30 jhorwitz autrijus: and i just got back from lunch
17:30 jhorwitz autrijus++
17:30 nothingmuch autrijus: if you have (time & patience) > threshold (not autothreaded!): http://pugs.kwiki.org/?NothingMuchIsaAsshole - covers one part of three
17:31 nothingmuch i'd like to have some feedback from someone whose seen the insides of these messes
17:31 autrijus what insides? :)
17:31 nothingmuch pugs, silly
17:31 autrijus <- not cabal
17:31 autrijus oh. you mean implementation.
17:31 nothingmuch yep
17:32 nothingmuch i don't care about the insides of desing
17:32 nothingmuch they are very talented people
17:32 nothingmuch very smart
17:32 nothingmuch but with all due respect to genius, this is all in theory
17:32 nothingmuch and that isn't enough
17:32 theorbtwo Not only that, but some of them, I think, don't code much.
17:33 nothingmuch at least not daytime job style code
17:33 nothingmuch where you have factors like idiot predecessors
17:33 nothingmuch other people's modules which don't always play nice, despite usefulness
17:33 ingy gugod: ping
17:33 nothingmuch workarounds in old code for problems that were fixed in more recent versions of (perlsome_module)
17:33 ingy gugod: where is FreePAN::SVNAdmin??
17:33 nothingmuch .... the list goes on.
17:34 gugod ingy: http://tpe.freepan.org/rep​os/gugod/FreePAN-SVNAdmin/
17:34 autrijus woot. hangman.p6 is very close to working.
17:34 autrijus (targetting parrot)
17:34 autrijus need file ops
17:34 gugod ingy: oh but we didn't finish the pre-commit-hook hack stuff
17:34 ingy gugod: ok, sorry, I'm being  dumb
17:35 ingy I just want it to make some new accounts
17:37 autrijus jhorwitz: hacking on src/Pugs/Compile/Parrot.hs should be very straightforward
17:38 autrijus jhorwitz: so if you found a failure, try if you can fix it :)
17:38 autrijus jhorwitz: you want committer bit?
17:38 jabbot pugs - 2405 - * rewritten monadic Parrot compiler. mos
17:43 justatheory has quit IRC ()
17:48 ilogger stops logging #perl6 at Wed Apr 27 17:48:21 2005
17:48 ilogger stops logging #perl6 at Wed Apr 27 17:48:21 2005
17:48 ilogger starts logging #perl6 at Wed Apr 27 17:48:43 2005
17:48 ilogger has joined #perl6
17:49 nothingmuch ilogger->admin++
17:51 jhorwitz autrijus: should have commit already (just haven't comitted anything yet)
17:51 chady has joined #perl6
17:52 ninereasons has joined #perl6
17:55 autrijus so
17:56 autrijus I think I'll change all :todo(1) to :todo
17:56 autrijus because it's vastly clearer
17:56 autrijus objections?
17:56 nothingmuch yeah, that's nicer
17:56 nothingmuch autrijus: any prelimenary comments about me being an asshole?
17:57 Odin- has quit IRC (Read error: 54 (Connection reset by peer))
17:57 sbkhh has joined #perl6
17:57 cognominal I thought the default value of trait/property was trait/property dependant
17:58 autrijus cognominal: here it is but simple pair.
17:58 autrijus and simple pair assumes (1)
17:58 nothingmuch http://www.abridgegame.org/pipermail​/darcs-devel/2005-April/002161.html <-- makes you smile
17:58 autrijus :)
17:59 cookys has quit IRC (Read error: 104 (Connection reset by peer))
17:59 autrijus nothingmuch: so, you know, larry agrees with you
17:59 nothingmuch really?
17:59 autrijus and he thinks that autothreading should only be activated when there is a lexical pragma
17:59 nothingmuch how come it's this way then?
17:59 autrijus "use junctions", "use autothread"
17:59 nothingmuch i think autothreading should have nothing to do with lexical pragmas
17:59 autrijus i.e. when the user explicitly use it.
18:00 nothingmuch i think there are means of combination more suitable
18:00 autrijus at the caller's site
18:00 nothingmuch that is better than nothing
18:00 nothingmuch but remember the 1st and 2nd rule of perl cgi programming:
18:00 nothingmuch use strict;
18:00 nothingmuch use CGI;
18:00 nothingmuch do we want the 1st and 2nd rule of p6 sanity to be 'no autothread'?
18:01 justatheory has joined #perl6
18:01 PerlJam nothingmuch: no junctions
18:01 cognominal the third is:  use less;  #  :)
18:01 nothingmuch why no junctions? they are useful at the end of the day
18:01 nothingmuch but i must admit it does make things look a little rosier
18:02 PerlJam (I'm beginning to think that junctions will cause more confusion than problems solved)
18:02 autrijus ok. so to answer your question
18:02 integral Why do you need to disable autothreading?  Can the compiler make a mistake?
18:02 autrijus 01:59 < nothingmuch> how come it's this way then?
18:02 nothingmuch PerlJam: i would love to be able to do computations or predicate checking on N values at a time
18:02 G2 has joined #perl6
18:02 autrijus the answer is that, well, damian argues very strongly for the current way
18:02 nothingmuch I just don't want to risk confusing myself in the process
18:02 PerlJam nothingmuch: me too, but you and I are "advanced" users :-)
18:02 autrijus and has fielded off all oppositions ;)
18:02 nothingmuch autrijus: i'll google for a good excuse.. thanks!
18:03 autrijus check p6l for at least ten times of "disable autothreading" thrads.
18:03 autrijus threads
18:03 theorbtwo s/times/tons/
18:03 nothingmuch autrijus: the last 5 times or so since i was subscribed i was not so convinced, but then again i didn't have the patience to really look into it
18:04 chady has quit IRC ("leaving")
18:05 PerlJam After all the p6l discussion on it, I've decided that autothreading is one of those things that will need to be enabled by default and used before we know if it should really be disabled by default.
18:07 nothingmuch isn't the overload::StrVal lesson enough of an argument against such behavior?
18:07 autrijus PerlJam++ # wise
18:07 nothingmuch and this is much much more fatal
18:08 Corion Oooo - more Parrot compiling fixes in r2405 !
18:10 Limbic_Region 8 unexpectedly succeeded?
18:10 autrijus cognominal: yeah, and with this change, we are very close (three days or so of work) at actually being able to run the test suite with --runparrot
18:10 Corion Heh: #        Got: pugs.exe: fnord
18:10 Limbic_Region I thought mj marked all passing todo tests as real tests
18:11 nothingmuch Limbic_Region: they keep changing =)
18:11 Corion Limbic_Region: Only for his private testing, not in the real branch
18:11 * Corion is fixing the unexpected compilation successes
18:11 Corion Maybe I'll add more examples to the test suite.
18:11 nothingmuch oh
18:12 autrijus Corion: you surely can, but I don't think that work in the long run
18:12 autrijus the idea is once Test.pm works for parrot
18:12 autrijus we have a "make smoke BACKEND=Parrot"
18:12 autrijus or something like that
18:12 autrijus that tests parrot regularly
18:12 Corion autrijus: Ah, that's a good idea too
18:12 nothingmuch autrijus++
18:13 nothingmuch beh
18:13 ingy autrijus: have you seen Test::Chunks yet?
18:13 Corion Whoa. Somebody touched many/all tests?
18:13 Corion (in r2406)
18:13 * nothingmuch is reading and reading and reading and still can't find a solid argument as to "why" damian wants it this way, not only how and what.
18:14 autrijus ingy: yes. good idea!
18:14 Corion I want (implicit) autothreading, so the language gets parallel without me worrying about it.
18:14 autrijus Corion: me. all :todo(1) is now :todo
18:14 Corion Aaaah.
18:14 nothingmuch Corion: if you're not going to worry about it, who will when it breaks?
18:14 ingy autrijus: I want to port to Perl6 as soon as we get classes
18:14 Corion nothingmuch: I expect me to write parallelizable code. :)
18:15 autrijus ingy: I'll let you know what 6.28.0 comes out :)
18:15 nothingmuch Corion: so you don't want to use any useful modules that didn't program defensively enough?
18:15 Corion ... at least for the cases where I use any() and all() (and sort() and map() and grep() )
18:15 Corion nothingmuch: Those modules then obviously aren't useful :)
18:15 nothingmuch or would you rather just say "this is OK to parallelize'
18:15 autrijus but probably around 6.2.5 will have usable classes already
18:15 ingy autrijus: it is my cleanest Spiffy code, so I'll be interested in how much Spiffier Perl6 version is
18:16 nothingmuch Corion: i'm thinking of a witty retort
18:16 autrijus wow. memory game is super fast now
18:16 Corion nothingmuch: No, I want the language/library to have less guarantees about the execution order. If anybody knows that map/grep/any/all will parallelize, nobody will rely on not being parallel.
18:16 autrijus each flip takes less than a second
18:16 nothingmuch they just push it down
18:16 nothingmuch btw- my semantics don't do away with autothreading
18:16 nothingmuch Corion: so how can we convert p5 to p6?
18:17 autrijus the performance has really came a long way
18:17 Corion nothingmuch: By manually converting.
18:17 Corion ... or by using Ponie
18:17 PerlJam nothingmuch: that's Larry's job.
18:17 nothingmuch Corion: i sort of agree with that, but i doubt it will happen
18:17 autrijus ... or PPD
18:17 nothingmuch PerlJam: larry is not a god
18:17 ingy gugod: I'm having a bad freebsd day. where is the http config again?
18:18 PerlJam nothingmuch: no, but it's is a problem he is actively working on.
18:18 autrijus /usr/local/etc/apache2/httpd.con
18:18 autrijus f
18:18 Limbic_Region nothingmuch - I believe PerlJam was referring to the fact that he was working on...nevermind
18:18 Limbic_Region PerlJam beat me to the punch
18:18 ingy autrijus: thx
18:18 PerlJam Limbic_Region: type faster!  ;)
18:18 jabbot pugs - 2406 - * change `:todo(1)` to `:todo` for great
18:18 gugod ingy: ever newly installed software config goes onder /usr/local/etc
18:18 Limbic_Region I likely do type faster, I was looking for the thread where Larry talked about it
18:18 gugod s/onder/under/
18:19 ingy gugod: gotcha
18:19 sbkhh is now known as Odin-
18:19 Limbic_Region PPD has last remaining memory leak plugged, perhaps someone wants to consider using it to do the p5 -> p6 conversion when Larry mentioned his project to change the parser
18:19 ingy gugod: now we will also be hacking MacKwiki when you arrive
18:19 gugod FreeBSD -- A /usr/local OS
18:19 gugod ingy: of course
18:19 ingy I need Tiger
18:19 gugod ingy: I have some secret module for you already
18:20 ingy :p
18:20 gugod ingy: which I can't release yet
18:20 gugod ingy: not after Tiger (shhhh...)
18:20 nothingmuch has left
18:20 ingy does it contain the Tiger dmg? :p
18:20 nothingmuch has joined #perl6
18:20 gugod haha
18:20 PerlJam "I've discovered a lovely proof of this theorem but it's too big to write in the margin here"
18:20 decay hm, there's a warez copy out, isn't it?
18:21 PerlJam gugod == Fermat?
18:21 gugod There is no enough disk space so I can't make the tarball for releasing it
18:21 autrijus Limbic_Region: where is PPD?
18:21 * nothingmuch wonders whether this time it's a good idea to wait 2-3 weeks before installing a new OS
18:22 Corion nothingmuch: Wait for Tiger service release 1 :)
18:22 nothingmuch decay: prolly gold masters or the first dev dvd
18:22 Limbic_Region autrijus - PPD from AS?
18:22 nothingmuch Corion: i won't mind version 0 if it's stable
18:23 autrijus Limbic_Region: PPD from Larry :)
18:23 PerlJam FWIW, here's an email about what Larry is doing regarding converting perl5 to perl6: http://groups-beta.google.com/group/perl.p​erl6.language/browse_thread/thread/55f891b​192f20c14/e9e890786ee32357?q=Larry+Wall+pe​rl+translator&amp;rnum=1#e9e890786ee32357
18:23 Limbic_Region where is it status wise you mean?  
18:24 Limbic_Region sorry - I am confused
18:24 Limbic_Region I really should be heading home preparing to sign my life away as they say
18:24 * Limbic_Region closes in an hour and a half
18:25 autrijus :)
18:25 autrijus good luck!
18:25 Limbic_Region has quit IRC ("dead man walking")
18:25 awwaiid has quit IRC (Read error: 104 (Connection reset by peer))
18:28 jabbot pugs - 2407 - Promoted unexpected -CParrot compilation
18:31 Corion r2407 - http://datenzoo.de/pugs/win2k.html
18:39 simcop2387-vnc has quit IRC ("Client exiting")
18:39 simcop2387-vnc has joined #perl6
18:40 simcop2387 has quit IRC ("Client exiting")
18:40 simcop2387 has joined #perl6
18:42 nothingmuch has quit IRC (Remote closed the connection)
18:43 nothingmuch has joined #perl6
18:44 Corion I'm adding tests for things that already work but don't seem to have tests. Like that my $ref = { foo => 'bar' }; say $ref[0] # dies
18:46 Aankh|Clone is now known as Aankhen``
18:51 ninereasons autrijus, the interactive shell is misbehaving.  
18:51 ninereasons it requires subs to be declared with 'my'
18:51 ninereasons sub hello($x){"hello $x"}
18:51 ninereasons say hello 'world'
18:51 ninereasons *** Error: No compatible subroutine found: &hello
18:51 ninereasons my sub hello($x){"hello $x"}
18:51 ninereasons sub {...}
18:51 ninereasons say hello 'world'
18:51 ninereasons hello world
18:55 ninereasons r2405
18:58 jabbot pugs - 2408 - New test to check that Arrayrefs used as
18:59 wolverian has quit IRC ("leaving")
18:59 wolverian has joined #perl6
19:04 Shadow_ has joined #perl6
19:04 Shadow_ Hallo Guys
19:04 Shadow_ Guys, i has test1.pl, that declare 'my $a = "Hello World"', and after that call 'require "test2.pl". In test2.pl exist next string 'print $a'. But undefined error raised. How i can export all variables to test2.pl from test1.pl ?
19:04 theorbtwo Hello, shadow.
19:05 theorbtwo Are you sure you're using perl 6?
19:05 mauke hahaha
19:05 Shadow_ yeah
19:06 mauke where did you get it?
19:06 PerlJam Shadow_: then the short answer is:  you can't.
19:06 Shadow_ mauke: it is my code
19:06 mauke Shadow_: no, perl6
19:06 Shadow_ PerlJam: why? I need split my big file to several little
19:06 Shadow_ mauke: no matter
19:07 mauke Shadow_: idiot
19:08 theorbtwo Don't do that in perl 6.  You shouldn't do that in perl 5 either, but that's a question for another channel.
19:08 Shadow_ theorbtwo: hehe, all does in one big file? :)))
19:09 theorbtwo No.
19:09 theorbtwo Export subs, not variables, generally, and do it with "is exported".
19:09 theorbtwo What error message does that get?
19:10 mauke hmm, can you say 'my $lexical is exported;'?
19:10 Shadow_ theorbtwo: ok, thanks
19:11 Shadow_ theorbtwo: but if i need create one header file, that contain big collection of constant, and need to use these constant in several files?
19:11 wilx has joined #perl6
19:11 Shadow_ theorbtwo: is there better way to do it?
19:12 castaway sounds C-ish
19:12 autrijus ninereasons: fixed.
19:12 Shadow_ castaway: yeah, you right
19:12 autrijus committing
19:12 theorbtwo Create an abstraction that doesn't use magic numbers, and do that.
19:12 autrijus you can use "our" :)
19:12 castaway ick
19:12 autrijus and that would work.
19:13 castaway constants are subs in p5, what are they in p6 ?
19:13 autrijus they are variables in perl 6.
19:13 autrijus but subs are really only variables.
19:14 theorbtwo our $foo := 10 is exported
19:14 theorbtwo ?
19:14 autrijus that works
19:14 castaway so one can export them?
19:14 theorbtwo Er, ::= 10.
19:14 PerlJam perl6 will have enumerated "constants" too
19:14 autrijus sure can.
19:14 castaway ok then.
19:14 autrijus oh. ::=.
19:14 autrijus we can actually implement that now.
19:14 * autrijus goes
19:14 theorbtwo You can export variables in perl 5 as well, it's just generally considered poor form.
19:14 autrijus someone write a test?
19:14 Shadow_ YES!
19:15 autrijus my $x; say $x; $x ::= 9;
19:15 autrijus should print 9
19:15 Shadow_ I forget about 'our' prefix!!
19:15 Shadow_ autrijus: thanks!
19:15 autrijus np
19:15 mauke hahaha
19:15 ninereasons that was fast, autrijus; thank you.
19:15 autrijus np :)
19:16 Shadow_ last year not perl programming, only C :)
19:16 PerlJam Shadow_: and now perl6?
19:17 Shadow_ PerlJam: yeah, perl6 and perl5
19:17 * Shadow_ write linux drivers
19:17 mauke Shadow_: you might want to read http://perl.plover.com/FAQs/Namespaces.html
19:18 Shadow_ mauke: 10x
19:18 mauke no, once or twice should be sufficient
19:19 PerlJam heh
19:19 PerlJam http://donate.perlfoundation.org/
19:19 PerlJam Something sent there should be sufficient
19:22 xerox has quit IRC ("ERC Version 5.0 (CVS) $Revision: 1.751 $ (IRC client for Emacs)")
19:28 jabbot pugs - 2409 - * repair interactive shell.
19:36 * Shadow_ wrote perl script on 4000 lines and wanna split it to several parts :)
19:36 autrijus my $j; $j = 9; $j := 10; my $x ::= $j; $x;
19:36 autrijus this prints "9". nice.
19:36 autrijus someone please add a test? :)
19:38 jabbot pugs - 2410 - * `my $var ::= expr` works.
19:42 lhooq has joined #perl6
19:43 Aankhen`` has quit IRC ("Quote: "We (heart) comic sans... and we'll kill animals to prove it" [Time wasted online: 2hrs 25mins 25secs]")
19:43 * nothingmuch summons stevan
19:47 masak how does this summoning thing work, anyway? :)
19:47 gcom has joined #perl6
19:48 nothingmuch i don't know
19:48 nothingmuch it worked once for me
19:48 nothingmuch i just tried it, and 2-3 minutes later stevan was here,
19:48 masak maybe he reads the html logs
19:48 theorbtwo Perhaps it was just luck.
19:48 nothingmuch in that case he reads them through a crystal ball =)
19:50 masak it could be possible to drop a bot in here which notifies you of someone mentioning your name
19:50 dada has quit IRC (Read error: 145 (Connection timed out))
19:50 Corion Summoning depends on the phase of the moon, the right location, and of course, the right sacrifices!
19:51 Corion For some entities it is enough to say their name three times.
19:52 masak sounds scary :) what if i changed my name to stevanstevanstevan? :)
19:52 Corion masak: I'm not sure if it works for stevan :)
19:52 masak lol
19:55 Corion Chat!Zilla has the habit of playing a sound file whenever my name gets mentioned here.
19:56 nothingmuch Corion: Corion Corion!
19:56 * nothingmuch makes music
19:56 Corion nothingmuch: Only one beep per line :)
19:56 Corion ... consider nopasting it :)
19:56 nothingmuch =/
19:57 mauke that means we should append "Corion" to all our lines
19:57 mauke using black on black text
19:58 Shadow_ has left
19:58 jabbot pugs - 2411 - * It's not PIR, it's IMC
20:02 Corion Heh. examples.t dives into an infinite loop/heap exhaustion :)
20:02 Corion ... and nested_pairs.t finds no compatible subroutine &skip anymore ... Weird
20:05 ninereasons you might need to make install, to get a new Test.pm, Corion  ?
20:05 ninereasons (guessing)
20:05 MobyTurbo has joined #perl6
20:05 Corion ninereasons: Hmmm - usually my script does Just that, but I'll retry. skip() was there before, so I wonder why it should not work anymore now ...
20:06 Corion ... and I never make install - I only do make().
20:06 autrijus Corion: it worksforme
20:06 autrijus nested_pairs too
20:06 Corion I'll nuke it from space and recompile then... I get various failures anyway ...
20:08 jabbot pugs - 2412 - * tweak some CGI installation instructio
20:09 xerox has joined #perl6
20:10 ninereasons Corion, t/examples/examples.t (examples/functional/fp.p6) is hanging now for me, also.  
20:10 Corion ninereasons: It hangs because a subprocess hangs - kill pugs and it should continue.
20:10 ninereasons exactly right, Corion
20:10 Corion ... It'll output a message that the heap is exhausted soonish otherwise (256MB here)
20:12 autrijus got that too
20:13 autrijus fixing
20:14 * theorbtwo wonders why AUTHORS sometimes ends up with extra \cM
20:14 autrijus because DOS editors ;)
20:15 autrijus fixed, sorry.
20:15 theorbtwo Shouldn't svn magic take care of it?
20:15 autrijus r2413
20:15 autrijus theorbtwo: prolly not
20:15 jhorwitz has quit IRC ("Chatzilla 0.9.67 [Firefox 1.0.2/20050317]")
20:15 Corion Maybe we should set up guard scripts, like cvs can have
20:16 Corion ... automagically kick off a smoke test on checkin for example :)
20:16 Corion (and automagically add a newline at the end of the file, especially for me ;) )
20:16 theorbtwo The other users of the box might not like that suggestion.
20:16 Corion theorbtwo: Bah. :)
20:18 jabbot pugs - 2413 - * oops, multi sym has to be in order.
20:19 theorbtwo autrijus: I finally figured out the secret syntax of newtype, I think, but now I see some very strange-looking type errors.
20:19 theorbtwo src/Pugs/AST.hs:1309:24:
20:19 theorbtwo    Couldn't match `Eval Val' against `Eval Val'
20:19 theorbtwo      Expected type: Eval Val
20:19 theorbtwo      Inferred type: Eval Val
20:19 theorbtwo    In the definition of `force': force (MkThunk c) = c
20:19 theorbtwo    In the definition for method `Pugs.Types.Thunk.force'
20:19 Corion theorbtwo: That's a mighty strange error indeed :)
20:19 theorbtwo (They aren't all quite that silly, but many of them look quite odd.)
20:20 zaphod has joined #perl6
20:21 theorbtwo BTW: The secret syntax is that the stuff after the constructor name is not the argument to the constructor.
20:21 autrijus theorbtwo: whoa. you sure you changed AST.hs-boot as well?
20:21 theorbtwo Oh.  Whoops, that might have something to do with it.
20:22 theorbtwo Ah, that's much better.
20:23 autrijus now to actually add instances :)
20:23 autrijus (most should be really straightforward)
20:23 autrijus let the typechecker be thy guide
20:23 theorbtwo Right -- "No instance for (Monad Eval) arising from...".
20:23 autrijus and mostly it should be just unpack the type and delegate downwards
20:24 autrijus return a = MkEval (return a)
20:24 nothingmuch gaal++
20:24 autrijus etc.
20:25 theorbtwo Cool.
20:25 theorbtwo Hm, I named my constructor Eval, not MkEval, so the existing code doesn't need to change.
20:25 theorbtwo Is this a problem?
20:26 zaphod has quit IRC ("1;")
20:27 autrijus call it MkEval :)
20:27 autrijus it doesn't matter either way.
20:27 autrijus the existing code won't need to change.
20:31 Corion Give it a different name and then introduce Eval = MkEval
20:31 Corion :-)))
20:32 Corion (I prefer (and use) evil = eval; so I can then have evil($string))
20:32 autrijus newtype (Eval a) = MkEval ...
20:32 * theorbtwo uses x as the type variable just cauze.
20:33 autrijus that's fine.
20:33 theorbtwo newtype (Eval x) = MkEval    (ContT Val (ReaderT Env IO) x)
20:33 autrijus yup.
20:33 theorbtwo instance Monad Eval where {a >>= b = MkEval (a) >>= MkEval (b)}
20:33 autrijus I think you can derive Typeable too.
20:33 autrijus deriving (Typeable)
20:34 theorbtwo In any case, I now get an error in Pugs.Types.Hash No instance for (Monad Eval).
20:35 theorbtwo It hasn't yet compiled AST.hs, only the -boot, and the docs (section 4.6.9) explictly say /not/ to put instances in the -boot file.
20:36 lhooq has quit IRC (Read error: 110 (Connection timed out))
20:38 autrijus hm.
20:38 autrijus I think we lose.
20:39 autrijus so: probably introduce a
20:39 autrijus retEval :: a -> Eval a
20:39 autrijus export that in AST.hs-boot
20:39 autrijus implement it in AST.hs as
20:39 Corion Heh. pugs.exe -e "" -ne say # doesn't anymore.
20:39 autrijus retEval = return
20:39 autrijus and use retEval in Types.
20:39 autrijus theorbtwo: makes sense?
20:39 autrijus Corion: oh right.
20:39 autrijus the $_ defaulting is borken
20:40 Corion autrijus: Ah
20:40 autrijus would work if you say 'say $_'
20:40 autrijus add / untodo tests
20:40 Corion Hmmm. Maybe I should make the "-n" code more defensive :)
20:41 Corion r2413 - http://datenzoo.de/pugs/win2k.html # some breakage, due to not defaulting to $_ at the moment
20:42 theorbtwo That feels like a big breaker in the way you use Eval vs the way you use all other monads... though if you only have to use it in the things compiled between AST-boot and AST, it might be OK.
20:42 autrijus theorbtwo: that is the idea.
20:42 autrijus I think that's okay.
20:42 autrijus Corion: it's repaired
20:43 Corion resmoking ;)
20:44 autrijus sorry ;)
20:44 theorbtwo That didn't help -- same error.
20:44 autrijus huh?
20:44 theorbtwo I'd assume it has a problem with >>= missing as well as return.
20:45 autrijus oh. argh!
20:45 autrijus try putting instance declarations in .hs-boot :-/
20:45 theorbtwo Donno why it would complaign about the last thing in the file first, though.
20:45 theorbtwo Same thing.
20:45 theorbtwo Can we move the definition of Eval to a file that's compiled earlier?
20:45 autrijus yes.
20:46 autrijus Internals would be it.
20:46 autrijus and define Monad there
20:46 autrijus instance Monad, that is
20:48 ninereasons is it a bad idea of maintain a MANIFEST ?
20:48 ninereasons s/of/to/
20:48 jabbot pugs - 2414 - * repair $_ defaulting... I hope
20:48 Juerd Why would it be a bad idea?
20:48 ninereasons I don't know; we just don't have one
20:48 theorbtwo Except the defintion of Eval needs Val and Env, which are in AST.hs-boot, and getting that presumably puts us back where we started.
20:48 ninereasons I wondered why
20:49 theorbtwo Because then you have to keep it up to date all the time, rather then just correcting it just before releases.
20:49 iblechbot has quit IRC (Connection timed out)
20:49 autrijus ninereasons: because it costs extra commits with no gain
20:49 Juerd ninereasons: Hm, there used to be one, so the reason why can probably be found in version control logs.
20:49 Juerd Or that.
20:49 autrijus theorbtwo: actually. Internals can use .hs-boot.
20:49 autrijus # SOURCE #
20:49 autrijus which would provide Val and Env.
20:49 autrijus problem solved
20:50 ninereasons autrijus, if we had one, it would make 'make distclean' a valid target;  # small gain.
20:50 autrijus however, you would have to rewire .hs-boot to not use Internals
20:50 autrijus prolly happy.
20:50 autrijus ninereasons: you can always copy an old MANIFEST over
20:50 Juerd afk  # 24s04e19
20:50 autrijus or "make manifest"
20:53 pernod has joined #perl6
20:53 autrijus theorbtwo: I need to sleep now... best luck wrestling with the dependency monster
20:53 autrijus please refactor away as you see fit :)
20:53 autrijus journal up; g'nite folks
20:53 * autrijus waves &
20:53 ninereasons night && thanks.
20:54 theorbtwo G'night, autrijus.
20:54 theorbtwo Thanks for getting me started.
20:54 * theorbtwo sighs -- I should ask questions earlier.
20:55 Corion Heh. Now the type of abs() broke :)
20:55 Corion r2414 - http://datenzoo.de/pugs/win2k.html
20:56 Corion ... but that's about all breakage that happens
20:56 autrijus Scala is fun
20:56 autrijus but as fun as it is, I still must sleep. :)
20:57 autrijus theorbtwo: rock on! :) I think #haskell may also be of help
20:57 ninereasons "scala" as in http://scala.epfl.ch/ , I guess ?
20:58 autrijus *nod*
20:58 * autrijus waves again &
20:59 Corion Hmmm. Weird - I don't see at all where op1Numeric defaults to $_ if nothing is given...
21:00 Corion Ah. In the signature. Except that it doesn't completely work. Weird.
21:01 * Corion &
21:01 Corion has quit IRC ("Chatzilla 0.9.68a [Firefox 1.0.3/20050414]")
21:04 gaal yay! #line works :)
21:05 nothingmuch gaal++
21:06 gaal but this needs plenty of testing. do you have that patch to the harness, that drops the timestamps? makes regresstesting locally easier.
21:06 gaal of course i can grep -v it :)
21:06 gaal yaml++
21:09 pernod has left
21:10 G2 has quit IRC ("oops")
21:17 nothingmuch sorry
21:17 nothingmuch you can darcs pull the repo
21:17 nothingmuch and darcs unpull the patch
21:17 nothingmuch and just run that
21:17 nothingmuch thank you cherry picking
21:17 gaal for now i'll stick with the grep-v'ing, thanks
21:18 gaal if i get distracted now, i won't finish this
21:18 nothingmuch gaal++
21:18 nothingmuch although darcs keeps you undistracted
21:18 nothingmuch did i send you that link?
21:18 gaal what link?
21:18 nothingmuch http://www.abridgegame.org/pipermail​/darcs-devel/2005-April/002161.html
21:19 gaal :)
21:42 gaal TDD++; # found some bugs for me, free!
21:42 nothingmuch =D
21:42 nothingmuch indeed
21:44 gaal and incidentally,
21:44 gaal I love The Koeln Concert
21:44 gaal so beautiful.
21:47 nothingmuch dunno it
21:48 gaal Keith Jarrett
21:54 Steve_p has joined #perl6
22:04 cjn has quit IRC (Read error: 110 (Connection timed out))
22:06 Limbic_Region has joined #perl6
22:14 nothingmuch_ has joined #perl6
22:16 nothingmuch has quit IRC (Read error: 60 (Operation timed out))
22:18 mj has quit IRC (Read error: 104 (Connection reset by peer))
22:18 nothingmuch_ is now known as nothingmuch
22:19 MobyTurbo has quit IRC (No route to host)
22:25 didie_p6 has quit IRC (Read error: 60 (Operation timed out))
22:31 castaway_ has joined #perl6
22:34 Limbic_Region stevan ping
22:34 nothingmuch not here
22:34 Limbic_Region thanks
22:34 theorbtwo has quit IRC (Read error: 60 (Operation timed out))
22:35 ihb has joined #perl6
22:36 b6s_ has joined #perl6
22:36 b6s has quit IRC (Read error: 113 (No route to host))
22:37 elmex has quit IRC ("... gute nacht, hab dich lieb bani")
22:39 gcom has quit IRC ("using sirc version 2.211+KSIRC/1.3.12")
22:44 SamB has quit IRC (Read error: 104 (Connection reset by peer))
22:46 castaway has quit IRC (Read error: 110 (Connection timed out))
23:00 Limbic_Region has quit IRC ("tired")
23:01 SamB has joined #perl6
23:28 broquaint has joined #perl6
23:34 larsen has quit IRC ("later")
23:42 mugwump autrijus: darcs pugs sync daemon needs prodding
23:53 Shillo has joined #perl6
23:53 Shillo Finally. Done bootstrapping ghc. Pugs works. Wooot!
23:57 mauke did it take more than 50 hours?
23:57 Shillo Took 3. With a 22 hours break in the middle.
23:58 mauke nice. my computer is still trying to create libHSbase.s
23:58 Shillo And one compiler crash due to flaky CPU.
23:58 mauke er, .a
23:58 Shillo Oif.
23:58 Shillo Gig of RAM really, really helps.
23:59 mauke huhu, 64 megs here

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

Perl 6 | Reference Documentation | Rakudo