perl6-projects.org/ | nopaste: sial.org/pbot/perl6 | evalbot: 'perl6: say 3;' | irclog: irc.pugscode.org/ Set by mncharity on 25 March 2009. |
|||
00:04
payload left
00:09
hercynium joined
00:12
davidad joined
00:24
DemoFreak left
00:25
payload joined
|
|||
wayland76 | Here's a lambdabot idea: link it to Google define, and have it grep for perl or programming definitions in the output | 00:26 | |
(as an alternative to the perl6 glossary idea that mncharity presented) | |||
00:28
c9s_ joined
00:40
dduncan joined
00:42
nihiliad joined
00:56
iblechbot left
01:16
meppl joined
01:26
davidad left
01:27
davidad joined
01:31
M_o_C left
01:37
minazo joined
|
|||
dalek | kudo: fb2752d | pmichaud++ | t/spectest.data: Add S05-mass/named-chars.t to spectest (w/icu requirement) |
01:54 | |
01:57
minazo left
02:25
dKingston left
|
|||
meppl | good night | 02:33 | |
s1n | frioux|home, frew|work: ping | 02:46 | |
02:51
amoc left
02:56
meppl left
03:12
hercynium left
03:19
Limbic_Region left
03:22
alester joined
03:36
Sepheebear joined
|
|||
s1n | jnthn: ping | 03:46 | |
03:51
justatheory left
|
|||
wayland76 | I'm proably the only one left :) | 04:03 | |
04:06
cotto joined
04:08
TimToady left
|
|||
s1n | does actions.pm have any mechanism to check if a file exists? | 04:21 | |
04:23
diakopter left
|
|||
s1n | rakudo: use v6 | 04:26 | |
p6eval | rakudo 881ed3: ( no output ) | ||
s1n | wtf, that's giving me a NSF complaint | 04:27 | |
04:27
justatheory joined
|
|||
pmichaud | s1n: what platform? | 04:29 | |
std: #<is this an error?> | 04:30 | ||
p6eval | std 26066: OUTPUT«Undefinedok 00:02 34m» | ||
pmichaud | std:#<is this an error?> | ||
std: 'hello' | |||
p6eval | std 26066: OUTPUT«ok 00:02 35m» | ||
pmichaud | std: #(is this an error?) | ||
s1n | pmichaud: gentoo amd64 | ||
p6eval | std 26066: OUTPUT«Undefinedok 00:02 34m» | ||
s1n | how can we make that NSF error tell me what file it's complaining about? where would i find that code? | 04:31 | |
ahh, i had to do a real clean, it stopped doing it now | 04:32 | ||
pmichaud | yes, I need to clean up the makefile to detect those situations a bit better. | ||
s1n | rakudo: use v6; | 04:33 | |
p6eval | rakudo 881ed3: ( no output ) | ||
s1n | man, nevermind | ||
it's still doing it for me | |||
without the semi-colon, it works, from -e | |||
pugs_svn | r26067 | pmichaud++ | [t/spec]: Add some #?rakudo skip markers, fix some tests. | 04:37 | |
r26068 | pmichaud++ | [t/spec]: Fix embedded comment error in S32-array/delete.t . | 04:48 | ||
04:49
alester left
|
|||
s1n | nope, figured it out | 04:53 | |
when i leave the rakudo directory, it then gives the NSF error | |||
when i am in that directory, everything works fine | 04:54 | ||
pmichaud: sound like a bug? | |||
even when i copy the fakexecutable, it still fails | |||
same thing with using 'parrot perl6.pbc' when outside of the rakudo directory | 04:55 | ||
dalek | kudo: 0e8b7a4 | pmichaud++ | t/01-sanity/09-types.t: Fix error in comment in t/01-sanity/09-types.t |
04:57 | |
kudo: 68ea385 | pmichaud++ | (3 files): Add ability to support embedded comments. |
|||
pmichaud | yes, sounds like a bug. | 05:06 | |
but it's working for me. :-| | 05:07 | ||
oh, I spoke too soon. I get the same error. Hrm. | |||
05:08
nihiliad left
|
|||
pmichaud | oh, looks like a bug jnthn introduced. | 05:10 | |
I suspect I'll have to let him repair it. | |||
The code being generated by actions.pm is now adding a line like: .include "src/pr_macros.pir" | 05:12 | ||
which obviously won't work from outside of rakudo's root. | |||
05:22
brunoV left
|
|||
s1n | pmichaud, jnthn: i filed it as #64448 | 05:38 | |
this is kinda stopping me from my development and i don't understand what it's doing there to know how to fix it myself | |||
pmichaud: there are in fact 3 uses of .include in actions.pm, are all 3 going to be issues? | 05:40 | ||
pmichaud | s1n: no, the other .includes use stuff that comes with parrot | 05:49 | |
so the others aren't an issue. | |||
I don't understand what it's doing either -- jnthn just added it today. | |||
(I'm also not sure why it's a macro and not just a normal function, which is the way we've been doing most stuff like this.) | |||
comments indicate we have to do it this way to get a newclosure from the correct scope | 05:53 | ||
05:54
eternaleye joined
|
|||
pmichaud | I think there ought to be a cleaner approach than the macro one. | 05:55 | |
dalek | kudo: 924ec3f | pmichaud++ | docs/spectest-progress.csv: spectest-progress.csv update: 347 files, 8406 passing, 0 failing |
06:00 | |
wayland76 | Are you telling me macros are unclean? | ||
:) | |||
pmichaud | they generate a lot more code than a simple function call. | 06:02 | |
anyway, sleep time for me. bbl | |||
wayland76 | Ah, there is that. Goodnight :) | 06:03 | |
06:03
nacho joined
06:15
Interfect joined
06:47
justatheory left
06:51
cognominal left
07:09
DemoFreak joined
07:12
ejs joined,
dduncan left
07:33
jhuni joined
07:37
kane_ joined
07:54
pmurias joined
07:58
Tene_ joined
08:11
Tene left
08:15
c9s_ left
08:16
c9s_ joined
08:19
meteorjay joined
08:32
masak joined
|
|||
masak | ahoj, Parrot-butterflies. | 08:33 | |
08:35
iblechbot joined
|
|||
wayland76 | Parrot? | 08:36 | |
(for a minute I was wondering what "ahodj" was, until I discovered it was a euro-ism (or IPA-ism) for "ahoy") | 08:37 | ||
masak | wayland76: aye. it's a common greeting in Slovakia. | 08:38 | |
wayland76 | Oh, I like sovlakia -- lamb or chicken for preference :) | 08:39 | |
(souvlakia *is* the plural for souvlaki, isn't it? :) ) | |||
masak | ehm. | ||
wayland76 | :) | ||
sorry | |||
masak | :P np. | ||
now, there was this Spec addition that I let slip yesterday... | 08:40 | ||
masak backlogs | |||
09:01
ejs left
|
|||
masak | the return type of shift, according to S32, is Scalar. | 09:01 | |
what if the first element happens to be a Hash or an Array? | |||
masak thinks that return type should be Any or Object | 09:02 | ||
09:05
ashizawa left,
ashizawa joined
|
|||
masak | I'd be happy if someone reviewed this patch to S09: gist.github.com/90163 | 09:07 | |
it captures what I want to say, but I feel it might not be clear enough to merit inclusion in the spec. | 09:08 | ||
comments welcome. | |||
wayland76 | forgiveness...permission :) | 09:10 | |
09:11
barney joined
|
|||
moritz_ | masak++ | 09:13 | |
masak | ok, so I'll commit, then. | ||
it's just that I feel that the entire issue explained in that section is... subtle. | 09:14 | ||
hm, I'll add a phrase about ++ and -- et al DWIMming, too. | 09:15 | ||
wayland76 | Well, if TimToady doesn't like it, he can say so :) | ||
masak | I hope others dare speak up, as well. :) | 09:16 | |
moritz_ | ruoso will ;-) | 09:17 | |
masak | 哈哈 | ||
09:17
mjk joined
|
|||
wayland76 | What's with the triangle and two squares? | 09:19 | |
masak | wayland76: I find that the sound of laughter is best captured by sinographs. I don't know why, but they really look like laughter to me. | ||
wayland76: it says "haha". | |||
Patterner | What about ":) :)"..? | 09:20 | |
masak | Patterner: those are two smiles. | ||
...rotated 90 degrees. | |||
wayland76 | LoL? | ||
(List of Lists, right? :) ) | 09:21 | ||
masak | fair enough, but none of these are actually onomatopoetic. | ||
the character 哈 is actually pronounced "ha1" | |||
wayland76 | What's 1? | 09:22 | |
masak | wayland76: a high, level tone. | ||
well, you asked. :) | |||
wayland76 | I did. | ||
How do you say it with a tone pattern like this: /^ | |||
masak | rising and then dropping? | 09:23 | |
wayland76 | Rising on the first, and rising and dropping on the second :) | ||
masak | in Mandarin, that's not a single tone. but I guess tone 2 followed by tone 4 would sound something like that. | ||
wayland76 | oh, ok :) | ||
pugs_svn | r26069 | masak++ | [S09] added table of operations that autovivify | 09:32 | |
masak | moritz_: running 'make spectest' on a half-month-old t/spec turned out to be a bad idea. :) | ||
wayland76 | Anyway, since there's no activity on my Parrot patches, I think I'll go read for a while. I may not be back until Monday. | ||
09:32
mjk left
|
|||
masak | moritz_++ # much must have happened in the spectest suite. | 09:32 | |
09:32
wayland76 left
|
|||
masak | moritz_: by the way I'm getting 'Redeclaration of variable ' on some test files, and warnings on some others. | 09:33 | |
moritz_ | masak: I know | ||
masak | thought so. :) | ||
moritz_ | in particular my.t tests redeclaration | 09:34 | |
masak | aye. | 09:35 | |
jnthn | oh hai | 09:48 | |
masak | jnthn: hai | 09:49 | |
jnthn | oooh...I broke-ish Rakudo :-( | ||
masak | the one on github? or your local copy? | 09:50 | |
jnthn | erm, well both | 09:51 | |
masak | sounds interesting? if what you say is true, how come all tests pass? :P | 09:52 | |
s/\?/./ | |||
jnthn | masak: I broke using Rakudo out of the build directory, apparently. :-( | ||
moritz_ can confirm that it's broken | |||
jnthn | By trying to do good code re-use. ;-) | ||
masak | oh. | 09:53 | |
jnthn | Yeah, makes sense now I think about it. Just pondering a good solution... | ||
masak | that's right, it doesn't work here either. | ||
09:54
jhuni left
09:56
ejs joined
|
|||
jnthn | (git stash)++ | 09:58 | |
masak | git stash is strange. :) | 09:59 | |
it's like a completely orthogonal way of storing away changes. | |||
moritz_ | it works fine as long as your stash is small | ||
if it's too big, you forget which stash is what | |||
10:00
mikehh left
10:01
masak left,
masak joined
|
|||
masak | I've never had more than one thing stashed at a given time, I think. | 10:02 | |
jnthn | I've just pushed a second one... | ||
Though plan to grab it back soonish. | |||
OK, I need coffee, then to fix my fail. | 10:03 | ||
pugs_svn | r26070 | moritz++ | remove duplicate test (for example S12-attributes/instance.t | 10:05 | |
r26071 | moritz++ | [t] merge oo/attributes/attribute_list.t into instance.t | |||
r26072 | moritz++ | remove bogus test | 10:11 | ||
10:13
aindilis joined
|
|||
pugs_svn | r26073 | moritz++ | moved both.t to spec, after small cleanup | 10:14 | |
10:16
ruoso left
|
|||
pugs_svn | r26074 | moritz++ | remove partially bogus and duplicate test | 10:17 | |
dalek | kudo: 4698d3f | (Moritz Lenz)++ | t/spectest.data: add S12-methods/class-and-instance.t to spectest.data |
||
moritz_ | somhow I forget the [t] marker when working with git :( | 10:20 | |
moritz-- | |||
pugs_svn | r26075 | moritz++ | [t] move overload.t to spec/ | 10:21 | |
r26076 | moritz++ | [t] remove now empty directory (why can't git-svn do that?) | |||
r26077 | moritz++ | [t] move test with longer name than content to spec/integration/ | 10:24 | ||
jnthn | (BTW fix for the stuff I broke currently smoking) | 10:27 | |
pugs_svn | r26078 | moritz++ | fixed wrong usage of try { } | ||
moritz_ | @karma moritz | 10:28 | |
lambdabot | moritz has a karma of 500 | ||
jnthn | Half way to a thousand :-) | ||
@karma jnthn | 10:29 | ||
lambdabot | You have a karma of 200 | ||
jnthn | Beating me my miles. | ||
*by | |||
@karma jonathan | |||
lambdabot | jonathan has a karma of 65 | ||
jnthn | meh | ||
10:31
Interfect left
|
|||
jnthn | moritz_: I'm seeing a fail in t\spec\S12-attributes\instance - that's one you just added/updated, I think? | 10:35 | |
FAILED tests 88-93 | |||
10:37
barney left
10:44
Cybera1 joined
|
|||
dalek | kudo: f17a691 | jnthn++ | src/parser/actions.pm: Can't .include the parametric roles macro at runtime, so just inline the PIR (best I can think of for now; don't see to have Q:PIR{ } in NQP, which may allow something shorter). |
10:45 | |
kudo: 64a8988 | jnthn++ | : Merge branch 'master' of [email@hidden.address] |
|||
jnthn | Erm. I think dalek missed two other patches that were in there too... | 10:46 | |
masak | they were ex-TER-minated! | 10:47 | |
jnthn | :-P | ||
For anyone who's curious, I just made Positional and Associative also be parametric roles. | |||
oh curious | 10:48 | ||
On github if you follow the link for that commit you get a 404. | |||
masak | github has done that for me a lot lately. | ||
jnthn | quickreportgithubbug | 10:49 | |
masak | I've asked on #github and github-devel, but gotten no sensible reply. | ||
:/ | |||
jnthn | :-S | ||
I suspsect that dalek not seeing them and this issue are not unrelated. | |||
masak | I think it's reasonable to assume that github has run into scaling problems. | 10:50 | |
10:54
mikehh joined
|
|||
jnthn gets back to the patch that he ran out of energy to debug last night | 10:58 | ||
All being well, we should have typed arrays/hashes/subs in the next few days. | 10:59 | ||
moritz_ | jnthn: (re failing test) looking... | ||
masak | jnthn: (re typed arrays) neat. | 11:00 | |
jnthn: what about the untyped-array-of-ints problem? did that one ever get resolved? | 11:01 | ||
jnthn | masak: Not that I'm aware of. | 11:02 | |
pugs_svn | r26079 | moritz++ | [t/spec] fixed bad plan, jnthn++ | ||
jnthn | masak: Though cleaning up S14 is on my task list, so may ponder it a bit during that. | 11:04 | |
masak | the untyped-array-of-ints problem, in my opinion, is a place where gradual typing becomes a bit ugly. | 11:09 | |
moritz_ | which problem are you refering to? | 11:10 | |
pugs_svn | r26080 | moritz++ | [t] move autopair_instantiation.t to spec/, clean up | ||
masak | moritz_: an untyped array, containing just Ints, say. | 11:11 | |
moritz_: passed to a sub which only accepts Array of Int. | |||
jnthn | rakudo: my $x = Pair.new(key => 'DEFAULT', value => 1); say $x.key | ||
p6eval | rakudo 881ed3: OUTPUT«DEFAULT» | ||
masak | moritz_: it feels wrong not to accept the array as a matching parameter, just because it's not typed. | 11:12 | |
moritz_ | aye | ||
masak | moritz_: but the alternative -- traversing it and checking -- is even worse. | ||
moritz_ | agreed | ||
masak | moritz_: and what if it's lazily infinite? | ||
jnthn | rakudo: my $x = Perl6Pair.new(key => 'DEFAULT', value => 1); say $x.key | ||
p6eval | rakudo 881ed3: OUTPUT«invoke() not implemented in class 'NameSpace'current instr.: '_block14' pc 62 (EVAL_17:40)» | ||
masak | jnthn: that looks like a bug. | 11:13 | |
dalek | kudo: 58d1635 | (Moritz Lenz)++ | t/spectest.data: we now pass autopairs.t |
||
moritz_ | masak: check the first item, and dispatch on its type. And then install an assertion that throws an exception when the other values aren't of that type (if it's bound to something with a type constraint) | ||
Perl6Pair isn't specced anywhere :) | |||
masak | moritz_: sounds intriguing. | 11:14 | |
moritz_: you're right. no bug. | |||
jnthn | Actually I think the real problem is more general. | 11:15 | |
That scheme works for arrays, but then what of hashes? | |||
And then what of types that users write, etc. | |||
moritz_ | right | ||
masak | a hash doesn't have a first item. | 11:17 | |
and the "first item" part was the only thing in moritz_'s solution that felt arbitrary, so maybe something else is needed instead. | |||
moritz_ | maybe containers need to define a 'tell me a preliminary type' method | 11:18 | |
or even better | |||
they override .can | |||
masak | ooh! | 11:19 | |
moritz_ | and give the "right" answer, whatever is "right" in their opinion | ||
(and maybe return a Maybe instead of a True, or something) | 11:20 | ||
enum canType <NOWAY MAYBE ABSOLUTELY>; # ;-) | 11:21 | ||
afk | |||
jnthn | Ouch. | 11:24 | |
That's an...interesting...ordering problem. | |||
11:25
PhatEddy joined
|
|||
jnthn | (The export trait depends partly on Pair.key | 11:25 | |
...and exports itself...and export depends upon constructing pairs) | |||
masak | heh. | 11:28 | |
jnthn | export trait's implementation calls key | 11:29 | |
11:29
agentzh left
|
|||
jnthn | Thing is, by that point we didn't actually re-bless key into a Rakudo class. | 11:29 | |
Which now it's expected to be at the point of its first invocation. | |||
11:29
agentzh joined
|
|||
jnthn | oh, key isn't currently exporing itself, but it maybe should be... | 11:30 | |
So moving it up in the setting ordering helps. | |||
11:31
kane_ left
|
|||
masak | expect more of this down the road. | 11:34 | |
PhatEddy | I think I have a patch for the 99999[0] problem. Anyone have a thought about where the test for the case might go? | 11:35 | |
jnthn | Actually I've moved Pair.key out of the setting - I think it's one of those cases where we might just have to accept that it's kinda "low level". | 11:37 | |
And now | |||
> sub foo($x) returns Int { return $x ?? 42 !! "oh hai" } | |||
> say foo(1); say foo(0); | |||
42 | |||
Type check failed on return value | |||
lambdabot | <no location info>: parse error on input `$' | ||
<no location info>: parse error on input `;' | |||
jnthn | Now to see if we have any chance of making it through the tests. | ||
masak | jnthn: cool. | ||
jnthn | Whee. | 11:39 | |
> sub foo() returns Int { } | |||
> say &foo ~~ Callable | |||
1 | |||
> say &foo ~~ Callable[Str] | |||
0 | |||
lambdabot | Not in scope: `say'Not in scope: `&'Not in scope: `foo'Not in scope: `~~'No... | ||
Not in scope: `sub'Not in scope: `foo'Not in scope: `returns'Not in scope: ... | |||
jnthn | > say &foo ~~ Callable[Int] | ||
lambdabot | Not in scope: `say'Not in scope: `&'Not in scope: `foo'Not in scope: `~~'No... | ||
jnthn | 1 | ||
erm, sorry lambdabot! | |||
masak | jnthn: wow! | 11:40 | |
jnthn | std: sub foo() returns Callable[Int] { } | 11:44 | |
p6eval | std 26080: OUTPUT«ok 00:02 34m» | ||
jnthn | hmm, wonder why we can't parse that. | ||
11:47
jedai left
11:52
ejs left
11:56
Cybera1 is now known as Cybera
12:01
payload left
12:04
rgs left
12:33
kane_ joined
|
|||
pmurias | masak: .<> is desugared to .{} | 12:51 | |
12:51
ruoso joined
|
|||
masak | pmurias: so I should leave it out? | 12:51 | |
pmurias | think so | 12:53 | |
masak does so | |||
ruoso | HellO! | ||
12:54
Kisu left
|
|||
pmurias | ruoso: hi | 12:54 | |
ruoso | masak, .{} and .[] doesn't autovivify | ||
pmurias, hi | |||
masak | ruoso: no, I know that. | ||
that's the point of the rest of that section. | |||
but I'm at a loss to express what I want better than that. | |||
pmurias | ruoso: so my %hash<foo><bar> = 1 doesn't autovivify %hash<foo>? | 12:55 | |
masak | pmurias: yes, it does. | ||
and that's my point. | |||
ruoso | pmurias, yes... but only at the point you assigned | 12:56 | |
masak | ...and it's not very clear in my addition. | ||
ruoso | not before that | ||
masak | ruoso: we agree. | ||
moritz_ found that quite clear before | |||
masak | now help me make the text say that, too. :) | ||
12:57
meppl joined
|
|||
pmurias | masak: i'm not sure .unshift will autovivify | 12:57 | |
ruoso | masak, "causes the protoobject to be of the given type:" | ||
pugs_svn | r26081 | masak++ | [S09] removed .<> from the table | ||
r26081 | masak++ | | |||
r26081 | masak++ | It's just sugar anyway. pmurias++ for pointing that out. | |||
masak | ruoso: that's a long table heading. | ||
pmurias: well, me neither. | 12:58 | ||
ruoso | masak, that's not for the header | ||
moritz_ | why shouldn't it? | ||
ruoso | but for the text before the table | ||
masak | ok. | ||
ruoso | the header can simply be | ||
"operator", "type" | |||
pmurias | moritz_: normal autovivication works during binding | 12:59 | |
masak | ruoso: ok. your first suggestion makes for a strange sentence, but I'll see if I can make it work somehow. | ||
ruoso: "causes the protoobject to instantiate to the right type just in time:" | 13:00 | ||
ruoso: does that work for you? | |||
ruoso | a proto only instantiates to its own type | 13:01 | |
jnthn | rakudo: say Bool::True ~~ Bool | ||
p6eval | rakudo 881ed3: OUTPUT«1» | 13:02 | |
masak | ruoso: my %hash; %hash<foo><bar> = 42; # instantiates %hash<foo> as a Hash | ||
jnthn | rakudo: say Bool.ACCEPTS(True) | ||
p6eval | rakudo 881ed3: OUTPUT«0» | ||
jnthn | rakudo: say Bool.ACCEPTS(Bool::True) | ||
p6eval | rakudo 881ed3: OUTPUT«1» | ||
masak | ruoso: my %hash; %hash<foo>.push(42); # instantiates %hash<foo> as an Array | ||
ruoso | it creates a proto of the hash type | ||
eich is later instatiated | 13:03 | ||
8wich | |||
masak | ok... | ||
still not sure I understand the exact mechanism. | |||
pmurias | moritz_: disregard my answer, i got confused | ||
masak | ruoso: what about %hash<foo>[0]<bar>.push(42) ? that one has to instantiate two Hashes and two Arrays. | 13:05 | |
ruoso | the decision of it being a hash happens at .{} time | ||
but it is not instantiated at that time | |||
masak | ruoso: ack. | ||
pmurias | masak: my %hash; my $bar := %hash<foo>;%hash<foo> doesn't exists here;$bar = 5;%hash<foo> is 5 here | ||
masak | pmurias: ack. | ||
I'm not sure why you're telling me this. | 13:06 | ||
I know. | |||
pmurias | masak: my %hash; my $bar := %hash<foo><bar>;%hash<foo> doesn't exists here;$bar = 5;%hash<foo> is a Hash here | ||
masak: that's what i meant to say ;) | |||
masak | yes. | ||
I know this. | |||
pmurias | so it's not the .{} which autovivfies but binding to %hash<foo><bar> | 13:07 | |
masak | I have a patch with ruoso's latest suggestions, along with my improvements. can I commit it, or should I nopaste it? | ||
pmurias: yes. I know. | |||
pmurias: if you feel that the added table contradicts that somehow, please help me improve it. | |||
don't just tell me things that I already know. :) | 13:08 | ||
pugs_svn | r26082 | jnthn++ | [t/spec] A few tweaks to keep the return type checks happy. | ||
13:08
brunoV joined
|
|||
masak | gist.github.com/90203 | 13:09 | |
pmurias | masak: did you find the .push and .unshift autovivification in the specs? | 13:11 | |
masak | pmurias: no, the table is a tidied-up version of a moritz_ IRC comment. | ||
but it makes sense to me. | 13:12 | ||
moritz_ | pmurias: if he did, he wouldn't have to add it ;-) | ||
masak | I think .push is the same kind of change as assigning to .{} | ||
moritz_ | .[] | ||
masak | oh. right. | 13:13 | |
ruoso | masak, but that would imply that you can simply | ||
push %foo<bar>, 1 | |||
and that's not going to fly | |||
moritz_ | ruoso: that's exactly how it works in perl 5 | ||
and maybe the way to go is over the subs | |||
pmurias | ruoso: push %foo<bar>,1 is arguably better | ||
as push is known to work on Arrays | 13:14 | ||
moritz_ | because there can simply be a function push($type_that_autovivs_potentially is rw, *@args) | ||
that does the autoviv | |||
and the method form could dispatch to that | |||
walk & | |||
ruoso | hmm... | ||
what is the $type_that_autovivs_potentially ? | 13:15 | ||
masak | I feel the current discussion is not about the change I'm about to commit, so I'll just go ahead and commit it. | ||
ruoso | masak, I'm still unconfortable | ||
masak | ruoso: me too. | ||
pmurias | masak: by the same reasoning one could expect .substr in lvalue context to also autovivify | 13:16 | |
ruoso | about the relationship between the protoobject and the instantiation | ||
masak | I don't entirely understand this issue. | ||
pmurias: I think the difference is that Hash and Array are container types. | |||
ruoso | the protoobject doesn't "instantiate to the right type" | ||
the protoobject needs to be of the correct type from beggining | |||
it just happens to be autovivified laetr | 13:17 | ||
masak | ruoso: ok, I think I see what you mean. | ||
PhatEddy | rakudo: my @a; @a[1] = "b"; my @b = @a | ||
p6eval | rakudo 881ed3: OUTPUT«Null PMC access in isa()current instr.: '!CALLMETHOD' pc 16471 (src/builtins/guts.pir:74)» | ||
masak | PhatEddy: old or new? :) | 13:18 | |
PhatEddy | Just a reminder on patch rt 62948 | ||
masak | ah. | ||
pmurias | masak: .{} and .[] are special cased | ||
masak | pmurias: aye, so the issue really is that they don't belong in a table with push and unshift, yah? | 13:19 | |
jnthn | rakudo: my @a; @a[1] = "b"; say "alive" | ||
p6eval | rakudo 881ed3: OUTPUT«alive» | ||
jnthn | rakudo: my @a; @a[1] = "b"; say @a.perl | ||
p6eval | rakudo 881ed3: OUTPUT«Null PMC access in isa()current instr.: 'parrot;List;!flatten' pc 5960 (src/classes/List.pir:227)» | ||
masak | especially since push and unshift work immediately, whereas .[] and .{} are delayed, as ruoso points out. | ||
ruoso | masak, pmurias, well.. the question is really if push should autovivify or not... | 13:20 | |
jnthn | rakudo: my @a; @a[1] = "b"; say @a[0] | ||
p6eval | rakudo 881ed3: OUTPUT«Use of uninitialized value» | ||
masak | ruoso: I think it should. | ||
jnthn | rakudo: my @a; @a[1] = "b"; .say for @a | ||
p6eval | rakudo 881ed3: OUTPUT«Use of uninitialized valueb» | ||
jnthn | Hmm. | ||
ruoso | the table should contain everything that autovivifies, determining the type of the autovivified object | ||
PhatEddy | jnthn: hint rt 62948 describes the problem in some detail (rt.perl.org/rt3/Public/Bug/Display....?id=62948) | ||
pmurias | perl6: my $foo;$foo<bar> = 1; say $foo; | 13:22 | |
p6eval | pugs: OUTPUT«bar 1» | 13:23 | |
..elf 26082: OUTPUT«bar 1» | |||
..rakudo 881ed3: OUTPUT«Method 'postcircumfix:{ }' not found for invocant of class 'Failure'current instr.: 'postcircumfix:{ }' pc 4118 (src/classes/Associative.pir:77)» | |||
ruoso | mildew: say "am I alive?" | ||
p6eval | mildew: OUTPUT«Bareword found where operator expected at perl6-snapshot/STD.pm line 4, near "$LANG is" (Missing operator before is?)Bareword found where operator expected at perl6-snapshot/STD.pm line 5, near "$PKGDECL is" (Missing operator before is?)Bareword found where operator expected | ||
..... | |||
ruoso | pft | ||
13:23
Cybera left
|
|||
pmurias | a make in perl6-snapshot is needed | 13:24 | |
13:24
M_o_C joined
13:25
dKingston joined
|
|||
masak | the discussion about push, unshift, .[] and .{} stalled. I can't commit what I have, and I don't know what to change it to in order to be able to commit. | 13:32 | |
13:34
dalek joined
|
|||
jnthn | erm. oops! | 13:34 | |
jnthn promises to write shorter commit messages next time | |||
masak | :P | 13:35 | |
jnthn | OK, first cut of returns enforcement is in. | ||
Not at all perfect yet. | |||
masak smells rakudobugs in the air | |||
13:36
rgs joined
|
|||
jnthn | For example, it currently doesn't check implicit return values just yet. | 13:37 | |
masak | implicit return values? | ||
as in 'return' ? | |||
jnthn | sub foo() returns Int { return "oh hai" } # fails | ||
sub foo() returns Int { "oh hai" } # not enforced yet | |||
masak | aha, as in 'no return' :) | 13:38 | |
jnthn | Yes. | ||
Want pm's input on how to do that best. | |||
masak | jnthn: while you're between tasks, do you have any thoughts on rt.perl.org/rt3/Ticket/Display.html?id=62622 ? | ||
jnthn | This does bulk up the output a little in the PAST and in the PIR, so we may want to use a PIR macro or something to help that... | 13:39 | |
looking... | |||
masak | especially the last comment. | ||
jnthn | making prefix:<+> smarter is not so hard | 13:40 | |
masak | yes, but the other thing...? :) | ||
jnthn | Taht's harder. :-P | ||
masak | I suspected as much. | 13:41 | |
jnthn | Thing is that it's probably going to dispatch as infix:<+>(Any,Any) | ||
masak | I'll nopaste a piece of code from Druid to show a real-life case where this is annoying. | ||
jnthn | I guess it could then do prefix:<+> on each of its arguments and redispatch, which would probably give you the semantics you want. | ||
But at the cost of a double-dispatch. | 13:42 | ||
(Since prefix:<+> would be smart enough to give an Int, so infix:<+>(Int,Int) would get called, which would give back an Int) | |||
masak | gist.github.com/90211 | ||
I'm already typing those variables as Int, why should I need to explicitly cast the subtractions? | 13:43 | ||
that I needed to surprised me. | 13:44 | ||
13:45
PhatEddy left
|
|||
ruoso | masak, what is the type of $<coords>[0]<row_number>? | 13:45 | |
masak | ruoso: a Match, I guess. | 13:46 | |
ruoso | well... | ||
the return of Str - Int can't be Int | |||
masak | no? | ||
ruoso | what if the Str contain "1/3" | 13:47 | |
masak | I see that. | ||
ruoso | rakudo: say "1/3" - 1; | ||
p6eval | rakudo 881ed3: OUTPUT«0» | ||
ruoso | hmm... wasn't that supposed to be numified correctly? | ||
rakudo: say "0.33" - 1; | |||
p6eval | rakudo 881ed3: OUTPUT«-0.67» | ||
jnthn | ruoso: I guess because we don't do Rat yet. | ||
ruoso | ah | ||
ok | |||
masak | ruoso: in my particular case, I know for a fact that the string will always numify to an integer. | 13:48 | |
ruoso | then you should be happy by using Num as the type of your variable | ||
masak | ruoso: and if 4 - 3 is an integer, why shouldn't "4" - 3 be? | ||
ruoso: I don't see why I should need to. | 13:49 | ||
ruoso | masak, because the return of Str - Int is not an Int | ||
it's a Num | |||
rakudo: say ("1" - 1).WHAT | |||
p6eval | rakudo 881ed3: OUTPUT«Num» | ||
masak | well, that's what the ticket is about :) | ||
ruoso | there's no issue there | ||
Int is a type | |||
it's not a subset of Num | 13:50 | ||
(one could argue that it could be... ) | |||
if you really want Int precision, the cast is appropriae | 13:51 | ||
masak | ruoso: irclog.perlgeek.de/perl6/2009-02-28#i_946119 | ||
ruoso | if you don't really care, your variable should be of a less narrow type | ||
masak | ruoso: I'll be using those values as indexes to arrays, so I really care. | ||
ruoso: I just want Perl 6 to be as accommodating as possible here. | 13:52 | ||
ruoso | well... | ||
I guess you could have something like... | |||
multi infix:<->(Str $a where /^\d+$/, Int $b --> Int) { } | 13:53 | ||
pugs_svn | r26083 | jnthn++ | [t/spec] Correct and change fudging of some return type checking tests. | ||
ruoso | because that's pretty much what you want | ||
masak | ruoso: yes. but putting it like that makes it seem a little silly. | ||
ruoso: I want Perl 6 to numify to an Int if that's possible. | 13:54 | ||
jnthn | ruoso: If prefix:<+>("4") is meant to give Int, it's possible for the Any,Any case to re-dispatch. It'd give the semantics masak wants. But then it's a performance question. | ||
ruoso | rakudo: say (+"1").WHAT | 13:55 | |
p6eval | rakudo 881ed3: OUTPUT«Num» | ||
masak | ruoso: irclog.perlgeek.de/perl6/2009-02-28#i_946150 | ||
ruoso | so... | ||
masak | so... | ||
ruoso | multi prefix:<+>(Str $a where /^\d+$/--> Int) { } | ||
masak | ruoso: no, not a Str. it has already numified to an Int at that point. | 13:56 | |
I don't think extra variants of prefix:<+> are needed. | |||
ruoso | rakudo: multi prefix:<+>(Str $a where /^\d+$/--> Int) { int(+$a) }; say (+"1").WHAT | ||
p6eval | rakudo 881ed3: OUTPUT«Malformed routine definition at line 1, near "prefix:<+>"current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)» | ||
ruoso | ops | ||
13:56
Sepheebear is now known as sephee
|
|||
ruoso | masak, well.. that can be made at a lower level or at a higher level | 13:57 | |
but it looks just like a different multi variant | |||
masak | ok. | ||
whatever. | |||
as long as it DTRT. | |||
ruoso: but it's not just Str. | 13:58 | ||
in my case, it's a Match. | |||
ruoso | I guess that makes it even worse... | ||
because it's in the numification of Match, not Str | |||
actually | |||
it's the same thing | |||
masak | ruoso: well, the numification of a Match is just the numification of the stringification of that Match. | 13:59 | |
ruoso | because the Match delegates the numification to the Str containing the matched part | ||
masak | aye. | ||
but that still doesn't make that Match a Str. | |||
so dispatch will fail. | |||
jnthn | It's time for me to go and drink beer. Back later, perhaps. ;-) | ||
masak | jnthn: o/ | ||
s1n | jnthn: your fix for that macro works now | ||
ruoso | so... the question is wether conceptually there is a prefix:<+>(Str $x where /^\d+$/ --> Int) { } | 14:00 | |
masak | no. I don't see why you think the question is that. | 14:01 | |
I just want things to numify to the narrowest numerical type, and everything will solve itself. | |||
ruoso | because if the CORE API defines that prefix<+>(Str) returns a Num, the cast is necessary | ||
masak | ruoso: then I don't think it should be defined as returning a Num. | 14:02 | |
ruoso | exactly | ||
masak | either that, or Int should do Num. | ||
ruoso | rakudo: say Int ~~ Num | ||
p6eval | rakudo 881ed3: OUTPUT«1» | ||
masak | oh, good. :) | ||
problem solved? | |||
it returns an Int, which does Num. everyone's happy. | 14:03 | ||
ruoso | the CORE API just need to say that prefix:<+>(Str $x where /^\d+$/) returns Int | ||
masak, but it doesn't return Int all the time | |||
masak | right. | ||
ruoso | it only returns Int when /^\d+$/ | ||
that's why I say that "conceptually" | |||
there is another variant for prefix:<+? | |||
*prefix:<+> | |||
masak | ruoso: I still don't see why you need to specify that multi variant. | 14:04 | |
ruoso | even if that is implemented in some other way | ||
in terms of API spec | |||
if you are making strong typing | |||
you want strong typign | |||
and the types should be enforced | |||
masak | hm, fair enough. | 14:05 | |
ruoso | so you need to document when you get a narrower type | ||
masak | ruoso: your regex will need to cover integers written in other bases, too. | ||
14:05
meteorjay left
|
|||
masak | ruoso: and technically, the string need only start with a number. | 14:05 | |
ruoso | well... actually.... | ||
prefix:<+>(Str $x where <STD::int>) # or some such | 14:06 | ||
masak | nice! | ||
ruoso | hmm... | 14:08 | |
is there a way to get the match variable from a regex being used in a signature? | |||
hmm... maybe | 14:09 | ||
prefix:<+>(Str $x where /$match := <STD::int>/) | |||
std: multi foo(Str $x where /$match := <STD::int>/) { say $match } | 14:10 | ||
p6eval | std 26083: OUTPUT«##### PARSE FAILED #####Malformed multiMalformed routineUnrecognized regex metacharacter at /tmp/bhj8W7h2nt line 1:------> multi foo(Str $x where /$match := <STD::int>/) { say $match } expecting any of: quantifier regex atom rxinfix | ||
..wsFAILED 00:02 38m» | |||
moritz_ | maybe $/ is available inside the sub? | ||
ruoso | what if there is more than one regex in the signature | ||
? | |||
moritz_ | screwup :-) | 14:11 | |
ruoso | what is the correct way of doing named capture in inline regexes? | ||
std: my $foo; $foo ~~ /$named := (bla)/; | 14:12 | ||
p6eval | std 26083: OUTPUT«##### PARSE FAILED #####Unrecognized regex metacharacter at /tmp/P83i4eytm7 line 1:------> my $foo; $foo ~~ /$named := (bla)/; expecting any of: quantifier regex atom rxinfix wsOther potential difficulties: Variable $named is | ||
..not predeclared at /tmp/P83... | |||
ruoso | std: my $foo; $foo ~~ /$<named> := (bla)/; | ||
p6eval | std 26083: OUTPUT«##### PARSE FAILED #####Unrecognized regex metacharacter at /tmp/JBonKhOvhK line 1:------> my $foo; $foo ~~ /$<named> := (bla)/; expecting any of: quantifier regex atom rxinfix wsFAILED 00:02 36m» | ||
pugs_svn | r26084 | pmurias++ | [re-smop] porting over LexicalScope - needs Hash and Scalar | 14:20 | |
14:21
meteorjay joined
14:23
abra joined
14:25
diakopter joined
|
|||
masak | hm, unable to run my Druid tests. getting 'compiler returned NULL ByteCode' from Rakudo. | 14:26 | |
moritz_ | masak: with latest rakudo_ | ||
masak | moritz_: aye. | ||
moritz_ | s/_/?/ | ||
masak | also, it claims that Test.pir does not exist in my RAKUDO_DIR, when it clearly does. | ||
moritz_ | and did you reconfigure before building? | ||
masak | possibly not. doing a clean rebuild of everything. | 14:27 | |
hopefully, all my worries will go away. | |||
ruoso cook lunch & | |||
14:28
dKingston left
14:30
PerL_MonK joined
|
|||
dalek | kudo: 0bb68ee | (Geoffry Broadwell)++ | (2 files): Configure improvements [Configure] Add --parrot-opt passthrough to parrot configure [gen_parrot.pl] Pass @ARGV to Configure; exit on Configure fail; visual tweaks [Configure] Visual tweaks Signed-off-by: Moritz Lenz [email@hidden.address] |
14:31 | |
14:32
rgs left
|
|||
moritz_ | jnthn: can RT #64448 be closed? or do you want tests? (don't know if it can be tested from within Perl 6 yet) | 14:32 | |
masak | yup, problems went away. | ||
s1n | moritz_: i think you can close that one | 14:33 | |
i've been testing it all morning and i think we're hardpressed to write a test for that | |||
unless we move the test suite outside rakudo? | |||
pmichaud | good morning, #perl6 | 14:39 | |
14:39
agentzh left
|
|||
masak | hi, pmichaud | 14:39 | |
14:39
agentzh joined
|
|||
pmichaud | jnthn: I think I might have a solution for the newclosure problem. Actually, I have several solutions :-) | 14:41 | |
one of which should be good enough. | |||
diakopter | rakudo: say "'morn!" | 14:43 | |
p6eval | rakudo 881ed3: OUTPUT«'morn!» | ||
japhb | moritz_: thank you for committing my patch | 14:44 | |
diakopter | yay,/wc | 14:46 | |
14:46
diakopter left,
diakopter joined
14:49
diakopter left,
diakopter joined
14:50
davidad left
|
|||
moritz_ | japhb: you're welcome | 14:52 | |
pmichaud | I think it should be parrot-options instead of parrot-opt | 14:53 | |
moritz_ | I can change that, it's a no-brainer ;-) | ||
pmichaud | wait, there's more. | ||
14:53
Tene joined
|
|||
masak | rakudo: .say for (1..8).reverse; say "!"; say (1..8).reverse.perl | 14:54 | |
14:54
ChanServ sets mode: +o diakopter
|
|||
japhb | pmichaud: I waffled on that for a while ... basically it came down to how I would name a variable -- abbreviated only when the abbreviation is common and every programmer would know exactly what the abbreviation meant. | 14:54 | |
masak | p6eval? | ||
pmichaud | it should also be abbreviated only if frequently used. If used infrequently, it should probably be spelled out. | 14:55 | |
I don't expect the option to be frequently used. | |||
japhb | pmichaud: note that --parrot-opt sends *one* option per mention. --parrot-options implies it would send more than one. | ||
14:56
p6eval left,
p6eval joined
|
|||
pmichaud | I'm not even sure that we should have --parrot-option | 14:56 | |
moritz_ | maybe parrot-conf? | ||
14:56
abra left
|
|||
japhb | pmichaud: ... and that would be the argument that had me waffling. *I'll* use it every time; I don't know how others will use it. | 14:56 | |
moritz_ | rakudo: say "alive" | ||
p6eval | rakudo 881ed3: OUTPUT«alive» | ||
moritz_ | rakudo: .say for (1..8).reverse; say "!"; say (1..8).reverse.perl | 14:57 | |
pmichaud | I suspect that people who need custom options for parrot shouldn't be using --parrot-config | ||
japhb | moritz_: That's used to say where the parrot-conf binary is | ||
pmichaud | sorry, --parrot-opt | ||
or --gen-parrot | |||
japhb | moritz_: (Existing code) | ||
moritz_ | japhb: ok | ||
14:58
ZuLuuuuuu_ joined
|
|||
japhb | pmichaud: I have to send '--jitcapable=0' all the time. But I like having the ability to just --gen-parrot, and know I will get exactly the parrot rev you have blessed. | 14:58 | |
14:58
cognominal joined
|
|||
moritz_ | masak: .say for (1..8).reverse doesn't produce any output | 14:58 | |
masak | moritz_: indeed. | 14:59 | |
just submitted a rakudobug about it. | |||
moritz_ | "good" | ||
pmichaud | why is that a rakudo bug? | ||
14:59
ChanServ sets mode: +o diakopter
|
|||
masak | :/ | 14:59 | |
pmichaud: because it's wrong. | |||
moritz_ | pmichaud: because 1..8.reverse should produce 8..1:by(-1) | ||
masak | and now I have to make a workaround for Druid. :/ | ||
pmichaud | oh, okay. | ||
moritz_ | or a list 8, 7, 6, 5, 4, 3, 2, 1 | ||
pmichaud | since most of Range is now in setting, it ought to be possible to make that work :-) | 15:00 | |
moritz_ | rakudo: .say for (1..8).list.reverse | ||
masak | pmichaud: it used to work. | ||
I've been relying on it since December. | |||
15:00
p6eval left
|
|||
masak | moritz_: don't we have tests for that? | 15:00 | |
pmichaud | oh, then I suspect a bug in the setting code that was just added. | ||
15:00
p6eval joined
|
|||
masak | pmichaud: aye. | 15:00 | |
trying to find the commit. | |||
pmichaud | I didn't get a good chance to review it; I know there are other bugs in there. | 15:01 | |
masak | commit 2752e0e62, it seems. | ||
moritz_ | yes | ||
pmichaud | japhb: how about --gen-parrot-options="--jitcapable --prefix=somewhere --optimize" ? | ||
moritz_ | I should have reviewed more carefully, it seems | 15:02 | |
and we need better test coverage | |||
masak | strange, the .reverse method looks as though it should handle this. | ||
15:02
Psyche^ joined
|
|||
pmichaud | I suspect the error is in the from/to handling | 15:02 | |
masak | it negates .by, just as it should. | ||
anyway, now you know. | |||
masak goes back to working around | |||
japhb | pmichaud: I suppose so. Would you accept '--parrot-options' instead of '--gen-parrot-options'? | 15:03 | |
pmichaud | I'd like it to be clear that the options are going to gen-parrot | ||
as opposed to being options that we might pass when running parrot. | |||
japhb | Oh, I see your point | ||
OK, will rebase and make a new patch | |||
(to go on top of the existing one) | 15:04 | ||
masak | ah, .list.reverse works as a workaround for now. | ||
15:05
meteorjay left
|
|||
pmichaud | japhb: that would be excellent, thanks. | 15:06 | |
15:06
Tene_ left
|
|||
pmichaud | Also, do we know that every perl installation has Getopt::Long? I'm pretty sure it does, but I'm often surprised by such things. | 15:06 | |
moritz_ | pmichaud: it's in core | ||
pmichaud | okay, great. | ||
s1n | what version of core was it added? | ||
japhb | pmichaud: I checked corelist. It was in version 5.0 | ||
s1n | there you go | ||
japhb | (To be clear, I checked *before* I created the patch. ;-) | ||
pmichaud | japhb++ | 15:07 | |
moritz_ | pmichaud: would you accept Range.perl generate a Range.new(from => ..., to => ..., by => -1) for by != 1? | ||
pmichaud | moritz_: yes. | ||
15:07
nihiliad joined
|
|||
moritz_ | or should it do that in all cases, for consistentcy? | 15:07 | |
pmichaud | I'd also accept that it put the :by adverb on the end (even though we don't parse it yet) | ||
moritz_ | I can do that too | 15:08 | |
pmichaud | I think I like the Range.new approach for the moment. | ||
I don't like the given/take in Range.perl, though. | |||
we should be able to just do ('^' if $.to_exclusive) | |||
pugs_svn | r26085 | moritz++ | [t/spec] test for RT #64458, masak++ | ||
masak | moritz_++ | ||
moritz_ | pmichaud: ok, I'll improve that method now | 15:09 | |
pmichaud | say [~] 1, ('^' if 0), '..', ('^' if 1), 10 | ||
rakudo: say [~] 1, ('^' if 0), '..', ('^' if 1), 10 | |||
p6eval | rakudo 881ed3: OUTPUT«10..^10» | ||
pmichaud | oops | ||
oh, that fix didn't make it in yet. | |||
leave given/take until I can fix the ('^' if 0). | |||
(which I will do now) | 15:10 | ||
15:10
kidd` left
15:11
kidd joined
|
|||
pmichaud | +1133 passing spectests since Oslo release. Good progress this month :-) | 15:12 | |
15:14
diakopter is now known as diakopter_afk
|
|||
masak | wow. that's a lot of tests. | 15:14 | |
pmichaud | yes, and there's still ~3 weeks until the next release :-) | 15:15 | |
japhb | (rakudo team)++ | ||
15:16
justatheory joined
15:17
diakopter_afk is now known as diakopter
15:19
Patterner left,
Psyche^ is now known as Patterner
|
|||
moritz_ | pmichaud: what's your fix then? returning Nil from a not-executed if? | 15:19 | |
pmichaud | returning () | ||
moritz_ | ah, that's the same | ||
pmichaud | (empty list) | ||
S04 technically says it returns () | 15:20 | ||
moritz_ | ok | ||
pmichaud | so I'm doing that. It may be that S04 should be updated to say that it returns nil. | ||
the place it matters is with something like: | |||
my $x = (3 if 0); | |||
should $x become a Capture, or should it be Nil/Failure? | 15:21 | ||
anyway, I'm just following the spec. :-) | |||
(the written spec) | |||
moritz_ | that's fine by me | ||
pmichaud | spectesting the (1-line) fix now | 15:22 | |
moritz_ | ok, I have some changes here that depend on it ;-) | ||
pmichaud | do we have any tests for ($value if $cond) yet? | 15:23 | |
moritz_ | I don't know of any | ||
but the suite is large... :) | |||
pmichaud | rakudo: my @a = ($_ * 2 for 1..5); say @a.perl; | 15:24 | |
masak | p6eval is sick today. | 15:25 | |
15:25
p6eval left
|
|||
pmichaud | I think it might be caught in an infinite loop from (1..10).reverse | 15:25 | |
masak | why would that loop infinitely? | ||
it doesn't on my box... | |||
moritz_ | no, it showed that it wants to eval it | ||
pmichaud | because before the latest commit, Range.reverse used to do .list.reverse | 15:26 | |
masak | latest commit? is dalek sick too? | ||
pmichaud | sorry, "commit that moved Range methods from pir to setting" | 15:27 | |
masak | ah. | ||
pmichaud | cspencer's patch changed Rakudo's interpretation of Range.reverse | ||
changed it to match the spec, but also broke it. | |||
masak | aye. | ||
moritz_ | and .list is still lin PIR, it seems | ||
pmichaud | because Ranges don't know how to do negative :by yet | ||
japhb | pmichaud: Now that I'm working on the new patch, I remembered why I did only one parrot option per --parrot-opt ... because if you allow multiple, then you need to use system($string) rather than system(@list) in order to get the options to flatten -- but system($string) won't be portable if $^X contains spaces .... Do you mind if I do --gen-parrot-option (no 's') and do one option per? That way I can still do system(@list). | 15:28 | |
pmichaud | japhb: could split the string on spaces. | 15:29 | |
moritz_ | pmichaud: not so easy, for --cc="ccache gcc" | ||
japhb | pmichaud: that assumes none of the options contain spaces either ... and then to fix that you get into parsing ... | ||
pmichaud | which gets back to my point of: people with complex parrot build requirements shouldn't be using --gen-parrot. | ||
that said, I'll accept --gen-parrot-option (no 's') if that's what you prefer. | 15:31 | ||
japhb | pmichaud: --gen-parrot does two things: One, it's convenient shorthand and saves typing and brain work. Two, it tries to guarantee that parrot is in sync with Rakudo's expectations. Neither of those mean I shouldn't be able to pass down an option or two | ||
OK, thank you. | |||
pmichaud | (ranges) I'd love to implement :by, but it's really tricky. | 15:33 | |
moritz_ | hrm | ||
ranges use ++ to get to the next value | |||
which they need for string delemiters | 15:34 | ||
pmichaud | correct | ||
and it gets trickier with: 'a'..'z':by(1.5) | |||
moritz_ | so we're limited to integer :by for now, I'd say | ||
pmichaud: I think non-integer :by simply doesn't make sense for non-numbers | |||
pmichaud | this was already discussed here on #perl6 as being valid | 15:35 | |
personally I think that the spec for string ranges is a bit broken | |||
but now that I'm thinking about it, I might know an easier way to resolve it. | |||
moritz_ | more interesting... if :by is negative, should -- be used? or ++ on .to? | 15:36 | |
15:37
meteorjay joined
|
|||
pmichaud | I think that :by negative means that we decrement from | 15:38 | |
(on iteration/shift) | 15:39 | ||
my $a = 10..1:by(-1); $a.shift; say $.perl; # "9..1:by(-1)" | |||
can we restart p6eval? | 15:40 | ||
moritz_ | it seems the -1 case should be only a few lines of PIR | ||
pmichaud: I'm realcleaning and building both parrot and rakudo right now | |||
pmichaud | okay. | ||
moritz_ | pmichaud: will restart p6eval once that's done | ||
pmichaud | but here's an example that shows the difficulty of string ranges | ||
15:41
diakopter sets mode: -o diakopter
|
|||
pmichaud | oh, nm, I'll come up with it later. | 15:41 | |
anyway, I think I'll re-do Range. | 15:42 | ||
so that $.from and $.to are always numeric | |||
moritz_ | should I re-do .reverse for now to return a list, to help masak? | ||
pmichaud | yes, that would seem to work. I don't know how long it'll take to clean up Range. | 15:43 | |
masak | I'm fine, I have a workaround. :) | ||
pmichaud | so, whatever you two decide :) | ||
15:43
ChanServ sets mode: +o diakopter
|
|||
masak | my Druid tests just caught a mistake I made in a refactoring. life is good. | 15:44 | |
moritz_ | tests++ | ||
masak | they rock. | 15:45 | |
15:45
xinming joined
15:46
p6eval joined
|
|||
moritz_ | rakudo: say "back" | 15:46 | |
p6eval | rakudo 0bb68e: OUTPUT«back» | ||
pugs_svn | r26086 | moritz++ | [evalbot] warn if unlink of temp file failed | 15:48 | |
15:48
smtms joined
|
|||
pugs_svn | r26087 | pmichaud++ | [t/spec]: Unfudge + clean up tests of ($value if answer) statement modifier | 15:49 | |
moritz_ | so we did have such tests. Impressing :) | 15:50 | |
pmichaud | well, two. | ||
15:50
grawity joined
|
|||
moritz_ | that's less impressing ;-) | 15:50 | |
pugs_svn | r26088 | pmichaud++ | [t/spec]: Add tests for ($value unless $answer) statement modifier. | 15:52 | |
pmichaud | arggggh.... fixing ($value if $answer) causes Range.perl to _break_ | 15:53 | |
moritz_ | pmichaud: never mind, I have a modified Range.perl here that relies on your fix :) | ||
pmichaud | I think that might break also. | ||
I went through this exercise on Thursday | |||
I thought the problem might be something else... but apparently it's not. | |||
moritz_ | should I nopaste my changes for you to try? | 15:54 | |
pmichaud | yes, that would save me recreating them :-) | ||
moritz_ | I'll email them if that's ok, that's easier for me right now | 15:55 | |
pmichaud | that's fine, yes. | ||
ohhhhhhhhhh CRAP | |||
moritz_ | pmichaud: sent | 15:56 | |
pmichaud | it's okay, I know where the problem lies. | ||
15:56
davidad joined
|
|||
pugs_svn | r26089 | moritz++ | [t/spec] test ($expresion if $condition) in scalar context | 15:57 | |
15:58
meteorjay left
|
|||
masak discovers that proto does not build Druid properly | 16:02 | ||
I see what the problem is, but I'm too tired to think up a solution. | |||
pmichaud | okay, one more round of spectests, then I can push this commit. | 16:04 | |
16:04
|jedai| joined,
grawity left
16:06
ZuLuuuuuu_ left
16:07
|jedai| is now known as jedai
|
|||
japhb | hacking is *so* much slower when the kids are awake and not watching TV ... | 16:11 | |
pmichaud: new patch sent to rakudobug | |||
pmichaud | japhb: looking | ||
moritz_ | rt.perl.org/rt3/Ticket/Display.html?id=64460 | 16:12 | |
pmichaud | I'll let moritz++ apply if he's ready for that :-) | ||
I'm in the middle of spectesting. | |||
moritz_ | ok | ||
japhb | I hate how RT smashes indents ... | 16:13 | |
moritz_ | + my @opts = @{ $options{'gen-parrot-option'} || {} }; | ||
shouldn't that be || [] ? | |||
japhb | moritz_: OH HELL | ||
yes | |||
sorry | |||
pmichaud | moritz++ # I would probably not have noticed that. | ||
japhb | I tested with 1 option, and multiple options, but of course not 0. Because I'm an idiot today. | ||
sigh, thanks moritz_++ | |||
moritz_ | japhb: if you send your patches with git-format-patch HEAD^ I don't have to add the authorship information manually (for the next time ;) | 16:14 | |
japhb | That's what I did ... | 16:15 | |
16:15
Khisanth joined
|
|||
japhb wonders why it didn't work right | 16:15 | ||
moritz_ | when I do it, I get a From: $author | ||
in the second line | |||
and date etc. | |||
pmichaud | maybe older version of git? | 16:16 | |
japhb | Mine is fairly new: git version 1.6.2.1 | ||
Perhaps because I sent with git send-email, and it didn't DTRT? | |||
moritz_ | ah, that's it | 16:17 | |
git-format-patch adds email headers | |||
and rt swallows them | |||
japhb | rt-- | ||
I guess then use git-format-patch, but then attach to manually-created email instead of git send-email ... | 16:18 | ||
16:19
davidad left
|
|||
moritz_ | that'll be easier for us | 16:19 | |
pmichaud | I'm open to creating a (Perl 5) script that automates patch submission, if anyone's interested. | 16:20 | |
moritz_ | good idea | 16:21 | |
japhb | moritz_: fair enough. I'm still just trying to figure out how to best contribute, so when I have something bigger than just Configure patches, it will be smoother. | ||
pmichaud | japhb: we're all still trying to figure that out, I think. | ||
japhb | pmichaud: fair enough. :-) | ||
pmichaud | so your contributions here are particularly valuable :-) | 16:22 | |
16:22
sephee left
|
|||
moritz_ | ok, patch applied locally; I'll push it when pmichaud's changes went in, because I have other local changes as well that depend on it | 16:23 | |
japhb | heh | ||
moritz_ | I could move them to a branch and rebase, but that seems too much hassle | 16:24 | |
japhb | OK, sent | ||
moritz_: er ... my patch? Or a different one? | 16:25 | ||
moritz_ | japhb: yours | ||
japhb | I just amend'ed and resent the corrected patch, so of course I think I messed with you. | ||
masak | it's almost possible to pick the Perl 6 track for all of NPW. | 16:26 | |
japhb | nice | ||
masak | people interested in Rakudo will have something to look forward to. | ||
16:27
davidad joined
|
|||
pmichaud | I hope there are some. :-) | 16:28 | |
so far the list of "people attending talk" was pretty small when I looked on Thu. | 16:29 | ||
that said, I don't mind performing to an empty house :-) | |||
(I much prefer a full house, but I'll perform to a nearly empty one) | |||
moritz_ | ok, here's my idea for the create-patch script: | ||
1) if we're on branch master, just do a git-format-patch HEAD^ | 16:30 | ||
2) if we're on a different branch, squash all changes from the current branch into master, and git-format-patch that commit | |||
(and for the second option require a commit message, because the "squashed commit of..." isn't all that informative) | 16:31 | ||
does that sound sane? | |||
pmichaud | sounds good to me. | ||
japhb | moritz_: kinda feels a little limiting, but let's see how it works out ... not like we can't change it later. :-) | 16:32 | |
moritz_ | japhb: if you don't want the limits, you use git directly | ||
japhb: but not everybody is all that comfortable with that | |||
japhb | moritz_: I guess I had something simpler in mind: | ||
1) git-format-patch -1 | 16:33 | ||
2) create email, attach patch, send to rakudobug | |||
Squash management, was, in my mind, outside the scope | |||
pmichaud | I think squashing could be helpfu. | 16:34 | |
*helpful | |||
but I'll let the person writing the script decide :-) | |||
moritz_ | we can have both ;-) | ||
japhb | pmichaud: no argument at all ... but maybe just have a "--no-squash" option? It's possible I might be on a branch, but not want to merge back to master before sending the patch | ||
moritz_ | yes, squashing should be optional | 16:35 | |
how should it send the mail? with Mime::Lite? | 16:36 | ||
pmichaud | or have a --squash option | ||
japhb | moritz_: that's a decent one, but are there any that were in core? | ||
moritz_ | japhb: don't think so | 16:37 | |
pmichaud | if there's not a good one in core, I'm willing to take one from CPAN | ||
japhb | pmichaud: agreed | ||
moritz_ | corelist /mail/ doens't find any | ||
japhb forgot about that regex option | 16:38 | ||
masak | rakudo: regex foo_bar { foobar }; say "foobar" ~~ /<foo_bar>/ | 16:41 | |
p6eval | rakudo 0bb68e: OUTPUT«foobar» | ||
masak | rakudo: regex foo-bar { foobar }; say "foobar" ~~ /<foo-bar> | ||
p6eval | rakudo 0bb68e: OUTPUT«Statement not terminated properly at line 1, near "~~ /<foo-b"current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)» | ||
moritz_ wants a MAIN sub for Perl 5, and sub names with hyphens | |||
masak | pmichaud: can I report this to rakudobug? | ||
pmichaud | masak: no, because it's not a bug :-) | ||
masak | I thought it best to ask for exactly this reason. :) | 16:42 | |
pmichaud | or you can report it, but I'll respond with a message to p6l saying "wtf?" | ||
masak | :) | ||
moritz_ | it's ambiguous in the sepc, I think | ||
pmichaud | agreed. | ||
moritz_ | maybe we need a wtf mail | ||
masak | ok, let's do it that way. | ||
masak submits rakudobug | |||
moritz_ | for example char classes could require whitespaces | ||
around the - | 16:43 | ||
pmichaud | oh | ||
moritz_ | std: /<foo-bar>/ | ||
pmichaud | S05 beats us to it. | ||
p6eval | std 26089: OUTPUT«ok 00:03 35m» | ||
pmichaud | However, in order to combine classes you must prefix a named | ||
character class with C<+> or C<->. Whitespace is required before | |||
any C<-> that would be misparsed as an identifier extender. | |||
moritz_ | wow | ||
TimToady++ | |||
japhb | rakudo: regex foo-bar { foobar }; say "foobar" ~~ /<foo-bar>/ | ||
pmichaud | okay, it's a rakudobug, and I don't have to ask p6l whazzup | ||
p6eval | rakudo 0bb68e: OUTPUT«Statement not terminated properly at line 1, near "~~ /<foo-b"current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)» | ||
japhb | Interesting ... gives the same error with or without trailing / | 16:44 | |
pmichaud | I just have to fix PGE to recognize perl6's new identifier | ||
it's because PGE wants <+foo-bar> | |||
without that, it can't recognize <foo-bar> as being anything usable | |||
so the pattern fails, so the smart match fails, so... | 16:45 | ||
okay, ($value if $answer) pushed. | 16:47 | ||
(_finally_) | |||
masak | rakudo: regex foo'bar { foobar }; say "foobar" ~~ /<foo'bar>/ | ||
moritz_ | that serial testing is slow :( | ||
p6eval | rakudo 0bb68e: OUTPUT«Statement not terminated properly at line 1, near "~~ /<foo'b"current instr.: 'parrot;PGE;Util;die' pc 129 (runtime/parrot/library/PGE/Util.pir:83)» | ||
masak | make sure you get that case too. :) | ||
moritz_ | however redoing it in parallel requires another perl module to be present | ||
(parrot shipped with a Test::Harness 3.something iirc) | 16:48 | ||
dalek | kudo: a06d768 | pmichaud++ | src/ (2 files): Add ($value if $cond) semantics for if/unless modifiers. |
||
masak pulls and heads home to bake bread | |||
16:52
grawity joined
16:53
grawity left
16:54
dKingston joined
16:55
sephee joined
16:56
sephee left,
sephee joined
16:58
masak left
|
|||
moritz_ | cool, prototype of patch sending script works ;-) | 17:01 | |
ruoso .oO( ohloh is a really cool thing to mention in a CV... it now measures 4 years experience of Perl, by the Open Source contributions I've made... ) | 17:06 | ||
eiro | hello wolrd | ||
moritz_ | sadly ohloh tracs the openfoundry pugs repository | 17:07 | |
which doesn't show the commits of the last ~2 years | |||
ruoso | ah,,, | ||
is it? | |||
moritz_, nops... it uses svn.pugscode.org | 17:08 | ||
it's just ohloh that is behind in the project updats | |||
pmichaud | afk, lunch | 17:11 | |
ruoso | the cool thing is looking at pugs repo and seeing it say that pugs is with 19.5M dollars ;) | 17:13 | |
s/with/worth/ | |||
pmurias, do you think we still need the GlobalInterpreter? | 17:21 | ||
I was thinking we could get rid of it... | |||
by passing the interpreter to the initializers that require one | 17:22 | ||
what do you think? | |||
pmurias | ruoso: i think we can get rid of it | 17:25 | |
ruoso | cool | ||
I think we're pretty close to finish the refactoring aren't we? | |||
(I should say you, since you're doing it almost alone ;) | 17:26 | ||
work-- | |||
pmurias | scalar,hash,code and IO and re-mildew will be able to run code on re-smop | ||
ruoso | :) | 17:27 | |
17:30
kane_ left
17:32
payload joined
|
|||
pmurias | bbl& | 17:32 | |
17:32
pmurias left
|
|||
ruoso | @tell pmurias one other thing I'd like to have in this refactoring is cleaning up the CORE namespace, putting it all inside a SMOP package, so we can hide it later... | 17:33 | |
lambdabot | Consider it noted. | ||
dalek | kudo: db0dd4f | (Geoffry Broadwell)++ | Configure.pl: [Configure] change option name to --gen-parrot-option. Signed-off-by: Moritz Lenz [email@hidden.address] |
17:37 | |
kudo: 2fb96f8 | (Moritz Lenz)++ | src/setting/Range.pm: Range.reverse returns a list for now, because :by(-1) is NYI |
|||
kudo: 105ec22 | (Moritz Lenz)++ | src/setting/Range.pm: better Range.perl |
|||
moritz_ | ruoso: ok, then it's updated... last time I checked (perhaps 2 months ago) they used the old one, and I sent them a mail | ||
17:40
TimToady joined
|
|||
japhb wonders why my name keeps getting mangled | 17:42 | ||
(in the commit messages | |||
Hmmm 'git config user.name' is correct ... | 17:50 | ||
moritz, is my name missing the 'e' between the r and y in the patch headers? | 17:51 | ||
17:51
|jedai| joined
17:52
justatheory left,
ChanServ sets mode: +o TimToady
17:54
Psyche^ joined
17:55
jedai left,
|jedai| is now known as jedai
17:59
amoc joined
18:05
Patterner left,
Psyche^ is now known as Patterner
18:15
NordQ joined
|
|||
s1n | pmichaud: still going to give a talk to dallas.p6m? | 18:18 | |
pmichaud | s1n: sure, I can do that sometime. Haven't scheduled it yet. | 18:24 | |
pmichaud sits outside on the back porch and enjoys the incredibly beautiful weather we're having here. | 18:27 | ||
18:27
jferrero joined
|
|||
TimToady | yes, am admiring the weather in Houston on the telly. I suspected there was a golf tournament in Houston cuz I saw a blimp when we stopped there yesterday, and confirmed when I got home :) | 18:28 | |
well, it's nearer Humble, really | 18:29 | ||
s1n | yes, today's weather greatly improved | ||
pmichaud | wb, TimToady. Trip went well? | ||
TimToady | yes, all five talks went pretty well | 18:30 | |
pmichaud | I greatly enjoyed your MIT talk :-) | ||
TimToady | though the one at Bloomberg was very nip-and-tuck | ||
actually started a minute or two late because we had to run a video cable to another room | |||
their "video wall" didn't like my laptops output, or vice versa | 18:31 | ||
s/ps/p's/ | |||
anything hanging fire that I haven't noticed in my brief dips in the cyberstream? | 18:32 | ||
besides junctions, of course... :) | |||
pmichaud | I've got a lot of posts to make with questions... but nothing urgent. | 18:33 | |
Your answer about threading over 1 < $x < 3 caught me by surprise. | |||
TimToady | that's how I've been thinking of it, don't know how hard it is to implement that way though | ||
gravity | Is the MIT talk online somewhere? | 18:34 | |
pmichaud | I think it may end up being slightly easier. | ||
TimToady | and maybe not general enough, given some of the other speculations | ||
but maybe for 6.0 we'll just do something conservative | |||
pmichaud | anyway, I'm letting it percolate in the background. Currently we have to do some special stuff in PCT in order to get chained expressions to work at all -- fixing the threading to be like what you imagine might also eliminate some of those. | ||
s1n | TimToady: is the Spec (documentation) supposed to display sanely with perl5's perldoc tool? | 18:37 | |
TimToady | the specs are some unhappy hybrid of p5 and p6 pod, I suspect | 18:41 | |
groceries & | |||
pugs_svn | r26090 | s1n++ | [spec] minor touch-ups to better format the pod for perl5's perldoc tool. | 18:45 | |
s1n | moritz_: are you aware of any tests for reading $*IN? | ||
18:49
dduncan joined
|
|||
pmichaud | TimToady: Oh, I could use some guidance on my "Deciphering infix:<cmp>" message to p6l (sent 2009-03-26) | 18:49 | |
I suspect I can clean up quite a few things in Rakudo with an answer to that one. | 18:50 | ||
19:04
dKingston left,
dKingston joined
19:11
rindolf joined
|
|||
rindolf | Hi all. | 19:11 | |
pmichaud | Range.pir:56 : + 'from_exlcusive => ' ~ $.to_exclusive.perl, | 19:12 | |
looks like a couple of typos there. | |||
pmichaud fixes. | 19:13 | ||
s1n | pmichaud: when are we getting together again? | 19:15 | |
pmichaud | oh, my schedule is opening up again for a week or so. Feb and Mar were really hectic because of so many non-perl related events for me. | 19:16 | |
(mainly having to do with family stuff) | |||
But I depart for Oslo a week from Tuesday. | |||
s1n | i'm in between work in school right now | 19:17 | |
just about to start up new assignments, this week is good for me | |||
pmichaud | My wife is away this weekend so I don't know what our plans are for the week. We could tentatively pick and evening and get together (also with frioux if desired). | 19:18 | |
s1n | i have time this weekend if you really want | 19:19 | |
i haven't been able to get ahold of frioux for most of this week | |||
19:19
PhatEddy joined
|
|||
pmichaud | I have to stick around the house to watch kids until at least tomorrow afternoon. | 19:21 | |
19:29
justatheory joined
|
|||
PhatEddy | rakudo: my Bool $a; say 3 cmp $a | 19:29 | |
p6eval | rakudo db0dd4: OUTPUT«Use of protoobject as value1» | ||
PhatEddy | rakudo: my Bool $a; say $a cmp 3 | ||
p6eval | rakudo db0dd4: OUTPUT«-1» | ||
pmichaud | why would one compare a Bool there? | 19:30 | |
PhatEddy | rakudo: my Bool $a; say 3 cmp +$a | ||
p6eval | rakudo db0dd4: OUTPUT«Use of protoobject as value1» | ||
PhatEddy | It isn't a great use but I am not sure why not?? | ||
pmichaud | fair enough. :-) | 19:31 | |
PhatEddy | Note that the example above may or may not be connected to parrot tt - 285 - | 19:33 | |
rakudo: say undef cmp 3 | |||
p6eval | rakudo db0dd4: OUTPUT«Multiple Dispatch: No suitable candidate found for 'cmp', with signature 'PP->I'current instr.: 'infix:cmp' pc 15341 (src/builtins/cmp.pir:146)» | ||
PhatEddy | rakudo: say 3 cmp undef | ||
p6eval | rakudo db0dd4: OUTPUT«Use of uninitialized value1» | ||
19:34
PZt left
|
|||
pmichaud | I can't speak for parrot's desired semantics, but it's likely to be irrelevant soon in Rakudo's case. | 19:36 | |
(because Rakudo's infix:<cmp> won't be using Parrot's 'cmp' opcode. | |||
(at least, not generically as it does now) | 19:37 | ||
19:38
jedai left
|
|||
PhatEddy | If I don't see another matching rt ticket then I might put up a p6 one for non-cumutative cmp error behavior. | 19:39 | |
pmichaud | I think there's already a ticket for that? | ||
19:41
|jedai| joined
|
|||
PhatEddy | I don't see anything under cmp or commutative for p6 but will take another look ... | 19:43 | |
pmichaud | guess not. | 19:45 | |
(I don't see it either.) | |||
PhatEddy | found it I think - rt <a href="rt.perl.org/rt3/Public/Bug/Display....</a> - it's just been too long since I worked on it ... | 19:50 | |
pmichaud | ah, yes, that's likely to be an interesting case as well. | 20:02 | |
I've got a message open to p6l asking about the semantics of infix:<cmp> (and thus min) -- we may need to see how that comes out first. | 20:03 | ||
TimToady | seems like cmp should be commutative, whatever it does | ||
been thinking about cmp | |||
I think for different types we want it to default to something dwimmy as long as consistency can be maintained | |||
pmichaud | there's also the case of 3 cmp undef (as PhatEddy++ notes above) | 20:04 | |
TimToady | trick is not getting into a situation where three types do A < B < C < A | ||
if the default is something like coerce to Str and then cmp, then we get a warning on undefs | 20:05 | ||
though we might get a *lot* of warnings... | |||
pmichaud | I don't know that I have an issue with that :-) | ||
but something like 3 min undef may also be related | |||
my Int $a; say 3 min $a; # ??? | |||
TimToady | 0 and a warning, if we stick with p5 semantics... | 20:07 | |
but something to be said for sticky undefs on that sort of thing | 20:08 | ||
pmichaud | and also we have that [min]() == +Inf | ||
TimToady | yes | ||
so that's grep out undefs semantics | |||
which doesn't help with cmp | 20:09 | ||
since you don't know which way to bias it | |||
pmichaud | and since min is (currently) defined with cmp as a default... things get weird. | 20:10 | |
20:10
lambdabot joined
|
|||
pmichaud | at least, I think it is. | 20:10 | |
oh, that's .min | |||
20:10
payload left
|
|||
pmichaud | instead of infix:<min> | 20:10 | |
20:11
payload joined
20:15
pmurias joined
|
|||
pmurias | ruoso:re SMOP namespace, i don't think it's nessesary we can overwrite the entries in the CORE:: namespace once we have better variants | 20:19 | |
20:21
rindolf left
20:25
sri_kraih_ joined
20:26
ZuLuuuuuu joined
|
|||
pugs_svn | r26091 | moritz++ | [t/spec] more tests for Range.reverse | 20:31 | |
r26092 | moritz++ | [t/spec] unfudge a passing TODO test for rakudo | 20:34 | ||
pmichaud | back in 20 # waiting spectest run to finish | 20:35 | |
moritz_ | japhb: no, I mis-spelled your name when I applied to first version of the patch, sorry | ||
20:36
NordQ left
|
|||
ruoso | pmurias, my point is that some names doesn't belong to the CORE namespace at all | 20:37 | |
20:41
sri_kraih left
|
|||
pmurias | ruoso: you mean like AdhocSignature? | 20:46 | |
ruoso | yeah... and some other things | 20:47 | |
20:49
davidad left
20:50
M_o_C left
20:57
M_o_C joined
20:59
ejs joined
|
|||
dalek | kudo: 5942053 | pmichaud++ | src/parser/actions.pm: Change 'newclosure' to 'clone' in create_parametic_role, All tests still pass. |
21:06 | |
kudo: e0cf1ed | pmichaud++ | src/ (2 files): Move 'create_parameterized_role' from a macro to a subroutine in guts.pir. |
|||
kudo: 0310a36 | pmichaud++ | src/setting/Range.pm: Fix typos in Range.perl() . |
|||
s1n | pmichaud: ping | 21:15 | |
21:17
ejs1 joined
21:19
ZuLuuuuuu left,
dKingston left
21:22
dKingston joined
21:25
orafu joined
|
|||
jnthn looks through the huge backscroll to see who mentioned him | 21:26 | ||
pmichaud: I assume your patch moving the parametric role creation works. though I am curious to know why... :-| | 21:28 | ||
OTOH, after 3 liters of beer maybe tell me tomorrow. ;-) | 21:29 | ||
pmichaud | it works. | ||
jnthn | OK, if it passes all the spectests it's *prorably* ok. | ||
21:29
ejs left
|
|||
jnthn | The point is that the roles end up with their methods having the correct outers. | 21:29 | |
pmichaud | if using newclosure on a Sub that has already had capture_lex performed on it (as all PCT blocks do), then only a clone is needed. | ||
jnthn | Oh! | ||
OK, yes, you're right. | 21:30 | ||
pmichaud++ | |||
21:30
FurnaceBoy joined
|
|||
jnthn | Thanks for spotting that. | 21:30 | |
You eliminated pr_macros.pir as a result? | |||
(If not, it's an easy patch to do so. OTOH, maybe you needn't.) | |||
pmichaud | oh, I didn't take it out of the repo yet.. meant to do it but was sidetracked waiting for spectest run to finish. | ||
I'll do that now. | |||
moritz_ | s1n: (re tests for $*IN) no :/ | 21:31 | |
jnthn | pmichaud: Or now you've shown the way, feel free to leave it to me. | ||
pmichaud | oh, I was also thinking of making a dependency for Makefile -- this might be a good time to do that also. | ||
jnthn | OK. If it's easy enough for you to do it, then feel free to JFDI. :-) | 21:32 | |
pmichaud | I just need a way to force a failure when attempting to build the Makefile | ||
moritz_ pushed a branch named mail-patch to github | |||
jnthn | rakudo: sub foo($x) returns Int { return $x ?? 42 !! "fails it" }; foo(1); foo(0); | ||
p6eval | rakudo 0310a3: OUTPUT«Type check failed on return valuecurrent instr.: 'die' pc 15853 (src/builtins/control.pir:204)» | ||
moritz_ | my new script for sending git pathes by mail is in there | 21:33 | |
it's still fairly simplistic, and for now sends patches to me, to not spam the RT queue with test mails :-) | |||
jnthn | rakudo: sub foo($x) returns Int { return $x ?? 42 !! "fails it" }; say foo(1); say foo(0); | ||
pmichaud | DCONWAY is giving a Perl 6 tutorial at OSCON. | ||
p6eval | rakudo 0310a3: OUTPUT«42Type check failed on return valuecurrent instr.: 'die' pc 15853 (src/builtins/control.pir:204)» | ||
pmichaud makes plans to go. | |||
jnthn can't afford the flights | |||
...and was slightly overwheled by the size of OSCON. | 21:34 | ||
pmichaud | flights looked reasonably cheap this year | ||
jnthn | pmichaud: Note the above works. However... | ||
pmichaud | jnthn: will you be at YAPC::EU ? | ||
jnthn | rakudo: sub foo($x) returns Int { $x ?? 42 !! "fails it" }; say foo(1); say foo(0); | ||
p6eval | rakudo 0310a3: OUTPUT«42fails it» | ||
jnthn | pmichaud: of course! ;-) | ||
moritz_ wonders how dconway can keep up with all the Perl 6 changes but not find any time to work on pod6 | |||
pmichaud | okay, I'm still trying to make arrangements to be there. | ||
jnthn | pmichaud: Any suggestions for making the implicit return be assigned to exception and doing a goto? | 21:35 | |
pmichaud: I couldn't see a neat way. :-| | |||
pmichaud | moritz_: easy -- he's keeping up with the Perl 6 changes, leaving no time to work on pod6 | ||
jnthn | YAPC::EU - yes, would be good. | ||
moritz_ | pmichaud: ;) | ||
pmichaud | jnthn: I've been thinking that iwbni the implicit return fell through to the other code somehow. No, I don't have a quick answer for it. | 21:36 | |
but I haven't thought about it much yet. There's undobutedly a clean answer. | |||
jnthn | OK. | ||
At least that makes me think I didn't miss something really obvious. | |||
It's not quite fall-through. | |||
pmichaud | we have to do something dealing with implicit return anyway. | 21:37 | |
jnthn | Because the return val is expected to be in exception. | ||
Aye. | |||
pmichaud | because the semantics are slightly different from p5 (and from what PCT currently implements) | ||
jnthn | Well, not just for what I did now, but also for C<as>. | ||
pmichaud | we can always have the exception "fall through" to whatever the normal return code needs to be. | 21:38 | |
and refactor the common stuff there. | |||
jnthn | True. | 21:39 | |
pmichaud | it's very likely all part of the LEAVE "block" | ||
jnthn | Perhaps. | ||
s1n | rakudo: my @t = <hello world>; say "fail: @t[0]" | ||
p6eval | rakudo 0310a3: OUTPUT«fail: @t[0]» | ||
pmichaud | (which might not be a true block) | ||
s1n | no interpolation yet? | ||
jnthn | no | ||
moritz_ | not of hash/array items | ||
pmichaud | we have interpolation, just not of things ending in postcircumfix. | ||
jnthn | pmichaud: I'm open to whatever solution you think is best there. | 21:40 | |
s1n | oooh | ||
pmichaud | rakudo: my @t = <hello world>; say "fail {@t[0]}"; | ||
p6eval | rakudo 0310a3: OUTPUT«fail hello» | ||
jnthn | pmichaud: However, scheduling wise, I am trying to get my current grant polished off in the next week. | ||
pmichaud | I don't have any immediate suggestions. If it can't wait for NPW, you may just need to hack something in for now then. | 21:41 | |
I _really_ need to get farther along on my grant. | |||
jnthn | pmichaud: Sure, I know. | ||
pmichaud: My scheme was more, apply for a small grant, complete it and immediately submit for the next one along with filing a final report. | |||
21:42
pmurias left
|
|||
pmichaud | well, that was mine too... but I'm having to monitor other changes and do tasks that weren't explicitly listed in my grant :0( | 21:42 | |
jnthn | Ideally, I'll submit my next grant application before NPW. | ||
pmichaud | so my grant keeps getting starved a bit. | ||
jnthn | Yes, I don't at all envy you that task. It's pretty much a grant in itself. :-( | ||
pmichaud | well, I kinda folded those things into my existing grant, but they aren't cashable milestones. | 21:43 | |
i.e., it's hard for me to say "yes, I did those things, pay me." | |||
jnthn | I guess me throwing so much stuff into Rakudo has both helped and not helped in that sense. | ||
Well, we have the Perl 6 prelude now at least... | 21:44 | ||
pmichaud | anyway, my guess would be that we really ought to get some clarification from TimToady on his expectations for leave (exception? not an exception?) and that will guide us as to handle the other stuff. | ||
jnthn | Aye. | ||
pmichaud | I'd like to have my first milestone report in prior to NPW, myself. | ||
21:45
PhatEddy left
|
|||
jnthn | I plan to get typed arrays and hashes in place somewhat next week. | 21:45 | |
s1n | rakudo: class Foo { has %.bar = ('some', 1) } | ||
p6eval | rakudo 0310a3: ( no output ) | ||
s1n | damnit, i'm getting nonexistant sub some | 21:46 | |
jnthn | I am *very* close then to things like multi a(Int &x) { }; multi a(Str &x) { }; working. I believe. | ||
And stick whatever sigil in there you want. | |||
& or % and @ | |||
pmichaud | that will be very helpful. | 21:47 | |
jnthn | It falls out pretty neatly of the parametric roles stuff I already did. | ||
s/of/from/ | |||
pmichaud | for all of the review/extra stuff your work may have given me (some, but not overly so), I'm _really_ glad to have your work in Rakudo now. We absolutely need it, and this has been the right time for it. | ||
21:48
ejs1 left
|
|||
jnthn | You have the both good and bad role of pumpking. :-) | 21:48 | |
pmichaud | indeed, it goes with the job. As long as people aren't too frustrated by how I'm handling things then I'm okay with it. :-) | 21:49 | |
jnthn | Oh, I'm most certainly glad to have someone with a bunch more experience than I have looking at what I'm doing. :-) | ||
pmichaud | (and yes, I know there's some frustration... but I don't always know how to avoid it) | ||
okay, back patio is getting too warm... time to go back inside the house... bbiab | |||
jnthn | Heh. Today was the first day this year here in Blava where it's been warm enough to sit outside in a t-shirt to enjoy a few beers. :-) | 21:50 | |
A balcony is the one thing my otherwise awesome appartment is missing that would make it completely perfect. | 21:51 | ||
21:52
xinming left
|
|||
s1n | rakudo: class Foo { has %.bar = ("some", 1) }; my Foo $f; $f.bar<some>.say | 21:53 | |
p6eval | rakudo 0310a3: OUTPUT«Method 'postcircumfix:{ }' not found for invocant of class 'Failure'current instr.: 'postcircumfix:{ }' pc 5354 (src/classes/Associative.pir:107)» | ||
s1n | what's wrong with that code? | 21:54 | |
jnthn | hmm | ||
s1n | if i do a 'my $f = Foo.new', it works | 21:55 | |
jnthn | rakudo: class Foo { has %.bar = ("some", 1) }; my Foo $f; Foo.new; | ||
p6eval | rakudo 0310a3: ( no output ) | ||
jnthn | s1n: Oh. | ||
Yeah | |||
Of course. | |||
s1n | .new isn't automatically called? | ||
jnthn | No. The proto-object is a "empty instance". | ||
Doens't let you access attributes. | |||
s1n | why isn't an undef error then? | ||
should it not be a parsefail? | 21:56 | ||
jnthn | no | ||
not a parse fail, it'd be runtime I expect | |||
It's fine to call a method that doesn't access sate | |||
s1n | man, that took me several hours to reproduce | ||
jnthn | (OK, maybe we can statically detect that one does...) | ||
s1n | should i file a bug on that? | 21:57 | |
pmichaud | rakudo: class Foo { has %.bar = ('some', 1) }; my Foo $f .= new; $f.bar<some>.say; | ||
jnthn | Only to the degree that we want a better error on accessing attributes in a proto. | ||
p6eval | rakudo 0310a3: OUTPUT«1» | ||
pmichaud | looks like it's correct to me. | ||
jnthn | pmichaud: Rakudo is correct, though I think it'd be nice if trying to access an attribute on a proto-object gave you something more helpful. | 21:58 | |
pmichaud | that sounds tricky-ish. | ||
s1n | well, i was looking at a parsefail for a few hours that should have been an undef runtime error (imho), and it took me forever to create that test case as to it's cause | ||
jnthn | s1n: The error tells you it's an undef... :-) | 21:59 | |
(Failure) | |||
pmichaud | "invocant of class 'Failure'" means it's an undef. There is no Undef type. | ||
jnthn | pmichaud: Well, my thought was do it in the getattribute vtable method for proto-object. | ||
pmichaud: However, that got in the way of something else, IIRC. I never had time to track down what/why. | 22:00 | ||
s1n | i'm suggesting the error (ugly parrot errors) just be cleaned up if possible | ||
pmichaud | I suspect that proto-objects might still have attributes :-) | ||
s1n: I'm happy to clean them up if we can (1) clearly detect the error and (2) have better text to give. It's not always possible to do those at the moment. | |||
jnthn | s1n: Actually, the "Parrot error" is pretty accurate... | ||
pmichaud | but filing tickets about confusing error messages is perfectly okay. | 22:01 | |
(we might say "there's not much we can do about it yet", but at least we'll have a record of them.) | |||
(and can create FAQ items that explain them better) | |||
s1n | alright, it was highly unintuitive to me what the cause was | ||
jnthn | s1n: Though I agree it can be improved since doing stuff like that on a proto-object is potentially a common mistake. | ||
s1n | the fact that you can't fix it yet is okay, but it really didn't help me any | ||
pmichaud | I suspect part of the problem was not recognizing that my Foo $f; doesn't create an instance of Foo. | ||
jnthn | *nod* | 22:02 | |
s1n | is it supposed to create an instance of Foo? | ||
pmichaud | no. | ||
jnthn | No | ||
pmichaud | but if you expect it to do so, then you get confusing errors. | ||
s1n | i kinda expected it too | ||
jnthn | And to be honest, it hadn't ever occured to me that it would. But that may be my background in other languages with types. | ||
s1n | (too much c++) | ||
pmichaud | my Foo $f simply says that $f is constrained to only hold objects of type Foo. | ||
jnthn | Well, also it sets the initial undef value of $f. | ||
pmichaud | jnthn: yes, in C/C++ saying Foo f; creates an instance of Foo | ||
jnthn | pmichaud: Really?! | 22:03 | |
s1n | my $f is Foo; seems cleaner and more logical to me | ||
pmichaud | I think it's really my $f of Foo; | ||
s1n | jnthn: yes, the compiler will provide a default constructor :) | ||
pmichaud | my $f is Foo would be something different. | ||
jnthn | Wow. | ||
OK, I didn't ever do C++ (yet). | |||
pmichaud | jnthn: it's little different from saying struct Foo f; | ||
(which creates the struct) | 22:04 | ||
jnthn | C# and Java both make it creating an instance of the object surprising to me. | ||
s1n | pmichaud: in c++, they're the same semantics :) | ||
jnthn | Ah, yes, true. | ||
OK, then I see it somewhat. | |||
pmichaud | s1n: Yes, I know -- I've been writing C++ since it was known as "cfront" :-) | ||
s1n | pmichaud: i still manage cfront code :) | ||
pmichaud | now _that's_ a bit scary :-) | 22:05 | |
s1n | yes, yes it is | ||
jnthn | .oO( Was I born then? ) |
||
pmichaud | jnthn: I was using cfront in 1986. | ||
s1n | i cower in fear when i have to interact with Rogue Wave | ||
jnthn | pmichaud: OK, so I was like, a year old. | ||
pmichaud: I wasn't programming at that age. ;-) | |||
s1n | pmichaud: we have cfront that was in use 2 years ago hah!! | ||
s/in use/newly created/ | 22:06 | ||
PerL_MonK | s1n think about your Foo as not being able to be called as my Foo $f(1,2,3); | ||
default constructor upon class definition would need something like that | 22:07 | ||
pmichaud | canonical mechanism is my Foo $f .= new(...args...); | ||
PerL_MonK | object rather | ||
pmichaud | if no args, then my Foo $f .= new; | ||
PerL_MonK | in Perl6 maybe, which doesnt seem natural really :) | 22:08 | |
s1n | pmichaud: yeah, that cleared up like 4 bugs HAH | ||
PerL_MonK | compared to Java/C++/Python or whatever other OOP | ||
s1n | that was totally unintuitive | ||
pmichaud | I'm not responsible (mostly) for language design. :-| | ||
s1n | i assumed that proto was going to default the .new with no parameters | ||
PerL_MonK | noone actually blamed you about it :) | 22:09 | |
that was.. let's say a quick note | |||
but my Foo $f; $f.new(1,2,3); looks nice | |||
jnthn | I think pretty much every other language I've worked in that did OO actually required you to create an instance of the object. :-) | ||
PerL_MonK: Yeah, apart from that won't actually do what you want... :-) | 22:10 | ||
PerL_MonK | yeah make that -> | ||
jnthn | PerL_MonK: Since with that $f is not changed, but still the proto. | ||
pmichaud | $f.new(1,2,3) creates (then discards) an object of type Foo | ||
jnthn | my Foo $f .= new(1,2,3) | ||
pmichaud | $f remains unchanged, since it wasn't assigned to. | ||
s1n | jnthn: the case i was referring to still calls the constructor, but if you don't specify, it will use the no parameter version | ||
jnthn | Or my $f = Foo.new(1,2,3) # if you can't want $f typed | ||
s1n | which is exactly .new() | 22:11 | |
PerL_MonK | blah | ||
s1n | so 'stl::string blah' call's stl::string's empty parameter constructor, basically defaulting blah to be "" | ||
which is what i was used to | |||
pmichaud | time to order (and fetch) pizza...bbiaw | 22:12 | |
s1n | what's wrong with this one: | 22:13 | |
rakudo: my %foo = ("test", 1); my @bar = <test>; say %foo<@bar[0]>; | |||
p6eval | rakudo 0310a3: OUTPUT«Use of uninitialized value» | ||
pmichaud | <@bar[0]> is same as {'@bar[0]'} | 22:14 | |
22:14
payload left
|
|||
s1n | oh | 22:14 | |
duh | |||
22:16
mib_hh520ivx joined
|
|||
s1n | @seen frioux|home | 22:16 | |
lambdabot | frioux|home is in #perl6. I don't know when frioux|home last spoke. | ||
s1n | @seen frew|work | ||
lambdabot | frew|work is in #perl6. I don't know when frew|work last spoke. | ||
s1n | store& | 22:17 | |
22:19
payload joined
22:21
mib_hh520ivx left
22:26
amoc left
22:27
Tene_ joined,
Tene left
23:09
PerL_MonK left
23:19
iblechbot left
23:31
meppl left
23:36
mfwitten joined
23:37
dKingston left
23:49
dKingston joined
|