Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2009-10-04

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
17:32 ilbot2 joined #perl6
17:32 Topic for #perl6is now »ö« | http://perl6.org/ | nopaste: http://paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo: / pugs: / std: | irclog: http://irc.pugscode.org/ | UTF-8 is our friend!
17:33 * moritz_ bemoans a lack of IRC logs over the weekend
17:33 colomon it was pretty quiet over the weekend.
17:34 colomon though lanny wrote a nice function to convert a Num to a Rat.
17:34 colomon diakopter did a bunch of cool stuff, as per normal lately.
17:35 * moritz_ runs his 'update-stuff' script that updates about 15 repositories ;-)
17:35 moritz_ I see that perl-5.11.0 wwas released - obra++
17:35 masak obra++
17:36 moritz_ masak++ the dot sigil
17:37 diakopter moritz_: can ilbot2 import from irssi logs?
17:37 moritz_ diakopter: no
17:37 diakopter sad
17:37 moritz_ I've written a script, but sadly some of the display logic depends on monotonic primary keys
17:37 moritz_ and importing older stuff would break that
17:38 zloyrusskiy joined #perl6
17:38 absurddoctor joined #perl6
17:45 kcwu joined #perl6
17:46 absurddo1tor joined #perl6
17:53 tak11 joined #perl6
17:59 Chillance joined #perl6
17:59 moritz_ mildew-js: say 3, 4
17:59 p6eval mildew-js: OUTPUT«execute(): execute error: ReferenceError: P6Int is not defined at mildew line 336.␤»
17:59 moritz_ mildew-js: say '3'
17:59 p6eval mildew-js: OUTPUT«3␤»
18:06 FOAD_ joined #perl6
18:11 colomon moritz_: so when do we start implementing Numeric?  ;)
18:12 moritz_ colomon: ;-)
18:13 moritz_ colomon: let's wait some more until the bikeshedding has settled
18:14 masak so Numeric is the big all-encompassing role, yes?
18:15 moritz_ yes
18:16 moritz_ do we still have an 'Ordered' role?
18:16 moritz_ the only mentin is in S02:1073:    Range       A pair of Ordered endpoints
18:16 moritz_ which might just as well be a typo
18:18 colomon moritz_: I suppose I should learn how to use Roles first anyway.  :)
18:19 moritz_ colomon: in this case roles aren't scary - if you know Java's interfaces, you have a very good idea of what happens
18:19 moritz_ except that roles can contain implementation too
18:20 masak there's an Order enum.
18:21 colomon moritz_: I have never programmed in Java, but I've read the C# specs for interfaces.  And I've used C++ multiple inheritance in more or less the way roles are supposed to work, I think.
18:21 colomon but it's still a long step from that to using them in practice, I bet.
18:21 moritz_ ah, and there's an Ordering too
18:22 bionoid joined #perl6
18:22 moritz_ oh
18:23 moritz_ std: subset Ordering where Signature | KeyExtractor | Comparator | OrderingPair | Whatever;
18:23 p6eval std 28606: OUTPUT«ok 00:01 100m␤»
18:23 moritz_ uhm, subset of what?
18:23 masak I have a question about Array.delete. S32/Containers describes it with 'Sets elements specified by C<@indices> in the invocant to a non-existent state, as if they never had a value.' does this mean something different from 'Sets elements specified by C<@indices> in the invocant to C<undef>'?
18:23 moritz_ (take straigt from S29)
18:24 masak moritz_: appears it parses, at least.
18:24 masak maybe there's an implicit 'of Object'
18:24 moritz_ masak: for typed arrays there's a difference, yes
18:24 masak ah, hence the strange wording.
18:24 masak I see. thanks.
18:25 moritz_ yw
18:25 baest_ joined #perl6
18:25 masak the 'as if it never had a value' currently has a ghastly interpretation in Rakudo. it gives a Null PMC access.
18:25 masak well, Parrot does.
18:25 moritz_ lol
18:26 masak I'm reading the PIR of that routine now. it basically says 'make these indices contain the Null PMC'.
18:26 masak so no wonder.
18:26 moritz_ assigning an undef would be much better, even if not quite accurate
18:27 masak maybe I should just port it to the Setting and get it over with.
18:27 * masak tries
18:30 moritz_ colomon: did you apply the Num -> Rat patch?
18:31 colomon moritz_: I did not, thought I have a copy locally.
18:31 colomon Did he send it to perl 6 compiler?  I don't always follow that...
18:32 moritz_ it's in RT (and thus p6c, I think)
18:32 colomon (copy locally == cut and paste from lanny's nopaste)
18:33 colomon If you'd like, I'd be happy to track it down and do it.  Be good practice...
18:33 colomon (track down the proper patch, I mean, so he gets credited properly)
18:34 moritz_ sure, would be great
18:35 * moritz_ looks at the patch
18:36 moritz_ I'm a bit worried that sub _modf might be visible to Perl 6 programs
18:38 cahek joined #perl6
18:39 Tene masak: pong
18:39 masak Tene: at the place in time where I pinged you, did you notice cosimo_'s troubles with SQLite3?
18:40 Tene masak: I haven't read any scrollback.  I could if you'd like.
18:40 payload joined #perl6
18:41 colomon moritz_: interesting... he didn't have _modf in the version I saw.
18:41 moritz_ colomon: probably duplication removal
18:41 colomon should it be "my sub" or something like that?
18:42 masak Tene: short summary: SQLite3 evaluates to 'Undef' on line 50 in SQLite.pm. it worksforme, but not for cosimo_. we don't know why.
18:42 moritz_ colomon: that would be great. Last time I checked it 'my' functions didn't work in the setting - but maybe they do now
18:42 colomon let me see what happens...
18:43 moritz_ I didn't quite understood how the patch works - but it gives 335/113 for pi, which is a very nice approximation ;-)
18:43 RoomsUser_ joined #perl6
18:43 moritz_ and 1/10 for 0.1, -1.5 for -0.2 etc
18:44 moritz_ in short, I like it ;-)
18:44 Tene masak: if you can find anyone who can reproduce the problem, I can troubleshoot it.
18:44 masak cosimo_: ping
18:44 Tene masak: the first step I'd try is running it under strace.  if you can get me an strace log, it should help a lot.
18:44 colomon moritz_: "patch does not apply"
18:45 masak aye. my intuition told me that too, but I'm still too inexperienced to know what to _do_ with such an intuition. :P
18:45 moritz_ colomon: it said that for me too, but in fact it did apply
18:45 moritz_ I changed a small detail, then did git-add src/setting/Num.pm
18:45 moritz_ and then git-am --continue
18:45 Tene masak: you'd grep the log for SQLite to see what paths it looked for the library in.
18:46 masak ah.
18:46 colomon moritz_: didn't apply at all for me.
18:48 lisppaste3 moritz_ pasted "version of lanny++'s patch that applies right now" at http://paste.lisp.org/display/88169
18:48 moritz_ colomon: try this one
18:48 moritz_ (with git-am $filename)
18:48 colomon moritz_: that's just the diffs between his patch and yours, isn't it?
18:48 moritz_ uhm, sorry
18:49 moritz_ right
18:49 moritz_ let me get you the right one
18:50 lisppaste3 moritz_ annotated #88169 "next try (actualy patch for colomon++)" at http://paste.lisp.org/display/88169#1
18:50 s1n1 joined #perl6
18:51 colomon moritz_++
18:53 colomon working on testing it now.
18:58 perl_7_0_0 joined #perl6
18:58 colomon yeah, the 355/113 test is very nice.  and you can actually get a lot better rational pi by upping the tolerance....
18:59 colomon Trying it as "my sub" now.  (Or should I check it in first and then do that?)
19:00 moritz_ first try
19:00 colomon I meant check in lanny's patch and then mess with it -- not sure if I said that clearly the first time.
19:00 moritz_ I do it this way usually:
19:00 moritz_ 1) apply the original patch
19:00 moritz_ 2) experiment with it
19:01 moritz_ 3) commit my changes
19:01 moritz_ 4) run git-rebase -i HEAD^3
19:01 moritz_ squash my changes in the original patch
19:01 moritz_ 5) push
19:01 moritz_ 6) profit
19:02 colomon I used "git apply patch", that doesn't seem to have staged the patch or committed it or anything.  I don't seem to have git-am?
19:02 masak a blog post about the non-ubiquity of TDD: http://lastofthecarelessmen.blo​gspot.com/2009/10/testing.html
19:02 meppl joined #perl6
19:03 moritz_ colomon: git-am also addes the author information automatically
19:04 moritz_ colomon: so if you apply with 'git-apply' you need to commit with 'git commit --author="..."'
19:04 colomon so I probably should do that before making my own change on top of his, yes?
19:04 moritz_ yes
19:05 colomon Okay.  btw, my sub seems to have worked, at least with my first crude test of it.
19:06 NorwayGeek joined #perl6
19:07 colomon should I include his e-mail in the author string, do you think?
19:07 moritz_ well, if (1.1).Rat lives and Num::$subname doesn't work, it's fine
19:09 moritz_ yes, include email address
19:09 colomon danke.
19:09 NorwayGeek joined #perl6
19:09 NorwayGeek joined #perl6
19:15 nErVe joined #perl6
19:16 colomon running tests now.
19:16 Su-Shee left #perl6
19:26 crythias joined #perl6
19:43 moritz_ with this patch (with non-'my' sub) I get this error in t/spec/S11-modules/nested.t
19:43 moritz_ ok 5 - can use multiple "Role $name" statements (in multiple files) RT 67976
19:43 moritz_ Ambiguous dispatch to multi '_block1697'. Ambiguous candidates had signatures:
19:43 moritz_ :()
19:43 moritz_ :()
19:43 moritz_ in Main (src/gen_setting.pm:3468)
19:44 moritz_ looks like a code generation bug to me
19:44 moritz_ (or maybe it's a newer parrot version that triggers it, not sure
19:47 s1n joined #perl6
19:48 colomon You're ahead of me on the spectest, I'm still in S06.  :)
19:48 moritz_ I let both of my cores work on it ;-)
19:48 moritz_ ok, that failure seems to be related to parrot
19:48 colomon I think firefox is stealing all my cycles anyway...
19:50 colomon oh hey, I get that failure too.
19:51 colomon Hmm... I didn't run perl Configure before this spectest, maybe that would help?
19:54 moritz_ I'm currently trying an older parrot revision
19:57 masak I got that error too earlier today.
19:58 moritz_ can parrot's parallel build being broken doesn't help with bisecting, really
20:00 masak sorry, what?
20:02 moritz_ s/can /
20:02 moritz_ sorry :)
20:02 pmurias joined #perl6
20:03 masak ah. :)
20:03 colomon Is -j2 the "use two cores" flag for make?
20:04 masak it is.
20:06 * moritz_ is baffled by that parrot error
20:06 moritz_ i can got back to a parrot version as old as Wednesday and still reproduce it
20:08 masak the plot thickens!
20:09 s1n joined #perl6
20:11 colomon not a parrot error?  I'm pretty sure I ran the full spectest before committing all the trig stuff on Friday, and it all passed.  My parrot hasn't updated since them, as far as I know.
20:12 colomon (definitely not.)
20:14 moritz_ I'm trying older versions of parrot now, step by step
20:15 moritz_ can sombody confirm or deny the sanity of http://smolder.plusthree.com​/app/public_graphs/start/18 please?
20:16 Kodi joined #perl6
20:16 colomon moritz_: I added a few trig tests on friday, if that's what you're asking.  ;)
20:16 moritz_ "a few"
20:17 moritz_ ;-)
20:19 Kodi rakudo: my @foo; my $x = 1; push @foo, $x; ++$x; say $x; say @foo[0];
20:19 masak whoa.
20:19 p6eval rakudo a796cf: OUTPUT«2␤2␤»
20:19 colomon I wondered when someone would noticel
20:19 moritz_ ;-)
20:19 masak spectest finished. duration: 110 minutes. failures in t/spec/S03-operators/series.rakudo t/spec/S03-operators/smartmatch.rakudo t/spec/S11-modules/nested.t t/spec/S32-num/rat.t
20:20 moritz_ masak: are you on latest rakudo?
20:20 masak I'll check.
20:20 moritz_ that looks suspiciously like tests I touched today
20:20 moritz_ (except nested.t)
20:21 Kodi rakudo: my @foo; my $x = 1; @foo[0] = $x; ++$x; say $x; say @foo[0];
20:21 p6eval rakudo a796cf: OUTPUT«2␤1␤»
20:21 moritz_ oh wait, it's much easier
20:21 moritz_ TimToady++ touched the test recently.
20:21 masak I seem to be on bleeding, yes.
20:22 moritz_ masak: could you nopaste the bit more verbose summary please?
20:22 masak aye, no prob.
20:22 Kodi I do think that's a bug— push ought to add the value, not an alias. Does anybody know if it's already been reported?
20:22 masak moritz_: http://gist.github.com/201612
20:23 masak Kodi: it has.
20:23 Kodi masak: Oh, good, thanks.
20:24 masak Kodi: http://rt.perl.org/rt3/Tic​ket/Display.html?id=69548
20:24 Kodi Yeah, it's pretty freaky all right.
20:24 pugs_svn r28607 | moritz++ | [t/spec] fudge test for rakudo that fails after adding a stubbed role
20:25 * moritz_ worksaround that bug by @a.push: do { my $y = $x }
20:25 masak that but report is recent, but I think the bug itself has been known longer. it feels familiar.
20:25 moritz_ same as the gather/take bug
20:25 * masak 's workaround is @a.push($x+0)
20:25 moritz_ masak: that only works for numbers
20:25 masak oh, for sure.
20:25 masak my programs only handle numbers. :P
20:26 Kodi I ended up doing @a[@a.end + 1] = $x.
20:26 masak ouch. :)
20:26 masak peraps we should rewrite push that way. :P
20:26 Kodi Indeed.
20:26 moritz_ certainly @a[*+1] = $x read nicer, though ;-)
20:28 masak yes, but it's wrong.
20:28 masak it should be 'minus 1'. :P
20:28 masak oh wait.
20:28 masak no, I'm wrong.
20:28 moritz_ shouldn't it be *+0 or so?
20:28 masak it should.
20:28 moritz_ rakudo: my @a = 1, 2; @a[*+0] = 3; say @a.perl
20:29 p6eval rakudo a796cf: OUTPUT«[1, 2, 3]␤»
20:29 masak Kodi: check if your code is doing what you intend.
20:29 moritz_ rakudo: my @a = 1, 2; @a[*] = 3; say @a.perl
20:29 p6eval rakudo a796cf: OUTPUT«[3, undef]␤»
20:29 Kodi moritz_: It's fine now.
20:29 masak that's correct.
20:29 moritz_ aye
20:29 masak but perhaps hard to explain to newbies.
20:29 moritz_ whatever ;-)
20:30 masak 哈哈
20:34 colomon why is the @a[*]  is some sort of whatever slice?
20:35 colomon try that again.
20:35 colomon is the @a[*] some sort of whatever slice?
20:36 masak it's the slice of all elements.
20:36 masak at least along the zeroth dimension.
20:38 s1n joined #perl6
20:39 masak moritz_++ # nice sprixel post
20:40 moritz_ thanks
20:40 moritz_ diakopter++ # he reviewed it and improved it here and there
20:40 colomon hey, sweet, spectest runs in 15 minutes on my quad core linux box
20:40 colomon if I use -j4
20:41 moritz_ I think the test harness doesn't honour the -j option (that only affects the build), but you can also use 'TEST_JOBS=4 make -j 4 spectest'
20:42 moritz_ (it defaults to 3)
20:43 colomon hmmm... so that was just the effect of having 4 cores available to handle 3 jobs?  (And lots of ram.)
20:43 masak rakudo: class MyHash is Hash {}; my MyHash $h
20:43 p6eval rakudo a796cf: OUTPUT«Could not build C3 linearization: ambiguous hierarchy␤in sub trait_mod:of (src/gen_setting.pm:136)␤called from Main (/tmp/2nZgZpKlVy:0)␤»
20:43 masak workaround: wrap/delegate, I guess.
20:43 masak still, sad.
20:45 nbrown joined #perl6
20:45 moritz_ colomon: I'd think so
20:47 nErVe joined #perl6
20:49 pmurias masak: url? for the blog pos
20:49 pmurias t
20:49 masak http://perlgeek.de/blog-en/pe​rl-6/announcing-sprixel.html
20:52 lanny joined #perl6
20:52 lanny Hi, all.  In response to backlog _modf should go away when perl6 has a POSIX library.
20:53 moritz_ lanny: I think that colomon has a fix right now which makes _modf purely internal...
20:53 colomon at least in theory...
20:53 moritz_ which means it's no problem at all
20:54 colomon should I verify that my spectest failures are the same as the general run of spectest failures and then check in lanny's patch?
20:54 lanny Excellent.
20:54 moritz_ colomon: yes
20:55 lanny Where is the proper place to bikeshed on Numeric btw?  I'm not looking to retread covered ground.
20:55 masak ah, so Jon Lang, a p6l regular, isn't on IRC at all? I like that subset of the Perl 6 community, they come off as tortoises simply by not being on IRC. :)
20:55 masak nothing wrong with that, of course.
20:56 masak lanny: bikeshedding usually takes place on p6l. but here is fine, too.
20:56 lanny Well in that case... :)
20:56 lanny I notice that sign() is in Real.  Shouldn't it be higher up in the structure.  I would think 7.Int.sign might be of interest.
20:56 lanny I could have used it in Num.Rat in fact.
20:56 moritz_ Int is a Real
20:57 moritz_ and so is Num
20:57 masak how do I tell an Array to be one element shorter than it is?
20:59 lanny Ok.  How about Rat?
20:59 moritz_ Rat is Real too
20:59 lanny Don't make me come over there.  :)
20:59 pugs_svn r28608 | Kodi++ | [t/spec/S32-array/push.t] Added a test for RT #69548
20:59 moritz_ masak: shift? pop?
20:59 masak moritz_: oh, right. thanks.
20:59 lanny Ok.  Real in perl6 must mean something different then in mathematics
20:59 moritz_ lanny: Real means "not complex" in Perl 6
20:59 moritz_ and as far as I understand mathematics, that's roughly the same
20:59 moritz_ and Rat is a subset of Real, of course
20:59 lanny No.  Rats can't represent all Reals so Rats can't be Reals (in math)
20:59 moritz_ well, that's why we don't use inheritance for that
20:59 lanny Understood.  I'm just thinking of the confusion such terminology will cause.
20:59 moritz_ but rather role composition
20:59 jaldhar joined #perl6
20:59 lanny Yeah.  Been playing with that in Scala.  My heads about half wrapped around role composition
21:00 moritz_ if you can do $op with Real, then you can do $op with Rat
21:00 Kodi left #perl6
21:00 moritz_ which is why Rat implements the Real interface/role
21:00 lanny decades of study are yelling at you in my head right now.  :)
21:01 moritz_ there's some kind of impedance mismatch between the Perl 6 type system and mathemtical subsets...
21:01 lanny But I don't have a quick counterexample.
21:01 lanny Yes.  I'm just thinking of the pain that's caused in Haskell.
21:01 moritz_ lanny: note that I don't say that $op on Rat produces a $at again
21:01 lanny Although wanting to go off the deep in for the prelude isn't something I'd want to see in p6 either.
21:02 moritz_ it might very well produce a Real
21:02 lanny Noted.
21:02 moritz_ like sqrt(Rat) -> Real
21:02 lanny Bumped into that trying to produce a multiply-with-carry RNG and not having uint...
21:09 lanny Would you like a sqrt(Rat)->Rat?  I've got one squirreled away somewhere.
21:09 colomon lanny: I think that way lies madness.
21:09 lanny :P
21:09 lanny colomon: was more of a poke than something I think was really needed
21:09 colomon well seriously, all of the trig functions could be implemented to return Rats if called with Rats
21:09 lanny I am still concerned about the terminology though.
21:09 moritz_ I don't think it's a good idea
21:09 moritz_ conceptually all these functions return reals, not rationals
21:10 moritz_ (and yes, I'm away that the computer only knows about rationals...)
21:11 pugs_svn r28609 | diakopter++ | [sprixel] a few medium-ish refactorings; reduced durations of while/preincrement microbenchmark by 50%
21:11 nErVe joined #perl6
21:12 masak tests++ # you are my joy and my greatest enemy
21:12 masak s/enemy/adversary/
21:12 * moritz_ was about to suggest rm if they were really enemies ;-)
21:13 lanny Surely they are more antagonist?  If they are *your* adversary I'll start saying your name a lot while writing them such that I am overlooked.
21:14 * moritz_ just needed 2 minutes to find the xterm where he started a largish mv
21:15 moritz_ time to clean up my windows, it seems ;-)
21:15 masak beating the tests is fun, though.
21:15 masak the end guy is hard.
21:16 lanny Is there thought that p6 will have a POSIX for things like modf() or will such be rolled into p6 and the posix implementations provide the lifting at the machine level for posix machines?
21:17 lanny Motivating thought is Real.modf()
21:18 * moritz_ doesn't know
21:21 pugs_svn r28610 | pmurias++ | [mildew-js] moved runtime.js into re-mildew
21:21 pugs_svn r28611 | pmurias++ | [mildew-js] some progress on the runtime
21:21 pmurias lanny: the second option is preferable when possible
21:25 lanny Ok.  So it wouldn't be taken amiss if I document a modf() in role Real for S32?
21:26 xinming joined #perl6
21:27 lanny and (looking at POSIX) fmod
21:28 lanny alternately I can throw these ideas at perl6-language and see if they stick there.
21:28 diakopter oh.  my microbenchmark comparisons were way off, earlier... due to very large differences in 'startup/parse' time
21:28 diakopter hrmph
21:28 moritz_ lanny: we currently try to avoid POSIX names, except when they are very good
21:28 moritz_ lanny: and I don't think modf is a good name ;-)
21:28 moritz_ s/try/trying/ # time for me to go to bed ;-)
21:29 lanny I agree.  It's just what I had for my perl5 impl
21:30 diakopter pmurias: I did a bunch of refactoring... improved sprixel's runloop/traversal by around 1-2 decimal orders... substituted a smart-ish JS exception handling system for tons and tons of checks
21:32 diakopter also (for some reason), rakudo on my VPS runs 10-20x slower than on my notebook in a vmware linux vm
21:32 diakopter but sprixel runs about the same.
21:32 diakopter v8 & perl are 64-bit on both.
21:32 moritz_ is it the same architecture? (32bit vs. 64bit)?
21:33 moritz_ hm, ok
21:34 diakopter anyway, here are some updated microbenchmark numbers: (just for entertainment purposes only; do not base any claims on these non-numbers)
21:36 diakopter rakudo -e 'loop (my $x=0;++$x < 100000;) {}; say $x' #real    0m4.392s
21:36 diakopter rakudo -e 'loop (my $x=0;++$x < 1;) {}; say $x' #real    0m0.999s
21:36 diakopter perl sprixel.pl -e 'loop (my $x=0;++$x < 100000;) {}; say $x' #real    0m20.058s
21:36 diakopter perl sprixel.pl -e 'loop (my $x=0;++$x < 1;) {}; say $x' #real    0m1.787s
21:37 pugs_svn r28612 | Darren_Duncan++ | Spec S03 : add Range methods .excl_min, .excl_max
21:37 diakopter keep in mind, in sprxiel those are bigints, so they're like quadruple boxed
21:38 diakopter spirxel, even
21:38 diakopter I mean.
21:38 diakopter sprixel.
21:40 pmurias diakopter: in perl5 it's 0.024
21:40 nbrown joined #perl6
21:42 zaphar_ps joined #perl6
21:44 slavik2 joined #perl6
21:44 diakopter pmurias: no it's not. :)  it's 0.014
21:44 slavik2 perl6: say "Hello"
21:45 p6eval elf 28612, pugs, rakudo a796cf, sprixel 28609: OUTPUT«Hello␤»
21:45 slavik2 perl6: say "Hello";
21:45 slavik2 bah
21:45 p6eval elf 28612, pugs, rakudo a796cf, sprixel 28609: OUTPUT«Hello␤»
21:45 slavik2 perl6: say (0==1);
21:45 p6eval rakudo a796cf, sprixel 28609: OUTPUT«0␤»
21:45 p6eval ..elf 28612, pugs: OUTPUT«␤»
21:45 slavik2 perl6: say (1==1);
21:46 p6eval elf 28612, pugs, rakudo a796cf, sprixel 28609: OUTPUT«1␤»
21:46 slavik2 perl6: say ?{1==1};
21:46 p6eval elf 28612, pugs, rakudo a796cf: OUTPUT«1␤»
21:46 p6eval ..sprixel 28609: OUTPUT«execute(): execute error: Symbolic_unary prefix__S_Question not yet implemented; srsly!!?!?? at sprixel.pl line 89.␤»
21:46 slavik2 perl6: say ?{1==0};
21:46 p6eval pugs, rakudo a796cf: OUTPUT«1␤»
21:46 p6eval ..sprixel 28609: OUTPUT«execute(): execute error: Symbolic_unary prefix__S_Question not yet implemented; srsly!!?!?? at sprixel.pl line 89.␤»
21:46 p6eval ..elf 28612: OUTPUT«␤»
21:54 slavik2 do assertions work yet?
21:57 diakopter phenny: tell mberends I'm redoing the entirety of sprixel's builtins in Perl 6 (with embedded JS for some things) after I redo the interpreter engine to treat everything as an .invoke(), with proper captures and signatures and the like.
21:57 phenny diakopter: I'll pass that on when mberends is around.
21:59 masak slavik2: you mean in regexes?
21:59 slavik2 yes
21:59 slavik2 rules/tokens/grammars
21:59 masak slavik2: only the kind where you use double curlies and write the assertion in PIR.
21:59 slavik2 masak: {{ pir code }} ?
21:59 slavik2 wait ... we can embed pir code in perl?
21:59 masak <? {{ pir code }}>
21:59 slavik2 interesting
21:59 masak slavik2: at least for now, we can.
21:59 masak until we have the real thing.
21:59 slavik2 how do I refer to $0?
21:59 slavik2 I want to do this: <?{ 0 <= $0 <= 255 }>
21:59 slavik2 my $string = "1234"; token tok { (\d+) <?{ 0 <= $0 <= 255 }> }; if ($string ~~ /<tok>/) { say $/ } ;
21:59 slavik2 roughly
22:02 pugs_svn r28613 | Kodi++ | [perl6.org] Added a mention of Sprixel to the compilers page.
22:06 colomon moritz_: errrr.... spectest done, and I only had two failures: push.t and sinh.t?!
22:12 masak yay! all tests pass, including two TODO ones!
22:13 masak but it's too late to run the spectests now, so the commit'll have to come tomorrow.
22:13 Lichtkind joined #perl6
22:13 quietfanatic slavik2: According to spec, that case would be something like token tok { [\d+] ~~ {0 <255} }, I think...
22:13 quietfanatic Excuse me
22:14 quietfanatic s/{0 <255}/{0 <= $_ <= 255}/
22:14 slavik2 interesting
22:14 quietfanatic But Rakudo's not quite that sophisticated.
22:14 masak I have a fix for RT #67446 locally. http://gist.github.com/201663
22:15 quietfanatic the ~~ doing a submatch
22:15 masak I have a feeling Rakudo might get that sophisticated soon.
22:16 slavik2 masak: how soon?
22:16 slavik2 I've been waiting since parrot was like 0.6-devel
22:16 masak slavik2: I'm not the one to decide how soon. :) but soon.
22:17 slavik2 christmas?
22:17 masak before that.
22:17 masak I'm following the pct-rx development with interest.
22:17 masak it's really progressing nicely.
22:18 slavik2 sweet!
22:18 colomon lanny: I've applied your patch to rakudo.  Thanks!
22:19 lanny My pleasure and thanks back.
22:19 quietfanatic Until then, you'll have to use this :) /<!after \d> [ 25<[0..5]> | 2<[0..4]>\d | 1?\d\d ] <!before \d>/
22:19 masak or PIR.
22:20 diakopter moritz_ (or anyone): any ideas/tips on how to run mangle.pl in reverse... I need to unmangle .... or perhaps I don't.
22:20 dalek rakudo: 42ed85a | (Lanny Ripple)++ | src/setting/Num.pm:
22:20 dalek rakudo: add a cast for Num to Rat with optional error
22:20 dalek rakudo: Adds Num.Rat which creates a Rat approximation of a Num with an error tolerance (defaults to 1e-6).
22:20 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/4​2ed85adefc2867d0d23399ac029c2a508fcd68b
22:20 dalek rakudo: 1ca164a | (Solomon Foster)++ | src/setting/Num.pm:
22:20 dalek rakudo: Change Num._modf to "my" to make it private.
22:20 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/1​ca164a87db6324abd21c54070732260995a7a1d
22:20 quietfanatic s/1?\d\d/1?\d?\d/
22:23 masak g'night.
22:23 diakopter quietfanatic: /<!after \d> [ 25<[0..5]> | 2<[0..4]>\d | 1\d\d? | <[2..9]>\d? ] <!before \d>/ # don't allow leading zeroes
22:24 quietfanatic diakopter:  /<!after \d> 0* [ 25<[0..5]> | 2<[0..4]>\d | 1?\d?\d ] <!before \d>/  # allow leading zeros
22:24 diakopter oh...
22:25 quietfanatic diakopter: note that 1?\d?\d allows 1\d\d, \d\d, or \d
22:26 diakopter right, I didn't realize the person wanted to match 0<[0..9]>
22:26 diakopter (also I left out the "0" case)
22:27 quietfanatic Even the old one would have matched 00 or 0
22:27 quietfanatic but not 000 :)
22:28 nbrown_ joined #perl6
22:30 Lichtkind pmichaud: ping
22:32 nbrown joined #perl6
22:39 nErVe joined #perl6
22:42 nErVe left #perl6
23:06 zaphar_p1 joined #perl6
23:20 justatheory joined #perl6
23:22 payload joined #perl6
23:35 diakopter should I de-[mangle.pl] the node names from STD (see mangle.pl in src/perl6) or mangle them from my JS source  (anyone please feel free to comment)
23:35 eternaleye joined #perl6
23:37 diakopter e.g. infix:sym<->  comes across as infix__S_Minus
23:37 ihrd joined #perl6
23:37 ihrd left #perl6
23:38 diakopter in other words, should the dispath of 'infix__S_Minus' appear internally as 'infix__S_Minus' or 'infix:sym<->'
23:38 diakopter dispatch
23:38 diakopter I see pmurias' mildew-js uses the latter
23:42 diakopter I suspect it should use the mangled edition.
23:42 NorwayGeek joined #perl6
23:59 rhr joined #perl6

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

Perl 6 | Reference Documentation | Rakudo