Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2011-12-17

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:04 raiph i notice perlito used to emphasize its nature as a perl6 subset ("miniperl") but now just talks about being a perl6 implementation
00:26 Lothar joined #perl6
00:34 whiteknight joined #perl6
00:34 molaf_ joined #perl6
00:48 dalek niecza: 40118ed | sorear++ | / (5 files):
00:48 dalek niecza: Implement correct-style <{ }> assertion
00:48 dalek niecza: review: https://github.com/sorear/niecza/commit/40118edf04
01:06 spine joined #perl6
01:07 dalek niecza: df250ea | sorear++ | / (3 files):
01:07 dalek niecza: Implement dottyop regex assertions
01:07 dalek niecza: review: https://github.com/sorear/niecza/commit/df250eacc8
01:15 bkolera joined #perl6
01:17 drbean joined #perl6
01:24 thou joined #perl6
01:27 simcop2387 joined #perl6
01:30 awwaiid joined #perl6
01:37 flussence *sigh* I really wish I could figure out what makes tryrakudo die like that. The backend doesn't die, it just... stops accepting input randomly.
01:38 flussence maybe it's the session timeout thing acting up...
01:38 Guest92961 joined #perl6
01:38 envi_ joined #perl6
01:49 poincare101 joined #perl6
01:49 poincare101 Cmon guys! When can I move out of php and back into perl?! (employer refuses to use perl 5, but like perl 6)
01:49 poincare101 even duke nukem forever released
01:50 Chillance joined #perl6
01:52 poincare101 perl6: say 3;
01:52 p6eval pugs b927740, rakudo d5729f, niecza v12-51-g40118ed: OUTPUT«3␤»
01:57 sorear You can do it now, although you'll need to write a lot of infrastructure yourself
02:13 dalek niecza: bca1172 | sorear++ | / (4 files):
02:13 dalek niecza: Implement <foo> calling my regex foo if in scope
02:13 dalek niecza: review: https://github.com/sorear/niecza/commit/bca1172445
02:22 cognominal joined #perl6
02:23 sivoais joined #perl6
02:29 sorear niecza: say join '|', [1, 2]
02:29 p6eval niecza v12-52-gdf250ea: OUTPUT«1 2␤»
02:29 jaldhar joined #perl6
02:30 benabik joined #perl6
02:50 tokuhirom joined #perl6
02:58 TiMBuS dies rakudo (nqp) use libffi now? so we dont need parrots thunks to do nci
02:58 TiMBuS also, does zavolaj work at all? becuae it sure doesn't seem to D:
02:59 colomon I believe it's supposed to be working in nom now.
02:59 benabik TiMBuS: Rakudo nom uses dyncall, not libffi
03:00 am0c joined #perl6
03:04 TiMBuS did parrot also switch to dyncall or
03:05 TiMBuS is this uh. one of those 'things'. where parrot and rakudo diverge
03:09 TiMBuS "===SORRY!=== No applicable candidates found to dispatch to for 'trait_mod:<is>'. Available candidates are:"
03:09 TiMBuS aw
03:10 TiMBuS that's zavolaj's unix-fork.p6 example
03:11 TiMBuS changing the declaration to: "sub fork() returns Int is native('libc')"
03:11 TiMBuS gives me: Cannot locate native library 'libc'
03:12 TiMBuS oh dear
03:12 TiMBuS maybe i dont have it :P
03:13 mkramer joined #perl6
03:18 benabik TiMBuS: What platform?
03:19 TiMBuS linux
03:19 TiMBuS frankenstein ubuntu
03:20 mkramer joined #perl6
03:22 geekosaur there should still be a /usr/lib/libc.so, but if it's being tricky then /lib/libc-mumble.so and /lib/libc.so.6
03:24 TiMBuS of course
03:24 TiMBuS rakudo just refuses to find it
03:32 TiMBuS okay that's bizzare? its just calling dlLoadLibrary which just calls dlopen
03:35 Psyche^ joined #perl6
03:48 TiMBuS sub fork() returns Int is native('libc.so.6') { ... }
03:49 TiMBuS -_- linux
04:25 dalek niecza: b37bff8 | sorear++ | / (3 files):
04:25 dalek niecza: Implement <&foo(ARGS)> syntax
04:25 dalek niecza: review: https://github.com/sorear/niecza/commit/b37bff86b5
04:25 dalek niecza: bf48f50 | sorear++ | / (3 files):
04:25 dalek niecza: Respect context correctly on @0 and @<foo>
04:25 dalek niecza: review: https://github.com/sorear/niecza/commit/bf48f506eb
04:25 dalek niecza: ecef049 | sorear++ | src/ (4 files):
04:25 dalek niecza: Mergeback
04:25 dalek niecza: review: https://github.com/sorear/niecza/commit/ecef0497ae
04:36 tokuhirom joined #perl6
04:48 drbean joined #perl6
05:12 benabik joined #perl6
05:30 poincare101 left #perl6
06:14 drbean joined #perl6
06:22 dalek niecza: d32b7c4 | sorear++ | / (5 files):
06:22 dalek niecza: Refactor proto compilation in preparation to make them actually used
06:22 dalek niecza: review: https://github.com/sorear/niecza/commit/d32b7c46a4
06:49 dalek niecza: 2f1fbaa | sorear++ | lib/ (3 files):
06:49 dalek niecza: Actually use proto definitions to a small extent
06:49 dalek niecza: review: https://github.com/sorear/niecza/commit/2f1fbaa5eb
07:11 drbean joined #perl6
07:13 sorear rakudo: grammar G { proto regex f { x {*} y } }
07:13 p6eval rakudo d5729f: OUTPUT«===SORRY!===␤Proto regex body must be {*} (or <*> or <...>, which are deprecated) at line 1, near "}"␤»
07:30 sorear phenny: tell TimToady STD parses both {*} and [*] in regexes, but S05 only specs {*}.  Which should win?
07:30 phenny sorear: I'll pass that on when TimToady is around.
07:48 sorear niecza: if 1 { my $/; "x" ~~ /./ }; say $/
07:48 p6eval niecza v12-58-g2f1fbaa: OUTPUT«Any()␤»
08:14 drbean joined #perl6
08:28 GlitchMr joined #perl6
08:28 dalek rakudo/nom: d9d3ec3 | moritz++ | src/core/Exceptions.pm:
08:28 dalek rakudo/nom: make X::Base a role, and add X::Obsolete
08:28 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d9d3ec3ba6
08:37 sorear o/ moritz, GlitchMr
08:38 GlitchMr Hi
08:39 moritz \o
08:41 dalek niecza: 5b61026 | sorear++ | / (6 files):
08:41 dalek niecza: Implement fancy proto regexes with stuff around {*}
08:41 dalek niecza: review: https://github.com/sorear/niecza/commit/5b61026703
08:41 * sorear -> sleep
08:42 moritz phenny: ask jnthn what's the best way to make sub throw from Perl6::Actions also available in Perl6::Grammar? move it to Perl6::Grammar and then install an alias? or put it into the cursor somhow, like panic? and if yes, how?
08:42 phenny moritz: I'll pass that on when jnthn is around.
09:09 fridim_ joined #perl6
09:35 mkramer joined #perl6
10:30 guest___ joined #perl6
10:38 MayDaniel joined #perl6
10:45 mkramer1 joined #perl6
10:49 drbean joined #perl6
10:55 donri joined #perl6
11:04 envi_ joined #perl6
11:07 replore joined #perl6
11:12 Moukeddar joined #perl6
11:19 donri left #perl6
11:22 drbean joined #perl6
11:27 preflex_ joined #perl6
11:31 cognominal joined #perl6
11:46 ab5tract joined #perl6
11:54 grondilu joined #perl6
11:58 dalek mu: 40e7e7f | moritz++ | misc/perl6advent-2011/schedule:
11:58 dalek mu: [advent] update schedule for yesterday, just for completeness
11:58 dalek mu: review: https://github.com/perl6/mu/commit/40e7e7f779
12:06 whiteknight joined #perl6
12:13 hundskatt joined #perl6
12:14 moritz nom: say get; say lines[0]
12:14 p6eval nom d9d3ec: OUTPUT«Land der Berge, Land am Strome,␤Land der Äcker, Land der Dome,␤»
12:21 jnthn o/
12:21 phenny jnthn: 08:42Z <moritz> ask jnthn what's the best way to make sub throw from Perl6::Actions also available in Perl6::Grammar? move it to Perl6::Grammar and then install an alias? or put it into the cursor somhow, like panic? and if yes, how?
12:22 jnthn moritz: Any reason it shouldn't go into the world, then $*ST.throw(...) would work?
12:22 jnthn moritz: $*ST is available throughout the grammar and actions. Plus you're calling it anyway to find the exception object, I guess.
12:23 moritz jnthn: good idea, thanks
12:25 * jnthn wonders when the least bad time is to rename that.
12:28 moritz no reason not to do it now
12:28 moritz I don't know of any bigger branches that would suffer from it
12:30 jnthn *nod*
12:30 jnthn OK, then probably I do it this weekend.
12:30 * jnthn can has some tuits :)
12:31 jnthn Also plan to look at more Zavolaj bits.
12:31 moritz what do you want to rename it to?
12:32 moritz Perl6::World  and then $*W instead of $*ST ?
12:32 moritz I have a bit of hacking time right now, unless Ronja decides that she needs more attention :-)
12:33 GlitchMr if (-e 'file') {...}
12:33 GlitchMr How can I write this in Perl 6?
12:33 tokuhir__ joined #perl6
12:33 moritz if 'file'.IO.e { ... }
12:33 GlitchMr :)
12:35 jnthn moritz: Yes, that is the renaming I was planning.
12:36 jnthn moritz: And the matching ones in NQP, HLL, etc.
12:36 jnthn (though they can be done independently of each other)
12:36 moritz wow, I did't know that NQP had a SymbolTable
12:38 mj41 joined #perl6
12:39 orafu joined #perl6
12:44 moritz jnthn: I'm on the rename in Rakudo now. Seems to be easily automated.
12:46 jnthn moritz: Great, thanks :)
12:47 * jnthn away for a few moments
13:08 dalek rakudo/nom: d59a2d3 | moritz++ | / (4 files):
13:08 dalek rakudo/nom: rename SymbolTable to World
13:08 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d59a2d384f
13:08 dalek rakudo/nom: 02cced8 | moritz++ | src/ (7 files):
13:08 dalek rakudo/nom: rename $*ST to $*W. No functional changes
13:08 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/02cced877d
13:11 jnthn \o/
13:11 jnthn moritz: Are you taking on NQP too, or shall I?
13:11 moritz jnthn: I'll try, though my experiences with renaming files in nqp are not too good
13:12 moritz (btw tests pass after each of the previous commits, which is why I didn't put them into a branch)
13:12 jnthn That's fine :)
13:12 jnthn I'd have been worried if the renaming had caused disruption.
13:14 tester joined #perl6
13:15 tester left #perl6
13:20 moritz nqp doesn't seem to be so problematic after all
13:20 jnthn \o/
13:21 dalek rakudo/nom: e354349 | jnthn++ | docs/ROADMAP:
13:21 dalek rakudo/nom: Merge the two regex sections in the roadmap.
13:21 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e3543497b7
13:33 simcop2387 joined #perl6
13:39 dalek rakudo/nom: 6adbc07 | jnthn++ | src/Perl6/Optimizer.pm:
13:39 dalek rakudo/nom: Fix a regression in block inlining optimizations.
13:39 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6adbc074dc
13:43 pkkm joined #perl6
13:46 dalek nqp: 5c46507 | moritz++ | / (8 files):
13:46 dalek nqp: rename SymbolTable to World
13:46 dalek nqp:
13:46 dalek nqp: also updates generates files, to escape bootstrapping issues.
13:46 dalek nqp: review: https://github.com/perl6/nqp/commit/5c46507fb6
13:46 dalek nqp: c43ccbe | moritz++ | .gitignore:
13:46 dalek nqp: .gitignore generated files from dyncall
13:46 dalek nqp: review: https://github.com/perl6/nqp/commit/c43ccbe5da
13:46 dalek nqp: 6ad0a71 | moritz++ | src/stage0/ (6 files):
13:46 dalek nqp: update bootstrap files
13:46 dalek nqp: review: https://github.com/perl6/nqp/commit/6ad0a714d6
13:58 raiph joined #perl6
14:23 hundskatt joined #perl6
14:30 jnthn moritz: u done nao?
14:31 colomon sorry I'm running late on the Advent post.  Probably will be able to finish it this afternoon (Michigan time)
14:32 colomon gotta go to Santa House now with three generations of Fosters.  :)
14:44 dickinsm joined #perl6
14:44 dickinsm left #perl6
14:46 Chillance joined #perl6
14:52 Trashlord joined #perl6
15:08 mkramer joined #perl6
15:16 dalek nqp: 0e65c0a | jnthn++ | / (5 files):
15:16 dalek nqp: Rename HLL::Compiler::SerializationContextBuilder to HLL::World. Also rename the over-long, but widely used get_object_sc_ref_past to just get_ref.
15:16 dalek nqp: review: https://github.com/perl6/nqp/commit/0e65c0a972
15:17 dalek rakudo/nom: d51f3fe | jnthn++ | / (3 files):
15:17 dalek rakudo/nom: Bump NQP_REVISION and chase World API changes.
15:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d51f3fe3b8
15:38 thou joined #perl6
16:03 clintongormley1 joined #perl6
16:29 dalek nqp: 4762987 | jnthn++ | 3rdparty/sha1/sha1. (2 files):
16:29 dalek nqp: Pull in and twiddle a public domain SHA-1 implementation.
16:29 dalek nqp: review: https://github.com/perl6/nqp/commit/47629879cf
16:29 dalek nqp: c1567ab | jnthn++ | / (3 files):
16:29 dalek nqp: nqp::sha1(...)
16:29 dalek nqp: review: https://github.com/perl6/nqp/commit/c1567aba56
16:29 dalek nqp: a9b908a | jnthn++ | src/NQP/Grammar.pm:
16:29 dalek nqp: Switch NQP to use a SHA-1 hash of the soruce as the serialization context identifier, not a timestamp. This, along with a similar patch to Rakudo, should help with some of the bogus wrong-version issues we've been seeing with pre-compilation, while still forcing re-compilation to happen when it is needed.
16:29 dalek nqp: review: https://github.com/perl6/nqp/commit/a9b908af60
16:29 dalek nqp: fa287ec | jnthn++ | src/NQP/ (2 files):
16:29 dalek nqp: Use $*W for the world in NQP also, for consistency with how we now do it in Rakudo.
16:29 dalek nqp: review: https://github.com/perl6/nqp/commit/fa287ec60e
16:29 dalek rakudo/nom: fcbec55 | jnthn++ | tools/build/NQP_REVISION:
16:29 dalek rakudo/nom: Bump to latest NQP.
16:29 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fcbec555c2
16:29 dalek rakudo/nom: 22d23a8 | jnthn++ | src/Perl6/Grammar.pm:
16:29 dalek rakudo/nom: Use SHA-1 of the source instead of a timestamp for the serialization context ID, which should be more relaxed and require less unneeded re-compilations. Should help with some of the pre-compilation issues.
16:29 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/22d23a8e82
16:30 jnthn phenny: tell tadzik hopefully 22d23a8 clears up some of the pre-comp issues we've been seeing.
16:30 phenny jnthn: I'll pass that on when tadzik is around.
16:39 ksi joined #perl6
16:44 clintongormley1 left #perl6
16:46 GlitchMr42 joined #perl6
16:53 lichtkind joined #perl6
17:01 kboga joined #perl6
17:01 tadzik oh hai
17:01 phenny tadzik: 16:30Z <jnthn> tell tadzik hopefully 22d23a8 clears up some of the pre-comp issues we've been seeing.
17:03 tadzik I hope so, nice :)
17:03 kboga hey jnthn, while technically not a bug, i think https://github.com/perl6/nqp/commit/fa287ec60e did something unintentional: $*SCOPE -> $*WOPE
17:03 jnthn kboga: oops!
17:03 tadzik :D
17:03 kboga :D
17:03 jnthn ...and it did it so consistently that all the tests still passed :D
17:04 tadzik how th did it happen? :P
17:05 moritz probably a global search for SC or so :-)
17:06 moritz s:g/SC/W/
17:06 jnthn Right :)
17:06 jnthn Well, $*SC to $*W :)
17:06 jnthn Fixed locally, testing ;)
17:07 tadzik huh, I thought that changed $*ST
17:08 jnthn tadzik: In nom, we always called it ST (SymbolTable). NQP knew it as SC (Serialization Context)
17:09 dalek nqp: 103f44d | jnthn++ | src/NQP/ (2 files):
17:09 dalek nqp: I accidentally s/$*SCOPE/$*WOPE/. kboga++ for noticing!
17:09 dalek nqp: review: https://github.com/perl6/nqp/commit/103f44d005
17:09 tadzik oh, ok
17:09 jnthn Anyway, now it's HLL::World, NQP::World, Perl6::World and $*W throughout. :)
17:09 jnthn My wopey mistake aside, I hope this reduces confusion. :)
17:22 sayu joined #perl6
17:31 MindosCheng joined #perl6
17:34 moritz Hello::World!
17:36 tadzik Hello::Moritz!
17:39 jnthn heh :)
17:46 sorear good * #perl6
17:48 sorear (Does anyone know TimToady's status?)
17:48 tadzik Hello::Sorear
17:51 * TimToady still has shingles-induced ADD and a houseful of visiting distractions
17:51 phenny TimToady: 16 Dec 19:43Z <sorear> tell TimToady I am wondering why assertion:variable uses <EXPR(%LOOSEST)>.  Is <$foo = $bar> supposed to mean something?
17:51 phenny TimToady: 07:30Z <sorear> tell TimToady STD parses both {*} and [*] in regexes, but S05 only specs {*}.  Which should win?
17:52 mkramer joined #perl6
17:54 TimToady [*] can go away
17:54 * TimToady doesn't remember much about assertion:variable's intentions
17:55 * TimToady is about a week behind in backlogging...
17:56 * TimToady has mostly been up to physical labor but not mental; cephalic shingles takes a month or two to recover from
17:59 jnthn Ouch :(
18:00 jnthn TimToady: Sounds nasty. :( Hope the recovery goes smoothly, even if it'll take a bit...
18:02 TimToady so I can answer easy questions, but things that take deeper rumination tend to go astray
18:04 replore_ joined #perl6
18:08 dalek roast: 3d3f9a2 | moritz++ | S32-exceptions/misc.t:
18:08 dalek roast: initial tests for typed exceptions; very unstructured for now
18:08 dalek roast: review: https://github.com/perl6/roast/commit/3d3f9a244a
18:15 mkramer joined #perl6
18:16 tadzik jnthn: I still get Incorrect pre-compiled version of /home/tadzik/src/perl/panda/ext/JSON/Tiny.pm loaded with fresh panda installation :/
18:18 tadzik oh, wait
18:18 tadzik why does it complain about ext/JSON/Tiny? :/
18:18 tadzik so it doesn't like to be ran againt a different version than the one it was compiled against
18:18 dalek std: dc62e1d | sorear++ | STD.pm6:
18:18 dalek std: Remove metachar:sym<[*]> (TimToady says it is a fossil)
18:18 dalek std: review: https://github.com/perl6/std/commit/dc62e1d231
18:20 sorear TimToady: The regex code looks for '{*}' as a string, without whitespace; should non-regex protos require the same syntax?
18:20 sorear (Do you know offhand if the asymmetry is an oversight)
18:22 jnthn tadzik: er, and if it's still doing it then it means the *source* of those two is different, I think...
18:22 jnthn tadzik: Are they out of sync?
18:22 jnthn tadzik: Before it woudln't run against *anything* other than what it was compiled against.
18:22 jnthn tadzik: Now it's relaxed to "should be same source code"
18:23 tadzik jnthn: I suppose the JSON::Tiny bundled with panda is quite old
18:23 tadzik but well, it shouldn't be compiling it against it
18:23 tadzik it is used to _run_ panda, which will then copy panda someplace else and compile it using the JSON already built and installed
18:24 tadzik I guess updating ext/JSON is more of a workaround than a real solution
18:25 tadzik or is it?
18:26 jnthn tadzik: I'm just wondering if something, somewhere is then compiling against a different JSON::Tiny than you think it is.
18:26 tadzik it'd seem so that ext/JSON/Tiny is used not only to run the bootstrap
18:27 jnthn tadzik: Yeah.
18:27 jnthn tadzik: Which I guess is not what you intended.
18:27 tadzik PERL6LIB=$PWD/ext:$PWD/lib perl6 bin/panda install .
18:27 tadzik let me guess: Panda::Builder pushes stuff at the *end* of PERL6LIB...
18:27 jnthn Could explain it :)
18:27 tadzik hm, nope
18:28 tadzik my $p6lib = "{cwd}/blib/lib:{cwd}/lib:{%*ENV<PERL6LIB>}";
18:28 tadzik but that explains it too
18:28 tadzik JSON::Tiny is in PERL6LIB, then we compile panda against... eww
18:28 tadzik we can't really pop ext/ off PERL6LIB in the middle of the panda run
18:30 tadzik okay, so bootstrap can just use $PWD after PERL6LIB
18:30 dalek niecza: 93ea52a | sorear++ | src/ (2 files):
18:30 dalek niecza: Remove [*] stub
18:30 dalek niecza: review: https://github.com/sorear/niecza/commit/93ea52ab20
18:30 tadzik let's see
18:32 localhost joined #perl6
18:39 cognominal jonathan, what is needed 1/ to get --target=parse working
18:40 cognominal jnthn
18:40 tadzik eww, this bootstraping staff is harder than I thought it is
18:40 tadzik I'll look at it tomorrow, less tired
18:41 cognominal my question is probably related to the bootstrapping
18:41 tadzik no worries, I only mean panda bootstraping
18:41 cognominal $ perl6 --target=parse -e 'say "hi"'
18:41 cognominal Could not locate compile-time value for symbol StaticLexPad
18:44 tadzik jnthn: so if I compile panda against a JSON::Tiny v3, and then I update JSON::Tiny to v4, panda just breaks?
18:44 jnthn cognominal: Figuring out where that error is coming from...
18:44 jnthn cognominal: 'cus I ain't sure without going digging. :)
18:44 jnthn tadzik: If you pre-compiled v3, and update it to v4, then re-compilation is needed.
18:45 jnthn tadzik: I mean, why would you not need to do it?
18:45 jnthn tadzik: We can look at who is responsible for maintaining the pre-compilation cache.
18:45 tadzik jnthn: I mean: I install panda compiled against a random JSON::Tiny, then I update JSON::Tiny to some other random version, and everything breaks?
18:45 tadzik and I have to rebootstrap panda and everythign?
18:46 jnthn tadzik: If you're pre-compiling panda and you update one of its pre-compiled dependencies, then yeah, it's going to be a problem.
18:46 tadzik okay
18:46 jnthn tadzik: At least you get told about it now.
18:47 tadzik true
18:47 jnthn tadzik: In ng I remember quite a few times where we silently used old pre-compiled versions of things and got very obscure errors.
18:47 tadzik still, I have no idea how to handle that properly and efficiently
18:47 jnthn tadzik: I can see two ways to go on it
18:47 cognominal my other gripe is to access EXPR method (which is a nqp symbol) from a perl6 grammar.
18:48 jnthn tadzik: Either the installer worries about triggering needed re-compilation of things that depend on a module that gets updated.
18:48 jnthn tadzik: Or we never pre-compile by hand and make Rakudo responsible for maintaining the cache.
18:49 tadzik don't we have long-term plans for the 2nd?
18:49 mkramer joined #perl6
18:49 tadzik the 1st seems quite nasty to me :/
18:49 tadzik and is probably the only efficient way at the moment
18:50 jnthn tadzik: Yeah, though I *think* Pm was a bit uneasy about the 2nd. I want to understand exactly why before I go and put it in.
18:50 tadzik I see
18:50 tadzik I can just make Panda::Builder::build a no-op for now
18:56 ksi joined #perl6
19:05 packetknife joined #perl6
19:05 simcop2387 joined #perl6
19:07 sorear rakudo: $_ = 'foo $16 bar'; s[ '$' <( \d+ ] *= 2; say $_
19:07 p6eval rakudo 22d23a: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<[ ]>, couldn't find final ']' at line 2␤»
19:10 jnthn std: $_ = 'foo $16 bar'; s[ '$' <( \d+ ] *= 2; say $_
19:10 p6eval std be1f10e: OUTPUT«ok 00:01 124m␤»
19:10 jnthn ...wtf.
19:10 jnthn *I* can't parse that :)
19:11 lichtkind moritz: ping
19:11 mkramer joined #perl6
19:11 sorear jnthn: S05:4387
19:12 jnthn sorear: But that says
19:12 jnthn s:g[\$ <( \d+ )>] *= 2
19:13 jnthn sorear: I don't see the closing )> in what you pasted. What am I missing?
19:13 jnthn s/pasted/tried
19:13 jnthn std: $_ = 'foo $16 bar'; s[ '$' <( \d+ )> ] *= 2; say $_ # this makes sense to me
19:13 p6eval std be1f10e: OUTPUT«ok 00:01 124m␤»
19:13 jnthn nom: $_ = 'foo $16 bar'; s[ '$' <( \d+ )> ] *= 2; say $_ # this makes sense to me
19:13 p6eval nom 22d23a: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<[ ]>, couldn't find final ']' at line 2␤»
19:14 jnthn Though nyi
19:14 sorear jnthn: <( and )> are not actually pairing operators
19:14 sorear and )> at the end of a match is redundant
19:14 jnthn ...ouch.
19:15 sorear at least they didn't used to be
19:16 jnthn sorear: Where is <( actually defined in S05? I can't find it...
19:17 sorear 1857
19:17 sorear right below "The following tokens include angles but are not required to balance"
19:20 jnthn ah, I see
19:20 jnthn Well, apart from the bit on how they interact with backtracking, but that's prolly 'cus my brain is tired :)
19:20 jnthn I like the feature. Not so sure I like the syntax for it ;-)
19:20 colomon joined #perl6
19:21 sorear o/ colomon
19:21 lichtkind hai @all
19:22 colomon \o
19:24 sorear hello lichtkind
19:24 araujo joined #perl6
19:24 lichtkind sorear: :)
19:26 araujo joined #perl6
19:26 araujo joined #perl6
19:28 sorear jnthn: Do you know how <~~0> and <~~> are supposed to interact with capturing?
19:28 lichtkind is ~~0 an op ?
19:28 sorear jnthn: 1824 suggests that <~~0> might result in adding $1
19:28 sorear lichtkind: S05:1804
19:29 araujo joined #perl6
19:33 jnthn sorear: Hmm. It is suggestive of that. I don't actually know whether that's an accident of the example
19:33 jnthn sorear: I worry more about the named case
19:33 cognominal joined #perl6
19:33 jnthn <foo> d <~~foo>
19:33 jnthn Neither of those are quantified, but now should we get a list of results?
19:34 lichtkind sorear: thank you i didnt know that
19:35 sorear jnthn: It's suggestive but I don't think I can usefully generalize from it.
19:35 sorear jnthn: See also the parenthetical on line 1497
19:35 jnthn sorear: Yeah, it feels unintentional to me
19:36 sorear Also I think 1513 is a real fossil
19:36 jnthn (1497) indeed, <~~0> introducing a capture feels inconsistent and surprising.
19:37 jnthn (fossil) yes.
19:38 sorear hmm
19:38 jnthn If you want a $1, you can always do (<~~0>)
19:38 jnthn Which is much more explicit.
19:38 jnthn ooc, how do you plan to implement <~~0> ?
19:38 sorear niecza: say "a1b2c3xyz" ~~ / <[a..z]> \d <&?BLOCK>? /
19:38 p6eval niecza v12-60-g93ea52a: OUTPUT«(timeout)»
19:38 sorear jnthn: I hadn't gotten there yet really
19:39 jnthn sorear: OK. The *easy* way is probably just refer back to the relevant piece of AST.
19:39 jnthn Then the compiler needn't handle this case specially.
19:39 jnthn <~~> is just "call self again"
19:40 sorear I wonder why my last test failed
19:40 jnthn Not sure...you'd think it'd hit end of string at some point.
19:40 jnthn (and thus refuse to recurse further)
19:42 jnthn dinner here, bbiab. Then...NativeCall hacking time! :)
19:45 sorear jnthn: actually it doesn't recurse at all
19:45 sorear I wish the mono thread dumper was more reliable
19:50 dalek niecza: 0a764b6 | sorear++ | lib/Kernel.cs:
19:50 dalek niecza: Add sanity check to avoid infinite looping in exception dispatch when the call graph contains a cycle
19:50 dalek niecza: review: https://github.com/sorear/niecza/commit/0a764b6d7c
19:51 sorear now, uh, to put it mildly, this should not happen
19:52 sorear oh, hmm.
19:52 sorear &?BLOCK is getting a reference to the mainline code, but the call system assumes the mainline is called _once_
19:52 sorear niecza: say "a1b2c3xyz" ~~ regex { <[a..z]> \d <&?BLOCK>? }
19:52 p6eval niecza v12-60-g93ea52a: OUTPUT«#<match from(0) to(6) text(a1b2c3) pos([].list) named({}.hash)>␤»
19:52 sorear \o/
19:53 sorear now that an actual block is being used it works :)
20:12 pkkm joined #perl6
20:19 dalek niecza: ac66b89 | sorear++ | / (4 files):
20:19 dalek niecza: Implement <( and )>
20:19 dalek niecza: review: https://github.com/sorear/niecza/commit/ac66b89858
20:23 sorear phenny: tell jnthn /(<foo>) <~~0>/ /(<foo>) (<~~0>)/ /(<foo>) $1=<~~foo>/ What do you imagine the capture trees from these three regexes as?
20:23 phenny sorear: I'll pass that on when jnthn is around.
20:24 sorear rakudo: say Match.^methods(:local)
20:24 p6eval rakudo 22d23a: OUTPUT«prematch postmatch caps chunks Str Numeric Bool ACCEPTS perl gist orig from to CURSOR ast␤»
20:24 sorear rakudo: say Match.^parents
20:24 p6eval rakudo 22d23a: OUTPUT«Capture() Cool() Any() Mu()␤»
20:29 Trashlord joined #perl6
20:36 ksi joined #perl6
20:44 moritz sorear: I don't think <~~0> captures anything, because it starts with punctuation
20:44 moritz lichtkind: pong
20:45 packetknife joined #perl6
20:46 moritz nom: $@
20:46 p6eval nom 22d23a: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at line 1, near "$@"␤»
20:46 moritz nom: $"
20:46 p6eval nom 22d23a: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at line 1, near "$\""␤»
20:46 moritz std: $"
20:46 p6eval std dc62e1d: OUTPUT«[31m===[0mSORRY![31m===[0m�Unsupported use of $" variable; in Perl 6 please use .join() method at /tmp/4cKhyS9K8U line 1:�------> [32m$"[33m�[31m<EOL>[0m�Parse failed�FAILED 00:01 119m�»
20:46 dalek rakudo/nom: b57f60e | moritz++ | / (3 files):
20:46 dalek rakudo/nom: make throw() a method in Perl6::World
20:46 dalek rakudo/nom:
20:46 dalek rakudo/nom: Also run a test for typed exceptions
20:46 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b57f60e837
20:47 molaf joined #perl6
20:47 Trashlord joined #perl6
20:54 colomon New Advent post up, proofreading deeply appreciated, as I am both sick and surrounded by company.
20:54 colomon http://perl6advent.wordpress.com/2011/12/17/day-17-gtk-mandelbrot/
20:54 colomon I somehow forgot to add three more pictures I generated for the article.
20:56 moritz colomon++
20:56 moritz I've only skimmed it, too tired for proper proof reading
20:56 moritz nom: $\
20:56 p6eval nom 22d23a: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at line 1, near "$\\"␤»
20:57 moritz std: $\
20:57 p6eval std dc62e1d: OUTPUT«[31m===[0mSORRY![31m===[0m�Unsupported use of $\ variable; in Perl 6 please use the filehandle's :ors attribute at /tmp/A9tq4lYqqq line 1:�------> [32m$\[33m�[31m<EOL>[0m�Parse failed�FAILED 00:01 119m�»
20:57 moritz rakudo seemes to have regressed on a lot of those error messages
21:14 sorear colomon++
21:14 sorear proofreeding&
21:16 sorear colomon: &.done-bc should be &.done-cb
21:16 moritz jnthn: any objections to adding an accessors for $!orig in NQPCursorRole or NQPCursor?
21:17 moritz jnthn: that way I could create line numbers from the cursor directly, without going through a match (usefor the the <obs> rule in Perl6::Grammar)
21:18 sorear I didn't see anythign else
21:21 moritz hm, doesn't really seem to help either :(
21:23 jnthn moritz: Note that Perl6::Grammar is still using the older regex engine.
21:23 phenny jnthn: 20:23Z <sorear> tell jnthn /(<foo>) <~~0>/ /(<foo>) (<~~0>)/ /(<foo>) $1=<~~foo>/ What do you imagine the capture trees from these three regexes as?
21:24 moritz jnthn: ok, in method obs() in Perl6::Gramar, how do I get my hands on a $/ object?
21:24 jnthn sorear: Eww. Those would probably make by "just reference the AST from the earlier capture" approach problematic...since that chunk of the AST would want to capture.
21:24 jnthn moritz: If it's a method, you don't have one - you just have self which is a cursor.
21:25 jnthn moritz: What do you need in particular?
21:25 jnthn moritz: Is there not a self.pos() already?
21:26 moritz jnthn: I need $/.orig and $/.from
21:26 sorear jnthn: what uses which grammar engine, and what are the differences between them?
21:27 moritz yes, self.pos, would be good enough
21:27 jnthn sorear: Rakudo still uses nqp-rx's grammar engine + mods to make it use 6model objects.
21:27 moritz sorear: Perl6::Action still uses the old regex engine, but with 6model object
21:27 jnthn sorear: wait, that was unclear
21:27 jnthn sorear: Rakudo still uses nqp-rx's grammar engine + mods to make it use 6model objects for parsing Perl 6.
21:27 moritz erm, Perl6::Grammar
21:27 jnthn sorear: It uses QRegex for a user's grammars and regexes.
21:27 moritz but regexes in rakudo user land use qregex
21:28 jnthn My goal for the January release is that it's all on QRegex.
21:29 jnthn Since it does LTM, is more efficient, and will literally eliminate 1000s of lines of PIR from our codebase.
21:30 sorear jnthn: docs/TODO.S05 has a very terse list of things I have issues with marked DUBIOUS or DISCUSS
21:30 jnthn moritz: cursor does have a .from method
21:30 sorear just fyi
21:31 sorear jnthn: what should happen with / <foo> <( <bar> )> <baz> /; $/.chunks ?
21:31 sorear there are captures outside $/.from ..^ $/.to
21:31 sorear s/^/i.e. when /
21:31 moritz I don't think there are, in $/
21:32 jnthn sorear: The spec read to me like <( and )> just give you a different .to and .from
21:32 moritz $/ doesn't know anything about stuff outside <(...)>
21:32 jnthn moritz wants the less easy answer ;-)
21:32 moritz heh, seems jnthn and I have different ideas about that :-)
21:33 jnthn I can see having the stuff before and after captured could be useful
21:33 jnthn I mean, then you could substitute just a certain bit of text
21:33 sorear moritz: what happens in / (..) & (. <( .) / then?  $0 straddles $/.from
21:33 jnthn But be able to capture and refer to bits on the other side of it.
21:33 jnthn er, on either side of it, I meant.
21:33 moritz sorear: hm, no idea
21:34 jnthn sorear: I've no idea how on earth one would implement tiebreaker 5 efficienlty.
21:34 jnthn Or sanely
21:34 jnthn Or...yeah, please say that can go away :)
21:35 * moritz -> sleep
21:35 jnthn 'night, moritz
21:37 sorear jnthn: I'm not quite sure what it means even...
21:38 jnthn sorear: I think it's trying to say "augmented rules are considered below ones in the grammar in the first place"
21:38 sorear jnthn: I guess .caps and .chunks should warn if any captures overlap the edge of the match
21:38 jnthn And then trying to define an ordering between different monkey-patchings.
21:38 jnthn I guess you could get the meta-object to track such things.
21:38 jnthn Though even then the "distance" concept is weird.
21:39 sorear if it's not a total order, it's not useful as a final tiebreaker
21:39 jnthn sorear: Yeah, and I'm not totally convinced it can be. Plus I'm not convinced it's a useful tiebreaker anyway.
21:39 jnthn I mean, we encourage langauge derivation by subclassing or mixins.
21:39 sorear ditto
21:39 jnthn Both of which are already covered.
21:40 jnthn (by 3)
21:41 jnthn sorear: By the way, how did you handle augment with regard to the bounded serialization?
21:41 sorear jnthn: augment blocks are implicitly INIT phasers
21:41 jnthn sorear: wfm
21:41 mj41 joined #perl6
21:42 jnthn Dunno if TimToady'll have some objections to that interpretation...
21:42 jnthn Feels sane though.
21:42 sorear I'm sure he will.  _I_ have objections to it.
21:42 sorear But I couldn't think of anything better.
21:42 jnthn That's where I got to with it.
21:42 jnthn "This ain't ideal but every other option sucks harder."
21:43 jnthn All the items inside of an augment are declarative, though, so it's only the meta-object "wiring" that is happening at INIT time.
21:44 sorear Right, just a bunch of .^add_method and .^invalidate calls
21:44 sorear (I think .^invalidate needs to disappear from the public API, but that's very todo)
21:44 jnthn Invalidation probably wants to be under the control of the meta-object.
21:45 jnthn OK, really time to try and dig into this native call array stuff...
21:51 jnthn ...if I can remember the design of the thing I was half way through implementing when $dayjob struck.
22:00 imarcusthis yay, managed to render hello world with Mojolicious through Perlito
22:00 imarcusthis and the p5 backend
22:01 dalek nqp: e233dc4 | jnthn++ | src/6model/ (3 files):
22:01 dalek nqp: Add function to the index repr ops table for getting the element stable.
22:01 dalek nqp: review: https://github.com/perl6/nqp/commit/e233dc4f24
22:13 bkolera joined #perl6
22:19 bluescreen10 joined #perl6
22:37 dorlamm joined #perl6
22:52 sbp joined #perl6
22:53 sbp left #perl6
22:53 nsh joined #perl6
23:16 dalek niecza: c6fb1d3 | sorear++ | / (2 files):
23:16 dalek niecza: Remove Match[0] feature which no longer seems a net win
23:16 dalek niecza: review: https://github.com/sorear/niecza/commit/c6fb1d3cbd
23:16 dalek niecza: 7dedef9 | sorear++ | / (3 files):
23:16 dalek niecza: Add Match methods: kv, keys, values, caps, chunks, prematch, postmatch
23:16 dalek niecza: review: https://github.com/sorear/niecza/commit/7dedef92d4
23:17 dalek nqp: 530d322 | jnthn++ | src/NQP/Actions.pm:
23:17 dalek nqp: Implement .REPR in NQP.
23:17 dalek nqp: review: https://github.com/perl6/nqp/commit/530d322703
23:17 dalek nqp: 52f0785 | jnthn++ | src/6model/reprs/CArray.c:
23:17 dalek nqp: Helps to not have void as the return type if you want to return stuff...
23:17 dalek nqp: review: https://github.com/perl6/nqp/commit/52f078531c
23:17 dalek nqp: 6401041 | jnthn++ | src/ (2 files):
23:17 dalek nqp: First couple of ops for indexed repr funcs.
23:17 dalek nqp: review: https://github.com/perl6/nqp/commit/6401041394
23:17 dalek nqp: 31a8dc5 | jnthn++ | src/6model/reprs/CArray.c:
23:17 dalek nqp: Fix bits/bytes thinko.
23:17 dalek nqp: review: https://github.com/perl6/nqp/commit/31a8dc5057
23:20 sorear jnthn: what is the current project stuff?  how does a CArray repr function?
23:20 dalek rakudo/nom: 40091ee | jnthn++ | src/core/operators.pm:
23:20 dalek rakudo/nom: The type-object case of infix:<but> need not .clone().
23:20 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/40091ee169
23:20 dalek rakudo/nom: c4876ea | jnthn++ | / (2 files):
23:20 dalek rakudo/nom: Bump to latest NQP.
23:20 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c4876ea5b8
23:20 dalek rakudo/nom: c7b0aa9 | jnthn++ | src/Perl6/Metamodel/Mixins.pm:
23:20 dalek rakudo/nom: Mixins should preserve the representation of the object being mixed in to.
23:20 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c7b0aa942b
23:21 dalek zavolaj: 6803a5a | jnthn++ | lib/NativeCall.pm6:
23:21 dalek zavolaj: Put in first few bits of C array handling support. Doesn't do much yet, though it just managed to successfully access a C array of doubles passed returned to it.
23:21 dalek zavolaj: review: https://github.com/jnthn/zavolaj/commit/6803a5aae4
23:22 jnthn sorear: The CArray representation mostly just keeps hold of a chunk of memory that it treats like a C array.
23:23 jnthn sorear: The native call engine just finds and passes along that pointer. Or, alternatively, makes an instance of the type in question and sticks the pointer in there.
23:23 jnthn It attempts to give you bounds checking if you create the array yourself. Of course, if it just comes back from C land, there's little it can do to help.
23:25 jnthn Implicit in all of this is that 6model is now starting to understand types of representation beyond "an object with attributes". Which is a helpful part of $research_project to work out how to bootstrap 6model from zero.
23:26 sorear What is the use model for this new representation?
23:26 sorear I don't completely understand the last comment
23:26 jnthn sorear: The NativeCall library exposes a class that uses this representation.
23:26 sorear What is a representation other than a way of stuffing attributes into a memory block?
23:27 sorear jnthn: so you can make a CArray in Perl, use it mostly like an Array, but have O(1) marshalling?
23:28 jnthn sorear: Mostly, I've realized that if you s/attributes/data/, you get some kind of "ubiquitous representation polymorphism".
23:29 jnthn sorear: Yes, the idea is you can work with it just like an array, but under the covers it's making sure you're getting something you can pass off to C.
23:29 jnthn So yes, O(1) mashalling.
23:30 sorear What do you mean by s/attributes/data/ ?
23:30 sorear Are you saying that it is possible now to write classes which use means other than the attribute API to store data?
23:30 jnthn sorear: It was a substitution on your "What is a representation..." comment
23:31 jnthn sorear: Where I'm heading with this is, representation polymorphism seems to abstract nicely beyond just objects, but to data structures in general.
23:31 sorear A CArray is not an object?
23:32 jnthn Hmm, I'm explaining this badly...
23:32 jnthn Yes, it is an object.
23:32 jnthn What I'm trying to get at is that not all objects work on the basis of storing attributes.
23:33 jnthn Some of them want an array-ish interface. Like, CArray.
23:33 jnthn Some of them, like P6int, have never stored attributes at all. Their only interest is boxing.
23:34 jnthn Representations are always about memory management/memory access. They're always orthogonal to type. But there's different "modes" of accessing memory.
23:34 jnthn Which might be boxing/unboxing, attributes, array-ish indexing, etc.
23:40 sorear Ah.
23:40 sorear Are you planning to still have a limited set of repr operations?
23:41 * sorear is simultaneously reading LoL.pm and trying to figure out what this is and how it works
23:41 jnthn Yes.
23:41 sorear Just adding (optional) index operations?
23:42 jnthn Well, I've broken out most of what I had before into sub-protocols.
23:42 jnthn So now a REPR implements a few common things they all have, plus optionally any of attribute access, boxing and indexing.
23:43 jnthn Uninstantiable (the most boring REPR ever) implements none of those.
23:44 * sorear wonders if this means Rakudo will stop using RPAs
23:45 jnthn Yes, it's a step in that kind of direction too. Though if Parrot really *does* want to implement 6model then all of its PMCs will need to be "re-realized" in 6model terms.
23:48 sorear What exactly is LoL currently?
23:49 sorear Where is nqp::p6list defined?
23:49 sorear ah, found the second answer
23:49 jnthn sorear: I didn't quite figure LoL out yet. I know it gets special handling somewhere in the iterator code.
23:50 * jnthn wonders when Pm will next drop by
23:51 jnthn It seems to suceed at not flattening.
23:52 jnthn Getting a write-up of this stuff is one of the things Pm mentioned to me that he's most wanting to do.
23:53 jnthn OK, time for me to relax a bit. Still recovering from two weeks of relatively intense $dayjob.
23:54 jnthn back tomorrow &

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

Perl 6 | Reference Documentation | Rakudo