Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2009-10-26

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:05 frew joined #perl6
00:26 ihrd joined #perl6
00:26 ihrd left #perl6
00:44 mikehh joined #perl6
00:55 OuLouFu joined #perl6
00:56 mikehh joined #perl6
00:56 carlin Does the RSS Feed on rakudo.org not update?
01:01 kent\n joined #perl6
01:09 mikehh joined #perl6
01:28 mikehh joined #perl6
01:34 s1n_mini joined #perl6
01:35 Schwern joined #perl6
01:40 mikehh joined #perl6
01:46 titeflat joined #perl6
01:47 titeflat perl6: say 3;
01:47 p6eval elf 28893, pugs, rakudo 49e62f: OUTPUT«3␤»
01:48 titeflat perl6: say "hello Bob";
01:48 p6eval elf 28893, pugs, rakudo 49e62f: OUTPUT«hello Bob␤»
01:49 markmont spec tests added (as promised) to http://rt.perl.org/rt3/Tic​ket/Display.html?id=70011
01:49 markmont Hopefully it's ready to go.
01:51 mikehh joined #perl6
01:52 titeflat perl6: my a = 1;
01:52 p6eval rakudo 49e62f: OUTPUT«Malformed declaration at line 2, near "a = 1;"␤in Main (file <unknown>, line <unknown>)␤»
01:52 p6eval ..elf 28893: OUTPUT«Undefined subroutine &GLOBAL::prefix__61 called at (eval 124) line 3.␤ at ./elf_h line 5881␤»
01:52 p6eval ..pugs: OUTPUT«*** ␤    Unexpected "="␤    expecting ":" or "("␤    at /tmp/D4EzpW7U3B line 1, column 6␤»
01:53 titeflat my a : 1
01:53 titeflat perl6: my a : 1;
01:53 p6eval elf 28893: OUTPUT«Undefined subroutine &GLOBAL::a called at (eval 125) line 3.␤ at ./elf_h line 5881␤»
01:53 p6eval ..pugs: OUTPUT«*** ␤    Unexpected " 1"␤    expecting "("␤    at /tmp/i34inCn5Rs line 1, column 7␤»
01:53 p6eval ..rakudo 49e62f: OUTPUT«Malformed declaration at line 2, near "a : 1;"␤in Main (file <unknown>, line <unknown>)␤»
01:54 s1n_mini titeflat: did you mean $a?
01:54 titeflat yes!
01:55 s1n_mini rakudo: my $a = 1; say $a;
01:55 p6eval rakudo 49e62f: OUTPUT«1␤»
01:57 _jaldhar joined #perl6
02:06 titeflat perl6: my $a = 1, 2, 2
02:06 p6eval elf 28893: OUTPUT«Useless use of a constant in void context at (eval 121) line 3.␤»
02:06 p6eval ..pugs, rakudo 49e62f:  ( no output )
02:07 titeflat perl6: my $a = 1..Inf ; say $a[5]
02:07 p6eval pugs: OUTPUT«Stack space overflow: current size 8388608 bytes.␤Use `+RTS -Ksize' to increase it.␤»
02:07 p6eval ..rakudo 49e62f: TIMED_OUT
02:07 p6eval ..elf 28893: OUTPUT«Can't call method "postcircumfix__91_32_93" without a package or object reference at (eval 124) line 4.␤ at ./elf_h line 5881␤»
02:10 titeflat perl6: my $a = 1..4 ; say $a[5]
02:10 p6eval rakudo 49e62f: OUTPUT«Use of uninitialized value␤␤»
02:10 p6eval ..pugs: OUTPUT«␤»
02:10 p6eval ..elf 28893: OUTPUT«Can't call method "postcircumfix__91_32_93" without a package or object reference at (eval 124) line 4.␤ at ./elf_h line 5881␤»
02:18 titeflat perl6: my @a = 1..Inf ; say @a[5]
02:19 p6eval pugs: OUTPUT«Stack space overflow: current size 8388608 bytes.␤Use `+RTS -Ksize' to increase it.␤»
02:19 p6eval ..rakudo 49e62f: TIMED_OUT
02:19 p6eval ..elf 28893: OUTPUT«Can't call method "postcircumfix__91_32_93" without a package or object reference at (eval 124) line 4.␤ at ./elf_h line 5881␤»
02:20 pnate ;-[
02:23 dalek nqp-rx: a669f19 | pmichaud++ | build/ (2 files):
02:23 dalek nqp-rx: Clean up Makefile a bit, bump PARROT_REVISION.
02:23 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/a​669f199e640a1e631249cb30ca59d14dead6c95
02:23 dalek nqp-rx: 920efd9 | pmichaud++ | src/PAST/Compiler-Regex.pir:
02:23 dalek nqp-rx: [regex]:  Add 'pastnode' type for PAST::Regex.
02:23 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/9​20efd9f5258557a73d25227a929b5f701ab8343
02:34 eternaleye joined #perl6
02:46 mikehh joined #perl6
02:49 snarkyboojum_ joined #perl6
02:55 tak11 joined #perl6
02:57 KyleHa joined #perl6
02:58 KyleHa std: my %h = a => 1; say %h<a>:delete;
02:58 p6eval std 28893: OUTPUT«ok 00:01 110m␤»
02:59 KyleHa rakudo: my %h = a => 1; say %h<a>:delete;
02:59 p6eval rakudo 49e62f: OUTPUT«Confused at line 2, near ":delete;"␤in Main (file <unknown>, line <unknown>)␤»
03:24 agentzh joined #perl6
03:24 eternaleye joined #perl6
03:27 eternaleye joined #perl6
03:37 xp_prg joined #perl6
03:40 jsut what is the equivilent of eval "require $package" in perl6?
03:40 jsut or eval "use $package" for that matter
03:41 carlin rakudo: eval("use Foobar"); say $!;
03:41 p6eval rakudo 49e62f: TIMED_OUT
03:42 pugs_svn r28894 | kyle++ | [t/spec] Test for RT #68482
03:42 carlin (that worked locally). Not sure if `try { use Foo }` should work as well (doesn't at the moment at least).
03:42 pugs_svn r28895 | kyle++ | [t/spec] Test for RT 68714
03:42 jsut try { require $package } at least threw an error
03:43 jsut yeah, locally for me it doesn't set $!, but i can't then actually instantiate objects of that class
03:43 jsut which makes me think i'm either dones something wrong, i'm approaching it wrong, or it's a bug
03:45 jsut Null PMC access in get_string()
03:46 jsut maybe the problem is $class.new(...) doesn't work actually
03:46 KyleHa "Null PMC access" is always a bug.  It's like a segmentation fault.
03:46 jsut ah
03:48 markmont left #perl6
04:05 astrojp left #perl6
04:12 frew joined #perl6
04:16 frew joined #perl6
04:18 charsbar_ joined #perl6
04:19 baest_ joined #perl6
04:20 frew joined #perl6
04:22 cxreg joined #perl6
04:22 frew_ joined #perl6
04:22 huf joined #perl6
04:25 justatheory joined #perl6
04:26 Helios- joined #perl6
04:27 kcwu joined #perl6
04:27 mikehh joined #perl6
04:30 Woodi joined #perl6
04:34 araujo joined #perl6
04:34 Jedai joined #perl6
04:35 ruoso joined #perl6
04:55 eternaleye joined #perl6
04:58 eternaleye joined #perl6
05:01 * diakopter looks around
05:01 envi^office joined #perl6
05:06 justatheory joined #perl6
05:09 envi^office joined #perl6
05:10 mberends joined #perl6
05:10 * mberends saw diakopter looking around
05:15 mikehh joined #perl6
05:29 dalek nqp-rx: 63139fe | pmichaud++ |  (3 files):
05:29 dalek nqp-rx: Refactor the build/bootstrap build process to avoid cross-stage conflicts.
05:29 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/6​3139fe0382466df643732425e32c1d8069bf1a9
05:29 dalek nqp-rx: 1a369e2 | pmichaud++ |  (6 files):
05:29 dalek nqp-rx: More build process cleanups.  Add :PIR{{...}} modifier for inlined PIR
05:29 dalek nqp-rx: in regexes.
05:30 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/1​a369e20210f189717b6f8b32fcea1cdb0df0300
05:36 mberends if carlin++'s patch to setting/IO/Socket.pm fixes the recv() method as expected, many network client projects that were "hung" will now be fixed. carlin++ !
05:37 mberends patch in http://rt.perl.org/rt3/Publi​c/Bug/Display.html?id=70017
05:39 envi^home joined #perl6
05:41 dalek nqp-rx: 4039648 | pmichaud++ | build/Makefile.in:
05:41 dalek nqp-rx: Improve "make clean" target a bit.
05:41 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/4​039648d92023552b703e832a43bb428c65e33ae
05:47 eternaleye_ joined #perl6
05:52 rhr joined #perl6
05:54 mikehh joined #perl6
05:58 quux joined #perl6
05:59 quux joined #perl6
06:09 JimmyZ joined #perl6
06:18 colomon joined #perl6
06:26 cotto joined #perl6
06:41 rfordinal joined #perl6
06:43 Bzek joined #perl6
06:59 xabbu42 joined #perl6
07:13 desertm4x joined #perl6
07:18 desertm4x_ joined #perl6
07:19 Su-Shee joined #perl6
07:19 Su-Shee good morning. :)
07:32 KatrinaTheLamia joined #perl6
07:32 moritz_ oh hai
07:37 pugs_svn r28896 | jimmy++ | [zh-cn/syn/S02-bits.pod] added a bit translations on Built-In Data Types
07:39 iblechbot joined #perl6
08:14 mariuz joined #perl6
08:14 tuxdna joined #perl6
08:18 envi^office joined #perl6
08:25 KatrinaTheLamia joined #perl6
08:36 rfordinal joined #perl6
08:39 dakkar joined #perl6
08:49 eternaleye_ joined #perl6
09:03 carlin S32-io talks about a socket.get function that returns data up to the first occurrence of a specific value (eg "\n"). Would it be worth writing a patch to implement that? (given how up in the air anything in S32-io is)
09:03 moritz_ carlin: yes
09:04 pnate2 joined #perl6
09:04 tuxdna joined #perl6
09:06 carlin alright :-)
09:06 * carlin gets to work
09:06 moritz_ if a HTTP server can read line by line, that's certainly helpful :-)
09:14 rgrau joined #perl6
09:24 xenoterracide joined #perl6
09:49 snarkyboojum_ joined #perl6
09:50 masak joined #perl6
09:50 tuxdna joined #perl6
09:51 zamolxes joined #perl6
09:52 jnthn oh morning
09:52 jnthn A new week is upon us.
09:53 moritz_ it is
09:53 mathw oh hai
09:53 moritz_ jnthn: how was your trip to italy?
09:54 masak mornin'
09:54 moritz_ masak: I'm disappointed you didn't make the ticket with number 70000 :-)
09:54 jnthn moritz_: Trip was nice.
09:55 jnthn moritz_: getting up at 4:30am for the flight home was less so.
09:55 masak moritz_: heh.
09:56 masak moritz_: I was pretty knocked out yesterday.
09:56 moritz_ carlin: might I ask you to also write some tests for RT #70017? that would be really awesome
09:57 moritz_ masak: hope you feel better now
09:58 carlin moritz_: sure, I had intended to do it earlier but got distracted
09:59 masak moritz_: a little. I need to recover, is all.
09:59 moritz_ carlin: \o/
10:02 moritz_ luckily the DST -> non-DST switch bought me an hour back
10:02 moritz_ so my sleep cycle automatically became a tad more normal
10:02 masak nod.
10:03 donaldh joined #perl6
10:04 moritz_ wow, apache's log file for perl6.org has grown considerably
10:04 moritz_ let's see if rakudo makes it through without a segfault :)
10:07 KatrinaTheLamia joined #perl6
10:10 carlin rakudo: my $foo-bar = 'quux'; 'quux' ~~ / $foo-bar /;
10:10 p6eval rakudo 49e62f: OUTPUT«Confused at line 2, near "bar /;"␤in Main (file <unknown>, line <unknown>)␤»
10:11 carlin Is it possible to write that in a way that works?
10:11 moritz_ with eval
10:11 daemon joined #perl6
10:11 masak carlin: with... what moritz_ said.
10:11 xinming_ joined #perl6
10:15 moritz_ http://moritz.faui2k3.org/tmp/access.svg # updated access statistics for perl6.org
10:16 moritz_ it'll be interesting to know how it looks like in April or May 2010 :-)
10:16 masak indeed.
10:17 masak carlin: it's possible to get quite close to the real syntax with a bit of trickery.
10:17 masak rakudo: sub r($rx, &c) { my $s = c($rx); return c("/$s/") }; my $foo-bar = "quux"; my &c = { eval($_) }; say "quux" ~~ r(q/ $foo-bar /, &c)
10:17 p6eval rakudo 49e62f: TIMED_OUT
10:17 masak p6eval: you're very slow, you know that?
10:17 pmurias joined #perl6
10:18 carlin I'm writing it in the setting, would eval be alright there or it would it be better to alias the variable to a name without hyphens?
10:18 KatrinaTheLamia joined #perl6
10:19 moritz_ carlin: are you sure you can't work with index() or rindex() or split or so instead?
10:23 carlin Indeed, index() will work. Thanks
10:23 * moritz_ found a nice real-world use for rindex last weekend
10:24 moritz_ $/.from - $/.orig.rindex("\n", $/.from) # column at which the match starts
10:24 tuxdna joined #perl6
10:42 tuxdna joined #perl6
10:47 rfordinal left #perl6
11:03 tuxdna joined #perl6
11:03 szabgab joined #perl6
11:13 masak yes, rindex is occasionally very useful.
11:24 pmurias joined #perl6
11:24 pmurias diakopter: hi
11:38 dalek book: acc87f8 | moritz++ | docs/TODO:
11:38 dalek book: [docs] add TODO file which holds a list of technical TODOs
11:38 dalek book: review: http://github.com/perl6/book/commit/ac​c87f88419bc2daa6c5714057c62eb678e8f361
11:44 dalek book: fa5f59c | moritz++ | docs/TODO:
11:44 dalek book: [docs] one more technical TODO
11:44 dalek book: review: http://github.com/perl6/book/commit/fa​5f59c648c9b97549edefab056fc76b584cde95
11:47 synth joined #perl6
11:50 moritz_ http://devwhy.blogspot.com​/2009/10/loss-of-zfs.html "pioneers are the ones with arrows in their back"
11:54 lichtkind joined #perl6
12:04 takadonet joined #perl6
12:05 takadonet morning all
12:07 moritz_ \o/
12:07 colomon morning!
12:11 astrojp joined #perl6
12:21 zloyrusskiy joined #perl6
12:29 SmokeMachine joined #perl6
12:31 envi^home joined #perl6
12:32 Bzek joined #perl6
12:34 mikehh joined #perl6
12:40 jsut joined #perl6
12:42 lichtkind_ joined #perl6
12:56 PerlJam good morning #perl6
12:57 moritz_ good morning PerlJam
12:57 jnthn morning, PerlJam
12:57 masak oh hai PerlJam
12:58 moritz_ PerlJam: do you have an estimate of how much time you spent for the release?
12:58 PerlJam moritz_: 2-3 hours, most of that time was waiting for the spectests
13:00 moritz_ PerlJam: ok, that roughly matches my experience
13:01 mikehh joined #perl6
13:05 frederico joined #perl6
13:14 meppl joined #perl6
13:17 mikehh joined #perl6
13:23 masak carlin++ # recv patch
13:23 iblechbot joined #perl6
13:25 jnthn Did it get applied yet?
13:25 masak dunno.
13:25 moritz_ no
13:25 moritz_ masak: feel free to apply though
13:26 masak oki.
13:53 Schwern joined #perl6
14:00 alester joined #perl6
14:06 nihiliad joined #perl6
14:19 KyleHa joined #perl6
14:22 frew joined #perl6
14:26 KatrinaTheLamia joined #perl6
14:26 lisppaste3 jsut pasted "should this work? (constructor delegating to subclass)" at http://paste.lisp.org/display/89294
14:27 moritz_ oh ouch
14:28 moritz_ you need to pre-declare SubThing before you can use it
14:28 moritz_ but that's not yet implemented in rakudo
14:29 moritz_ the best thing you can do for now is probably to have a subroutine instead
14:29 moritz_ which calls the appropriate constructor for you
14:30 masak rakudo: class Thing {}; class SubThing is Thing {}; class Thing is also { method new() { return SubThing.new() } }; Thing.new
14:30 p6eval rakudo 49e62f: TIMED_OUT
14:30 moritz_ p6eval--
14:31 p6eval joined #perl6
14:31 jsut|work in the actual implementation i intend to also create the subclasses name dynamically, and attempting to load it
14:31 moritz_ rakudo: class Thing {}; class SubThing is Thing {}; class Thing is also { method new() { return SubThing.new() } }; Thing.new
14:31 p6eval rakudo 49e62f: TIMED_OUT
14:31 jsut|work there is lots of other stuff i can fool around with and not worry about that for now.
14:31 * moritz_ doesn't udnerstand that
14:32 jsut|work in p5 there is URI, and URI::http etc etc
14:32 jsut|work URI.pm doesn't actually have use ... for all of them
14:32 jsut|work it just requires the ones it needs when you try to create an instance of them.
14:33 jsut|work so URI.new('http://lolol.org') would return an instance of URI::http
14:33 moritz_ jsut|work: my not understanding was about evalbot not working, not about your things
14:33 jsut|work ahhh
14:33 jsut|work ok ;)
14:35 jsut|work on the cl that gives me: maximum recursion depth exceeded ...
14:36 moritz_ that would explain the timeout :-)
14:36 jnthn jsut|work: Isn't that correct, though?
14:36 jnthn jsut|work: new is normally inherited from Object
14:36 jnthn Here you've put in the parent class another new method
14:36 jnthn And thus subclasses of the parent will see that new method.
14:36 jnthn And thus you're doing a recursive call.
14:37 jnthn So I think Rakudo is correct here.
14:37 ryan\n\n joined #perl6
14:38 jsut|work that's an error in my simplification i think.
14:39 jsut|work but maybe it's messed up in the other version too, i'll de simplify
14:39 moritz_ rakudo: for 1..100 { }; say "alive"
14:40 p6eval rakudo 49e62f: OUTPUT«alive␤»
14:40 moritz_ rakudo: for 1..1000 { }; say "alive"
14:40 p6eval rakudo 49e62f: OUTPUT«alive␤»
14:40 moritz_ rakudo: for 1..10000 { }; say "alive"
14:40 p6eval rakudo 49e62f: OUTPUT«alive␤»
14:40 lisppaste3 jsut annotated #89294 "untitled" at http://paste.lisp.org/display/89294#1
14:40 moritz_ rakudo: for 1..1e5 { }; say "alive"
14:40 jsut|work added a constructor to the slass that just calls bless, still blows up.
14:40 p6eval rakudo 49e62f: TIMED_OUT
14:41 moritz_ jsut|work: you still need to pre-declare SubThing, as masak++ demonstrated above
14:41 moritz_ rakudo: class Thing {}; class SubThing is Thing { method new() { bless(*) }}; class Thing is also { method new() { return SubThing.new() } }; Thing.new
14:42 masak but I also agree with jnthn++ that you should actually be getting an infinite loop from that.
14:42 p6eval rakudo 49e62f: TIMED_OUT
14:42 jsut|work if i use moritz's is also, then it works
14:42 jnthn You probably menat return SubThing.bless(*)
14:42 payload joined #perl6
14:42 jnthn Well, probably wanted... :-)
14:42 jsut|work i have no idea what i mean, i just try stuff ;)
14:42 jnthn ;-)
14:43 jnthn Talking of trying stuff...let's get Rakudo building on latest Parrot again. :-)
14:43 * jnthn makes a branch
14:43 masak jnthn++
14:43 jnthn oh, ouch
14:43 jnthn we actually...fail at building Parrot.
14:43 lisppaste3 jsut annotated #89294 "This ond doesn't blow up" at http://paste.lisp.org/display/89294#2
14:44 justatheory joined #perl6
14:44 jsut|work i don't know if that actually helps with with what i was actually trying to do or not.
14:44 jsut|work it does actually result it me getting a SubThing object though :D
14:45 moritz_ that looks pretty much like what you wanted, no?
14:45 jsut|work yeah
14:45 jsut|work now i just need to get it to work where i'm dynamically creating the class name of the subclass
14:46 jsut|work but i should probably do some work work and save that for later
14:46 jsut|work my most recent floundering (from yesterday) is in here: http://github.com/jsut/URI.p6
14:47 moritz_ jsut|work: do you want that project added to proto, our prototype package installer?
14:48 payload joined #perl6
14:48 jsut|work it's not in any state where it'd make sense to install, but if you mean package it up so you can make; make test; make install; sure :D
14:49 masak that particular part is up to the project dev(s), I fear. :)
14:49 jsut|work i looked at what the had for Web.pm.  then looked away cause it didn't seem like fun to play with
14:49 masak tell me more.
14:49 pugs_svn r28897 | carlin++ | [t/spec/S32-io] Add (fudged) tests for recv with a parameter
14:49 jsut|work i just wanted to be able to run tests, which i did liberate from your Makefile
14:49 masak :)
14:50 jsut|work i was just looking at the infrastructure, not actually into it's guts
14:50 masak ihrd++ has a project called uri in projects.list already.
14:50 masak jsut|work: that something you're familiar with?
14:50 jsut|work nope
14:50 masak http://github.com/ihrd/uri
14:50 jsut|work i was just using this as a way to learn a bit of p6
14:51 masak jsut|work: usually when people do the same thing independently, we investigate whether they can merge their efforts in some way.
14:51 masak but right now ihrd is pretty much MIA. he comes in here occasionally, but that's all.
14:52 zaphar_ps joined #perl6
14:52 jsut|work his implementation looks at first glance to be very http specific
14:53 masak ok. I'm no expert myself.
14:53 masak jsut|work: if you believe your project has some advantage to ihrd's uri project, we'd definitely want to see it in proto's projects.list eventually.
14:53 jsut|work i say that just cause in the base URI.pm he's got authority, and query, which don't exist in all URI's.
14:53 masak and preferably some collaboration, but that's up to you and ihrd.
14:54 masak jsut|work: I see. yes, that would make it HTTP-specific.
14:54 jsut|work this is mostly just a way to for me to learn some stuff, i have no great hopes for it to be the definative uri package or anything
14:55 moritz_ jsut|work: some day we'll be able to have multiple packages called URI, disambiguated by an "authority" specification
14:55 moritz_ jsut|work: so there can be many URI.pm's
14:55 jsut|work that could be fun to manage ;)
14:56 moritz_ fsvo "fun" :-)
14:57 jsut|work ;)
15:01 eternaleye joined #perl6
15:06 PacoLinux joined #perl6
15:13 masak are labels slated for April?
15:14 moritz_ labels?
15:14 masak I don't find anything about 'label' in docs/ROADMAP
15:14 moritz_ as in, foo: thing?
15:14 masak as in those, yes.
15:14 masak primarily useful in deeply nested loops.
15:15 KyleHa I miss labels sometimes.
15:15 moritz_ maybe ask Tene++ about it, he sometimes does exception stuff like that
15:15 masak good idea.
15:15 nihiliad joined #perl6
15:15 moritz_ though it might be related to "D.  Parrot context and return continuation handling"
15:16 pugs_svn r28898 | kyle++ | [t/spec] Test from Jason Cole
15:16 masak possibly.
15:17 [particle] what is the scope of a label?
15:17 Psyche^ joined #perl6
15:20 masak [particle]: my approach to implementing it (regardless of what the spec says) would be to make it have the smallest possible scope that's still practically usable.
15:21 KyleHa I thought Perl 5 labels were file scoped, but I didn't find a doc to back me up.
15:21 masak e.g. a label sitting on a for loop can only be next/last/redo'ed from within that for loop.
15:21 Tene masak: I have a plan for how to implement that; I just haven't done the work on it.
15:21 masak Tene: \o/
15:21 jnthn That greatly increases the chances of Rakudo * supporting it. :-)
15:21 masak Tene: I'm starting to feel the need for some of my more complicated programs.
15:22 eternaleye joined #perl6
15:23 moritz_ masak: you can certainly help by writing some tests for it :-)
15:23 Tene masak: if you're blocking on it, first go make sure there are good tests for it, then come harass me again
15:23 masak :)
15:23 masak I might get to it tonight. I'm leaving myself a note.
15:24 moritz_ phenny: tell masak: mind the tests!
15:24 phenny moritz_: I'll pass that on when masak is around.
15:24 moritz_ :-)
15:24 masak phenny: you don't need to, I have my own...
15:24 phenny masak: 15:24Z <moritz_> tell masak mind the tests!
15:24 masak ...system right here.
15:24 moritz_ masak: now you just have to stay quiet ... too late :-)
15:26 masak I think I could produce a dozen tests or so quite easily for this.
15:26 masak and now that I know that Tene could have a use for them, I have the motivation. :)
15:26 masak just need to wait for the work day to end. :P
15:33 * TimToady is back after a weekend sanity break
15:33 * [particle] wonders about a label on a gather statement
15:33 TimToady er, that's a break *for* sanity, not a break *of* sanity
15:33 PerlJam TimToady: heh, I was about to ask  :)
15:34 masak [particle]: well, since a gather is classified as a loop...
15:34 moritz_ sanity++
15:34 masak oh wait, that's 'given'.
15:34 TimToady the whole point of gather is to be orthogonal to control flow
15:35 masak nod.
15:35 [particle] so, labels on gather probably won't do what you mean
15:36 TimToady 'course, one could make a case for labeled gathers anyway, but maybe those are rare enough one should just push to named arrays
15:36 [particle] and that's fine.  probably deserves mention, though.
15:37 mathw yeah that sort of scares me
15:38 TimToady KyleHa: labels don't have to be in the same file in Perl 5, though you can get warnings for leaving subs to search for a label outside that
15:39 KyleHa So a Perl 5 label is totally global?
15:39 TimToady global gives entirely the wrong idea
15:39 TimToady it's totally dynamic
15:39 mathw it just searches outwards until it finds it?
15:39 TimToady yes
15:39 TimToady and goto even searches back down some if it needs to
15:40 moritz_ that sounds not very efficient
15:40 TimToady intentionally :)
15:40 moritz_ :-)
15:41 mathw there are other priorities than the efficiency of goto...
15:41 mathw like, the efficiency of all the structures you can use without getting eaten by the code quality velociraptor
15:41 mikehh joined #perl6
15:42 moritz_ raptor-driven design :-)
15:42 TimToady for Perl 6 I'd probably hoist goto-able labels up into a set of visible labels for each dynamic scope, and do the descending goto as a separate operation from scanning outward for a known label
15:42 ruoso joined #perl6
15:43 payload joined #perl6
15:44 TimToady since visible labels can be statically known, I suspect
15:44 TimToady goto can go up dynamic scopes, but only really goes back down lexical scopes
15:45 TimToady but certainly goto is not required for rakudo *, unless someone gets up the gumption
15:46 gbacon joined #perl6
15:47 * jnthn suspects his gumption for implementing goto is pretty far down :-)
15:47 TimToady that's the "whatever" part of R*
15:48 TimToady hmm, that could be confused with the metaop, so maybe r*
15:50 masak joined #perl6
15:51 * mathw suspects there are easier and more worthwhile things to implement in rakudo before r*
15:53 PerlJam mathw: like anything that extirpates "Null PMC Access" messages.  That's a jihad I could get behind  :)
15:54 KyleHa Hmm.  I think of loop labels as pretty basic.  I don't care if 'goto' works, but I really want to 'next' an outer loop sometimes.
15:56 KyleHa Like here:  http://perlmonks.org/?node_id=610246
15:59 fax joined #perl6
16:00 TimToady sure, that's just a control exception to a location that is known at compile time
16:00 KyleHa rakudo: 'aa' ~~ /(.)$1/; say 'alive';
16:00 p6eval rakudo 49e62f: OUTPUT«Null PMC access in get_string()␤in Main (file src/gen_setting.pm, line 295)␤»
16:00 KyleHa Is that supposed to die with a better error message, or is it supposed to live and match?
16:00 TimToady I think that, unlike with P5, P6 will distinguish syntax for static vs dynamic scope-leaving
16:01 TimToady so next FOO requires FOO to be a visible label
16:01 PerlJam KyleHa: die with a better message
16:01 KyleHa PerlJam:  Thanks.
16:01 TimToady but next "FOO" does not, and doesn't warn
16:01 PerlJam KyleHa: it certainly doesn't match because $! didn't get set anywhere.
16:01 PerlJam er, $1
16:01 masak joined #perl6
16:02 KyleHa PerlJam: I thought it might match since $1 is empty, and (.) does match.
16:02 TimToady rakudo: 'aa' ~~ /(.)$0/; say 'alive'
16:02 p6eval rakudo 49e62f: OUTPUT«alive␤»
16:02 PerlJam KyleHa: Hmm.  good point.  But then I'd expect it to be a "use of initialized value" warning or something
16:03 KyleHa In Perl 5, "aa" =~ /(.)$2/ matches and warns.
16:03 TimToady it means something else in Pelr 5
16:04 moritz_ KyleHa: note that in Perl 5 the $2 is interpolated before the match starts
16:04 moritz_ TimToady: so "die with a nice error message" is the right thing to do?
16:04 TimToady I think it's arguable that an undefined variable never matches in P6
16:04 moritz_ std: /(.)$0/
16:04 p6eval std 28898: OUTPUT«ok 00:01 106m␤»
16:05 solarion joined #perl6
16:06 TimToady moritz_: die is almost never the right thing to do in Perl 6, because exceptions screw with parallel processing
16:07 moritz_ TimToady: well, that's something that can be detected at compile time, no?
16:07 moritz_ TimToady: or would it use a $0 from the outer scope if the match object doesn't provide one?
16:07 TimToady not in the general case of undefined $foo
16:08 TimToady in the specific case it could deduce that it will be undef
16:08 TimToady certainly Perl 5 does something similar in deciding what \10 means
16:09 moritz_ well, fail()ing or warn()ing certainly works for me
16:09 * KyleHa thinks 10 means "too many captures".
16:09 * TimToady thinks 10 means "bad language design"  :)
16:10 moritz_ well,l probably both :-)
16:10 TimToady but Perl 1 had to make many compromises to include as much Unix-hood as possible
16:11 KyleHa OK, I think I'll write the test so that 'aa' ~~ /(.)$1/ lives.  Maybe I'll even test what it does.
16:12 moritz_ you can just test nok 'aa' ~~ /(.)$1/;
16:12 KyleHa Good.  Thank you, moritz++
16:13 moritz_ and maybe include a link to this discussion (about undef not matching)
16:13 PerlJam TimToady: so $0 vars mentioned in a regex always refer to the $/ of that match and not previous matches?
16:14 PerlJam TimToady: to get the other thing you have pass them through a lexical or something that'll save state?
16:15 moritz_ there's always $OUTER::0 or OUTER::<$0> or whatever it's called :-)
16:19 PerlJam What makes $0 and friends different is that they aren't explicitly declared, so OUTER doesn't make as much sense to me
16:19 pugs_svn r28899 | lwall++ | [S05] spec that /$var/ warns and fails if $var is undefined
16:21 moritz_ PerlJam: maybe CALLER:: then?
16:21 moritz_ that doesn't rely on explicit declaration, iirc
16:22 TimToady the actual lexical variable involved is $/, and may be accessed either via OUTER or CALLER as appropriate
16:23 lisppaste3 masak pasted "What would this script print in a Perl 6 implementation with a lazy gather?" at http://paste.lisp.org/display/89300
16:24 moritz_ masak: that's pretty much undefined, since the laziness is not guarantued by current spec
16:25 masak moritz_: will 'C' be in @a at all?
16:25 moritz_ masak: chances are that it'll not be
16:25 TimToady gather is dynamic, not lexical
16:25 moritz_ masak: and the you get a "take without gather" warning
16:25 moritz_ erm, yes
16:26 PerlJam TimToady: I still don't have a good mental model of things.   When is $/ declared?
16:26 moritz_ so regardless of laziness 'C' will not be in @a
16:26 TimToady PerlJam: it's not
16:26 TimToady every block automatically gets $_, $/, and $!
16:27 TimToady I suppose you could call that "declared"
16:27 PerlJam TimToady: so,  $alpha ~~ /foo/; $beta ~~ /bar/;  utilize the same $/ ?
16:28 TimToady yes, the regex is setting CALLER::<$/> in either case
16:28 TimToady which it can, since $/ is implicitly contextual
16:28 PerlJam okay, I got it now.
16:29 PerlJam previously I think I was suffering some p5ism or something because I thought of each /regex/ as creating a new $/
16:33 KyleHa So when 'aa' ~~ /(.)$1/  "fails", does that mean it does not match, or it produces a Failure object like fail()?
16:34 * KyleHa is not firing on all cylinders today.
16:34 PerlJam KyleHa: it's a monday
16:35 KyleHa PerlJam: Not only that, I lost a couple of hours of sleep last night to my sick child.
16:35 KyleHa Not complaining, more apologizing.
16:38 PerlJam KyleHa: I think you and I have the same problem but for different reasons.  I went to bed around midnight last night, but couldn't go to sleep.  Finally, sometime after 3:00am, I fell asleep to be awoken at 4:30am by my 3 year old son crawling into bed with us.
16:38 PerlJam and then I got up at 6:00am for work.
16:41 simcop238 joined #perl6
16:41 icwiener joined #perl6
16:43 KyleHa If it were taking me that long to fall asleep, I'd chew some melatonin.
16:44 Su-Shee I read a book and drink milk with nutmeg, vanilla, cinnamon and honey. ;)
16:44 KyleHa That sounds yummy!
16:45 Su-Shee well if I can't sleep, I better have a relaxed, cosy hour instead.
16:47 PerlJam Su-Shee: warm or cold milk?
16:49 Su-Shee hot.
16:50 Su-Shee if you want to make it easy, use one of those "chai" mixes and just add nutmeg.
16:51 Su-Shee (works as hot chocolate as well ;)
16:51 cdarroch joined #perl6
16:51 TimToady KyleHa: in the context of a regex, "fail" just means "doesn't match"
16:51 masak mmm.
16:51 KyleHa TimToady: Thank you!
16:52 moritz_ TimToady: when things like '(' ~ ')' $stuff fails, does it set $!?
16:55 hercynium joined #perl6
16:58 pugs_svn r28900 | kyle++ | [t/spec] Tests for RT #70007
16:59 pugs_svn r28901 | moritz++ | [t/spec] unfudge IO tests which now pass
16:59 dalek rakudo: 22ded10 | (Carlin Bingham)++ | src/setting/IO/Socket.pm:
16:59 dalek rakudo: Change IO::Socket.recv() to accept a parameter specifying the number of bytes which will be received
16:59 dalek rakudo: Signed-off-by: Moritz Lenz <moritz@faui2k3.org>
16:59 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/2​2ded10cd3f8e9774ca17d5bb8e42bed7efb7938
17:00 ejs joined #perl6
17:02 moritz_ carlin+++
17:02 moritz_ carlin++ even ;-)
17:02 pmurias joined #perl6
17:02 stephenlb joined #perl6
17:05 simcop2387 joined #perl6
17:10 xp_prg joined #perl6
17:11 masak moritz_: sorry I didn't apply that one. I was on my way, but got sidetracked by git reporting worrying problems related to object consistency.
17:11 masak moritz_++ # for applying the ticket
17:12 pmurias how can i make Inline::CPP stop including iostream.h during it's test suit (seems to result in an error on my system)?
17:14 masak swimming &
17:15 rfordinal joined #perl6
17:19 xp_prg I heart perl6
17:20 dalek nqp-rx: 09880e0 | pmichaud++ | src/NQP/ (2 files):
17:20 dalek nqp-rx: Refactor scope and variable declarators.
17:20 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/0​9880e06b3e1dfdd714bf389bdc1a80855eaae7f
17:20 dalek nqp-rx: 9f56d59 | pmichaud++ | src/Regex/Cursor-protoregex-peek.pir:
17:20 dalek nqp-rx: [regex]:  Building a tokrx hash can result in the protoregex hash
17:20 dalek nqp-rx: being modified while it's being iterated -- refactor so that
17:20 dalek nqp-rx: we get the complete list of method names from the protoregex hash
17:20 dalek nqp-rx: before we start building tokrx.
17:20 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/9​f56d592362265f8a84c8f4d1d75ec77b3f6d542
17:20 dalek nqp-rx: 18624fc | pmichaud++ | build/ (2 files):
17:20 dalek nqp-rx: Bump PARROT_REVISION to get Parrot -t fixes, and fix build sequence
17:20 dalek nqp-rx: so that we're left with a P6Regex.pbc .
17:20 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/1​8624fcfb4ba0d6a96b4e525b10542be3a75a60a
17:20 dalek nqp-rx: 45d5132 | pmichaud++ | src/stage0/P6 (2 files):
17:20 dalek nqp-rx: Update bootstrap versions of P6Regex/P6Grammar.
17:20 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/4​5d5132e606fcbd124e0087bcf3488a8f207e1f1
17:21 moritz_ oh wow, pmichaud++ was productive again
17:21 jnthn Yeah!
17:22 jnthn Seems there's really Nice progress towards having NQP running fully again on the new infrastructure.
17:23 moritz_ phenny: tell markmont I've sent you a pugs commit bit, so that you can apply patches to the spectests yourself (for future patches ;-)
17:23 phenny moritz_: I'll pass that on when markmont is around.
17:24 Bzek joined #perl6
17:24 pmichaud actually, most of that was less "productive" and more "bugfix"
17:24 pmichaud but I am about to add subs into nqp-rx
17:25 pnate joined #perl6
17:25 jnthn :-)
17:26 jnthn I'm going to eat dinner, hope I stop feeling so ill, and all being well try and get a bit further on the updates to run on Parrot trunk.
17:26 jnthn I've hit a segfault in the stage 1 so far though, which is like...gah.
17:29 pmichaud I've also decided that (like Perl 6)  subs in nqp-rx will be lexical subs
17:29 pmichaud (unless declared 'our')
17:29 japhb pmichaud, can I make an nqp-rx sub and invoke request?
17:29 pmichaud sure
17:29 japhb 1. slurpy args + flatten for call
17:30 japhb 2. optional params (positional is good enough)
17:30 pmichaud we already do optional params
17:30 pmichaud (in NQP)
17:30 japhb pmichaud, really?  I thought that wasn't working, hmmm.  Probably error on my part.
17:30 japhb But #1 still stands.  Plumage's code has much ugliness to get around that.
17:31 pmichaud do you need flattened named args?
17:31 pmichaud I'm likely to do both, but it'll be syntactical
17:31 pmichaud i.e.,   |$foo  probably won't work, but |@$foo   will
17:32 japhb Not doing any named args yet ... mostly because all the places I would have wanted them, I'd also want flatten and/or slurpy.
17:32 pmichaud okay
17:32 NorwayGeek joined #perl6
17:32 pmichaud anyway, noted, likely to be added, yes.
17:32 japhb thank you
17:32 pmichaud ultimately I want to be able to use NQP to implement nearly all of PAST, and that will require argument flattening
17:32 moritz_ pmichaud: speaking of nqp-rx... just tell me when you think it's worthy to include it in p6eval
17:33 pmichaud moritz_: oh, good thinking!
17:33 japhb ... and I can get rid of ugly hacks like 'call_flattened'
17:33 pmichaud moritz_: it's almost ready now, I think.
17:33 jnthn japhb: I've used named params recently.
17:33 jnthn (in nqp)
17:34 jnthn And they worked for what i was doing. :-)
17:34 japhb jnthn, I meant, for the cases I had in Plumage's code.
17:34 pmichaud the piece that might be missing at the moment is that the default "make" doesn't yet build the nqp binary
17:34 pmichaud I could add that I suppose.
17:35 pmichaud anyway, time for lunch here.
17:35 pmichaud bbiaw
17:36 payload joined #perl6
17:37 mikehh joined #perl6
17:41 TimToady moritz_: I don't think regex failure ever sets $! unless something goes seriously wrong
17:42 payload joined #perl6
17:42 moritz_ TimToady: so how does the caller find about the improved error messages that :dba and ~ are supposed to generate?
17:43 moritz_ $/.err or so would wfm
17:43 TimToady well, .panic is something seriously wrong :)
17:43 moritz_ wfm too
17:44 TimToady std doesn't really give a way to capture that from a .parse yet
17:46 moritz_ well, it would be nice to have something in the spec, so that I can bother pmichaud to implement it, and use it in the book ;-)
17:46 moritz_ (it's useful otherwise too... ;-)
17:50 tuxdna joined #perl6
17:53 Bzek_ joined #perl6
17:55 rfordinal left #perl6
17:55 stepnem joined #perl6
18:00 pugs_svn r28902 | kyle++ | [t/spec] Test for RT 69172
18:03 Util joined #perl6
18:04 Util rakudo: say $*KERNEL
18:04 p6eval rakudo 49e62f: OUTPUT«Contextual $*KERNEL not found␤␤»
18:04 payload joined #perl6
18:04 Util perl6" say $*KERNEL
18:04 Util perl6: say $*KERNEL
18:04 p6eval rakudo 49e62f: OUTPUT«Contextual $*KERNEL not found␤␤»
18:04 p6eval ..elf 28902, pugs: OUTPUT«␤»
18:06 Util perl6: say $*OSNAME
18:06 p6eval rakudo 49e62f: OUTPUT«Contextual $*OSNAME not found␤␤»
18:06 p6eval ..elf 28902, pugs: OUTPUT«␤»
18:08 pmichaud in nqp-rx, I've found it's helpful to have an extra parameter to .parse that specifies the starting rule
18:09 pmichaud e.g. --    my $match = SomeGrammar.parse($text, 'integer');
18:09 pmichaud i.e., something other than TOP
18:09 moritz_ I wouldn't mind having that in the spec ;-)
18:09 TimToady that's :rule in STD
18:09 pmichaud so
18:09 pmichaud my $match = SomeGrammar.parse($text, :rule<integer> );   # ??
18:10 pmichaud if so, wfm.
18:10 TimToady see method initparse's args
18:11 pmichaud TimToady: did you see my question some time ago about the meaning of    /  abc <OtherGrammar::xyz>  def /   ?
18:11 pmichaud i.e., is the "xyz" subrule called with a new cursor of type OtherGrammar, or ... ?
18:11 TimToady no, still backlogging while sitting in a Jiffy Lube with a TV blaring in my year :)
18:11 pmichaud okay
18:11 pmichaud this was probably over a week ago :)
18:12 TimToady oh, well, in that case, I missed it
18:12 pmichaud np
18:12 pmichaud I expect I'll come up with a fair number of small "how does this work" sorts of questions over the next couple of weeks.
18:12 pmichaud I'm thinking I may just number them so we can refer to them (and you'll know if you've missed any :-)
18:13 TimToady #37 is 'no'
18:13 pmichaud got it.  (for those who are curious, question #37 is apparently  "have you answered all of my questions yet?")
18:16 pmichaud actually, maybe I should keep the questions (and answers) as a file in a repo somewhere.  pugs, I guess?
18:16 TimToady car done, biab &
18:22 avar pmichaud: +1 for writing it down, then other people could perhaps try to answer too..
18:22 pugs_svn r28903 | pmichaud++ | Add a file "pm.txt" that records miscellaneous questions Pm has
18:22 pugs_svn r28903 | about the spec/implementation so we can keep a history of them
18:22 pugs_svn r28903 | and refer to them easily on #perl6.
18:22 avar looks like you agree:)
18:22 pmichaud http://svn.pugscode.org/pugs/misc/pm.txt
18:23 pmichaud ummmm, how do I signal svn and/or the svn.pugscode.org server that the file is a .txt file?
18:23 pmichaud (so that it doesn't try to send/download it as binary)
18:24 avar svn propset svn:mime-type text/plain pm.txt ?
18:24 avar but perhaps the server won't obey it
18:24 pugs_svn r28904 | pmichaud++ | Set svn:mime-type property on pm.txt.
18:25 pmichaud that did it.
18:25 pmichaud avar++
18:25 avar whee
18:26 pmichaud TimToady: feel free to answer directly in the file or here on #perl6 :)
18:26 pmichaud whichever is eaiest
18:27 pmichaud *easiest
18:27 pmichaud (if answered on #perl6, I'll move the answer into the file)
18:28 dalek rakudo: fc56071 | markmont++ | src/ (3 files):
18:28 dalek rakudo: make $! always be a Perl object instead of sometimes being a Parrot Exception PMC.
18:28 dalek rakudo: Signed-off-by: Moritz Lenz <moritz@faui2k3.org>
18:28 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/f​c560718604c9fdfa9fdfeab27f58e089ab874ea
18:28 pugs_svn r28905 | moritz++ | [t/spec] more tests for $!, patch courtesy of markmont++
18:33 beggars joined #perl6
18:35 broquaint joined #perl6
18:39 broquain1 joined #perl6
18:43 SmokeMachine joined #perl6
18:45 dalek rakudo: 657d55c | (Kyle Hasselbacher)++ | src/setting/ (2 files):
18:45 dalek rakudo: [setting] make !% work with Whatever
18:45 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/6​57d55cce1f1ded33fd1f731344bd31b33099cb8
18:46 __ash__ joined #perl6
18:47 __ash__ is anyone else having problems building rakudo?
18:47 KyleHa __ash__: What problem are you having?
18:47 __ash__ with the latest pull, anyway
18:47 __ash__ various error: ‘struct parrot_interp_t’ has no member named ‘current_args’ problems
18:48 KyleHa I'll rebuild from scratch and see what happens...
18:48 __ash__ i just updated parrot to the latest, then built it, and then updated rakudo
18:48 __ash__ it might be the version of parrot i am using?
18:49 KyleHa I think Rakudo still wants to use the released 1.7.0 Parrot.
18:49 jnthn __ash__: That means your Parrot is too new.
18:49 jnthn __ash__: Please use the Parrot noted in build/PARROT_REVISION.
18:49 __ash__ okay, i'll undo my parrot update
18:49 jnthn Rakudo needs significant updates to work with latest Parrot.
18:50 __ash__ major parrot changes?
18:50 jnthn Right.
18:50 jnthn I'm working on the udpates in the branch pccupdate
18:50 pugs_svn r28906 | kyle++ | [t/spec] unfudge passing test
18:52 glurks joined #perl6
18:53 KyleHa pmichaud++  # labeling low hanging fruit (LHF)
18:54 rgrau` joined #perl6
18:54 TSa HaloO
18:55 jnthn TSa: oh hai
18:58 colomon Is there a canonical Perl 6 way to remove duplicate strings from a list / array of them?
18:59 japhb rakudo: say ?undef;
18:59 p6eval rakudo 49e62f: OUTPUT«0␤»
18:59 japhb rakudo: say ?1
18:59 p6eval rakudo 49e62f: OUTPUT«1␤»
18:59 TimToady colomon: do you care about ordering on either input or output?
18:59 colomon TimToady: nope
19:00 Juerd @array.=uniq; would be nice to have :)
19:00 lambdabot Unknown command, try @list
19:00 Juerd lambdabot: I'd rather not :)
19:01 TimToady perl6: ('a'..'z').pick(20,:repl).uniq
19:01 p6eval elf 28906: OUTPUT«Can't call method "pick" without a package or object reference at (eval 126) line 3.␤ at ./elf_h line 5881␤»
19:01 p6eval ..pugs: OUTPUT«*** No compatible multi variant found: "&pick"␤    at /tmp/Yio0HCJOP7 line 1, column 1 - line 2, column 1␤»
19:01 p6eval ..rakudo 49e62f:  ( no output )
19:01 colomon rakudo: ('a'..'z').pick(20,:repl).uniq.perl.say
19:01 p6eval rakudo 49e62f: OUTPUT«["x", "m", "j", "o", "r", "t", "u", "c", "a", "p", "n", "w", "e", "s"]␤»
19:01 jnthn rakudo: my @array = <a a b b b c d c a b>; say @array.uniq
19:01 p6eval rakudo 49e62f: OUTPUT«abcd␤»
19:01 colomon woo-hoo!
19:02 colomon So why didn't I find .uniq in S32 Containers?  Where should I have looked?
19:02 PerlJam rakudo: my @array = <a a b b b c d c a b>; @array.=uniq; @array.say;
19:02 p6eval rakudo 49e62f: OUTPUT«abcd␤»
19:04 TimToady colomon: you seem to assume that you should be reading the spec rather than writing it.  :)
19:05 colomon TimToady: I have admit that of the spec, the spectests, rakudo's source, and the book, I'm of the opinion the last thing I should be writing is the spec.  :)
19:05 TimToady lol
19:06 PerlJam Hmm.  I could have sworn .uniq was already in the spec, but a quick ack proves me wrong.
19:12 pmurias joined #perl6
19:13 Juerd Hm, so this is implemented but not yet specced?
19:13 PerlJam Apparently
19:16 TimToady I'll wager it's only implemented for strings thus far
19:16 PerlJam rakudo:  my @array = (1,2,3,4,2,3,1,5,1,3,3); @array.uniq.say
19:16 p6eval rakudo 49e62f: OUTPUT«12345␤»
19:17 PerlJam rakudo:  my @array = (1,2,3,4,2,3,1,5,1,3,3); @array.uniq.say;   say @array[0].WHAT;
19:17 p6eval rakudo 49e62f: OUTPUT«12345␤Int()␤»
19:17 TimToady where types that uniquely map to string hash keys also happen to work
19:18 PerlJam could be
19:18 colomon uniq, line 350 in classes/List.pir
19:18 colomon First comment: TODO Rewrite it. It's too naive.
19:18 TimToady should really be based on %seen{Object} though, to get .WHICH semantics
19:19 colomon looks like it uses infix:eq by default for comparison?
19:19 PerlJam colomon: that's some low hanging fruit I think.  uniq could be written in perl 6 :)
19:20 colomon PerlJam: I'm pretty sure I could do a naive Perl 6 version...
19:22 colomon ah, see, this is what I get for looking at the spec rather than the spectests -- there's already a S32-list/uniq.t.
19:22 PerlJam That might be why I thought it was in the spec already.
19:25 lmc joined #perl6
19:32 colomon rakudo: my $a = "ab<alpha>cd"; say "abzcd" ~~ rx/ $a /; say $0;
19:32 p6eval rakudo 49e62f: OUTPUT«Null PMC access in get_string()␤in Main (file src/gen_setting.pm, line 295)␤»
19:32 colomon Known?
19:33 KyleHa I think so.  I'm looking for it...
19:33 TimToady bad code
19:34 colomon TimToady: what's the right way to write it?
19:34 TimToady rakudo: my $a = "ab<alpha>cd"; say "abzcd" ~~ rx/ <$a> /; say $/
19:34 p6eval rakudo 49e62f: OUTPUT«Confused at line 2, near "$a> /; say"␤in Main (file <unknown>, line <unknown>)␤»
19:34 PerlJam Well, it shouldn't be a "Null PMC access". It should just not match.
19:34 * colomon figured he was wrong, but "Null PMC is always a bug."
19:34 PerlJam (the original)
19:34 dalek nqp-rx: caa7f04 | pmichaud++ | src/cheats/hll-compiler.pir:
19:34 dalek nqp-rx: [hll]:  Remove obsolete emulation of old grammar+action setup.
19:34 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/c​aa7f042cd333599ce75b9eb36927bdc44011628
19:34 dalek nqp-rx: 4c4a0e2 | pmichaud++ |  (3 files):
19:34 dalek nqp-rx: [nqp] Initial subroutine declaration code (still missing params).
19:34 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/4​c4a0e20dd0dd13769af661cf07576c28bafa504
19:35 nnunley joined #perl6
19:39 Schwern joined #perl6
19:39 colomon std: my $a = "ab<alpha>cd"; say "abzcd" ~~ rx/ <$a> /; say $/
19:39 p6eval std 28906: OUTPUT«ok 00:02 114m␤»
19:39 nihiliad joined #perl6
19:39 pmichaud rakudo/pge doesn't know variable interpolation in regexes yet.
19:40 pmichaud (coming in the nqp-rx version, though)
19:40 colomon Huh, I thought I remembered doing that months ago.
19:40 colomon \o/
19:42 colomon That's the right way to do it, though?  rx/ <$a> / ?  Creates a regex object using the contents of $a?
19:43 pmichaud yes.
19:44 colomon Danke.
19:44 jnthn Latest pccupdate branch sees us make it through the build.
19:44 jnthn Completely now.
19:44 jnthn However, not through startup yet.
19:44 pmichaud one can also do
19:45 pmichaud my $a = /ab<alpha>cd/;   say "abzcd" ~~ rx/ $a /;  say $/;
19:45 pmichaud (rakudo doesn't support that form yet, either)
19:49 colomon pmichaud: what exactly is $a in that example?
19:51 tuxdna joined #perl6
19:51 pmichaud it's a regex
19:51 pmichaud just like if I do
19:51 pmichaud my $b = { say 'hello'; };
19:51 pmichaud then $b is a block/closure
19:52 colomon What's the difference between $a = /blah/ and $a = rx/blah/, then?
19:52 pmichaud "rx" gives you a place to add modifiers
19:52 pugs_svn r28907 | Util++ | [S32] Formatting - separated roots() from rand()
19:52 colomon ha!  :)
19:58 dalek nqp-rx: 4c594ad | pmichaud++ | src/NQP/ (2 files):
19:58 dalek nqp-rx: [nqp]:  Add simple parameters to signatures.
19:58 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/4​c594adce99ab5a481d3ce47a3990c96ca1d5cba
20:08 zamolxes joined #perl6
20:18 __ash__ joined #perl6
20:22 simcop238 joined #perl6
20:23 dalek nqp-rx: 8d35cab | pmichaud++ | src/Regex/P6Grammar/ (2 files):
20:23 dalek nqp-rx: [p6grammar]:  Allow names of form  category:sym�foo� .
20:23 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/8​d35cabb1ceb394746ece6334d32a20cc9cabe21
20:23 dalek nqp-rx: c4b8459 | pmichaud++ |  (4 files):
20:23 dalek nqp-rx: [nqp]:  Add relational ops, prefix ops.
20:23 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/c​4b8459641c006711c5b3b58cff29fdbd7ef8acc
20:25 pmichaud std: say(3,,4,);
20:25 p6eval std 28907: OUTPUT«[31m===[0mSORRY![31m===[0m␤Preceding context expects a term, but found infix , instead at /tmp/1K4tMwRQVr line 1:␤------> [32msay(3,,[33m⏏[31m4,);[0m␤FAILED 00:01 108m␤»
20:25 desertm4x joined #perl6
20:25 pmichaud std:  say(3,4,)
20:25 p6eval std 28907: OUTPUT«ok 00:03 106m␤»
20:26 rfordinal3643 joined #perl6
20:27 dalek book: faa1cec | duff++ | src/regexes.pod:
20:27 dalek book: [regex] Added some text about character classes
20:27 dalek book: * Initial text explaining character class composition and ranges
20:27 dalek book: * Use the word 'anchor' consistently
20:27 dalek book: * minor grammatical and other textual changes
20:27 dalek book: * Mention :sigspace on rules
20:27 dalek book: review: http://github.com/perl6/book/commit/fa​a1cec1e3249fbf888baf8a49bd7437236fae06
20:39 dalek book: 8f9db94 | (Solomon Foster)++ | src/regexes.pod:
20:39 dalek book: Fix typo: s/subrle/subrule/
20:39 dalek book: review: http://github.com/perl6/book/commit/8f​9db94f0dda270031edb75034ab10e929505c7d
20:42 diakopter std: say ,1
20:42 p6eval std 28907: OUTPUT«[31m===[0mSORRY![31m===[0m␤Preceding context expects a term, but found infix , instead at /tmp/wpLK0oqBY5 line 1:␤------> [32msay ,[33m⏏[31m1[0m␤FAILED 00:01 104m␤»
20:45 ugs joined #perl6
20:46 baest joined #perl6
20:46 dalek nqp-rx: d38591b | pmichaud++ |  (2 files):
20:46 dalek nqp-rx: [nqp]:  Complete subroutine declarations (positionals only),
20:46 dalek nqp-rx: add nullterms in comma lists.
20:46 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/d​38591b438a9e19e02f2bef170be35682124acbe
20:57 payload joined #perl6
21:02 hercynium joined #perl6
21:06 zloyrusskiy joined #perl6
21:13 zloyrusskiy joined #perl6
21:17 Whiteknight joined #perl6
21:27 moritz_ rakudo: say (* !% *)(5, 2)
21:27 p6eval rakudo 49e62f: OUTPUT«invoke() not implemented in class 'Boolean'␤in Main (file src/gen_setting.pm, line 295)␤»
21:27 moritz_ rakudo: say (5 !% 2)
21:27 p6eval rakudo 49e62f: OUTPUT«0␤»
21:34 KyleHa That Whatever !% thing not working as it ought, still?
21:34 hcchien joined #perl6
21:37 Su-Shee left #perl6
21:40 moritz_ right
21:40 moritz_ at least not with two whatevers
21:40 moritz_ rakudo: say (* !% 2)(5)
21:40 p6eval rakudo 49e62f: OUTPUT«invoke() not implemented in class 'Boolean'␤in Main (file src/gen_setting.pm, line 295)␤»
21:40 moritz_ rakudo: say (5 !% *)(2)
21:40 p6eval rakudo 49e62f: OUTPUT«invoke() not implemented in class 'Boolean'␤in Main (file src/gen_setting.pm, line 295)␤»
21:40 moritz_ wait
21:40 moritz_ that's an older rakudo
21:41 moritz_ from Oct 22
21:42 moritz_ svn: Working copy '.' locked
21:42 moritz_ that was the culprit
21:44 dalek nqp-rx: 64e2c87 | pmichaud++ |  (3 files):
21:44 dalek nqp-rx: [nqp]:  Add infix:<||>, infix:<&&>, and infix:<//>.
21:44 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/6​4e2c87c819666a8cdb2e613cf649044f68f88ef
21:44 dalek nqp-rx: ccd1d5b | pmichaud++ |  (3 files):
21:44 dalek nqp-rx: [nqp]:  More operators and tests.
21:44 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/c​cd1d5b98897e4cb90720ae5874794bbf5881073
21:45 ugs left #perl6
21:48 pugs_svn r28908 | kyle++ | [t/spec] Test for RT 65668, List.reduce: &infix:<+>
21:48 pugs_svn r28909 | kyle++ | [t/spec] Tests for RT #65672, multi does Callable
21:48 pugs_svn r28910 | kyle++ | [t/spec] Test for RT 65700, subtyped attributes in instantiation
21:56 zamolxes joined #perl6
22:08 moritz_ rakudo: 1
22:08 p6eval rakudo 657d55:  ( no output )
22:08 moritz_ rakudo: say (* !% 2)(5)
22:08 p6eval rakudo 657d55: OUTPUT«0␤»
22:08 moritz_ rakudo: say (* !% *)(5, 2)
22:08 p6eval rakudo 657d55: OUTPUT«too many arguments passed (2) - 1 param expected␤in Main (file src/gen_setting.pm, line 295)␤»
22:09 moritz_ ha!
22:09 jnthn Ahh...I may have finally made some progress...
22:10 jnthn (on getting us running on Parrot trunk)
22:10 * jnthn had been blocked on the same issue for a couple of hours
22:13 jnthn Aye, we survive startup again now.
22:13 jnthn Unfortunately, we appear to fail most of the sanity tests, though. :-(
22:14 jnthn oh, no wonder
22:15 jnthn Given that adding two numbers together is broken.
22:24 dalek book: c0f92ed | moritz++ | src/regexes.pod:
22:24 dalek book: [RX] more nit-picking, trailing spaces
22:24 dalek book: review: http://github.com/perl6/book/commit/c0​f92ed28b4f294ee9dc12b97d3239ae88a1c528
22:25 dalek nqp-rx: 190f5e9 | pmichaud++ |  (3 files):
22:25 dalek nqp-rx: [nqp]:  Add while/until/repeat_while/repeat_until .
22:25 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/1​90f5e9294ce8da9694daf7529b31fd052a48560
22:25 dalek nqp-rx: 01986c7 | pmichaud++ | t/nqp/14-while.t:
22:25 dalek nqp-rx: [nqp]:  Add tests for "repeat [while|until] <xblock>" form.
22:25 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/0​1986c719def7eeae2bfc33430da9bb0abc49114
22:28 Whiteknight joined #perl6
22:32 gbacon joined #perl6
22:32 Raugturi joined #perl6
22:37 pugs_svn r28911 | Util++ | [S32] Corrections for typos, mis-formatting, cut-and-paste errors, and other minor offences.
22:39 [particle] joined #perl6
22:44 constant joined #perl6
22:54 diakopter pmurias: ponghi
22:56 pmurias diakopter: hi
22:57 pmurias diakopter: i'm thinking we should release V8 on cpan
23:16 jnthn OK, good news and bad news.
23:16 diakopter pmurias: sure
23:16 diakopter jnthn: first the bad news?
23:17 * moritz_ wants just the good news
23:17 quietfanatic joined #perl6
23:18 dalek nqp-rx: d9b2cc4 | pmichaud++ |  (3 files):
23:18 dalek nqp-rx: [nqp]:  Add 'for' statement and tests.
23:18 dalek nqp-rx: review: http://github.com/perl6/nqp-rx/commit/d​9b2cc4eff58743ea3007a61dcc7dbcc15f800c1
23:18 jnthn Good news: I've now got Rakudo running on Rakudo trunk. We pass all sanity tests. The benchmarks don't slow a huge slow-down.
23:18 pmichaud outstanding!
23:18 pmichaud jnthn++
23:18 jnthn And so far I'm down to t\spec\S02-names_and_variables\fmt and no sign of problems.
23:18 pmichaud I'm about halfway through nqp's test suite
23:18 rfordinal joined #perl6
23:18 jnthn The bad news: the spectests are running *really* slowly.
23:18 jnthn I don't know how much slower, but I can feel the difference.
23:19 jnthn My guess (wild guess) since the benchmarks that exercise various runtime things and especially binding lots of signatures didn't lose all that much, is that it must be a compile-time cost.
23:19 jnthn I'm fearing PGE and/or other things have gotten way slower.
23:20 jnthn pmichaud: Meh, not so outstanding: it's taken me over six hours to get us to this point.
23:21 jnthn And there's still one thing I know I gotta put back.
23:21 pmichaud I wonder if all of those :slurpy :named arguments in PGE are slowing us down :-|
23:21 jnthn pmichaud: I dunno.
23:21 pmichaud I think six hours is pretty good, considering the calling convention world changed :-)
23:21 pmichaud I would've been guessing a day or two
23:21 pmichaud fwiw, I would count the six hours as a vienna rakudo day
23:21 jnthn Well, this is the "just get it running again" patch.
23:22 jnthn pmichaud: oh, I counted it in on my signatures grant.
23:22 pmichaud fair enough
23:22 jnthn pmichaud: I've spent a lot of time on it, but not more than I was expecting really to get to this point.
23:22 pmichaud even better, ten
23:22 pmichaud *then
23:23 jnthn pmichaud: Nested signatures are going to be not too much pain, since I already stubbed in a bunch of what I needed for them.
23:23 pmichaud I've spent a bit more time than expected on the nqp/regex stuff, but I'm very happy with the results and how much more easily things go together
23:23 pmichaud nqp itself looks much cleaner now.
23:23 jnthn pmichaud: Which means my biggest concern is going to be the multiple returns.
23:23 pmichaud within the next day or two I expect I can be self-hosting nqp
23:23 pmichaud er, nqp-rx
23:23 jnthn Yes, I've been glancing at your commits now and then and I'm liking it a lot.
23:24 pmichaud entirely self-hosted
23:24 moritz_ pmichaud: what are the plans for LTM?
23:24 pmichaud moritz_: work on them when I need them.
23:24 moritz_ ok
23:24 pmichaud I don't know that I'll get to them before december
23:24 pmichaud that said, the protoregexes already know how to do a primitive form of ltm
23:24 pmichaud they can do ltm for constant prefixes
23:25 pmichaud they don't know how to do ltm for quantified character classes, such as \w*
23:25 moritz_ well, it's a start.
23:25 jnthn I figure constant prefix LTM is still going to be a decent win.
23:25 jnthn pmichaud: Is that all of the "peek" stuff you've been putting in?
23:25 pmichaud jnthn: yes
23:26 pmichaud just a sec, I'll dump a table
23:26 jnthn pmichaud: OK. I looked, but didn't understand it. ;-)
23:26 rfordinal joined #perl6
23:28 pmichaud http://gist.github.com/219139   # example of peek tables in action
23:29 pmichaud whenever the parser is asked to parse a noun, if the next set of characters match any of those prefixes it knows immediately what rule(s) to check
23:29 pmichaud and doesn't bother to attempt any of the others
23:29 pmichaud (same for statement_control)
23:29 moritz_ so what does the empty string (first line of that hash) mean here?
23:30 pmichaud that hold rules that don't have a constant prefix
23:30 moritz_ ok
23:30 pmichaud i.e., it's the rules that get checked if none of the bigger-than-empty prefixes matched
23:31 jnthn Should be a win.
23:31 moritz_ and if one with a constant prefix and another one both could match, the one with constant prefix wins because of LTM rules?
23:31 pmichaud yes.
23:31 pmichaud the longer prefixes win.
23:31 * moritz_ finally thinks he understood some things
23:32 pmichaud for example, "qq" will win over "q"
23:32 pmichaud gotta run to dinner -- bbl
23:32 moritz_ and both will win over \w+?
23:32 pmichaud no
23:32 moritz_ guten appetit!
23:32 pmichaud I think \w+ wins over q/qq if it happens to be longer
23:32 pmichaud but qq would win over q\w+
23:32 pmichaud (assuming it was matching 'qq' literally)
23:33 pmichaud that's the part that gets trickier
23:33 jnthn :-)
23:33 moritz_ so it's TODO
23:33 pmichaud it's easy to code constant strings -- full LTM patterns will take more doing
23:33 pmichaud gone to dinner
23:33 * moritz_ finds the thought of implementing full LTM pretty scary
23:33 jnthn moritz_: Yeah, me too.
23:34 moritz_ figuring out the LTM boundaries
23:34 moritz_ then inline all the subrules, building a DFA
23:34 jnthn Yeah, that will be hard.
23:34 moritz_ (eliminating recursion along the way)
23:34 jnthn I'd not know where to start on that.
23:34 moritz_ the run the DFA
23:34 moritz_ somehow track which branch matched
23:35 moritz_ re-parse that to get the right captures
23:35 * moritz_ shudders
23:35 diakopter TimToady: what do you think about making an option for std so it uses cached .ast (as well as cached .syml)... maybe not long term, but maybe so...
23:35 * jnthn is glad he picked the easier bits of Rakudo to work on :-)
23:36 jnthn Whee. We're down to S05 and only S03-junctions/autothreading.t fails (and I knew it would, because I didn't actually put that part back yet).
23:36 moritz_ well, there are also scary corners in MMD
23:36 jnthn Well, yes. :-)
23:37 jnthn Those don't make my brain go quite so explodey though. :-)
23:37 jnthn "easier" != "easy" :-)
23:38 wknight8111 joined #perl6
23:38 moritz_ rakudo: say ?("easier" != "easy") # SCNR
23:38 p6eval rakudo 657d55: OUTPUT«0␤»
23:39 Nekonulo joined #perl6
23:40 nbrown joined #perl6
23:40 jnthn :-P
23:45 Nekonulo Erm... excuse me, I'm a relative perl6 newbie. Everything runs fine, but for just messing around, I was hoping to find a way to turn stict off. I've tried google searching, and haven't been able to find anything...
23:46 moritz_ Nekonulo: that's not yet implemented in Rakudo
23:46 Nekonulo OK, thank you.
23:46 ihrd joined #perl6
23:46 ihrd left #perl6
23:46 moritz_ welcome to Perl 6 by the way
23:47 moritz_ and if you build something cool, let us know ;-)
23:47 moritz_ (and if not, tell us where you hit problems, that's valuable to know)
23:49 moritz_ TimToady: in S05 "we define token patterns as those patterns that can be matched without potential side effects or self-reference" - that rules out both backreferences and recursion, right?
23:50 diakopter yes
23:51 moritz_ diakopter: thanks
23:53 moritz_ wow, the LTM section in S05 is short and tough
23:53 tak11 joined #perl6
23:54 jnthn Ooh. Tests are into S12 and still only 1 fail.
23:54 moritz_ just a sanity check - LTM matches might still involve backtracking, right?
23:54 moritz_ when you have two tokens t1 { <a> <.ws> <rest1> } and t2 { <b> <.ws> <rest2> }
23:55 moritz_ then <t1>|<t2> perform a LTM of <a> | <b>
23:55 moritz_ and the longer one (say <a>) wins
23:55 moritz_ but then if <rest1> doesn't match
23:55 moritz_ the engine will still try to match <t2>
23:56 pmichaud yes, they still allow for backtracking, to the degree that ratcheting allows it
23:56 moritz_ so in general (with more than two alternatives) it has to backtrack into the LTM to find the second-longest match
23:56 pmichaud correct
23:56 moritz_ ok, now I feel I have a pretty good hand-waving understanding of LTM
23:57 moritz_ maybe I should write that up into a blog post or so
23:57 snarkyboojum_ joined #perl6
23:57 moritz_ and try to see if that shakes out some new uncertainties on my behalf
23:58 Chillance joined #perl6
23:58 * jnthn would enjoy reading that
23:58 moritz_ but now it's time for sleep, maybe I'll get to it tomorrow or on Wednesday

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

Perl 6 | Reference Documentation | Rakudo