Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2011-12-26

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:00 sorear phenny: tell colomon I'm wondering how to work the spectest stuff into announce.v13
00:00 phenny sorear: I'll pass that on when colomon is around.
00:03 colomon I'm back... little guy did NOT want me reading tonight.
00:03 phenny colomon: 00:00Z <sorear> tell colomon I'm wondering how to work the spectest stuff into announce.v13
00:04 colomon what are you wondering about it?
00:05 x3nU #perl6 seems to be most active perl irc channel these days
00:05 x3nU pretty strange
00:07 colomon why is that strange?
00:07 x3nU perl 6 isn't exactly most popular thing
00:10 colomon but it's got two implementations with very active development at the moment, both coordinated over this channel.
00:10 dduncan that might also be because more established languages have split up into a variety of channels, while Perl 6 stuff is concentrated in fewer
00:11 dduncan eg, most Perl 5 talk is in channels about specific tools or modules rather than generic Perl 5 I think
00:11 dduncan or a lot is on mailing lists
00:11 dduncan Perl 6 talk doesn't seem to be on email lists as much as it used to
00:12 dduncan colomon, what is the other most active implementation besides Rakudo?
00:12 colomon Niecza
00:12 dduncan okay
00:12 dduncan I might have guessed that, what with it having regular release announcements
00:13 dduncan is there more than one person working on Niecza
00:13 sorear x3nU: have you tried looking on irc.perl.org?
00:13 sorear dduncan: I count as five people
00:13 dduncan okay
00:13 sorear seriously, though, bus number = 1.  colomon and [Coke] are trying to fix this
00:14 colomon I'm not really trying to fix the bus number thing, but I am trying to make sure you don't have to do all the work!
00:14 sorear colomon: right now there's nothing much in the announcement about all the spectest improvement work that's been done
00:15 sorear maybe I'll link to tadzik/flussence's graph
00:15 dduncan on a tangent, is there any list of projects that are based on but don't intend to be a full Perl 6 implementation?
00:15 dduncan or are any known
00:15 dduncan not the lists, but projects
00:15 dduncan my Muldis D is based on Perl 6, and I thought there might be others
00:15 dduncan NQP maybe
00:16 dduncan is one
00:16 sorear phenny: tell flussence_ Do you mind if I use https://github.com/flussence/specgraphs/raw/master/impls.png in the niecza v13 announcement?
00:16 phenny sorear: I'll pass that on when flussence_ is around.
00:16 colomon sorear: you could say something like [Coke] and colomon are working on fudging spectests so they run on NIecza; between that and actual improvements, we've gained 5000+ working spectests since the last release.
00:20 dduncan I suppose Perlito is another
00:20 sorear nom: sub foo($x where { 12 }) { "Y" }; say foo(4)
00:20 p6eval nom eb6c4b: OUTPUT«Y␤»
00:20 sorear Is this correct?
00:21 sorear wait, of course it is
00:23 dalek niecza: 5a663d0 | sorear++ | docs/announce.v13:
00:23 dalek niecza: Add blurb about roast progress, link to flussence++ chart
00:23 dalek niecza: review: https://github.com/sorear/niecza/commit/5a663d02ca
00:23 colomon is it correct?  does the where clause smartmatch or does it just need to return true?
00:24 colomon or is it smartmatching on the block?
00:24 * colomon has not used where clauses in far, far too long
00:25 sorear I am, uh, not really sure
00:27 colomon yeah, it's smartmatching
00:27 colomon I think
00:27 colomon :(1) Will introspect the same way as:    :(Int $ where 1)
00:27 x3nU sorear: yes, i'm on few channels there
00:28 colomon nom: sub foo($x where 12) { "Y" }; say foo(4)
00:28 p6eval nom eb6c4b: OUTPUT«Constraint type check failed for parameter '$x'␤  in sub foo at /tmp/Lg7p0E_DBc:1␤  in block <anon> at /tmp/Lg7p0E_DBc:1␤  in <anon> at /tmp/Lg7p0E_DBc:1␤»
00:30 dduncan left #perl6
00:31 colomon nom: sub foo($x where /\w+/) { say $x }; foo("this"); foo("   ")
00:31 p6eval nom eb6c4b: OUTPUT«this␤Constraint type check failed for parameter '$x'␤  in sub foo at /tmp/odHAr76zcq:1␤  in block <anon> at /tmp/odHAr76zcq:1␤  in <anon> at /tmp/odHAr76zcq:1␤»
00:32 colomon yeah, that's totally smartmatching
00:42 simon__ joined #perl6
00:43 simon__ nom: my @a = 1..3; @a X @a X @a;
00:43 p6eval nom eb6c4b:  ( no output )
00:46 drbean joined #perl6
00:54 replore joined #perl6
01:02 benabik joined #perl6
01:55 donri joined #perl6
01:57 hypolin joined #perl6
02:08 sorear crazy idea of the day: how about making p6eval automatically "say" the result if no output is generated?
02:09 sorear (rakudo and niecza already have this logic for the REPL.  I'm imagining adding a --replish-output option)
02:15 envi_ joined #perl6
02:16 hundskatt joined #perl6
02:26 donri sorear: +1
02:37 colomon +1
02:38 sorear Who would be able to tell me if this is feasable on the Rakudo fence side?
02:40 mkramer joined #perl6
02:52 donri why not just surround "say (...)"?
02:57 geekosaur double output if the code already does a say?
02:58 sorear exactly
03:02 dalek niecza: 16011dd | sorear++ | src/ (2 files):
03:02 dalek niecza: Remove a bunch of fossils from signature handling
03:02 dalek niecza: review: https://github.com/sorear/niecza/commit/16011ddf14
03:07 mkramer1 joined #perl6
03:22 dalek niecza: 37737c7 | sorear++ | / (5 files):
03:22 dalek niecza: Realign compiler and runtime parameter flags to 1:1 correspondence
03:22 dalek niecza: review: https://github.com/sorear/niecza/commit/37737c76c1
03:24 mkramer joined #perl6
03:37 Psyche^ joined #perl6
03:39 mkramer1 joined #perl6
03:41 cognominal_ joined #perl6
03:46 mkramer joined #perl6
03:55 hypolin joined #perl6
04:18 mkramer left #perl6
04:39 TimTom joined #perl6
04:41 TimTom rakudo: my %a; %a<a> = <1 2 3>; say %a<a>; %a<a> = %a<a>,4; say %a<a>;
04:41 p6eval rakudo eb6c4b: OUTPUT«1 2 3␤maximum recursion depth exceeded␤  in method gist at src/gen/CORE.setting:682␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:39…
04:41 TimTom good, so it's not just me
04:42 simcop2387 joined #perl6
04:42 TimTom is it a known issue that assigning some kinds of parcels in rakudo is currently broken?
04:43 sorear I don't see a bug there
04:43 TimTom ␤maximum recursion depth exceeded␤  in method gist at src/gen/CORE.setting:682␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:3977␤  in method gist at src/gen/CORE.setting:39…
04:43 sorear %a<a> = %a<a>, 4 creates a recursive data structure
04:43 TimTom it should be printing 1 2 3 4 or something similar to it
04:44 TimTom but it shouldn't be an infinite recursive structure
04:44 sorear there is no 1 2 3 in the result
04:44 sorear after the assignment, <1 2 3> is unreferenced garbage
04:44 raiph joined #perl6
04:45 TimTom I don't care if it ends up as ([1,2,3], 4) or (1,2,3,4).  Either way it's not an infinitely recursive structure
04:45 Ingis joined #perl6
04:46 sorear TimTom: except as defined it *is* an infinitely recursive structure
04:46 sorear rakudo: my $a; $a = <1 2 3>; say $a; $a = [ @$a, 4]; say $a
04:46 p6eval rakudo eb6c4b: OUTPUT«1 2 3␤1 2 3 4␤»
04:46 TimTom sorear: so how would I instead get it to assign the value of %a<a> to the slot stored in %a<a>
04:47 TimTom okay, that's fine.  The underlying reason I found this is because hash push is broken
04:47 sorear TimTom: avoid using a parcel, because parcels are very lazy
04:47 sorear parcels don't actually fetch until they have to
04:47 IngisKahn joined #perl6
04:47 sorear when you say $a = $a, 4; the parcel doesn't fetch until long after $a is re-assigned
04:48 TimTom rakudo: my %a; %a.push(1 => 2); %a.push(1 => 3); say %a
04:48 sorear which is why it comes out recursive
04:48 p6eval rakudo eb6c4b: OUTPUT«("1" => [2, 3]).hash␤»
04:48 TimTom okay, so that one's just broken on my system
04:49 sorear what version are you on?
04:49 sorear b: my %a; %a.push(1 => 2); %a.push(1 => 3); say %
04:49 TimTom latest
04:49 p6eval b 1b7dd1: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at line 22, near "%"␤»
04:49 TimTom at least when I do a git pull it reports I'm at latest
04:50 sorear git status # What branch are you on?
04:50 TimTom master
04:50 stepnem_ joined #perl6
04:50 sorear b: my %a; %a.push(1 => 2); %a.push(1 => 3); say %a
04:51 p6eval b 1b7dd1: OUTPUT«1      2 3␤»
04:51 sorear TimTom: git checkout nom and try again
04:51 TimTom k
04:55 lue joined #perl6
04:55 lue hello world! o/
04:56 lue rakudo: say (9/9) ~~ Int;
04:56 p6eval rakudo eb6c4b: OUTPUT«Bool::False␤»
04:56 lue That feels like a bug.
04:59 sorear I said the same thing.
05:01 cooper joined #perl6
05:06 benabik nom: say (9/9).WHAT
05:06 p6eval nom eb6c4b: OUTPUT«Rat()␤»
05:11 cognominal joined #perl6
05:45 envi_ joined #perl6
05:47 kaleem joined #perl6
06:00 lutok joined #perl6
06:16 traingeek joined #perl6
06:16 traingeek left #perl6
06:35 replore_ joined #perl6
06:50 am0c joined #perl6
07:00 koban joined #perl6
07:27 pat_js joined #perl6
07:30 pat_js 08:29 *** 421 message Unknown command
07:32 cognominal joined #perl6
07:33 mkramer1 joined #perl6
07:45 sudokode joined #perl6
07:55 mkramer joined #perl6
08:07 sayu joined #perl6
08:26 dalek niecza: 8fef06e | sorear++ | / (5 files):
08:26 dalek niecza: More signatures refactoring - use bitfields througout
08:26 dalek niecza: review: https://github.com/sorear/niecza/commit/8fef06e4b9
08:29 HarryS joined #perl6
08:29 mkramer joined #perl6
08:48 ingy hi
08:48 ingy anyone around?
08:49 sorear yes
08:49 sorear but probably nobody useful. :)
08:50 ingy sorear!
08:51 ingy I have a question for you!
08:51 ingy what's the difference between a .a file and a .o file?
08:52 geekosaur .a file is a statc link archive, made of .o files
08:53 sorear .o files are like executable files, but without "main"
08:53 phenny sorear: Service not found in https://github.com/nslater/oblique/wiki
08:53 sorear compilers produce .o files, and the linker takes a bunch of .os and makes an executable
08:53 geekosaur as distinct from a dynamic link library which is made from .o files linked together in a special way (and often the .o files are compiled differently; see position-independent code)
08:53 sorear but people got tired of adding printf.o exit.o ... to their link lines, so the linker also accepts .a files, which are just archives contianing .o files
08:54 ingy oh
08:54 sorear I mean archives in a quite literal sense - .a files and .tar files can be used interchangably (well, the on-disk formats are incompatible)
08:54 sorear notably, Debian packages use ar format for some reason
08:55 ingy is a .a file like a static .so?
08:55 geekosaur it's simpler
08:55 ingy and wtf is geekosaur?
08:55 geekosaur BSD has libarchive, linux doesn't in general, so .a format is easier to manipulate
08:56 geekosaur erm?
08:56 ingy oh
08:56 ingy I thought you were a bot
08:56 ingy sorry
08:56 ingy :D
08:56 geekosaur (also ar files are generally flat, i.e. cannot hold subdirectories)
08:57 ingy let me try comething
08:57 geekosaur (I think gnu ar relaxes that somewhat)
08:57 ingy something
08:57 ingy thx geekosaur
09:02 sorear ingy: geekosaur is the *nix expert formerly known as allbery_b
09:02 sorear who has a long history of wisecracking about his age
09:03 sorear ingy: .a files are just file archives.  they aren't in any way specialized for use with linkers.
09:04 geekosaur if you've ever heard Against Me!'s "Thrash Unreal"... sometimes I feel like that
09:04 sorear geekosaur: which came first, ar or tar?
09:04 eiro joined #perl6
09:05 * sorear wanders off to sleep
09:05 geekosaur hm.  that goes back a long way.  ar came first with respect to use for disk files, though; tar was originally intended for disks (and you generally used numeric options 0-7 to pick /dev/rmt[0-7]nsted of the f/-f option)
09:05 * geekosaur isn't quite sure what happened to that line... network hiccuped
09:05 sorear s/disks/tapes/?
09:06 geekosaur tapes.  sigh
09:06 * geekosaur needs a nap
09:06 sorear wait, where are you living these days?
09:06 geekosaur time only tells part of the story; my sleep schedule is quite insane, when it exists at all
09:07 * geekosaur has a sleep disorder that leaves his sleep schedule drifting somewhat aimlessly and resistant to being fixed
09:07 sorear KF8NH suggests strong US ties but CTCP TIME says Western Europe
09:07 geekosaur oh.  this IRC session is in EC2 and its time zone is UTC
09:07 geekosaur but I'm actually located near Akron, OH atm
09:08 sorear ah
09:08 * sorear out for real
09:08 geekosaur and between the number of people all over the place that I regularly chat with and my own sleep non-schedule, utc for the IRC session is fairly convenient
09:12 ingy geekosaur: do you do any perl 5 XS?
09:21 eiro joined #perl6
09:22 geekosaur very little
09:27 masak morning, #perl6!
09:29 masak sorear: there once was logic to do what you proposed. it drove people nuts and interacted heavily with debugging. might just've been the implementation, of course, but from what I've seen the utility isn't worth the investment.
09:29 eiro joined #perl6
09:31 drbean joined #perl6
09:33 mkramer joined #perl6
09:37 mkramer joined #perl6
09:44 kaare_ joined #perl6
09:48 masak 9/9 ~~ Int is potentially a tricky one.
09:48 masak on one hand, you could decide that number results should always try to fit into the "narrowest" type; here, Int.
09:48 masak I've argued that many times myself.
09:49 masak on the other hand, it feels slightly unfair if someone does 'my Rat $r = $a / $b', and it typefails the times when $b divides $a.
09:50 mkramer joined #perl6
10:03 mj41 joined #perl6
10:03 Trashlord joined #perl6
10:19 drbean joined #perl6
10:34 masak breaking news: now there's a *second* prize in the contest: http://strangelyconsistent.org/blog/the-2011-perl-6-coding-contest
10:34 masak yet another reason to sign up. :)
10:39 tadzik the third prize can be an optimal way to tie a shoe :P
10:40 tadzik or that was supposed to be the LAF prize...
10:47 drbean joined #perl6
10:47 masak tadzik: what is it with you and the optimal way to tie a shoe? :P
10:49 tadzik it's awesome!
10:49 tadzik will teach you one day
10:49 masak :P
11:16 ponbiki joined #perl6
11:28 masak "First of all: Finally accept that there are two Perls now. 5 and 6. Period. The world needs more Perl - here we have it. :) None of the two will go away. That's a good thing." -- Su-Shee++ http://blogs.perl.org/users/su-shee/2011/01/random-contest-event-ideas.html
11:29 masak I really like the suggestions in that blog post.
11:31 koban left #perl6
11:36 cognominal joined #perl6
11:40 tadzik what's a <...> in function body?
11:40 tadzik optional yada yada?
11:43 masak nom: sub foo { ... }; foo; say "alive"
11:43 p6eval nom eb6c4b: OUTPUT«alive␤»
11:43 masak nom: sub foo { ??? }; foo; say "alive"
11:43 p6eval nom eb6c4b: OUTPUT«Stub code executed␤alive␤»
11:43 masak nom: sub foo { !!! }; foo; say "alive"
11:43 p6eval nom eb6c4b: OUTPUT«Stub code executed␤  in sub foo at /tmp/ariRzjFSxp:1␤  in block <anon> at /tmp/ariRzjFSxp:1␤  in <anon> at /tmp/ariRzjFSxp:1␤»
11:43 masak nom: sub foo { ... }; foo.^name
11:43 p6eval nom eb6c4b:  ( no output )
11:43 tadzik nom: sub foo { <...> }; foo; say "alive"
11:43 p6eval nom eb6c4b: OUTPUT«alive␤»
11:43 masak nom: sub foo { ... }; say foo.^name
11:43 p6eval nom eb6c4b: OUTPUT«Failure␤»
11:44 tadzik masak: https://github.com/mberends/http-server-simple/pull/4
11:44 masak tadzik: as far as I know, that's just a string with funny syntax.
11:44 tadzik oh, sane
11:44 tadzik nom: sub foo { <...> }; say foo.perl
11:44 p6eval nom eb6c4b: OUTPUT«"..."␤»
11:44 tadzik yep
11:44 masak &
11:45 donri left #perl6
12:08 Trashlord joined #perl6
12:41 sayu_ joined #perl6
12:50 sayu joined #perl6
13:06 PacoLinux joined #perl6
13:07 x3nU joined #perl6
13:24 mkramer joined #perl6
13:31 zhangkaizhao joined #perl6
13:37 sftp joined #perl6
14:08 Chillance joined #perl6
14:26 lateau_ joined #perl6
14:33 mkramer joined #perl6
14:43 mkramer joined #perl6
14:50 Trashlord joined #perl6
14:51 mkramer joined #perl6
15:04 lateau_ left #perl6
15:04 bluescreen10 joined #perl6
15:05 mkramer joined #perl6
15:28 am0c^ joined #perl6
15:57 TimTom joined #perl6
15:58 benabik_ joined #perl6
16:06 am0c joined #perl6
16:06 colomon_ joined #perl6
16:30 masak quiet today. is everyone in a post-Christmas dinner coma?
16:30 masak or are you absorbed by the p6cc problems? :P
16:30 tadzik more like in-a-cold coma :/
16:30 masak aww
16:31 tadzik not even in a mood for hacking
16:31 tadzik but did some psgi/POST research for HTTP::Server::Simple
16:31 * masak puts on armor and hugs tadzik :)
16:31 tadzik :)
16:32 tadzik ha
16:32 tadzik https://twitter.com/#!/samvtran/status/151317313386315776
16:32 tadzik it was a good move to merge it :)
16:33 masak \o/
16:34 masak I never saw the the point of those angle brackets, though.
16:34 tadzik they're just workaround
16:34 tadzik in this case
16:35 tadzik could've been removed completely and the effect would've been similar
16:36 masak ah.
16:36 tadzik now they just return "..."
16:36 tadzik but they're either never called, or their result is ignore
16:37 tadzik d
16:37 * tadzik ponders giving some serious love to H::S::Simple
16:38 * colomon has been pondering making a serious effort to port panda to niecza -- but $work and family will probably keep tuits in short supply for a couple of days
16:40 masak (Panda on Niecza)++
16:42 glitchmr joined #perl6
16:52 pmurias joined #perl6
16:54 jaldhar joined #perl6
16:58 * ruoso have been trying to get some word from the parrot folks on the "blocking buffered stream" idea
16:58 masak yes, nice email thread.
16:58 masak kudos.
17:01 TimTom Hi.  I'm looking for a way to either get the cross operator to return it's items as an list of arrays or for the for loop to take n items at a time without being forced to specify n scalar variables.  As an example of the list generation...
17:01 TimTom rakudo: my @a = (1,2,3); my $n = 2; say infix:<X>(|(http://en.wikipedia.org/wiki/Special:Search?go=Go&amp;search=@a xx $n));
17:01 p6eval rakudo eb6c4b: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 2␤»
17:01 TimTom oh good.  it interpreted that...
17:01 TimTom rakudo: my @a = (1,2,3); my $n = 2; say infix:<X>(|([ [@a] ] xx $n));
17:01 p6eval rakudo eb6c4b: OUTPUT«1 1 1 2 1 3 2 1 2 2 2 3 3 1 3 2 3 3␤»
17:03 masak TimTom: hi. sounds like you maybe want lol context.
17:03 masak "lol" here stands for "list of lists".
17:03 TimTom masak: most likely.  How would I get said context?
17:03 masak I'm not so sure it's fully supported yet... so, workaround, most likely.
17:04 masak here, let me dig up the relevant piece of spec for you.
17:04 ruoso say infix:<X>(|([ [1,2,3] ] xx 2)).perl
17:04 ruoso nom: say infix:<X>(|([ [1,2,3] ] xx 2)).perl
17:04 p6eval nom eb6c4b: OUTPUT«((ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),)).list␤»
17:05 ruoso nom: say infix:<X>(|([ [1,2,3] ] xx 2))
17:05 p6eval nom eb6c4b: OUTPUT«1 1 1 2 1 3 2 1 2 2 2 3 3 1 3 2 3 3␤»
17:05 ruoso nom: $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[0;0];
17:05 p6eval nom eb6c4b: OUTPUT«===SORRY!===␤Variable $a is not predeclared at line 1, near " := infix:"␤»
17:06 masak hm. I don't see any particular synopsis "introducing" lol context.
17:06 ruoso nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[0;0];
17:06 p6eval nom eb6c4b: OUTPUT«ListIter.new()␤»
17:06 ruoso nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[0;0;0];
17:06 p6eval nom eb6c4b: OUTPUT«ListIter.new()␤»
17:06 ruoso nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[0;0].get;
17:06 p6eval nom eb6c4b: OUTPUT«Method 'get' not found for invocant of class 'Parcel'␤  in block <anon> at /tmp/1CqkbYX8Dg:1␤  in <anon> at /tmp/1CqkbYX8Dg:1␤»
17:06 TimTom I know it's referenced at least in the spec.  In fact, it's referecned right in the cross operator section
17:06 TimTom but there's no explanation on how I would transform something into them.
17:07 ruoso nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)).lol; say $a[0;0].get;
17:07 p6eval nom eb6c4b: OUTPUT«Method 'lol' not found for invocant of class 'List'␤  in block <anon> at /tmp/8nn1qc4s8X:1␤  in <anon> at /tmp/8nn1qc4s8X:1␤»
17:08 TimTom I'm not sure how it affects the infix notation, but you want X, instead of X to get it into a semblance of a list of list for the return value.  But it still ends up treated as a single list for iteration
17:08 ruoso p6eval nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[1][1];
17:08 p6eval ruoso: nom eb6c4b: OUTPUT«2␤»
17:08 TimTom oooh
17:09 ruoso the bind operator will defer context enforcement
17:09 ruoso so you will get the actual iterators
17:10 ruoso in this case, $a[1;1] was supposed to work as well
17:11 ruoso but I guess it's not making the correct context
17:11 ruoso There was also a "capture context", but I'm not sure that ever got accepted/implemented
17:12 ruoso p6eval nom: my ¢a = infix:<X>(|([ [1,2,3] ] xx 2)); say $a[1][1];
17:12 p6eval ruoso: nom eb6c4b: OUTPUT«===SORRY!===␤Malformed my at line 1, near "\x{a2}a = infix"␤»
17:12 ruoso p6eval nom: my ¢a = infix:<X>(|([ [1,2,3] ] xx 2)); say ¢a[1][1];
17:12 p6eval ruoso: nom eb6c4b: OUTPUT«===SORRY!===␤Malformed my at line 1, near "\x{a2}a = infix"␤»
17:12 ruoso p6eval std: my ¢a = infix:<X>(|([ [1,2,3] ] xx 2)); say ¢a[1][1];
17:12 p6eval ruoso: std dc62e1d: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Malformed my at /tmp/H30mtq9BPc line 1:â�¤------> [32mmy [33mâ��[31m¢a = infix:<X>(|([ [1,2,3] ] xx 2)); say[0mâ�¤    expecting scoped declaratorâ�¤Parse failedâ�¤FAILED 00:01 120mâ�¤Â»
17:13 ruoso yep... not accepted/implemented
17:13 TimTom nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); for $a -> $elem { say $elem; }
17:13 p6eval nom eb6c4b: OUTPUT«1␤1␤1␤2␤1␤3␤2␤1␤2␤2␤2␤3␤3␤1␤3␤2␤3␤3␤»
17:13 TimToady we have a parcel context introduced with \ instead
17:13 TimTom it's still flattening when used in a for loop
17:14 ruoso TimTom: for will flatten the elements..
17:15 TimTom ruoso: as will any listy context.  assigning it to @d also gets the same result
17:15 TimToady lol is still unimplemented
17:15 TimTom I suppose I could instead iterate over ^$a.elems
17:15 colomon TimToady!  \o/
17:16 ruoso doesn't the Parcel have an API to get the immediate elements?
17:17 TimToady nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)); say $a[0].perl
17:17 p6eval nom eb6c4b: OUTPUT«(ListIter.new(),)␤»
17:18 TimToady nom: my $a := ([1,2,3],[4,5,6]); say $a[0].perl
17:18 p6eval nom eb6c4b: OUTPUT«[1, 2, 3]␤»
17:19 ruoso nom: my $a := ((1,2,3),(4,5,6)); say $a[0].perl
17:19 p6eval nom eb6c4b: OUTPUT«1␤»
17:19 ruoso wasn't that supposed to have two Parcels?
17:20 TimToady I would tend to think so
17:21 TimToady nom: my $a := ((1,2,3),(4,5,6)); say $a.perl
17:21 p6eval nom eb6c4b: OUTPUT«((1, 2, 3), (4, 5, 6))␤»
17:22 ruoso hmm... $a[0] is forcing flat list context
17:22 ruoso nom: my $a := ((1,2,3),(4,5,6)); say $a[0;0].perl
17:22 p6eval nom eb6c4b: OUTPUT«1␤»
17:22 ruoso nom: my $a := ((1,2,3),(4,5,6)); say $a[0;1].perl
17:22 p6eval nom eb6c4b: OUTPUT«2␤»
17:23 TimToady nobody implements ; yet either
17:23 ruoso ah. ok.
17:23 TimToady in fact, S09 has mostly been completely ignored
17:23 ruoso nom: say Parcel.^methods
17:23 p6eval nom eb6c4b: OUTPUT«Parcel Capture flat item list lol at_pos postcircumfix:<[ ]> STORE FLATTENABLE_LIST FLATTENABLE_HASH fmt of Bool Numeric Str ACCEPTS gist perl DUMP abs conjugate sqrt sign rand sin asin cos acos tan atan atan2 sec asec cosec acosec cotan acotan sinh asinh cosh acosh t…
17:24 TimToady nom: my $a := ((1,2,3),(4,5,6)); say $a.lol.perl
17:24 p6eval nom eb6c4b: OUTPUT«LoL.new((1, 2, 3), (4, 5, 6))␤»
17:24 TimToady nom: my $a := ((1,2,3),(4,5,6)); say $a.lol[0]perl
17:24 p6eval nom eb6c4b: OUTPUT«===SORRY!===␤Confused at line 1, near "say $a.lol"␤»
17:24 ruoso nom: my $a := ((1,2,3),(4,5,6)); say $a.lol[0].perl
17:24 TimToady nom: my $a := ((1,2,3),(4,5,6)); say $a.lol[0].perl
17:24 p6eval nom eb6c4b: OUTPUT«(1, 2, 3)␤»
17:24 p6eval nom eb6c4b: OUTPUT«(1, 2, 3)␤»
17:24 ruoso hah
17:24 TimToady looks like we have some lols
17:24 ruoso nom: my $a := infix:<X>(|([ [1,2,3] ] xx 2)).lol; say $a.lol[0][0];
17:24 p6eval nom eb6c4b: OUTPUT«Method 'lol' not found for invocant of class 'List'␤  in block <anon> at /tmp/KNC1ANnUM_:1␤  in <anon> at /tmp/KNC1ANnUM_:1␤»
17:25 TimToady I suspect it's only the minimum lol-hood to implement ** binding
17:26 TimToady but I'm exactly two weeks behind in backlogging due to brane malfunction, so don't quote me on anything
17:33 ruoso I am afraid infix:<X> is flattening too early
17:34 ruoso hmm... nope... it's not
17:35 ruoso nom: say infix:<X>(|(((1,2,3) xx 2)))[8][1].perl
17:35 p6eval nom eb6c4b: OUTPUT«3␤»
17:35 TimToady perl6: say ([1,2,3] X [4,5,6]).elems
17:35 p6eval niecza v12-183-g8fef06e: OUTPUT«1␤»
17:35 p6eval ..pugs b927740, rakudo eb6c4b: OUTPUT«9␤»
17:36 TimToady 1 is correct there
17:36 TimToady so yes, nom is flattening wrongly
17:37 masak aye.
17:37 TimToady [] should not flatten in a list context
17:37 masak submitted a rakudobug about that yesterday.
17:37 masak (but with &take, not infix:<X>)
17:37 masak suspect it's the same root cause, though. namely, &take :)
17:37 ruoso hmm.. why is 1 correct? isn't .elems being called on the parcel with the results?
17:41 TimToady perl6: say (([1,2,3],[1,2,3])).elems
17:41 p6eval pugs b927740, rakudo eb6c4b, niecza v12-183-g8fef06e: OUTPUT«2␤»
17:41 masak 2!?
17:42 TimToady .elems appears to be flattening
17:42 TimToady perl6: say ([1,2,3] X [1,2,3]).perl
17:42 p6eval pugs b927740: OUTPUT«((1, 1), (1, 2), (1, 3), (2, 1), (2, 2), (2, 3), (3, 1), (3, 2), (3, 3))␤»
17:42 p6eval ..niecza v12-183-g8fef06e: OUTPUT«([1, 2, 3], [1, 2, 3]).list␤»
17:42 p6eval ..rakudo eb6c4b: OUTPUT«((ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),)).list␤»
17:43 ruoso perl6: say ((1,2,3) X (1,2,3)).perl
17:43 p6eval pugs b927740: OUTPUT«((1, 1), (1, 2), (1, 3), (2, 1), (2, 2), (2, 3), (3, 1), (3, 2), (3, 3))␤»
17:43 p6eval ..rakudo eb6c4b: OUTPUT«((ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),)).list␤»
17:43 p6eval ..niecza v12-183-g8fef06e: OUTPUT«(1, 1, 1, 2, 1, 3, 2, 1, 2, 2, 2, 3, 3, 1, 3, 2, 3, 3).list␤»
17:44 TimToady niecza is wrong there in losing the subparcels from X, I think
17:45 TimToady otoh, your inner parens are supposedly noops
17:45 TimToady perl6: say (1,2,3 X 4,5,6).perl
17:45 p6eval niecza v12-183-g8fef06e: OUTPUT«(1, 4, 1, 5, 1, 6, 2, 4, 2, 5, 2, 6, 3, 4, 3, 5, 3, 6).list␤»
17:45 p6eval ..rakudo eb6c4b: OUTPUT«((ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),), (ListIter.new(),)).list␤»
17:45 p6eval ..pugs b927740: OUTPUT«((1, 4), (1, 5), (1, 6), (2, 4), (2, 5), (2, 6), (3, 4), (3, 5), (3, 6))␤»
17:46 cognominal joined #perl6
17:46 yunga joined #perl6
17:46 ruoso yeah.. true... but the effect was supposed to be the same yet... I think pugs is correct there..
17:47 TimToady it at least provides that appearance :)
17:47 masak Rakudo is just being weird in this case.
17:52 ruoso but [1,2,3] is supposed to be different than plain 1,2,3
17:52 ruoso perl6: say [1,2,3].perl; say (1,2,3).perl;
17:52 p6eval pugs b927740, rakudo eb6c4b, niecza v12-183-g8fef06e: OUTPUT«[1, 2, 3]␤(1, 2, 3)␤»
17:52 ruoso perl6: say [1,2,3].HOW; say (1,2,3).HOW;
17:52 p6eval niecza v12-183-g8fef06e: OUTPUT«ClassHOW.new(...)␤ClassHOW.new(...)␤»
17:52 p6eval ..rakudo eb6c4b: OUTPUT«Method 'gist' not found for invocant of class 'Perl6::Metamodel::ClassHOW'␤  in sub say at src/gen/CORE.setting:5649␤  in block <anon> at /tmp/0BfXLX4lvT:1␤  in <anon> at /tmp/0BfXLX4lvT:1␤»
17:52 p6eval ..pugs b927740: OUTPUT«<obj:Class>␤<obj:Class>␤»
17:53 masak [backlog] wow, the discussion abotu <numish> and LTM is eye-opening. I hadn't realized how much subrule parsing and calling actions can "get out of sync".
17:56 ruoso TimToady: btw, if you could take a look at a thread in parrot-dev I just posted, it would be interesting to get some confirmation about some expectations about concurrency...
17:57 ruoso http://lists.parrot.org/pipermail/parrot-dev/2011-December/006506.html if you're not subscribed
17:59 moritz \o
18:01 whiteknight joined #perl6
18:01 masak moritz! \o/
18:02 fglock joined #perl6
18:10 mkramer joined #perl6
18:14 sorear good * #perl6
18:14 sorear masak: ah, understood.  I will drop it then.
18:15 masak sorear: it's one of those "cute on paper" ideas, I think.
18:17 sorear niecza: say (1,2,3 X 4,5,6).raw-elem(2).perl # TimToady, known bug in .perl
18:17 p6eval niecza v12-183-g8fef06e: OUTPUT«Unhandled exception: Unable to resolve method raw-elem in class List␤  at /tmp/u0vVfpZ8vu line 1 (mainline @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2572 (ANON @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2573 (module-CORE @ 61) ␤  at /…
18:18 sorear niecza: say (1,2,3 X 4,5,6).raw_at(2).perl
18:18 p6eval niecza v12-183-g8fef06e: OUTPUT«Unhandled exception: Unable to resolve method raw_at in class List␤  at /tmp/tIhJvaDWkc line 1 (mainline @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2572 (ANON @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2573 (module-CORE @ 61) ␤  at /ho…
18:19 sorear ohright, it doesn't return a Parcel
18:19 sorear I really need help understanding the finer points of LoL and .lol semantics
18:21 GlitchMr joined #perl6
18:22 masak ruoso: I think jnthn will be interested in the current patrrot-dev thread. but he's currently on holiday.
18:27 masak ruoso: if I may channel him for a while, I'd say that "all sane concurrency will have to somehow build on CAS".
18:28 ruoso CAS?
18:28 masak that seems relevant at least for serializing access to that increment counter in the discussion.
18:28 masak http://en.wikipedia.org/wiki/Compare-and-swap
18:29 ruoso oh... but that is in a much lower level...
18:30 masak yes, it's grounded in hardware. but the *idea* of it is useful even at higher levels.
18:30 masak in some sense, all the other atomicity concepts build on CAS as a primitive.
18:31 masak so the question is "just" through which Perl 6 primitives we choose to expose it.
18:31 ruoso Yes... but I am talking on a level more abstract than that
18:31 ruoso I am talking in the model on how information flows and how parallel things preempt each other
18:31 masak right.
18:32 masak so it's more the "mental model of Perl 6" that you're interested in now.
18:32 masak not how to ground it in the VM.
18:32 carlin joined #perl6
18:33 ruoso with the exception that we would require one more vm primitive
18:33 ruoso that we used to
18:33 ruoso which is the akin to unix pipes
18:34 carlin has something changed with how Q:PIR {} works in Rakudo?
18:34 mj41 joined #perl6
18:34 carlin I'm getting "Cannot assign a non-Perl 6 value to a Perl 6 container" on code that worked a few months ago
18:34 tadzik carlin: what does the code return>?
18:34 masak well, I've always seen unix pipes as a kind of coroutines. so, basically equivalent to the gather/take primitive.
18:34 TimToady by default unix processes cannot modify their incoming env or arg values from the surrounding scopes
18:35 masak carlin: might need to containerize stuff explicitly nowadays.
18:35 masak carlin: maybe check how Rakudo's src/core/ does things.
18:35 TimToady also Q:PIR is deprecated in favor of nqp primitives
18:35 carlin ah ok
18:35 masak aye.
18:36 carlin so %r = box whatever isn't the way to go anymore?
18:36 tadzik you may want to box that from the Perl 6 side
18:36 tadzik like nqp::p6box_i(Q:PIR {}) for Int
18:36 masak ruoso: is there any reason I'm missing that things like '<==' would need more from Perl 6 than things like 'gather'?
18:37 TimToady any lazy list can potentially be implemented using threads in p6
18:38 TimToady in that sense <== isn't so special
18:38 TimToady but it is more of an indication that the user is thinking in parallel
18:38 masak to me it feels like "the same" primitive.
18:38 TimToady so the optimizer might make different choices
18:39 TimToady we may also end up with some restrictions on how the inner scope of a thread can interact with its outer scope by default
18:39 masak I've been mentally labelling the thread-like thing that runs inside of a 'gather' as a 'co' (from 'coroutine') -- essentially a green thread.
18:40 TimToady that's fine until it blocks :)
18:40 masak then it's a 'compet' :P
18:40 masak TimToady: wouldn't it make sense from the optimizer's point-of-view to *completely* restrict the thread's interaction with the outer scope by default?
18:40 masak and then have it ask nicely for permissions?
18:41 TimToady not necessary for constants
18:41 masak feels analogous to making params readonly.
18:41 TimToady and for some known-unchanging values
18:41 masak sure, but those are not problematic anyway...
18:41 TimToady but basically it's okay for any input you have no say in the production of
18:42 sorear restricting interaction between coroutines and outer scopes is very problematic.  I can't think how to implmenet it
18:43 TimToady well, ssa-ish fresh-binding-only semantics help with the loops involving the return value, at least
18:43 masak the boundary between threads isn't visible statically?
18:43 TimToady it is in <==, at least at the top level, but not in subcalls
18:43 sorear masak: threads can call functions outside them, like &infix:<+>
18:43 masak dang.
18:44 * masak de-trains, back in 30ish
18:45 TimToady anyway, our default is that it's the programmers fault, and if the compiler can help to detect badness, all the better
18:46 TimToady programs that rely on such side effects may become illegal in the future, which is a good reason to avoid programming in that style
18:46 TimToady it's an open question what can be caught in the absense of a monadic lifestyle, though...
18:47 TimToady and monads are not P6's job to inflict on the minds of programmers
18:47 TimToady or however a sane person would say that...
18:49 TimToady historically, Perl has not shied away from detecting specific problems just because the general problem is insoluable :)
18:50 TimToady .oO("Your program is going to halt at line 42.  You have been warned.")
18:52 thou joined #perl6
18:54 MayDaniel joined #perl6
19:00 Mowah joined #perl6
19:13 drbean joined #perl6
19:14 donri joined #perl6
19:15 sorear TimToady: what do you think about <:XID_Start> and <:XID_Continue> ?
19:15 sorear seems the Perl 5 folks have switched to using that to define identifiers
19:21 cognominal joined #perl6
19:24 TimToady I don't think anything about them.
19:27 TimToady it does not reassure me that a google for XID_Start finds only old four-year-old discussions though
19:31 TimToady I suppose if I put on my language designer meta-hat, I'd say that language designers don't like standards bodies telling them how to design their languages.  :)
19:38 ruoso masak: it is a coroutine that can be run concurrently, yes
19:38 ruoso we could consider that every gather spawns a new "concurrent task"
19:39 dalek niecza: 64376da | sorear++ | lib/CORE.setting:
19:39 dalek niecza: Seems STD wants <alpha> to match "_"
19:39 dalek niecza: review: https://github.com/sorear/niecza/commit/64376da5ca
19:39 sorear now running the pre-release spectest
19:40 moritz niecza: say so '_' ~~ /<:alpha>/
19:40 p6eval niecza v12-183-g8fef06e: OUTPUT«Bool::False␤»
19:42 sorear :alpha is the Unicode property "Alphabetic"
19:42 sorear <alpha> is now defined as <:alpha + [_]>
19:45 moritz yes, I'm aware
19:46 moritz just thought I'd check :-)
19:46 TimToady maybe we should rename that to <al_pha>  :)
19:47 TimToady more seriously, maybe it should be <wchar> if it reflects \w
19:48 TimToady but I shouldn't be designing anything till my brane improves a bit more...
19:49 IngisKahn joined #perl6
19:58 sorear aaaaa wchar_t
19:59 TimToady right...well, <w> is maybe available, but \w is still shorter :)
20:00 TimToady anyway, as I say, I'm still not quite up to weighing tradeoffs in my head
20:00 TimToady at least I can think about one thing at a time now...
20:00 TimToady last week it was more like .5 things at a time
20:02 TimToady s/week/month/
20:02 icwiener joined #perl6
20:02 masak ruoso: "concurrent task" is a cute term. I like.
20:03 drbean joined #perl6
20:04 ruoso masak: parrot uses the term 'task' as the generic for "green thread" or "os thread"
20:04 masak ooh, nice.
20:06 fglock left #perl6
20:08 fridim_ joined #perl6
20:25 cognominal_ joined #perl6
20:31 ksi joined #perl6
20:33 drbean joined #perl6
20:34 bbkr1 joined #perl6
20:46 mj41 joined #perl6
20:50 donri left #perl6
20:54 molaf joined #perl6
21:04 [particle] joined #perl6
21:06 ilogger2 joined #perl6
21:14 dalek niecza: 66cefa7 | sorear++ | Makefile:
21:14 dalek niecza: github.com has a valid SSL certificate now
21:14 dalek niecza: review: https://github.com/sorear/niecza/commit/66cefa779d
21:14 dalek niecza: a22318d | sorear++ | FETCH_URL:
21:14 dalek niecza: Update FETCH_URL
21:14 dalek niecza: review: https://github.com/sorear/niecza/commit/a22318d819
21:15 masak 'night, #perl6
21:15 sorear v13 ann sent
21:16 sorear 'night masak
21:18 Yary joined #perl6
21:19 [particle] joined #perl6
21:22 Yary Hi. I updated my Rakudo git clone (after about a year of non-use) and a simple Grammar failed- http://pastebin.com/wA0G9qRY
21:22 Yary is it my build, or has the syntax changed?
21:23 colomon probably syntax, give me a moment
21:24 colomon hmmm...
21:24 tadzik shouldn't that be :actions(Math::Actions.new)?
21:25 Yary I'll try adding ".new"
21:25 arlinius joined #perl6
21:26 colomon parse definitely still has an :actions argument
21:26 Yary same error here
21:27 Yary Not sure it is a good build. There was a test failure: t/02-embed/01-load.t ............... Failed 1/1 subtests
21:27 colomon Yary: it works for me
21:27 Yary OK that's good to know
21:28 colomon might be worth doing a "make realclean" and rebuilding everything from scratch
21:28 Yary arrgh takes forever but OK
21:30 Yary realclan lost my makefile :-(
21:30 Yary have to go for a bit, thanks for the start though
21:49 drbean joined #perl6
21:52 Yary just had to re-run Configure to get the Makefile back
22:13 drbean joined #perl6
22:18 y3llow joined #perl6
22:19 pothos joined #perl6
22:20 y3llow joined #perl6
22:22 pothos joined #perl6
22:23 y3llow joined #perl6
22:23 * sorear needs a more ... statistically robust ... way to do timings
22:25 y3llow joined #perl6
22:25 pothos joined #perl6
22:31 sorear phenny: tell [Coke] What do I need to do to run autounfudge against niecza?
22:31 phenny sorear: I'll pass that on when [Coke] is around.
22:56 dalek ecosystem: 5774692 | tadzik++ | META.list:
22:56 dalek ecosystem: Add Bailador
22:56 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/5774692483
23:10 tadzik nom: qr[/foo]
23:10 p6eval nom eb6c4b: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<[ ]>, couldn't find final ']' at line 2␤»
23:10 tadzik std: qr[/foo]
23:10 p6eval std dc62e1d: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤Unable to parse regex; couldn't find final '/' at /tmp/AjjYKRPFG_ line 1:â�¤------> [32mqr[/foo[33mâ��[31m][0mâ�¤    expecting any of:â�¤        quantifierâ�¤     regex atomâ�¤Undeclared routine:â�¤ 'qr' used at line 1â�¤Parse failedâ�¤FAILED 00:01 121mâ�¤Â»â€¦
23:10 tadzik hmm
23:10 mj41 joined #perl6
23:10 tadzik std: qr[/foo/]
23:10 p6eval std dc62e1d: OUTPUT«[31m===[0mSORRY![31m===[0m�Undeclared routine:� 'qr' used at line 1�Check failed�FAILED 00:01 121m�»
23:10 tadzik does it treat [/ as a delimiter?
23:17 whsdu joined #perl6
23:26 tadzik https://gist.github.com/1522280 -- mostly working Bailador pastebin
23:40 TimToady why are you expecting qr to do anything special?
23:41 tadzik I was expecting it to turn '/foo' into a regex
23:41 TimToady that's a p5ism
23:41 TimToady there is no qr in p6
23:41 tadzik oh, ok
23:42 TimToady maybe you wanted rx[]
23:42 tadzik probably, yes. Thank you
23:53 drbean joined #perl6

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

Perl 6 | Reference Documentation | Rakudo