Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2011-12-25

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:10 mkramer joined #perl6
00:11 drbean joined #perl6
00:28 drbean joined #perl6
00:28 mkramer joined #perl6
00:57 drbean joined #perl6
01:02 donri left #perl6
01:39 PacoLinux_ joined #perl6
01:47 dalek niecza: 48254f0 | (Solomon Foster)++ | lib/CORE.setting:
01:47 dalek niecza: Add default value for sub version of join.
01:47 dalek niecza: review: https://github.com/sorear/niecza/commit/48254f03fa
01:47 dalek niecza: d2cdef9 | (Solomon Foster)++ | t/spectest.data:
01:47 dalek niecza: Turn on join.t.
01:47 dalek niecza: review: https://github.com/sorear/niecza/commit/d2cdef9a16
01:49 dalek roast: 4bfbe31 | (Solomon Foster)++ | S04-phasers/begin.t:
01:49 dalek roast: Unfudge tests that now work in niecza.
01:49 dalek roast: review: https://github.com/perl6/roast/commit/4bfbe319bb
01:55 * colomon is making strata, listening to Newfoundland Christmas music, and contemplating adding min and max to niecza.
01:59 colomon oh, yes, and drinking spiked egg nog
02:02 thou joined #perl6
02:17 bsinger joined #perl6
02:17 colomon strata done.  taking advantage of Jen's absence (bell choir for the 9pm service) to stuff her stocking
02:25 drbean joined #perl6
03:02 tokuhirom joined #perl6
03:05 thou joined #perl6
03:17 dalek niecza: a7d963a | coke++ | t/spectest.data:
03:17 dalek niecza: run S16-filehandles/filetest.t again
03:17 dalek niecza: review: https://github.com/sorear/niecza/commit/a7d963a1ad
03:20 colomon o/, [Coke]
03:25 dalek roast: ecf161e | (Solomon Foster)++ | S32-list/reverse.t:
03:25 dalek roast: Fudge for niecza.
03:25 dalek roast: review: https://github.com/perl6/roast/commit/ecf161e577
03:25 bsinger left #perl6
03:30 benabik joined #perl6
03:32 [Coke] colomon: o/
03:33 dalek niecza: 702185e | (Solomon Foster)++ | t/spectest.data:
03:33 dalek niecza: Turn on S32-list/reverse.t.
03:33 dalek niecza: review: https://github.com/sorear/niecza/commit/702185e106
03:36 drbean joined #perl6
03:37 Psyche^ joined #perl6
03:41 twinshadow joined #perl6
04:00 dalek niecza: ade1b7d | Coke++ | tools/unrun_tests:
04:00 dalek niecza: avoid extra "/" in path on OS X
04:00 dalek niecza: review: https://github.com/sorear/niecza/commit/ade1b7dc71
04:00 dalek niecza: 0f82c9c | Coke++ | t/spectest.data:
04:00 dalek niecza: Remove trailing whitespace
04:00 dalek niecza: review: https://github.com/sorear/niecza/commit/0f82c9ce96
04:00 packetknife joined #perl6
04:14 colomon sorry for disappearing, my wife finally came home just after that last push.
04:15 colomon ;)
04:18 [Coke] I'm nearly done for the night, I think. What's up?
04:19 twinshadow joined #perl6
04:29 colomon nothing in particular, just saluting another Christmas Eve warrior.  ;)
04:31 [Coke] ;)
04:36 PacoLinux_ joined #perl6
04:41 avar joined #perl6
04:41 avar joined #perl6
04:41 gfldex joined #perl6
04:45 Ingis joined #perl6
05:51 PacoLinux_ joined #perl6
06:23 drbean joined #perl6
07:09 PacoLinux_ joined #perl6
07:29 fglock joined #perl6
07:47 envi_ joined #perl6
08:04 masak hi lol mornings people!
08:05 masak moritz and I are going to announce this year's p6cc today! we're writing up the blog post right now.
08:05 masak but this is just to let y'all know that things are underway. :)
08:24 fglock what is p6cc?
08:25 masak oh!
08:25 masak it's a programming contest that we did last year.
08:25 fglock ah, cool
08:26 masak moritz++ won it, and now he's helping arrange this year's contest.
08:26 masak http://strangelyconsistent.org/blog/masaks-perl-6-coding-contest
08:56 MayDaniel joined #perl6
09:07 Mowah joined #perl6
09:20 finanalyst joined #perl6
09:35 tokuhirom joined #perl6
09:44 snearch joined #perl6
09:48 mj41 joined #perl6
09:56 kaare_ joined #perl6
10:00 alvis joined #perl6
10:09 mj41 joined #perl6
10:21 PacoLinux_ joined #perl6
10:39 masak ...aaaaaaaand here we go...
10:39 masak blog post! \o/ http://strangelyconsistent.org/blog/the-2011-perl-6-coding-contest
10:39 masak may the best coder win! \o/
10:41 masak could I perhaps ask the favor of kind people on this channel to post that URL to Hacker News and Reddit?
10:43 Timbus oooo fun things to do
10:43 masak we'd like to think so ;)
10:43 masak sign up sign up sign up
10:44 Timbus haha. nah i'll pass, but i might try a few on my own
10:45 masak fair enough :)
10:48 moritz help spread the word by upvoting http://www.reddit.com/r/programming/comments/nq34x/the_2011_perl_6_coding_contest/
10:49 moritz ... and http://news.ycombinator.com/item?id=3390840
10:49 masak \o/
10:52 PacoLinux_ joined #perl6
11:04 envi_ joined #perl6
11:17 hundskatt joined #perl6
11:22 masak we're being downvoted on Reddit. help us by upvoting the post! http://www.reddit.com/r/programming/comments/nq34x/the_2011_perl_6_coding_contest/
11:23 muixirt joined #perl6
11:25 muixirt oops, "The requested URL /p6cc2011/t1-description was not found on this server."
11:25 colomon o/
11:26 Timbus just get the .zip
11:26 muixirt some links do not work in masak's blog post
11:26 Timbus s' got em all
11:27 muixirt Timbus: yes, but it maybe worth correcting though
11:27 Timbus definitely yes
11:27 moritz oops, I accidentally submitted the reddit URL to hackernes :/
11:27 Timbus just providing the workaround
11:27 masak moritz: it can't be edited?
11:28 * masak sees about fixing the broken links
11:28 masak muixirt++ # reporting it
11:28 moritz don't think so
11:28 masak masak-- # not double-cheking it
11:28 moritz somebody could just re-submit the original URL
11:32 masak links fix'd.
11:33 moritz masak++
11:35 masak FTP. it's hard. :)
11:36 moritz it is?
11:36 * moritz uses unison and git for synchronising his websites
11:43 * masak checks out unison
11:43 moritz it's like two-way rsync over ssh
11:44 masak right.
11:44 colomon and it's written in OCaml
11:44 moritz implemented in ocaml
11:44 masak nice!
11:44 colomon ocaML?
11:44 moritz colomon++ is faster
11:44 colomon however you spell it.
11:44 moritz OCaml is correct
11:44 moritz it's Caml, plus Objects
11:44 masak O'Caml :)
11:45 colomon as far as I know, it's the only functional programming program I use on a regular basis.  :)
11:47 colomon nom: 42.classify(* % 3)
11:47 p6eval nom eb6c4b:  ( no output )
11:48 colomon nom: say 42.classify(* % 3).perl
11:48 p6eval nom eb6c4b: OUTPUT«("0" => [42],).list␤»
11:48 colomon lives_ok { 42.classify: { $_ } },      "method form of classify should not work on numbers";
11:48 colomon test and comment do not agree
11:49 moritz probably a left-over from the days before we considered scalars one-element lists
11:49 moritz I'm pretty sure that if you trace the commit that last changed it, you'll find that it used to be dies_ok
11:50 dalek roast: f64c232 | (Solomon Foster)++ | S32-list/classify.t:
11:50 dalek roast: Fudge for niecza.  (Also be more explicit about the sort call for niecza.)
11:50 dalek roast: review: https://github.com/perl6/roast/commit/f64c232925
11:53 masak there was a time when we didn't consider scalars to be one-element lists?
11:53 * masak surprised
11:53 * geekosaur vaguely recalls such, yes
11:54 * colomon thought it had gone the other way, and we'd *stopped* considering scalars to be one-element lists....
11:56 snearch joined #perl6
12:02 achromic joined #perl6
12:03 mj41 joined #perl6
12:06 dalek roast: a921383 | (Solomon Foster)++ | S32-list/end.t:
12:06 dalek roast: Fudge for niecza.
12:06 dalek roast: review: https://github.com/perl6/roast/commit/a92138318e
12:08 tadzik 'morning!
12:09 colomon 'morning, indeed!
12:10 dalek roast: b8f2553 | (Solomon Foster)++ | S32-array/end.t:
12:10 dalek roast: Fudge for niecza.
12:10 dalek roast: review: https://github.com/perl6/roast/commit/b8f2553861
12:11 mkramer joined #perl6
12:15 lutok joined #perl6
12:17 dalek niecza: e02456e | (Solomon Foster)++ | lib/CORE.setting:
12:17 dalek niecza: Add moritz++'s classify method.
12:17 dalek niecza: review: https://github.com/sorear/niecza/commit/e02456eb9d
12:17 dalek niecza: a7489b4 | (Solomon Foster)++ | t/spectest.data:
12:17 dalek niecza: Turn on S32-list/classify.t.
12:17 dalek niecza: review: https://github.com/sorear/niecza/commit/a7489b48f1
12:17 dalek niecza: 64834ad | (Solomon Foster)++ | lib/CORE.setting:
12:17 dalek niecza: Add end method & sub.
12:17 dalek niecza: review: https://github.com/sorear/niecza/commit/64834adb36
12:17 dalek niecza: 3c70250 | (Solomon Foster)++ | t/spectest.data:
12:17 dalek niecza: Turn on S32-array/end.t and S32-list/end.t.
12:17 dalek niecza: review: https://github.com/sorear/niecza/commit/3c70250d63
12:19 fridim_ joined #perl6
12:22 achromic joined #perl6
12:23 * colomon continues hacking at niecza while he waits for the rest of his family to get up on this fine Christmas morning...
12:27 Trashlord joined #perl6
12:33 mkramer1 joined #perl6
12:33 masak tadzik: morningmakesureyousignupforthecontest! :D
12:34 tadzik masak: ...I did!
12:34 masak \o/
12:35 masak everyone else, follow tadzik's example! :D
12:35 alvis joined #perl6
12:35 tadzik those are funny tasks this year
12:37 masak yes, we're quite proud of them.
12:37 masak ooh, tadzik and someone else signed up already!
12:38 tadzik I hope I'll be able to give those a proper amount of time
12:39 masak tadzik: just curious; any of the tasks seem particularly easy, or particularly interesting?
12:40 tadzik reading just the headilnes "Find a way to express an integer as an expression containing four 9s" was the biggest "wtf" to me :)
12:41 masak :)
12:44 tadzik t3... idiomatic Perl 6... I think I see what you did there :)
12:45 tadzik time will tell
12:46 moritz there's more than just '[+] @foo' to the task :-)
12:47 tadzik I know :)
12:48 alvis joined #perl6
13:05 masak someone on Reddit thinks I should have used github instead of host things on my server: http://www.reddit.com/r/programming/comments/nq34x/the_2011_perl_6_coding_contest/c3b1v8t
13:12 * moritz thinks email submissions are fine
13:12 masak yeah; me too.
13:13 masak we could definitely've presented the tasks through github; maybe we even will, next year.
13:13 masak that feels like a more civilized way to distribute things than .zip files nowadays.
13:14 moritz aye
13:28 mkramer joined #perl6
13:32 mkramer joined #perl6
13:45 mkramer joined #perl6
13:47 pmurias joined #perl6
14:00 Chillance joined #perl6
14:02 mkramer joined #perl6
14:08 mkramer1 joined #perl6
14:18 mkramer joined #perl6
14:22 mkramer joined #perl6
14:31 mkramer joined #perl6
14:32 PacoLinux joined #perl6
14:33 bluescreen10 joined #perl6
14:54 mkramer joined #perl6
15:10 zhangkaizhao joined #perl6
15:11 achromic left #perl6
15:12 zhangkaizhao joined #perl6
15:18 zhangkaizhao joined #perl6
15:21 dalek roast: 484d409 | (Solomon Foster)++ | S32-list/minmax.t:
15:21 dalek roast: Rewrite file test to match current I/O spec.  Fudge for niecza.
15:21 dalek roast: review: https://github.com/perl6/roast/commit/484d409ea6
15:35 mkramer joined #perl6
15:37 dalek niecza: 7abe205 | (Solomon Foster)++ | lib/CORE.setting:
15:37 dalek niecza: min, max, and minmax.
15:37 dalek niecza: review: https://github.com/sorear/niecza/commit/7abe205496
15:37 dalek niecza: 9a8aaf4 | (Solomon Foster)++ | t/spectest.data:
15:37 dalek niecza: Turn on S32-list/minmax.t.
15:37 dalek niecza: review: https://github.com/sorear/niecza/commit/9a8aaf4e30
15:39 mkramer1 joined #perl6
15:40 x3nU joined #perl6
15:43 tokuhirom joined #perl6
16:05 mkramer joined #perl6
16:21 mkramer joined #perl6
16:26 mkramer joined #perl6
16:29 donri joined #perl6
16:55 Ingis joined #perl6
17:01 PacoLinux joined #perl6
17:08 mkramer joined #perl6
17:09 arnsholt Heh. NP-complete problems in a competition. That's just mean ^_^
17:12 masak arnsholt: just like you to go looking things up :P
17:13 mkramer left #perl6
17:14 mkramer joined #perl6
17:14 mkramer left #perl6
17:14 arnsholt masak: The question set my research-senses a'tingling =)
17:15 arnsholt But problem four sounds more dangerous than problem three, so far
17:15 arnsholt Just like the kayles problem last year =D
17:19 arnsholt I think I'm gonna have to check out a copy of TAoCP when I get back to university though
17:51 Mowah joined #perl6
18:12 sftp joined #perl6
18:32 lichtkind joined #perl6
18:32 lichtkind corrected 4 entries in perl 6 tablets index a
18:33 lichtkind advent calenda is really good for that
18:58 Radvendii joined #perl6
18:59 Radvendii hey, has panda been updated to run with rakudo 2011.12?
18:59 lichtkind not that i know of
19:00 drbean joined #perl6
19:00 ruoso was there any recent activity in the threading front?
19:02 lichtkind ruoso: i have a beatle farm :)
19:02 * ruoso feels that he lost something in that joke
19:02 Radvendii hahaha
19:02 lichtkind ruoso: i just ment that im not involved much in panda
19:03 lichtkind because of my own project called after a beatle
19:03 ruoso oh... I was asking in a Perl 6 sense in general...
19:04 lichtkind ruoso: same answer :) not taht i know o
19:04 lichtkind f
19:06 sayu joined #perl6
19:08 masak six people signed up to p6cc so far. \o/
19:08 masak that's after 8 hours.
19:08 Radvendii p6cc?
19:09 lichtkind coding contest
19:09 lichtkind not c compiler :)
19:11 masak Radvendii: http://strangelyconsistent.org/blog/the-2011-perl-6-coding-contest
19:11 masak signing up is free, and if no-one sends in a solution, you'll have 1 chance in 7 of winning 100€ worth of books. :)
19:13 masak ruoso: no, no significant progress with threading. Niecza does it, AFAIK. but nothing has happened spec-wise. we need a champion who JFDIs.
19:13 * masak .oO( or is that spelled "JFDsI"? )
19:15 ruoso masak: hm... so.. I'm trying to get my rythm back...
19:16 ruoso one thing that I have considered in the past and that I still think is the bridge to the parallelism model
19:16 ruoso is S07
19:19 ruoso I mean, we could simply have the basics, such as async block and the like... but if we consider things like feeds and lazy objects in general
19:19 benabik joined #perl6
19:20 ruoso List is actually more core to threading than explicit thread constructs
19:22 ruoso So what I have in mind is to kind of replicate the concept of unix pipes, in the sense that the VM would provide a basic "blocking buffered stream" primitive
19:23 ruoso and we would be able to have interpreter threads blocking on reading/writing operations in such streams
19:25 ruoso then an operation like "@a = 1..inf;" would create a "blocking buffered stream" and a new thread that would run the range generator, while the main thread would proceed as usual...
19:25 ruoso so it would produce some values until it fills the buffer, then wait for the values to be consumed, and as they are consumed, they would unblock the other thread
19:27 snearch joined #perl6
19:32 drbean joined #perl6
19:37 masak sounds interesting.
19:42 ruoso I am having a hard time finding anything about threading in the parrot docs
19:47 muixirt joined #perl6
19:48 PacoLinux joined #perl6
19:49 muixirt ruoso: maybe whiteknights advent blog post helps a little: http://whiteknight.github.com/2011/12/15/advent_4_threading.html
19:50 sorear good * #perl6
19:50 sorear o/ ruoso
19:51 ruoso hui sorear
19:53 sorear colomon: sorry.  I picked a bad day to be stuck in bed sick
19:56 ruoso muixirt: thanks... that did explain things... even if not the way I hoped
19:56 drbean joined #perl6
19:57 pmurias fg
19:57 pmurias sorry
20:04 sorear the task lineup for p6cc/2011 reminds me a lot of Project Euler.
20:06 geef joined #perl6
20:12 lichtkind index a has now much better navigation
20:12 masak sorear: I think the dreaded p4 problem from last year even had a kind of cousing amount eh project Euler problems. (but I didn't know that when I chose it.)
20:13 masak I haven't actually looked at many Euler problems.
20:13 masak ruoso: it's nice to have you back, by the way.
20:15 ruoso masak, thanks... yep... I was missing doing open source stuff too..
20:15 sorear project euler is great.  I did the first 75-100 of them as part of my "learn J" exercises earlier
20:16 sorear (it's suprising how many of them are J primitives)
20:16 pmurias is the spec avalible in a format suitable for a kindle?
20:19 sorear the spec is available in HTML.  What formats will a kindle grok?
20:19 * sorear compulsively gets to work on p1
20:19 sorear also, o/ masak
20:21 pmurias sorear: i'm looking for something explicitly formated for a ereader so it will display nicely
20:26 drbean joined #perl6
20:35 ksi joined #perl6
20:35 ruoso pmurias: I think calibre can convert html to epub
20:39 pmurias ruoso: i'll try pod2epub first
20:39 tadzik sorear: Kindle prefers .mobi
20:40 masak pmurias: I know Andrew Shitov had the spec on a kindle.
20:40 masak sorear: \o
20:40 masak sorear: are you another one of those who are going to attack the problems without signing up? :)
20:42 sorear yes.
20:43 masak Timbus indicated earlier that he's one too.
20:45 masak yes, project euler looks pretty great. I've been thinking of doing more of the problems, but have never gotten started with it.
20:54 simon__ joined #perl6
20:55 simon__ hello. I'm trying to make a list of lists with gather for but it keeps flattening the result. can someone tell me what i'm doing wrong?
20:56 masak simon__: maybe make a list of arrays instead?
20:56 masak lists of lists often flatten, because Perl works that way.
20:56 masak nom: say (gather { take [1..$_] for 4..6 }).perl
20:56 p6eval nom eb6c4b: OUTPUT«(1, 2, 3, 4, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 6).list␤»
20:57 masak huh.
20:57 simon__ that's what i've been doing
20:57 masak nom: say (gather { take [[1..$_]] for 4..6 }).perl
20:57 p6eval nom eb6c4b: OUTPUT«([1, 2, 3, 4], [1, 2, 3, 4, 5], [1, 2, 3, 4, 5, 6]).list␤»
20:57 sorear eheheheh... I don't think it should work that way
20:57 masak using double layers seems to work.
20:57 sorear b: say (gather { take [1..$_] for 4..6 }).perl
20:57 p6eval b 1b7dd1: OUTPUT«([1, 2, 3, 4], [1, 2, 3, 4, 5], [1, 2, 3, 4, 5, 6])␤»
20:57 sorear niecza: say (gather { take [1..$_] for 4..6 }).perl
20:57 masak but no, it seems wrong that it works so from the start in nom.
20:57 p6eval niecza v12-177-g9a8aaf4: OUTPUT«([1, 2, 3, 4], [1, 2, 3, 4, 5], [1, 2, 3, 4, 5, 6]).list␤»
20:58 sorear pugs: say (gather { take [1..$_] for 4..6 }).perl
20:58 p6eval pugs b927740: OUTPUT«([1, 2, 3, 4], [1, 2, 3, 4, 5], [1, 2, 3, 4, 5, 6])␤»
20:58 masak probably a bug.
20:58 sorear nomgression
20:58 * masak submits rakudobug
20:58 sorear hey, the masakbot is back
20:58 masak simon__++ # for discovering
20:58 sorear (You seem new.  Welcome, simon__)
20:59 masak sorear: after a refreshing vacation in the warmer parts of Asia ;)
20:59 simon__ thanks ;)
21:02 GlitchMr joined #perl6
21:02 sorear o/ GlitchMr
21:02 GlitchMr Hello
21:04 GlitchMr I'm just experimenting.  I'm trying to use qwebirc on Android.  It's hard to use.
21:05 GlitchMr I'm probably crazy or something.
21:05 moritz \o
21:05 masak hi GlitchMr
21:05 sorear o/ moritz
21:06 GlitchMr hi, masak
21:06 sorear nom: sub foo($x [$y] [$z]) { ... }
21:07 p6eval nom eb6c4b: OUTPUT«===SORRY!===␤Cannot have more than one sub-signature for a parameter at line 1, near ") { ... }"␤»
21:07 sorear std: sub foo($x [$y] [$z]) { ... }
21:07 p6eval std dc62e1d: OUTPUT«Potential difficulties:â�¤  $x is declared but not used at /tmp/OwZ05_4kHw line 1:â�¤------> [32msub foo([33mâ��[31m$x [$y] [$z]) { ... }[0mâ�¤  $y is declared but not used at /tmp/OwZ05_4kHw line 1:â�¤------> [32msub foo($x [[33mâ��[31m$y] [$z]) { ... }[0mâ�¤  $z is decla…
21:07 sorear std: sub foo($x [$y] [$z]) { ... } #OK
21:07 p6eval std dc62e1d: OUTPUT«ok 00:01 121m␤»
21:07 sorear stdbug or nombug?
21:09 sorear Is there a difference btween $x ($y) and $x [$y] ?
21:11 moritz I'm pretty sure that [$y] forces access via postcircumfix:<[ ]>
21:11 moritz not sure what ($y) does
21:12 moritz maybe the differences is that ($y) tries to coerce to Capture, or something (but I don't really have a clue)
21:13 moritz nom: sub f($x [$y]) { say $y }; f 1
21:13 p6eval nom eb6c4b: OUTPUT«Not enough positional parameters passed; got 0 but expected 1 in sub-signature of parameter $x␤  in sub f at /tmp/t4kY2PicLQ:1␤  in block <anon> at /tmp/t4kY2PicLQ:1␤  in <anon> at /tmp/t4kY2PicLQ:1␤»
21:13 moritz nom: sub f($x [$y]) { say $y }; f (1, 2)
21:13 p6eval nom eb6c4b: OUTPUT«Too many positional parameters passed; got 2 but expected 1 in sub-signature of parameter $x␤  in sub f at /tmp/g0vYVi8Bd7:1␤  in block <anon> at /tmp/g0vYVi8Bd7:1␤  in <anon> at /tmp/g0vYVi8Bd7:1␤»
21:13 moritz nom: sub f($x [$y]) { say $y }; f [1]
21:13 p6eval nom eb6c4b: OUTPUT«1␤»
21:13 moritz nom: sub f($x ($y)) { say $y }; f [1]
21:13 p6eval nom eb6c4b: OUTPUT«1␤»
21:21 sorear moritz: according to STD, both cases parse a <signature> inside
21:21 tadzik phenny: tell GlitchMr you should've tried qwebirc on a Kindle ;)
21:21 phenny tadzik: I'll pass that on when GlitchMr is around.
21:22 sorear colomon wanted post_constraint by Christmas
21:22 sorear (I failed him !)
21:26 moritz it's still christmas until tomorrow, according to my locale :-)
21:32 simon__ nom: my @xs = 1..5; @xs = gather for @xs -> $x { take $x };
21:32 p6eval nom eb6c4b:  ( no output )
21:32 simon__ nom: my @xs = 1..5; @xs = gather for @xs -> $x { take $x }; say for @xs;
21:32 p6eval nom eb6c4b: OUTPUT«␤␤␤␤␤»
21:33 simon__ nom: my @xs = 1..5; my @ys = gather for @xs -> $x { take $x }; say for @ys;
21:33 p6eval nom eb6c4b: OUTPUT«␤␤␤␤␤»
21:35 simon__ nom: my @xs = 1..5; my @ys = gather for @xs -> $x { take $x }; .say for @ys;
21:35 p6eval nom eb6c4b: OUTPUT«1␤2␤3␤4␤5␤»
21:35 simon__ nom: my @xs = 1..5; @xs = gather for @xs -> $x { take $x }; .say for @xs;
21:35 p6eval nom eb6c4b: OUTPUT«1␤2␤3␤4␤5␤»
21:36 sorear niecza: my @xs = 1..5; my @ys = gather for @xs -> $x { take $x }; say for @ys;  # I wonder how hard it would be to add this to nom?
21:36 p6eval niecza v12-177-g9a8aaf4: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/keivzLD8MR line 1:â�¤------> [32m = gather for @xs -> $x { take $x }; say[33mâ��[31m for @ys;  # I won…
21:39 ruoso nom: split //, "asdfg"
21:39 p6eval nom eb6c4b: OUTPUT«===SORRY!===␤Null regex not allowed at line 1, near ", \"asdfg\""␤»
21:39 ruoso why?
21:41 sorear because TimToady thought it would be a useful way to trap p5istic expectations of "last successful regex"
21:41 donri left #perl6
21:41 sorear nom: say split / '' /, "asdfg"
21:41 p6eval nom eb6c4b: OUTPUT« a s d f g ␤»
21:45 jaldhar joined #perl6
21:47 masak also, there's something to be said for always explicitly saying 'nothing'.
21:47 * masak fondly remembers the 'nothing' statement in Perl 6, which existed briefly
21:48 sorear like 'pass'?
21:48 masak yeah.
21:49 masak but it was a 0-param multi sub.
21:49 achromic joined #perl6
21:49 masak seems it went away for good 2008-07-18.
21:50 * sorear wonders what to put about spec-tests in announce.v13
21:52 masak that Niecza has taken leaps and bounds in that regard?
21:53 sorear perl6: say+5
21:53 p6eval niecza v12-177-g9a8aaf4: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/7hHnaoqlJN line 1:â�¤------> [32msay[33mâ��[31m+5[0mâ�¤â�¤Unhandled exception: Check failedâ�¤â�¤  at /home/p…
21:53 p6eval ..pugs b927740, rakudo eb6c4b: OUTPUT«␤»
21:54 sorear perl6: say$_
21:54 p6eval niecza v12-177-g9a8aaf4: OUTPUT«[31m===[0mSORRY![31m===[0m��Unsupported use of bare 'say'; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument at /tmp/8qZSqEnjvG line 1:�------> [32msay[33m�[31m$_[0m��Two terms in a row (listop with args requires w…
21:54 p6eval ..rakudo eb6c4b: OUTPUT«===SORRY!===␤Confused at line 1, near "say$_"␤»
21:54 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected "$_"␤    expecting "::", dot, ":", "(", term postfix or operator␤    at /tmp/oVmzwqffKQ line 1, column 4␤»
21:55 sorear I wonder why m<TAB> pulls up moritz when masak spoke more recently
21:55 sorear closing the moritz query window doesn't change it
21:55 sorear irsii-- #inscrutability
21:56 sorear masak: yes, I want something like that, but maybe more quantified :)
21:56 sorear irssi-- irsii++ # sp
22:00 masak sorear: I also want it more quantified, fwiw ;)
22:01 ruoso nom: split /''/, $*IN.slurp
22:01 p6eval nom eb6c4b:  ( no output )
22:01 packetknife joined #perl6
22:01 ruoso hmm.. the bot used to hae some sample input
22:02 sorear ruoso: you need "say" for there to be any outpuit.
22:02 ruoso nom: say split /''/, $*IN.slurp
22:02 p6eval nom eb6c4b: OUTPUT« L a n d   d e r   B e r g e ,   L a n d   a m   S t r o m e , ␤ L a n d   d e r   Ä c k e r ,   L a n d   d e r   D o m e , ␤ L a n d   d e r   H ä m m e r ,   z u k u n f t s r e i c h ! ␤ H e i m a t   b i s t   d u   g r o ß e r   S ö h n e , ␤ V o l k ,   b e g n…
22:02 ruoso nom: say((split /''/, $*IN.slurp).perl)
22:02 p6eval nom eb6c4b: OUTPUT«("", "L", "a", "n", "d", " ", "d", "e", "r", " ", "B", "e", "r", "g", "e", ",", " ", "L", "a", "n", "d", " ", "a", "m", " ", "S", "t", "r", "o", "m", "e", ",", "\n", "L", "a", "n", "d", " ", "d", "e", "r", " ", "Ä", "c", "k", "e", "r", ",", " ", "L", "a", "n", "d", " …
22:03 ruoso see.. there is a leading ""
22:03 ruoso that, I think, was not supposed to be there... was it?
22:04 masak ruoso: apparently, that's to spec.
22:04 sorear I think it is supposed to be there
22:04 sorear you're not supposed to use split /''/ anymore anyway
22:04 masak right.
22:04 sorear nom: say $*IN.slurp.comb.perl
22:04 p6eval nom eb6c4b: OUTPUT«("L", "a", "n", "d", " ", "d", "e", "r", " ", "B", "e", "r", "g", "e", ",", " ", "L", "a", "n", "d", " ", "a", "m", " ", "S", "t", "r", "o", "m", "e", ",", "\n", "L", "a", "n", "d", " ", "d", "e", "r", " ", "Ä", "c", "k", "e", "r", ",", " ", "L", "a", "n", "d", " ", "…
22:04 masak there's a special case in Perl 5 that silences a first empty element like that. the special case has been removed in Perl 6.
22:04 ruoso but... why does split returns an empty string?
22:05 ruoso is that really a special case?
22:05 * sorear wonders where to draw the line between "major" and "minor" features when the work this month has been mostly minor
22:05 ruoso i didn't know that
22:05 MayDaniel joined #perl6
22:05 sorear ruoso: because /''/ matches after a zero-length string
22:09 masak I have a feeling some people here might appreciate http://www.reddit.com/r/programming/comments/no0dy/another_world_code_review/
22:25 Ingis joined #perl6
22:27 dduncan joined #perl6
22:28 dduncan question - is it decided a canonical way to arrange Perl 6 modules in a lib/ dir accounting for multiple versions of the same module being installed at once?
22:28 dduncan I know Synopsis 11 (modules) talks about versioning packages, but I don't know about how this maps to common file systems
22:29 dduncan eg, if you have Foo::Bar, it might be stored as lib/Foo/Bar.pm if there was 1 version
22:29 masak djanatyn: [backlog] my ADHD approach to browsing beats your ADHD approach to browsing ;)
22:29 dduncan but what to do when there are multiple authorities or vnums?
22:30 masak djanatyn: at some point a few years ago, I had 4500 tabs open in Firefox.
22:30 arnsholt dduncan: If you have any brilliant ideas we're all ears I think
22:30 arnsholt It's one of the things that haven't really been ironed out yet
22:31 tadzik S11 is not quite describing the current living module ecosystem
22:31 sorear dduncan: figuring that stuff out has been on my TODO list for a while
22:31 sorear dduncan: I haven't worked out all the details yet, but one thing I am sure of is that a filesystem is not sufficient
22:31 masak there's been mumblings about a database of some kind handling the versioning. in some ways, I think that's sad, because it loses the contact with the file system.
22:31 sorear we're going to need some kind of package metadata database thing
22:31 djanatyn masak: wow :o
22:32 masak djanatyn: I'm not proud.
22:32 dduncan_ joined #perl6
22:32 tadzik djanatyn: ooc, why did you give up on the bailador task?
22:33 sorear I do most of my browsing in a 212x78 elinks window.  When the tab bar on row 76 gets to the point where I can only see 1 character from each title, I know I have too many open.
22:33 djanatyn tadzik: Too busy >_<
22:33 tadzik I see
22:33 tadzik I may want to hack up some POST support for it tomorrows
22:34 djanatyn I had a lot of things going on, and didn't put in the time I needed
22:34 sorear ...why does Bailador need special support from POST?
22:34 tadzik to better emulate Dancer
22:34 djanatyn I wanted to write a webapp that let users browse pod files.
22:34 djanatyn I would only need GET for that
22:34 tadzik also, atm the callback doesn't get any information about the request
22:35 sorear oh, GET vs. POST
22:35 tadzik aye
22:35 sorear I heard "Parrot Opcode Syntax Tree"
22:35 tadzik heh
22:35 arnsholt masak: I sort of maybe agree with you. The files should probably still live in the FS, but some kind of additional metadata DB is definitely needed
22:36 arnsholt And the filenames should have some kind of (reasonably) transparent connection with the metadata
22:36 arnsholt Modulo FS constraints and all that
22:37 sorear I also think we need to make the concept of "distributions" more manifest
22:38 pat_js joined #perl6
22:38 arnsholt Yeah, that probably makes sense
22:38 sorear if we have 20 versions of BigFramework installed, when BigFramework.pm says "use BigFramework::SupportingModule", Perl 6 needs to pick out the matching version
22:39 masak nod
22:39 arnsholt Indeed
22:39 masak there's a missing level of packaging there that I've been wanting to formalize; I called it "project" back in the day.
22:39 masak but "distribution" is a nice name, too.
22:39 masak it's what the C-sharpers call "assembly", I think.
22:40 arnsholt What other languages define module/ecosystem stuff as part of the spec?
22:40 arnsholt (Assuming there is one)
22:40 arnsholt Yeah, C# has some kind of versioning voodoo AFAIK
22:41 sorear Java's jars exist at the same Platonic level
22:42 arnsholt They're not versioned though, are they?
22:42 dduncan arnsholt, sorear, masak, I found myself wanting to solve essentially this problem, but perhaps slightly more complicated, right away, so I thought I'd look for precedents, but if there aren't any, I will come up with something workable
22:43 dduncan and I think we should have something that works well in the filesystem
22:43 dduncan but at the same time is also abstract enough
22:43 dduncan to not depend on the filesystem
22:43 dduncan eg, I believe that the package namespaces should be mappable to multiple storage methods
22:43 dduncan eg a tree of filesystem files, or a relational database say
22:44 dduncan the latter say useful when you want to have packages that live in the database
22:44 dduncan say for PL/PgPerl some day
22:45 dduncan my immediate context is that I'm now moving to actually implement my Muldis D language, which borrows a lot from Perl 6 in design and syntax but also focuses on database features
22:45 dduncan and I'm writing code right now that needs to work with multi-versions
22:45 dduncan so I'll invent something there that I think would likely work for Perl 6 too
22:46 dduncan besides auth and vnum variants, I also have another aspect to work in
22:46 dduncan which is segmenting
22:46 dduncan say if we have a logical package which is very large and we want to split it into multiple files for easier maintenance
22:46 dduncan I'm thinking Perl's autosplit functionality might be an analogy, but in my case it would be more manual, users decide on how to break up a logical packaeg
22:47 geef perl6? more like bitchassnig8
22:47 dalek niecza: 43fb0e8 | sorear++ | docs/announce.v13:
22:47 dalek niecza: First draft of announce.v13
22:47 dalek niecza: review: https://github.com/sorear/niecza/commit/43fb0e8c36
22:47 dalek niecza: 877780f | sorear++ | test3.pl:
22:47 dalek niecza: Some more regex tests... should merge these into roast
22:47 dalek niecza: review: https://github.com/sorear/niecza/commit/877780f97b
22:47 dduncan I had figured that say if Foo was splitup, then its pieces might go in the filesystem say as Foo/* but then we'd also need a way to not conflict with pages named Foo::*
22:47 dduncan so it seems the problem is like the multi-auth thing
22:48 dduncan they could all be solved in the same way
22:48 dduncan within the language isn't an issue, I have different syntax for referring to segments than normal packages
22:48 dduncan so its just the external view to figure out
22:50 dduncan now one might ask, why not split into smaller packages, but I prefer not to when they have mutual inter-dependencies
22:50 dduncan such as a package to define the language core
22:50 dduncan that is all
22:51 sorear nom: sub foo($x where 2 where 3) {$x}
22:51 p6eval nom eb6c4b:  ( no output )
22:51 dduncan note that segments are a detail private to a package, that users would not see
22:54 raiph joined #perl6
22:54 dduncan one possibly complicating detail, for Perl 6, is that explicit declaration of an auth or vnum for a package is optional
22:55 dduncan so then the question is to what to do with those when slotting them ... I suppose make the auth or vnum "undef" as its value
22:56 dduncan while not in the filesystem, is it defined how Perl internally deals with this?
22:56 dduncan distinguishing long names where auth or vnum are specified in a package declaration versus not?
22:58 tokuhirom joined #perl6
23:02 dduncan I thought, while not ideal, one possibility is to do like what happens with Pod rendered into other formats, and flatten the actual filesystem, so that say Foo::Bar becomes in the file system lib/Foo::Bar.pm or such
23:02 dduncan and then subdirs could be used to organize by auth or vnum etc
23:02 dduncan this would avoid certain name conflicts
23:03 dduncan on filesystems that don't let : in filenames there can be a simple encoding, like with say Pod rendered as man pages
23:03 dduncan the main downside is thousands of items at the same level
23:03 dduncan though if Perl 6 is for more modern systems that may be less of an issue
23:05 dduncan so then, for a package Foo::Bar:auth<dduncan>:vers<1.2.3> we could have lib/Foo::Bar/dduncan/1.2.3.pm or some such
23:06 dduncan or that could be partially inverted
23:06 dduncan lib/dduncan/Foo::Bar/1.2.3.pm
23:07 lichtkind joined #perl6
23:08 dduncan keep in mind that the hierarchy is just meant to be an approximation of an ideal organization, which would probably resemble a relational database instead
23:10 pmurias dduncan: lib/Foo::Bar/dduncan/1.2.3.pm seem to be a lot less convinient to work with than Foo/Bar.pm
23:11 lichtkind index A has now 654 items
23:12 lichtkind looks like perl 6 is fat ehm rich enough to get thousand
23:12 pmurias dduncan: so we would be storing the code in the working copy differently and in the module storage differently
23:12 pmurias dduncan: which seems a bit confusing
23:12 arnsholt Yeah, that'd be odd
23:13 arnsholt I think sorear's onto something with the distribution concept
23:14 arnsholt One possible solution then is to have lib/$dist-$auth-$ver/Foo/Bar.pm
23:16 pmurias lib/$sha_of_the_content seems better
23:17 arnsholt Better for the computer, but it'll make digging around in the FS cache hell
23:17 sorear colomon?
23:19 pmurias arnsholt: use a tool which spits out a directory full of cute symlinks?
23:20 sorear I would think that is missing the point
23:22 pmurias sorear: what are we trying to achieve?
23:23 dduncan to be clear, what I'm proposing is meant to be the same layout both for working and install
23:23 dduncan same as it is for Perl 5
23:23 dduncan XS notwithstanding
23:23 pmurias dduncan: anything longer then lib/Foo/Bar is unusable for me
23:23 dduncan anyway, its just an idea
23:23 pmurias for working
23:24 dduncan pmurias, so what layout do you propose when you have 2 Foo::Bar?
23:24 pmurias in the same working dir?
23:24 dduncan yes
23:24 masak I'm going to bed now, but I just wanted to say that I'm tickled pink about the uptake on p6cc this year. it's beyond my expectations.
23:24 masak 'night
23:24 dduncan or are you thinking of working and install dirs being different
23:25 * ruoso thinks about the way shared objects are handled...
23:25 sorear night masak
23:25 ruoso lib/Foo/Bar.pm.2.3.1-dduncan
23:25 dduncan there might be someone who wants to distribute multiple versions of something together
23:25 ruoso lib/Foo/Bar.pm  -> Bar.pm.2.3.1-dduncan
23:25 ruoso if that is the default version
23:25 masak ruoso: that doesn't look right -- versions are subordinate to auths.
23:26 masak really &
23:26 dduncan yes, versions subord to auths
23:26 pmurias dduncan: i'm considering install dirs different
23:26 sorear and auths are supposed to be URIish
23:26 dduncan sure, fair enough
23:26 ruoso different install dirs are very confusing
23:26 dduncan mainly I'm concerned with distribution dirs and working dirs which would probably be alike
23:26 dduncan or at least I'm used to it being that way
23:27 ruoso I would expect to have the version and author encoded in the file name...
23:27 ruoso which means different versions from different authros can fit in the same paths
23:27 dduncan ruoso, I had thought similar
23:27 dduncan so then, say lib/Foo/Bar-dduncan/2.3.1.pm
23:27 ruoso Nope
23:28 ruoso the filename
23:28 dduncan I mean -2.3
23:28 dduncan what then, lib/Foo::Bar-dduncan-2.3.1.pm?
23:28 ruoso lib/Foo/Bar.pm-dduncan-2.3.1.pm
23:28 dduncan I just said that
23:28 ruoso lib/Foo/Bar.pm-dduncan-2.3.1
23:28 dduncan oh
23:28 dduncan so the .pm isn't at the end
23:28 pmurias so when i increment the version i have to rename all the files?
23:28 ruoso presumably you don't... just your dist script
23:29 dduncan not having the .pm at the end would be a bit of a shift for me ...
23:29 ruoso your "make dist" will createe the archive with the proper names
23:29 ruoso dduncan: my reference is shared libraries... libfoo.so.0.0.1
23:29 dduncan in fact arguably the .pm is more to help the operating system, and ideally Perl itself wouldn't need it, except say to have a different name for a module and a directory
23:29 dduncan okay, if that's how shared libraries work
23:30 dduncan but would that be more installed names?  because I kind of wouldn't expect to have the 0.0.1 in the name of the file in version control
23:31 ruoso that would only be the installed names, yes
23:31 ruoso as I just said...
23:31 ruoso presumably, your make dist will create the archive with the names derived from your local files and the version metadata
23:31 dduncan ruoso, okay
23:33 ruoso the qustion then, is how to choose the default version...
23:34 ruoso and also... how to get the correct versions of modules in the same distribution
23:36 arnsholt And figuring oou
23:36 arnsholt Bah, premature carriage return
23:36 arnsholt And figuring out what to do when someone bundles someone else's module in their dist
23:37 drbean joined #perl6
23:37 ruoso Well, one could argue that bundles are "virtual" so the authorship and versions are the ones from the actual packages
23:37 colomon sorear: pong?
23:38 dduncan yes
23:38 dduncan what the actual packages declare should determine their placement
23:38 dduncan I consider distros to just be an archive of a subset of all the modules
23:38 dduncan that might be installable
23:39 dduncan and that the installed set is a different subset
23:39 dduncan the same package would live in the same place in all subsets of which it is a part, as defined by the package name inside it
23:40 dduncan as an exception, if a package doesn't internally define an auth or vnum, that can be auto-filled from the distro like a shorthand
23:40 dduncan but they would all have auth and vnum when they get into an installation, or fail to install
23:40 dduncan with my language I'm a bit different in making declared auth and vnum in a package mandatory
23:40 ruoso I once argued for distinct "source" dists and "install"d dists
23:41 dduncan and so avoid that particular issue
23:41 dduncan I prefer that a distro or a development dir is laid out so things can just run out of them directly, like a separate install
23:42 dduncan if they had similar layouts that would help
23:42 ruoso that is only true for modules that have no XS
23:42 dduncan yes
23:43 ruoso so even in the current scenario, you will run things pointing to "blib" instead of "lib"
23:43 dduncan or if otherwise what is in the dist has to be "compiled" before executing
23:43 dduncan oh, right
23:43 ruoso so, that fits the current world as well
23:44 dduncan maybe that's the solution then, lib/ can be less verbose, and blib/ has all the -auth-vers appended
23:44 dduncan or otherwise the more verbose layout
23:44 ruoso that was my thought
23:44 colomon sorear: gotta read to the little guy for a few.  back in 90min
23:44 ruoso and I would advocate for a "binary package" with the contents of  "blib"
23:45 ruoso but that invokes all sorts of other issues
23:45 dduncan there is a middle ground though
23:45 dduncan you could distribute somethiing analagous to bytecode in blib/
23:46 ruoso but then you get issues with binary compatibility, specially if your linking toi native code
23:46 ruoso so, let's not make the jump to binary packages yet
23:46 dduncan eg, in a Perl 6 module distro, you could distribute both Perl 6 source, the canonical thing, and also parrot bytecode for convenience, or versions of the Perl 6 compiled to other things
23:46 dduncan sure
23:47 dduncan in the case with my Muldis D language though, the language is bootstrapped, but I'm initially bootstrapping with Perl 5 or Perl 6 or something else, so I'd have to bundle a version in the latter form for anyone to be able to run my language
23:48 dduncan that's what I was getting at for middle ground
23:48 ruoso well, you need two phase-build
23:48 dduncan well for that matter its like building the Perl 6 STD.pm and compiling Perl 6 wit hthat
23:48 dduncan or Perl 6 standard libs
23:49 ruoso sure, you need to compile the compiler somehow
23:49 dduncan I am doing the analogy in my language, as the canonical version of my language libs and compiler are written in my language
23:49 dduncan anyway, that's more FYI, I don't need to discuss it
23:50 dduncan its mainly relevant in that I"m largely emulating the Perl 6 ecosystem with Muldis D, so what's good for one may be good for the other

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

Perl 6 | Reference Documentation | Rakudo