»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
acegrimm aye 02:14
ajs evening all 03:42
sorear good * #perl6 03:43
sorear hello ajs 04:12
cognominal does perl 6 supports what coffeescript calls destructuring assignment. It can be seen as a form of assignement on pattern matching. jashkenas.github.com/coffee-script/ 04:13
it is a feature of javascript harmony btw. 04:14
sorear rakudo: my [$x, $y] := [1,2]; say $y 04:15
p6eval rakudo e3bd9a: OUTPUT«===SORRY!===␤Malformed my at line 22, near "[$x, $y] :"␤»
sorear rakudo: my :([$x, $y]) := [1,2]; say $y 04:16
p6eval rakudo e3bd9a: OUTPUT«===SORRY!===␤Malformed my at line 22, near ":([$x, $y]"␤»
sorear rakudo: (-> [$x, $y] { say $y })([1,2]);
p6eval rakudo e3bd9a: OUTPUT«2␤»
sorear yes, but the parsing isn't fully implemented
cognominal oh, I remember now. I already bug jnthn on that 04:17
sorear (I haven't actually looked at the link, I'm working from the Haskell definition of destructuring binders)
cognominal and indeed, I was thinking haskell the first time I asked
for lack of a Perl 6 with a javascript backend, coffeescript is pretty nice. 04:18
and destructuring is pretty nice when extracting data from the DOM 04:19
sorear perl 6 with a javascript backend would have far, far too much overhead 04:20
perl 6 is not designed to run on a specific VM
it doesn't elegantly map to Javascript primitives the way Javascript-based languages do
cognominal When I reread myself I realize I speak english like Ali G. :( 04:22
sorear Who? 04:23
sorear Don't be so hard on yourself. Your English is better than quite a few "native" speakers I know 04:24
cognominal www.youtube.com/watch?v=fOIM1_xOSro # ali g interviews noam chomsky 04:25
JimmyZ good afternoom, #perl6
sorear hello JimmyZ 04:37
jdhore OK, I am currently working on the release of Rakudo 2011.03 05:01
PerlJam jdhore++ 05:04
JimmyZ hi JimmyZ 05:20
er, hi sorear
mberends colomon: thanks, replied to Aaron Sherman's comment :) 05:48
ajs oh? 05:52
mberends (the reply must be moderated before it appears publicly) 05:55
ajs ah
ajs should I just keep reloading or does someone want to fill me in? ;) 05:55
mberends commute &
ajs So, I've been working on that... I found one bug that I think was causing some undue speedup (still getting right answers for the given inputs, but still a bug). 05:59
But it's still performing well
yeah, since I fixed the bug, I'm no longer beating colomon, but I'm still scaling decently. 06:04
jdhore Are any rakudo people around? 06:10
moritz_, please help 06:14
colomon jdhore: what's up? 06:58
jdhore I've got a failing test and i'm not sure what to do with it 06:58
Test Summary Report 06:59
-------------------
t/spec/S02-builtin_data_types/instants-and-durations.t (Wstat: 0 Tests: 13 Failed: 1)
Failed test: 13
colomon that's okay, it's been an intermittent failure for a while
jdhore so just ignore it? 07:00
colomon yes
jdhore OK
dalek kudo: e70f27d | jdhore++ | / (3 files):
[release] Add announcement, update release gude and add myself to
07:06
kudo: 5e60355 | jdhore++ | VERSION:
[release] bump VERSION
jdhore whoo 07:19
Rakudo 2011.03 release complete!!!!
ajs Wow, grats!
jdhore thanks 07:20
colomon \o/ 07:22
colomon moritz_: Test 13 in S02-builtin_data_types/instants-and-durations.t isn't valid, at least as things are currently implemented in Rakudo. $t1 - $t0 uses Real.Rat internally, which is only accurate to 1e-6. So there's no reason to expect that $t0 + ($t1 - $t0) will equal $t1 exactly. 07:32
moritz_ colomon: I think the test should be modified to allow a diff of 1e-6 or so 07:53
colomon moritz_: IMO, it should probably use is_approx and call .x on both sides. 07:54
moritz_ or use rats consistently 07:58
tadzik hello 08:17
moritz_ jdhore++ # rakudo release 08:19
jdhore moritz_, thanks, dude
moritz_ jdhore: how did you find the release process? 08:20
any difficulties or time drains? 08:21
jdhore Pretty easy, actually, the most annoying part was waiting for all the tests in "make stresstest" to run...I have 8-cores, but they didn't parallelize (i didn't try make -j8 stresstest though, so that would fix my only annoyance if that is possible) 08:22
moritz_ jdhore: ah, TEST_JOBS=8 and a sufficiently new Perl 5 Test::Harness would have helped (see README) 08:23
jdhore ah
I'd love to do it again though 08:24
moritz_ feel free to add your name to docs/release_guide.pod 08:26
tadzik btw, didn't mberends appear twice in the announcement? 08:27
jdhore tadzik, I don't think so, though he may have once by nick and once by real name 08:28
moritz_ such things happen
tadzik yeah, that's what I mean. There's Martin Berends and there's martin :)
jdhore nope, there's a martin and Martin Berends
ah, I figured that may have been a different martin which is why i left it :) 08:29
tadzik yeah. For me the hardest part was probably figuring out who is who in the contributors.pl output :)
jdhore I think i'll go for my birth month (May) for the next release, but I could do April if no one volunteers by the time we near the release date. 08:30
moritz_ jdhore++ 08:31
good plan
dalek kudo: d8e5dec | jdhore++ | docs/release_guide.pod:
Add myself as the release manager for the May release.
08:34
ajs BBC headline: "Google buys Parrot to aid YouTube" 08:49
;-) 08:50
www.bbc.co.uk/news/technology-12757153
jdhore :D 08:55
tadzik :)
eso4g3_ soy gayyy 09:09
jdhore moritz_, do only R* releases get announced on rakudo.org? I just noticed that nothing was ever posted about 2011.02 09:11
moritz_ jdhore: yes, only R* releases
jdhore ah 09:11
moritz_ people confuse compiler and distribution releases
so we make the compiler releases less public 09:12
jdhore Yeah, makes sense.
eso4g3 my mother fuck your father
tadzik moritz_, can you? 09:13
jdhore moritz_, wow, looking at the download stats of R and R*, that's...yeah...Pretty apparent :P
tadzik oh, nevermind 09:13
tadzik flussence_: could github.com/flussence/p6-misc/blob/...ent.p6#L53 be just our Str multi method indent(0) ? 11:18
moritz_ tadzik: nope
tadzik that's not the same, yeah
moritz_ indent(0) boils down to (Int $ where 0)
not to ($ as Int where 0) 11:19
tadzik so it protects us from indent("foo")
flussence_ yeah, I tried most of the easy-looking things already
moritz_ rakudo: multi f($ as Int where 0) { say "yes" }; f "a"
p6eval rakudo d8e5de: OUTPUT«yes␤»
moritz_ flussence_: that's what you could use, if you don't like verbosity :-) 11:20
rakudo: multi f($ where 0) { say "yes" }; f "a"
p6eval rakudo d8e5de: OUTPUT«yes␤»
moritz_ works too, since smart-matching against a number automatically coerces 11:20
moritz_ TiMBuS: could you please open a new pull request for your second IO::Socket::INET iteration patch? 11:22
TiMBuS moritz_, i guess so 11:27
TiMBuS do you want me to merge it into a single patch or something? 11:32
moritz_ that would make the review easier, yes 11:33
moritz_ rakudo: class dice { has $.eyes = (1..20).pick }; say dice.new.eyes 11:36
TiMBuS well its probably just easier to compare the entire file before and after, in this case heh. but alright
p6eval rakudo d8e5de: OUTPUT«15␤»
moritz_ rakudo: class dice { has $eyes = (1..20).pick }; say dice.new.eyes
p6eval rakudo d8e5de: OUTPUT«Method 'eyes' not found for invocant of class 'dice'␤ in main program body at line 22:/tmp/sWvoOd4yqZ␤»
TiMBuS ok moritz_ done. had a bit of trouble with git 11:48
its all good now
TiMBuS but if you dodnt already know, you dont generally need a second pull request for the same branch. any new commits i make go into the topic 11:50
tadzik how far is this from being spec-conformant? 11:54
moritz_ tadzik: a spec change away :-) 11:56
tadzik hah :) 11:57
I kinda expected that answer
moritz_ I don't even know if there's a spec
moritz_ I tend to ignore much of the IO specs 11:57
simon__ Hey. I have some questions regarding the whatever star. 12:02
tadzik go on 12:03
simon__ I understand it's a shortcut to make a closure
but sometimes it doesn't work like expected
for instance with the range operator
moritz_ simon__: it does't always construct a closure, some operators are special-cased
for examply my $x = *; assign a Whatever to $x, not construct a closure that assigns the argument to $x 12:04
rakudo: say (1..*).max
p6eval rakudo d8e5de: OUTPUT«Inf␤»
simon__ i see
what about inside the indexing brackets? 12:05
moritz_ in particular =, :=, .., ... and comma are special-cased
(and maybe more)
simon__ seems like it refers to the itemcount there?
moritz_ simon__: indexing brackets are just a shortcut for a method call, they don't imply any special syntax
@a[*] just passes a Whatever object to the postcircumfix:<[ ]> method 12:06
simon__ but you can do something like this: my @a = 1..5; say @a[1 .. *-1]
moritz_ simon__: you can, because - binds tigher than ..
so * - 1 is a closure
and thus 1 .. *-1 becomes a closure too
even if 1 .. * does not 12:07
(confusing, I know)
simon__ so [] can take a function as argument?
moritz_ yes
rakudo: say (1, 2, 3).[-> $x { say $x; $x - 1} ]
p6eval rakudo d8e5de: OUTPUT«3␤3␤»
simon__ i've also tried something like @a[1..*] which doesn't work. is this a bug?
moritz_ rakudo: say <a b >.[-> $x { say $x; $x - 1} ]
p6eval rakudo d8e5de: OUTPUT«2␤b␤»
TiMBuS thats why [1..*] currently goes forever in rakudo..
moritz_ simon__: yes, that should work too, but doesn't 12:08
(known bug, and probably not easy to solve)
TiMBuS i remember trying to patch that
you gotta rewrite Range or add a parse rule
moritz_ simon__++ # asking good questions 12:09
simon__ if you give [] a function that takes multiple arguments, does it just plug in the itemcount for every one of them?
thanks ;)
moritz_ simon__: I think so, yes
rakudo: say <a b c>.[* - *]
p6eval rakudo d8e5de: OUTPUT«a␤»
moritz_ yes, it does :-)
tadzik rakudo: say *-* 12:12
p6eval rakudo d8e5de: OUTPUT«_block131␤»
moritz_ rakudo: say (*-*).signature.perl 12:13
p6eval rakudo d8e5de: OUTPUT«_block131␤»
moritz_ oh ouch
rakudo: say (my $ = (*-*)).signature.perl
p6eval rakudo d8e5de: OUTPUT«:(;; Mu $x1, Mu $x2)␤»
simon__ when @a[1..*] is fixed, is it gonna do @a[1 .. +*] or @a[1 .. *-1]? 12:23
moritz_ the latter (ie no trailing Any)
moritz_ TiMBuS: I'll apply your patch when I get home, and fix LWP::Simple afterwards 12:32
simon__ how come this works? @a[*-5 .. *] 12:53
shouldn't *-5 .. * make a closure that takes one argument and makes a sequence from that argument - 5 to infinity?
moritz_ has no idea 12:54
tadzik rakudo: say (*-5..*).perl
p6eval rakudo d8e5de: OUTPUT«_block131␤»
tadzik superb
rakudo: say Range.new( from => *-5, to => *).perl 12:55
p6eval rakudo d8e5de: OUTPUT«too many named arguments: 2 passed, 0 used␤ in main program body at line 22:/tmp/rkIibbM11f␤»
tadzik rakudo: say Range.new(*-5, *).perl
p6eval rakudo d8e5de: OUTPUT«{ ... }..Inf␤»
tadzik rakudo: say Range.new(*-5, *).Num
p6eval rakudo d8e5de: OUTPUT«Inf␤» 12:56
[Coke] ~~ 12:57
moritz_ brainstorming session! What project ideas could we offer for GSOC students? 13:43
flussence_ Improving printf-ish stuff? 13:44
moritz_ POD parser in rakudo is one
flussence_ rakudo: say printf('%2$s', 4, 3); 13:45
p6eval rakudo d8e5de: OUTPUT«Not enough arguments supplied for the given format string␤ in 'Cool::sprintf' at line 2754:CORE.setting␤ in 'sprintf' at line 2788:CORE.setting␤ in 'IO::printf' at line 5575:CORE.setting␤ in 'printf' at line 5789:CORE.setting␤ in main program body at line
..22:/tmp/L65RXhNixk␤»
moritz_ is that supposed to work? :-)
flussence_ apart from the first two words being obviously wrong... :)
it should do the same as what perl5 does 13:46
moritz_ other project ideas? 13:53
moritz_ modules that badly need porting? infrastructure tasks? 13:55
tadzik: do you have some TODOs in Panda that would make a good GSOC project? 13:56
flussence_ would be nice if it was easier to relocate a rakudo --gen-parrot install 14:00
moritz_ that's mostly a parrot task, not a rakudo one 14:01
flussence_ or at least so the result of "make install" will keep working while I'm recompiling it...
moritz_ it does
... if you recompile into a different location :-)
tadzik moritz_: oh, I guess whatever's on my mind I'll make it myself before GSoC starts :) 14:03
maybe there's a task about creating an entire infrastructure, to CPAN and beyond :) 14:04
besides, I'm probably going to apply too 14:06
moritz_ \o/ 14:07
tadzik so I'm quite yooking forward to task ideas, as jnthn's one, being awesome, seems out of my skills range 14:14
moritz_ does Pod6 parsing in rakudo sound saner to you? 14:15
tadzik I don't find that one insane :) But Pod parsind seems doable 14:16
or the .WHY things
moritz_ well, the two are related
tadzik aye 14:17
moritz_ you need to parse the Pod to attach it as .WHY
flussence_ (if someone writes a Pod parser, I'll write a pod2html5 thing for it) 14:25
moritz_ web tools: cookie jar, HTTP request and response, ... 14:26
donri isn't .WHY supposed to be unparsed? 14:28
moritz_ rakudo: sub f(::Int $x) { say Int.WHAT }; f("Foo")
p6eval rakudo d8e5de: OUTPUT«Str()␤»
moritz_ rakudo: sub f(::Int $x) { say Int.WHAT }; f("Foo"); say Int.WHAT
p6eval rakudo d8e5de: OUTPUT«Str()␤Int()␤»
moritz_ found a way to lexically rebind types :-) 14:29
std: sub f(::Int $x) { say Int.WHAT };
p6eval std 4608239: OUTPUT«Potential difficulties:␤ $x is declared but not used at /tmp/bGNp2OxR8q line 1:␤------> sub f(::Int ⏏$x) { say Int.WHAT };␤ok 00:01 122m␤»
tadzik moritz_: lokking at www.nntp.perl.org/group/perl.perl5....70045.html isn't the project ideas period over? 15:00
moritz_ tadzik: notreally; it just seems too late to change the URL that's submitted to google 15:01
tadzik: adding project ideas only becomes worseless once tasks are accepted/rejected 15:02
ajs Just had an interesting bug. Line of code used to contain "$a<foo>+$a<bar>". I made the two lookups local variables, but left one ">" so the code became: "$foo>+$bar" ... damn that was hard to find. 15:09
moritz_ rakudo: my $foo; my $bar; $foo>+$bar 15:10
p6eval rakudo d8e5de: OUTPUT«Use of uninitialized value in numeric context in <anon> at line 22:/tmp/jHkN43mavW␤Use of uninitialized value in numeric context in <anon> at line 22:/tmp/jHkN43mavW␤»
moritz_ rakudo: my $foo = 1; my $bar = 2; $foo>+$bar 15:11
p6eval rakudo d8e5de: ( no output )
moritz_ rakudo: my $foo = 1; my $bar = 2; say $foo>+$bar
p6eval rakudo d8e5de: OUTPUT«Bool::False␤»
moritz_ ajs: there are reasons why I recommend whitespace around infix operators
ajs Yeah, I have an old habit of doing things like "if $a+$b == $c+$d" so that the two sides of the comparison are clear. I think I'm going to have to break that habit in Perl6.... 15:12
ajs I think I'm going to take on writing a clone of Python's argparse for P6... I've always thought it had a lot going for it, but there are a couple things I wish had been designed very differently. 15:18
flussence_ rakudo: say [==] ([+] 2, 3), ([+] 1, 4) 15:19
p6eval rakudo d8e5de: OUTPUT«Bool::True␤»
ajs What is that, RP6N?
arnsholt ajs: Perl 6 has quite powerful argument parsing built-in as well 15:30
ajs I'm just interested in playing with an alternate approach is all
arnsholt That's cool as well. Just in case you were looking for a Getopt for Perl 6 =) 15:31
ajs One thing I like about argparse is that it's equally at home with something like the svn/git model (cmd options subcmd options) as it is with traditional unixish command-lines (cmd options rest) 15:33
It does this by treating the command-line like a function call, breaking it down into positional and named parameters. 15:34
moritz_ that's something that MAIN can't really do
it can dispatch based on a string literal 15:35
moritz_ but it can't distinguish general options from options to a subcommand 15:35
ajs Anyway, I'll be toying with that later. Work now. 15:37
TimToady it would be fairly easy to preprocess the args into a form acceptable to MAIN, and the MAIN mechanism is designed to make such preprocessing easy, since the whole script runs first 16:08
moritz_ so it would just modify @*ARGS ? 16:09
TimToady sure
that's why MAIN is called from the end of the script
might have to provide a way to modify USAGE though... 16:10
moritz_ there is one already :-)
TimToady making sure that one can call the standard USAGE and massage that message 16:11
maybe viewing a user-defined USAGE as some kind of a wrapper around the standard one 16:12
moritz_ well, according to current spec you can just use $?USAGE and massage it before printing it
TimToady okay
moritz_ rakudo doesn't provide that yet, but it should be quite possible to do 16:13
TimToady though there's something wrongish about that, since $? means a compile-time constant, and you couldn't know its value till the end of the file
$?USAGE would have to imply a level of indirection to mean "the value it will have at CHECK time" 16:14
moritz_ sub USAGE { print massage $?USAGE }
of course we could have a my $*?USAGE = $?UAGE; in the setting implied, saving you the hassle to actually the print yourself 16:15
but IMHO that's overkill
TimToady alternately, maybe there's some way we can finesse MAIN parsing to allow application of destructuring to a field of options
TimToady sub MAIN ('command', { :$foo, :$bar }, 'subcommand', :$baz) {...} 16:16
TimToady but then you have to copy/paste all those, which is a violation of DRY 16:16
moritz_ TimToady: and jnthn would strangle you :-) 16:17
TimToady or, we just baldly state that if the sigs contain a %hash, that's a subfield of switches managed positionally 16:18
or we provide some way of saying 'don't treat subsequent switch fiels as named parameters yet' 16:19
so it can be deferred to a submain function
moritz_ maybe abuse ;; for that?
TimToady or \$capture 16:20
or |$capture
moritz_ std: sub f($x, \$c) { } 16:21
p6eval std 4608239: OUTPUT«Potential difficulties:␤ $x is declared but not used at /tmp/VwNYtNw8rd line 1:␤------> sub f(⏏$x, \$c) { }␤ $c is declared but not used at /tmp/VwNYtNw8rd line 1:␤------> sub f($x, \⏏$c) { }␤ok 00:01 120m␤»
moritz_ rakudo: sub f($x, \$c) { say $x }; f 1, 2, 3, 4, :foo
p6eval rakudo d8e5de: OUTPUT«Too many positional parameters passed; got 4 but expected 2␤ in 'f' at line 1:/tmp/DliJYJLMMU␤ in main program body at line 22:/tmp/DliJYJLMMU␤»
TimToady something like that, but allow named params to be harvested before binding the remainder to $c 16:22
rakudo: sub f($x, |$c) { say $x }; f 1, 2, 3, 4, :foo
p6eval rakudo d8e5de: OUTPUT«1␤»
TimToady yeah, |, not \
moritz_ rakudo: sub f($x, |$c) { say $x; say $c.perl }; f 1, 2, 3, 4, :foo
p6eval rakudo d8e5de: OUTPUT«1␤\(2, 3, 4, "foo" => Bool::True)␤» 16:23
moritz_ \o/
TimToady but can you get at --foo if it's before? 16:23
moritz_ why not?
oh
TimToady more importantly, distingish pre-foo from post-foo
moritz_ I know why not
positional before named, and all that 16:24
seems that argument preprocessing is easier :-)
TimToady or a rule that turns embedded switch fields into a {...} 16:25
but only if the sigs have a {...} subfield 16:26
or a %hash subfield
could even be %*GLOBALOPTS as a parameter 16:27
TimToady is now thinking about protos that preprocess for their multis... 16:31
not sure {*} gives us enough rope to rewrite the arguments though... 16:32
won't fly unless proto MAIN can modify the args it feeds to {*} 16:33
also, won't help if the switches have already been denatured before the proto sees it 16:34
what it really comes down to is the 2-pass parsing problem, *again*... 16:37
so me wonders if there's some way to make it a 1-pass parse
something to think about in the shower & 16:40
Hugmeir rakudo: my $test = [\+] 1..10; $test.perl.say; 18:12
p6eval rakudo d8e5de: OUTPUT«(1, 3, 6, 10, 15, 21, 28, 36, 45, 55)␤» 18:13
Hugmeir rakudo: my @test = [\+] 1..10; @test.perl.say; 18:13
p6eval rakudo d8e5de: OUTPUT«[1, 3, 6, 10, 15, 21, 28, 36, 45, 55]␤»
masak halloj, zebras! 18:13
Hugmeir So alright, I'm kind of slow here. What does a triangle reduction return in scalar context? 18:19
masak depends what you mean by scalar context -- we don't really have scalar contexts in the same way as Perl 5 does. 18:19
masak rakudo: my @a = 1..10; my @b = [\+] @a; say +@b 18:20
jnthn The easy way to figure it out is to put .WHAT after the operation :)
p6eval rakudo d8e5de: OUTPUT«10␤»
jnthn rakudo: my $test = [\+] 1..10; $test.WHAT.say 18:20
masak Hugmeir: but if you mean the above, it returns the length of the list, just like all other numifications of lists.
p6eval rakudo d8e5de: OUTPUT«List()␤»
masak jnthn! \o/
jnthn masak! \o/
Hugmeir Stupid sexy context being contextual on the language it's used on. Who would've thought : ) 18:21
masak today's autopun spotting ^
diakopter hugme: hug Hugmeir 18:24
hugme hugs Hugmeir
Hugmeir Thnaks for the explanations! I meant it like in jnthn's message; assigning it to a scalar and asking .WHAT kindly did the trick.
masak ah. jnthn++ 18:24
Hugmeir jnthnn++ I guess. #perl6++ in general. 18:25
pmurias who started the hugging meme? 18:43
masak pmurias: au. 18:44
pmurias au? 18:44
PerlJam pmurias: audrey 18:45
masak pugs.blogs.com/audrey/2009/08/my-ho...gging.html
tadzik I think the "submethod BUILD { callsame; ... }" will become quite catchy 19:03
why is that submethod anyway?
masak because we don't want it to inherit? 19:05
tadzik I don't think I see the point... oh, so the BUILD in child will not override the parent one? 19:07
masak right, all the BUILDs are meant to be called by BUILDALL. 19:07
masak (that way, you generally don't *have* to do 'callsame' in a BUILD) 19:08
tadzik well, otherwise you don't get your attibutes
masak I don't think I understand. do you have an example handy? 19:10
tadzik sure, gimme a sec 19:12
tadzik masak: see wklej.org/id/494717/ 19:14
see the effect, then see what happens when you remove the callsame()
masak reads 19:15
tadzik oh, the parent class is basically useless 19:16
it's from the time I was implementing AFTERPARTY for Rakudo :)
masak ok, I see what the 'callsame' is doing, but I don't like it. 19:17
tadzik I don't like it either
masak ISTR someone suggested a change to object initialization recently that would make that go away. 19:17
tadzik I prefer the Moose's way
masak who was it, and what was the solution? 19:18
was it mberends, in the living room, with the cudgel? :)
tadzik (: 19:18
masak the solution was something like "for each class, first initialize the attributes with their default values, then call BUILD" 19:19
masak to me, that makes a lot more sense than having BUILD and attribute defaults compete. 19:19
hm, but maybe that was just a bug in Rakudo...?
tadzik no, that's a spec thingy 19:19
masak ok, then it officially sucks.
tadzik and Larry agrees on the current behaviour
I don't disagree 19:20
masak Larry agrees that it should change, or agrees with Rakudo's current crappy handling?
tadzik agrees with what the spec says, so "you write BUILD when you want to organize the attribute setting yourself" 19:21
masak :( 19:21
what's Moose do?
tadzik and if you want to have Moose-like behaviour, write stuff after bless in new
hm?
masak how does Moose do all this?
tadzik well, BUILD is called after everything is set up and ready 19:21
masak \o/ 19:22
tadzik that's the way I like it, and that's the way I expect it to work
tadzik I'm quite suprised Perl 6 is different 19:22
masak it's not just you. it's not just me. it's a bunch of people in RT.
masak here's one argument against the behavior: (1) user reads list of attributes, sees the default initializations. makes conclusions. "aha, that attribute gets set to that value at object initialization. (2) user gets tired from reading lots of methods in the rest of the class. besides, the init bits were probably at the top anyway. 19:26
masak (3) user misses BUILD halfway down the class. (4) BOOM 19:26
masak and don't tell me programmer should've put BUILD further up. it's the language that shouldn't cause action at a distance without good cause. 19:27
masak even worse action-at-a-distance: make class do nifty new role. role does a bunch of other roles. somewhere, a role contains a BUILD submethod. BOOM, attributes no longer get initialized. 19:28
masak ss/ \(2/" (2/ 19:30
masak we need some conversation here to drown out shi's constant joining and leaving :) 20:02
flussence_ that BUILD thing sounds like a good reason to have something like "does RoleName except qw(BUILD)"... 20:03
flussence_ (or perhaps to beat whoever wrote the role over the head with a cluestick) 20:04
masak both of those solutions are only workarounds to the real problem of BUILD canceling out the effect of attribute initialization. 20:05
flussence_ I'm pretty sure the only time I've ever used BUILD was... using it wrong. Hmm. 20:09
masak tadzik: three people had the same expectations: in June 2009, August 2009, and July 2010. rt.perl.org/rt3/Ticket/Display.html?id=68498 20:15
tadzik hah, I was almost expecting "and The Month of The Seeds, Anno Domini 1132" 20:16
masak tadzik: it's your country that has those strange month names, not mine :P 20:16
tadzik lies! :) 20:16
masak tadzik: by the way, your month names are totally charming. ;) 20:17
masak "stitch-month"? priceless. 20:17
tadzik Styczeń, Luty, Marzec, Kwiecień, Maj, Czerwiec, Lipiec, Sierpień, Wrzesień, Październik, Listopad and Grudzień? Seems pretty normal to me :)
masak it stiches together the old year and the new one.
tadzik (: 20:18
masak I bet there's a bunch of flowers and old leaves in there as well.
masak is "Kwiecień" to do with flowers? 20:18
masak ah yes, so it seems. and "Październik" is "flax month". you can just make this stuff up. 20:20
can't*
masak uh... and June is named after... an obscure insect? 20:24
tadzik nope, I think that has something to do with flora again 20:25
tadzik oh no, you're right 20:25
a not-yet-bee
masak used to make a red dye of some kind. 20:26
tadzik they used to make a red paint out of it, our Red is Czerwony
yeah :)
masak (Polish months)++ # making the Latin one's seem so boring! 20:26
s/one's/ones/
masak dduncan's email to p6l is classic p6l material... but also kind of a nice idea. :) to me that'd be a kind of a lint-like tool, and thus not even an extension so much as a "third-party" binary/module. 21:01
masak the prerequisite of such an idea is something PPI/STD-like, of course. 21:01
moritz_ which we have 21:02
\o/
masak :)
moritz_ will you write it (3rd party app), or should I?
masak please go ahead... and then reply to dduncan's email ;) 21:03
moritz_ uhm, I meant if I should write the reply :-)
masak oh :P
masak please go ahead and reply. I'm currently preparing for $teaching tomorrow. 21:04
moritz_ what are you going to teach? 21:05
jdhore How to be Awesome 101 21:06
masak first day of two was today. Android development.
masak jdhore: I'll take that as a compliment. thank you ;) 21:06
jdhore masak, ah, How to be Awesome 101 is next week?
masak depends how you count the GoOpen talk in Oslo :) 21:07
masak it's named "Herding Cats and Robots" :) 21:07
jdhore haha
masak and it's about you, #perl6! 21:07
moritz_ I thought bacek was the robot, and he's mostly in #parrot :-) 21:08
masak dang, bacek is stealing my reputation of being a bot... :P 21:08
masak .oO( reverse Turing test... )
tadzik can Rakudo compile STD.pm6? 21:17
moritz_ no
masak it will be a fine day when it can.
the turtles will laugh all the way down ;) 21:18
moritz_ :-)
moritz_ rakudo: my $t = time; sleep 0.1 for ^10; say time - $t 21:22
p6eval rakudo d8e5de: OUTPUT«1␤»
dalek ast: 15c1b74 | moritz++ | S32-io/IO-Socket-INET. (2 files):
[socket] adapt to more p5 like IO::Socket::INET implementation
21:25
tadzik "one spec change away" :) 21:29
tadzik moritz++ # nice 21:38
[Coke] (duncan) looks like a great padre thing.
tadzik installs LWP::Simple with Panda
tadzik oh, it fails the tests for me 21:39
tadzik moritz_: nopaste.snit.ch/38011 21:40
moritz_ with newest rakudo? 21:47
tadzik aye
or, wait
tadzik ...how newest? Gimme a sec :) 21:47
moritz_ well, it needs 15c1b74 21:48
the patch I just pushed
tadzik This is Rakudo Perl 6, version 2011.02-55-ge3bd9aa 21:48
moritz_ ETOOOLD
you're so last release
tadzik git pull => Already up-to-date.; make: Nothing to be done for `all'. 21:49
tadzik scrathes head
moritz_ don't forget "make install"
tadzik did
I don't see the patch in git log
jdhore moritz_, so i didn't break things?
tadzik did you really push it? 21:49
moritz_ oh 21:50
jdhore oh, you were referring to the INET change?
tadzik caught in the act! :)
tadzik jdhore: yes 21:50
jdhore ah, I thought you were saying I broke something in 2011.03 :D
moritz_ tadzik: I tried, but got a [rejected]
tadzik you're so pre-release :) 21:51
tadzik oh there it is 21:51
dalek kudo: 25e5bd0 | TiMBuS++ | src/core/IO/Socket/INET.pm:
Changed IO::Socket::INET to act more like perl5's. One connection per object, acts a little more like a filehandle, and most importantly, actually works (the old code no longer connects).

Signed-off-by: Moritz Lenz [email@hidden.address]
21:52
moritz_ TiMBuS++ 21:54
tadzik ==> Succesfully installed LWP::Simple 22:00
\o/
tadzik masak: Web.pm has some broken dependencies, doesn't it? 22:07
masak likely. 22:08
proabably simply bitrot.
tadzik it could probably make use of HTTP::Server::Simple 22:09
masak oh, indeed.
moritz_ ... which probably needs updating after last rakudo changes :-) 22:10
tadzik oh crap :)
masak the Perl 6 world has largely moved on without Web.pm.
moritz_ -> sleep
masak -> sleep
colomon well, we need to fix that, then, no?
TimToady tadzik: a role's submethods do not override a class's, so that problem doesn't arise with submethod BUILD 23:10
TimToady phenny: tell masak a role's submethods do not override a class's, so that problem doesn't arise with submethod BUILD 23:10
phenny TimToady: I'll pass that on when masak is around.
tadzik TimToady: I see 23:19
tadzik rakudo: use LWP::UserAgent:from<parrot> 23:25
p6eval rakudo 25e5bd: OUTPUT«===SORRY!===␤Parent of 'PCT;Grammar' is null␤»
tadzik that's funny
rakudo: use LWP::UserAgent:from<parrot>; 1 23:26
p6eval rakudo 25e5bd: OUTPUT«===SORRY!===␤Parent of 'PCT;Grammar' is null␤»
tadzik rakudo: use LWP::UserAgent:from<parrot>; say 'alive'
p6eval rakudo 25e5bd: OUTPUT«===SORRY!===␤Parent of 'PCT;Grammar' is null␤»