Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2012-12-05

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:17 skids joined #perl6
00:18 benabik joined #perl6
00:31 tokuhiro_ joined #perl6
00:33 dalek perl6-examples: 1af516d | (Felix Herrmann)++ | euler/prob018-felher.pl:
00:33 dalek perl6-examples: [euler] add solution for problem 18
00:33 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/1af516d99d
00:34 [Coke] for masak:
00:34 [Coke] -> (19:33) From Strider, to random:
00:34 [Coke] - You have a problem. You think "I know, I'll use bits." Now you have 10
00:34 [Coke] - problems.
00:35 dalek perl6-examples: b55835e | (Felix Herrmann)++ | euler/ (2 files):
00:35 dalek perl6-examples: [euler] add solution for problem 67
00:35 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/b55835e649
00:56 anuby joined #perl6
00:59 sorear o/ anuby
01:00 anuby hi
01:01 anuby i merely come office
01:07 hypolin joined #perl6
01:33 ifim joined #perl6
01:44 [Coke] rn: my $u = "\x[4444,4445]"; say $u.codes;
01:44 p6eval rakudo e2f2dc, niecza v24-5-g599cbcb: OUTPUT«2␤»
01:44 [Coke] rn: my $u = "\x[4444,4445]"; say $u.graphs;
01:44 p6eval niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: Unable to resolve method graphs in type Str␤  at /tmp/_Xn7jXVahd line 1 (mainline @ 4) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4208 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4209 (module-CORE @ 580) ␤  at /home/…
01:44 p6eval ..rakudo e2f2dc: OUTPUT«No such method 'graphs' for invocant of type 'Str'␤  in block  at /tmp/Gs_XKTdXkx:1␤␤»
01:55 dalek roast: 59f4e89 | coke++ | S0 (2 files):
01:55 dalek roast: niecza fudge
01:55 dalek roast: review: https://github.com/perl6/roast/commit/59f4e89439
01:56 dalek niecza: fa7713b | coke++ | t/spectest.data:
01:56 dalek niecza: run fudged tests
01:56 dalek niecza: review: https://github.com/sorear/niecza/commit/fa7713b37b
02:04 FROGGS_ joined #perl6
02:22 kcwu joined #perl6
03:01 hypolin joined #perl6
03:26 noggle joined #perl6
04:03 ira joined #perl6
04:03 ira nick quester
04:04 ira left #perl6
04:04 kcwu joined #perl6
04:06 ira joined #perl6
04:12 fgomez joined #perl6
04:16 xenoterracide hmm
04:17 xenoterracide my rakudo build doesn't include a perl6-debug
04:19 TimToady comes with star, seems
04:20 xenoterracide so something I'd have to install after building from git
04:24 BaggioKwok joined #perl6
04:36 Psyche^ joined #perl6
04:49 noggle joined #perl6
04:49 xenoterracide http://privatepaste.com/96e1f26c24 < what?
04:50 xenoterracide t/new.t .. No such method 'postcircumfix:<( )>' for invocant of type 'PseudoStash'
04:52 sisar joined #perl6
04:52 sorear r: MY()
04:52 p6eval rakudo e2f2dc: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&MY' called (line 1)␤»
04:52 sorear r: MY.()
04:52 p6eval rakudo e2f2dc: OUTPUT«invoke() not implemented in class 'MY'␤  in block  at /tmp/trToAqUHeX:1␤␤»
04:52 sorear r: MY::.()
04:52 p6eval rakudo e2f2dc: OUTPUT«No such method 'postcircumfix:<( )>' for invocant of type 'PseudoStash'␤  in  at src/gen/BOOTSTRAP.pm:852␤  in any  at src/gen/BOOTSTRAP.pm:836␤  in block  at /tmp/of3M7TE55C:1␤␤»
04:52 doy r: class A { }; my $fmn = "A"; my $impl = ::( $fmn ).new; say $impl
04:52 p6eval rakudo e2f2dc: OUTPUT«No such method 'postcircumfix:<( )>' for invocant of type 'PseudoStash'␤  in  at src/gen/BOOTSTRAP.pm:852␤  in any  at src/gen/BOOTSTRAP.pm:836␤  in block  at /tmp/BRbptseP1L:1␤␤»
04:53 sorear n: class A { }; my $fmn = "A"; my $impl = ::( $fmn ).new; say $impl
04:53 p6eval niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type PseudoStash␤  at /tmp/C9vGvabk1E line 1 (mainline @ 6) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4208 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4209 (module-COR…
04:53 sorear what
04:55 doy rn: ::( "foo" )
04:55 p6eval rakudo e2f2dc: OUTPUT«No such method 'postcircumfix:<( )>' for invocant of type 'PseudoStash'␤  in  at src/gen/BOOTSTRAP.pm:852␤  in any  at src/gen/BOOTSTRAP.pm:836␤  in block  at /tmp/okXiWQ2ntX:1␤␤»
04:55 p6eval ..niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type PseudoStash␤  at /tmp/PQWiNJPR7H line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4208 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4209 (module-COR…
04:55 jdv79 joined #perl6
04:56 xenoterracide it does not like the whitespace
04:56 doy rn: ::("foo")
04:56 p6eval rakudo e2f2dc:  ( no output )
04:56 p6eval ..niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at Niecza.StashCursor.Core (System.String key, Boolean final, Niecza.StashCursor& sc, Niecza.Variable& v, Niecza.Variable bind_to) [0x00000] in <filen…
04:57 doy rn: ::("foo bar")
04:57 p6eval rakudo e2f2dc:  ( no output )
04:57 p6eval ..niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at Niecza.StashCursor.Core (System.String key, Boolean final, Niecza.StashCursor& sc, Niecza.Variable& v, Niecza.Variable bind_to) [0x00000] in <filen…
04:58 sorear n: class A { }; my $fmn = "A"; my $impl = ::($fmn).new; say $impl
04:58 p6eval niecza v24-5-g599cbcb: OUTPUT«A.new(...)␤»
04:59 sorear xenoterracide++
04:59 sorear crazzy LTM bugs
05:01 xenoterracide http://youtu.be/kf0yQbrY9Pw < what?
05:02 jdv79 i don't remember that being so blue
05:20 Chillance joined #perl6
05:20 telex joined #perl6
05:38 telex joined #perl6
05:43 quester_ joined #perl6
05:55 hlin_laptop joined #perl6
05:58 hypolin joined #perl6
06:03 kaleem joined #perl6
06:05 noggle joined #perl6
06:06 hlin_laptop joined #perl6
06:09 birdwindupbird joined #perl6
06:12 fgomez joined #perl6
06:17 SamuraiJack joined #perl6
06:21 GlitchMr joined #perl6
06:28 GlitchMr http://perl6advent.wordpress.co​m/2012/12/05/a-perl-6-debugger/
06:28 phenny GlitchMr: 04 Dec 23:23Z <japhb> tell GlitchMr Regarding SIGSEGV from run(), see Rakudo bug #115390 -- in my bench script, I've had to convert loops with multiple run() calls to multiple loops with only one run() call each (as the last statement in the loop block).
06:28 GlitchMr Why this isn't in 2012 category?
06:30 GlitchMr I'll have to look into what's wrong with my only commit to Rakudo
06:31 GlitchMr Perhaps I was abusing undefined behavior
06:31 GlitchMr https://github.com/rakudo/rakudo/blo​b/00932520b63b725235ef2de43f2c8c08c7​51e7f5/src/core/control.pm#L167-178
06:37 FROGGS_ joined #perl6
06:48 FROGGS_ joined #perl6
06:51 cibs joined #perl6
07:05 FROGGS joined #perl6
08:11 kcwu joined #perl6
08:28 Kharec joined #perl6
08:31 quester left #perl6
08:35 Hor|zon joined #perl6
08:45 kresike joined #perl6
08:45 kresike good morning all you happy perl6 people
08:50 FROGGS morning kresike
08:52 kresike FROGGS, o/
08:54 fgomez joined #perl6
09:10 augustus joined #perl6
09:10 noggle_ joined #perl6
09:11 augustus hello, anybody hanging out here?
09:11 felher Who wrote the 'project euler' blogpost?
09:11 felher o/ augustus
09:12 diakopter augustus: what's up
09:12 augustus well i just got the latest from git, it's been about a year since I did
09:13 augustus wanted to check and see how some things were working, particularly phasers
09:13 augustus it seems like some things work better, but it's hard to tell since the old version doesn't run anymore I guess
09:15 marloshouse joined #perl6
09:16 sorear hey augustus
09:16 augustus yes sorear?
09:17 felher augustus: I can not comment on old versions not running anymore. But since you noted that you are interested in phasers -- there will be a perl6 advent calendar post on the fifteenth which is named 'Phasers set to stun: some neat use case'. You might want to read that :)
09:17 augustus I will certainly, it is an important topic to me ;) Mostly I wanted to find out if there was more current documentation on them
09:18 augustus they seem to work about 50% or so?
09:18 augustus but it is hard to tell what is intended vs what is not working yet
09:19 diakopter augustus: I'm curious, why phasers
09:19 tadzik augustus: how about http://perl6.org/compilers/features?
09:20 sorear o/ tadzik
09:20 tadzik bah. I found a screenshot from a project I once started, but I can't find the code anywhere :(
09:20 tadzik sorear: o/
09:20 augustus diakopter: features that promote correctness appeal to me, and phasers promote correctness ;)
09:21 augustus tadzik: I mean in the itty little details; phasers are *there* but don't always work as intended (?)
09:21 tadzik if they don't, it's a bug to be filed :) Any particular example>?
09:22 FROGGS IMO jnthn was working on phasers within the last two months and fixed stuff
09:22 tadzik that's more of a fact than an opinion :)
09:22 augustus well for one, UNDO never triggers and KEEP doesn't trigger except when loop naturally loops.  hard to tell when they are supposed to trigger
09:24 FROGGS augustus: see this for example: https://github.com/rakudo/ra​kudo/blob/nom/docs/ChangeLog
09:25 augustus FROGGS: thank you, I had looked at the latest changelog but should review further back
09:26 FROGGS augustus: here are the spectests for phasers: https://github.com/perl6/ro​ast/tree/master/S04-phasers
09:27 FROGGS so you can see what is working
09:30 augustus FROGGS: Thank you, I will look through those to see how they are supposed to work
09:30 FROGGS ya, but I dont see UNDO or KEEP there...
09:30 FROGGS maybe NYI
09:31 am0c joined #perl6
09:31 augustus they have keep/undo, but only with respect to functions, not loops
09:32 augustus and I'm guessing that the return value evaluating to True in a boolean context is what determines which gets run?
09:33 augustus although my expectation on KEEP/UNDO has to do with exceptions being thrown or not
09:33 fhelmberger joined #perl6
09:34 sorear loops are a kind of function.
09:34 sorear niecza has KEEP and UNDO but not fail.  I don't like fail.
09:34 wamba joined #perl6
09:36 augustus sorear: what I meant was that the test code provided does not included a loop, and I have been unabel to trigger an UNDO within a loop.
09:39 dayangkun joined #perl6
09:39 sorear n: for 1..10 { UNDO { say "undo called" }; die 5 }
09:39 p6eval niecza v24-5-g599cbcb: OUTPUT«undo called␤Unhandled exception: 5␤  at <unknown> line 0 (ExitRunloop @ 0) ␤  at /tmp/DE9FeblqRa line 1 (ANON @ 5) ␤  at /tmp/DE9FeblqRa line 1 (mainline @ 5) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4208 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE…
09:39 sorear n: for 1..10 { UNDO { say "undo called" }; last }
09:39 p6eval niecza v24-5-g599cbcb: OUTPUT«undo called␤»
09:39 jnthn phenny: tell GlitchMr looks like somebody already fixed my category error
09:39 phenny jnthn: I'll pass that on when GlitchMr is around.
09:40 bbkr jnthn++ # excellent post about debugger
09:41 jnthn augustus: It's not about true vs false, it's about defined/undefined.
09:42 jnthn r: for 1..10 { KEEP { say "kept" }; UNDO { say "undid" }; $_ %% 2 ?? 1 !! Mu }
09:42 p6eval rakudo e2f2dc: OUTPUT«undid␤kept␤undid␤kept␤und​id␤kept␤undid␤kept␤undid␤kept␤»
09:42 augustus jnthn: ok, that is good to know.
09:43 augustus jnthn: I take it Mu is undefined?
09:44 jnthn augustus: Well, undefined values in Perl 6 are represented by type objects, so you can have typed undefined values. But Mu is the most general kind of undefined, yes.
09:44 sorear Mu is undefined
09:44 sorear Any is undefined
09:44 sorear 5 is not undefined
09:45 jnthn But Int is
09:45 jnthn :)
09:45 sorear augustus' question is quite cromulent if you interpret "undefined" as an adjective :p
09:45 diakopter n: Int.defined.say
09:45 p6eval niecza v24-5-g599cbcb: OUTPUT«False␤»
09:45 augustus ok, so I do I get next/last to return undefined? next Mu doesn't work
09:45 sorear augustus: Did you see the n: example I gave?
09:45 diakopter r: Int.defined.say
09:45 p6eval rakudo e2f2dc: OUTPUT«False␤»
09:46 sorear n: for 1..10 { UNDO { say "undo called" }; next } # augustus, read this
09:46 p6eval niecza v24-5-g599cbcb: OUTPUT«undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤»
09:46 augustus sorear: yes sorry, I saw.  I think it may be a difference between nicza and rakudo?
09:46 jnthn sorear: Is it explicitly spec'd to do that?
09:47 augustus it seems that next/last skip the entire leave chain
09:47 jnthn sorear: Or more a case of "it's the thing that makes most sense"?
09:47 jnthn nr: for 1..10 { LEAVE { say "undo called" }; next }
09:47 p6eval niecza v24-5-g599cbcb: OUTPUT«undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤»
09:47 p6eval ..rakudo e2f2dc:  ( no output )
09:48 jnthn um, that's certainly wrong.
09:48 sorear augustus: I did not realize that was a rakudo-specific question
09:48 augustus sorry, I have rakudo, but my question relates to how thigns are supposed to be
09:48 augustus i don't know for some if it's intended or not
09:48 jnthn augustus: Niecza gets this one right, Rakudo has it wrong in this particular case.
09:49 augustus ok I see
09:49 sorear jnthn: I think next is specced to take a return value in at least one case (not the obvious one)
09:49 jnthn r: loop { LEAVE { say "undo called" }; next }
09:49 p6eval rakudo e2f2dc: OUTPUT«(timeout)»
09:49 jnthn At least it's consistently wrong...
09:49 sorear jnthn: so I would conjecture that plain next uses Nil, which is undefined
09:50 jnthn sorear: OK, makes sense.
09:50 * sorear learned a new name recently: penumbral argument
09:50 augustus Another quick question: if a block exits by an exception being thrown, that will be undefined and trigger UNDO?  I get an error about &throw being an undefined function so I don't know how to throw an exception
09:51 sorear augustus: exceptions are thrown by "die", and that absolutely calls UNDO
09:51 augustus when I tried die, the program just ended
09:51 augustus is "throw" no longer being used then?
09:51 sorear did you have a CATCH in scope?
09:51 augustus no
09:52 sorear throw was never used in Perl
09:52 augustus hmm I googled and found some perl6 thing using throw lol
09:52 sorear I think you may need CATCH or try to get a stack unwind
09:53 sorear r: LEAVE say "bye"; die "cow"
09:53 p6eval rakudo e2f2dc: OUTPUT«bye␤»
09:53 sorear r: UNDO say "bye"; die "cow"
09:53 p6eval rakudo e2f2dc: OUTPUT«bye␤»
09:53 sorear maybe some p6eval weirdness
09:55 augustus ok with a CATCH, die does what I'd expect, thank you.
09:56 augustus can you explain how CONTROL works? It triggers for me on next/last, but I when I say $_ it doesn't tell me what triggered it
09:56 * jnthn guesses he should take care of $dayjob tasks before looking into the next/last...
10:00 woosley joined #perl6
10:02 hoelzro updated gist on my advent calendar post: https://gist.github.com/4205120
10:02 hoelzro the more I think about this, the more I wonder if this should be a series of posts
10:02 hoelzro maybe the advent calendar should just whet the reader's appetite?
10:04 sorear augustus: CONTROL is triggered on next/last and tells the loop what to do.
10:04 sorear r: loop { CONTROL say $_; last }
10:04 p6eval rakudo e2f2dc: OUTPUT«===SORRY!===␤Missing block␤at /tmp/ys0vY66TA7:1␤»
10:04 sorear r: loop { CONTROL { say $_ }; last }
10:04 p6eval rakudo e2f2dc: OUTPUT«␤  in block  at src/gen/CORE.setting:429␤  in block  at src/gen/CORE.setting:486␤  in block  at /tmp/mJRETvsdBp:1␤␤»
10:05 sorear r: loop { CONTROL { say $_.PARROT }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«No such method 'PARROT' for invocant of type 'X::AdHoc'␤  in block  at /tmp/OyqE99KUBF:1␤  in block  at /tmp/OyqE99KUBF:1␤␤»
10:05 sorear r: loop { CONTROL { say $_.WHAT }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«X::AdHoc()␤»
10:05 sorear r: loop { CONTROL { say $_.keys }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«0␤»
10:05 sorear r: loop { CONTROL { say $_.^methods }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«message Numeric <anon> backtrace throw rethrow resumable resume fail is-compile-time Str gist␤»
10:05 sorear r: loop { CONTROL { say $_.message }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«␤»
10:05 sorear r: loop { CONTROL { say $_.perl }; last }
10:05 p6eval rakudo e2f2dc: OUTPUT«X::AdHoc.new(payload => "")␤»
10:06 sorear My guess is that rakudo is cheating a bit on CONTROL exceptions because they are so common.
10:06 sorear Niecza does.
10:07 augustus what else generates control exceptions?  I wouldn't think next/last were so common. And is there some element of that output which I can use to distinguish between next/last?
10:09 augustus or rather I guess, since you suspect they might be cheating a little, do you know if it's intended that $_ can be examined to make this distinction?
10:14 sorear augustus: next, last, return, redo, goto, leave, proceed, succeed (and thus when)
10:14 leont joined #perl6
10:15 LoRe joined #perl6
10:15 sorear n: loop { CONTROL { say $_.perl } ; last }
10:15 p6eval niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at GState..ctor (Niecza.Compartment setting, System.String orig, Niecza.P6any actions) [0x00000] in <filename unknown>:0 ␤  at Cursor..ctor (Niecza.Co…
10:15 sorear n: loop { last }
10:15 p6eval niecza v24-5-g599cbcb:  ( no output )
10:15 sorear n: for 1..10 { CONTROL { say $_.perl } ; last }
10:15 p6eval niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at GState..ctor (Niecza.Compartment setting, System.String orig, Niecza.P6any actions) [0x00000] in <filename unknown>:0 ␤  at Cursor..ctor (Niecza.Co…
10:15 sorear n: for 1..10 { CATCH { say $_.perl } ; last }
10:16 p6eval niecza v24-5-g599cbcb:  ( no output )
10:16 flussence rn: class H { has $!b = 1; method foo { say $!b } }; H.new(b => 2).foo;
10:16 sorear n: for 1..10 { CONTROL { say "moo" } ; last }
10:16 p6eval rakudo e2f2dc, niecza v24-5-g599cbcb: OUTPUT«1␤»
10:16 p6eval niecza v24-5-g599cbcb: OUTPUT«moo␤»
10:16 sorear n: for 1..10 { CONTROL { say "moo$_" } ; last }
10:16 flussence am I doing something completely wrong there?
10:16 p6eval niecza v24-5-g599cbcb: OUTPUT«(timeout)»
10:17 sorear n:  my $c; for 1..10 { CONTROL { $c=$! } ; last }; say $c
10:17 rindolf joined #perl6
10:17 p6eval niecza v24-5-g599cbcb: OUTPUT«Any()␤»
10:17 felher jnthn++ # nice debugger blogpost
10:17 sorear n:  my $c; for 1..10 { CONTROL { $c=$_ } ; last }; say $c.perl
10:17 p6eval niecza v24-5-g599cbcb: OUTPUT«Unhandled exception: System.NullReferenceException: Object reference not set to an instance of an object␤  at GState..ctor (Niecza.Compartment setting, System.String orig, Niecza.P6any actions) [0x00000] in <filename unknown>:0 ␤  at Cursor..ctor (Niecza.Co…
10:17 sorear n:  my $c; for 1..10 { CONTROL -> $x { $c=$x } ; last }; say $c.perl
10:17 p6eval niecza v24-5-g599cbcb: OUTPUT«[31m===[0mSORRY![31m===[0m��Missing block at /tmp/nZ2cN8ECkV line 1:�------> [32mmy $c; for 1..10 { CONTROL [33m�[31m-> $x { $c=$x } ; last }; say $c.perl[0m��Parse failed��»
10:18 sorear augustus: at one point in the past you could inspect $_ in CONTROL in Niecza, but that feature seems broken
10:18 augustus ok, thanks for all your help.
10:18 sorear augustus: it was never very useful, the value in $_ was just a small integer code like 3 for last :D
10:18 sorear augustus: I think eventually there should be spec for this
10:18 augustus well if it was well defined
10:18 jnthn Maybe they should be typed exceptions...
10:18 augustus yes so long as it's specced and you can count on it
10:18 jnthn X::Control::Next etc.
10:19 jnthn Guess moritz++ may have a take on this. :)
10:19 augustus i would vote for that
10:19 augustus if I had a vote lol ;)
10:19 augustus if they were typed, then would CONTROL just be an alias for CATCH then?
10:19 sorear flussence: private attributes cannot be assigned in constructors or inspected using .perl, because it makes Damian sad
10:20 jnthn augustus: No
10:20 flussence sorear: oh, thanks
10:20 bloonix joined #perl6
10:20 augustus jnthn: because control exceptions aren't like other exceptions I take it?
10:20 sorear flussence: if people keep coming in here with that question I'll revert the spec change
10:21 sorear p6l thinks purity of the "private attribute" concept trumps usability
10:22 sorear I acquiesced then, but my regret only grows
10:22 flussence it's definitely not following POLS. I think I just wasted 2 hours looking for a bug that wasn't there...
10:24 augustus sorear: when you are posting ouput from niecza is that from an online evaluator, or are you copy and pasting from your local machine?
10:24 jnthn augustus: Something like that.
10:25 augustus jnthn: ok some exceptions are more equal than others lol :)
10:25 sorear augustus: look carefully, the replies are not coming from sorear...
10:26 jnthn sorear: Not being able to refactor your privates safe in the knowledge you aren't breaking API is also a usability issue.
10:26 augustus yes, I saw that, which is what made me suspect an online evaluator, but I wasn't sure
10:26 augustus ohh is that what the n: does? run in niecza?
10:27 augustus and r: rakudo I'm guessing lol
10:27 flussence jnthn: would be helpful if it at least threw a warning there to say that code's wrong...
10:28 sorear augustus: yes!  you can use it too!
10:30 augustus i presume it's considered uncouth to run something that generates more than a couple lines of output?
10:30 flussence nah
10:30 sorear augustus: it's automatically truncated to one line
10:30 flussence r: say 'a' x 3000
10:30 p6eval rakudo e2f2dc: OUTPUT«aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa​aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa​aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa​aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa​aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa​aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa…
10:31 augustus ohh ok good, don't want to be a nuisance lol
10:31 sorear p: say $*PERL
10:31 p6eval pugs: OUTPUT«␤»
10:32 sorear p: say $*VM
10:32 p6eval pugs: OUTPUT«␤»
10:32 sorear p: say GLOBAL::
10:32 p6eval pugs: OUTPUT«*** ␤    Unexpected end of input␤    at /tmp/M2ELxMXJih line 1, column 13␤»
10:32 sorear anyway, I had better sleep
10:32 sorear be bold!
10:32 sorear &
10:33 jnthn .oO( I normally lean towards being italic myself... )
10:34 augustus thanks for all your help sorear
10:37 _jaldhar joined #perl6
10:39 masak g'antenoon, #perl6
10:39 FROGGS hi masak
10:40 masak [Coke]: [backlog] ooh, hadn't seen the "bits -> 10 problems" variation before :) #autopun
10:40 jnthn masak: There's a bug for you to file in le backlog too :)
10:42 masak :) getting there.
10:42 masak nr: for 1..10 { LEAVE { say "undo called" }; next }
10:43 p6eval niecza v24-5-g599cbcb: OUTPUT«undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤undo called␤»
10:43 p6eval ..rakudo e2f2dc:  ( no output )
10:43 masak hm, may I change the text here? it's confusing. :P
10:43 masak nr: for 1..10 { LEAVE { say "x" }; next }
10:43 p6eval niecza v24-5-g599cbcb: OUTPUT«x␤x␤x␤x␤x␤x␤x␤x␤x␤x␤»
10:43 p6eval ..rakudo e2f2dc:  ( no output )
10:43 * masak submits rakudobug
10:44 masak I'm sure I could sit down one evening with the phasers, go through S04 carefully, and shake out two or three bugs ;)
10:48 masak sorear: I'm fine with reverting the pure privateness of private attributes, but I think it should be accompanied by a proper discussion, just like last time.
10:49 * jnthn for one is not fine with it.
10:49 augustus masak: not sure if this is strictly related to phasers or if it's a bug, we were also discussing how/whether next/last could trigger UNDO (for example saying next Mu;) and how you could tell which CONTROL exception triggered from within a CONTROL phaser
10:50 masak sorear: keep in mind that even *without* .perl and constructor arguments, Perl 6 leans heavily to protecting the private attributes. you can't even reach them in a derived class or 'augment' re-declaration.
10:50 masak augustus: yeah, it's possible that that needs clarification, actually.
10:52 augustus personally, I would want a way to do next/last with a rollback, but would expect the default to KEEP. it seems the rakudo bug is skipping the entire LEAVE sequence if that helps
10:52 jnthn LEAVE and KEEP vs UNDO are handled it the same place, so if it's skipping one of them it'll be skipping the lot.
10:53 masak leaving a block should always trigger LEAVE, and exactly one of KEEP/UNDO.
10:53 jnthn Right.
10:53 augustus ok
10:54 masak (that's not to say that an individual block can't have several phasers of these types, of course)
10:55 augustus right; begin-type phasers go in order of declaration, end-type in reverse order right?
10:56 masak right.
10:56 grondilu joined #perl6
10:56 augustus and they're some kind of attribute that you can manipulate at run time right?
10:57 grondilu I got a "No object at index 164" when trying to (re)bootstrap panda
10:57 masak grondilu: that's a serialization error. could be due to version skew.
10:58 masak ...somewhere.
10:58 jnthn Probably stale .pir files somewhere
10:58 grondilu oh I know
10:58 grondilu I remember panda asking me to manually compile something last time
10:59 jnthn I thought I'd nailed the various pre-comp bugs and could start on some automated handling of that but I seem to recall hearing there still is at least one...
10:59 tadzik panda asking to manually compile stuff?
10:59 tadzik oh my. It became self-conscious
11:00 rindolf Hi all.
11:00 rindolf http://paste.debian.net/214489/
11:00 grondilu yeah iirc
11:00 grondilu /usr/local/src/rakudo/install/lib/parrot/4.10.0-de​vel/languages/perl6/site/lib/JSON/Tiny/Actions.pm
11:00 rindolf What can I do about it?
11:00 grondilu ^ this one
11:01 grondilu well, removing the pir or recompiling it didn't solve the problem anywya
11:02 rindolf I am getting a "Confused" message with latest nom.
11:02 masak rindolf: it would help if that paste contained the source code, too.
11:02 rindolf masak: sure.
11:03 rindolf masak: here - http://paste.debian.net/214490/
11:04 masak rindolf: =cut
11:04 masak rindolf: I'm not aware that Perl 6's Pod has '=cut'
11:05 masak tadzik: what's your opinion?
11:05 rindolf masak: then how do I terminate it?
11:05 Su-Shee_ joined #perl6
11:05 masak rindolf: please read S26.
11:05 masak rindolf: line 63: 'foreach'!?
11:06 masak rindolf: as a human parser, I'm bailing out of this code now.
11:06 jnthn r: foreach 1..10 { }
11:06 p6eval rakudo e2f2dc: OUTPUT«===SORRY!===␤Unsupported use of 'foreach';  in Perl 6 please use 'for'␤at /tmp/LrJKHZWFMw:1␤»
11:06 masak please re-do so that it actually uses Perl 6 keywords :)
11:06 jnthn :)
11:06 jnthn At least we catch that one...
11:06 jnthn std: =cut
11:06 p6eval std a8bc48f: OUTPUT«ok 00:00 40m␤»
11:06 rindolf masak: it was originally a Perl 6 program.
11:06 rindolf masak: it was originally a Perl 5 program.
11:07 tadzik ah, =cut
11:07 augustus masak: It is possible to do policy injection by dynamically adding/removing phasers?
11:07 tadzik =cut is a legal Pod Block name
11:07 masak rindolf: yeah, it looks it. it's insufficiently translated.
11:07 jnthn tadzik: ah, yes :)
11:07 tadzik so you can =cut, or =begin cut, or =para cut
11:07 tadzik but we should probably warn if someone does that
11:07 tadzik like, when would you mean that? Probably never
11:07 masak tadzik: we should probably error if someone does that.
11:07 tadzik maybe even error, yes
11:07 masak tadzik: '=cut' is all-lowercase, so it's reserved, no?
11:07 masak then we can error.
11:08 tadzik true
11:09 rindolf Confused again.
11:09 rindolf What kind of an error message is "confused"?
11:11 masak a bad one.
11:11 masak we do our best to replace it with better ones when we can.
11:11 masak STD is still state-of-the-art on this.
11:11 jnthn rindolf: It means "There's a syntax error that the parser can't classify any better for you"
11:11 masak Niecza does better than Rakudo, but Rakudo is getting there.
11:11 rindolf jnthn: well, it points to line #1.
11:11 masak rindolf: generally, if you know Perl 6 syntax, you won't get many "Confused" error messages.
11:12 jnthn rindolf: Yeah, 'cus Rakudo doesn't implement the highwater algorithm yet.
11:12 rindolf masak: don't look at me - I'm just a code monkey.
11:13 jnthn At least once we have that we'll be able to give a much better idea of exactly where things came unstuck...
11:13 rindolf I take orders, and perform them in the worst possible way.
11:13 rindolf http://paste.debian.net/214497/ - well this is what I have right now - should I use STD on it?
11:15 masak rindolf: not passing judgment. just letting you know that "Confused" isn't all that common once you know the syntax.
11:15 rindolf masak: OK.
11:16 masak rindolf: we should still fix those errors to be better for new users, of course.
11:16 rindolf masak: yes, indeed.
11:16 rindolf masak: also the line number.
11:17 jnthn If I can catch enough of a break from $dayjob stuffs, I should get at lesat the position bit of the highwater stuff in for December Rakudo release, which should mean we get much better position info in cases like this one.
11:18 Gothmog_ joined #perl6
11:24 not_gerd joined #perl6
11:24 not_gerd hello, #perl6
11:24 FROGGS ho not_gerd
11:24 FROGGS hi*
11:25 not_gerd rindolf: it's probably the missing , after the blocks when using &map
11:27 masak std: my @array = 1, 2; map { 42 } @array
11:27 p6eval std a8bc48f: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Strange text after block (missing comma, semicolon, comment marker?) at /tmp/F7Uy7nypIE line 1:â�¤------> [32mmy @array = 1, 2; map { 42 }[33mâ��[31m @array[0mâ�¤    expecting any of:â�¤       horizontal whitespaceâ�¤  infix or meta-infixâ�¤    infixed f…
11:27 masak arguably that's a better error message for that.
11:29 rindolf OK, STD to the rescue.
11:29 rindolf $.k++; ==> now this gives me a cannot assign to read-only value.
11:30 masak rindolf: you probably didn't declare the attribute 'is rw'
11:30 masak they're read-only by default.
11:30 rindolf masak: ah, OK.
11:30 leont joined #perl6
11:31 wamba joined #perl6
11:33 augustus I was reading apocalypse 12 (maybe the wrong place to look), and I must be missing something.  How do you add properties to an object on the fly without touching the class?
11:34 jnthn augustus: S12 is probably terribly out of date; see S12. But you're looking for mixins.
11:35 rindolf OK, now I'm getting a run time error. :-(
11:35 rindolf http://paste.debian.net/214500/ - why does this throws Wrong s100!
11:36 masak r: class C {}; my $d = C.new but role { has $.z is rw }; $d.z = 42; say $d.z
11:36 p6eval rakudo e2f2dc: OUTPUT«42␤»
11:36 masak augustus: see ^
11:36 augustus ahh ok
11:37 masak rindolf: no idea. glad to hear you got your code running, though.
11:37 masak rindolf: when asking questions of the form "why does it do X?", it helps if you remove all the code that's not relevant. that may also help you in seeing the problem.
11:37 rindolf masak: OK.
11:39 rindolf masak: here is a reduced code - http://paste.debian.net/214502/
11:41 masak rindolf: so, you're running <complicated function> lots of times, and your question is "why isn't it 11:43 < masak> nr: for 1..10 { LEAVE { say "x" }; next }
11:41 masak 11:43 <+p6eval> niecza v24-5-g599cbcb: OUTPUT«x␤x␤x␤x␤x␤x␤x␤x␤x␤x␤»
11:41 masak 11:43 <+p6eval> ..rakudo e2f2dc:  ( no output )
11:41 masak 11:43  * masak submits rakudobug
11:41 masak oops.
11:41 masak and your question is "why isn't it 86613?"
11:41 masak rindolf: I... I don't know why it isn't 86613. it's your code.
11:41 masak it's not obvious to me why it should be 86613.
11:42 not_gerd rindolf: add debug output to your for 1 .. 99 and you'll see that it'll yield 86613, but not in the expected position
11:42 * grondilu is back
11:43 cognominal joined #perl6
11:43 rindolf Oh wait, it was 11 .. 99
11:44 augustus is there some code you can point me to where I can see how to iterate/search/add/remove phasers?
11:44 rindolf An extra 1 got lost.
11:45 rindolf OK, now it appears to run, but it's very slow.
11:46 masak rindolf: welcome to #perl6 :)
11:46 timotimo for fast, try niecza. otherwise youre pretty much out of luck for now :(
11:46 * masak .oO( the initiation rites of a fiver: "it doesn't compile" -- "write Perl 6 like this" -- "it's slow" -- "yup" )
11:47 not_gerd rindolf: type annotations *can* help, but Rakudo just is incredibly slow
11:47 dakkar joined #perl6
11:47 not_gerd (still faster than it used to be, though)
11:49 FROGGS masak++ # :o)
11:49 masak there are various things you can do to avoid being terribly slow. not using 'for' loops is one thing. using native types is another.
11:49 FROGGS it's not that fast, but it is still awesome
11:50 masak and yeah, this is a temporary condition. we're steadily improving.
11:50 masak FROGGS: no need to defend a bad state of affairs.
11:50 masak FROGGS: we want to fix the slowness, plain and simple.
11:50 jnthn masak: "Don't use for" is bad advice, fwiw
11:51 FROGGS ya, sure, but all these magic that you can do, it is just more awesome than say Perl 5
11:51 jnthn masak: It can be faster.
11:51 jnthn r: my $s = now; my $a; for 1..100000 { $a++ }; say $a; say now - $s
11:51 p6eval rakudo e2f2dc: OUTPUT«100000␤2.4631678␤»
11:51 jnthn r: my $s = now; my $a; while $a < 100000 { $a++ }; say $a; say now - $s
11:51 p6eval rakudo e2f2dc: OUTPUT«use of uninitialized variable $a of type Any in numeric context  in block  at /tmp/_RorDS1cMr:1␤␤100000␤2.2285593␤»
11:51 jnthn Um.
11:52 jnthn The for version won on my box :S
11:52 jnthn 0.519 vs .0715
11:52 jnthn *0.715
11:53 masak so... the "'for' loops are slow" thing doesn't hold anymore? nice.
11:53 jnthn masak: Depends what you do with them.
11:53 dalek perl6-examples: fc6cc65 | (L. Grondin)++ | euler/prob001-grondilu.pl:
11:53 dalek perl6-examples: [Euler] #001 brute force, very short code
11:53 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/fc6cc654bd
11:53 jnthn masak: But I think the numbers above give an indication that the for with a range can match while loops.
11:54 masak aye.
11:55 augustus From S06 I'm unclear, can I make up my own traits? Are they discoverable at runtime?
11:55 not_gerd r: my $s = now; my int $a; while $a < 100000 { $a++ }; say $a; say now - $s
11:55 p6eval rakudo e2f2dc: OUTPUT«Cannot assign to a non-container␤  in sub postfix:<++> at src/gen/CORE.setting:3077␤  in block  at /tmp/RbjBf91vgn:1␤␤»
11:55 not_gerd r: my $s = now; my int $a; while $a < 100000 { $a = $a + 1 }; say $a; say now - $s
11:55 p6eval rakudo e2f2dc: OUTPUT«100000␤1.05353699␤»
11:57 Kharec joined #perl6
11:58 jnthn augustus: Traits are compile time, but yes, you can make your own
11:59 jnthn star: use NativeCall; sub malloc() returns OpaquePointer is native { * }; my $mem = malloc(128);
11:59 p6eval star 2012.10: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'malloc' will never work with argument types (int) (line 1)␤    Expected: :()␤»
11:59 jnthn oops :)
11:59 jnthn star: use NativeCall; sub malloc(int) returns OpaquePointer is native { * }; my $mem = malloc(128);
11:59 p6eval star 2012.10:  ( no output )
11:59 augustus Ok, i see an advent calendar entry from last year that may show me how to make my own.  I understand they are compile time; I was wondering if that meta data is lost at runtime.
11:59 jnthn Anyway, the "is native" trait there is provided by the NativeCall module.
12:00 jnthn augustus: It's up to your trait implementation to attach any metadata.
12:00 FROGGS r: multi trait_mod:<is>(Routine $r, :$awesome!) { say 42 }; sub a is awesome { ... }
12:00 p6eval rakudo e2f2dc: OUTPUT«42␤»
12:01 jnthn r: sub trait_mod:<is>(Routine $r, :$lol!) { $r does role { method lol() { 42 } } }; sub foo is lol { }; say &foo.lol
12:01 p6eval rakudo e2f2dc: OUTPUT«42␤»
12:02 leont left #perl6
12:03 augustus ahh ok so the Routine paramters is the one being modified
12:04 moritz right
12:04 * moritz wants 'is rw' renamed to 'is assignable'
12:05 jnthn yes, first arg is the declarand
12:06 masak moritz! \o/
12:06 augustus lets see, now to assign a trait to an anymous block, do I have to use a different syntax for the block?  It won't take {...} is trait
12:06 masak moritz: 'assignable' doesn't seem Huffmanly right.
12:08 moritz masak: but 'rw' and 'ro' carry conotations that confuse the user
12:09 jnthn We could always abbreviate assignable to...er, let's not :P
12:09 FROGGS hehe
12:09 augustus 'rw' and 'ro' just seem archaic, not wrong, but weird when the rest of perl 6 is so umm... modern?
12:11 masak moritz: I think the whole concept of readonlyness is still unresolved in Perl 6. especially between container objects and their contents.
12:13 augustus S06 specifically says you can't put traits on "Pointy Blocks."  how do I assign traits to blocks?
12:15 jnthn You can add them to both using the "also" syntax
12:15 jnthn r: sub trait_mod:<is>(Block $r, :$lol!) { $r does role { method lol() { 42 } } }; my $x = -> { also is lol; }; say $x.lol
12:15 p6eval rakudo e2f2dc: OUTPUT«42␤»
12:15 jnthn r: sub trait_mod:<is>(Block $r, :$lol!) { $r does role { method lol() { 42 } } }; my $x = { also is lol; }; say $x.lol # I think this works too
12:15 p6eval rakudo e2f2dc: OUTPUT«42␤»
12:16 augustus ah, inside the block
12:16 jnthn yes, preceded by an "also"
12:16 jnthn btw you can do this generally
12:16 jnthn class Foo { also is BaseFoo; } # can write the inheritance stuff like this
12:17 augustus I take it a Routine IsA Block?
12:17 jnthn Yes
12:18 augustus ok.  On a conceptual level, would you consider it better to assign phasers traits or roles to denote what policy they are implementing?
12:18 augustus I understand the trait in turn assigns a role
12:21 moritz it totally depends on what you do
12:21 moritz some traits simply change existing attributes
12:21 moritz others (like "is export") only change external information
12:21 yves_ joined #perl6
12:22 augustus yes, sorry, not all traits would assign roles, but in order to retain information all the way to runtime, you have to assign a role yes?
12:22 bowtie joined #perl6
12:23 augustus *well, add new information and have to stick around.  I understand you could change existing attributes without assigning a new role
12:23 jnthn augustus: If you want the information to be attached to the object, and the object doesn't already have a way to model the information, yes, you'd want to mix in a role.
12:24 moritz if you want to attach extra information to an object which you don't control, yes, you'd mix in a role
12:24 moritz jnthn++ was faster :-)
12:24 jnthn :)
12:27 augustus let me be more specific.  Lets say I want to scan existing phasers of a block, and see if any of them implmenet Policy X (potentially version Y from Vendor V etc etc).  If so, remove them, and add my own implmentation of Policy X.  This Policy meta-data, would you figure you assign it with a trait, or just adding roles directly?
12:28 augustus This seems like a gut-feel question, not a right or wrong kind of question ;)
12:29 * jnthn throws in a cautionary remark about &foo.phasers being somewhat experimental and not actually in the spec yet :)
12:29 jnthn But yeah, you would probably find traits the most convenient way to attach the info.
12:30 jnthn NEXT { also is SomePolicy; blah... }
12:31 augustus ok, this is the vibe I was getting.  Thanks for the feedback.
12:36 augustus oh, and I think that this kind of policy injection is a significant use case, so I would encourage &foo.phasers to be formalized so module writers can depend on it  :)
12:37 jnthn augustus: Well, as with all meta-programming stuff, it's trying to stike a difficult balance between giving implementations the flexibility they need to evolve and providing a common API for fiddling.
12:40 dalek Perlito: f15277a | (Flavio S. Glock)++ | README-perlito5-js:
12:40 dalek Perlito: Perlito5 - js - docs: add another link
12:40 dalek Perlito: review: https://github.com/fglock/​Perlito/commit/f15277a72c
12:42 augustus yes, you don't want to be exposing the wrong details through introspection, and I can't say as I have any particular insight as to how to balance it.  But I do know some things are meaningful on a conceptual/semantic level, and you can lock in a model for that
12:43 augustus even when implementation details later change; and of course then sometimes you have to do an incompatible v2 if your model missed something
12:43 rindolf OK, my code runs faster with Niecza.
12:46 augustus Thanks again everyone for all your help, but my time is up for the day.
12:47 moritz does YAPC::EU 2013 already have a website? if yes, where?
12:48 PacoAir joined #perl6
12:51 Kharec joined #perl6
13:01 SmokeMachine joined #perl6
13:02 SamuraiJack joined #perl6
13:09 bbkr "Sink (void) context causes a Failure to throw" - from doc.perl6.org/Failure. what exactly is this "Sink context"?
13:16 moritz bbkr: if the return value from an expression is not used (ie not assigned, bound or passed to somewhere else) it is said to be in sink context
13:16 moritz bbkr: it's not yet implemented (though I've started several branches to do that; the latest is qast-sink-1)
13:18 bbkr r: my $x = Exception.new.fail; say "alive" # so this should fail once sink context is implemented?
13:18 p6eval rakudo e2f2dc:  ( no output )
13:18 moritz bbkr: no
13:18 moritz bbkr: because the exception is assigned to $x, so it's not in sink context
13:19 moritz sub f() { fail('oh noes') }; f(); 1;
13:19 moritz here f is called in sink context
13:19 moritz so the Failure would be in sonk context too
13:19 moritz and thus would turn fatal
13:20 bbkr moritz: thanks, everything is clear now
13:20 benabik joined #perl6
13:21 moritz bbkr: you're welcome
13:24 bbkr moritz: one more thing - does context forcing counts as sink context in incoming implementation, for example ~f() ?
13:25 hoelzro who has time to look at my revised advent calendar notes? =)
13:27 rindolf Hi all.
13:27 rindolf Malformed has at /home/shlomif/Download/unpack/perl/Perl6​/perl6-examples/euler/prob149-shlomif.pl line 36:
13:27 rindolf ------>     has⏏ int $.k is rw = 1;
13:27 rindolf How can I give a typo annotation to has?
13:28 moritz typo annotation!
13:28 moritz r: class A { has int $.x }
13:28 p6eval rakudo e2f2dc:  ( no output )
13:28 moritz r: class A { has int $.x is rw }
13:28 p6eval rakudo e2f2dc: OUTPUT«===SORRY!===␤Cannot create rw-accessors for natively typed attribute '$!x'␤»
13:28 moritz r: class A { has int $.x = 1 }
13:28 p6eval rakudo e2f2dc:  ( no output )
13:28 moritz rindolf: try it without the 'is rw'
13:29 moritz bbkr: well ~f() doesn't put f() into sink context
13:29 moritz but ~f() might itself be in sink context
13:29 rindolf moritz: but how will I modify it afterwards?
13:29 moritz rindolf: from inside the class, by assigning to $!k
13:29 rindolf moritz: ah.
13:30 bbkr moritz: thanks again!
13:32 rindolf Malformed has at /home/shlomif/Download/unpack/perl/Perl6​/perl6-examples/euler/prob149-shlomif.pl line 36:
13:32 rindolf ------>     has⏏ int $!k = 1;
13:32 timotimo what's the line before it?
13:35 rindolf class FiboRand {
13:35 rindolf http://paste.debian.net/214520/ - here's the nopaste.
13:39 timotimo r: class FiboRand { has int $!k = 1; }
13:39 p6eval rakudo e2f2dc:  ( no output )
13:39 timotimo are you perhaps on a too old version of rakudo?
13:39 timotimo star: class FiboRand { has int $!k = 1; }
13:39 p6eval star 2012.10:  ( no output )
13:39 rindolf I'm using Niecza.
13:39 timotimo n: class FiboRand { has int $!k = 1; }
13:39 p6eval niecza v24-5-g599cbcb: OUTPUT«[31m===[0mSORRY![31m===[0m��Malformed has at /tmp/KOGInHMLGl line 1:�------> [32mclass FiboRand { has[33m�[31m int $!k = 1; }[0m��Parse failed��»
13:39 timotimo n: class FiboRand { has Int $!k = 1; }
13:39 p6eval niecza v24-5-g599cbcb:  ( no output )
13:39 rindolf Ouch.
13:39 moritz rindolf: oh, I think niecza doesn't support native types
13:39 timotimo try capital I, yeah
13:40 rindolf moritz: ah.
13:42 not_gerd r: (class { has int $!foo = 42 }).new
13:42 p6eval rakudo e2f2dc: OUTPUT«Cannot assign to a non-container␤  in block  at src/gen/CORE.setting:752␤  in method BUILDALL at src/gen/CORE.setting:730␤  in method bless at src/gen/CORE.setting:720␤  in method new at src/gen/CORE.setting:705␤  in block  at /tmp/W5d_w7Ypvr:1␤␤»
13:43 not_gerd jnthn: ^^^
13:43 jnthn not_gerd: known/RT'd already
13:43 not_gerd thanks
13:43 jnthn Waiting for somebody (probably me...) to make another pass over the native stuff
13:44 jnthn Need to solve the $native-int++ one to...
13:44 jnthn *too
13:46 dalek perl6-examples: e130ce9 | (L. Grondin)++ | rosalind/lia-grondilu.pl:
13:46 dalek perl6-examples: [rosalind] LIA
13:46 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/e130ce9be2
13:54 dalek perl6-examples: 0625935 | (Shlomi Fish)++ | euler/prob149-shlomif.pl:
13:54 dalek perl6-examples: Add a (very slow so far) solution for Euler #149.
13:54 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/06259354e5
13:54 dalek perl6-examples: 3036039 | colomon++ | euler/prob149-shlomif.pl:
13:54 dalek perl6-examples: Merge pull request #10 from shlomif/master
13:54 dalek perl6-examples:
13:54 dalek perl6-examples: Euler No. 149
13:54 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/3036039ddf
13:55 * rindolf nuzzles dalek
13:55 rindolf Exterminate!
13:56 rindolf colomon++ # Merging my pull request.
13:56 colomon Mind you, I think you're right that there's got to be a more perl6y way of doing that.  ;)
13:57 rindolf I've been thinking of using an infinite stream.
13:57 rindolf Will it be trimmed?
13:58 colomon it?
13:58 masak in what use case?
13:59 masak infinite basically presumes lazy. unless you really like programs that hang.
14:03 hash_table joined #perl6
14:17 atrodo joined #perl6
14:18 timotimo grondilu: how do you feel about adding comments to the rosalind example where you explain what the problem means, or a link to the problem statement on the website?
14:20 grondilu timotimo: I don't understand what you mean
14:20 moritz when looking at the rosalind solutions, one sees a solution without knowing what the problem is
14:20 timotimo https://github.com/perl6/perl6-example​s/blob/master/rosalind/lia-grondilu.pl - looking at this file and not knowing much about rosalind, i have no idea what's going on
14:20 grondilu there is already the code of the problem, so it's easy to check it out on rosalind.info
14:20 moritz (I guess)
14:21 timotimo oh? is "lia" the problem code?
14:21 grondilu it is
14:21 timotimo oh, indeed
14:21 grondilu http://rosalind.info/problems/lia
14:22 not_gerd might be a good idea to add the direct address to README
14:22 grondilu I'll add in README an explanation on how to make a link to rosalind given a problem code
14:25 skids joined #perl6
14:29 dalek perl6-examples: 2b09646 | (L. Grondin)++ | rosalind/README:
14:29 dalek perl6-examples: adding explanation on how to find a problem on rosalind given its code
14:29 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/2b09646646
14:29 dalek perl6-examples: 648b159 | (L. Grondin)++ | euler/prob149-shlomif.pl:
14:29 dalek perl6-examples: Merge branch 'master' of github.com:perl6/perl6-examples
14:29 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/648b159e97
14:31 not_gerd grondilu++
14:31 grondilu not_gerd: thanks but there's no need to increment me, dalek does it automatically ;)
14:34 grondilu though I'm not sure my IRC  and  github login are reckognised as the same thing :/
14:34 moritz they aren't
14:34 grondilu oh ok
14:34 moritz there's a (pretty outdated) mapping in the CREDITS file in parrot
14:35 not_gerd also, I appreciate your work on perl6-examples
14:36 kaare_ joined #perl6
14:39 rurban joined #perl6
14:42 Rix joined #perl6
14:48 * [Coke] wonders why we're using PARROT.
14:48 [Coke] that shouldn't have been uc'd, whoops.
14:49 [Coke] Seems like something in perl6/mu would be more apropos.
14:49 xilo_ joined #perl6
14:49 jnthn [Coke]: Prolly hysterical raisons.
14:52 colomon Am I correct in thinking that \w will match Unicode symbols and not just ASCII?
14:53 masak jnthn: is "raisons" a typo of "reasons" or "raisins"? :P
14:53 masak (or surprise French?)
14:54 rjt_pl joined #perl6
14:55 rurban colomon: with icu, yes
14:55 colomon rurban: danke
14:56 Kharec joined #perl6
14:58 jnthn masak: oui, oui :P
15:00 * grondilu has never tasted hysterical raisins :P
15:00 masak grondilu: and yet they're so common in development circles ;)
15:03 rurban colomon: but maybe even without icu also, only normalization is done by icu, so charclasses could also be handled without icu.
15:04 stopbit joined #perl6
15:04 colomon rurban: I think I have icu anyway, and the fact the program has been running for five minutes and my computer cooling fan just came on suggests it's getting much farther than it did before.  :)
15:05 rurban fan detection :)
15:07 tokuhiro_ joined #perl6
15:09 jnthn .oO( "I think my program has an infinite loop..." "Va fan!" )
15:11 xinming_ joined #perl6
15:11 masak phenny: sv en "Va fan!"?
15:11 phenny masak: "What the hell !" (sv to en, translate.google.com)
15:11 masak close enough :)
15:12 GlitchMr joined #perl6
15:12 masak though invoking the devil seems rather disproportionate for an infinite loop :) especially if it's only a suspected one.
15:12 masak maybe invoke some minor demon instead?
15:12 jnthn Worth it for a bad bi-language pun :P
15:13 masak I'm still holding out for your tri-language puns, they're the really good ones :P
15:13 [Coke] QUAD LANGUAGE PUN!
15:14 masak three or more, yes :)
15:14 jnthn I'm trying to remember if I found one that involved at least 3.
15:14 masak jnthn: "Min cheese e kass"
15:14 masak still the best one :)
15:14 jnthn No, no
15:15 jnthn "Min cheeze e sirsly kass" :P
15:15 masak hahaha
15:15 masak there's at least three languages in there.
15:15 jnthn :)
15:16 * [Coke] hurls https://gist.github.com/4216414 for anyone looking for some easy rakudo fudging targets.
15:17 [Coke] (there are two that work as is that aren't being run.)
15:17 masak I really like that leftmost column.
15:17 masak how can some files have A set without S and some have both S and A set?
15:18 * [Coke] is surprised jnthn didn't turn on t/spec/S05-modifier/perl5_0.t
15:18 masak does that mean that the ones with just A are empty?
15:18 [Coke] masak: it's from tools/up* . I don't overthink it, I just use to find likely unfudge targets.
15:19 [Coke] (that's a current run with any "0/0" removed)
15:21 masak [Coke]: ok. just curious :)
15:22 masak the "does 'all' imply 'some'" question reminds me of syllogisms, though.
15:23 hoelzro hey guys, what would be the best way to differentiate a Perl 6 file from a Perl 5 one? I'm thinking of adding better support for Perl 6 to ack
15:24 alester Last time I raised this issue in here, y'all said "Extensions are best"
15:24 phenny alester: 29 Aug 14:25Z <[Coke]> tell alester I'm seeing "technical debt" mentioned in several presentations at this $dayjob-internal conference. \o/
15:24 PerlJam I'm not sure there's a "best" yet.  There's just some stuff that kinda works.
15:24 rjt_pl masak: Reminds me more of MP's professor of logic.
15:25 masak "MP"?
15:25 cognominal joined #perl6
15:25 rjt_pl Monty Python :-)
15:25 masak the... argument clinic?
15:26 rjt_pl No it isn't!
15:26 masak :P
15:26 moritz hoelzro: 'use v6;' is a sure indicator that it's Perl 6
15:26 PerlJam hoelzro: files named *.p6 or *.pm6 are likely perl 6.   files that contain "use v6" or "module Foo" are likely perl 6.
15:26 hoelzro moritz: is 'use v6' pretty reliable?
15:27 moritz hoelzro: I've never seen a Perl 5 file 'use v6;'
15:27 alester But within how many lines of the first?
15:27 jnthn [Coke]: hm, I thought perl5_0.t was still epic fail...if it is workier now, it can be fudged :)
15:27 moritz so in that direction is it rather reliable
15:27 alester How many lines do we have to read before we hit the "use v6"
15:27 hoelzro moritz: I'm more concerned about Perl 6 files that don't include use v6
15:27 alester Also, do modules need the "use v6;"?
15:27 PerlJam hoelzro: I'd start by looking at S01:103
15:28 moritz alester: no; it's just good practise
15:29 alester hoelzro: My concern about the use v6 is that it would be first instance of us checking beyond the first line of the file for determining file-type
15:31 hoelzro fair enough
15:31 hoelzro I just want --perl6 to work =(
15:32 hoelzro I was thinking of adding a new ack filter for it, and not putting the perl6 rule in the defaults
15:34 masak hoelzro: there are a bunch of other heuristics you could apply to a source file to detect if it's Perl 6.
15:34 masak hoelzro: I bet something fairly accurate could be built just by detecting certain source substrings.
15:35 hoelzro I don't think coming up with a fairly accurate detector would be terrible, but I know that alester is concerned about looking past the extension/first line
15:36 masak oh, ok.
15:36 not_gerd .p6/.pl6/.pm6, shebang (Rakudo, Niecza, Pugs?) and use v6 in first lines sound resonable to me
15:36 masak well, if those are the limitations, then you will have to live with not detecting all Perl 6 files, I guess.
15:36 PerlJam How many lines to read into the file could be parameterized though.   Let the user choose how much to read.
15:37 rjt_pl joined #perl6
15:37 hoelzro my current rules in my own ackrc check the shebang and .p[lm]?6$
15:37 GlitchMr hoelzro: I usually use ack with perl6 with --perl
15:37 phenny GlitchMr: 09:39Z <jnthn> tell GlitchMr looks like somebody already fixed my category error
15:37 hoelzro but a lot of Perl 6 out there uses .pl/.pm =(
15:37 GlitchMr It doesn't work with .p6, but that's rare
15:38 asdf__ joined #perl6
15:38 dakkar joined #perl6
15:39 GlitchMr Also, Perl 5 programs will be valid Perl 6 programs when Perl 6 implementations will support Perl 5.
15:40 hoelzro I thought that was no longer a goal?
15:40 masak it's not a particularly easy goal, if that's what you mean :)
15:40 GlitchMr It isn't easy
15:40 GlitchMr But I think that Perlito already does that
15:41 hash_table joined #perl6
15:41 GlitchMr And AFAIK niecza also has experimental Perl 5 support
15:42 hoelzro very cool
15:42 not_gerd hoelzro: I'd just add a rule to detect .pl/.pm as perl6 if it starts with use v6 (or six-y shebang) and call it quits
15:42 GlitchMr Specification mentions either rakudo/niecza or pugs in shebang
15:42 hoelzro not_gerd: that would be good, but how far do we look for use v6?
15:42 PerlJam hoelzro: 10 lines
15:42 PerlJam :-)
15:43 GlitchMr It isn't easy
15:43 alester hoelzro and I are discussing getting out a beta of ack 2.0
15:43 alester and he foolishly said "I was thinking we could get a beta out by Christmas"
15:44 alester to which I could only respond...
15:44 GlitchMr Which Christmas?
15:44 not_gerd hoelzro: just beyond the shebang (assuming p5/p6 ever get to interoperate) and tell your users to not do stupid things
15:45 GlitchMr lol
15:45 alester If there's one good thing about having been in development for 11 years now is that we get a good running joke out of it.
15:45 alester not_gerd: The problem with "stupid things" is that there is no definition of what "smart things" is at this point.
15:45 hoelzro 11 = 5 + 6!
15:45 hoelzro coincidence?!
15:45 hoelzro ;)
15:45 alester There is no definition that "This is how you make a Perl 6 file be a Perl 6 file"
15:45 GlitchMr hoelzro: that calculation isn't valid
15:45 GlitchMr To begin with, 6! is 720.
15:46 hoelzro heh
15:46 imarcusthis joined #perl6
15:46 flussence it's valid in base-724
15:46 hoelzro 11 is 5 + 6.
15:46 hoelzro true
15:47 GlitchMr The problem is that better than grep (usually called ack) is very popular. Surely some of users would want to do "stupid things".
15:48 alester What is stupid?
15:48 alester What are you calling stupid?
15:48 GlitchMr alester: I was referencing what not_gerd has said
15:48 not_gerd alester: not starting a .pl/.pm file containing perl6 with use v6
15:48 alester Yes, but what exactly is a "stupid thing"
15:48 alester Why is that stupid?
15:48 alester Is it a requirement?
15:49 not_gerd because for historical reasons, .pl files are invoked with perl, and that will fail unpredictably if use v6 isn't used
15:49 GlitchMr By the way, I don't think ack is better than grep. To begin with, the regexpes in ack aren't guaranteed to fast. In grep, they are guaranteed to be O(NM)
15:50 alester GlitchMr: Excellent.  Then don't use it.
15:50 PerlJam heh
15:50 am0c joined #perl6
15:50 not_gerd just brainstorming, though - what about having --perl, --perl5 and --perl6 options, with the caveat that the --perl5 can have false positives and the latter false negatives?
15:51 GlitchMr But that regex performance issue affects most of programming languages with few exceptions that aren't popular anyway.
15:51 not_gerd (anyway, once we can freely intermix p5 and p6, the point becomes moot)
15:51 hoelzro well, it's not called "faster than grep"
15:51 * not_gerd can dream of the future
15:51 alester Also, the "betterthangrep" in the domain name doesn't specify what "better" means
15:51 alester and it also doesn't refer to ack.
15:52 alester See also: http://betterthangrep.com/more-tools/
15:52 flussence better = uses a sane regex syntax? :)
15:52 alester which are also better than grep, for some values of "better" and for some set of users.
15:52 hoelzro inouropinionanimprovementupongrep.com
15:52 alester GlitchMr: If you're hoping to engage in some sort of debate about the appropriateness of ack as your tool of choice, you're going to be disappointed.
15:52 GlitchMr Just wondering, is git grep better than grep?
15:53 alester I can't tell you without you defining what "better" means.
15:54 GlitchMr I usually use 'git grep' for searching.
15:54 not_gerd or, to make it more symmetric: --perl for both p5/p6, --perl5 and --perl6 for files that can be positively recognized as one or the other
15:55 hoelzro I get that a lot these days.
15:55 alester GlitchMr: Excellent.
15:55 hoelzro not_gerd: that's an interesting take on it; I hadn't considered that before
15:55 alester I'll also suggest that it's possible to have two different tools to choose from.
15:56 GlitchMr I like 'git grep' because 1) It works like grep 2) It ignores backup files 3) It ignores binary data
15:56 alester not_gerd, hoelzro: I'm just wary about --perl6 not being adequately reliable.
15:56 cognominal joined #perl6
15:56 GlitchMr I propose instead to not add --perl6 and adding *.p6 files detection to --perl
15:57 not_gerd alester: that was (part of) my reasoning behind having --perl catch both perl5 and perl6
15:57 masak not everyone names their Perl 6 source files *.p6
15:58 not_gerd also, what should happen with files that intermix { use v5;} and { use v6; } blocks?
15:58 alester masak: Exactly.  And there is no standard yet.
15:58 masak likely never will be.
15:58 alester Perl 6 is still in footpath territory, and we're talking about paving sidewalks.
15:58 masak not everyone uses *.pl for their Perl 5 code.
15:59 GlitchMr std: use v5; print/regexp/;
15:59 p6eval std a8bc48f: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Bogus term at /tmp/d866jMaCoj line 1:â�¤------> [32muse v5; print/regexp/[33mâ��[31m;[0mâ�¤    expecting any of:â�¤      prefix or termâ�¤ whitespaceâ�¤Parse failedâ�¤FAILED 00:01 52mâ�¤Â»
15:59 masak I've heard people insist that the .pl ending is for Prolog code.
15:59 alester And maybe for them it is.
15:59 * hoelzro uses .pro
15:59 GlitchMr Actually, it is
15:59 masak personally, I tend not to use a file ending at all.
15:59 kresike bye folks
16:00 masak I don't see why I should. from the outside, it's an executable file which happens to be a script.
16:00 GlitchMr Only .pm is magical for Perl 5.
16:00 alester GlitchMr: Except when it's Perl.
16:00 GlitchMr There is NOTHING special for .pl files
16:00 alester There is no one canonical answer.
16:01 masak indeed.
16:05 hoelzro I don't care what extension (if any) people use for Perl 6 scripts
16:05 hoelzro that's up to personal taste
16:06 hoelzro I would just like ack to detect them properly =)
16:06 hoelzro and maybe that's not a reasonable goal at the moment
16:06 alester hoelzro: That's my feeling, too.  That was my understanding a year or two ago, and it still is based on today's discussion.
16:06 masak well, detecting .p6 seems like a safe bet. it's just that it's not going to capture everything.
16:07 GlitchMr Actually, it won't catch most scripts... but it will catch my December wiki
16:07 masak if you only detect on file endings, you'll never catch my files without file endings. if you detect on shebang lines, too, you're better of, since I tend to put them in.
16:07 FROGGS joined #perl6
16:08 GlitchMr The problem with .p6 is that it's practically used only for executables
16:08 GlitchMr Usually most of logic is in .pm files
16:08 hoelzro masak: I currently check for .p6/.pm6 and the shebang line
16:08 GlitchMr And NOBODY uses .pm6
16:08 hoelzro really?
16:08 hoelzro I do...=(
16:08 jnthn STD.pm6 does :P
16:09 GlitchMr Well, ok
16:09 masak I tend to use .pm
16:09 jnthn Rakudo happily recognizes it.
16:09 masak I think .pm6 is a bit silly.
16:09 GlitchMr Official grammar does use it, but does anything else do
16:09 hoelzro and that's the issue
16:09 hoelzro not that people use .pm for Perl 6
16:09 hoelzro but that my technique currently doesn't register those files as Perl 6 code
16:10 masak generally, I try to avoid marking things as explicitly Perl 6. I know Perl 6 is a separate language from Perl 5, but I'm still not willing to mark everything up like that.
16:11 FROGGS masak: as long as you dont upload Perl 6 stuff to PAUSE ;o)
16:11 masak it's been done. not by me, though.
16:12 GlitchMr Actually, I think that some time ago somebody did upload Perl 6 stuff to PAUSE
16:12 masak I know both moritz and szabgab tried it.
16:12 GlitchMr But that was long time ago
16:12 masak with fairly disappointing results. documentation doesn't render right, for example.
16:12 * TimToady thinks of that as new wine in old wineskins
16:12 FROGGS ya, of course
16:12 masak I think there were other infrastructural problems.
16:12 GlitchMr But this is confusing, as PAUSE is intended to be used only with Perl 5 modules
16:12 not_gerd alester, hoelzro: see https://gist.github.com/4216992
16:13 GlitchMr For example, CPAN Testers could totally get confused when seeing Perl 6 module
16:13 masak GlitchMr: and yet we dearly want a CPAN eventually.
16:13 FROGGS masak: the indexer reads the module's version too, this doesnt work either
16:14 FROGGS IMO CPAN is one of the greatest thing, we need that
16:14 FROGGS things*
16:14 GlitchMr Isn't ecosystem CPAN already
16:15 FROGGS well, when talking about CPAN I really mean PAUSE+cpan client (panda) and search.perl.org (modules.perl.org)
16:16 FROGGS we still need a few improvements
16:16 FROGGS (and dists)
16:16 GlitchMr Something like CPAN or NPM registry?
16:16 FROGGS and a testers matrix
16:16 alester hoelzro: Do you have a ticket on this issue?  I think that not_gerd's gist would be a good start of one as far as ideas.
16:16 rurban How do you guys get the nice formatting in wordpress blog posts? Pasting from MS Word?
16:16 FROGGS GlitchMr: NPM?
16:16 hoelzro alester: good idea! I do!
16:16 GlitchMr FROGGS: https://npmjs.org/
16:17 alester But really, just bringing up CPAN points to the issues that are much bigger than ack.
16:17 alester How does PAUSE handle Perl 6 files?
16:17 GlitchMr It doesn't.
16:17 GlitchMr We are using perl6 ecosystem for now.
16:17 GlitchMr But this isn't even close to CPAN
16:17 not_gerd rurban: I used markdown to write the article and just copied the generated HTML to WP
16:18 * jnthn just wrote the post straight in the WP editor
16:18 GlitchMr By ecosystem, I mean https://github.com/perl6/eco​system/blob/master/META.list
16:18 rurban hmn, jonathans posts are specially nice
16:18 FROGGS alester: the main problem is that you can make a distribution (a bundle with a specific version) yet, so even having an upload portal wont help that much
16:18 FROGGS cnt*
16:18 FROGGS cant*
16:20 alester The Perl 6 CPAN will be the 800 pound gorilla of defining behaviors.
16:21 FROGGS that might be true
16:21 * hoelzro coins the term "6PAN"
16:21 TimToady already been done
16:21 hoelzro =(
16:21 FROGGS cool, 6pan.org is still available
16:22 BinGOs prior art is no barrier to a patent
16:22 pmurias joined #perl6
16:23 pmurias masak: rakudo got uploaded to PAUSE ;)
16:23 TimToady .oO(6pandoratheexplorer)
16:24 [Coke] back in the day, parrot was shipped that way.
16:24 hoelzro TimToady: sounds like a search tool =)
16:24 [Coke] someone, IIRC, got paid a big grant to map out 6pan stuff.
16:24 [Coke] so, be sure to dig for that paper before going off on your own.
16:25 Rix joined #perl6
16:25 masak [Coke]: are you thinking of MarkOv and http://cpan6.org/ ?
16:26 pmurias [Coke]: https://metacpan.org/module/Rakudo::Star
16:27 masak from that page: "CPAN6 is not even usable on the moment (as is Perl6)" :(
16:27 FROGGS a bit outdated
16:28 flussence that guy needs a slap for domain-squatting.
16:28 masak it's no fun to have a page that was last updated in 2010 make statements about the usability of Perl 6.
16:28 masak flussence: what, why? he is developing a project called cpan6.
16:28 pmurias it seems tempting to reuse cpan testers by making perl6 modules put on cpanm use Rakudo::Star to run their tests ;)
16:29 flussence masak: yeah, the site *says* it's under development. Doesn't mean it is though.
16:29 BinGOs cpanm != CPAN
16:29 * alester posts an orange diamond "Under Construction" animated GIF
16:29 masak flussence: that's not what I meant. I meant it's an appropriate domain name for a project with that name.
16:30 masak flussence: it hardly qualifies as "domain squatting" in any reasonable sense of the word.
16:30 rurban MarkOv would certainly be happy to use rakudostar to run the tests
16:30 rurban Someone just should kick his lazy ass, esp. if he/she is in the neitherlands.
16:30 BinGOs pmurias: and ironically cpanm is the one CPAN client that doesn't send CPAN tester reports.
16:31 cognominal joined #perl6
16:31 Celelibi joined #perl6
16:32 flussence it just seems wrong (and rude) to grab a site like that to ride on the perl 6 name, while contributing nothing in the other direction.
16:32 alester flussence: Or maybe someone nicely ask him about it.
16:33 alester The guy who registered rakudo.org was pretty cool about letting the project use it.
16:33 rurban Wellm his plan was to create a pause6 and cpan6, but then he went the xml way...
16:33 rurban http://cpan6.org/papers/cpan6-impl.pdf
16:33 timotimo hah, "the neitherlands"
16:34 moritz :-)
16:34 rurban converting all that mess to YAML and then it could be doable.
16:34 not_gerd that's where you get when you take a wrong turn on your way to neverland
16:34 flussence YAML? Why not $three-million-formats.pick()?
16:34 timotimo is the logo from the left composed of bits of the ubuntu logo? >_>
16:35 moritz I think everything on cpan6.org is older than Ubuntu :-)
16:36 rurban I'm sure he would love to get cpan6 functional
16:36 GlitchMr For me Perl 6 should support multiple module versions
16:36 masak I dislike when people talk about "slapping" or "kicking" someone who went as far as writing a specification and a web page for their project. feels a bit lacking in appreciation.
16:36 GlitchMr Just like Node.js already allows.
16:36 rurban masak: yes, sorry. I regret it
16:36 Chillance joined #perl6
16:37 rurban Liz invited him to the Perl summit
16:37 masak which was very good.
16:37 masak he does initiate collaborations. and his heart is in the right place.
16:38 masak I just think that his design as it stands is pretty far away from what Perl 6 needs.
16:38 rurban we have github nowadays, we just need an index
16:38 flussence masak: you're right. I shouldn't care. There's people paying for the site's development, they can care instead :)
16:39 masak flussence: if you correlate rudeness with number of abandoned projects, you'd probably consider me very rude.
16:39 not_gerd bye, #perl6
16:39 not_gerd left #perl6
16:40 TimToady rurban: yes, though github is just one way to turn an identity into a module; the important thing is to be sure that we know how to specify identity
16:41 FROGGS GlitchMr: what exactly do you mean by "multiple module versions"?
16:41 GlitchMr For example, module A requires module B version 0.1.*. Module C requires module B version 0.2.*.
16:41 timotimo "use ACME::Cat(v0.1)"
16:42 masak timotimo: there's no need to invent syntax for this. it's all in S11.
16:42 * masak feels a bit grumpy today :)
16:42 FROGGS GlitchMr: ohh, would that work?
16:42 FROGGS masak------^ ?
16:42 timotimo great
16:43 FROGGS timotimo: http://perlcabal.org/syn/S11.html#Versioning # this tab is open on my laptop for a week now
16:44 TimToady FROGGS: you want S11:570 specifically
16:45 FROGGS TimToady: what is 570 ?
16:45 TimToady line number
16:45 TimToady in the pod file
16:45 FROGGS ohh, must open with another editor to see that ;o)
16:45 TimToady the irclog will make that into a link
16:45 moritz FROGGS: check the public IRC logs; there S11:570 is a link to a specific line
16:45 FROGGS moritz: thanks
16:47 masak always nice to see new people discover the goodness of the IRC logs :)
16:47 masak moritz++
16:47 FROGGS ya, the irclog is pretty handy
16:48 FROGGS okay, so it should work to have multiple versions... but since we dont have versions implemented it should be NYI
16:49 TimToady s/versions/identities/ is how I think of it
16:50 FROGGS ya, could be two different auth's too
16:50 TimToady a version is just an arbitrary sequential tag for (part of) an identity, while an auth is an unordered one of those
16:50 TimToady git has pretty much demonstrated you don't need versions to track identities
16:51 TimToady but for official modules, it's the identity and the readonly-ness that are important
16:51 TimToady since if a module is not readonly, it's merely a container identity, which doesn't tell you much about what the module really does
16:53 TimToady note that the filename-via-INC is container identity, hence not suitable for official modules
16:53 TimToady fine for prototyping and such, of course
16:54 TimToady but that's why S11 distinguishes official modules from unofficial
16:54 TimToady and I don't think the unofficial/official boundary should be seen at the CPANish boundary
16:55 TimToady a site should have a way to make their own modules official
16:55 TimToady just as you can gave a git repo of your own, where everything is tracked by identity
16:56 TimToady s/be seen at/be seen as existing only at/
16:56 FROGGS I think I get what you mean
16:57 TimToady it's basically what rurban++ was getting at; the git model of identity is close to what we need for our module libraries
16:58 TimToady and name/version/auth is just a mapping to that identity
16:59 FROGGS I dont know what you mean by "git model of identity"
16:59 TimToady the name of anything in git is just its crypto-checksum
17:02 TimToady which stands in for the actual identity of the file, which is the actual entire file
17:02 TimToady just as value types in p6 have a .WHICH that is the value itself
17:04 TimToady the identity of any value is simply the value itself (by which I mean the abstract value that includes its type, not just the bits in memory)
17:04 rurban Go's goinstall has also a nice hackish way of installing things. First it looks for a core module of that name, and then it looks at github.
17:04 FROGGS I was thinking that we make a checksum when installing a dist to local disk to have something unique, but what you said sound like we should maybe do that when bundling dists or when uploading it to a 6PAN
17:04 TimToady modules are just immutable value types
17:05 rurban Now go has this dashboard as index: http://godashboard.appspot.com/ where you can submit your package
17:06 FROGGS he, most things start with "go"
17:06 TimToady FROGGS: yes, a module must have a unique global identity from the time of submission, not just locally
17:07 cognominal joined #perl6
17:07 FROGGS will there be several 6PANs? or just one to trust?
17:08 TimToady the advantage of this view is that once you know the identity of what you want to download, IT DOESN'T MATTER where it comes from
17:08 tadzik trust pandas
17:08 tadzik (hello perl6)
17:08 FROGGS hi tadzik
17:08 TimToady so no CPANish bottlenecks
17:08 FROGGS ya
17:08 * FROGGS will read something about signatures then
17:09 TimToady because it's easy to replicate a readonly data
17:09 TimToady *database
17:09 rurban http://golang.org/doc/articles/go_command.html
17:10 TimToady the CPAN bottleneck is actually in the assignment of identity, I suppose, since it can replicate once things are uploaded
17:10 TimToady the git approach provides a global way to calculate identity without going through a PAUSE
17:10 TimToady so it scales better
17:11 SamuraiJack joined #perl6
17:11 TimToady in a sense, github is making the same "mistake" as PAUSE, in giving you a single point of failure/constriction
17:11 FROGGS so you say I type: panda install git@github.com/foo/bar.git and there is no need for the author to package it?
17:13 TimToady well, depends on what you mean by "package"
17:14 FROGGS basically incrementing the version, and make a zipball
17:14 TimToady to the extent that a module knows its own dependencies, it can "self-package"
17:15 TimToady zipball is not an identity, it's just a collection that is convenient for transporting a bunch of objects in parallel; dependency calculation is separate from this, to my mind
17:15 TimToady if it happens that the zipball contains the dependencies, it simplifies things, fo course
17:16 FROGGS I'm not talking about dependencies, I'm talking about making a cut and ship this thingy (the zipball) as a working piece
17:16 TimToady it won't work if you don't talk about dependencies :)
17:17 TimToady it's the dependencies that make it into a working piece
17:17 FROGGS well, its pandas job to get the dependencies too
17:18 FROGGS my job when making a package is just to declare the deps, not to include them
17:19 TimToady I guess I don't see how you're saying anything different from me...
17:19 FROGGS hmmmm :/
17:19 FROGGS well, that should be good, ehh?
17:20 TimToady I guess I'm saying it doesn't matter much where packaging is done, on the one end or the other, as long as the user ends up with the right deps
17:21 15SAAMW1P joined #perl6
17:21 TimToady packaging is a convenience for transport, mostly, and it's the contents of the package that provide its identity
17:21 TimToady a bundle of value types is still kind of a value type
17:22 masak oh, most definitely.
17:22 TimToady RPMs kind of mix up those two levels, from the standpoint of how I look at it
17:23 FROGGS_ joined #perl6
17:23 TimToady sort of the same problem as makefile dependencies that are not emergent from the properties of the files themselves
17:24 TimToady it's installing a higher-level dependency to stand in for a bunch of low-level dependencies, which has both advantages and disadvantages
17:26 rurban I'm halfway through with my parrot string debugging adventure: http://perl6advent.wordpress.​com/?p=1217&amp;preview=true
17:28 cognominal joined #perl6
17:32 diakopter rurban: not visible
17:38 diakopter rurban: (to me anyway)
17:39 rurban it's just a draft
17:40 * masak .oO( I smell a wumpus )
17:49 au hjkjhghnbvcf65hnnnnbghnhbbn8i8i99i~89ikol,
17:50 au whoa, bad cat. sorry.
17:50 masak I thought it was a brilliant solution to the modules discussion :P
17:50 au certainly so if you choose a suitable decoder :p
17:51 masak seems the cat was walking left-to-right, anyway.
17:51 au very astute :p
17:54 spider-mario joined #perl6
17:54 FROGGS joined #perl6
17:59 Kharec joined #perl6
18:01 timotimo it seems like the cat was a bit into vim ... hjkjh :)
18:10 grondilu joined #perl6
18:10 grondilu rn: say (state $)++ for ^3;  # testing anonymous state variable
18:10 diakopter keyboards should detect cat feet
18:10 p6eval rakudo e2f2dc, niecza v24-5-g599cbcb: OUTPUT«0␤1␤2␤»
18:11 grondilu cool
18:11 [Coke] au: hi!
18:12 diakopter .u 1F43E
18:13 phenny diakopter: Sorry, no results for '1F43E'.
18:13 diakopter PAW PRINTS it should say
18:14 FROGGS .u ó
18:14 phenny U+00F3 LATIN SMALL LETTER O WITH ACUTE (ó)
18:14 FROGGS cool, my client is doing utf-8 now ;o)
18:15 [Coke] Does perl6 give us a way to get U+00F3 LATIN SMALL LETTER O WITH ACUTE (ó) from ó ?
18:15 [Coke] (or is a lookup table needed?)
18:18 [Coke] 12345ó789
18:18 FROGGS I believe there is a lookup table, see http://cpansearch.perl.org/src/DANKOGAI​/Unicode-Char-0.02/lib/Unicode/Char.pm
18:22 au o/ [Coke]
18:27 dalek rakudo/stdier: 71dc392 | jnthn++ | src/core/Exception.pm:
18:27 dalek rakudo/stdier: D'oh, got red/green back to front.
18:27 dalek rakudo/stdier: review: https://github.com/rakudo/rakudo/commit/71dc392af5
18:27 dalek rakudo/stdier: ff0bbde | jnthn++ | src/Perl6/Grammar.pm:
18:27 dalek rakudo/stdier: Fix $*PKGDECL showing up in output.
18:27 dalek rakudo/stdier: review: https://github.com/rakudo/rakudo/commit/ff0bbded3e
18:29 masak hehe, "stdier". :)
18:29 MayDaniel joined #perl6
18:29 masak red/green back to front: "your program is TOTALLY WRONG up to here. then it gets much better" :P
18:30 jnthn Yes :P
18:30 jnthn Can't believe I didn't spot that the other night :P
18:30 jnthn I'm gonna have that branch for a while as the place I develop various bits of STD convergence work.
18:30 masak maybe you were temporarily color-blind.
18:30 jnthn But will merge into master now and then as I feel happy stuff is good enough to share.
18:31 jnthn Which is where I've got with what's in there so far, so...
18:34 dalek roast: 7fb70de | jnthn++ | S14-roles/basic.t:
18:34 dalek roast: Fudge an error message test.
18:34 dalek roast:
18:34 dalek roast: For one, should probably be a typed exception. But also it passed for
18:34 dalek roast: the wrong reason before; location information isn't meant to make it
18:34 dalek roast: into the message itself. No regression from user perspective (in fact,
18:34 dalek roast: the position of the error is more clearly indicated now).
18:34 dalek roast: review: https://github.com/perl6/roast/commit/7fb70de2ca
18:34 dalek rakudo/nom: 6b01881 | jnthn++ | src/ (2 files):
18:34 dalek rakudo/nom: Start showing context, with eject marker.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6b018814ed
18:34 dalek rakudo/nom: a109e73 | jnthn++ | src/Perl6/Grammar.pm:
18:34 dalek rakudo/nom: Make panic always throw X::Comp::AdHoc.
18:34 dalek rakudo/nom:
18:34 dalek rakudo/nom: This also means all the panics get the location included in the error.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/a109e738d7
18:34 dalek rakudo/nom: cff96f1 | jnthn++ | src/core/Exception.pm:
18:34 dalek rakudo/nom: Color output of compile time errors.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/cff96f111d
18:34 dalek rakudo/nom: 8dbb9a8 | jnthn++ | src/core/Exception.pm:
18:34 dalek rakudo/nom: Only show location if we have it.
18:34 dalek rakudo/nom:
18:34 dalek rakudo/nom: Just hardening for the case we don't for some reason.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/8dbb9a8f92
18:34 dalek rakudo/nom: 71dc392 | jnthn++ | src/core/Exception.pm:
18:34 dalek rakudo/nom: D'oh, got red/green back to front.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/71dc392af5
18:34 dalek rakudo/nom: ff0bbde | jnthn++ | src/Perl6/Grammar.pm:
18:34 dalek rakudo/nom: Fix $*PKGDECL showing up in output.
18:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ff0bbded3e
18:37 raiph joined #perl6
18:38 [Coke] IWBNI, if you do a perl --Configure.pl --gen-parrot and nothing changes, that it NOT do a make realclean.
18:38 [Coke] (end up rebuilding more than you need)
18:40 raiph phenny tell moritz http://stackoverflow.com/questions/25268​04/how-is-perls-inc-constructed-aka-what​-are-all-the-ways-of-affecting-where-pe
18:48 masak raiph: phenny didn't seem to listen to that. maybe a colon is needed?
18:48 moritz it's OK
18:51 * [Coke] wonders what we should now see in nom branch re: stdification.
19:12 jnthn Better location info, hopefully.
19:12 jnthn r: if 1 { say sin(42 }
19:12 p6eval rakudo ff0bbd: OUTPUT«[31m===[0mSORRY![31m===[0m�Unable to parse expression in argument list; couldn't find final ')'�at /tmp/YqaIVte5gw:1�------> [32mif 1 { say sin(42 [33m�[31m}[0m�»
19:12 jnthn Like so.
19:15 [Coke] ah. doesn't show in the REPL.
19:16 [Coke] jnthn++
19:17 jnthn std: hmm...
19:17 p6eval std a8bc48f: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Bogus term at /tmp/dqQKs8shjt line 1 (EOF):â�¤------> [32mhmm...[33mâ��[31m<EOL>[0mâ�¤Undeclared routine:â�¤     'hmm' used at line 1â�¤Parse failedâ�¤FAILED 00:00 42mâ�¤Â»
19:17 jnthn ah yes, it does have 3 =s too
19:25 mikemol Funny beep messages again?
19:29 bluescreen10 joined #perl6
19:29 jnthn mikemol: Huh?
19:30 cognominal joined #perl6
19:30 mikemol Nothing. Heard some unexplained beeps from my computer, had an unread hilight from #perl6 still, looked, didn't see a highlight, but did see some od output from p6eval.
19:31 mikemol A few times in the past, p6eval was coaxed into emitting characters that caused beeps in my irssi+screen session. Though maybe that's what happened.
19:32 mikemol But now I think it was just a vim session giving me some delayed terminal beeps from a few too many ESC commands.
19:35 masak r: say "mikemol: \a"
19:35 p6eval rakudo ff0bbd: OUTPUT«mikemol: ␤»
19:35 masak r: say "beep boop \a \a" for ^10
19:35 p6eval rakudo ff0bbd: OUTPUT«beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤beep boop  ␤»
19:36 masak :D
19:36 * jnthn locks masak in a cage so he can't escape
19:37 masak can I bring my laptop?
19:37 jnthn Sure! :P
19:37 TimToady see also http://rosettacode.org/wiki/Morse_code#Perl_6
19:37 masak jnthn: then we have an agreement.
19:38 masak TimToady: :P
19:39 masak TimToady: reminds me of http://www.youtube.com/watch?v=PENJxl-THS8 :D
19:40 dalek nqp: d140252 | jnthn++ | src/ (2 files):
19:40 dalek nqp: Add a $!shared to cursor, for parse-wide things.
19:40 dalek nqp:
19:40 dalek nqp: We'll move $!orig and $!target in to here. This will mean they need not
19:40 dalek nqp: both be copied into every Cursor, meaning we'll save a word per Cursor,
19:40 dalek nqp: at the cost of a little extra indirection occasionally. Also this will
19:40 dalek nqp: be a good place to hang certain other things.
19:40 dalek nqp: review: https://github.com/perl6/nqp/commit/d140252da6
19:40 dalek nqp: 0b5b9e8 | jnthn++ | src/QRegex/Cursor.nqp:
19:40 dalek nqp: Move $!orig into ParseShared.
19:40 dalek nqp: review: https://github.com/perl6/nqp/commit/0b5b9e89ae
19:40 dalek nqp: 4e91efd | jnthn++ | src/ (2 files):
19:40 dalek nqp: Stop breaking Cursor's encapsulation.
19:40 dalek nqp: review: https://github.com/perl6/nqp/commit/4e91efd4f1
19:40 dalek nqp: 3b98f66 | jnthn++ | src/ (2 files):
19:40 dalek nqp: Move $!target into ParseShared.
19:40 dalek nqp:
19:40 dalek nqp: This means we're now saving a pointer per Cursor.
19:40 dalek nqp: review: https://github.com/perl6/nqp/commit/3b98f66c74
19:41 dalek rakudo/nom: a8d2cc2 | jnthn++ | / (3 files):
19:41 dalek rakudo/nom: Updates for Cursor memory use reduction refactor.
19:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/a8d2cc2932
19:42 flussence stuff is happening!
19:49 _ilbot joined #perl6
19:49 Topic for #perl6 is now »ö« Welcome to Perl 6! | http://perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: http://irc.perl6.org/ | UTF-8 is our friend!
19:52 benabik_ joined #perl6
19:54 TimToady it's only the stuff that isn't happening that keeps everything from happening all at once...
19:54 TimToady time if funny that way...
19:54 TimToady *is
19:55 GlitchMr But stuff is always happening!
19:55 GlitchMr (no idea why I've used "!" at end of previous sentence)
19:55 flussence why are we yelling!?
19:56 TimToady WE'RE NOT!
19:56 GlitchMr You cannot lie on IRC.
19:56 GlitchMr IRC protocol doesn't support YELL command or anything close. But I guess that CTCP ACTION could be abused to add such command...
19:57 flussence I imagine it'd be really uncomfortable to lie down on an IRC channel, what with the speed text scrolls at...
19:58 TimToady I was gonna say I usually lie on my bed, but that could be misconstrued...
19:58 GlitchMr Sometimes it scrolls slowly, sometimes it scrolls quickly (like when somebody merges branches).
19:59 jnthn stroll, then I'll take a crack at the highwater thingymajig... &
19:59 FROGGS jnthn: cant build nqp+rakudo: Can not get attribute '$!target' declared in class 'NQPCursor' with this object
19:59 GlitchMr But you know what, Earth scrolls with 465.1m/s at equator. Enjoy.
20:01 TimToady GlitchMr: but it's biased in favor of those who read left-to-right
20:01 * ingy suspects TimToady is typing from his bed again... (he's prone to that)
20:01 flussence r: 0.14 #`[mm/px] * 12 #`[px line height] * 60 #`[fps] # IRC scroll speed in mm/sec (probably messed up somewhere :)
20:01 p6eval rakudo ff0bbd:  ( no output )
20:01 flussence r: say 0.14 #`[mm/px] * 12 #`[px line height] * 60 #`[fps] # IRC scroll speed in mm/sec (yep)
20:01 p6eval rakudo ff0bbd: OUTPUT«100.8␤»
20:01 GlitchMr Uhmmm... pixels are angular measurement unit.
20:02 flussence let's pretend 96dpi :)
20:02 GlitchMr Well, ok then
20:03 FROGGS jnthn: does this change something? (behaviour of .panic) https://github.com/rakudo/rakudo/commit/ff0bbded3e
20:03 flussence .oO( we can extrapolate that moving phone displays are significantly less dangerous to sit on than desktop ones... )
20:04 TimToady but the desktop ones are moving too
20:14 snearch joined #perl6
20:17 jnthn Niice!
20:17 jnthn The weather is now awesome cold rather than annoying cold. :)
20:17 jnthn FROGGS: Yeah, it was the quick fix...probably should also go hunt down whatever it is in NQP that makes that not work properly as it was.
20:17 jnthn FROGGS: Still got build problems?
20:18 benabik joined #perl6
20:18 jnthn The error looks like once you'd get with a non-updated NQP..
20:29 sorear good * #perl6
20:29 masak sorear! \o/
20:36 kurahaupo joined #perl6
20:37 dalek perl6-roast-data: c5a5f97 | coke++ | / (3 files):
20:37 dalek perl6-roast-data: today (automated commit)
20:37 dalek perl6-roast-data: review: https://github.com/coke/perl6​-roast-data/commit/c5a5f97894
20:38 [Coke] yay, niecza is back up over 86%.
20:38 [Coke] rakudo - +S12-introspection/parents.t aborted 59 test(s)
20:39 kivutar joined #perl6
20:43 FROGGS jnthn: still the same, stopped
20:43 FROGGS Using ~/dev/nqp/nqp (version 2012.11.1-9-g3b98f66).
20:44 FROGGS ohh, wait
20:48 FROGGS jnthn: false alarm
20:49 FROGGS wow, thats colorful
21:00 moritz jnthn++ # stdier
21:01 moritz p6advent post for tomorrow is already lined up for publishing
21:01 moritz http://perl6advent.wordpress.com/2012/12​/06/day-6-lexical-imports/?preview=true
21:02 jnthn FROGGS: I'm hoping it's also more informative... :)
21:02 moritz rurban: there seem to be two copies of your post for day 7 -- could you please delete the one that you don't want published?
21:03 FROGGS jnthn: it is ;o)
21:03 FROGGS just wanted to check that the error messages I fiddled are behaving nicely
21:04 moritz btw rakudo setting parse time didn't change much with this last patch
21:04 jeffreykegler joined #perl6
21:05 jnthn moritz: Yeah, that's a good thing.
21:06 jnthn moritz: There was the risk of the extra indirection being a slowdown.
21:06 jnthn Now I just gotta hope the highwater thing doesn't have that effect.
21:06 jnthn STD does it as a contextual, but for no especially good reason, it seems.
21:06 jnthn Well, besides it's cute/convenient.
21:14 fhelmberger joined #perl6
21:20 xilo_ joined #perl6
21:31 spider-mario joined #perl6
21:35 jnthn Woo, highwater (the position bit, not the expects) seems to work!
21:35 jnthn https://gist.github.com/4219713 # example of the improvement
21:35 masak ~~~\o/~~~
21:36 jnthn Gets line number right now too :)
21:36 jnthn And doesn't seem to slow things down.
21:36 * jnthn waits for the spectest to finish
21:36 jnthn Provided it passes this is going straight into nom :)
21:36 [Coke] jnthn++
21:37 jnthn I'll do highexpect in the branch 'cus that one is a bit scarier. :)
21:37 spider-mario joined #perl6
21:38 spider-mario joined #perl6
21:38 benabik joined #perl6
21:39 dalek nqp: 785d2fa | jnthn++ | src/QRegex/Cursor.nqp:
21:39 dalek nqp: Implement tracking of highwater whenever we lex.
21:39 dalek nqp: review: https://github.com/perl6/nqp/commit/785d2faaa2
21:40 spider-mario joined #perl6
21:43 uvtc joined #perl6
21:44 jnthn dalek seems in no hurry to report it but I pushed the changes to nom.
21:44 topo joined #perl6
21:44 PerlJam joined #perl6
21:44 jnthn This and the earlier work should mean we now do a lot better at reporting the locations where things went wrong.
21:45 uvtc Hi all. Just noticed, at the 2012 advent calendar, the day 5 blog post wants to be tagged "table of contents"3.
21:45 uvtc Without the 3.
21:45 uvtc :)
21:46 uvtc left #perl6
21:51 bruges joined #perl6
21:53 spider-mario joined #perl6
21:55 spider-mario joined #perl6
21:57 bbkr_ was .candidates_matching on Method class renamed lately?
21:58 jnthn Yes; candidates_matching was always a Rakudo thing and it was renamed to match spec.
21:58 jnthn Now called "cando"
22:03 bbkr_ jnthn: thanks. looks like it's expecting Capture now (which seems more logical to me than list of params), but everything works as expected :)
22:04 jnthn bbkr_: Yeah, and .cando since it's spec is also now regression tested in spectest :)
22:08 bbkr_ hm, how can I flatten list of params in Capture? I have sample $params = [1,"foo",3] and previously I had .candidates_matching(|$params). the same trick does not work in cando( \( |$params) )
22:12 cognominal_ joined #perl6
22:14 LlamaRider joined #perl6
22:17 bbkr_ nvm, .flat method did the trick
22:36 lue joined #perl6
22:36 lue hello o/
22:36 masak hellue! \o/
22:38 rindolf joined #perl6
22:39 lue I've come to the conclusion now that the best way to separate the src/core is to give rakudo the gift of gcc's -c flag (at least the "oh don't worry, those stubbed classes, they're defined in another file" part)
22:40 masak lue: not sure what you mean.
22:41 bbkr_ r: class A { method foo (Int){} }; my $t = [1]; A.^find_method("foo").cando( \(A, @($t) )).perl.say;
22:41 p6eval rakudo 53daef: OUTPUT«()␤»
22:41 bbkr_ looks like bug to me
22:42 sorear if only it were that simple
22:44 lue The idea is to to run each file in src/core through perl6 in a way that it won't complain about as-of-yet undefined classes etc. (hence me thinking of gcc -c and multi-file C/++ projects). Then concatenate the compiled files and do the normal PIR->PBC step.
22:44 lue I have no idea how difficult it would be to add this, but I like this idea better than trying to rearrange the code in src/core
22:45 bbkr_ jnthn: do you have any idea why my example above one does not work? if I replace signature with \(A, 1) it finds method.
22:46 Araq joined #perl6
22:46 lue (In other words: allow pmichaud's suggestion here: L<http://www.nntp.perl.org/group/perl.​perl6.compiler/2009/09/msg4891.html> to work, as rakudo currently complains on a package that's only stubbed)
22:47 bbkr_ r: (\(1)).perl.say; my $t=[1]; (\(@($t))).perl.say'
22:47 p6eval rakudo 53daef: OUTPUT«[31m===[0mSORRY![31m===[0m�Confused�at /tmp/jj3Zd5Fe2W:1�------> [32mperl.say; my $t=[1]; (\(@($t))).perl.say[33m�[31m'[0m�»
22:47 bbkr_ r: (\(1)).perl.say; my $t=[1]; (\(@($t))).perl.say
22:47 p6eval rakudo 53daef: OUTPUT«Capture.new( list => (1,).list, hash => EnumMap.new())␤Capture.new( list => (1,).list, hash => EnumMap.new())␤»
22:47 sorear Araq!
22:47 Araq sorear!
22:47 masak Araq! \o/
22:48 Araq wow ... do you guys know who I am? ;-)
22:48 sorear lue: it is not so simple as to just concatenate the compiled files.  A lot of delicate surgery must be done to link them together
22:49 masak Araq: nope. but welcome! :)
22:49 sorear masak: you don't remember Araq?
22:49 lue I figured. That was how I initially thought out the process, but had trouble believing "just concatenating" would work.
22:49 sorear I do
22:49 masak sorear: the name sounds vaguely familiar, yes...
22:49 * masak hits the backlog
22:50 masak oh, yeah.
22:50 masak Araq: yes, I do know who you are :)
22:51 Araq yay ... alright ... so are strings still mutable in perl 6?
22:51 sorear no.
22:51 Araq pity ... but understandable
22:52 lue (Frankly, I'm not very sure that src/core *could be* rearranged into compilable smaller bits, which is why I right now prefer what I've proposed.)
22:52 masak Araq: it doesn't really limit what you can do with them.
22:53 sorear lue: I have a new computer and it builds the niecza setting in 18 seconds
22:53 Araq well how do you explain to an outsider that the "king of strings" language called perl changed its string semantics? ;-)
22:54 sorear I would say it didn't.
22:54 sorear Strings in perl have never been mutable, from my point of view... ;D
22:55 sorear but we did change a lot of stuff with Str
22:55 sorear for instance, Str always contains Unicode codepoints now, *never* octets
22:55 masak Araq: let's put it like this: what is it that you think you can no longer do now that strings are immutable?
22:57 * lue should try niecza really soon. He already has mono on his computer.
22:58 Araq masak: can I do  s[i] = 'A' ? sorry if the syntax is wrong, I hardly ever used perl ;-)
22:58 doy Araq: you couldn't do that in perl 5 either
22:59 masak Araq: Perl doesn't tend to view strings as arrays.
22:59 sorear what *is* different is that current perl 6 implementations use garbage collection, so they can't optimize the case of substr($x,0,1,'A'); when $x points to a Str with one reference
23:00 sorear Perl 5 could do that in a zero-copy way if SvREFCNT($x) == 1
23:00 masak strings are item values. if you want them as a sequence of chars, you have to do .comb
23:00 sorear I mean the underlying PV refcnt
23:00 doy r: my $foo = "foo"; substr-rw($foo, 0, 1) = "a"; say $foo
23:00 p6eval rakudo 53daef: OUTPUT«aoo␤»
23:00 Araq ok, I think I got it
23:00 doy eval: my $foo = "foo"; substr($foo, 0, 1) = "a"; $foo
23:00 buubot_backup doy: aoo
23:04 Araq eval: my $foo = "foo"; my $bar = $foo; substr($foo, 0, 1) = "a"; $bar
23:04 buubot_backup Araq: foo
23:05 LlamaRider joined #perl6
23:12 rindolf joined #perl6
23:14 znsba joined #perl6
23:16 Araq bye
23:16 Araq left #perl6
23:27 jnthn sleep &
23:30 hash_table joined #perl6
23:34 * [Coke] sets up jnthn with an IV drip of caffeine for sleeping and plays an audio book of the spec.
23:42 tadzik joined #perl6
23:49 skids joined #perl6

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

Perl 6 | Reference Documentation | Rakudo