»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by lichtkind on 5 March 2010.
00:00 ruoso joined
jnthn lue: Yeah, there was a new monthly release today. 00:01
lue: We'll do a Rakudo monthly on Thursday that builds against it.
lue R* is coming! 00:02
jnthn Yes, but it's not this release. ;-)
lue ...
:(
jnthn lue: Rakudo * will not be one of the normal monthly releases.
lue oh. 00:03
:)
jnthn lue: The regularly monthly releases are just "compiler releases".
lue so when is R*
jnthn Rakudo * when it comes will be more than that - also some modules, module install tool, etc.
lue so it's been bumped to after April I take it ;)
jnthn lue: We didn't set exactly yet. It was planned for April originally, but we had to re-plan a bit; see use.perl.org/~JonathanWorthington/journal/40258 00:04
cognominal rakudo: my %e = enum < ook! ook. ook? >; %e<souk>++
p6eval rakudo cdb2b8: ( no output )
jnthn cognominal: :-) 00:05
cognominal: Well, the anonymous enum constructor is just spec'd as giving you a Hash.
Well, last I checked it was anyway. :-)
jnthn wonders if he can find the anonymous role bug before his beer runs out 00:07
...not that I feel remotely tired, even though it's 2am. :-/
lue I don't know the situation concerning Pm, but from the several things I've seen, it's certainly valid (I want to use a word with a more positive connotation than valid actually) 00:09
00:09 elmex joined
lue I have noticed he's missing, though. 00:09
jnthn: you can do it! Stay up until 4! It's in you!!! :) 00:10
jnthn lue: I'm quite sure it is, my problem isn't actually tomorrow. It's more like, when I find out that on Thursday or Friday I'm meant to attend a meeting in another city that starts at 9am. ;-) 00:11
I try not to let my body clock skew too far; I'm actually employed now, and now and then have to suffer such annoyances as morning meetings. :-) 00:12
lue jnthn: just for you xkcd.com/361/
:)
jnthn lol :-)
lue I'm actually scared that you _do_ stay up 'til 3 every night. ( That guy has your name written all over himself :) ) 00:13
jnthn On the upside, I think I found the bug... 00:14
lue \o/ 00:16
00:16 Liig joined
lue is uploading /dev/beer.h to CamelTorrent for jnthn 00:16
jnthn Oh, I went to the store today, the fridge is pretty loaded now. :-) 00:17
Also, why on earth do you have C header files in /dev?!
:-)
spreadsheet His /dev stands for development 00:18
^_^
jnthn :-) 00:19
lue I made that goof a long time ago when I meant /usr/include
check the backlogs, I ended up making my /usr/include /dev and vice versa
(not in real life, although that would be awesome)
jnthn oh hey I fixed it. 00:20
> my $x = 42 but role { method omg { "wtf" } }; say $x.omg
wtf
lue resolution: <a href="example.com/patch.zip">patch.zip</a> [rated PG-13] 00:22
00:29 Liig left 00:30 ash__ left 00:31 clkao joined, liig joined
lue I'm slightly more interested in making things to go with rakudo that coding rakudo itself :) 00:32
00:32 confis-ca-tive is now known as hatseflats
jnthn lue: That's fine. Do it. :-) 00:36
colomon lue: Anything you code using Rakudo will probably entertain you and help us find a few bugs. :) 00:37
lue alright :)
jnthn colomon: I got sucked in to anonymous classes and roles this evening after fixing the earlier multi bug. I'll look at the next round of them tomorrow. :-)
colomon fair enough!
I like seeing anonymous roles working too. Though I admit as a programmer I'm not quite clear on why I'd want to use them. ;) 00:38
lue why would you? They haven't revealed themselves yet :)
colomon woah! lots of files changed by moritz_++, eh? 00:39
jnthn colomon: Yeah it's cool!
colomon groan. 00:40
lue ooh, separate Date.pm! (although I get the feeling its been around for a while)
colomon lue: nah, it doesn't date that far back. 00:41
jnthn groan. 00:42
colomon ;)
jnthn > my $x = 0 but role { method Bool { True } }; say $x; if ?$x { say "yay" }
0
yay
Unfortunately, doesn't work without the ? :-/
colomon huh. does if not call ? implicitly? 00:43
jnthn Seems not :-(
lue colomon: so it uses the epoch? :)
jnthn Ah well, that's another day's problem.
colomon I certainly don't have the time for it.
oh wait, have we stopped with the Date puns? 00:44
00:44 Kyril left
lue .now() we have (sorry, really stopping) 00:45
jnthn Stop it this Instance!
*Instant
ETYPINGSPOILEDPUN 00:46
lue rakudo: die("Instance not yet implemented")
p6eval rakudo 07fd77: OUTPUT«Instance not yet implemented␤current instr.: '&die' pc 17238 (src/builtins/Junction.pir:400)␤»
jnthn rakudo: my $x = class { method lol { say "oh hai" } }; $x.lol 00:47
p6eval rakudo 07fd77: OUTPUT«oh hai␤»
jnthn \o/
Now that's what I call first class.
lue *hearty seaman's laugh*
.oO(jnthn must be getting week. It's ~2AM where he is)
00:48
colomon rakudo: my $x = class { method lol { say "oh hai" } }; my $a = $x.new; say $a.lol;
p6eval rakudo 07fd77: OUTPUT«oh hai␤1␤»
colomon \o/ 00:49
lue :D
colomon rakudo: my $x = class does Real { method lol { say "oh hai" } }; my $a = $x.new; $a.lol;
p6eval rakudo 07fd77: OUTPUT«Malformed package declaration at line 11, near "Real { met"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
jnthn colomon: It takes does as the class name
colomon: STD does similar 00:50
colomon: You can do that, but you need to write :: in place of a name.
colomon rakudo: my $x = class :: does Real { method lol { say "oh hai" } }; my $a = $x.new; $a.lol;
p6eval rakudo 07fd77: OUTPUT«oh hai␤»
00:50 baisong joined
colomon jnthn++ 00:50
rakudo++
lue buubot: karma rakudo 00:57
buubot lue: rakudo has karma of 48
jnthn buubot: karma jnthn
buubot jnthn: jnthn has karma of 771
jnthn buubot: karma jonathan
buubot jnthn: jonathan has karma of 352
jnthn rakudo: say 771 + 352
p6eval rakudo 07fd77: OUTPUT«1123␤»
jnthn jnthn-- # flaunting karma wealth 00:58
lue buubot: karma jnthn
buubot lue: jnthn has karma of 770
lue 1122
dalek kudo: ee9c308 | jonathan++ | src/builtins/Failure.pir:
Fix bug in error reporting of unknown subs (and attempts to invoke other fails).
00:59
kudo: 483a9da | jonathan++ | src/Perl6/Compiler/Role.pm:
The next step in unbreaking anonymous roles; still some issues, but this gets the basics actually working.
lue xkcd.com/488/ ought to be put on a sticker and passed out amongst the crowd 01:01
jnthn sleep time for me, night all o/ 01:05
TimToady o
/
jnthn
.oO( Great, now I'll have a nightmare about being beheaded )
01:06
;-)
jnthn s.eeps
colomon o/
lue good night 01:08
01:21 snarkyboojum left 01:24 baisong left 01:29 wknight8111 left 01:36 gfx joined
lue afk 01:46
01:48 nihiliad left 01:53 agentzh joined 01:57 gurjeet joined 01:58 Psyche^ joined 02:02 Patterner left, Psyche^ is now known as Patterner 02:04 gurjeet left 02:31 Sarten-X left 02:33 snarkyboojum joined, nihiliad joined 02:39 snarkyboojum left 02:44 gfx left 02:51 plobsing_ joined 02:53 plobsing left 02:56 ash__ joined 02:57 Sarten-X joined 02:58 rv2733 left 03:06 Sarten-X left 03:11 ash__ left 03:18 petdance joined, nihiliad left 03:31 molaf joined, Khisanth left, Khisanth joined
lisppaste3 colomon pasted "Help needed from PIR experts..." at paste.lisp.org/display/98077 03:37
sorear colomon: the LHS of find_lex *must* be a P register 03:42
lexicals are always PMCs
incidentally, 'self' is a valid P register name 03:43
it's implicitly .local'd by IMCC in every :method
so assign %r, self is probably fine 03:44
03:48 Sarten-X joined
sorear pmichaud, ping 03:48
ingy morning... 03:49
for 10 more mins in .tw, anyway
03:53 yinyin joined 04:02 Sarten-X left 04:05 Sarten-X joined 04:12 meppl joined 04:19 snarkyboojum joined 04:26 meppl left 04:49 jaldhar joined 04:54 stephenlb left 04:55 gfx joined 04:57 kaare joined, kaare is now known as Guest61929 05:00 ReiniUrban joined 05:01 snarkyboojum left, rurban left, ReiniUrban is now known as rurban 05:09 jaldhar left 05:13 jaldhar joined, Guest61929 is now known as kaare_ 05:17 molaf left 05:22 justatheory left 05:25 snarkyboojum joined 05:44 ilogger2 joined 05:58 colomon joined
sorear 20:42 < sorear> colomon: the LHS of find_lex *must* be a P register 05:59
20:42 < sorear> lexicals are always PMCs
20:43 < sorear> incidentally, 'self' is a valid P register name
20:43 < sorear> it's implicitly .local'd by IMCC in every :method
20:44 < sorear> so assign %r, self is probably fine
diakopter :)
05:59 diakopter sets mode: +ooo sorear colomon ingy, TimToady sets mode: +vvv buubot dalek hugme, TimToady sets mode: +vv ilogger2 IRSeekBot, TimToady sets mode: +vv lisppaste3 p6eval 06:12 meppl joined
sorear tries to avoid pinging 06:13
snarkyboojum rakudo: say Nil.end 06:14
p6eval rakudo 483a9d: OUTPUT«-1␤»
06:18 uniejo joined
sorear rakudo: class X { method postcircumfix:<( )>() { say "Hi!"; }; }; (X.new)(); 06:19
p6eval rakudo 483a9d: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤current instr.: 'perl6;X;postcircumfix:<( )>' pc 392 (EVAL_1:170)␤»
sorear whaaat
eternaleye rakudo: class X { method postcircumfix:<( )>() { say "Hi!"; }; }; my $foo = X.new; $foo.(); 06:26
p6eval rakudo 483a9d: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤current instr.: 'perl6;X;postcircumfix:<( )>' pc 420 (EVAL_1:176)␤»
06:27 mberends joined
mberends \o 06:27
eternaleye o/
mberends made a bit of progress in proto :-)
sorear yay
TimToady ʎɐʎ 06:29
diakopter mberends: yoyoyoyo 06:30
sorear where do you get all those fancy characters? 06:32
TimToady .u turned 06:33
well, I have a program that scans the Unicode descriptions
sorear is \N unique to P6?
TimToady so far :) 06:34
so are \h and \v, I think
sorear I'm not really a big fan of reading \U0001013E in source code
06:34 meppl left
TimToady well, AEGEAN MEASURE SECOND SUBUNIT isn't much better... 06:35
sorear: are you confusing p6's \N with p5's \N?
p6's has nothing to do with Unicode
it's "not a newline"
rakudo: say "\c[AEGEAN MEASURE SECOND SUBUNIT]" 06:36
p6eval rakudo 483a9d: OUTPUT«𐄾␤»
sorear I thought \N{AEGEAN MEASURE SECOND SUBUNIT} was used in double quotey strings
that's the p5 one?
TimToady yes 06:37
was combined with \c in p6
so \N could be any character that isn't at a \n match
sorear does \n match more than just \u000A ? 06:38
06:38 Cristina_ joined
TimToady hmm 06:38
06:38 iblechbot joined
TimToady std: /\N{AEGEAN MEASURE SECOND SUBUNIT}/ # should complain about undefineds 06:38
p6eval std 30424: OUTPUT«===SORRY!===␤Undeclared names:␤ 'AEGEAN' used at line 1␤ 'MEASURE' used at line 1␤ 'SECOND' used at line 1␤ 'SUBUNIT' used at line 1␤Check failed␤FAILED 00:01 110m␤»
TimToady good
spinclad diakopter: (syntax for continuations): i like cont_1234(params): ... and goto cont_1234(args); along with passing them around as args and params 06:39
TimToady sorear: yes, \n matches any logical newline for common OSes
in p6, not in p5
diakopter spinclad: params?
spinclad after all, '(calling) a continuation is just a goto with arguments' 06:40
diakopter what arguments/params?
06:42 `snarkyboojum joined, `snarkyboojum left
spinclad (1) a continuation is a label with parameters, you goto it with arguments; (2) as first-class things, continuations can get passed around 06:42
06:42 Bzek joined
diakopter what are the parameters? (where do they go) 06:42
I mean, where do the arguments go 06:43
spinclad (two separate things really; having both cases of params/args in one line was confusing things i suppose)
not sure of yourr question 06:44
diakopter cont_1234(5) where does the 5 go
spinclad the arguments go: goto $c(args);
diakopter where does the 5 end up: 06:45
?
spinclad it gets bound to cont(int $i):
diakopter and where does $i end up
sorear mberends: I was looking at vill the other day, very neat
spinclad and the code after the cont(...): label will see it bound 06:46
06:46 scottamatot joined
mberends sorear: :-) vill is on ice until Rakudo * is out 06:46
spinclad a label with parameters, a goto with arguments
diakopter ok; I haven't thought of it that way
I didn't see the need for parameters/arguments, but I can see how that would be useful. 06:47
spinclad that's what i was playing with yesterday and the day before
that's how you can translate loops and conditionals down to 'assembly' code 06:48
sorear Where do anonymous methods fit into the Spectrum of Language Feature Insanity? 06:49
spinclad well, especially loops: variables updated per iteration can just be bound at entry 06:50
sorear SSA and CPS make a /beautiful/ combination
spinclad sorear: along with anonymous first-class values of other types, /me thinks 06:51
sorear: agreed
06:51 _jaldhar joined
sorear in the context where I am speaking, methods are not values 06:51
they are names 06:52
method $method () { ... } # overrides the method defined with name $method in a superclass
could be implemented with a gensym
spinclad in the context i'm speaking from, they are values you can get to by name
/get to by any means in the language 06:54
including the name-to-method namespace hash in the class metaobject 06:55
(aka vtable)
(or rather, the vtable may be its runtime residue) 06:56
but never mind me; just another ivory tower nutcake 06:57
scottamatot there are no just ivory tower nutcakes 07:01
sorear the ivory tower is something that they invented to stop people from daring to dream 07:03
snarkyboojum those "they" people - incorrigible 07:06
spinclad but these nuts taste just dreamy 07:07
crunchy, too -- i think they may be showing some promise 07:08
scottamatot promising nuts, o' all tings! 07:12
07:15 jaldhar_ joined 07:16 _jaldhar left
sorear prepares to be shot down 07:16
moritz_ takes up his shot gun
rakudo: say Date.new('0000-01-01').daycount 07:17
p6eval rakudo 483a9d: OUTPUT«-678940␤»
scottamatot I'm convinced ivory towers were invented by elephants. Who else has the capital?
moritz_ each country has a capital :-) 07:18
mberends alpha: my @a=<2 3>;my @b=@a.map({$_ xx 2});@b.perl.say 07:19
p6eval alpha 30e0ed: OUTPUT«["2", "2", "3", "3"]␤»
mberends rakudo: my @a=<2 3>;my @b=@a.map({$_ xx 2});@b.perl.say 07:20
p6eval rakudo 483a9d: OUTPUT«[["2", "2"], ["3", "3"]]␤»
sorear hey, I never noticed t/spec/S01-perl-5-integration before
this is *awesome*
mberends ^^ which is correct, alpha or rakudo?
moritz_ mberends: probably alpha 07:21
mberends it was bugging proto
moritz_ assignment to an Array flattens out the parcels returned from each map
or s/parcel/capture/ # not quite sure 07:22
sorear (I don't actually understand how list context works in Perl6)
spinclad mberends: hm... should be (('2', '2'), ('3', '3')) as Parcels i think, which should flatten to alpha's version
(what moritz_ said)
mberends my workaround is not to use map :-/ 07:23
sorear what does \%h mean in Perl 6? 07:25
sorear needs somebody to sit down and explain t/spec/S01-perl-5-integration at some point 07:26
this is a wonderful mine of prefabricated decisions but I'm not sure how it all works
moritz_ what do you mean by "prefabricated decisions"? 07:27
sorear I don't like having to decide interface issues 07:28
moritz_ I'm sure they need some work, especially those tests involving wantarray()
sorear++ # methodicals 07:31
sorear you like them?
moritz_ I'm of two minds, actually 07:32
I think it's very useful for HLL interop
spinclad (procedurals, functionals ...)
moritz_ and I think it's dangerous if overused as a pseudo-OO paradigm
sorear can't say I'm enthusiastic about all aspects myself 07:36
hmm, eval_lex.t looks nasty to implement
moritz_ oh yes
sorear hrm, pugs had full 5/6 interop? 07:38
moritz_ no 07:39
nothing in Perl 6 world has ever had anything "full" :/ 07:41
07:41 hg joined 07:42 hg is now known as Guest9849 07:56 fridim joined
sorear how did pugs 5/6 work? did it implement most of the spectests? 07:59
spinclad btw, should i expect t/spec/S05-mass/rx.rakudo to run a long time? running spectests, it's been sitting there for about 8 minutes runtime (5m utime, 3m stime), which is several hours on my undermemoried box (256MB real, so this 275-350M process is getting 170-200M to live in). i'm letting it run for now... 08:00
sorear: the spectests only test Perl 6, not 5 08:01
mberends spinclad: yes, noticed the same here also
sorear spinclad: S01 tests both. 08:02
08:02 jaldhar_ left
spinclad mberends: ok, i'll just check on it now and then for progress then 08:03
08:03 scottamatot left
spinclad sorear: ok, my error 08:04
in its day it ran all of the spectests (fudged for todo, skip, and such much like now), being the seed implementation for them 08:06
spinclad to bed & o/ 08:11
sorear it's amazing how much the cultural difference between perl6 and parrot is 08:16
here, we aim for the moon
there, it's "what do we need *right now*"
mberends yes, it's amazing
as Q2 (the launch window for Rakudo *) draws to a close, expect some more urgency here too. 08:17
sorear if Pugs really did pass all the non-fudged tests in S01, it was /quite remarkable/ 08:18
moritz_ I'm nearly sure it did not pass them all 08:19
sorear it could run XS code, intermix Perl 5 and 6 without eval, and share lexicals between domains
:(
mberends when you look at Pugs like that, it had so much going for it, and only the bus number against 08:21
moritz_ yes 08:22
sadly the bus number is a fairly hard criterion 08:23
mberends hopes to learn Haskell one day
sorear Haskell does not lend itself well to high bus numbers 08:24
sorear knows it well, but still has trouble dealing with big projects 08:25
08:26 masak joined
masak oh hai, #perl6 08:26
mberends oh hai, masak
mathw lolitsmasak o/ 08:28
masak backlogs 08:32
moritz_ isn't convinced that changing Date.daycount to a specified epoch is actually a win 08:35
sorear studies the Pugs perl5 implementation
it is... vastly smaller than Blizkost 08:36
masak moritz_: I'm not convinced that it's an overall win for the method to be public. seems to lead to quite some bikeshedding, for one. :)
08:37 dakkar joined 08:38 lestrrat is now known as lest_away
moritz_ masak: you're probably right 08:39
masak: which is why I marked the whole section as conjectural... might just as well remove it
masak +1
going Solomonian on bikeshedders has proven to work well in the past. :) 08:40
TimToady: 'has constant' still makes me happy. what's my best solution if I want to do something similar with an enum? (i.e. share it between a class and all its descendents.) enum is also a type declarator, but the name doesn't have a twigil... 08:43
08:43 meppl joined
moritz_ I'm not quite sure I can remove the public method from the implementation yet 08:43
due to limitations in core scoping stuff
masak that's fine, as long as it's evident that it's not by spec. 08:44
08:45 slavik joined 08:52 Trashlord joined
masak I know some people have reported similar things lately, but here goes: I'm getting 'Null PMC access in invoke()' when compiling src/Perl6/Grammar.pm 08:52
is this known?
will it be fixed before the release tomorrow?
moritz_ masak: git pull please
it should have been fixed yesterday 08:53
masak I'm on latest.
moritz_ you are? that's bad...
pugssvn r30425 | moritz++ | [S32::Temporal] remove .daycount method - use $date - $start_of_epoch to obtain a day count starting from a fix epoch 08:54
masak though my Parrot revision is 45845, as opposed to the 45822 in PARROT_REVISION.
I'll try building with the recommended Parrot.
moritz_ masak: there were branch merges after the parrot release
masak ah.
moritz_ including the immutable strings, for which a separate rakudo branch exists 08:55
masak that would explain it, then. thanks.
08:57 Bzek left 08:59 Khisanth joined
moritz_ wonders how much painting a bike shed can bare before collapsing under the weight 09:04
frettled moritz_: "bear", perhaps? 09:06
moritz_ probably not many bears :-) 09:07
frettled (bare = strip off)
moritz_ but yes, "bear"
frettled I suspect the answer is Mu³
moritz_ anyway, I'd like to propose a change in our Temporal discussions: anybody who proposes anything more complicated than the current status has to implement an at least partially working prototype in Perl 6 first 09:08
"For example, in Russia there are two concurrent calendars (the secular and religious) and they are a fixed number of days apart. Hence Christmas - December 25 in both calendars - occurs on December 25 in the secular calendar, but on Jan 5 (I think) according to the secular calendar, but December 25 according to the religious calendar." 09:11
I don't understand it at all. How can Christmas be both Dec 25 and Jan 5 int he secular calendar? 09:12
masak usually, the bikeshed doesn't collapse, because the paint is only hypothetical and a matter of discussion. :)
09:12 finanalyst joined
finanalyst hi. sorry to have dumped my proposal without warning 09:14
just back logged. you wonder about old and new Christmas in Russia. Its quite simple really
moritz_ I wonder how a day can be two different days. 09:15
finanalyst new Christmas is 25 December, old Christmas is 5 January 09:16
moritz_ ah
so you're really talking about two different days
which wasn't obvious from your mail at all :-)
finanalyst but "old Christmas" is 25 Dec in the calendar that was in Russia at the time of the revolution
masak [backlog] turns out that `[+];` still works. yay!
moritz_ rakudo: say [+] 09:17
p6eval rakudo 483a9d: OUTPUT«Unable to parse postcircumfix:sym<[ ]>, couldn't find final ']' at line 11␤current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)␤»
moritz_ std: say [+]
p6eval std 30425: OUTPUT«===SORRY!===␤Prefix requires an argument at /tmp/GdOz8bDh3D line 1 (EOF):␤------> say [+]⏏<EOL>␤Parse failed␤FAILED 00:01 110m␤»
finanalyst i was trying to be as concise as possible
masak well, not in Rakudo or STD.pm6, but in pure Perl 6 :P
moritz_ ok :-)
09:20 lest_away is now known as lestrrat
moritz_ rakudo: class A { }; A::foo 09:27
p6eval rakudo 483a9d: OUTPUT«Can not find sub A::foo␤current instr.: 'perl6;Perl6Exception;throw' pc 14763 (src/builtins/Seq.pir:38)␤»
moritz_ rakudo: class A { }; A::foo(:bar)
p6eval rakudo 483a9d: OUTPUT«Can not find sub A::foo␤current instr.: 'perl6;Perl6Exception;throw' pc 14763 (src/builtins/Seq.pir:38)␤» 09:28
moritz_ finanalyst: your proposal on p6l sounds like you want to have an Instant, then apply a day filter, then a month filter... 09:37
09:37 Guest9849 left
moritz_ finanalyst: if that's what you want to do, I'm afraid it doesn't work 09:37
finanalyst moritz_: why is that?
moritz_ finanalyst: becaue leap seconds and DST changes are day dependent, so you need to map to the exact date in the first place 09:38
finanalyst moritz_: exactly.
the day filter handles the leap seconds DST
the month filter handles the leap days
moritz_ I don't understand that 09:39
the day filter needs to determine the full date already
like 2010-02-28
finanalyst no.
moritz_ it must
because a day isn't uniform in length
finanalyst the day filter only provides a day_of_week and an offset from start of epoch 09:40
2010-02-28 is a calendar name consisting of calendar dependent year and month names
so to get to 2010-02-28 from an Instant, you need to know time-zone, and calendar information\ 09:41
moritz_ and dst, right
finanalyst yes
moritz_ but you need to information already to map an Instant to a day
s/to/that/ 09:42
so in your scheme you need to supply that information twice
finanalyst so there are two processes: 1) going from instant to yy-mm-dd and 2) going from yy-mm-dd to instant
moritz_: i dont see why information is supplied twice. 09:47
09:47 yinyin joined
moritz_ finanalyst: once while mapping from instant to day, once while mapping from day to year-month-dayOfMonth 09:47
finanalyst the idea is to had dst and leap second information encapsulated in the time-zone day fiter 09:48
month filter is dependent on day fitler
year on month
so dst and leap second are incorporated in day filter and so transparent to month filter 09:49
moritz_ maybe there's nothing wrong with it after all
finanalyst but month filter handles leap days
moritz_ it's just that upon first reading I thought that each of these filters would be relatively simple 09:50
now I've realized that the day filter needs to handle the full DateTime complexity
finanalyst not the time complexity
moritz_ and after having identified the day, the rest is trivial 09:51
finanalyst i would say that by isolating the exceptions to the correct filters, the complexity of DateTime becomes more manageable 09:52
then moving from time-zone to another, or to another calendar, requires using a different filter at the appropriate level
also filters such as quarter, decades, centuries can be added on over the months and years streams 09:53
moritz_ finanalyst: I only believe it makes things easier when you actually implement it, and find it to be easier 09:54
finanalyst: to me it sounds like Instant => day is the hard part, and all the reset is just a SMOP compared to it, how ever you structure it
finanalyst moritz_: that is very profound wisdom and i can only agree
jnthn o/ 09:55
moritz_ doesn't feel wise at all, rather like a jerk
09:56 clintongormley joined
jnthn sorear: (methodicals) If an object has a method foo, do we call that one, and we only go looking for methodicals if we get a failed dispatch? 09:59
jnthn is trying to get his head around the proposal
I think we've already in the past had some method-dispatch-falls-back-to-sub-dispatch-ish semantics and they got removed for various reasons. 10:00
moritz_ right; the new thing about this proposal is that the sub fallback is not for ordinary subs, but for things especially written for that purpose 10:01
jnthn Yeah, that's the reason I'm kinda curious about it. 10:02
I'm not sure it's different enough.
But maybe.
10:03 rgrau` joined 10:04 broquaint joined
sorear jnthn: I was thinking that methodicals take precedence over methods. 10:11
It's only 80% baked idea.
10:12 meteorjay left, meteorjay joined
jnthn sorear: Then potentially every method dispatch we do has to check for methodicals first. Though depending on how it's formulated we could maybe figure that out at compile time, but I'm not convinced yet. 10:13
sorear They are designed *specifically* to be compile time checkable 10:21
$o.foo generates a subish call iff there is a methodical operator named foo in the lexical environment 10:22
I'm not sold on 'our' methodicals
moritz_ sorear: uhm... didn't you write about type constraints?
sorear this is actually a good reason to ditch them
moritz_ sorear: the types in variables isn't generally known at compile time
sorear the type constraints are to allow for subclasses to be associated with more specific definitions 10:23
like what we have for postcircumfix
es
moritz_ uhm, what do we have for postcircumfixes? not sure I follow 10:24
sorear postcircumfix:<[ ]> needs to be overridden by any class that implements Positional
methodicals are multis to support that 10:25
however, if there is a methodical operator in scope and multi dispatch fails, the entire dotty fails
(and now I need to sleep)
moritz_ but postcircumfix:<[ ]> isn't restricted to Positional
10:28 broquaint left 10:33 broquaint joined
masak rakudo: class BracketsGrumpy { method postcircumfix:<[ ]>($x) { die "Waah! I don't like brackets!" }; say BracketsGrumpy.new[42] 10:39
p6eval rakudo 483a9d: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 11␤current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)␤»
masak rakudo: class BracketsGrumpy { method postcircumfix:<[ ]>($x) { die "Waah! I don't like brackets!" } }; say BracketsGrumpy.new[42]
p6eval rakudo 483a9d: OUTPUT«Waah! I don't like brackets!␤current instr.: '&die' pc 17240 (src/builtins/Junction.pir:400)␤»
10:45 JimmyZ joined 10:48 JimmyZ left
jnthn masak: :-) 10:56
10:56 yinyin left
masak might interest someone to see how Boo does macros: boo.codehaus.org/Syntactic+Macros 10:57
11:02 pmurias joined 11:05 jaldhar_ joined 11:09 broquaint left
masak interesting to read all the comments on news.ycombinator.com/item?id=1279238 11:09
I feel the tone is much more hopeful and positive than only a few months ago. 11:10
possibly thanks to the excellent article that led to this discussion. leont++
colomon must be it, I greatly doubt the average HN reader is following what we're doing here... 11:11
11:11 jaldhar_ left 11:12 jaldhar_ joined
colomon sorear++ 11:14
11:14 pmurias left, pmurias joined
masak finanalyst: just saw your massive email on p6l about calendars. will reply after reading it all. 11:15
and after mulling a bit.
hopefully in the next few days.
but for now, please be aware that to the extent that 'tightly focused on the Christian Gregorian calendar' is a trap, it's one we've been walking into, not falling into. 11:16
I've been wanting to steer clear of premature generalization of the kind that leads to having to wield names like Calendar::Gregorian just to get the time of day. 11:18
(and I've been saying this so much lately that I feel I'm repeating myself when I restate it now.) 11:19
11:22 envi^home joined 11:28 iblechbot left
moritz_ masak: irclog.perlgeek.de/perl6/2010-04-21#i_2248424 should take care of that :-) 11:31
masak oh right, that was in relation to finanalyst's post. 11:32
I'm all for people matching up non-trivial proposals with implementation. that should weigh down most of the astronauts out there. 11:34
finanalyst masak: agree. silly to have long calendar names for simple things 11:35
masak (not necessarily talking about finanalyst here, whose email I haven't digested yet)
finanalyst but that can be handled by aliasing
masak aliasing?
you mean doing Short ::= Long::Name::Which::I::Can't::Bear::Typing::All::The::Time?
finanalyst yes
masak meh 11:36
moritz_ that only hides the symptoms of the complexity
masak if you need to do that, you're covering up the deeper problem.
right.
finanalyst not sure
some things are inherently complex
but they show up in corner cases 11:37
most people dont care about different time zone
but if they do, they need to be able to have a consistent way to deal with it
masak finanalyst: 'some things are inherently complex' is quite a silly thing for the one proposing to parameterize over all the world's calendar systems to say. :P
finanalyst similarly, different calendars
masak I'm prepared to go quite far to protect the inherent simplicity of the current Temporal. 11:38
finanalyst doesnt really look simple to me
masak that said, being able to plug in other calendar systems and make them look native would be quite OK. 11:39
just not core.
finanalyst and it hides the complexity of dst and leap seconds
doesnt matter if core or not, just that it can be done easily 11:40
moritz_ well, Instant is already core
so as long as you can round-trip Instant and DateTime, you can very easily integrate it with custom date/time implementations
finanalyst if you want some time in perl6, something has to be core
masak indeed. 11:41
file modifications are times, for example.
finanalyst the measurement paradigm, a term i invented to avoid saying DateTime, is not specified currently 11:42
there is just a blank space for semi-internal
pmurias why do we need date handling in the setting?
moritz_ pmurias: we don't, really. I was mostly following Dave Rolsky's advice 11:43
finanalyst may be the algorithm / method for 'round-tripping' that you intend is similar to the methodology i describe
moritz_ pmurias: but it does make it easier to provide convient conversion methods between DateTime and Date 11:44
finanalyst to what extent is Setting considered 'core'
and how can you make a distinction between Date and Time? What is 10 hours after 31 Dec 2010 , 21.40 11:45
moritz_ well, you can look at dates in isolation
time in isolation is much harder 11:46
pmurias finanalyst: setting contains the things which are loaded into your lexical scope at program start
i don't think there are any core modules in perl 6
finanalyst but are the settings not considered a part of the implementation?
moritz_ currently Test.pm has this status implicitly
finanalyst sorry core/non-core is a distraction. 11:47
pmurias finanalyst: the setting used to be called the prelude
finanalyst the first Setting library will probably carry to all implementations of perl6.
pmurias: i followed some of the discussion before prelude was changed to settings 11:48
i am a long-term troll
pmurias is confused
finanalyst pmurias: sorry to be confusing. 11:49
pmurias finanalyst: what's the think you don't know 11:51
s/think/thing/
finanalyst pmurias: sorry got to go for a bit - newspaper interview
11:53 pmurias left
masak audreyt++ # pugs.blogs.com/pugs/2010/04/how-to-...in-10.html 12:02
I'm seeing uncanny parallels in the Haskell 2010 announcement to the Perl 6 process. 12:04
"Haskell 2010 is a small but significant step on the road that was started by the Haskell' committee 4 years ago, The process has not been a smooth one, and there have been several changes of direction, but the current process is actually producing concrete results that let us move the language forward in positive steps, so I feel we're on the right track."
^_^
mathw Well as I understood it when Haskell' kicked off, they weren't really sure what they needed to do anyway 12:05
Other than everyone agreeing that Haskell 98 was now too old and they needed to produce an updated standard 12:06
pmichaud good morning, #perl6 12:10
moritz_ good morning
masak pmichaud: \o
12:12 lestrrat is now known as lest_away 12:14 jaldhar_ left, jaldhar_ joined 12:16 Associat0r joined, Associat0r left
colomon yow, my infix:<+> to .Numeric patch caused 1366 failures in the spectest. :( 12:23
*prefix:<+>
moritz_ lemme guess, it interacts with get_number vtable? 12:24
colomon I don't know yet.
set_pmc() not implemented in class 'Array' 12:25
current instr.: 'perl6;Any;Numeric' pc 372996 (src/gen/core.pir:30000)
called from Sub 'prefix:<+>' pc 288268 (src/gen/perl6-actions.pir:21177)
Hmmm... I guess for Positional (Iterable?) .Numeric should forward to .elems. 12:26
moritz_ colomon: currently Rakudo has a kind of weird scheme for prefix:<+> 12:27
colomon rakudo: my Iterable $a = 1..10; say $a.Num.WHAT 12:28
p6eval rakudo 483a9d: OUTPUT«Int()␤»
moritz_ afaict prefix:<+> does a numeric coercion in PIR
which boils down to a get_number vtable call
colomon :pirop<set N*>
is what it says.
moritz_ so Mu has a get_number override
which calls .Num 12:29
colomon .me is puzzled by that
moritz_ it may have to do with with HLL interop
not sure
12:29 mariano__ joined
masak blogs.perl.org/users/jt_smith/2010/...-perl.html 12:29
colomon you're totally right about the get_number thing. 12:30
masak "...and it has nothing to do with Perl 6!" -- I feel that's both true and false :)
12:30 [particle] joined
masak but I'm probably biased. 12:30
12:30 mariano__ left
moritz_ he even mentions Class::MOP specifically 12:31
but it has nothing to do with perl.
erm, Perl 6
sure
colomon: so did you change Mu.pir to call .Numeric instead of .Num?
colomon I didn't.
moritz_ so what was it you changed?
(that would be thing I'd try first) 12:32
colomon I changed prefix:<+> to not have a PIR implementation, then wrote a prefix:<+> which calls .Numeric
what I don't understand: Mu.get_number calls .Num. Str.Num calls prefix:<+> to do the conversion.
how is that not an endless loop?
moritz_ because Str has a separate get_number from PIR/parrot
colomon ah! 12:33
okay, will strike my patch and try your approach.
moritz_ not sure if that works if .Numeric returns something that's not a parrot number 12:34
12:34 iblechbot joined
colomon rakudo: say "45".get_number 12:35
p6eval rakudo 483a9d: OUTPUT«Method 'get_number' not found for invocant of class 'Perl6Str'␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
moritz_ vtable != ordinary method
colomon I think you're right about the parrot number thing: $N0 = self.'Numeric'() 12:36
On the other hand, a working .Numeric patch using it will be more correct than the current version, even if it's still not completely correct.
12:36 broquaint joined
CokeBot9000 points out to sorear that he is seeing a snapshot of nearly 10 years of parrot activity. 12:37
pmichaud (get_number) The standard mechanism to obtain a numeric value of an object in Parrot is to use the get_number vtable 12:40
jnthn back from errands 12:41
pmichaud so Rakudo tries to map that into Perl space as best it can, so that we can obtain numbers from other objects in the Parrot ecosystem that won't have a '.Numeric' method.
or, put another way, it's important to remember that not all objects at runtime are subclasses of Any, or even of Mu :-) 12:42
masak HLL interoperability is hard!
colomon let's go shopping! 12:43
colomon 's first attempt at changing Mu.get_number fails horribly.
12:45 mariano__ joined 12:46 smash_ joined
smash_ hello everyone 12:46
colomon In the longer run, wouldn't it make more sense to hard-wire .Numeric to call get_number for things outside Perl 6 space? Otherwise prefix:<+> and .Numeric will never "be the same"....
masak smash_: \o
colomon smash_: o/
masak colomon: sounds sane to me. 12:47
moritz_ colomon: but where would you hard-wire it?
colomon moritz_: darned if I know.
moritz_ you can't do that in the object, because it's not in the (non-Perl 6) object
so you'd have to do it in the dispatcher
which just feels oh-so-wrong
12:48 lest_away is now known as lestrrat
jnthn Yeah, I'm not keen on that one either. 12:48
OTOH, there could be a last gasp "oh no, we found no method, look in this language interop namespace"
moritz_ jnthn: which would fail for autoloaded methods 12:49
pmichaud no, not necessarily
jnthn moritz_: In what sense?
(Yes I can see how things maybe could go awry there...)
pmichaud "oh no, we found no method even after autoloading, look ..."
jnthn pmichaud: Yeah, that'd perhaps work. 12:50
moritz_ jnthn: consider a foreign $obj that responds to all methods
jnthn: then it would respond to .Numeric, but in a generic, wrong way
not in the get_number way
anyway, the current get_number mess seems less wrong to me than hard-coding .Numeric in a dispatcher 12:52
colomon Changing Mu.get_number to call .Numeric is resulting in an infinite recursion. :\
moritz_ colomon: for what kind of objects?
colomon not sure, that's while compiling Test.pmn 12:53
*pm
moritz_ you can try +1 without having compiled Test.pm
pmichaud colomon: what are you trying to achieve, here, ooc? 12:54
colomon ....um... actually that's what happens when you invoke perl6
moritz_ colomon: my guess is that if .Numeric return something which is not a parrot number, then the assignment to $N0 will trigger a call to get_number
colomon pmichaud: by spec, prefix:<+> calls .Numeric. I'm just trying to make that happen. 12:55
pmichaud colomon: I suspect the spec will ahve to change on that point, if Perl 6 is to have language interoperability 12:56
otherwise +$python_obj is never going to work, because $python_obj doesn't have a .Numeric method.
12:57 fridim left
colomon Even if it does change, I would imagine it will change to prefix:<+> calls .Numeric for p6 objects... 12:59
pmichaud sure, that's likely.
moritz_ which is what Rakudo currently does, excepth it's spelled .Num atm
pmichaud well, Rakudo does it by passing through the get_number vtable interface, though. 13:00
moritz_ right
pmichaud prefix:<+> doesn't call .Num directly, it calls get_number which then calls .Num on p6 objects
13:00 ReiniUrban joined, pmurias joined
colomon rakudo: my Complex $c = 1i; say +$c 13:00
p6eval rakudo 483a9d: OUTPUT«You can only coerce a Complex to Num if the imaginary part is zero␤current instr.: 'perl6;Perl6Exception;throw' pc 14763 (src/builtins/Seq.pir:38)␤»
13:01 ReiniUrban is now known as rurban
colomon Does get_number require you to return a Parrot number type, or is that just a "feature" of our current implementation? 13:02
pmichaud at the moment, it requires a Parrot native number, which IMO is a design failure on Parrot's part. (more) 13:03
See the long discussion in trac.parrot.org/parrot/ticket/1445 for why. 13:04
and trac.parrot.org/parrot/ticket/1470 shows how it's proposed that Parrot's get_number be able to return things other than native numbers.
masak rakudo: say +(2i * 2i)
p6eval rakudo 483a9d: OUTPUT«-4␤»
masak \o/
13:07 lestrrat is now known as lest_away
PerlJam greetings 13:10
CokeBot9000 PerlJam: yo. 13:11
PerlJam: you secede yet?
PerlJam not that I know of
pmichaud ...secede? 13:12
CokeBot9000 pmichaud: lame regional humor!
now you make a joke about wall street.
pmichaud oh, I get it. I actually live in that region. 13:13
PerlJam there's a wall street in plano?
:)
pmichaud and, alas, I live in the subregion where we appear to routinely elect and support the people in favor of secession
CokeBot9000 pmichaud: makes you feel any better, I live near the capital, so I hear about everybody that gets elected in these parts. 13:14
pmichaud (which means that at some point I can start organizing actually vote the idiots out of office, as opposed to the situation I used to have where all I could do was look from afar and say "I wish I could do something to get those people out of office"
PerlJam I'm not sure how well the "idiots out of office" campaign will fare. 13:15
remember: some group of idiots voted them *in* in the first place
CokeBot9000 "don't be idiots". great slogan! 13:16
I'd vote for that. =-)
pmichaud PerlJam: yes, but it's easier to have an impact when you're in the same precinct/district with the idiots
when I lived in CRP, for example, I would've loved to have worked to get Tom Delay out of office
jnthn
.oO( that'd make a great name for a beaurocrat...they love to delay crap )
13:17
pmichaud in my case, I was soooooo happy to actually be able to vote Don McLeroy off of the State Board of Education (apologies to all for obscure regional political reference) 13:18
(short answer: McLeroy is one of those who is pushing to change state curriculum standards to support Intelligent Design theory.) 13:19
[particle] i know about mcleroy....
pmichaud (although they no longer refer to it as "Intelligent Design" )
PerlJam what's the new moniker?
pmichaud I don't know that there's a new moniker. 13:20
I think they explicitly wanted to avoid any sort of label.
PerlJam yeah, that's a subtle win for them
pmichaud Anyway, McLeroy lost in the primary (yay!), so I can feel that my vote did something useful. :) 13:21
13:21 CokeBot9000 left
PerlJam I don't mind if they teach ID in the classroom as long as it's given proper context. "There are lots of theories, some have evidence, others are just wishful thinking; here are some examples of each ... " :-) 13:21
moritz_ well, as long as they also teach the religion of the Flying Spaghetti Monster, I'm fine 13:22
13:22 rgrau joined
colomon rakudo: say (+(5/4)).WHAT 13:23
13:23 ive joined
p6eval rakudo 483a9d: OUTPUT«Num()␤» 13:23
moritz_ hm. Maybe for now it would be sane-ish workaround to try .Numeric first in prefix:<+> and only fall back to the vtable method if that fails 13:24
pmichaud colomon: if you want to change prefix:<+>, you probably need logic like
...what moritz++ said
moritz_ (despite the downsides which I explained above)
pmichaud actually, I would suggest testing the argument for Mu-ness, use .Numeric if ~~ Mu and get_number otherwise
one could also let Parrot multimethods take care of it, if you're willing to leave prefix:<+> out of the p6-setting 13:25
jnthn Ouch, then every numification needs an isa check. :|
pmichaud jnthn: not every numification, only those using prefix:<+>
jnthn Well, true. 13:26
pmichaud and there actually aren't that many of those.
moritz_ jnthn: c'mon, every numification needs with prefix:<+> needs two multi dispatches right now anyway
s/needs//
pmichaud ...it does?
colomon So this would mean taking the pirop back out of prefix:<+>, and coding it as an operator.
moritz_ pmichaud: sure, to prefix:<+> and then to .Num
pmichaud colomon: yes.
moritz_ well, not every, but many 13:27
pmichaud moritz_: oh, right. (I misread.)
moritz_ I don't think a type check is so much more expensive
pmichaud actually, it is. :-(
moritz_ even when not implemented as smart match?
13:27 CokeBot9000 joined
pmichaud even then. Parrot type checking is much worse than you might otherwise expect 13:28
especially for deeply nested classes
moritz_ ouch
pmichaud it ends up being an O(n^2) operation, where n is the depth of the derivation.
colomon :\
moritz_ that's *really* ouch
is there a ticket for that?
pmichaud at least we fixed it so it's not O(n^2) of string comparisons. :) 13:29
PerlJam where's chromatic with his +10 wand of optimization?
pmichaud PerlJam: that's the optimized version, actually. :-(
moritz_ so.. how much of our total execution time is spent in type checking code? 13:30
10%?
pmichaud oh no, not nearly that much.
colomon errr.... I just started writing our multi prefix:<+>(Mu $a)
Do I still need to check against Mu if I do that?
slavik I have researched this, but how can I get rakudo to compile perl6 to pbc?
pmichaud type checking is slow compared to what you expect it would likely be, not slow relative to overall execution time
I'm just saying that type checking might not be faster than a method call. 13:31
moritz_ pmichaud: well, afaict type checking needs to be done for every multi dispatch...
pmichaud colomon: note that prefix:<+>(Mu $a) won't work for any objects that aren't Mu.
(unless that case is hotpathed somewhere in the dispatch)
colomon so how can I say prefix:<+>(any conceivable object $a)? 13:32
pmichaud colomon: I don't know the answer to that one, which is why prefix:<+> is still in PIR. 1/2 :-)
moritz_ colomon: maybe with prefix:<+>(\$x) ?
jnthn Note that for Perl 6 multi subs we have a type-ID-based cache. 13:33
If we can get a good enough answer from that, we don't do any type checks other than on the first dispatch.
moritz_ though you can't store the result of unpacking in a variable if its not ~~ Mu
jnthn That's why it's ~10% faster to call a multi sub in Perl 6 than a non-multi.
moritz_ ah, ok
jnthn s/Perl 6/Rakudo/ 13:34
[particle] multi prefix:<+>($a) won't work?
pmichaud [particle]: that's actually prefix:<+>(Any $a)
[particle] rats. makes sense, but rats.
pmichaud no, Rats are a subclass of Any. :-P 13:35
jnthn I thought they were Cool now?
:-)
[particle] no, rats are elected in texas :P
colomon They're Real, at any rate.
pmichaud jnthn: I didn't say "immediate subclass" :-P
jnthn ;-)
pmichaud Rats are a subclass of Mu, also. :)
jnthn So we have Real Cool Rats in Perl 6. 13:36
moritz_ aye
pmichaud while the rats in texas are definitely Not Cool.
moritz_ imaginary rats often indicate phobias
jnthn subset TexasRat of Rat where * !~~ Cool; 13:37
pmichaud colomon: my suggestion would be to write prefix:<+> in src/cheats/num-ops.pir 13:39
jnthn oh no, we'd moved it out of cheats I thought 13:41
masak would 'subset TexasRat of Rat where none(Cool);` do the same thing?
pmichaud no
prefix:<+> has always been :pirop<set__NP> iirc
which means that prefix:<+> has been limited to floating point values 13:42
which is what colomon++ is trying to fix, iiuc
anyway, it'd be similar in this respect to prefix:<~>, which is also done as a PIR cheat.
colomon any quick hints on how to write $a ~~ Mu in PIR? 13:43
Mu.'ACCEPTS' somehow? 13:44
jnthn $P0 = get_hll_global 'Mu'
$P0.'ACCEPTS'(...)
pmichaud ick, don't go through ACCEPTS for this
use 'isa'
jnthn Where ... is the register holding $a
pmichaud as it is, we're turning a vtable call into a subroutine dispatch :-(
jnthn Aye, what pmichaud said for this case. :-)
pmichaud $I0 = isa ..., ['Mu'] 13:45
oh, just a sec....
nopaste.snit.ch/20321 13:46
colomon pmichaud++ 13:47
pmichaud I suppose we could also do it as a Parrot multi
I'm not sure which would be faster, there -- an explicit check in the sub or letting Parrot figure out the correct sub to dispatch
colomon building now. 13:48
pmichaud as a multi, it would look like: nopaste.snit.ch/20322
colomon I'll try the first version first. 13:49
pmichaud don't forget to remove the :pirop<> from Grammar.pm 13:50
colomon and define Mu.Numeric. :)
pmichaud ...? 13:51
why would one define Mu.Numeric?
13:51 molaf joined
colomon prefix:<+> is calling it.... 13:51
pmichaud not every object has a .Numeric
moritz_ Cool should have .Numeric 13:52
pmichaud prefix:<+> calls the .Numeric of whatever object gets passed, not Mu.Numeric
moritz_ it's fine for +$thing to fail if $thing is not Cool
pmichaud it's fine for +$thing to fail if $thing doesn't have a .Numeric
defining Mu.Numeric defeats that.
colomon well, at the moment nothing at all has .Numeric defined. Sticking it in Mu is a quick way to check the change. It just forwards to .Num at the moment, so (at least in theory) it will have the same behavior as before, no? 13:53
moritz_ yes, but it kinda defeats the purpose of the patch :-) 13:54
so good for testing, bad for pushing
pmichaud actually, I think it won't have the same behavior.
but it's reasonable to use it for testing
colomon I promise I won't check it in like that.
pmichaud keep in mind that you're fundamentally altering the flow of control of the base types 13:55
so the old rules about what happens when no longer apply
it's similar in kind (but not degree) to the same sorts of problems we experience when we change the organization of list/array/iterator. It has profound effects.
the "same behavior as before" didn't involve Numeric at all for Int/Num/Str. 13:56
colomon compiles okay, +"45" still works, and one of the test files that crashed before works again.
pmichaud er, rephrase
the "same behavior as before" didn't involve .Num at all for Int/Num/Str
now it will.
colomon right. 13:57
pmichaud I would probably prototype Cool.Numeric as
method numeric() { pir::set__NP(self); } 13:58
s/numeric/Numeric/
colomon thank you! 13:59
ah, with the current version S03-operators/numeric-context.t blows up badly. Time for Cool.Numeric... 14:03
That fixes that test file. 14:08
14:14 tylerni7 joined 14:15 iblechbot left 14:19 tylerni7 left, tylerni7 joined 14:21 finanalyst left 14:29 tylerni7 left 14:33 uniejo left 14:37 tylerni7 joined, tylerni7 left, tylerni7 joined 14:40 justatheory joined 14:42 meppl left
moritz_ colomon: does it fix the rest of the spectest too? 14:44
14:51 ash_ joined 15:02 constant joined, constant left, constant joined
masak Alias: ping 15:02
diakopter :| 15:03
:||
15:04 rv2733 joined 15:07 ash_ left
masak diakopter: why the straight face? 15:08
diakopter heh 15:09
masak you should get a mouth with positive curvature, like this :)
jnthn :]
masak :>
diakopter oh, that's a MOUTH!?!??!? I always thought the ), |, ( represented the shape of the eyebrows.
masak no, the eyebrows go above the eyes. 15:10
diakopter yeah.
above is to the right
avar Perlito is interesting KP6 risen from the ashes I see
jnthn IRC. Where we all have unibrows.
PerlJam diakopter: depends on which direction gravity is coming from
pmurias avar: it evolved from mp6
15:10 ash__ joined
colomon moritz_: not quite. but it's close... 15:11
15:11 rv2733 left
avar pmurias: But similar ideas as kp6 or? What's it aiming for? 15:11
colomon +Mu is failing.
CokeBot9000 diakopter: your ways are strange and confusing to me. 15:12
15:12 rv2733 joined
pmurias avar: you should talk with fglock about that 15:14
avar: it's implementing a subset of Perl 6 efficiently on many backends 15:15
avar Yeah, I worked a bit on it when it was called mp6 and kp6, released it on cpan :) 15:16
diakopter masak: I was kidding. 15:18
heh?
pmurias avar: i remember 15:19
masak diakopter: the possibility occured to me.
15:19 arthur-_ joined
avar Just wondering if it's likely to get any further, as it were. This time. KP6 stalled because of some grammar issues IIRC 15:20
Or if it's just explicitly a really small perl 6 (why?) 15:21
mberends ./perl6 -e'DateTime.now.strftime("year %Y").say' # year 2010 15:23
masak \o/
mberends: you have it working locally?
mberends yup :)
PerlJam why call it "strftime" ? just because of history? 15:24
masak mberends++
PerlJam (why not call it .fmt ?)
avar If it's going to be .fmt maybe it shouldn't be DateTime :)
mberends PerlJam: Least Surprise. Yes, history. libc and p5 DateTime
afk # nom, bbl 15:25
masak .fmt *is* nicer. but people will likely expect .strftime
PerlJam .strftime is least surprise from outside Perl 6, but I would have actually expected .fmt 15:26
(.fmt is the "normal" formatting method)
masak ...with a completely different set of formats...
PerlJam true. :)
it's all polymorphic on the object being formatted 15:27
masak I'm having a hard time arguing with you, because I like .fmt as well :) 15:30
PerlJam now that I meta-think about it, the "time" part of .strftime triggered my useless-redundancy detector.
and .strftime is so last century :)
anyway, I don't mean to bikeshed and since I'm not the one doing the work ... 15:31
oh, and mberends++
[particle] PerlJam: so, now you're suggesting .strf? ;) 15:32
masak well, 'str' is kinda redundant too. maybe .f ? :P
PerlJam no matter what color you make it, the bikeshed is still blue in my mind :) 15:33
[particle] it's grue, you only saw it after the switch.
wolverian what other things respond to .fmt? 15:35
masak Any
Hash
Array
Pair
(or probably Mapping and List, rather than Hash and Array)
and among these, all .fmt methods have the same format string, namely the sprintf one. 15:36
wolverian right, I was thinking along the lines of liskov.
masak it would break Liskov. 15:37
in some sense.
PerlJam Liskov is about inheritance. Where's that at?
It would break "different things should look different"
masak well, since the format of the format string in strftime is completely different, DateTime objects will not purely extend the behaviour of Any. 15:38
wolverian surely DateTime inherits Any?
masak it does.
15:40 arnsholt left, arnsholt joined, jaldhar_ left
PerlJam rakudo: my $s = "foo"; say $s.fmt(':%7s:'); 15:40
p6eval rakudo 483a9d: OUTPUT«: foo:␤»
PerlJam rakudo: my $s = "foo"; say $s.fmt(':%7s:%7s:'); 15:41
p6eval rakudo 483a9d: ( no output )
PerlJam rakudo: my %h = foo => "bar"; say %h.fmt(':%7s:');
p6eval rakudo 483a9d: OUTPUT«: foo:␤»
PerlJam rakudo: my %h = foo => "bar"; say %h.fmt(':%7s:%7s:');
p6eval rakudo 483a9d: OUTPUT«: foo: bar:␤»
PerlJam I'll claim Liskov is already broken then :) 15:42
masak hm. probably so.
jnthn oh noes min liskov e kass
masak then I retreat to the 'different things should look different' argument and hold my position from there! :)
jnthn I guess it depends if you interpret it as "has a method with the same name"
Or "has a method with the same name and <mad hand waving> the same semantics"
masak jnthn: I might just put up "Min Liskov e kass" on the door to our office. :P 15:43
colomon on noes, babelfish doesn't do Swedish! 15:45
moritz_ colomon: it's fine for +Mu to fail
jnthn masak: It isn't the classiest of Swedish expressions.
colomon: Google Language does
masak no, it's quite kass.
colomon moritz_: there's actually a test that +Mu should be 0 in the spec tests.
moritz_ CokeBot9000: that doesn't mean it's right :-) 15:46
erm, meant colomon, sorry
colomon I've fudged it for the moment, then. 15:48
masak wonder if it would be possible to write an IRC bot that detected tab completion failures as they happened, with a high accuracy...
15:49 iblechbot joined, riffraff joined
colomon moritz_: and the next issue is another spectest: my $foo = 0; ok $foo == 0 15:50
moritz_ that one should work :-)
colomon I'm very tempted to just say Mu.Numeric { 0; } 15:52
moritz_ Mu is an extraordinary value these days
colomon: want to push your changes to a branch? 15:53
pmurias avar: kp6 stalled when it turned out to be very slow (the bootstraped version was sluggish)
colomon moritz_: will do in a bit. 15:55
jnthn pmurias: huh, that never stalled Rakudo. ;-)
avar :)
diakopter jnthn: XXNSNSNGGG
masak mberends: have you seen cpanminus? it's a wonderful application to be inspired by. miyagawa++
diakopter: are those eyebrows, too? 15:56
diakopter probably
Tene perl6: say (<foo bar baz> >>xx<< (3,4,2)).perl 15:59
p6eval elf 30425: OUTPUT«Undefined subroutine &GLOBAL::xx called at (eval 130) line 3.␤ at ./elf_h line 5881␤»
..rakudo 483a9d: OUTPUT«["foo", "foo", "foo", "bar", "bar", "bar", "bar", "baz", "baz"]␤»
..pugs: OUTPUT«(("foo", "foo", "foo"), ("bar", "bar", "bar", "bar"), ("baz", "baz"))␤»
TimToady masak: testing a patch for 'has enum $.meth <foo bar>' 16:00
masak TimToady: \o/
would that generalize further, to ordinary non-attr variables? 16:01
jnthn uff
TimToady presumably
jnthn TimToady: Does this act like some kind of named enum?
Or just sugar for the anon enum syntax and store the constructed hash in $.meth ?
TimToady haven't decided
jnthn OK 16:02
16:02 jaldhar_ joined
TimToady but perhaps there's an easy way to install a missing orthogonality; perhaps not 16:02
jnthn is glad he didn't get around to much enums stuff in Rakudo 16:03
masak jnthn: the former alternative is the richer one, but perhaps there's some technical difficulty?
jnthn masak: Yeah, I'm kinda not sure how it'd work out implementation wise.
TimToady in any case, $.meth<foo> would get you the enums value as an ordinary hash lookup 16:04
*enum's
masak jnthn: I do hope that named enums are still slated for Rakudo Star, though. :/
jnthn mumble
TimToady I'm thinking that Bool<True> might be the correct way to write that rather than Bool::True
masak 'correct'?
don't both work by the current spec? 16:05
TimToady correcter
masak this *is* Perl we're talking about, right? :P
TimToady: TIMTOWTDI
(oh the irony)
TimToady I'm thinking whether enums really need to imply storage of names in a subpackage
16:06 astrojp joined
masak seems that bare names lend themselves better to static checks. 16:06
TimToady if you know a hash is constant, there's no difference 16:07
masak troo.
TimToady and that's why we distinguish constant from readonly; we know constants at compile time
and enum makes a constant hash
masak so, Bool<True> and True, but not Bool::True ? 16:08
still feels kinda funny.
TimToady if you can tell me why it feels funny, that would be useful :) 16:09
masak I guess because I think of the True as being exported from Bool::True, and now you tell me it doesn't exist anymore.
:)
moritz_ it's inside out
16:10 envi^home left
arnsholt masak: I guess you'll just have to 'Bool::True := True' =) 16:10
masak arnsholt: I'll create a module that gives me Bool::True and all corresponding enum values back :) 16:11
personally, I think Bool::True makes a lot of sense. it's the True constant in the Bool package.
16:15 REPLeffect joined
TimToady I need to work out the policy on second-class imports though 16:17
traditionally, if two enums collide, neither of them works
we could also throw deduced imports into that pot 16:18
er, deduced needs
masak where can I read up on the terms 'second-class import' and 'deduced import'?
TimToady right here
masak great :)
what are they?
TimToady I just explained how enums traditionally work 16:19
masak the none-of-them-works-on-collision. yes. 16:20
it's in S12.
TimToady when we see an unknown name like Sun, we provisionally guess that it means Day<Sun> (or Day::Sun)
I actually first saw that policy in Ada, and thought it was sane
masak *nod*
PerlJam is interested in how the guessing works 16:21
TimToady but if it could mean either Day<Sun> or Star<Sun>, then neither gets it
moritz_ so enum Day <Sun Mon ...> installs a provisional Sun symbol that does the guessing?
TimToady that would be one way to work it
moritz_ and when anything else touches Sun, that guessing goes away?
masak then the Sun blows up!
TimToady or Day advertises it contains second-class names in a CANDO-ish kind of way
the latter might lend itself better to guessing auto-uses 16:22
PerlJam and we query all enums of their CANDOness
?
moritz_ doesn't sound quite straightforward
(Perl 6 isn't straight forward, I know... :)
TimToady so the recent discussion wrt whether Date is in core could use that, perhaps
if you say Date, and it's unambiguous because only the Date module has made its name available provisionally, you get auto-use of Dat 16:23
*Date
but if it's ambiguous, you don't, and the compile blows up
16:23 ab5tract joined
masak for some reason, the prospect doesn't seem as enticing for classes as for enum values... 16:24
TimToady problems with this: only gets you the most recent version
but typenames are also constants of a sort
they're even parsed the same, more or less
PerlJam std: class Sun { ... }; enum Day <Sun Mon>;
16:24 xinming_ joined
p6eval std 30425: OUTPUT«ok 00:01 110m␤» 16:24
PerlJam rakudo: class Sun { ... }; enum Day <Sun Mon>; 16:25
p6eval rakudo 483a9d: ( no output )
TimToady std doesn't check that yet
16:25 REPLeffect left
PerlJam right, but that's my gauge on how much thought you've given things ;) 16:25
TimToady though that might be lhf
in that case, class Sun would take precedence, and you never even see the enum 16:26
moritz_ so Mon wouldn't work either?
TimToady Mon would work, by the usual reckoning 16:27
it's only Sun that collides
and only one of them is second-class, so it just disappears
an argument can be made for treating them all as first class, though 16:28
PerlJam std: package Foo; class Foo { ... }
p6eval std 30425: OUTPUT«===SORRY!===␤Illegal redeclaration of symbol 'Foo' (see line 1) at /tmp/iQtUecrk8E line 1:␤------> package Foo; class Foo⏏ { ... }␤Check failed␤FAILED 00:01 107m␤»
TimToady in a sense, though, we already get second class anything by putting it into an outer lexical scope
PerlJam Everything leans lexical these days, right? enum Foo ... ; makes a lexical Foo ? 16:29
masak ah, so 'second class' means 'shadowable by more real names'? 16:30
TimToady that's part of it
but the 'collisions disappear rather than complaining' is a bit more than that 16:31
if you tried defining conflicting names in an outer scope, either one would win, or you'd get an error
second-class names shadow each other
16:31 cdarroch joined, cdarroch left, cdarroch joined
TimToady which you can't do with lexical nesting 16:31
I'll need to think about this more 16:32
pmurias TimToady: is postcircumfix:<[ ]> lexical?
TimToady all operator macros are lexical 16:33
it's only sort of an accident that the INVOKE method is named with postcircumfix:<( )>
I've been thinking about breaking that for a while now 16:35
it causes lots of confusion when () too many things at too many levels 16:36
foo() is a multi-method dispatch, not an INVOKE, though it turns into IN
one or more INVOKES underneath
possibly with intervening method calls 16:37
dispatchers really call INVOKE, not .()
jnthn ... 16:38
16:38 REPLeffect joined
pmurias is that specced somewhere? 16:38
jnthn Well. I guess we essentially do something like that in Rakudo.
jnthn decides it's close enough :-)
TimToady it might be possible to unify them again, but only if all multis are really INVOKEing the proto first 16:39
which I'm also thinking about hard
jnthn That's decidedly not the way we're doing it in Rakudo.
16:39 IllvilJa joined
jnthn I'm quite skeptical about going that way, fwiw. 16:39
TimToady there's a serious mismatch between how protos work currently
jnthn I'm probably not convinced enough of the value of protos in general. 16:40
TimToady the regex proto is only a cousin to the ordinary proto, and this bothers me
jnthn In Rakudo so far it's only a "nothing else worked" fallback. 16:41
PerlJam cousins should have different names.
jnthn I guess by the spec, any traits declared on the proto are meant to get distributed onto the individual candidates too.
TimToady yes, but you'll notice the flow of that is the opposite direction from use as a fallback 16:42
pmurias TimToady: why does the spec mention method postcircumfix:<[ ]> {...} ?
TimToady I'm thinking use as a fallback is 180° wrong
pmurias * postcircumfix:<( )> {...} ?
TimToady pmurias: because the spec was written by an idiot
jnthn TimToady: :/
TimToady: In that case, maybe the best thing for Rakudo * is to toss support for proto on subs/methods alltogether while we work out the right semantics. 16:43
TimToady in my current thinking, () only ever calls an "only" sub, but some "only" subs happen to be protos that govern a set of candidates and allow multies to be declared in their scope 16:44
PerlJam jnthn: you mean omit from R* or toss now with the intent of having it worked out and implemented for R*?
TimToady that's pretty much how they already work in regexes
pmurias only subs and multis have to have the same interface as it's possible to do my &foo := cond() ?? &some_multi :: &some_sub
jnthn PerlJam: I don't think we have resources to re-work what TimToady is thinking of in time for R*
16:45 _jaldhar_ joined
jnthn *to do the re-work that... 16:45
PerlJam jnthn: okay. Conservativism is best then.
TimToady I don't think we have to rework it for R*, this is just a heads up
jnthn I'm not saying it's inherently wrong or bad; the better unification with protoregexes strikes me as a good thing.
16:45 REPLeffect left
jnthn Just that I don't feel it's something I can sit down and attack in an afternoon. 16:46
TimToady though interestingly, I think this is closer to Dan's original design for multi dispatch 16:47
jnthn Well, the way we have it in Rakudo right now is a kind of double-dispatch anyway.
We vtable_invoke the multi-dispatcher which in turn vtable_invokes the candidate that it chose
But the problem is that there's no Perl 6 level thingy that corresponds to being between the two. 16:48
TimToady basically, we'd say that inside a proto, something like ... means to call the actual mutli dispatcher on the protos candidates
and the point being that the proto that only contains ... can be optimized away eventually
the signature constraint naturally falls out of the call to the proto directly 16:49
jnthn Well, that's the other thing. If this isn't going to give us a bunch of extra cost, we need to know enough at compile time to do that. And that means building a bit more infrastructure that tells us so.
16:49 jaldhar_ left
TimToady it doesn't have to be artificially propagated to the candidates 16:49
jnthn What about traits?
TimToady traits can set dynamic vars for the subcalls
16:49 jaldhar joined
jnthn If I have an "is rw" trait on the proto, what does that imply for the multi candidates? 16:50
TimToady think my $*trait = whatever; inside the body of the proto, before the ...
jnthn Should we apply "is rw" to each of them too?
huh.
But traits are things we apply once at compile time.
TimToady not all traits would have to work the same way
16:50 _jaldhar_ left
jnthn Either we're going to apply those that are on the proto to the multi-candidates too, or we're not going to. 16:51
TimToady different traits can propagate differently, including being copied to multis
or both
jnthn OK, there's a few compiler-handled traits that needs some special treatment, eys.
*yes
TimToady it's not an either/or thing
PerlJam How is the programmer to know which?
jnthn But in general a trait application is a dispatch to a trait_mod routine. 16:52
TimToady why it the programmer to care?
that's encapsulated in the trait
the trait_mod can modify anything it likes
traits have never been specced as well-behaved 16:53
there are just certain conventions
but trait_mods have all the power of BEGIN
since they run at compile time
ruoso TimToady, the "methodicals" thread on p6l seems to ask for a spec on how to override the default method dispatcher... 16:54
TimToady they can rewrite the body of a proto to wrap a my $*VALUE = mumble around the ...
PerlJam I think I'd like to know if a particular trait on the proto is copied to the multis or not
TimToady they can mix in a role if the like
PerlJam: then read the docs :P
anyway, this can all be post R* 16:55
ruoso TimToady, I replied to the thread with some assumptions about that matter taken mostly from IRC discussion, but largely undocumented... it would be nice if you could take a look at that just to see if I'm thinking sideways in the correct axis... 16:56
TimToady ruoso: I'll try, but I have many distractions today 16:57
PerlJam TimToady: IRC tends to do that :) 16:58
16:58 REPLeffect joined
TimToady yes, well, I was planning to start fighting termites before this, sigh... 16:58
later &
jnthn Ooh, yay...I have to meetings this week. I need not worry about fixing my body clock. \o/ 16:59
*no
mberends masak: yes, I'd read the App::cpanminus docs( "Are you on drugs?" ;) and like its design. Definitely inspiring. Almost off-topic Pyrus (PHP's next-gen installer) is also nice: pear.php.net/manual/hu/pyrus.commands.php 17:07
masak not at all off-topic. will look it up. 17:08
colomon moritz_: I just got all tests passing, so instead of making a branch, I'm just going to push it to master. 17:13
moritz_ colomon++ 17:14
17:14 dakkar left
colomon Done. 17:15
jnthn colomon++
moritz_ colomon: remember to commit the spectest changes too, if you have any :-) 17:16
colomon Ha! No spectest changes for this patch, but when I did svn diff I found two changes I should have committed weeks ago. :) 17:17
dalek kudo: 56120b7 | (Solomon Foster)++ | src/ (4 files):
Change prefix:<+> to dispatch to .Numeric for all types which descend from Mu. Define Mu.Numeric to return 0, Cool.Numeric to call the pir function to convert to a Num.
17:20
pugssvn r30426 | colomon++ | [t/spec] Add tests for Fibonacci series starting with 0. (Sounds crazy, but we didn't handle that case properly at one point.) 17:22
17:23 iblechbot left
pugssvn r30427 | colomon++ | [t/spec] Tests for Real.ceiling, Real.floor, Real.truncate, and Real.round. 17:28
masak colomon++ 17:32
17:32 masak left 17:34 ash__ left 17:37 ash_ joined
jnthn -> nomshop 17:38
17:48 [particle] is now known as [particle]_tpf 17:57 smash_ left 18:07 hudnix joined 18:11 ShaneC joined, ShaneC left 18:12 ash_ left, ash_ joined
colomon > say +(4+3i) 18:13
4 + 3i
18:13 ash_ left 18:17 Jedai joined
dalek kudo: 3e3a934 | (Solomon Foster)++ | src/core/Numeric.pm:
Add Numeric.Numeric.
18:17
pugssvn r30428 | colomon++ | [t/spec] Simple tests for prefix:<+> on Rat and Complex. 18:18
dalek kudo: 1f638cc | moritz++ | docs/ChangeLog:
[docs] another ChangeLog entry
18:23
kudo: e329a94 | moritz++ | src/core/Date.pm:
[Date] move private subs inside the class
18:30 ramf joined 18:31 [particle]_tpf is now known as tpf|[particle] 18:40 _jaldhar joined, gurjeet joined 18:43 jaldhar left 19:02 ramf left
pmichaud colomon: ping 19:18
colomon pong
pmichaud why a Mu.Numeric? I still think that's wrongish 19:19
moritz_ too
colomon We have spectests that assume Mu.Numeric and Any.Numeric return 0.
pmichaud then I think those tests are wrong. 19:20
colomon Apparently Any() definitely should return 0.
moritz_ Mu.Numeric == 0 is certainly wrong
that makes more sense, yes
colomon I'm agnostic about Mu.
pmichaud why should Any() return 0?
colomon my $foo; $foo == 0
moritz_ pmichaud: so that my $x; $x == 0; returns true
pmichaud that should act like a failure
and the failure object should return 0. 19:21
i.e., it's not Any that returns 0, but the protoobject.
(because it's undefined)
19:21 cdarroch left
pmichaud basically it's a "use of uninitialized value..." 19:21
colomon so something like 19:22
fail "use of uninitialized value"
pmichaud that's better, but I basically disagree that all objects should have a Numeric() method defined.
that's.... wrong. 19:23
and it's certainly wrong that class XYZ { ... }; say +XYZ.new; # 0 is wrong.
jnthn pmichaud: I guess the real answer is that it should be a method Numeric(Any:U :) { 0 }
pmichaud jnthn: except it should be a failure, not an integer. 19:24
jnthn That is, only on (undefined) proto-objects.
pmichaud: Ah, OK
pmichaud it's a use of an uninitialized value.
jnthn pmichaud: Yes, agree.
19:24 cdarroch joined, cdarroch left, cdarroch joined
pmichaud which should return a failure, which should throw an exception unless it's "handled" first. 19:24
jnthn pmichaud: Sorry, was being too focused on the signature. :-)
19:24 pjcj joined
jnthn method Numeric(Any:U :) { fail 'Use of uninitialized value in numeric context' } or some such. 19:25
colomon I certainly have no stake in Mu or Any .Numeric, just trying to update what the Numeric types do without breaking existing functionality.
pmichaud in the meantime, if you wish to do 19:26
method Numeric() { $.defined ?? (die "Can't take numeric value") !! fail "Use of uninitalized value" } 19:27
or something like that, I'd feel better.
colomon On Any or Mu?
moritz_ Any 19:28
pmichaud well, what would we expect from
CokeBot9000 (.Muneric)
pmichaud my Mu $x; say $x == 0;
moritz_ die
19:28 pyrimidine joined
jnthn OTOH, things like .list do live in Mu, or at least iirc. 19:28
pmichaud hmmm, I'm still thinking of .list living in Any 19:29
jnthn Ah, OK
pmichaud I guess it could go in Mu. Still have to work that out (this weekend, hopefully)
jnthn I don't feel strongly either way.
I would prefer that they're all consistently in one or the other though.
pmichaud I'm not sure they can be.
There's different expected behaviors for each, so it makes sense for them to be in different places.
put another way, "consistently in one or the other" might be a false (foolish?) consistency :) 19:30
jnthn Maybe.
pmichaud I'm fine with it going for Any for now. It's easily moved.
jnthn Maybe I'll be happier if I distinguish structural contexts from value ones. :-)
pmichaud oh, wait. 19:31
nm. Any is fine.
jnthn (that is, .list, .item and .hash should live together, and .Numeric, .String, etc also should, and I'd like to see the two groups of 'em together)
pmichaud I agree that .list, .item, .hash belong in similar places.
jnthn That is, it'd not feel weird if .list and .Numeric were in different places, but it'd feel odd to me if .list and .item were, or .Numeric and .Stringy were. 19:32
pmichaud I agree that .Numeric, .String belong in similar places.
I'm not sure it's all the same place :)
jnthn OK
pmichaud (we're agreeing :)
jnthn Yes. :-)
colomon fair enough.
jnthn My initial discomfort was a little too broad. :-)
colomon and I just put .Numeric next to .Str in Any.
:)
pmichaud somehow I'm comforted to hear you say that. :-)
Should be .Stringy, yes? ;-) 19:33
I mean, if you want to fix them.... :)
colomon I think redoing the Numeric world is enough for me today.... ;)
pmichaud and the world is better off for it.
jnthn I think it's .Stringy rather than .String.
pmichaud However, the AnonymousMonks of the world will totally unappreciate you for it. :)
colomon considers how much $work he has to do, and reckons avoiding changing Str to Stringy this week is a Good Thing. 19:34
pmichaud sure, .Stringy can wait.
colomon sure, if we weren't all lazy we'd just have a couple of 24 hour hacking sessions and finish Rakudo.
jnthn should probably use his Perl 6 time today to continue worrying about multis and roles and the like.
colomon should probably be using his remaining time today to hack in C++. :( 19:35
19:36 ash_ joined
colomon > my $x; say $x == 0 19:36
Use of uninitalized value
jnthn Wait, is that an exception?
moritz_ in numeric context
jnthn I *think* it should just warn...
Granted fail won't give that semantic. D'oh.
moritz_ aye
ash_ rakudo: my $x; say $x == 0;
p6eval rakudo 1f638c: OUTPUT«1␤»
19:37 m6locks left
jnthn Aye, I expect the 1 + a warning. 19:37
colomon my $x; say +$x
doesn't return anything at all -- say just silently fails.
jnthn Oh. 19:38
19:39 iblechbot joined, pyrimidine is now known as openbio|pyrimidi, ohhai joined
colomon Is there a way to get a graceful exception? 19:39
19:40 finanalyst joined
jnthn I can't immediately thing of how you construct a lazily-thrown warning in Perl 6. 19:42
*think
moritz_ but it's better to omit the warning than to fail
from an early adopters point of view 19:43
jnthn Well, there's always a cheat
Which is instead of to "fail" then call "warn" then evaluate to 0 19:44
19:44 wasy joined
jnthn (always die in the case $.defined is treu though) 19:44
pmichaud alpha had a Failure object, it would return a numeric value of 0 but also issued a warning when it wasn't handled 19:45
19:45 ohhai left
pmichaud because 19:45
my $x; $x.defined; say +$x; # no warning. 19:46
jnthn Ah
That's far righter
pmichaud++
19:46 wasy left
pmichaud which points to the fact that $x *cannot* simply be Any. 19:46
my $y; say +$y; # warning 19:47
my $x; $x.defined; say +$x; # no warning
unless using .defined on protoobjects doesn't have the same semantics as it would for failure objects
19:47 sundar joined
pmichaud which I suppose is entirely possible. 19:47
I guess it would make sense if +Any always threw a warning. 19:48
i.e., using .Numeric on a protoobject might always generate the warning
(and then return 0)
colomon wait, you guys just completely lost me there. 19:49
jnthn pmichaud: I disagree with:
my $x; $x.defined; say +$x; # no warning
pmichaud jnthn: okay, works for me. 19:50
jnthn pmichaud: I would however exepct:
pmichaud in other words, protoobjects always warn when used, and don't act like Failures in this respect
jnthn my $x; my $y = +$x; $y.defined; say $y; # no warning
pmichaud I expect the +$x to give a warning.
It's "use of an uninitialized value." 19:51
jnthn Ah, OK
I guess I'd expected my $y = +$x; to mean that $y is now a Failure
pmichaud No
I'd expect $y to still be a 0 at this point.
Because $y *is* initialized. 19:52
jnthn In the case of:
ash_ my $x; my $y = +$x; # warning?
jnthn my $x; my $y = +$x;
Which step do we get the warning emitted?
pmichaud at the point of attempting to take the numeric value of $x.
ash_ i'd expect a use of uninitialized variable at y =
(personally)
pmichaud the difference is something like this: 19:53
sub foo() { fail "Bzzt"; }; my $y = foo(); say $y; # warns
jnthn OK, so it's *different* to that case. 19:54
OK.
pmichaud sub foo() { fail "Bzzt"; }; my $y = foo(); $y.defined; say $y; # no warn
i.e., the thing that fail() returns is a Failure object, which has the magic .Bool/.defined behavior on it
but protoobjects always warn.
(when used as values) 19:55
jnthn *nod*
OK, agree.
pmichaud colomon: still lost?
colomon pmichaud: less so. but I've no idea how to implement what you guys are talking about now... 19:56
pmichaud colomon: just a sec
pugssvn r30429 | lwall++ | [STD] allow enum names to be variables so that an enum can have an accessor
pmichaud method Numeric() { $.defined or warn "Use of undefined value in numeric context"; 0;
}
ash_ whats the difference between that $.defined and doing my $x; $x.defined ? 19:57
pmichaud or, more likely
method Numeric() { die "Numeric not implemented for $.WHAT()" if $.defined; warn "..."; 0; } 19:58
ash: $.defined is the same as self.defined
jnthn: what's blocking implementation of :U and :D again? 19:59
ash_ but... why does my $x; $x.defined; say +$x; not warn then?
moritz_ ash_: it does
pmichaud ash_: because $x is a protoobject (Any)
colomon pmichaud: my only problem there is that I've been trying to make different versions of that work while you and jnthn have been talking, and so far none of them do.
pmichaud and it does warn.
ash_ oh
okay, i was confused on that bit
pmichaud (i.e., I have to retract what I claimed earlier... sorry about that)
TimToady phone
jnthn pmichaud: Nothing is *really* blocking it in a sense. 20:00
colomon warn "..." followed by 0 doesn't seem to actually return the 0.
20:00 lichtkind joined
colomon > my $x; say +$x 20:00
Use of uninitalized value
jnthn pmichaud: Mostly I didn't immediately know the clean way to extract the adverb after the type name.
colomon no zero.
pmichaud jnthn: I don't think it's an adverb, technically.
It looks to me more like a longname. 20:01
jnthn pmichaud: It is
pmichaud checks STD.pm6
jnthn pmichaud: Let me say it better
lichtkind pmichaud: hej wb
moritz_ colomon: maybe note() instead of warn (as another evil hack)
jnthn pmichaud: I don't know what the general meaning of those colonpairs after a longname are.
pmichaud colomon: I'm fine if we just print something to $*ERR for now, then.
$*ERR.say("Use of undefined value ..."); 0; 20:02
colomon trying note at the moment.
PerlJam jnthn: glad it's not just me :)
20:02 takadonet joined, takadonet left
moritz_ note is basically $*ERR.say() 20:03
pmichaud jnthn: I think it depends on the longname
jnthn pmichaud: That is, I wanted to work out something general, rather than a hack.
pmichaud: Ah.
20:03 takadonet joined
pmichaud jnthn: but I'll look at STD's parsing and see if I can tease anything out 20:03
jnthn pmichaud: Suggestions welcome.
pmichaud: I'm open to Just Making It Work, but I wanted to at least try and get a sense of a good approach first. :-) 20:04
20:04 m6locks joined, hghgd_ joined 20:05 Cristina_ left
colomon > my $a; say +$a 20:05
Use of uninitalized value
0
jnthn \o/ 20:06
20:06 Spreadsheet_ joined
jnthn colomon: Maybe add "in numeric context" 20:06
moritz_ s\o/ccess
colomon > class Tree { has $.leaf; }; my $x = Tree.new; say +$x
Can't take numeric value for Tree()
moritz_ s/for/of/ maybe? 20:07
20:07 CokeBot9000 left, CokeBot9000 joined
colomon does it make sense to have Tree() instead of Tree there? This is the case where Tree is defined... 20:07
moritz_ "for object of type Tree" 20:08
jnthn Yeah, that's quite nice
.WHAT.perl gets it without the ()
colomon er? 20:10
rakudo: say 5.WHAT 20:11
p6eval rakudo 1f638c: OUTPUT«Int()␤»
20:11 CokeBot9000 is now known as TPF-Coke, masak joined
colomon rakudo: my $a = 5/4; say "hello $a.WHAT.perl" 20:11
20:11 TPF-Coke is now known as TPF|Coke
p6eval rakudo 1f638c: OUTPUT«hello 1.25.WHAT.perl␤» 20:11
colomon rakudo: my $a = 5/4; say "hello $a.WHAT" 20:12
p6eval rakudo 1f638c: OUTPUT«hello 1.25.WHAT␤»
masak ahojte, alle Lambda-Leute!
colomon: you need parens at the end.
jnthn Language Score: 3
masak++
colomon rakudo: my $a = 5/4; say "hello $a.WHAT.perl()"
p6eval rakudo 1f638c: OUTPUT«hello Rat␤»
20:13 user2387153 joined
pugssvn r30430 | moritz++ | [t/spec] test that subset type checks perform the nominal type check first 20:14
Spreadsheet_ Are there any Perl interactive prompts?
moritz_ rakudo has one, but it's not quite awesome yet 20:15
masak Spreadsheet_: if you just type 'perl6', you get one.
Spreadsheet_ masak: thanks
masak it's still suffering from 'every line is its own block' disease.
which makes it less useful.
Spreadsheet_ I only have Perl 5 so I don't know about Perl6 20:16
I have some suggestions for a possible Perl6 prompt
masak great!
Spreadsheet_ Or prompts in general, I'm going to paste it
masak let's hear them.
nopaste it.
(see /topic)
Spreadsheet_ still has to write it, but has thought of most of it at school
masak we like hearing suggestions. sometimes we like realizing them as well :) 20:17
Spreadsheet_ I mean write the suggestion, I have no coding ability :(
moritz_ that you can learn :-)
masak I might implement a REPL for Yapsi at some point, but I haven't really tried to figure out how to use ReadLine from Rakudo. 20:18
moritz_ rakudo: "foo\123bar" 20:19
p6eval rakudo 1f638c: OUTPUT«Unrecognized backslash sequence: '\1' at line 11, near "23bar\""␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
20:20 _buno_ joined
moritz_ rakudo: use Test; plan 1; eval_dies_ok q{"\123"}, '"\123" is now illegal'; 20:21
p6eval rakudo 1f638c: OUTPUT«1..1␤ok 1 - "\123" is now illegal␤»
moritz_ rakudo: use Test; plan 1; eval_dies_ok q{"\023"}, '"\023" is now illegal';
p6eval rakudo 1f638c: OUTPUT«1..1␤not ok 1 - "\023" is now illegal␤# Looks like you failed 1 tests of 1␤»
masak test development on-channel :) moritz_++ 20:22
moritz_ std: "\023"
p6eval std 30428: OUTPUT«ok 00:01 109m␤»
jnthn moritz_: \0 is a valid escape sequence.
For NULL
masak yeah.
we realized that the other week :)
moritz_ that explains why the tests fail
masak Rakudo++
moritz_ rakudo: say "\040".perl 20:23
p6eval rakudo 1f638c: OUTPUT«"\x[0]40"␤»
jnthn \0NOES
pugssvn r30431 | moritz++ | [t/spec] \0 is a valid escape sequence 20:24
20:27 openbio|pyrimidi is now known as pyrimidine
masak Spreadsheet_: Pugs has a decent REPL, if I recall correctly. 20:27
20:28 hghgd joined
moritz_ masak: you do 20:28
jnthn It even had pretty ascii art at startup. :-)
And beat the Rakudo one in other aspects. 20:29
*beats 20:30
masak I blame the Haskell. it's just so magical and awesome.
jnthn looks forward to Rakudo having a good one. :-)
jnthn builds Rakudo with paste.lisp.org/display/98066 to find out how it explodes
diakopter Haskell is the terrorist of programming languages
masak and Parsec. Parsec was allegedly a big reason Pugs could grow so fast so quickly. 20:31
pugssvn r30432 | moritz++ | [t/spec] test for RT #67932
20:31 finanalyst left 20:32 hghgd_ left, kensanata joined 20:33 kfo_ joined
pmichaud ...are we adding .abs to Numeric? If so, why? 20:33
masak I've been picking up GGE this evening. trying to get grammars to work.
pmichaud I figured .abs belonged in Cool, and that's about it.
20:33 mariano__ left
jnthn pmichaud: fwiw, I'm investigating why it makes the role composer explode. 20:34
pmichaud: Rather than planning to apply it.
pmichaud okay, that's fine with me.
jnthn pmichaud: Though I think colomon++ may have been planning to apply it once I fix that bug.
So perhaps still a good question anyway. :-)
masak pmichaud: .abs is spec'd as a method on Numeric, returning a Numeric. 20:35
moritz_ pmichaud: because the spec says .abs should be in Numeric
pmichaud that feels wrongish to me.
masak rakudo: say Complex ~~ Numeric
p6eval rakudo 1f638c: OUTPUT«1␤»
pmichaud I guess I need to refresh my memory on what Numeric represents. 20:36
20:36 kfo_ is now known as kfo
masak S02: "For instance all the numeric types perform the C<Numeric> role [...]" 20:37
pmichaud sure, but that doesn't mean that all of the numeric methods belong there.
especially if they're just going to say "you need to overload this"
masak *nod*
20:39 pyrimidine left
pugssvn r30433 | moritz++ | [t/spec] calling a non-existing sub in a namespace should mention that sub in the error message 20:40
moritz_ it took me quite some time to find the appropriate test file for this test 20:41
lisppaste3 Spreadsheet pasted "Interactive Perl suggestion" at paste.lisp.org/display/98106 20:44
masak looks 20:45
20:45 mariano__ joined
masak Spreadsheet_: I fully agree. 20:46
and I've been advocating that line for over a year :)
see the first part of use.perl.org/~masak/journal/38279
Spreadsheet_: admittedly, your proposal is more detailed. I'd really like to see something like that for Perl 6. 20:47
pmichaud So would I. I hope someone who knows more about editors than I can implement it. :)
Spreadsheet_ oo my bad 20:48
pmichaud I know how to do grammars and regexes and compilers. Interactive editing is well out of my comfort zone at the moment.
Spreadsheet_ hehe the line 2 of broken.p6 does have a semicolon
pmichaud (and the few times I tried writing an editor many many many years ago, I failed miserably)
ash_ pmichaud: is anyone working on the interactive terminal?
pmichaud s/failed miserably/gave up and said "not worth the trouble"
moritz_ pmichaud: well, start with the RPL part, then :-)
pmichaud ash_: I plan to fix the REPL so that it remembers lexical declarations from one line to the next 20:49
masak \o/
pmichaud I *might* be able to fix it so that it detects "oh, you're in the middle of a block, I'll grab more input until you're done"
masak Spreadsheet_: yes, variable names can have numbers in them.
Spreadsheet_: they can also have dashes and apostrophes in Perl 6.
rurban I tried to add a readline repl to scsh (scheme shell) and found out that it's very hard to do. with the perl5 Readline lib it's easier. see perl5db.pl 20:50
pmichaud I'm definitely not planning to do "hit the up-arrow a couple of times and you get a full-screen editor display of your function". Someone else gets to do that part.
jnthn pmichaud: fwiw, I think STD has some hook for getting more input.
pmichaud Rakudo already has a readline repl. The tricky part is handling declarations.
jnthn pmichaud: May be a place to take inspiration.
pmichaud jnthn: yes, I've seen it.
jnthn OK, cool. 20:51
masak pmichaud: in which file does Rakudo pull in readline? I guess somewhere in PCT, yes?
ash_ how hard would it be to keep a buffer of the output, then with like double up arrow you pipe it into env EDITOR or something?
pmichaud what would be really useful is to see if STD actually made use of that hook interactively (perhaps it does already and I just haven't noticed?)
ash_ then on close of that, evaluate and start where you left off?
pmichaud masak: readline is Parrot core
rurban one trick is to add run-time declared subs and types to the completion table 20:52
TPF|Coke Spreadsheet_: rakudo's repl already has readline. no?
pmichaud masak: it's built into the I/O PMCs already
masak pmichaud: yes, I know. my line of questioning will lead up to 'can I use it in my Perl 6 program in Rakudo'.
ash_ yeah, it will use readline if you have it
if the up arrow works for you, it has readline
Spreadsheet_ TPF|Coke: if it does, then good, because no one likes seeing ^[[D when they press <
pmichaud masak: I don't see why one couldn't use it in a Rakudo program; we just need to define the appropriate classes and methods for it 20:53
Spreadsheet_ That is what it does right?
TPF|Coke I definitely want the ability to add some of those customizations for partcl.
masak pmichaud: ok, that sounds promising.
pmichaud masak: I can probably write a proof-of-concept
masak \o/
++pmichaud
pmichaud builds rakudo trunk to see if he can prove that readline works. 20:54
moritz_ works here
(the built-in one)
pmichaud moritz_: from P6?
masak Spreadsheet_: anyway, good work. it's proposals like that that fuel good work around here.
moritz_ pmichaud: nope
pmichaud oh.
20:55 hudnix left
rurban my $<tab> => files 20:55
20:55 gbacon left
pmichaud searches for #perl6 discussions on .Numeric 20:55
rurban su<tab> => subs starting with su not files
masak or types. or enum values. 20:56
or constants.
rurban or hashes and classes, ...
masak or builtins.
rurban clisp has all this 20:57
pmichaud I really wish the perlgeek.de search knew how to include punctuation
moritz_ hides
rurban clisp even detects if you want a file or string completion
(inside a string)
moritz_ so... it can read minds? 20:58
ash_ is there a place we can write about the features that could be useful for REPL? so we don't forget? or can figure out a prioirty on them so we know which ones are more or less important?
masak Perl 5's $\ has been replaced by $*OUT.output-line-separator, yes? 20:59
pmichaud the priority is going to be set by whoever implements them. Almost any other form of priority is probably not useful. :-)
moritz_ std: $\
p6eval std 30433: OUTPUT«===SORRY!===␤Unsupported use of $\ variable; in Perl 6 please use the filehandle's :ors attribute at /tmp/gwgEmpUNbp line 1:␤------> $\⏏<EOL>␤Parse failed␤FAILED 00:01 109m␤»
jnthn rakudo: $\
p6eval rakudo 1f638c: OUTPUT«Confused at line 11, near "$\\"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
masak ash_: you could write a blog post about it.
jnthn aww 21:00
moritz_ it's one of those I haven't ported, it seems
masak :ors?
21:00 ReiniUrban joined
moritz_ output-record-separator 21:00
masak yesyes.
but
ReiniUrban But I think a string starting with a / also triggers pathname completion
ash_ true, then i could try implementing it too, if i am feeling special, but i am a bit busy... so i probably wouldn't get a chance till school ends for the summer
moritz_ rakudo: $\
p6eval rakudo 1f638c: OUTPUT«Confused at line 11, near "$\\"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
masak moritz_: I don't see an 'ors' attribute in the spec. 21:01
moritz_ it's there in src/Perl6/Grammar.pm line 673 (detection of $\)
masak I'm sure it is.
I'm just pointing out the mis-alignment between STD.pm6 and the spec.
S32/IO talks about an output-line-separator method. 21:02
moritz_ s/the spec/the rest of the spec/ :-)
21:02 rurban left, ReiniUrban is now known as rurban
masak right. the synopses. 21:02
21:02 TPF|Coke is now known as CokeBot9001, CokeBot9001 is now known as CokeBot9000, cotto_work joined
pmichaud note that TimToady++ has commented in the past that STD.pm is also "spec" :-) 21:03
(which is what moritz_++'s comment indicates :)
masak yes.
in that case, I call spec self-contradiction.
pmichaud indeed. We should resolve it.
masak I was thinking about how to port the first example of www.catonmat.net/blog/perl-one-line...-part-one/ to Perl 6. 21:04
thinking about it, I'd rather write $*OUT.ors than $*OUT.output-line-separator :P
moritz_ pmichaud: re editor in REPL, the most promising feature would be to shell out to $EDITOR
masak both are much longer than $\, but one is absurdly longer. 21:05
moritz_ pmichaud: because everybody has their favorite one, and doesn't like any variation of it
pmichaud moritz_: kind of like shells do, then?
moritz_ pmichaud: yes
no idea if that's actually a good idea in the long run...
pmichaud moritz_: I'm in favor of that. I hope someone implements it. :) :)
masak 'night. 21:06
21:06 masak left
jnthn going to read for a bit, then more hacking 21:06
colomon: Got a fix for the role bug you were hitting when trying to pop abs in Numeric. 21:07
rakudo: my $x = 42 but role { method omg { say 'lol' } }; say $x; say $x.omg
p6eval rakudo 1f638c: OUTPUT«42␤lol␤1␤»
jnthn \o/
arnsholt Kewl. 21:08
jnthn Going to read for a bit, and then will try and fix the stuff that keeps us from passing S14-role/anonymous.t, even though the above works.
dalek kudo: fadb800 | moritz++ | (2 files):
make reduce() a bit more usable, and test it
21:09
pmichaud our multi reduce(&op, $list) { $list.reduce(&op) 21:10
}
looks wrong to me
the one moritz_++ looks correct (and should probably be the only one) 21:11
*moritz_++ did
moritz_ pmichaud: istr it's needed for the meta ops because some of the iterators don't do Positional yet 21:12
but I agree that it's probably wrong
pmichaud okay. If possible, I prefer that known probably wrong things go in src/cheats/ somewhere.
so maybe src/cheats/metaops.pm 21:13
dalek kudo: 205d9d3 | moritz++ | src/Perl6/Grammar.pm:
properly carp on $\ usage
21:15
moritz_ -> bed
CokeBot9000 there's a readline standard for exiting out to your editor already, no? 21:19
pmichaud to me, the hard part is knowing what to send to the editor. 21:20
CokeBot9000 current line so far?
pmichaud well, if you're going to an editor, usually you want more than just the current line 21:21
i.e., you want the current sub or block or class or something like that
colomon jnthn: \o/ 21:22
21:22 wknight8111 joined, kensanata left 21:23 riffraff left, molaf left 21:25 gurjeet left, gbacon joined
sundar pmichaud: do you mean multiple lines may have been input at the REPL and they might all need to be passed? Is multiple line input going to be supported? 21:25
pmichaud sundar: yes, I'd hope so 21:26
sundar: so one can do
21:26 _buno_ left
pmichaud > sub foo() { 21:26
> ...
> }
pugssvn r30434 | colomon++ | [t/spec] Remove +Mu == 0 test. 21:27
pmichaud that's certainly implied by Spreadsheet_++'s nopaste, if I'm reading it correctly.
Spreadsheet_ Hmm, what?
lisppaste3 pmichaud pasted "readline in p6, for masak" at paste.lisp.org/display/98110 21:28
pmichaud phenny: tell masak readline in p6 at paste.lisp.org/+23PA 21:29
argh.
phenny: tell masak readline in p6 at paste.lisp.org/+23PA
21:29 mariano__ left
pmichaud enophenny? 21:29
diakopter phenny no workie
not for a week at least? 21:30
I think.
sbp oh, sorry 21:32
21:32 phenny joined
sbp dunno what happened there! 21:32
pugssvn r30435 | mberends++ | [spec/S32-temporal/DateTime.t] renamed from Temporal.t, add 2 strftime tests 21:35
21:42 snarkyboojum joined
diakopter phenny: tell pmurias this is quite interesting to me. research.microsoft.com/pubs/121449/...eport2.pdf particularly: 21:42
phenny diakopter: I'll pass that on when pmurias is around.
diakopter phenny: tell pmurias ... As Figure 1 shows, we actually have both X86 and CIL versions of the Bartok runtime code and the JavaScript runtime code available at runtime. Having the CIL form may seem unnecessary at first as we can just call directly into the X86 form. 21:43
phenny diakopter: I'll pass that on when pmurias is around.
diakopter phenny: tell pmurias ... However, in order to optimize traces that span calls into the runtime, we use the CIL of runtime methods and dynamically compile them into a form that contains profiling counters or callbacks to our trace recorder. 21:44
phenny diakopter: I'll pass that on when pmurias is around.
diakopter phenny: tell pmurias ... This way, the recorded trace contains CIL instructions of any inlined runtime methods along with CIL instructions from compiled JavaScript code.
phenny diakopter: I'll pass that on when pmurias is around.
diakopter phenny: tell pmurias ... This is crucial in order to optimize traces that span runtime code, in particular for the JavaScript runtime, as its methods contain most of the specialization opportunities.
phenny diakopter: I'll pass that on when pmurias is around. I'll have to use a pastebin, though, so your message may get lost.
diakopter heh
szabgab moritz_, do you already know if you'll be able to attend LinuxTag Berlin?
diakopter moritz_ went to sleep I think
szabgab it is not even midnight for him :-) 21:45
but then maybe I should too...
diakopter wth 21:49
pugssvn r30436 | mberends++ | [t/spec/S32-temporal/Temporal.t] really remove, it is now called DateTime.t 21:57
dalek kudo: 2a93f45 | (Martin Berends)++ | (2 files):
[core/Temporal.pm] add a fairly large subset of strftime() and some tests for it
22:06
kudo: c778995 | (Solomon Foster)++ | src/core/ (2 files):
Remove Mu.Numeric. Add Any.Numeric, and make it both pickier and more informative.
pmurias diakopter: the paper seems interesting, i'll read it tommorow 22:09
phenny pmurias: 21:42Z <diakopter> tell pmurias this is quite interesting to me. research.microsoft.com/pubs/121449/...eport2.pdf particularly:
pmurias: 21:43Z <diakopter> tell pmurias ... As Figure 1 shows, we actually have both X86 and CIL versions of the Bartok runtime code and the JavaScript runtime code available at runtime. Having the CIL form may seem unnecessary at first as we can just call directly into the X86 form.
pmurias: 21:44Z <diakopter> tell pmurias ... However, in order to optimize traces that span calls into the runtime, we use the CIL of runtime methods and dynamically compile them into a form that contains profiling counters or callbacks to our trace recorder.
pmurias: 21:44Z <diakopter> tell pmurias ... This way, the recorded trace contains CIL instructions of any inlined runtime methods along with CIL instructions from compiled JavaScript code.
[Sorry, some messages were elided and lost...]
22:15 astrojp left 22:19 hercynium joined
lichtkind mberends: hai 22:20
mberends lichtkind: rehai
diakopter jae 22:21
lichtkind :)
mberends 'k
lichtkind mberends: whazzup buddy?
22:21 nihiliad joined
mberends lichtkind: making progress on DateTime and proto 22:22
sundar Where does rakudo read parrot's current revision number from?
22:24 iblechbot left
mberends rakudo: %*VM<config><revision>.say 22:25
p6eval rakudo 205d9d: OUTPUT«45822␤»
22:25 ive left
avar rakudo %*ENV<shell> 22:28
rakudo: %*ENV<SHELL>
p6eval rakudo 205d9d: ( no output )
mberends rakudo: %*ENV<SHELL>.say 22:29
p6eval rakudo 205d9d: OUTPUT«/bin/bash␤»
lue Hello there! 22:30
mberends hellue there!
jnthn back
sundar mberends: thanks.. but I phrased my question dumbly. What I wanted to know was, where does rakudo's Configure.pl read the existing parrot's revision number from? does it use svn info or something else? 22:33
22:33 pmurias left
mberends sundar: it runs parrot_install/bin/parrot_config 22:34
dalek kudo: 0b67c52 | jonathan++ | src/metamodel/RoleToRoleApplier.nqp:
Should check definedness rather than truth when looking if a method exists in the role composer; this is because .Bool method may not be defined so early in the bootstrap in places we'd want it to be, so we exploded if roles were used in a certain way in the setting.
22:35
jnthn Another cut with the circularity saw. :-)
22:35 ash_ left 22:36 lest_away is now known as lestrrat
lue your startup grammar talk hertz my brain /o\ 22:37
jnthn Mine too. ;-)
lue ah, you're checking if it exists rather than how good its character is. 22:38
22:40 ShaneC joined, ShaneC left 22:42 krakan joined 22:44 meppl joined 22:50 Kyril joined
jnthn lue: Yes. :-) 22:51
lue rakudo: 51-38 22:59
p6eval rakudo c77899: ( no output )
lue rakudo: say 51-38
p6eval rakudo c77899: OUTPUT«13␤»
lue you're 13 minutes late :)
jnthn jnthn is never late. He replies exactly when he intends. :-) 23:02
23:10 snarkyboojum left
lue wonders if A0 is what all the cool posters are printed on 23:11
23:12 user2387153 left
jnthn No, just the big ones. 23:13
sorear CokeBot9000: 10 years of Parrot? Where?
lue I'm just wondering what most posters (i.e. seen in school halls) are sized. ~1m each side seems a bit huge 23:15
23:15 orafu joined
CokeBot9000 sorear: I was rounding for effect. the project's been around since 2001. 23:16
runtime/parrot/library/SQLite3.pir 23:17
lue it's only an off-by-one error :)
CokeBot9000 bah.
runtime/parrot/library/SQLite3.pir
bah!
8/29/01 23:18
mberends rakudo: DateTime.now.strftime("It is now %k.%M%p on %A").say 23:22
p6eval rakudo 0b67c5: OUTPUT«It is now 23.06pm on Wednesday␤»
sorear finishes backlog
CokeBot9000 just thought that might offer some insight into why parrot may appear more conservative than rakudo.
23:22 sundar left
jnthn is 2 tests of passing all of S14-role/anonymous.t :-) 23:26
*off
lue .u hand 23:29
phenny U+270C VICTORY HAND (✌)
CokeBot9000 .u degree 23:30
phenny U+00B0 DEGREE SIGN (°)
CokeBot9000 yay.
23:35 awwaiid joined 23:36 ingy joined, awwaiid left, awwaiid joined
sorear wonders what ruoso is trying to accomplish 23:40
colomon jnthn: \o/ 23:41
jnthn colomon: I've got it working but...we get intermittent failures. I've a good idea why though.
colomon jnthn++ 23:42
30837 passing tests here, wonder if we can squeeze out another 163 by release tomorrow...
which reminds me, what was that test with .Numeric that you had to fudge the other day?
jnthn erm 23:43
something entirely unrelated to Numeric
jnthn tries to remember
colomon methods.t ?
jnthn Oh
colomon anonymous.t
jnthn S12-methods/multi.t iirc.
Oh
or S12-class/anonymous.t more likely.
Yes, the last I think.
23:44 rgrau left
jnthn Was Numeric and Stringy. 23:44
pugssvn r30437 | colomon++ | [t/spec] Unfudge .Numeric test that now works.
jnthn But you can probably unfudge part of it with Numeric.
pugssvn r30438 | colomon++ | [t/spec] Unfudge .Numeric test that now works. 23:46
colomon both anonymous.t and methods.t had one. :)
two down, 161 to go. ;)
23:46 gurjeet joined
colomon afk # pub 23:47
23:51 rv2733 left 23:56 mberends left 23:58 clintongormley left