perl6-projects.org/ | nopaste: sial.org/pbot/perl6 | evalbot: 'perl6: say 3;' | irclog: irc.pugscode.org/
Set by mncharity on 25 March 2009.
00:30 Whiteknight left 00:35 bacek__ joined 00:43 justatheory left 00:50 dalek left, dalek joined
s1n moritz_: i read some of S12's handles delegates and that's not what i really wanted to do 00:56
moritz_: if i read that correctly, it's like associating a scalar to a coderef of another object, i kinda wanted to do that within the class i'm delagating to 00:57
it kinda sounds like i might be able to morph delegates into what i want, but it's not clear to me 01:02
01:25 hcchien joined 01:27 mofino left 01:33 awarefish left 01:36 bacek joined 01:38 bacek_ left 01:43 c9s_ is now known as c9s
pugs_svn r26653 | ron++ | note association of test with RT #61838 01:57
01:57 Kyosuke_Kiryu joined 02:54 dukeleto_ is now known as dukeleto
pugs_svn r26654 | lwall++ | [lift.t] identifiers must be alphanumeric 03:14
03:26 mikehh left
pugs_svn r26655 | lwall++ | [S04] clarify parsing of statement controls 03:36
r26656 | lwall++ | [STD] parse try {...} as originally intended, moritz++
r26656 | lwall++ | [STD] start playing with YOU_ARE_HERE stub
r26656 | lwall++ | [STD] don't complain on :keepall etc.
r26657 | lwall++ | [S02] random minor cleanup 03:39
r26658 | lwall++ | [Callable] defined defined on Code 03:42
r26658 | lwall++ | [Containers] de-List routines that should return Capture instead, like pick
r26658 | lwall++ | [Containers] define :delete and :exists as normative
r26658 | lwall++ | [Containers] explicate (some of) the relationship of junctions to sets
03:50 alester_ joined
pugs_svn r26659 | lwall++ | incomplete plural to singular tranformation on key tests 03:56
r26660 | lwall++ | [S04] previous patch confused statement prefixes with statement controls 03:57
04:01 justatheory joined 04:21 alester_ left
pugs_svn r26661 | lwall++ | [keepall.t] missing semi 04:21
r26662 | lwall++ | [S14] syntax category declarations need symbol in brackets 04:29
r26663 | lwall++ | [basic.t] s/:is/:<is>/ etc. 04:30
04:43 sri_kraih_ left 04:49 alester_ joined 05:12 dalek left 05:13 dalek joined 05:22 minazo joined 05:29 justatheory left 05:30 minazo left 05:35 szabgab left, szabgab joined 05:50 nihiliad left 05:55 alester_ left 06:01 iblechbot joined 06:05 araujo left 06:08 DemoFreak joined 06:12 eMaX joined 06:13 agentzh left, agentzh joined 06:15 cognominal left
moritz_ TimToady++ 06:15
pmichaud good morning 06:16
06:17 jeremiah_ left, jeremiah_ joined 06:18 cognominal joined
moritz_ good morning 06:19
pmichaud: it seems your changes to join broke some spectest 06:24
pmichaud yes, I have the fix in my local commit. 06:25
I'm spectesting now, then will push.
moritz_ great 06:26
pmichaud But it also found a bug in slurpy @_.
So I'm pushing that as well.
moritz_ even better
I remember at least one ticket for buggy @_;
rakudo: sub a { say @_.perl }; a(2, 3, 4) 06:27
p6eval rakudo cddb16: OUTPUTĀ«[2, 3, 4]ā¤Ā»
pmichaud yes, that's the one.
moritz_ but not that ;-)
pmichaud rakudo: sub a { say @_[2]; } a(2, 3, 4)
p6eval rakudo cddb16: OUTPUTĀ«Statement not terminated properly at line 1, near "a(2, 3, 4)"ā¤ā¤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)ā¤Ā»
pmichaud rakudo: sub a { say @_[2]; }; a(2, 3, 4)
p6eval rakudo cddb16: OUTPUTĀ«4ā¤Ā»
moritz_ rakudo: sub a { say @_.elems }; a(2, 3, 4)
p6eval rakudo cddb16: OUTPUTĀ«3ā¤Ā»
pmichaud rakudo: sub a { say @_[2]; }; a(2 p5=> 3, 4 p5=> 6)
p6eval rakudo cddb16: OUTPUTĀ«Use of uninitialized valueā¤ā¤Ā» 06:28
pmichaud (should've been '4' there.)
moritz_ agrees 06:29
do you happen to know how I can convert a timestamp to RFC822 format in Perl 5?
pmichaud 822?!
egads. 06:30
I'd use strftime, but that is probably locale-dependent.
moritz_ the thing that RSS feeds need
well, I'll try google ;-)
06:33 ab5tract left 06:37 payload joined
pmichaud oooh, passed a todo, also. :-) 06:43
06:45 lumi left
pmichaud oops, failing some. 06:47
(failing different ones now)
06:49 patmat joined
patmat hello :) 06:49
pmichaud good morning 06:50
06:52 mikehh joined 06:55 payload left 07:09 eMaX left 07:13 smtms joined
Tene finally home from con... 07:15
time to update sources and see what's been happening.
07:26 REPLeffect left 07:30 kidd joined 07:40 payload joined
dalek kudo: r3c95282 | pmichaud++ | src/parser/actions.pm:
Refactor handling of nodes to !add_param, fixing implicit slurpy array.
07:45
kudo: r020fd49 | pmichaud++ | src/setting/Any-list.pm:
Make sure .join flattens lists.
kudo: r0588e8c | pmichaud++ | src/setting/Any-list.pm:
Change .join flattening a bit.
pugs_svn r26664 | pmichaud++ | [t/spec]: Unfudge a passing todo, add some implicit slurpy param tests. 07:46
08:02 payload1 joined, payload left 08:06 agentzh left, agentzh joined 08:20 eMaX joined 08:23 jhuni joined 08:31 riffraff joined 08:58 meppl joined 09:03 payload1 left 09:06 Jedai joined 09:13 hatseflats joined
hatseflats morning everyone 09:13
09:14 masak joined
masak felicitations on the new week. 09:15
hatseflats sounds like someone has a case of 'mondays' :) 09:16
masak hatseflats: :)
hatseflats so, roles in Perl6 need not be abstract, right? 09:19
masak hatseflats: right.
in fact, in the common case they aren't, IIUC. 09:20
hatseflats that makes them different from traits, correct?
masak hatseflats: the term "traits" means different things to different people.
hatseflats right
masak if you would supply the context in which you're using the word... :) 09:21
hatseflats well, if I believe what wikipedia tells me, traits are purely abstract classes that an be used within a class or object but not add to the inheritence chain
masak apart from the 'purely abstract' part, it sounds a lot like Perl 6 roles. 09:22
hatseflats right
iiuc, roles are at least derived from the idea of traits 09:23
masak aye.
moritz_ to add to the confusion, Perl 6 also has the concept for traits 09:24
in which case traits are roles that are mixed in by a special mechanism
that provides nice syntactic sugar
hatseflats the context is this, I have a schol project where I need to design my own language, and I want to add something extra for a bit of extra credit, and I figured I'd go for traits, but 'you perl people' seem to be the only ones out there that have a decent grasp over the subject
moritz_ heh :-) 09:25
09:25 payload joined
moritz_ hatseflats: what kind of language? and do you also have to implement it? 09:25
hatseflats I have to implement it up to the AST, and I'm just grabbing parts from languages I like. Right now I'm thinking about the object / class system I will want to use 09:26
masak hatseflats: you should check Ovid's blog posts. he has blogged a lot about roles recently. 09:27
hatseflats: also, possibly, the Moose documentation.
moritz_ use.perl.org/~ovid/
09:27 lumi joined
moritz_ use.perl.org/~Ovid/journal/ to be more precise 09:27
hatseflats that's useful, thanks :) 09:28
right now, I'm here syntactically: dpaste.com/40747/
and I figured that if roles / traits can be non abstract I might as well just implement them as classes themselves 09:29
perhaps with a guard, but nothing more than that
pure abstract roles could be implemented through a interface class, and be used as a role
moritz_ somehow that reminds of javascript, syntactically
hatseflats I took the associative array thingy synta from js 09:30
moritz_ lunch^
lunch& acutally
09:31 wollmers joined
hatseflats perhaps I should also just apply some cluebrick and build the thing for Parrot at the same time 09:32
masak hatseflats: yes, do that.
hatseflats: PCT.
hatseflats pct?
masak hatseflats: Parrot Compiler Toolkit. 09:33
hatseflats: I'm sure I could dig up a decent tutorial for you somewhere.
hatseflats: you won't regret the choice.
hatseflats oh, yes. I've hear dgood things about it, and since it is a dynamic language, should work out just fine
at the same time, it'll give me a decent insight in how to build up to the AST for my own stuff, I will still need to write a parser etc from scratch for the assignment 09:34
masak start by watching this: www.youtube.com/watch?v=DzpSREpLJY8
hatseflats saw that
good stuff :) 09:35
masak ok :)
09:37 eternaleye left, bacek__ left 09:38 eternaleye joined 09:40 riffraff left
jnthn H H 09:40
masak O AI
O AI 09:41
jnthn Teamwork. :-) 09:42
hatseflats: Parrot provides some support for roles out-of-the-box too. :-)
hatseflats nice 09:43
jnthn hatseflats: Though it's not that widely used and in fact the language heavily using it (Rakudo) then layers a bunch of parametric polymorphism on top of it all too.
So it's not the easiest example. :-) 09:44
hatseflats parametric polymorphism... I'll have to look that one up.
jnthn hatseflats: It's the fancy academic word for generics, if that means more to you. 09:45
hatseflats that's Java's name for C++'s templates, right? 09:46
jnthn lol
Yes. :-)
I should probably start these conversations by asking people what languages they know. :-) 09:47
masak hatseflats: though Java's generics are somewhat more limited than C++'s templates.
jnthn Yeah.
hatseflats masak: not to say that C++'s templates are all the rage
masak hatseflats: dunno, haven't used them.
hatseflats: they do seem powerful indeed. 09:48
I've seen people execute algorithms at compile-time with them.
jnthn Perl 6 goes ever further and lets you parameterize on just plain old values rather than types, though Perl 6 has a kinda interesting idea about what you can pass off as a type too.
hatseflats hmm, will have to read into that.
masak use.perl.org getting more flak: use.perl.org/~jarich/journal/38920
hatseflats but I don't want to implement generics just quite yet, so I'm safe for the speciics :) 09:49
* specifics
masak :) 09:50
hatseflats masak: I don't see what's wrong with that specific ad at all...
masak hatseflats: I didn't at first either.
hatseflats: but, quoting the blog post, "My entry was about the challenges of getting more women into Perl and IT in general; not about picking up women from a dating site."
I can see how that can send the wrong signals... 09:51
hatseflats masak: I read that yes, nothing wrong with that ad so far ;-)
jnthn expects he doesn't have to go read this post to guess what has happened.
masak jnthn: right. the above summarizes it.
jnthn It's probably a bit like the ads on my Ukraine photos page on my travel site. *sigh*
hatseflats no, but seriously, you can hardly blame any adbot for not understanding the context of the page
masak hatseflats: true. on the other hand, the message of the main content can be coloured by the message of ads in a bad way. 09:52
hatseflats: regardless of whether there's any intention behind it or not.
here's another example: www.aprilwinchell.com/2009/04/18/un...placement/ 09:53
hatseflats oh there are plenty examples
masak & 09:54
hatseflats but would you want people who get 'offended' or put off by such coincidental circumstances to enter a community
09:59 eternaleye left
wollmers pmichaud: ping 10:00
10:00 eternaleye joined 10:02 araujo joined
jnthn wollmers: It's a little early for pm yet, I expect. :-) 10:02
wollmers jnthn: Where in the source tree of rakudo can I find the tokenizer/lexxer of rakudo? 10:03
masak hatseflats: it's a difficult question. I'm not sure it's always unreasonable of people to be offended by a tasteless combination of content and ads, even though the connection is 'all in the mind'.
jnthn wollmers: The grammar itself is part of the Rakudo source tree, but the compiler for the grammar is in Parrot. 10:05
github.com/rakudo/rakudo # rakudo source
svn.parrot.org/parrot/trunk/ # parrot source, see compilers/pge/
wollmers jnthn: Have these here locally, but where exactly? 10:06
jnthn src/parser/ for the Rakudo one, and compilers/pge/ in the Parrot one. 10:07
hatseflats masak: at some point I stopped looking at it as grey area, anyone suspecting malice over coincidence or ignorance should apply, or get applied, some cluebrick 10:08
wollmers jnthn: Seems that identifiers/names use the wrong Unicode character class - throws an error if Hindi vowel signs are used.
masak hatseflats: you're certainly entitled to that opinion. 10:09
jnthn That's probably something to look at in the compilers/pge/ bit I'd guess.
wollmers jnthn: thx, will look into it.
hatseflats masak: my main issue with my opinion is offending someone ;)
masak hatseflats: aye.
jnthn hatseflats: That'd probably be fine if humans were rationale. Apart from they kinda aren't.
masak meta-offense.
hatseflats trapped again in that ever circular reference loop of metalevel abstraction 10:10
10:10 iblechbot left 10:11 iblechbot joined
jnthn www.jnthn.net/images/google_fail.png # Google Translate fails it again... 10:15
masak :) 10:16
jnthn (The text on the left is Slovak for "In beautiful Bratislava". Quite how they manage to translate the name of one European capital to the name of another is beyond me.)
masak jnthn: itre.cis.upenn.edu/~myl/languagelog...05494.html 10:17
10:20 skids left 10:26 jhuni left 10:29 Kyosuke_Kiryu left
jnthn masak: Interesting. 10:32
masak Language Log rocks. 10:35
10:36 agentzh left
wollmers STD: my $ą¤¦ą„‚ą¤øą¤° = 2; 10:36
moritz_ std: my $ą¤¦ą„‚ą¤øą¤° = 2;
p6eval std 26664: OUTPUTĀ«ok 00:02 36mā¤Ā»
wollmers rakudo: my $ą¤¦ą„‚ą¤øą¤° = 2; 10:37
p6eval rakudo 0588e8: OUTPUTĀ«Statement not terminated properly at line 1, near "\u0942\u0938\u0930 = 2;"ā¤ā¤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)ā¤Ā»
wollmers rakudo: my $ą¤¦ą„‚ą¤ø = 2; 10:38
p6eval rakudo 0588e8: OUTPUTĀ«Statement not terminated properly at line 1, near "\u0942\u0938 = 2;"ā¤ā¤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)ā¤Ā»
wollmers rakudo: my $ą¤¦ą¤ø = 2; 10:39
p6eval rakudo 0588e8: ( no output )
10:40 Morpheus_PL joined
jnthn continues his trawl through the world of smop 10:45
10:49 payload left, payload joined 10:50 Morpheus_PL left 10:54 Morpheus_PL joined
masak I plan to blog about this hobby hacking later in the day: gist.github.com/106418 11:04
it's about finding numbers with only Langford pairs in them.
I wrote one brute-force attempt, and one slightly smarter attempt when the first one took way too much time and memory.
working blog post title: "Et tu, brute-force?" 11:05
jnthn nice
masak++
masak the problem is really nice, and can be tackled in a few minutes:
given some numbers 1..$n repeated twice, let's say 1,1,2,2,3,3 11:06
find an ordering such that for the pair of numbers $i, there are exactly $i numbers between the two numbers
hatseflats 1 2 1 3 2 3 <-- but not the last three 11:07
3 1 2 1 3 2
right? yeah 11:08
masak yup.
and that's the only solution, modulo mirroring, for $n == 3.
moritz_ masak: you could safe lots of runtime and memory by calling .uniq earlier in the recursion of all-possible-orderings
masak moritz_: nice idea. patches welcome. 11:09
hatseflats reminds me of the golomb ruler problem
masak moritz_: you'll get an honourable mention in the blog post. :)
jnthn OK, I think I've worked out how we'll fix up BUILD/BUILDALL and do attribute traits... 11:10
hatseflats hmm
...cant.... read.... perl
darn
masak awaits a real BUILD with anticipation
hatseflats: can I help you, sir? 11:11
moritz_ setting attributes in BUILD well be a real boost
hatseflats masak: no, I'm trying to read the logic in your langford sub, but I can't read perl well enough to understand it ;:)
* :)
masak moritz_: that did not parse.
hatseflats: that might be because I didn't strive for readability. 11:12
hatseflats: I wrote those as one-liners, and preferred one-character var names.
hatseflats I noticed
I take pride in writing oneliners in other languages, but perl is a bit too obscure just yet
moritz_ s/well/will/
masak hatseflats: but that's why I asked, because the last thing you need is to be thrown off by Perl 6 syntax on top of that.
hatseflats "obfuscated perl contest"
yay
masak hatseflats: for example, the '->' arrows might be new for you. 11:13
hatseflats no, I love the challange
*challenge
err....
english-fail
masak hatseflats: also, those ^..^ things :)
11:14 agentzh joined
hatseflats I'd imagine .. is a range operator of kind 11:14
but the ^'s in there
masak hatseflats: they mean, "up until, but not including"
hatseflats hmm, okay.
makes perfect sense to have that 11:15
masak alternative blog post title: "my undying love for .kv on lists"
moritz_ masak: my first attempt of early .uniq didn't work out, and I'm not motivated to debug right now :/ 11:16
masak moritz_: understandable.
moritz_: I might mention you anyhow. :)
anyway, the first attempt was a dead end. 11:17
.uniq in the right place might speed it up slightly, but the second one is (a) less code, (b) much more efficient 11:18
also note the exquisite use of param defaults and referring to prior params in the second one :P
that feature rocks. 11:19
moritz_ but is @a = [...] actually right?
doesn't that assign an array to the first item?
masak moritz_: where do you see that?
and, yes it does. 11:20
moritz_ and is [email@hidden.address] { !$_ };" the same as "none(@slots)"?
@slots = [0 xx 2*@candidates]
lambdabot Unknown command, try @list
masak moritz_: ooh, nice.
moritz_: oh.
I will try without it and see if it works.
(peer review)++
rakudo: my @a = [1,2,3]; say @a.elems 11:21
p6eval rakudo 0588e8: OUTPUTĀ«1ā¤Ā»
moritz_ and 'unless none(...)' should be the same as 'if all(...)', no?
masak rakudo: sub foo(@a = [1,2,3]) { say @a.elems }; foo
p6eval rakudo 0588e8: OUTPUTĀ«3ā¤Ā»
masak moritz_: seems different rules apply for param assignments.
moritz_ maybe it's more like binding? 11:22
11:22 LadyLunacy joined
masak rakudo: say "OH HAI" unless none(1,2,3) 11:22
p6eval rakudo 0588e8: OUTPUTĀ«OH HAIā¤Ā»
masak rakudo: say "OH HAI" unless none(1,2,3,0)
p6eval rakudo 0588e8: OUTPUTĀ«OH HAIā¤Ā»
masak 's head spins
rakudo: say "OH HAI" if all(1,2,3)
p6eval rakudo 0588e8: OUTPUTĀ«OH HAIā¤Ā»
masak rakudo: say "OH HAI" if all(1,2,3,0)
p6eval rakudo 0588e8: ( no output ) 11:23
masak moritz_: no, 'unless none' and 'if all' aren't the same.
moritz_ right
masak 'if all' seems to be the behaviour I want.
moritz_ unless none = if any, I think
masak aye.
hatseflats why the *bliep* is rakudo outputting so many crapchars? 11:24
moritz_ what are crapchars?
hatseflats non-ascii chars
sorry
masak hatseflats: are you thinking of the ā¤ characters?
hatseflats and others
moritz_ that's the translation of a newline character
masak that's a feature, not a bug. we want to see the newlines in the output.
hatseflats 13:22 < p6eval> rakudo 0588e8: OUTPUTĆÆĀæĀ½OH HAIĆ¢Ā¤ĆÆĀæĀ½ 11:25
that's what I see
masak hatseflats: please update your client. :)
hatseflats to something utf8 capable?
moritz_ hatseflats: this channel is utf-8 only :-)
masak hatseflats: aye.
hatseflats ah
yes
that works better
my screen session was still in non-utf8
masak we're practically non-utf-8-intolerant in here.
and proud of it.
moritz_ perl6-projects.org/ | nopaste: sial.org/pbot/perl6 | evalbot: 'perl6: say 3;' | irclog: irc.pugscode.org/ | UTF-8 is your friend! 11:26
hatseflats well, sure, but my config broke and now screen doesn't default to utf8 anymore :( 11:26
masak (UTF-8 is in the set of things you'd rather stay friends with.)
moritz_ ASCII just hasn't enough characters for us 11:27
masak neither does Latin-1 :)
hatseflats how about EBCDIC? 11:28
is that good enough?
moritz_ did you mean to say "is that bad enough"?
hatseflats only if the other question will get me banned
moritz_ we're not so quick with bans in here :-) 11:29
hatseflats no, I know :) 11:30
masak especially not for something so simple as an opinion. :)
moritz_ right, there's nothing wrong with EBCDIC as long as I don't have to deal with it 11:31
masak indeed.
& 11:32
hatseflats :) 11:35
11:40 iblechbot left 11:45 masak left 11:47 DemoFreak left 11:48 DemoFreak joined 12:03 DemoFreak left 12:05 ruoso joined 12:14 c9s left, c9s joined 12:16 PhatEddy joined
PhatEddy rakudo: UnManagedStruct.new 12:17
p6eval rakudo 0588e8: OUTPUTĀ«Null PMC access in getprop()ā¤current instr.: 'parrot;Perl6;Grammar;is_type' pc 172191 (src/gen_grammar.pir:34726)ā¤Ā»
PhatEddy rakudo: UnManagedStructz.new
p6eval rakudo 0588e8: OUTPUTĀ«Could not find non-existent sub UnManagedStructzā¤current instr.: '_block14' pc 53 (EVAL_16:43)ā¤Ā»
PhatEddy rakudo: File.new
p6eval rakudo 0588e8: OUTPUTĀ«Null PMC access in getprop()ā¤current instr.: 'parrot;Perl6;Grammar;is_type' pc 172191 (src/gen_grammar.pir:34726)ā¤Ā»
jnthn That's leakage from Parrot; we have a ticket on that, and I expect HLL use will solve it... 12:18
(Which there has been quite a bit of work towards)
PhatEddy (One of?) the ticket(s) is RT #62156 - and your last comment on the ticket seems to indicate some confusion as to where the "File class" is defined ... 12:20
12:23 zamolxes joined 12:26 azawawi joined 12:28 masak joined 12:31 iblechbot joined
jnthn ruoso: ping 12:31
ruoso jnthn, pong 12:33
hatseflats pang!
jnthn ruoso: Hi! I'm wanting to try and get the meta-class/representation stuff straightened out some in Rakudo. 12:34
I've spent a couple of hours looking through smop stuff.
ruoso jnthn, cool
jnthn I have a couple of questions, if you have time.
ruoso well... ask them... then I'll see if I have the time to answer now ;) 12:35
jnthn :-)
On the representation stuff.
The spec talks about being able to use things like a Hash or a Cstruct and so forth as an alternative representation. 12:36
ruoso right
jnthn However, I also notice that you define a representation API.
ruoso yes
jnthn The things you list in there are not operations that, say, a hash will have out of the box. 12:37
In this case, what exactly is going on, and how do we get from a plain old Hash to something that supports this API?
ruoso you need to get the implementation of hash-based OO
and that is in the representation
I basically split the OO in two parts 12:38
one is how the things are stored
and other is what they mean
so, it wouldn't really be a regular hash
jnthn OK, so the first is the representation, the second is the meta-class?
ruoso yes
ok... but I have to run now... bbl
jnthn OK, thanks for that...would like to discuss more, grab me when there's a good time for you. :-) 12:39
12:42 payload left 12:47 payload joined 12:51 skids joined
jnthn skids++ # your patch just got applied :-) 12:55
12:56 pmurias joined 12:58 exodist joined 13:06 dalek left, dalek joined
pugs_svn r26665 | azawawi++ | [S:H:P6] version 0.50 includes the latest STD.pm 13:07
13:07 DemoFreak joined
masak sometimes I wonder if the solution to this whole strict casting business shouldn't be to have a lenient 'scalar mode' in which the distinction between Str and different kinds of Num was intentionally blurred... 13:13
13:13 rindolf joined
masak type theorists will probably be able to tell me why this is a bad idea. :) 13:13
but often that feels like what I want.
rindolf rakudo: 1|2 13:14
hatseflats so, in perl6 I can bind roles to object instances, not only classes, right?
p6eval rakudo 0588e8: ( no output )
rindolf rakudo: (1|2).say
p6eval rakudo 0588e8: OUTPUTĀ«12ā¤Ā»
masak hatseflats: right. and that's when they're called 'traits'.
(IIRC)
hatseflats masak: iiuc, that's not true, at least , them being called traits.
masak rindolf: it's strange that you only get one newline from that. 13:15
hatseflats: in Perl 6, you mean?
hatseflats if memorhy serves me, traits are on a class level abstraction, not object level
masak hatseflats: in Perl 6, you mean?
hatseflats well, that, of course, I woudln't know
masak hatseflats: recall that vocabularies differ between communities.
hatseflats yeah... that sucks 13:16
okay
masak hatseflats: that's what makes it slightly difficult to talk about, at least until you qualify your terms.
wollmers std: my $ā’¶;
p6eval std 26665: OUTPUTĀ«##### PARSE FAILED #####ā¤Syntax error (two terms in a row?) at /tmp/4MXGA5NIAl line 1:ā¤------> my $ā’¶;ā¤ expecting any of:ā¤ POSTā¤ infix or meta-infixā¤ infix stopperā¤ postfixā¤ postfix_prefix_meta_operatorā¤ shape definitionā¤ standard
..stopperā¤ statement modifier loopā¤...
hatseflats so, syntactically, how do I bind a 'trait' into an Perl 6 object?
masak hatseflats: S12.
hatseflats ok
masak perlcabal.org/syn/S12.html 13:17
wollmers rakudo: my $ā’¶;
p6eval rakudo 0588e8: OUTPUTĀ«Malformed declaration at line 1, near "$\u24b6;"ā¤ā¤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)ā¤Ā»
rindolf rakudo: ((2&3) > 1).say
p6eval rakudo 0588e8: OUTPUTĀ«1ā¤Ā»
rindolf Shouldn't it be a boolean?
masak rindolf: ideally, yes.
skids traits are compile time. When they are runtime they are "properties"
masak there's an RT ticket about it.
skids: oh, right. that's it. 13:18
and they're not really related to roles.
jnthn figures he should clear up the terminology a bit here... 13:20
masak rakudo: class A {}; class B hides A {}
jnthn When you write a role, and you do class Foo does MyRole { } that's compile time compositon into a class.
p6eval rakudo 0588e8: OUTPUTĀ«Unable to parse class definition at line 1, near "hides A {}"ā¤ā¤current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:86)ā¤Ā»
masak submits TODO rakudobug
jnthn wtf is hides?
masak jnthn: S12 :)
"the synopsis that never ended" 13:21
jnthn std: class A {}; class B hides A {}
13:21 awarefish joined
p6eval std 26665: OUTPUTĀ«##### PARSE FAILED #####ā¤Unable to parse class definition at /tmp/bQiRwqAhhZ line 1:ā¤------> class A {}; class B hides A {}ā¤ expecting traitā¤FAILED 00:02 35mā¤Ā» 13:21
masak huh.
jnthn I was pretty sure I'd not seen STD parsing that.
Anyway, continuing
hatseflats rakudo: while(1);
p6eval rakudo 0588e8: OUTPUTĀ«Could not find non-existent sub whileā¤current instr.: '_block14' pc 60 (EVAL_17:47)ā¤Ā»
jnthn When you take an existing object and add a role to that, it's called a mix-in.
masak S12:1716
TimToady: ^ bug in STD? 13:22
jnthn A trait is something applied at compile time, and trait names are often introduced as roles, and if they set a property that'll be handled by roles too.
So there can be (and often will be) a relationship between traits and roles, but there doesn't have to be.
hatseflats aha 13:23
masak hatseflats: keywords like 'while' are whitespace-significant.
hatseflats: also, please be gentle with p6eval :)
jnthn (I did read the traits paper. What Perl 6 calls traits is not really what that paper talks about. What Perl 6 calls roles is much closer.)
hatseflats masak: aye, will do. :)
masak rakudo: $*IN.lines(1).say
p6eval rakudo 0588e8: OUTPUTĀ«Land der Berge, Land am Strome,ā¤Ā» 13:24
masak \o/
jnthn rakudo: $*IN.lines.pick
p6eval rakudo 0588e8: ( no output )
jnthn rakudo: say $*IN.lines.pick
p6eval rakudo 0588e8: OUTPUTĀ«Einig laƟ in BrĆ¼derchƶren,ā¤Ā»
patmat lol
masak rakudo: say $*IN.lines.pick.flip
p6eval rakudo 0588e8: OUTPUTĀ«!hcierretsƖ setfĆ¼rpegleivā¤Ā»
PerlJam what's on p6evals' $*IN?
patmat lol 13:25
jnthn The Austrian national anthem.
masak PerlJam: the Austrian national anthem.
PerlJam ah
13:26 les left, samlh left, antiphase left, moritz_ left, presh left, cj left 13:27 moritz_ joined, les joined, samlh joined, cj joined, presh joined, antiphase joined, irc.freenode.net sets mode: +o moritz_
masak rakudo: say $*IN.lines.pick.split.sort.join 13:27
p6eval rakudo 0588e8: OUTPUTĀ«too few arguments passed (1) - 4 params expectedā¤current instr.: 'parrot;Any;split' pc 41571 (src/gen_setting.pir:6342)ā¤Ā»
masak rakudo: say $*IN.lines.pick.split('').sort.join
p6eval rakudo 0588e8: OUTPUTĀ«ā¤Ā»
masak hm.
rakudo: say $*IN.lines.pick.split('').sort.join 13:28
p6eval rakudo 0588e8: OUTPUTĀ« ,HddeeeefhiiilmmnrsttttuuwƟā¤Ā»
masak :)
13:28 LylePerl joined, pmurias left
PerlJam masak: sort the letters in the whole thing by frequency :) 13:28
13:29 sri_kraih joined, pmurias joined
masak PerlJam: nice idea. which letter comes out on top. betcha it's 'e'. 13:29
s:2nd/\./?/
rakudo: ++%*h{$_} for $*IN.slurp.split(""); say .key, "\t", .value for %*h.pairs.sort({ -.value })[^10] 13:35
p6eval rakudo 0588e8: OUTPUTĀ«e 88ā¤ 60ā¤r 47ā¤i 41ā¤n 37ā¤t 36ā¤s 27ā¤d 24ā¤h 24ā¤ā¤ 23ā¤Ā» 13:36
masak craziest one-liner I've ever written.
jnthn ...wow!
PerlJam -.value is neat
masak bows 13:37
PerlJam (I would've just used reverse)
rakudo: say "{.key}\t{.value}" for (do { my %h; %h{$_}++ for $*IN.lines.split(''); %h }).pairs.sort({.value}).reverse[^10]; 13:46
p6eval rakudo 0588e8: OUTPUTĀ«e 88ā¤ 83ā¤r 47ā¤i 41ā¤n 37ā¤t 36ā¤s 27ā¤h 24ā¤d 24ā¤g 20ā¤Ā»
PerlJam (just cause :-)
masak PerlJam++
PerlJam hey ... how come the number of spaces is different between mine and yours? 13:51
13:52 presh left
PerlJam (I assume the second thing is spaces) 13:52
13:52 presh joined
moritz_ aren't these tabs? 13:52
PerlJam oh, maybe
masak oh, wait. 13:53
rakudo: say (do { my %h; %h{$_}++ for $*IN.lines.split(''); %h }).pairs.sort({.value}).reverse[^10].perl;
p6eval rakudo 0588e8: OUTPUTĀ«["e" => 88, " " => 83, "r" => 47, "i" => 41, "n" => 37, "t" => 36, "s" => 27, "h" => 24, "d" => 24, "g" => 20]ā¤Ā»
masak rakudo: say (do { my %h; %h{$_}++ for $*IN.lines.split(''); %h }).pairs.sort({.value}).reverse[^10]; 13:54
p6eval rakudo 0588e8: OUTPUTĀ«e 88 83r 47i 41n 37t 36s 27h 24d 24g 20ā¤Ā»
masak rakudo: .say for (do { my %h; %h{$_}++ for $*IN.lines.split(''); %h }).pairs.sort({.value}).reverse[^10];
p6eval rakudo 0588e8: OUTPUTĀ«e 88ā¤ 83ā¤r 47ā¤i 41ā¤n 37ā¤t 36ā¤s 27ā¤h 24ā¤d 24ā¤g 20ā¤Ā» 13:55
masak ah, there you go.
PerlJam prepares for a mandatory "training" on dysfunctional teams 13:59
14:07 broquaint left 14:10 awarefish left 14:12 mizioumt joined 14:13 iblechbot left 14:16 awarefish joined
pmurias ruoso: i can work on p6opaque right now? (you don't have uncommited stuff?) 14:16
pugs_svn r26666 | pmurias++ | [re-smop] exposed symbols needed for p6opaque 14:19
14:20 mberends joined
masak mberends: good afternoon, good sir. 14:21
mberends good afternoon to you too, sirrah.
masak mberends: how's that OO-ification of proto coming? 14:22
mberends there is a Sockets test working locally. Sorry, the promised tuits for proto were stolen. Today looks good, however. 14:23
masak ok.
mberends: I'm holding back so I don't start micromanaging you. :) 14:24
mberends: better to give you free hands and then discuss the result, methinks.
jnthn If I create a local branch in git, it stays local unless/until I push the branch at some point, right? 14:25
masak is trying to learn efficient teamwork
mberends heh, micromanaging me doesn't work. each attempt makes future ones less likely to succeed.
masak jnthn: aye.
mberends masak: could you help me with some OS X networking input? 14:26
masak mberends: possibly.
what do you need?
jnthn pmichaud: ping me when you're about :-) 14:27
mberends some netstat arguments and the resulting output. in Linux the command 'netstat --tcp --listen --numeric' works for the test. How would OS X so something similar? 14:28
*do
BSD is unlikely to support the GNU long option names, I fear. 14:29
re: the micromanaging, I do expect you to refactor my refactoring ;) 14:30
masak me too, but that's not micromanaging. 14:31
that's just pedantry :)
mberends :) let's go back to calling it teamwork 14:32
masak gist.github.com/106487
mberends: fair enough.
mberends: oh, and that gist url was for thee, sir.
mberends gotit, thank you kindly 14:33
14:33 minazo joined 14:35 frew|work joined 14:36 [particle] joined 14:37 alester left 14:40 ejs1 joined 14:41 payload left 14:42 broquaint joined
mberends masak: pray wouldst thou perform this command on thy shell, and dispatch the result unto me: netstat -f inet -p tcp -a -n 14:45
14:45 azawawi left, zamolxes left
masak mberends: I shall gladly comply, good sir. 14:46
what strikest me is a long list of addresses of some kind, fashioned in six different columns. 14:47
ah, and the word "Proto" is topmost! :)
mberends that be goode
hah!
lol
proto is everywhere, just as we planned ;) 14:49
masak world domination by default. :)
14:50 alester joined
mberends Could you send a gist of the netstat output? It seems to be the right data. 14:52
masak well, what exactly would I be sending. 14:53
moritz_ www.catalyzed.org/2009/05/the-perl-...idity.html very much to the point IMHO
masak I don't want to compromise the security of my university.
mberends rather let's not risk anything. If I knew exactly what the data contained, I would probably not be asking for this trial, so I cannot promise that it is safe. 14:55
masak moritz_: nice post.
mberends: I'll email you. 14:56
mberends masak: good workaround :)
masak there, sent. 14:57
alester I don't like the implied message that it's OK that we scorn people and are hostile. 14:58
"If you come to us and do X, we will be hostile, and we're OK with that."
15:00 eternaleye left
moritz_ I think it's a very good description of the current state of the perl community, wether we like it or not 15:00
alester It is a description, but I don't see you damning it.
15:00 alester left, alester joined, alester left 15:01 mizioumt1 joined, eternaleye joined, payload joined
moritz_ that's probably because I can very much understand the reasons 15:01
and damning something which I understand and maybe even did a few times myself would make me a hypocrite 15:02
15:02 mizioumt left 15:04 hudnix joined 15:05 nihiliad joined 15:07 _REPLeffect joined
mberends masak: thanks, the netstat layout is very different than the Linux equivalent, but our good friend regex will find the values required :) 15:07
15:07 _REPLeffect is now known as REPLeffect
masak mberends: I hope there will come a day when such workarounds are no longer needed. :) 15:07
mberends when Apple and Microsoft follow Novell and switch to Linux, that day will come ;) 15:08
masak I was referring more to being able to do these things natively in Perl 6. but YKWIM. :) 15:09
moritz_ wonders if Debian/GNU FreeBSD will be usable at the time of the next release :-)
15:10 icwiener joined 15:11 eMaX left 15:15 alester joined
alester back, sorry. 15:15
15:15 justatheory joined
alester moritz_: The way I read that posting, it sounds like you're OK with the state of affairs as it is now. I'd rather we (as members of a commenuity) explicitly disapprove of it. 15:18
moritz_ alester: first of all, I didn't write it. 15:19
alester OK, it sounded like someone else said you did.
but mea culpa.
moritz_ no problem
masak well, I said "nice post".
because I liked it when I read it. 15:20
moritz_ I do not like hostility, but I think before we explicitly disapprove of it, we should offer other behavioural patterns
alester I don't see that there needs to be an order.
The other behavioral pattern is "Don't be hostile." 15:21
moritz_ ie what to do instead, when somebody acts if #perl$something was a support channel
alester: no, that's not a pattern
"not a circle" is also not a geometric figure
alester I disagree.
moritz_ I made the experience that telling people what to do can work far better than telling people what not do to 15:22
if you tell an addict "don't smoke", that will help nothing.
if you tell him what he can do in order to stop smoking, you might help him. 15:23
alester Are we hostility addicts? Interesting idea.
masak if someone comes to me and wants to know how to program something, but is unwilling to learn the required background knownledge for being able to do the task, I might decide that it's not an efficient use of my time to continue helping that person.
alester masak: Nobody's suggesting otherwise.
moritz_ alester: not addicts, but many are surely caught in behavioural patterns
(including me) 15:24
masak alester: that's all I got out of that post. the "ok, you can go away now" part is when everyone on a channel reaches that conclusion.
alester Yes, but one need not say it.
masak indeed.
moritz_ and many learned that if somebody didn't invest any effort, a quick way to get rid of them is to offend them, so that channel is clear for more efficient talk 15:25
masak and most people probably don't.
moritz_ not because they have fun offending somebody, but because it's a very easy solution
alester I think they DO have fun offending people
or showing superiority.
masak alester: that would definitely be a part of it, yeah. 15:26
alester: that's what happens when a group forms.
it gets an inside and an outside.
alester Somewhere in my blog-posts-to-write list is "You don't always have to be better than everyone else."
moritz_ alester: there may be some of those, but you'd have trouble convining them of anything else
masak and some people seem to like to patrol the border.
alester I'm less concerned with the hardcore jerks than I am those who are leaning that way and may not realize it. 15:27
mberends This channel is noted for the patience and helpfulness of its members, trying to encourage more people to join it. Other channels are a bit more exclusive and intolerant. The members here should consciously avoid drifting in that direction as Perl 6 becomes reality.
moritz_ alester: and I think that those can be helped by showing them other options.
15:27 FurnaceBoy joined
alester moritz_: I'm not saying not to show them. 15:27
moritz_ alester: good :-) 15:28
masak I think we should consciously promote kindness and helpfulness, recognising it in people and picking up patterns we like.
moritz_ alester: I just believe that it'll be much more efficient than telling them what not to do
masak++
pmichaud jnthn: I'm about
jnthn pmichaud: Hi :-) 15:29
pmichaud good morning, #perl6
jnthn Good weekend?
pmichaud yes, reasonably good weekend. I finally got my office cleaned up, which is good because apparently something in the office was triggering an allergy.
jnthn Wow!
Was it an old lolcat? ;-)
alester moritz_: OTOH, there are things where it is not possible to provide an alternative. 15:30
15:30 payload left
Tene Good morning Perl 6! 15:30
moritz_ alester: sure
masak pmichaud, Tene: o/
Tene I'm very busy teaching and pbx-ing this week, but I should still be around occasionally. 15:31
Just hilight me or leave a msg with purl.
Tene AFK, teaching.
masak or phenny++.
jnthn pmichaud: I've been doing a lot of thinking about object stuff, and want to discuss some ideas I have for changes.
pmichaud jnthn: okay.
I was thinking of fixing arrays today. 15:32
(has-a vs. isa)
jnthn Nice!
pmichaud What sorts of changes are you thinking of? Or do you wish to discuss them some other time? 15:33
jnthn Now is fine with me if it is for you.
I've got very little on my schedule at the moment, and knowing if the things I'm looking to pursue are along the right lines would unblock me.
Anyway, the easy-ish one first. 15:34
Summary: I think we need to take the changes you are planning for Parrot's lexpads and apply them to objects too. 15:35
That is, we'd create an instance of the object with the containers set up and traits applied once.
To get a new instance, we'd clone this.
pmichaud We'd still have to do something with their initial values. 15:36
masak literal++ # for his p6l thinking on docstrings
jnthn That means we can do traits on attributes just look on any other container, should be a bit more efficient, and will clean up the bugs we currently have where you override BUILD and get a null PMC access.
pmichaud well, I totally understand the problem with BUILD -- it just needs a rewrite. 15:37
jnthn Initial values are done at BUILD time rather than being traits.
We'd still do that lot at build time.
pmichaud is there any way we could use the protoobject as the copy?
jnthn It's not about initial values, it's about initial containers.
And the traits being applied to them at compile time (or once). 15:38
Well, that's kinda the next and bigger thing I wanted to talk about.
pmichaud go ahead. :-)
jnthn I've been thinking a lot about the metaclass/representation/instance thing.
15:39 awarefish left
jnthn I've spent a few hours looking at smop to see what's going on there too. 15:39
I think that in places we can learn from them. I really, really don't see us following their representation API because it doesn't map well onto Parrot.
Anyway, to summarize... 15:40
1) PMCs are representations. A representation does now how to provide storage of methods, attributes, a parent list and so on. It also should point to a meta-class, however. 15:41
alester moritz_: One benefit of being jerks, though.
jnthn 2) Our REPR API is basically part of the PMC vtable interface.
alester I've abandoned two projects recently that I wanted to help contribute to because my welcome was so hostile, so I'm back to working on Parrot splint targets.
jnthn 3) The meta-class instance should be a singleton. It doesn't actually hve any state itself, so is not per-class. But rather, the it uses the representation API to get at the data it needs. 15:42
[particle] alester: glad to see we're at the bottom (now top) of your todo list :P 15:44
jnthn 4) We would create a P6opaque PMC, which will subclass Object. Unlike Object, it can be instantiated and it basically is our proto-object. It provides all of the add_method etc interface through vtables. However, it creates a Parrot class behind the scenese and is really delegating there.
alester not ranked. Just two other projects I use more.
and that I hadn't looked at at all.
jnthn The first time we instantiate it, it would create an initial instance and set up the containers (we'd intercept set_attribute perhaps). 15:45
Then for future instantiations we'd clone this one.
So yes, it is a lot like cloning the proto-object. It could almost *be* cloning the proto-object apart from it's awkward because we don't know our storage layout until we have fully defined the class. 15:46
15:47 kimtaro joined
jnthn 5) We'd have a cheat-like-hell version of P6Opaque too, or maybe just the same one that cheats if it sees our meta-class is the default one, that doesn't have to delegate anything at all to the meta-class. 15:48
15:48 ejs1 left
jnthn (so we can be fast) 15:48
6) find_method will do some magic too...like handing back a P6Invocation PMC instead of just the method. This knows how to get a whole candidate list. On the first invocation it acts like invoking the first candidate, but it also stashes itself in that candidate's lexpad, which is how callwith and callsame and that lot would work (as we discussed a bit in Oslo). 15:49
(p6opaque's find_method on the non-default meta-class would have to delegate to ^can in order to get the candidate list...) 15:50
15:51 PhatEddy left
jnthn That's about it. Basically though it means we move to something that looks a bit more prototype based. 15:51
skids is going to have to study up just to understand all that :-)
pmichaud Okay, here are my initial reactions 15:52
overall, it's probably a good idea
jnthn However, we're mostly staying class-based under the hood.
jnthn stops talking and listens :-)
pmichaud it's certainly a good idea from a potential-compatibility-with-smop perspective
15:53 clkao left, hcchien left
pmichaud As far as singleton metaclass instance goes, we're actually pretty close to that now. We could make P6metaclass into a singleton -- I simply had it creating separate instances because it provided an easy place to stick the name and protoobject attributes. Those could probably be properties on the Class PMCs, though, in which case we don't need separate P6metaclass objects. 15:54
I do see some big advantages to that.
jnthn (class PMCs already have a name slot and a namespace slot that we could well just re-use, btw)
pmichaud I'm not sure that's a good idea.
Parrot's idea of name and namespace might not exactly match Perl 6's idea of name and namespace. 15:55
jnthn Yes, that's true.
pmichaud indeed, they often don't match.
jnthn I'm happy to keep those separate.
pmichaud we also want to be sure we do something smartish with anonymous classes.
anyway, continuing on... 15:56
15:56 japhb left
pmichaud I'm not sure that add_method needs to be done through a vtable interface, or why having it go through the vtable interface is important or an advantage. 15:56
jnthn It's not about the vtable interface, it's about needing to call add_method on the meta-class. 15:57
For when people have custom ones and want to do something funky with it.
pmichaud right, so it could just be an add_method method, but not necessarily a vtable function.
jnthn OK, to clarify...
pmichaud (we've already been working to move away from vtable functions for class manipulation)
jnthn I'm proposing that we stick to vtable methods for our _represenation_ interface, not our meta-class one. 15:58
pmichaud why?
or what's the important distinction?
jnthn Because our representation = our object instance.
pmichaud you'll need to qualify "object" there. 15:59
(in order for me to understand)
jnthn Let me try and give an example.
class Foo { }; my $x = Foo.new; 16:00
$x here is an instance, and Foo is too (just the proto-object)
erm, type object ;-)
16:00 Psyche^ joined
jnthn Representations are just the underlying storage for an instance. 16:01
pmichaud just storage, not methods?
jnthn p6opaque is really just Parrot's Object PMC.
Well, here's where smop is very prototype-ish.
16:02 japhb joined
jnthn In the smop world, so far as I can follow anyway, they're all stored on the object. 16:02
pmichaud ("object"?)
jnthn I can only guess that in a clone they don't actually clone the method list.
as in, the instance
In the Parrot world, every instance points back to a class which is the storage of the methods, etc.
pmichaud okay.
jnthn smop conflates the two much more.
pmichaud In the Parrot world, every instance points back to a class which is also the schema for its attributes. But not the attributes themselves. 16:03
jnthn There's no separate thing representing the commonalities between objects of the same class.
Right.
pmichaud Got it.
jnthn What I'm proposing is that we have a sinlge type, P6opaque, that we deal with directly for doing everything.
16:04 barney joined
jnthn The fact that it does have a Parrot class behind the scenes is something that we shouldn't need to care about. 16:04
pmichaud okay, that gets to another question... would P6opaque go into Parrot, or just be Rakudo-specific?
arnsholt A priori, that should be distinct from Parrot, no? 16:05
pmichaud arnsholt: if so, that causes major issues for PGE, PCT, and NQP.
all of which are built on a Perl 6 class model.
16:05 hcchien joined
jnthn I'm undecided on that. Part of it depends on whether you see PGE, PCT, NQP etc adopting this in place of P6Object. 16:05
pmichaud well, P6object was intended to be Parrot's version of P6opaque. 16:06
arnsholt Ah, right. In that case, I think making it a(nother) Parrot library would be a solution
pmichaud I do know that we have to keep the two compatible somehow, or else we'll end up with some serious tool breakage. We'd then be left with the undesirable choice of maintaining separate object models for PGE versus rakudo (and papering over the differences where we can), or making PGE Rakudo-specific. 16:07
my intent has always been that PGE, PCT, NQP, etc. use the same object model as whatever Perl 6 (Rakudo) is using. 16:08
jnthn I guess what I'm proposing sort of supplants a lot of the work P6object is doing, and tries to do it in a more "native"-ish way.
pmichaud where "native" means...?
jnthn native is probably the wrong word. 16:09
It's possible that refactoring P6Object into a different shape may get us where we want to go too. 16:10
TimToady can parrot be supplied with tools compiled under rakudo without needing to include rakudo?
pmichaud TimToady: with difficulty. It depends on how much those tools depend on the Perl 6 runtime.
TimToady well, if we want to distribute bare rakudo applications to run on parrot... 16:11
japhb Speaking of native versus Rakudo object models ... IIRC, native typed structs are way down the line on the Rakudo roadmap. But I need to be able to create some simple {Un,}ManagedStruct wrappers for use with OpenGL. How should I represent them? With a Perl 6 class that has-a member that is-a ManagedStruct PMC?
16:11 Patterner left, Psyche^ is now known as Patterner
pmichaud TimToady: then yes, a Perl 6 runtime would need to be available. Of course, if it has 'eval' or if any of the components are P6 source then we'd need the compiler. 16:12
jnthn But I think actually trying to have some kinda p6opaque PMC that knows how to be prototype-ish rather than some of the stuff we do in P6Object today (creating anonymous subclass etc) could be cleaner/more performant etc.
pmichaud jnthn: perhaps I should provide a little background
first, I'm not at all opposed to what you're proposing, nor am I trying to argue for the status quo. I agree with you that a lot of things could be cleaner.
when creating P6object (late 2007!), I was hoping that it would point the way to a more prototype-based model for Parrot's object system 16:13
indeed, I was hoping that eventually Parrot itself would move to a model more like P6object instead of the one it has now. 16:14
And the reason I chose "P6object" as the name (as opposed to "P6opaque") was to explicitly recognize that it might not be exactly what we need.
jnthn *nod*
pugs_svn r26667 | lwall++ | [STD] add trait_auxiliary:<hides>, masak++ 16:15
masak :)
jnthn I guess that part of what I want to do is to bring the prototype stuff a bit "closer to the metal" as it were.
pmichaud what I found in writing the compiler tools was that Parrot's existing OO metamodel wasn't well suited for writing the tools.
so I created P6object as an abstraction latyer between them.
*layer
16:16 iblechbot joined
jnthn P6object is serving pretty well in doing that. I just really feel we need to - soon - sort out exactly what our alternative meta-classes and our representation interface is going to look like. 16:16
pmichaud I'm totally okay with refactoring/replacing P6object to do that. But I'm not okay with the tools and Rakudo maintaining closely-parallel-but-not-quite-identical metamodels. 16:17
jnthn And we need to address the current mis-match in Perl 6 dispatch semantics and Parrot ones, so we can get one Perl 6 method call to actually be - in the p6opaque-with-no-custom-metaclass case - just a single Parrot method call in the common case. At least so far as the dispatch goes. 16:18
Yes, your point on the tooling is spot on.
pmichaud If we find ourselves having to go that direction (separate models), then I'd probably prefer to just focus on Rakudo and let someone else take over the design/maintenance of the other tools entirely. 16:19
(and rakudo would keep its own set.)
But that's not a very tasty answer.
jnthn I don't think we'll have to.
pmichaud Agreed.
jnthn In fact, I think we could even keep P6object looking the same on the outside. 16:20
pmichaud well, that was P6object's purpose.
jnthn And change the way it does stuff on the inside.
Right, I guessed as much. :-)
pmichaud as an intermediate step, can we see about simply refactoring p6object to look how we want, before worrying about making it into a PMC ? 16:21
I agree that as a PMC it could be much faster.
jnthn Well, here's the other issue. 16:22
I kinda *need* to subclass Parrot's Object anyway.
pmichaud Because ... ?
jnthn Because I want to override find_method.
So I can get us down to jsut emitting $P0.'foo'() for method calls
pmichaud That sounds slightly different (more) 16:23
jnthn And so I can hand back a P6Invocation to wrap the stuff.
I agree I maybe could work my way around all of this in various ways. But I'd much rather just try and deal with the bigger picture while I've got a pile of time without the distractions, and the problems in my head. 16:24
pmichaud Oh, I agree.
I'm trying to get to a final model that doesn't involve workarounds. Or, to the extent that we do have workarounds, they're workarounds we plan to live with for a very long time. 16:25
jnthn Right. And I'm getting nervous about the current pile.
I know that this alternative-representation-and-metaclass stuff sounds like advanced features that most people don't need. 16:26
pmichaud would the override for find_method be found in Rakudo or in Parrot ?
16:26 clkao joined
jnthn But in reality, we've already done most of the common parts of S12. :-) 16:26
pmichaud I'm not at all arguing against it. I'm particularly not saying "we really don't need it".
I'm simply trying to see where all of the pieces will end up going. 16:27
jnthn I'm thinking that we'd probably want to not have p6opaque in Parrot, but something else that p6opaque would subclass.
pmichaud can that something else be "Object PMC"?
jnthn Not if we want it to act as Just Another Representation.
16:28 masak left
jnthn It'd be a subclass ob the Object PMC. 16:28
*of
It'd not even override find_method there.
pmichaud I don't understand.
I don't understand why we need the intermediate class. (I'm weak on the "representation" aspects of the model) 16:29
jnthn Maybe it's best if I compare how it looks now with how I see it looking afterwards.
Basically imagining the program: class Foo { }; Foo.new 16:30
We: 1) Create a Parrot class object to represent Foo. 2) Set it up with attributes and methods. 3) Create a subclass of it to serve as our proto-object. 4) Instantiate that and install it in the namespace. 5) Use that proto-object to find the actually Parrot level class and instantiate that to get our instnace of Foo. 16:31
*actual
pmichaud japhb: just to note that your question didn't get overlooked -- it's on the stack. 16:33
jnthn I'm proposing that this becomes: 1) Create our p6opaque or whatever we call the Parrot version. 2) Through the metaclass, add the methods and attributes. The metaclass is implemented in terms of calling v-table methods on p6opaque. 3) Install that into the namespace; it *is* our proto-object. 4) Look up the proto-object in the namespace and just (if it's in $P0 say) do $P0.'new'() on it to get our instance. 16:34
pmichaud better would be new $P0
jnthn Notice that we never create, nor touch, a Parrot Class. WE are always dealing with a single proto-object, which behind the scnees is dealing with a class object for us.
That would work too.
16:35 ejs left, abra joined
jnthn The real work would be done in the instantiate v-table method. 16:35
pugs_svn r26668 | hinrik++ | [S07] fix the year in Last Modified date
jnthn The reason that we need to use the v-table methods as our repr API is because it's essentially "out of band".
pmichaud what you're proposing is where I wanted to get with P6object, yes.
16:36 cosimo joined
pmichaud i.e., that the user of P6object wouldn't ever touch a Parrot class. 16:36
16:36 minazo is now known as ElectricHeavyLan, hercynium joined
jnthn If you look at smop, they have a different (but not so different as I was expecting...or maybe I just don't grok it) mechanism where there is another bunch of methods, like our vtable ones, that operate on the representation, that are invisible from normal method dispatch. 16:36
literal I see that Synopses 20 (Introspection) and 30 (Standard Perl library) are marked "Draft" on perlcabal.org/syn. Is that true? Are there drafts somewhere? 16:37
pmichaud You were just running ahead of me in terms of adding object capabilities to Perl 6.
So we decided that we'd prototype things in Rakudo and then (hopefully) unify it with P6object.
I.e., I didn't want P6object changes to bottleneck your work. It sounds like we're at the unification step :-) 16:38
jnthn Sure. I think we might be at the point of wanting to unify now.
oh, agreement!
:-)
moritz_ literal: I never heard of these two
pmichaud I've never been entirely happy that Rakudo does as much Parrot-level class manipulation as it does. 16:39
at least we now have it abstracted into guts.pir instead of in actions.pm :-)
jnthn Yes. :-)
16:40 eMaX joined, ElectricHeavyLan left
pmichaud does the existing Parrot vtable API have all of the operations we'd need? 16:40
jnthn Well, I was still trying to figure PCT out when I put the very first cut of OO support in. :-)
Yes, I think so, because I think I made sure of that when I was involved in doing Parrot OO stuff before.
moritz_ don't forget to write a deprecation notice for P6object if you want to change some interfaces 16:41
pmichaud we can preserve the existing interfaces, no problem.
jnthn moritz_: I'm hoping we'll avoid interface changes.
moritz_ ok
pmichaud the whole point of P6object was to make it look like you had a Perl 6 HLL interface.
(to the extent that we knew what that was in November 2007))
Returning to... 16:42
16:34 <jnthn> I'm proposing that this becomes: 1) Create our p6opaque or whatever we call the Parrot version...
Is the adding of methods, attributes, etc. done through normal method calls or through vtables? 16:43
jnthn both ;-)
pmichaud I mean user-level API.
jnthn You call methods on the meta-class.
pmichaud Sorry.
jnthn user-level API for adding stuff to a class is "talk to the meta-class"
pmichaud which would be metaclass.'foo'(...) ? 16:44
and not foo_opcode metaclass, ...
jnthn Right.
pmichaud okay.
jnthn Oh yes, the meta-class provides a completely method interface.
And the uses the representation API (e.g. vtable stuff)
pmichaud it uses a vtable interface behind the scenes, but the standard programmer (the one creating classes and methods) never actually sees it 16:45
(sees the vtable interface)
16:45 DemoFreak left
jnthn Correct. 16:45
pmichaud Good.
Last question.
What do we do about Int, Str, and Num ?
since those are outside of P6object.
16:46 ejs joined
pmichaud (I should say "Integer", "String", and "Float") 16:46
and Complex.
and Exception.
jnthn Good question. We currently cheat massively on those.
pmichaud Yes, primarily for performance reasons.
16:46 eternaleye left
pmichaud I didn't want to write wrappers for them. 16:46
jnthn The thing is that from what I can follow Int is meant to be a role.
pmichaud I'm fine with Int being a role and a punned class. At the time this was all going together we didn't have a clearly defined Parrot Role implemenetation. 16:47
jnthn for sure.
pmichaud so I didn't see how to make that work.
jnthn I think the way it's maybe meant to work is something like...
role Int { has int $.Int }
Note lowercase int in there
That is, it has a natively typed attribute. 16:48
[particle] you're talking about parrot hll classes here, not perl 6 classes
pmichaud bigints.
role Int must handle bigints.
jnthn Ah, true.
[particle] it's hll integration at that point
pugs_svn r26669 | hinrik++ | [p6-proj] point to the SVN::Web interface for t/spec link
pmichaud I guess my question is, do we rewrite custom pmcs for Int/Num/Str/Complex/other in Rakudo, or do we re-use what Parrot already provides (or both?) 16:49
jnthn So today are we subclassing Parrot's Integer?
pmichaud Today we subclass Parrot's Integer, yes.
jnthn OK, nothing I'm suggesting takes away our ability to subclass Parrot classes.
pmichaud except those subclasses are instances of Object PMC
(those subclasses create instances of Object PMC) 16:50
jnthn At the moment we just do
pmichaud I don't know that subclassing Integer would give us something that uses P6opaque
jnthn intproto = p6meta.'new_class'('Int', 'parent'=>'parrot;Integer Any')
That would jsut become something like:
(well, it'd stay exactly the same, I mean, it would inside P6Object do something like...) 16:51
$P0 = new 'P6opaque'
p6metaclass.'add_parent'($P0, ...pmcproxy for parrot;Integer here)
Remember P6Opaque is just a subclass of Object. The only difference is that it's creating a kind of Class PMC (or a subclass of that) behind the scenes. 16:53
pmichaud that's kind of my point.
we don't do that now.
jnthn And it knows how to handle add_method and forward it.
We can't?
pmichaud right now what we do is more like
$P0 = new 'Class'
p6metaclass.'add_parent'($P0, ...pmcproxy for parrot;Integer)
we can't currently 'add_parent' on an Object.
(yes, I know you're saying that we do that) 16:54
16:54 cdarroch joined
jnthn Right, that's what I'm proposing p6opaque would give us the ability to do. 16:54
pmichaud right, I understand that.
thinking.
jnthn Behind the scenes it will boil down to a call on a Parrot Class object.
pmichaud so, when I want to create a new Int instance, how does that happen? 16:55
start with Int.new 16:56
which becomes intproto.'new'()
intproto is a P6opaque, yes?
jnthn Correct.
16:57 DemoFreak joined
pmichaud so here's where I lose the details. 16:57
what happens next?
[particle] heh, the opaque part works.
jnthn So we call .new. .new calls intproto.CREATE, which in turn calls intproto.^CREATE
Which then goes to the representation API and does new intproto
That calls VTABLE_instantiate. 16:58
On p6proto
pmichaud (also, I wonder if protoobject-ness should just be a mixin role :-)
jnthn This will then manufacture and return a new instance (with the pre-initialized containers from a clone stuff happening)
No no no, that's what you've missed! :-)
16:59 icwiener left
jnthn We don't do a protoobjectness mix-in any more. 16:59
pmichaud how does 'defined' work, then?
or stringification?
jnthn defined goes on "do we have any instance data? if not, we must be the undefined proto" 17:00
Though that is a choice of the metaclass (the default one does that, though...)
pmichaud s/the undefined proto/an undefined proto/
jnthn Yes, an.
pmichaud there can be more than one undefined proto.
jnthn Right, exactly. Dog{ :name<Fido> } for example. 17:01
pmichaud In the case of Int, what does "do we have any instance data" mean?
jnthn Remember that when we subclass a PMC, we (currently, and this seems unlikely to change anytime soon in Parrot) end up with a proxy instance of Integer.
So there's just an Integer PMC sat in the instance data store. 17:02
pmichaud but you're saying that Int (the type object) wouldn't be a proxy instance
yes?
s/but/so/
jnthn It isn't today.
pmichaud Today it is, yes.
jnthn Today it _looks_ like it is.
pmichaud rakudo: say Int.does('Integer');
p6eval rakudo 0588e8: OUTPUTĀ«1ā¤Ā» 17:03
jnthn But actually it's creating an instance of the Integer PMC.
[particle] rakudo: say Int.PARROT()
p6eval rakudo 0588e8: OUTPUTĀ«ā¤Ā»
jnthn It's the reason you can say things like $P0 = getattribute my_rakudo_int, [ 'Integer' ], 'proxy'
patmat www.pastie.org/467035
pmichaud .PARROT doesn't help here, because it's an anonymous class
patmat can someone tell me whats wrong with that?
I'm a programming newbie in general, i cant find an error :( and the interpreter tells me crap 17:04
pmichaud jnthn: yes, but I can do get_attribute of the 'proxy' on the protoobject.
(currently)
patmat Statement not terminated properly at line 25, near "say 'Moech"
jnthn Right. With what I'm suggesting here, the proto-object wouldn't have any storage.
literal patmat: there's no semicolon at the end of line 24
pmichaud patmat: "my $antwort" is missing a semi
patmat ooops sorry
moritz_ also this:
if ($antwort == 'j') { $i == True; 17:05
you probably meant '$i = True;'
jnthn and probably eq 'j' :-)
pmichaud you probably meant $i = ($antwort == 'j'); :-)
you probably meant $i = ($antwort eq 'j'); :-)
literal and '$i = False;'
moritz_ oh, when you ask "what's wrong?", please also tell us why you think that something's wrong
or what error you observe 17:06
17:06 rafl joined
pmichaud moritz_: he did do that 17:06
moritz_ oh
patmat :P
pmichaud 17:04 <patmat> Statement not terminated properly at line 25, near "say 'Moech"
jnthn pmichaud: That is, the pointer the RPA that currently provides the storage hangs off would just be a PMCNULL.
moritz_ yes, I see
jnthn (In the proto)
patmat excuse accepted! :PP
moritz_ "#perl6 is too busy today" ;-) 17:07
jnthn pmichaud: Your point on stringification is a harder one. Hmm.
pmichaud jnthn: okay, I can see that it would work.
jnthn: isn't it just the same as defined?
"am I the protoobject, if yes, stringify this way -- else delegate to my class/proxy"
jnthn Oh, yes, that would work.
pmichaud it might still have some rough edges, though. 17:08
moritz_ understoot at most half of what jnthn and pmichaud wrote in the last hour ;-)
jnthn Sure.
moritz_ *understood
pmichaud okay, now for the big question.
the really big question. :-)
jnthn ...i can haz cheezburger? 17:09
pmichaud this feels to me like a refactor that is at least as big as the parameter refactor we did at the beginning of the year.
patmat hm i really have a problem with this... easy ... program
jnthn pmichaud: It's non-small, for certain.
pmichaud a bit more so, because it also impacts all of the tools.
jnthn pmichaud: But I don't think we have to do it all in one chunk like that one.
ruoso jnthn, I'm back 17:10
jnthn e.g. phase 1 - fill out the meta-class stuff and make sure everything is using that, not twiddling with class objects.
pmichaud jnthn: you think we can do it in pieces, given the amount of parrot-class specific stuff that is .... ah, you want to get rid of rakudo's fiddling with class objects.
jnthn I think that might be a good first step.
If it is doing everything through the meta-class then the next steps become easier. 17:11
pmichaud agreed.
jnthn ruoso: hi
pmichaud and I'm happier at any rate.
because I much prefer it to be doing things via the meta-class than manipulating classes and roles directly as it does now.
jnthn Agree.
ruoso jnthn, I should be around for a while now... after a all-morning meeting 17:12
pmichaud How hard would it be for us to write up the interface before doing the code?
jnthn ruoso: OK. I figured out a few more answers to my questions.
pmichaud i.e., kinda of like a design document?
actually, it would be worthwhile for Parrot to have a P6object PDD.
jnthn pmichaud: Well, I was pondering as a first cut we'd try following the HOW API in www.perlfoundation.org/perl6/index....mop_oo_api 17:13
pmichaud I've been trying to follow that as closely as I can already.
so that's a good way to go.
jnthn Right, so we should be in decent shape then.
pmichaud does this mean that BUILD/CREATE/etc. would move into Parrot, or at least a version of them?
patmat www.pastie.org/467824 17:14
no error, but it doesnt work right
jnthn That's a question I had for ruoso. It appears that smop has BUILD/CREATE in Object delegating to the metaclass.
patmat same with $i = True und $i = False
jnthn That may be right, but it wasn't entirely clear to me if it should in S12.
Oh, wait,
CREATE has to.
pmichaud For now I'm fine if it does mean that...
moritz_ patmat: in what way does it not work? 17:15
jnthn Because it deals with the representation API.
pmichaud Right.
patmat moritz_ the questoin "Willst du noch einmal..."
question.. pops up
pmichaud Although perhaps it can do so internally in P6object (Parrot), and we just expose it in Rakudo.
patmat then then
moritz_ patmat: ... but you never assign anything to $answer
patmat Use of uninitialized value 17:16
moritz_ erm, $antwort
patmat and then the game starts again
moritz_ my $antwort = prompt('Mƶchtest du noch einmal spielen?[j/n]';
my $antwort = prompt('Mƶchtest du noch einmal spielen?[j/n]');
that would work
but as it is currently, $antwort is never filled with a value
jnthn True, though .new is defined in terms of CREATE, bless, BUILD, etc. 17:17
pmichaud jnthn: well, we can have a cheating .new in P6object and a "real" new for Rakudo.
or something like that.
jnthn True. :-)
patmat ah oops it works 17:18
pmichaud and I'm not opposed to having CREATE/bless/BUILD in P6object anyway. We already have .new .
jnthn OK.
So I think we could maybe do something like:
1) Fill out the metaclass some more.
pmichaud I'm just trying to not bring too much of Perl 6 into Parrot (because I think we'll get some resistance)
jnthn 2) Get everything using that that currenlty muddles with classes directly.
patmat i even forgot the $*IN.get; first moritz_ 17:19
for $antwort... because I was so angry!! :P
17:19 clintongormley joined
jnthn 3) profit 17:19
erm
:-)
pmichaud I'm fine with this. 17:20
Except in #2, it should be "Get everything _in Rakudo_ ..."
other languages still need to work for 8 months.
jnthn True. We do need to be careful not to break other stuff.
I wonder if we need to have a new flag "use p6opaque" or whatever we call it for a while. 17:21
17:21 nbrown_ joined
ruoso you are both aware of the pseudo implementations in src-s1p. right? pmichaud, jnthn... 17:21
jnthn ClassHOW.pm and Object.pm?
literal is the perlcabal.org stuff (CSS and such) not in pugs svn?
ruoso yes
jnthn Yes, I've read them both, multiple times.
Today. :-) 17:22
pmichaud I've read them once or twice.
moritz_ literal: the css could be on perl.org, not sure
pmichaud jnthn: I don't think we need the flag.
jnthn pmichaud: No, I hope not.
pmichaud jnthn: I'd say we just get started on it and see where we run into roadblocks.
moritz_ literal: docs/feather/index.hml loads the css from search.cpan.org/s/style.css
ruoso if everything is right, no flag is needed
patmat moritz_: you still have the '=*IN; 17:23
pmichaud ruoso: we're having to coordinate with other Parrot projects that might not have the same ideas.
patmat ' in your tutorial
pmichaud (thus the possible need for the flag)
jnthn ruoso: .^! is your syntax for "call this on the repr API"?
moritz_ patmat: ah, forgot one file
literal moritz_: I'm wondering where the CSS used for S26.html is
wollmers std: my $a1'a; 17:24
p6eval std 26669: OUTPUTĀ«ok 00:02 36mā¤Ā»
ruoso jnthn, yes... .^! is the calls the the repr is supposed to intercept
jnthn ruoso: OK.
wollmers rakudo: my $a1'a;
p6eval rakudo 0588e8: ( no output )
jnthn ruoso: And do you mostly only deal with the repr API in the meta-class in smop?
moritz_ literal: docs/feather/perl.css, presumably
ruoso jnthn, yes... I try to keep it private to the meta-class implementations
wollmers rakudo: my $a1'a = 'c', say $a1'a; 17:25
p6eval rakudo 0588e8: OUTPUTĀ«Use of uninitialized valueā¤ā¤Ā»
ruoso but just for encapsulation sake
jnthn ruoso: OK, good - sounds consistent with where I'm wanting to go with Rakudo on this.
ruoso no coding limit, actually
[particle] wollmers: s/,/;/
17:25 kimtaro left
pmichaud rakudo: my $a1'a = 'c'; say $a1'a; 17:25
p6eval rakudo 0588e8: OUTPUTĀ«cā¤Ā»
wollmers rakudo: my $a1'a = 'c'; say $a1'a;
p6eval rakudo 0588e8: OUTPUTĀ«cā¤Ā»
pmichaud Rakudo doesn't parse item assignment yet.
literal moritz_: ah, yes 17:26
pmichaud (The comma is valid Perl 6, Rakudo gets it wrong.)
mberends moritz_: about to add a socket test to pugs, could you please look at it (and try it out)? 17:27
moritz_ mberends: I have to run now, but I can try it in about 3hrs
mberends: feel free to commit right away
jnthn pmichaud: OK, sounds like I have my work cut out for me. :-)
mberends ok, that's fine.
pmichaud jnthn: well, I'm hoping it's more our/us than you/you 17:28
i.e., I'd like to closely follow what's going on.
(because it impacts so many of the tools and other language items)
jnthn Oh, for sure. :-)
I didn't say you hadn't got your work cut out for you too. :-) 17:29
pugs_svn r26670 | mberends++ | [t/spec/S32-io/IO-Socket-INET.t] shell script forks client and server
pmichaud in all of this, does P6object learn to deal with roles, too?
jnthn It'll get a compose_role method on the meta-class. I think we'll end up with a RoleHOW as well as a ClassHOW. 17:30
pmichaud Excellent.
jnthn I think we'll keep things fairly minimal though (enough but not too much).
pmichaud I want it to be role-aware also.
jnthn No way do we want to drag the parametricism into P6object.
pmichaud Agreeed. 17:31
okay, time for lunch here.
I've lost much of the morning I was planning to work on Lists, though :-)
but for good reason.
jnthn Sorry!
I feel unblocked now though. :-) 17:32
pmichaud good.
okay, I'll bbiah
pugs_svn r26671 | hinrik++ | [docs] comment out .TITLE in css (not used anywhere afaik), this should make S26's Title look right again 17:33
17:37 nbrown left, nbrown_ is now known as nbrown
pugs_svn r26672 | mberends++ | [IO-Socket-INET.t] remove developer scaffolding 17:39
17:41 M_o_C joined 17:49 kimtaro joined 17:51 amoc joined 17:57 pyrimidine joined 18:00 mizioumt joined 18:06 mizioumt1 left 18:20 barney left 18:21 LylePerl left
pmurias ruoso: hi 18:23
18:24 pyrimidine_ joined
ruoso hi pmurias 18:27
pmurias ruoso: what does ^!is_container do? 18:28
ruoso pmurias, it's just something to check if p6opaque should intercept FETCH 18:30
18:31 kimtaro left 18:33 pyrimidine left 18:34 kimtaro joined
ruoso pmurias, I'm not sure it should really stay there... but it was a necessary hack at that point... 18:36
pmurias ruoso: removing it and waiting till it bites us again is an option 18:39
ruoso pmurias, well... I know why it bites us 18:40
it solves an infinite loop, because at some point, the HOW might end up calling FETCH on the p6opaque when implementing the FETCH 18:42
pmichaud back from lunch 18:45
pmurias ruoso: want we have to face the problem when dealing with object which define FETCH? 18:47
18:47 M_o_C left 18:48 nbrown left 18:49 pyrimidine_ is now known as pyrimidine 18:55 PacoLinux left, PacoLinux joined 18:58 payload joined 18:59 abra left, abra joined 19:00 ElectricHeavyLan joined 19:01 kimtaro left
wollmers pmichaud: couldn't locate the problem with Hindi characters in identifiers in rakudo/src/parser 19:03
dalek kudo: r2e5607d | pmichaud++ | docs/spectest-progress.csv:
spectest-progress.csv update: 379 files, 10999 passing, 11 failing
wollmers pmichaud: they contain VOWEL SIGNS which are alphabetic but not letters 19:04
pmichaud wollmers: it's likely that Parrot's idea of alphabetic isn't purely unicode. 19:05
wollmers pmichaud: specs are also confusing - see my post at p6l 19:06
pmichaud I'll leave the specs for TimToady to figure out. :-) 19:07
at any rate, unless there's a strong immediate need for it, I'm not likely to worry too much about getting the alphabetics exactly right until Parrot cleans up its string handling a bit. 19:08
jnthn We passed 3,000!
wtf 19:09
pmichaud 3000?
jnthn We passed 11,000!
.oO( yeah, I really do need my dinner... )
pmichaud well, 3 == 0b11
and right now we would appear to be at 11010 which looks nicely binary :-)
jnthn I haven't the slightest idea where I got the number 3,000 from. :-)
pmichaud well, your statement wasn't false. :-) 19:10
jnthn On the up side, my dinner is about ready. :-)
lol
I've found one small issue.
pmichaud only one? ;-)
jnthn Meta-class methods should really take the current object as the first parameter.
Often though they're taking it as the named to=>
pmichaud in p6object, or in what we're trying to move to?
jnthn Which probably was done before the "object as first parameter" thing was spec, to be fair.
In p6object. 19:11
pmichaud I don't mind if that changes. It's very unlikely anyone is using it.
wait, let me rephrase that.
I suggest using a different method name for now to get things working/correct.
We can then deprecate the old names and update later.
similar to the changes happening in Match for .text, .ast, etc. 19:12
19:12 abra left
jnthn I might just be able to have both as multi-variants with the same name too. 19:12
pmichaud that's fine also.
jnthn I didn't check yet.
That'd be best but yes, different names...
OK, my nom is ready. bbiab
19:18 ejs left
literal moritz_: there's something wrong with the urls in your blog posts, see for example perlgeek.de/blog-en/perl-6/blackjac....writeback 19:20
I am referring to the "posts in this category" links
19:21 fridim_ joined 19:23 ejs joined 19:37 ruoso left 19:41 clintongormley left 19:42 fridim_ left 19:43 fridim_ joined 19:45 fridim_ left
pmichaud pugs: say List ~~ Array; 19:47
p6eval pugs: OUTPUTĀ«ā¤Ā»
pmichaud pugs: say Array ~~ List;
p6eval pugs: OUTPUTĀ«1ā¤Ā»
jnthn That's same as Rakudo, right? 19:48
pmichaud yes, I was just verifying.
jnthn :-)
pmichaud prepares to rip out src/classes/List.pir . 19:50
pmichaud looks for something to distract him.
jnthn removes everything but List.pir from pmichaud's view
20:01 rindolf left
pmichaud oops. 20:03
I pushed to the wrong branch.
japhb pmichaud: I believe my question is still on your stack ...? Re: proper way to use {Un,}ManagedStruct from Rakudo?
ouch
pmichaud shouldn't be a problem, though.
Yes, the question is still on the stack. The answer is likely that we don't know the answer yet.
at least, I'm sure that I don't. 20:04
and my best guesses are likely to change in May.
japhb pmichaud: OK, thanks. 20:05
dalek kudo: r1c0ac16 | pmichaud++ | perl6.pir:
Convert several internal Lists to Arrays.
20:07 ejs left 20:13 ejs joined 20:14 aindilis joined 20:28 pyrimidine left 20:29 kimtaro joined 20:41 kimtaro left 20:43 ejs left 20:45 PacoLinux left 20:46 PacoLinux joined 20:49 kimtaro joined 20:50 jeremiah_ left 20:51 kimtaro left
TimToady pmichaud: note that for the self ticket, the phrase in question is a has initializer, which runs in BUILD context, and hence does have an obvious instance self, so this isn't really about binding self to the class 21:00
moritz_ did you reach any conclusions if want() is going to stay? 21:02
pmichaud TimToady: okay, thanks. 21:04
So we definitely can't leave self as being a plain lexical, unless we're making use of 'lift' somehow.
or otherwise attach the context to self... which we have to do anyway. I'll have to think about it a bit more. 21:05
jnthn The thing on the RHS of the = is made a closure already; we just need to make it an anonymous method.
pmichaud That works for me.
jnthn (and remember to pass self in too)
pmichaud well, the closure has to be invoked on the newly built object, I suspect. 21:06
jnthn yes
pmichaud okay, I'll update the ticket. 21:07
in the general case, though, is 'self' available in the body of a class declaration? 21:08
(as opposed to within initializers, as the ticket case shows)
jnthn No.
pmichaud (ticket updated)
TimToady I don't see what it buys us that $?CLASS does give us better
or some reasonable fascimile 21:09
self in the class seems to be confusion waiting to happen
pmichaud good for me
more ticket updating. :-)
TimToady moritz_: given how lazy Captures are, I don't see much use for want any more 21:10
pmichaud DO NOT WANT want()
should we start excising it from the spec and test suite? 21:11
TimToady and while an optimizer or type inferencer may be able to conclude what the eventual context will be, I hate to have user code relying on the optimizer
Tene I still like my evil continuation-based want(). :)
TimToady Tene: feel free to write one, and advertise it on E-Bay
hacking good continuation support into all the VMs on which Perl 6 will run will be a good side benefit 21:12
jnthn TimToady: Agree self in the class is just confusion waiting to happen.
pmichaud I think we all agree that there's no self in the class declaration. Good.
moritz_ wonders if all those tests in assign.t can be written without want() in a meaningful way, and who will do that 21:13
(not me)
pmichaud moritz_: I'm sure they can. I think they were misdiagnosed as needing want() in the first place.
moritz_ it's not a misdiagnose that they need want() right now ;-) 21:14
pmichaud I'm not even sure the tests are correct according to the current spec. 21:15
21:15 pmurias left
moritz_ feel free to rip them out, only leaving a list of cases that could be tested 21:16
I'm not at all into the list/item assignment business :/
21:17 PacoLinux left, PacoLinux joined
pmichaud I'll see about cleaning them up after I've refactored List/Array, I think. 21:17
Tene does the 'return a capture' thing work well enough in rakudo to replace the uses of want() ? 21:18
jnthn pmichaud: How are you finding the refactor?
pmichaud jnthn: interruptions around the house, so I think I'll do it tonight when there should be fewer of those.
jnthn kk
pmichaud (we had various deliveries, kids are home, wife is home soon, etc.)
jnthn I tired to start on it once and found it painful.
pmichaud I think the trick is going to be that RPA maps to Array and not List. 21:19
jnthn Yes, but that still leaves isa => hasa.
pmichaud I don't see that as being a big problem.
so far the few things I've modified have gone okay.
jnthn ok, nice. 21:20
pmichaud it does want a major rewrite of src/classes/List.pir, but that's not too big a deal. I've only rewritten that file three times previously :-)
s/rewritten/written/
pugs_svn r26673 | moritz++ | [t/spec] made Socket test a bit more robust
pmichaud (rewritten it twice previously)
jnthn Yeah, if there's anyone who's suited to the job, it's you. :-) 21:21
pmichaud For the first cut I'm also going to leave List as eager -- just want to get the isa/hasa done first.
Then I'll fix up postcircumfix:<[ ]> and proxies.
then we can work on laziness.
jnthn Sure, I wasn't expecting laziness to be tackled in with this just yet. :-)
pmichaud no, but it shouldn't be too difficult to add once this is done. 21:22
jnthn Indeed. 21:23
And also they can become roles. Woo.
pmichaud it might be more important to do parametric roles before tackling laziness.
jnthn ? 21:24
Oh, you mean just to make them parametric.
pugs_svn r26674 | lwall++ | [S12] clarify has = semantics
pmichaud right.
jnthn In theory, that'll be easy.
(Since I've done all the hard bits...)
pmichaud TimToady++ # S12 clarification looks great 21:25
21:28 Whiteknight joined
TimToady narcolepsis & 21:29
pmichaud afk for a bit
21:34 skids left 21:36 masak joined
masak oh hai. don't mind me. 21:36
rakudo: class A { has $.a is rw }; A.a = 5; say "alive"
p6eval rakudo 1c0ac1: OUTPUTĀ«Null PMC access in getprop()ā¤current instr.: 'infix:=' pc 14678 (src/builtins/assign.pir:20)ā¤Ā»
masak rakudo: say [].perl
p6eval rakudo 1c0ac1: OUTPUTĀ«[]ā¤Ā»
masak ah. the latter bug has already been fixed since my local revision. 21:37
masak submits rakudobug for the Null PMC access
jnthn masak: We already have at least one ticket for the "omg I tried to access state on a proto and it didn't work out too well for me" issue. :-) 21:39
masak jnthn: "what's a proto?" :P
jnthn I dunno, but Austria is grateful for it. 21:40
masak :)
jnthn: I think you're right. I'll leave it there in RT anyway, in case this was a yet-unfound case.
jnthn I'll just be able to close two. :-)
When I fix it. 21:41
masak exactly.
the statistics look better. everybody's happy.
jnthn finds an entire file in Rakudo that appears unused 21:42
pmichaud back
moritz_ jnthn: docs/ROADMAP? /me ducks and runs for cover 21:43
pmichaud yeah yeah
jnthn lol 21:44
pmichaud which file unused? 21:46
jnthn src/builtins/traits.pir
(we moved everything it did to guts.pir) 21:47
(ages ago)
running spectests anyway just to make sure it really can die.
pmichaud I think src/pmc/perl6array.pmc is also unused.
jnthn same 21:49
will check and clear that one up too
heh, not even compiled 21:50
21:59 Morpheus_PL left 22:00 iblechbot left 22:11 exodist left 22:15 PacoLinux left 22:18 rdice joined 22:22 mizioumt1 joined 22:24 mizioumt left 22:25 nihiliad left 22:26 masak left, LadyLunacy left 22:33 jiing left 22:37 simcop2387 left 22:44 skids joined 23:01 mizioumt1 left
jnthn Infinoid: I fear dalek is now giving me karma^W^W^Wreporting commits at the moment. :-S 23:10
Infinoid jnthn: It worked 3 hours ago, did it break since then? 23:14
jnthn Infinoid: I've commited several things recently. 23:15
(last hour or so)
Infinoid To the "master" branch?
23:16 DemoFreak left
jnthn * master 23:16
yes
And I'm doing git push origin master
Infinoid: see github.com/rakudo/rakudo/commits/master 23:17
dalek kudo: r5ea5aad | jnthn++ | build/Makefile.in:
Add P6Invocation to makefile.
jnthn ok, it got that one...there were a few before that it missed htough.
*though
Infinoid I think pmichaud's (apparently non-branch?) 1c0ac16 may have confused it 23:18
23:18 DemoFreak joined
Infinoid or maybe the review link looks weird now that it's not the most recent, I dunno. 23:18
jnthn Yeah, I think pmichaud accidentally comitted to the wrong place earlier. 23:19
Infinoid Ok. There is a known issue with dalek's github parser with non-linear history. That'll affect non-rebase branch merges, it needs to keep a hash of already-seen revisions to solve that one 23:20
but dalek++ for at least outputting *something* 23:21
I don't know whether you're seeing is that or something else
^what
jnthn OK, no biggie.
pmichaud I pushed to the master branch on accident, but it was a harmless change.
(I've already run spectests to verify :-) 23:22
Infinoid No biggie, that shouldn't have broken dalek then
jnthn pmichaud: I don't have ICU here, but I just comitted something that affects your ICU code. It looks completely sane (just adds a cast).
pmichaud: Was a patch from NotFound++ for C++ building.
(in perl6.ops) 23:23
pmichaud checking.
dalek kudo: rd86c014 | jnthn++ | src/ (2 files):
Fixes to let us build on C++. Patch courtesy of NotFound++.
pmichaud github++ for making this easy.
jnthn It didn't occur to me until after I'd checked it built etc that this code would be ifdef'd out for me.
pmichaud there's also a change there that gets rid of a 'const' declarator...? 23:24
jnthn pmichaud: Apparently it upsets the C++ build. I dunno the specifics, ask NotFound on #parrot. I do know that he's done a lot of Parrot C++ stuff, so was inclined to trust his patch.
pmichaud same here. 23:25
jnthn I have about zero C++ experience.
Happy someone who does is helping out though. :-)
skids jnthn: well, no wonder you get work done, then :-) 23:26
jnthn I've also tossed in a stub of another PMC I'm gonna need. Not finished yet...
skids: ;-)
pmichaud ah, that section of code probably shouldn't be using strwhich at all. 23:27
(it's improperly typed) 23:28
jnthn Ah.
C++ ftw then. :-)
well
C++ compiler. Not the language.
pmichaud testing fix. 23:31
23:31 simcop2387 joined 23:42 DemoFreak left 23:49 payload left
jnthn Wow. Parrot's startup time just improved, it would seem. :-) 23:55
jnthn tries it