Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2012-09-12

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 TimToady what we really need is smart tabs that know how to line up with the longest non-tab thing
00:01 TimToady then we could just use proportional fonts all over the place and still make code line up nicely
00:01 sorear i.e. lhs2TeX
00:01 timotimo have you ever tried that out as a prototype?
00:02 timotimo just to see if propertional fonts in code do look viable if done right? (i.e. you'd do it right manually and come up with technology to do it right automatically afterwards)
00:03 TimToady the main problem with it is that it has to be work both forwards and backwards from the longest bit
00:04 TimToady so youre really doing layout on multiple lines in parallel, left to right
00:04 TimToady *
00:04 TimToady *'
00:05 TimToady this implies some kind of smart text container that limits the effect of this to a set of lines
00:06 TimToady kinda like TeX does whole-paragraph hypthenation optimization
00:09 sorear TimToady: this is a solved problem, lhs2TeX does it but is somewhat Haskell-specific
00:09 TimToady not to mention TeX specific
00:31 mikemol TimToady: If you guys can find a suitable fixed-width font, I can specify it in the RC CSS load.
00:32 * mikemol &
00:35 ggoebel__ joined #perl6
00:36 kst joined #perl6
00:57 perigrin joined #perl6
01:04 scott_ joined #perl6
01:07 woosley left #perl6
01:09 MikeFair_ good evening all! :)
01:11 TimToady timotimo: actually, it looks from the ir clogs that the copypaste worked fine on input (see http://irclog.perlgeek.de/​perl6/2012-09-11#i_5979839), but our irc clients didn't cope on output
01:13 TimToady or possible screen didn't copy with Plane 1 chars
01:13 TimToady *cope
01:14 hypolin joined #perl6
01:14 benabik It showed up basically correct for me (piles of whitespace above/below), although I'm using a OS X program instead of something terminal based.
01:15 helecho joined #perl6
01:31 sorear screen is BMP only, yah
01:31 sorear someday I'm going to replace irssi+screen with something better
01:31 sorear but first I'd have to find a new server
01:32 sorear the one that diakopter++ has been graciously letting me use is a little limited
01:32 shachaf Oh, *screen* is the reason my IRC client can't handle non-BMP characters?
01:32 * shachaf sighs.
01:32 sorear it doesn't even have tmux :(
01:32 shachaf I guess this is a reason to use tmux.
01:33 sorear what, you've been resisting tmux?
01:33 * sorear sics doy on shachaf
01:33 * sorear ducks
01:33 shachaf I tried it once and didn't like something about it, and screen was working fine.
01:36 tokuhiro_ joined #perl6
01:37 * geekosaur has been trying to switch himself over from screen to tmux
02:01 hypolin joined #perl6
02:11 OuLouFu joined #perl6
02:32 geekosaur joined #perl6
02:39 benabik joined #perl6
03:00 ggoebel joined #perl6
03:26 BlueT_ joined #perl6
03:33 BlueT_ joined #perl6
03:43 BlueT_ joined #perl6
04:04 scott_ joined #perl6
04:08 gootle joined #perl6
04:32 jaldhar_ joined #perl6
04:32 cognominal joined #perl6
04:43 kaleem joined #perl6
04:49 ggoebel joined #perl6
05:02 kaleem joined #perl6
05:38 moritz good morning
05:41 hypolin joined #perl6
05:42 sorear o/ moritz
05:49 fhelmberger joined #perl6
06:04 fgomez joined #perl6
06:05 wtw_ joined #perl6
06:13 cognominal joined #perl6
06:16 ggoebel joined #perl6
06:18 stepnem joined #perl6
06:25 s1n joined #perl6
06:38 erkan joined #perl6
06:40 ggoebel joined #perl6
06:44 cognominal joined #perl6
06:45 wamba joined #perl6
06:52 marmay joined #perl6
07:06 brrt joined #perl6
07:06 dalek specs: 22f12ce | (Felix Herrmann)++ | S32-setting-library/Containers.pod:
07:06 dalek specs: [S32::Containers] fix minor typo
07:06 dalek specs: review: https://github.com/perl6/specs/commit/22f12ce2da
07:10 spider-mario joined #perl6
07:12 ggoebel joined #perl6
07:23 tadzik good day #perl6
07:25 FROGGS__ joined #perl6
07:26 FROGGS joined #perl6
07:28 moritz \o tadzik
07:45 DfA joined #perl6
07:53 xinming joined #perl6
08:06 kaleem joined #perl6
08:07 kaleem_ joined #perl6
08:10 FROGGS good morning
08:11 tadzik hello FROGGS
08:11 tadzik how is the bubble game coming along? :)
08:16 FROGGS well, I can draw text now too, but I didnt committed the changes yet
08:16 FROGGS my hacks that I did to unpack C-struct are right now just working on 64bit machines
08:16 sorear o/ #perl6
08:16 tadzik oh, I see
08:17 FROGGS don't know If its good to add such a module to modules.perl.org :/
08:17 tadzik hello sorear
08:17 FROGGS hi sorear
08:17 sorear FROGGS: there is some absolutely horrid stuff on CPAN5
08:17 tadzik well, I just want to shout "GUYS GUYS WE HAVE AN SDL GAME RUNNING SMOOTHLY ON RAKUDO" sooner or later :)
08:17 FROGGS ya, the current SDL module (pure pir) isnt that good too
08:20 Psyche^ joined #perl6
08:20 sorear heh heh heh heh heh.
08:20 FROGGS tadzik: let me prepare a commit...
08:23 kresike joined #perl6
08:23 kresike good morning all you happy perl6 people
08:24 tadzik hello kresike
08:25 kresike hello tadzik o/
08:25 FROGGS hi kresike
08:26 kresike hello FROGGS o/
08:39 dakkar joined #perl6
08:47 cognominal joined #perl6
08:51 FROGGS how do I get the dirname from $?FILE ?
08:51 sorear n: say $?FILE
08:51 p6eval niecza v21-1-ga8aa70b: OUTPUT«/tmp/kddimH9zGR␤»
08:51 tadzik r: say $?FILE.WHAT; say $?FILE.perl
08:51 p6eval rakudo d1f4dc: OUTPUT«Str()␤"/tmp/3Djo0Fy79G"␤»
08:52 moritz r: say IO::Path.new($?FILE).directory
08:52 p6eval rakudo d1f4dc: OUTPUT«Could not find symbol '&Path'␤  in method <anon> at src/gen/CORE.setting:9836␤  in  at src/gen/Metamodel.pm:2317␤  in any find_method_fallback at src/gen/Metamodel.pm:2305␤  in any find_method at src/gen/Metamodel.pm:859␤  in  at src/gen/BOOTSTRAP.pm:826␤  in any  …
08:52 moritz oh, that doesn't work on evalbot
08:52 moritz because we remove all IO classes
08:52 cognominal needs a mockup :)
08:53 sorear n: say $?FILE.IO.combine('.')
08:53 p6eval niecza v21-1-ga8aa70b: OUTPUT«".".IO␤»
08:53 sorear n: say $?FILE.IO.append('.')
08:53 p6eval niecza v21-1-ga8aa70b: OUTPUT«"/tmp/3R8YNow58T/.".IO␤»
08:53 cognominal forgot the variable name for rakudo configuration :(
08:53 FROGGS cool, IO::Path.new($?FILE).directory works
08:53 sorear n: BEGIN say $?FILE.IO.slurp
08:53 p6eval niecza v21-1-ga8aa70b: OUTPUT«Unhandled exception: slurp may not be used in safe mode␤  at /home/p6eval/niecza/lib/CORE.setting line 1673 (List.gist @ 5) ␤  at <unknown> line 0 (ExitRunloop @ 0) ␤  at /tmp/oaNyR6WyTu line 1 (ANON @ 3) ␤  at <unknown> line 0 (ExitRunloop @ 0) ␤  at /home…
08:53 FROGGS thanks moritz
08:54 sorear oh, huh, I fixed that
08:54 sorear n: say $?ORIG # well this works at least (?)
08:54 p6eval niecza v21-1-ga8aa70b: OUTPUT«say $?ORIG # well this works at least (?)␤»
08:54 tadzik ...huh?
08:54 FROGGS hehe
08:56 sorear tadzik: $?ORIG is a bug and/or undocumented feature of STD that I implemented in Niecza because I thought it would be funny
08:56 sorear maaaaany versions ago
08:57 rhr joined #perl6
08:59 tadzik :)
09:15 scott_ joined #perl6
09:24 wamba joined #perl6
09:29 masak good antenoon, #perl6
09:32 masak today: Perl 6 day.
09:32 masak I have some errands to run first, though.
09:38 sorear o/ masak
09:38 kresike hello masak o/
09:40 tadzik \o masak
09:42 masak "sigilless style" looks to me like a committee was 50%-50% on whether sigils are a good idea, so they compromised and put both variants into the language.
09:51 scott__ joined #perl6
09:54 FROGGS hi masak
09:55 FROGGS does somebody know why $dir is Mu?
09:55 FROGGS https://gist.github.com/3705646
09:56 FROGGS arnsholt: ping?
09:58 sorear masak: TimToady has a committee of split personalities.
09:58 sorear FROGGS: traits like "is native" run at BEGIN time, before normal code
09:58 sorear FROGGS: you should be able to make that work if you wrap the assignments in a BEGIN block
09:59 sorear our $dir; BEGIN { $dir = 'abc' }
09:59 sorear BEGIN our $dir = 'abc'; # shorter, note absense of braces
10:00 FROGGS cool, will try
10:01 FROGGS rn: BEGIN our $dir = 'abc';
10:01 p6eval niecza v21-1-ga8aa70b:  ( no output )
10:01 p6eval ..rakudo d1f4dc: OUTPUT«===SORRY!===␤Cannot assign to a non-container␤»
10:01 FROGGS okay, braces ;o)
10:01 FROGGS rn: our $dir; BEGIN { $dir = 'abc' }
10:01 p6eval niecza v21-1-ga8aa70b:  ( no output )
10:01 p6eval ..rakudo d1f4dc: OUTPUT«===SORRY!===␤Cannot assign to a non-container␤»
10:02 FROGGS ó.ò
10:02 scott__ joined #perl6
10:03 FROGGS rn: BEGIN { our $dir = 'abc' }; say $dir
10:03 p6eval rakudo d1f4dc: OUTPUT«===SORRY!===␤Variable $dir is not declared␤at /tmp/M2cTBTkz95:1␤»
10:03 p6eval ..niecza v21-1-ga8aa70b: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤Variable $dir is not predeclared at /tmp/F2tWyKQlwY line 1:â�¤------> [32mBEGIN { our $dir = 'abc' }; say [33mâ��[31m$dir[0mâ�¤â�¤Unhandled exception: Check failedâ�¤â�¤  at /home/p6eval/niecza/boot/lib/CORE.setting line 1435 (die @ …
10:03 FROGGS I'm lost
10:05 sorear FROGGS: try using my instead.
10:05 sorear rn: BEGIN my $dir = 'abc'
10:05 wamba joined #perl6
10:05 p6eval niecza v21-1-ga8aa70b: OUTPUT«Potential difficulties:â�¤  $dir is declared but not used at /tmp/Hh44Alpo7U line 1:â�¤------> [32mBEGIN my [33mâ��[31m$dir = 'abc'[0mâ�¤â�¤Â»
10:05 p6eval ..rakudo d1f4dc:  ( no output )
10:05 FROGGS ohh, cool
10:05 sorear looks like both compilers have no propblemw ith that
10:05 sorear basically any time you're tempted to use our, think again
10:05 cognominal r:  say $_ for Method.^methods
10:05 p6eval rakudo d1f4dc: OUTPUT«gist␤Unmarshallable foreign language value passed for parameter '$_'␤  in block  at /tmp/10nLLXmzmG:1␤␤»
10:06 FROGGS ya, it's working
10:06 FROGGS sorear++
10:06 sorear sleep&
10:06 cognominal not sure if I already pasted this one
10:06 FROGGS gnight
10:06 cognominal r:  say  Method.^methods
10:06 p6eval rakudo d1f4dc: OUTPUT«No such method 'gist' for invocant of type 'Sub'␤  in method gist at src/gen/CORE.setting:4748␤  in sub say at src/gen/CORE.setting:7161␤  in block  at /tmp/wy8Luujuns:1␤␤»
10:07 cognominal probably same cause but different error messages
10:07 FROGGS r: say Method.^methods.WHAT
10:07 p6eval rakudo d1f4dc: OUTPUT«Parcel()␤»
10:09 cognominal I like introspection as a way to learn the language but it is still has some rough edge in rakudo
10:09 cognominal got a long way this last few months though
10:09 snarkyboojum joined #perl6
10:10 masak agreed.
10:10 masak feel free to submit the above two things as rakudobugs.
10:10 masak &
10:11 snarkyboojum joined #perl6
10:16 kaleem joined #perl6
10:20 snarkyboojum joined #perl6
10:22 ggoebel joined #perl6
10:41 snearch joined #perl6
10:54 wk joined #perl6
11:05 Su-Shee_ joined #perl6
11:23 daxim joined #perl6
11:24 mucker joined #perl6
11:48 baest_ joined #perl6
12:10 cognominal joined #perl6
12:10 dalek ecosystem: 650642f | (Tobias Leich)++ | META.list:
12:10 dalek ecosystem: added Games::BubbleBreaker
12:10 dalek ecosystem: review: https://github.com/perl6/e​cosystem/commit/650642f816
12:11 FROGGS tadzik^^
12:11 tadzik \o/
12:11 tadzik now I can shout
12:11 FROGGS I'll hope that it will install fine
12:11 tadzik I'll check at $home, probably
12:12 FROGGS because I have a .c file in SDL/lib
12:12 FROGGS dont know if that will work
12:13 Celelibi joined #perl6
12:13 FROGGS huh: resolve stage failed for Games::BubbleBreaker: Project Games::BubbleBreaker not found in the ecosystem
12:14 FROGGS panda said that^^
12:16 cognominal joined #perl6
12:18 tadzik hold on
12:18 tadzik I'll bump the modules API
12:19 tadzik it usually runs hourly
12:22 FROGGS ahh, k, good to know
12:22 FROGGS cron++
12:23 cognominal joined #perl6
12:24 tadzik FROGGS: ok, panda update now and it should work
12:26 wk_ joined #perl6
12:31 cognominal joined #perl6
12:35 FROGGS tadzik: it still can't find it
12:36 FROGGS do I have to update my pando cache somehow?
12:37 FROGGS ohh, there is panda update
12:37 FROGGS fetching now!
12:37 fhelmberger joined #perl6
12:38 yarp joined #perl6
12:38 yarp joined #perl6
12:42 PacoAir joined #perl6
12:42 yarp say "good morning";
12:43 moritz r: say 'oh hai yarp'
12:43 p6eval rakudo d1f4dc: OUTPUT«oh hai yarp␤»
12:43 yarp r:say "good morning"
12:44 PacoAir joined #perl6
12:44 FROGGS tadzik: so far, so good; but my .c file doesn't get installed
12:44 FROGGS time for Inline::C, isnt it?
12:45 FROGGS and I need to fix my tests
12:45 [particle]1 joined #perl6
12:46 [Coke] I have a friend with a 12 year old who wants to program video games, and would love to able to point him at perl6 & sdl. I pointed him at karthik for now.
12:46 FROGGS kartik is pretty busy
12:46 FROGGS I'd love to help
12:47 FROGGS there's a project called Avanger that might be of interest
12:47 FROGGS https://github.com/PerlGameDev/Avenger
12:48 FROGGS we might do something like this for perl6 too, but this will take time
12:48 FROGGS and kartik has no time to do perl6 stuff atm, I'm the only one who cares
12:48 Su-Shee me idiot would use something common which most people use for game development, but hey, that's just me. ;)
12:49 FROGGS libSDL is common for game developement
12:49 nuba joined #perl6
12:49 pochi joined #perl6
12:49 Su-Shee maybe, but definetely not with Perl.
12:49 FROGGS right
12:51 yarp but curent rakudo is very slow
12:53 FROGGS ya, you just can make smaller games atm
12:53 [Coke] FROGGS: well, not at him personally, but his online trail of p5 SDL games.
12:53 [Coke] Su-Shee: also: I don't write games, so I had nothing to offer except "I know this one guy..."
12:54 [Coke] now, if the youngun was interested in the glamorous world of custom corporate tax software for multinationals...
12:55 [Coke] ... man, what the hell happened to my dreams of writing video games. Crap.
12:56 perigrin_ joined #perl6
12:56 tadzik same here
12:56 tadzik I wanted to become a programmer because of games
12:57 p6eval joined #perl6
12:57 FROGGS almost true for me
12:58 crab2313 joined #perl6
13:02 moritz I never wanted to become a programmer, I just became one ;-)
13:02 sorear I used to be a game programmer, then realized I had absolutely no interest in it
13:02 FROGGS what are you doing here then?
13:03 moritz not programming games :-)
13:04 FROGGS I meant sorear, but actually I didn't read "game"
13:07 dayangkun joined #perl6
13:10 JimmyZ joined #perl6
13:14 * masak is back
13:14 masak game programming has always been a big part of why I program.
13:15 masak there's something about games, even very simple ones, that makes programming them fun.
13:16 masak today is apparently http://en.wikipedia.org/wiki/Programmers'_Day
13:16 * moritz finds most games to be too much effort or too complex to program, because he's lazy :-)
13:17 masak wow! which is apparently an officially recognized holiday in Russia!
13:19 * __sri is waiting for the book Game Programming with Perl6
13:20 masak heh :)
13:24 * moritz waits for "Programming Paradigms with Perl 6"
13:31 masak the book idea by Gloria? I got the feeling that would be a Perl 5 book... but thinking back, I don't think either 5 or 6 was mentioned explicitly in the discussion.
13:32 fgomez joined #perl6
13:33 M_o_C joined #perl6
13:35 [Coke] so make it "with perl" and do it both ways.
13:35 skids joined #perl6
13:36 moritz masak: I think Gloria meant it as a killer app for Perl 6, and then the 5ers noticed that it'd work fine for Perl 5 too :-)
13:36 sorear masak: they'll have fun writing about data parallel in 5 :D
13:36 * JimmyZ is always waiting for a faster rakudo
13:37 [Coke] moritz++
13:37 [Coke] JimmyZ: don't wait. profile it today and tell us what's slow.
13:37 masak sorear: heh.
13:37 masak moritz: oh, yes. that was probably it.
13:37 benabik joined #perl6
13:37 JimmyZ [Coke]: PCC ?
13:38 [Coke] JimmyZ: That's an excellent guess. Can you verify? suggest ways to make it go faster?
13:39 sorear [Coke]: jnthn told me quite directly at yapc::eu that PCC was one of the problems
13:39 yarp joined #perl6
13:39 JimmyZ [Coke]: yes, I can, just compare fib.pir and fib.pl.
13:40 JimmyZ which fib.pir is almost 50 times slower
13:40 JimmyZ IIRC
13:40 tadzik ....wow, it is?
13:40 bluescreen10 joined #perl6
13:40 JimmyZ IIRC, not sure now
13:41 * [Coke] misses chromatic.
13:41 JimmyZ m0's PCC is also a pain
13:41 [Coke] Do we have any C developers in here that could see if that could be improved?
13:43 nine_ joined #perl6
13:43 nine_ left #perl6
13:44 sorear [Coke]: I get the feeling you've missed a large part of the profile that's been done lately on rakudo
13:44 * [Coke] adds that to his list of things to try out as time permits.
13:44 * [Coke] almost forgot about the rosettacode test, though. hurm.
13:44 [Coke] sorear: very likely. is it published?
13:45 [Coke] i.e somewhere other than backscroll?
13:47 sorear masak: do you know if jnthn et al published this?
13:49 masak published what?
13:49 masak a profile?
13:49 masak I think pmichaud is the one to talk to.
13:50 JimmyZ I'm wrong, about 3 times slow. I think 50 times was m0
13:50 tokuhiro_ joined #perl6
13:51 thou joined #perl6
13:51 kenjiskywalker joined #perl6
13:52 stopbit joined #perl6
13:53 Moukeddar joined #perl6
13:55 JimmyZ and the other thing it that PMC is expensive, confirmed by bacek++ and rakudo
13:56 moritz it's expensive that we create PMC per call
13:56 JimmyZ using PMC type is also expensive
13:57 wamba joined #perl6
13:57 skids tadzik: https://github.com/skids/perl6sum # should be usable enough for modules.perl6.org now.
13:58 leprevost joined #perl6
13:58 tadzik skids: t/ should be top-level
13:58 tadzik also, did you read http://wiki.perl6.org/Create%​20and%20Distribute%20Modules ?
13:59 skids nope, but I will.
14:01 [Coke] JimmyZ: what's the alternative?
14:01 [Coke] (to using PMCs)
14:01 [Coke] "use less of them" is good advice.
14:02 FROGGS__ joined #perl6
14:02 JimmyZ [Coke]: use int/str/num if possible
14:02 skids tadzik: OK, I'll work on that later.  Thanks tadzik++
14:02 [Coke] I know in partcl, I pretty much couldn't NOT use PMCs without doing a lot of work at compile time to try to use natives. (I think nqp actually DOES a lot of that work now.)
14:03 [Coke] JimmyZ: yah, it's hard to do that.
14:03 JimmyZ or use 6model?
14:04 moritz 6model objects are also PMCs
14:04 moritz what 6model does is avoiding lots of extra PMCs
14:04 JimmyZ so what's why bacek++ said porint parrot to 6model?
14:04 moritz (like for attributes)
14:05 JimmyZ porting
14:05 moritz well, then we wouldn't have to use PMCs for 6model objects anymore
14:05 moritz thing is, we want our objects to be collected by the GC eventually
14:05 Moukeddar joined #perl6
14:05 moritz and currently the GC looks at strings and PMCs
14:06 moritz so, every user-facing object must be a PMC
14:06 moritz (same for passing stuff around)
14:06 sorear .oO( 6model objects backed by STRINGs )
14:06 [Coke] sorear: this ain't tcl.
14:06 [Coke] ... well, partcl is tcl. nevermind.
14:07 moritz sorear: parrot strings are immutable-ish, so that would not be much fun :-)
14:09 sorear not fun?  PURE FUN!
14:09 JimmyZ someone said lorito is bad, but I think lorito will be good if it's designed well, at least it's easy to jit
14:10 JimmyZ jitting parrot's ops or dynops by using libjit is almost impossible
14:13 FROGGS joined #perl6
14:20 brrt jitting parrot is  nearly impossible period
14:20 brrt or
14:20 brrt jitting parrot and getting something more efficient than inteprretation is nearly impossible
14:23 moritz well, parrot has decided long ago to provide rather high-level ops
14:23 moritz and that's a problem for JITting
14:23 moritz so, one must revise this decision (that's what lorito/m0 plan to do)
14:24 moritz and then suddenly the performance characteristics change drastically, and you have to rethink everything
14:24 moritz so, you'll end up a with big (nearly complete) rewrite
14:24 moritz at least that's my mental image of the process
14:24 masak mine too.
14:25 masak lorito/m0 as a big step to reversing some of the "hasty" decisions back in 2003.
14:25 atrodo It'd be very difficult to prevent lorito/m0 from becoming a complete rewrite
14:25 masak essentially giving Parrot a new Parrot.
14:25 GlitchMr joined #perl6
14:27 sorear what I've seen of lorito makes me think it will kill performance for everything except the jit
14:27 * JimmyZ wonders why sorear hates the lorito design
14:27 * JimmyZ doesn't think so
14:28 JimmyZ lorito makes things smaller and smarter
14:28 JimmyZ and jit is always the killer feature
14:29 sorear but these days I try to avoid talking too much about parrot
14:29 * JimmyZ too
14:29 sorear just ignore it, hope it gets better, and try not to say too many things that might disturb people
14:34 atrodo I did some initial looking at porting parrot and pir and everything to a lorito prototype, and it'd be a huge amount of work.  I've come to the conclusion that porting parrot's users to a new platform would be easier
14:35 brrt the thing about lorito, the thing about m0 what i'm most worried about
14:35 brrt is that it provides /no/ high-level features
14:35 brrt at all
14:35 kaare__ joined #perl6
14:35 brrt whatsoever
14:36 brrt which means, that calling-a-function is not defined by the vm
14:36 brrt which means that different langauges will use differently optimised calling conventions
14:36 benabik M0 is supposed to be the low level the high level is implemented in.  External users should not see it unless they're trying to extend the VM.
14:36 [Coke] so, more like old school assembly.
14:36 masak I think various performance shortcomings of Parrot might be forgiven/ignored if the original vision of Parrot had been realized -- to be a common platform for dynamic languages.
14:36 brrt very much like old school assembly
14:37 atrodo I for one am not a fan of that direction of m0
14:37 brrt my point is one and only
14:38 brrt how are you going to assure interoperability with such low-level operations
14:39 benabik Interop is always going to be a matter of convention.
14:39 GlitchMr .u 
14:39 phenny U+F8E5 (No name found)
14:39 brrt old parrot made interop the high goal
14:39 brrt which is why there is the vtable interface
14:39 leont joined #perl6
14:39 brrt which works!
14:39 brrt everything is abstract
14:39 brrt at the painful cost of interpretation speed
14:39 atrodo you hope and pray everyone follows a singluar ABI
14:39 tadzik except that there was only one person caring about HLL interop
14:40 tadzik which then got discouraged because nobody else cared
14:40 benabik I would suggest that if you all care about this, you join #parrot and/or #parrotsketch and _help us_.
14:40 c1sung joined #perl6
14:40 * brrt thinks that if you specify high-level constructs simply enough
14:40 brrt you will get interoperability
14:40 benabik "simple high-level"?
14:40 JimmyZ porting parrot's users to a new platform? I'm not a fan of jvm and C# ;)
14:40 [Coke] tadzik: While I sympathize with your pain, there was more than one person who cared.
14:40 brrt yep
14:41 tadzik [Coke]: true. s/cared/worked on the code/ I guess
14:41 JimmyZ I don't care about HLL interop if it's slow
14:41 * leont isn't a fan of the jvm or clr either
14:42 moritz benabik: I do care about parrot, but with my limited tuit supply I know I won't do much more than talking
14:42 [Coke] tadzik: I tried to provide an HLL for folks to interop with. ;)
14:42 brrt you can specify say, lambda as: create a buffer, put the contents of register $2 into the first word, register $3 into the second, the first is the code ref, the second is the 'stack' ref
14:42 tadzik [Coke]: well, I'm just
14:42 tadzik parroting
14:42 tadzik Tene's words
14:42 tadzik (pun indented)
14:43 benabik moritz: This conversation comes up from time to time.  "Why doesn't Parrot do ___?"  My answer right now is "The two developers working on it don't have time for everything, so go help.".  Maybe if I remind people how OSS works, we'll get some help.  It doesn't have to be you.
14:43 brrt if you do that, then everybody writing a compiler can just say 'lambda $reg, $code, $stack'
14:43 brrt which can then be used with a call $lambda, $stack, $continuation
14:43 moritz benabik: I do pretty much the same for rakudo
14:43 brrt those are relatively high-level constructs
14:43 benabik brrt: Welcome to designing M0.
14:43 [Coke] benabik: I think we all know how OSS works.
14:44 brrt benabik: I've been thinking about m0 a /lot/ by now
14:44 brrt i think you need /some/ high level constructs
14:44 moritz benabik: I just think it's a dangerous attitude, because it makes it easy to become defensive
14:44 brrt to do the things that langauges must share
14:44 benabik M0 is supposed to have continuations and objects.
14:44 JimmyZ I had been looking forward to gerdr's new M0 implementation :)
14:44 [Coke] benabik: and many of us here have/do contribute to parrot. I myself don't work in C, which makes it difficult to actually help out with core issues.
14:45 atrodo I think lorito needs two things: Things and a way to call functions on things
14:45 leont benabik: that sounds like perl 5 (re "Why doesn't Parrot do ___?")
14:45 benabik Gah!
14:45 JimmyZ gerdr++'s
14:45 benabik I'm not trying to be defensive!  I just want help!
14:45 moritz I know, I know
14:45 sorear leont: I think there may be more than two people working on perl 5
14:45 * sorear hugs benabik
14:46 tadzik brrt: wasn't that m1's thing?
14:46 leont sorear: yeah, but still it's about 4 people doing 80% of the work
14:46 leont (if not more than 80%)
14:46 brrt tadzik: what I worry about is that somebody is then going to compile to m0, bypassing m1, and saying 'it runs on parrot'
14:46 brrt which is true
14:46 brrt but not the point
14:46 sorear who are the current four, ooc?
14:46 moritz leont: I guess that's the dynamic of nearly all open source projects
14:47 brrt because you could not then possibly interoperate
14:47 benabik brrt: Parrot shouldn't accept raw M0 as a program.
14:47 leont Nicholas, DaveM, Father C and the release manager of the month, I'd say
14:47 sorear leont: are you the same leon t from the PRS?
14:47 brrt benabik: then you cannot compile to m0 bytecode and ship it
14:47 leont sorear: yeah
14:47 * brrt should have been at yapc
14:47 masak sorear: hm... whiteknight, bacek, cotto, and *mumble*?
14:47 [Coke] masak: wrong project. ;)
14:48 masak oh!
14:48 benabik masak: rurban at the moment, and bacek and cotto haven't been seen much of late.
14:48 * leont forgot Karl on that list
14:48 [Coke] leont: 2 of those are subsidized, aye?
14:48 leont Yeah
14:48 benabik brrt: Yup.  Don't do that.  You compile to PBC (or its replacement) + M0 ops.  The PBC specifies how to compose the M0.
14:48 brrt then m0 is the 'invisible intermediate layer'
14:48 brrt in which case
14:49 atrodo then there's no point to m0
14:49 brrt get rid of it as a specification, and implement it as a /explicit/ intermediate layer
14:49 brrt much like v8 does
14:50 benabik brrt: But more to the point, it's possible to break interop using HLL ops.  Interop between raw parrot and Rakudo is non-trivial for example.
14:51 sirrobert joined #perl6
14:52 brrt benabik: that is very true, and very much a problem
14:52 brrt and it Should Not Be That Way :-)
14:52 * JimmyZ heard that m0b will replace pbc
14:52 benabik HLL interop is matter of providing tools good enough to use and having languages use them.
14:52 benabik No matter what level you implement what in.
14:53 atrodo I've heard a lot of things, and most of it contradicts everything else.  m0 is in design hell
14:53 brrt benabik: then we should define those tools
14:53 moritz that has been tried
14:53 atrodo No matter what tools you provide, some langauges will want/need to use their own
14:55 moritz currently I think the only real approach to m0 and HLL interop is having a hacker who does most of the work (including design) on his own
14:55 moritz that's basically the only way to escape the "designed to death" trap
14:56 atrodo moritz: If I had the tuits, I would actually do exactly that.
14:56 moritz atrodo: yes, that's the common catch
14:56 benabik If I can find a way to make a reasonable thesis of it, I might do it.  :-D
14:57 moritz benabik: "I purposefully the whole parrot" :-)
14:57 benabik moritz: Yeah.
14:57 benabik moritz: But a few years paid to work on it can do a lot.
14:57 benabik But I need to: claw &
14:58 benabik Uhm.  class &
14:58 JimmyZ So the final problem is that Parrot Foundation has no sponsor ;)
14:59 moritz I'm not sure
14:59 sorear to be fair TPF is not exactly drowning in cash either
15:00 moritz so far I haven't heard any of the parrot core hackers say "I would want to work on parrot full time. Can we find the cash to do it?"
15:00 leont sorear: TPF has quite a bit of cash in the Perl5 maintenance fund, but not much anywhere else
15:01 tadzik and for Hague Perl 6 grants, I think
15:01 moritz well, then there's the part of the Hague grant for improving the TPF infrastructure
15:01 moritz that's what, 50k? 100k?
15:01 tadzik that too
15:01 leont The Hague Perl 6 grant is almost done
15:01 moritz (USD)
15:01 leont AFAIK
15:01 moritz leont: I don't think so
15:01 brrt JimmyZ: its one problem
15:01 leont I could be wrong, Karen gave all the details at YAPC::{NA,EU}, but my memory is limited
15:01 moritz leont: the last thing I've heard was that there was about half of the technical funds left, and nearly all of the infrastructural
15:02 jaldhar_ joined #perl6
15:02 leont Yeah, I can see how infrastructural money is harder to spend
15:02 moritz well, there were two applications
15:03 moritz one was withdrawn, iirc
15:03 moritz but the way TPF responded to szabgab's proposal was to never decide
15:03 moritz which made me sad
15:03 leont Well, that's a general TPF issue
15:03 leont s/TPF/OSS/
15:04 moritz because I think gabor is quite capable of this sort of stuff, but TPF folks were afraid of change (?)
15:04 JimmyZ What's szabgab's proposal?
15:04 wamba joined #perl6
15:05 moritz JimmyZ: basically to get paid to persuade companies to sponsor Perl development
15:05 JimmyZ oh
15:05 moritz http://news.perlfoundation.org/2010/0​6/hague-grant-application-perl-e.html
15:06 JimmyZ I heard it
15:06 cognominal joined #perl6
15:06 JimmyZ I thought it was accepted
15:07 moritz JimmyZ: I'm pretty sure it wasn't
15:07 moritz JimmyZ: I've never seen any decision either way on the TPF blog
15:08 moritz and I'm pretty sure I talked to Gabor about it
15:08 JimmyZ that's sad
15:09 kresike bye folks
15:12 sirrobert off topic:  moritz, do you use postgresql-9.2?
15:12 moritz sirrobert: not yet
15:13 moritz but in time, i will
15:13 masak I think Grammar::Debugger currently falls victim to this bug: https://rt.perl.org/rt3/Tic​ket/Display.html?id=114836
15:13 sirrobert do you know of a good resource for getting started?  (as in, I'm at the "for the love of God, how can it be so hard to get this running?" point... why won't psql just work?
15:13 masak at least that's what a cursory analysis gives.
15:13 moritz masak: wasn't it you who wrote the QAST transformer for those loops? :-)
15:14 sirrobert moritz: the package installs fine, everything seems ok, but the docs don't say anything about how to set up accounts for psql... they assume you can use it already.
15:14 masak r: my $x; repeat { $x = 5 } while $x
15:14 p6eval rakudo d1f4dc: OUTPUT«Cannot assign into a PMCNULL container␤  in block  at /tmp/xCPedXstBW:1␤␤»
15:14 moritz sirrobert: on debian, I do  su - postgres
15:14 masak moritz: I've certainly been in and around that area, yes. good memory.
15:14 masak moritz: don't know if I'm the ultimate cause of the bug. in some sense, it doesn't matter.
15:15 moritz sirrobert: and then use the 'createuser' command line too
15:15 sirrobert moritz: ok... just cleaned it out and am re-installing.  will try
15:15 masak moritz: maybe my knowledge of the code will help be track it down, though.
15:15 * masak tries
15:15 moritz masak: note that the error occurs in the assignment, but only if the variable also mentioned in the 'while' block
15:15 arnsholt sirrobert: It usually provides a program called createuser as well
15:15 masak aye, I noticed.
15:15 moritz r: my $x; repeat { $x = 5 } while False
15:15 p6eval rakudo d1f4dc:  ( no output )
15:15 moritz r: my $x; repeat { $x = 5 } while $x
15:15 masak moritz: which makes it seem to be a lexical kind of thing.
15:15 p6eval rakudo d1f4dc: OUTPUT«Cannot assign into a PMCNULL container␤  in block  at /tmp/4mIyaLbwXP:1␤␤»
15:15 arnsholt (But that's mostly a wrapper around SQL stuff)
15:16 masak moritz: I think the error would stand out quite plainly if there was a way to inspect the resulting QAST...
15:16 masak er, the resulting intermediate code, I mean.
15:16 moritz aye. As the appropriate system user, you should be able to use 'createdb', 'createuser', 'createrole' and 'psql' commands
15:16 moritz masak: I've missed such a facility while hacking on the sink context thingy :/
15:18 cognominal joined #perl6
15:18 moritz I've located the codegen in nqp/src/QAST/Operations.nqp
15:18 moritz and then stared at it for a while
15:18 moritz and then shook my head
15:19 moritz in particular I don't see how it relates to scopes at all
15:20 moritz and why 'while' is not affected
15:20 masak yes, the codegen is in that file.
15:21 * masak stares at it for a while, too
15:22 * moritz also stares at the generated pir
15:22 moritz the difference between a while-loop (working) and the repeat { } while (failing) is minimal
15:22 moritz r: my $x; while $x { $x = False }
15:23 p6eval rakudo d1f4dc:  ( no output )
15:23 moritz oh, maybe I have found it
15:24 masak oh?
15:25 moritz http://moritz.faui2k3.org/tmp/repeat-while.diff
15:25 moritz null $P108
15:25 moritz goto while12_redo16
15:25 moritz is the main difference
15:25 moritz I suspect that the 'null' is what gives us the NPMCA
15:26 masak sounds reasonable.
15:27 masak this line: https://github.com/perl6/nqp/blob/m​aster/src/QAST/Operations.nqp#L573
15:27 moritz and the way registered are nulled has to with Stmt vs. Stmts, no?
15:27 masak no idea.
15:27 moritz oh, an explicit null
15:27 moritz let's try to remove that
15:27 masak so... we null $x, and then immediately try to assign to it in the loop body?
15:27 masak yeah, I can see how that may not end up so well.
15:33 masak here's the commit that added that line: https://github.com/perl6/nqp/commit/3c​9b25fd57242c575480b285b2046a220d17fed9
15:34 GlitchMr Because git blame is useful :)
15:38 * masak reads https://en.wikipedia.org/wiki/Con​tinuation-passing_style#Examples and finds a deep similarity between CPS and Haskell's monads
15:38 sorear masak: CPS is the free monad.
15:38 MayDaniel joined #perl6
15:40 masak I have no idea what that means, but I'm glad there is an actual similarity, and not just my imagination.
15:41 sorear https://en.wikipedia.org/wiki/Free_object
15:42 sorear might be best to start with "Examples"
15:43 masak ok.
15:43 moritz masak: oh, your imagination is just a multidimensional manifold on the vector spece of endofuctors, or so :-)
15:43 masak also, commutative diagrams look like abstract art to me. https://upload.wikimedia.org/wikipe​dia/commons/b/b1/YonedaLemma-02.png
15:44 masak maybe I should tattoo a commutative diagram on my upper arm, and then category theorists can giggle behind my back about what it really means.
15:44 sorear a free object is the most generic possible object of a sort.
15:45 sorear CPS is a monad, Haskell calls it Cont
15:46 sorear most monads have properties, like in the IO monad, a given statement will return at most once
15:46 sorear Cont has no properties, everything goes
15:46 sorear the free group is a group with no properties.  only the group laws are valid
15:46 sorear in the free group, ab = ba if and only if a = b^-1 or a = identity or b = identity
15:47 masak ah.
15:47 masak I can kinda-sorta see it.
15:47 masak it's the least constrained kind of group that's still a group.
15:47 sorear any statement which is true of a free object is true of any object in the sort
15:47 sorear well, equality statments
15:48 masak also makes sense, I guess.
15:52 GlitchMr https://gist.github.com/3707610
15:52 GlitchMr I would like 'multi sub fizzbuzz(Int $ where { $_ %% 15 }) { 'FizzBuzz' }' to be more important than other multi subs
15:52 GlitchMr Would this be possible?
15:53 moritz GlitchMr: try adding an 'is default' to it
15:53 GlitchMr Thanks
15:54 masak wow, an actual use of 'is default'.
15:55 sirrobert cool feature
15:55 masak well, yes and no.
15:55 masak I would consider 'is default' in any actual code to be a code smell.
15:55 moritz it's a blatant misuse of the feature :-)
15:55 masak why "misuse"? isn't this exactly what it's for?
15:56 masak promoting some multis ahead of others?
15:56 colomon joined #perl6
15:56 moritz hm, yes
15:56 masak in a sense, it's a code smell for the same reason CSS's !important is a code smell.
15:56 moritz mental model mismatch
15:57 [Coke] masak: mmm. I know exactly why I shouldn't use !important. and yet it's a nice hammer and ends up squashing many issues. ;)
15:57 moritz masak: fwiw removing that 'null' from QAST/Operations.nqp seems to fix the issue
15:57 moritz running a spectest now
15:58 sirrobert moritz: got psql working; thanks (http://blog.deliciousrobots.com/2011/12/13/ge​t-postgres-working-on-ubuntu-or-linux-mint/)
15:58 TimToady 'is default' is one of those escape valves that indicate that some other part of the language is either missing or being ignored by the programmer
15:58 masak that's a good summary, I guess.
15:59 masak same with CSS !important -- there's like four features you could've used before using that.
15:59 TimToady it can indicate that the type system is not up to doing what needs doing, or that the programmer doesn't sufficiently understand the type system
15:59 moritz or that maybe the type system isn't the best approach :-)
15:59 TimToady unfortunately, making the first part better makes the second part worse
15:59 snearch joined #perl6
16:00 TimToady the more complete the type system, the harder for mere mortals to understand
16:00 TimToady Haskell solves this by abandoning the mere mortals :)
16:01 TimToady many languages solve it by abandoning a type system, so everything becomes operational rather than declarative
16:02 TimToady Perl 6 tries to have it both ways, as usual.
16:02 masak oh come on, Haskell isn't that bad :)
16:03 brrt left #perl6
16:03 masak moritz++ # removing 'null'
16:04 * TimToady hugs Haskell
16:04 * geekosaur would have pointed to Agda as leaving the humans behind...
16:04 leont Haskell is something you have to warp your mind around first
16:04 masak [Coke]: I'm not anti-hammers. if we always avoided inserting code smells, we would be less productive.
16:04 masak leont: and second, and third...
16:04 sirrobert lunch &
16:04 skids The only place I've had to use "is default" was to deal with some probably incorrect rakudo behavior.  I think the above is one case of that since presence of a constraint is supposed to be a tie-breaker.
16:04 TimToady use hammer <default BEGIN eval>;
16:04 masak leont: "Haskell is easy to learn. I've done it five times by now." -- TimToady
16:05 [Coke] masak: I think haskell's pretty bad, but then, I don't use it.
16:05 TimToady or should that be 'use MONKEY_HAMMER <default BEGIN eval>;'
16:06 sorear augment class Mu { method looks_like() { "thumb" } }
16:06 TimToady we could fold in MONKEY_TYPING too: use MONKEY <augment>;
16:07 cognominal joined #perl6
16:07 geekosaur I use it.  it takes some getting used to, certainly, but that's a good thing from a stretching-the-mind standpoint.  perhaps not so much for day-to-day usability
16:08 masak I read this on Twitter recently: "When your hammer is a build system, ever problem looks like a build."
16:08 TimToady though if we included BEGIN in there, bosses would outlaw it, and then we'd have to find a way to do it anyway, like with 'constant'
16:08 [Coke] twitter! poor cjbot.
16:10 fgomez joined #perl6
16:10 masak [Coke]: what happened to it?
16:10 TimToady ended up a skull in a shakespeare play
16:11 Circlepuller joined #perl6
16:13 masak maybe an IRC channel is the wrong output channel for such a bot.
16:14 TimToady maybe it wants a dedicated IRC channel
16:14 sorear make it output to stdout and run it >> ~p6eval/dalek/dalek-poller/queue
16:15 TimToady we're just not dedicated enough here :)
16:16 masak there are limits even to our dedication.
16:16 masak for example, retweets of the same tweet turned out to be fairly... repetitive.
16:17 TimToady you can say that again
16:17 TimToady "There are limits even to our dedication." would make a great book dedication.
16:18 masak :P
16:18 masak but only after dedicating the book to tens of thousands of people.
16:19 TimToady limiting something to 0 is also a limit
16:19 TimToady or 1, if you count the autopun.
16:20 masak rn: say "There are limits even to our dedication.".comb(/dedication/).elems
16:20 p6eval rakudo d1f4dc, niecza v21-1-ga8aa70b: OUTPUT«1␤»
16:20 masak rn: say "There are limits even to our dedication.".comb("dedication").elems
16:20 p6eval rakudo d1f4dc: OUTPUT«Cannot call 'comb'; none of these signatures match:␤:(Str:D : Mu *%_)␤:(Str:D : Regex $pat, $limit = { ... }, :match(:$match), Mu *%_)␤:(Cool : Mu *%_)␤:(Cool : Regex $matcher, $limit = { ... }, Mu *%_)␤␤  in method comb at src/gen/CORE.setting:2053␤  in block  at …
16:20 p6eval ..niecza v21-1-ga8aa70b: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type Str␤  at /home/p6eval/niecza/lib/CORE.setting line 629 (Cool.comb @ 16) ␤  at /tmp/bl8K23Lufc line 1 (mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4138 (ANON @ 3) ␤  …
16:21 masak .comb doesn't take a string. ok.
16:27 [Coke] cjbot didn't handle twitter being down.
16:27 [Coke] basically caused it to flush its cache.
16:28 [Coke] sorear: if you can do it via dalek faster than I can get back to it, that's fine.
16:29 * masak half-opposes filling #perl6 with retweets
16:30 masak I'm not talking of the flush-cache case, but the normal, working case.
16:31 Circlepuller_ joined #perl6
16:42 [Coke] but not commit messages?
16:43 Vlavv_ joined #perl6
16:46 masak it is rare that commit messages are re-tweeted to the channel.
16:46 masak repetitions of commit messages happen sometimes in the case of merges. but they tend to coincide with dalek flooding and being kicked by the system.
16:47 [Coke] ah. So tweets are ok, but rewtweets are not?
16:47 masak here's what I'm saying. assume a tweet about Perl 6 is so popular that it garners thousands of retweets. what do we gain from seeing each one of them on the channel?
16:47 benabik joined #perl6
16:47 masak right. tweets good, retweets bad.
16:48 [Coke] Sure, that's reasonable.
16:48 [Coke] ... good luck getting that many rewtweets, though. ;)
16:48 [Coke] I'll add that to the list of things that must be fixed before cj can be turned back on.
16:48 arnsholt masak: That about the build system, is so true! =)
16:49 arnsholt I do a bajillion things with make these days
16:49 [Coke] masak: if you could open a ticket at github/coke/cjbot, that'd be helpful.
16:51 * benabik backlogs.
16:53 masak [Coke]: consider it done.
16:53 benabik Haskell doesn't leave mortals behind.  It sit above them and invites them to come up to it.  More rude than dismissive.
16:54 arnsholt benabik: Context? =)
16:57 tj joined #perl6
17:00 stopbit joined #perl6
17:00 cognominal joined #perl6
17:00 Guest34211 Just taking a first look at Perl 6 and rakudo.  I'm looking at the source to ufo.  There seems to be a subroutine "dir" in the namespace by default.  But I have been unable to find where this is specified.
17:00 Guest34211 I looked in the builtins synopsis.
17:01 cognominal joined #perl6
17:01 Guest34211 I note that http://perl6advent.wordpress.com/​2010/12/03/day-3-file-operations/ refers to it: "Instead of opendir and friends, in Perl 6 there is a single dir subroutine"
17:01 masak Guest34211: http://doc.perl6.org/routine/dir
17:02 gfldex Guest34211: perlcabal.org/syn/S32/IO.html#dir
17:02 masak moritz++ # it's so nice to be able to link to doc.perl6.org like that
17:03 leont Nice use of that junction, that's pretty awesome
17:04 masak yes, I hadn't seen that before. but yeah, all() should be vacuously true. :)
17:04 masak rn: say so all
17:04 p6eval niecza v21-1-ga8aa70b: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤The 'all' listop may not be called without arguments (please use () or whitespace to clarify) at /tmp/sFke9xkoPK line 1 (EOF):â�¤------> [32msay so all[33mâ��[31m<EOL>[0mâ�¤â�¤Unhandled exception: Check failedâ�¤â�¤  at /home/p6eval/…
17:04 p6eval ..rakudo d1f4dc: OUTPUT«True␤»
17:04 Guest34211 masak, gfldex: thanks
17:04 masak rn: say so all()
17:04 p6eval rakudo d1f4dc, niecza v21-1-ga8aa70b: OUTPUT«True␤»
17:04 benabik joined #perl6
17:05 masak rn: say so any()
17:05 p6eval rakudo d1f4dc, niecza v21-1-ga8aa70b: OUTPUT«False␤»
17:05 masak rn: say so one()
17:05 p6eval rakudo d1f4dc, niecza v21-1-ga8aa70b: OUTPUT«False␤»
17:05 benabik arnsholt: http://irclog.perlgeek.de/​perl6/2012-09-12#i_5981273
17:05 dalek Perlito: 8fdcbaf | (Flavio S. Glock)++ | / (5 files):
17:05 dalek Perlito: Perlito5 - initial impl of caller()
17:05 dalek Perlito: review: https://github.com/fglock/​Perlito/commit/8fdcbaf4dc
17:06 Guest34211 and the thing that confirms that it's correct for it to automatically be in the main namespace without me having to import it from IO is the fact that it's listed at http://doc.perl6.org/#Routines , is that right?
17:09 GlitchMr caller()? It's really basic :). But I guess it works
17:10 fgomez joined #perl6
17:11 masak Guest34211: think so. though I'm not 100% that list is complete yet.
17:11 [Coke] shouldn't the spec have something to say about that? no?
17:11 GlitchMr caller() accepts additional argument, but sometimes it doesn't return what you want even in actual Perl implementation, so whatever
17:12 masak GlitchMr: I'm sure fglock will happily accept patches.
17:13 masak GlitchMr: also, it's unusual for people in here to stand by the sidelines commenting how commits of new features don't do enough yet.
17:13 GlitchMr well, I guess it's good enough for start
17:14 masak I'm sure your tone just happens to sound dismissive. twice.
17:18 cognominal joined #perl6
17:18 masak re "It's very basic": that's how features are build, generally. you start with something small that works, and then add to it.
17:18 masak built*
17:18 leont left #perl6
17:22 PerlJam GlitchMr: What fancy thing do you want instead?  Can you describe it?  Maybe you can build it and share?
17:23 GlitchMr http://perlcabal.org:8080/
17:23 GlitchMr Perhaps...
17:23 [Coke] GlitchMr: is english your first language?
17:24 GlitchMr No
17:24 GlitchMr ok, so HTTP server sort of works
17:27 FROGGS joined #perl6
17:27 FROGGS__ joined #perl6
17:30 GlitchMr tadzik:
17:30 GlitchMr sub baile is export {
17:30 GlitchMr given HTTP::Easy::PSGI.new(port => 3000) {
17:30 GlitchMr Why it is hardcoded?
17:31 PerlJam Because no one has written the code to make it otherwise.
17:35 benabik joined #perl6
17:36 cognominal joined #perl6
17:38 TimToady Prototypes "Я" Us
17:38 GlitchMr http://perlcabal.org:5266/ - Bailador sort of works (I'm going to do something serious in it)
17:38 TimToady Toys "Я" Us   # not so far off the truth
17:39 spider-mario joined #perl6
17:39 alvis joined #perl6
17:39 wamba joined #perl6
17:40 GlitchMr Not like it was intended to be used in production, but hey, this is feather, so fun
17:41 alvis left #perl6
17:46 cognominal joined #perl6
17:48 GlitchMr http://perlcabal.org:5266/lol
17:48 GlitchMr I'm aware of XSS issue
17:48 GlitchMr This is going forward
17:49 GlitchMr 2012-09-12T17:48:30Z -- GET /lol HTTP/1.1
17:49 GlitchMr 2012-09-12T17:48:55Z --
17:49 GlitchMr unknown HTTP method
17:49 GlitchMr This is getting crazy
17:51 masak GlitchMr: having thought about it, all other things equal, I prefer you to be slightly dissing of various things, than to just react with '...' :)
17:54 benabik_ joined #perl6
17:58 GlitchMr https://gist.github.com/3708613 gives me "Unable to open filehandle from path 'content/rghwrg'"
17:58 GlitchMr Am I doing something wrongly?
17:58 moritz does it exist?
17:58 GlitchMr try {} should catch it, shouldn't it?
17:59 kenjiskywalker joined #perl6
18:00 masak not if you don't handle it in the CATCH...
18:01 masak something needs to &succeed from the CATCH block, or set $!.handled, IIRC.
18:01 GlitchMr That... makes sense
18:01 GlitchMr Even if it is somewhat confusing
18:03 masak you probably have a better idea for how it should be done. :)
18:03 GlitchMr succeed without when clause
18:03 GlitchMr That... sort of makes sense
18:04 masak I disagree.
18:04 GlitchMr Why I cannot use "succeed" without "when"?
18:04 masak you can.
18:04 masak oh, I thought you meant that you wanted "succeed" to be implicit if there wasn't a "when" clause in the CATCH.
18:05 masak and I think that would be a bad idea.
18:05 kenjiskywalker joined #perl6
18:05 masak you're fully free to use &succeed either directly, or indirectly through a "when" clause.
18:08 GlitchMr succeed when True?
18:09 kenjiskywalker joined #perl6
18:09 cognominal joined #perl6
18:12 kenjiskywalker joined #perl6
18:14 masak rn: given 42 { succeed; say "this doesn't get run" }; say "alive"
18:14 p6eval rakudo d1f4dc: OUTPUT«succeed without when clause␤  in block  at src/gen/CORE.setting:352␤  in block  at src/gen/CORE.setting:429␤  in block  at /tmp/3ZMygYDIWi:1␤␤»
18:14 p6eval ..niecza v21-1-ga8aa70b: OUTPUT«alive␤»
18:14 masak hm. I'm tentatively with Niecza on this one.
18:14 * masak checks the spec
18:15 masak hm. nope. Rakudo is right there.
18:16 masak "succeed" binds (statically) to the surrounding "when" block. Niecza should have flagged the above as an error.
18:16 * masak submits niecza-issue
18:16 FROGGS tadzik: from reading https://github.com/tadzik/panda/b​lob/master/lib/Panda/Installer.pm there is no way to tell panda that it should install a .c file?
18:18 fgomez joined #perl6
18:19 benabik joined #perl6
18:19 GlitchMr http://perlcabal.org:5266/%3Cbody%20onloa​d=%22alert('XSS%20yourself%20ftw')%22%3E
18:19 GlitchMr I'm XSS-ing yourself
18:19 GlitchMr oh wait
18:19 GlitchMr Why am I doing this
18:20 moritz why indeed?
18:24 cognominal joined #perl6
18:33 GlitchMr Why Dancer crashes every time I attempt to make POST request?
18:33 HarryS joined #perl6
18:34 GlitchMr The crash looks like https://gist.github.com/3708917
18:34 GlitchMr But it looks more like HTTP::Easy crash
18:35 moritz didn't you have the same error before with GET?
18:36 GlitchMr No
18:36 GlitchMr It only happens with POST request
18:36 GlitchMr Simple POST request
18:36 GlitchMr http://perlcabal.org:5266/ - if you will attempt to create article, it will crash
18:36 moritz so fix it
18:37 GlitchMr The problem is that it is HTTP::Easy crash
18:38 GlitchMr But...
18:38 GlitchMr unless $method eq any(<GET POST HEAD PUT DELETE>) { die "unknown HTTP method"; }
18:38 GlitchMr POST is known
18:38 moritz so what's in $method?
18:39 GlitchMr I'll have to use debugger ;)
18:39 GlitchMr but that's ok
18:39 moritz a simply   say $method.perl  will suffice
18:40 GlitchMr wow, this debugger is amazing
18:40 GlitchMr It can even debug regular expressions
18:40 GlitchMr It can debug almost anything :-)!
18:40 GlitchMr Except for syntax errors, I guess
18:41 masak how would you debug a syntax error? even the thought is a category error.
18:43 GlitchMr Even if this debugger only has breakpoints and single steps, it's usually enough :)
18:43 GlitchMr I guess that more will be added later
18:44 cognominal joined #perl6
18:44 moritz masak: I routinely debug syntax errors with bad error messages by commenting out chunks of code
18:45 mdupont joined #perl6
18:46 MayDaniel joined #perl6
18:46 GlitchMr oh, it wasn't POST
18:46 GlitchMr Rakudo just was seeing ghost query once a while
18:46 GlitchMr I wonder why
18:46 [Coke] binary compilation search.
18:47 moritz GlitchMr: are you using a browser?
18:47 GlitchMr Yes
18:47 moritz GlitchMr: there you go
18:47 moritz GlitchMr: browsers do all sorts of stuff
18:47 moritz GlitchMr: like ask for a favicon.ico
18:47 moritz or send a HEAD request now or then
18:47 GlitchMr favicon.ico would be catched by page request
18:47 GlitchMr get /^\/(<-[/]>*)$/ => sub ($name is copy) {
18:47 GlitchMr It would return 404, because page favicon.ico doesn't exist
18:48 [Coke] When I'm debugging this sort of thing, I find a tool like Fiddler very helpful.
18:48 masak moritz: oh, sure. but running them through a debugger felt like a category error.
18:49 moritz anyway, browser in general do many more requests than you'd expect
18:49 moritz *browsers
18:49 masak moritz: I also employ the technique of commenting stuff out. for really large golfings, I ratchet forward using a throwaway git branch.
18:50 moritz git++
18:50 moritz imagine doing that in svn :-)
18:50 GlitchMr Now, I wonder how I could set Location: header in Bailador. But I probably know answer already - I cannot do that... easily
18:51 moritz then create a way to do it
18:51 moritz it's all open source, you know
18:51 masak "there is no spoon"
18:53 GlitchMr hmmm... but content_type function exists... perhaps I could see how it works
18:53 [Coke] folks, sometimes we don't want to CREATE tools so much as use them. I know this isn't the right channel for that, necessarily.
18:53 masak moritz: as I'm writing this git course, a mental model is emerging that I find quite interesting. in centralized VCSes, there's just the working copy and the central repository, in a sense. in git-like systems, there's the working copy, *your unpushed work*, and (by convention, often) a central repository. that unpushed work is where a lot of the flexibility resides.
18:53 GlitchMr $app.response.headers<Content-Type> = $type;
18:53 GlitchMr I have my answer
18:54 masak [Coke]: it's not yet late enough in Perl 6's development when you can expect that all tools will have been created for you, no. like you can with Perl 5.
18:55 GlitchMr Except... I don't think I can access $app directly in Bailador
18:56 GlitchMr Because of Bailador "design"
18:56 GlitchMr But I guess that having multiple Bailadors at once would be strange, so singleton sort of works
18:57 * masak hugs GlitchMr
18:57 masak GlitchMr: I'm sure tadzik will also happily accept patches.
18:58 GlitchMr I already have changed Bailador so port won't be hardcoded
18:58 GlitchMr Or rather, it's hardcoded to different port
18:59 GlitchMr (ok, it doesn't change anything)
18:59 diakopter masak and moritz: you are being way too defensive. don't assume GlitchMr is complaining. Lots of people point out problems intending to be helpful, not looking for someone to tell them, "well fix it your own fucking self"
19:00 moritz diakopter: statements like "But I probably know answer already - I cannot do that" don't sound like that
19:00 diakopter still, it could be tongue-in-cheek ribbing, not disgruntled maligning
19:01 diakopter give him the benefit of the doubt
19:01 GlitchMr I could hack "Location" header like that: https://github.com/GlitchMr/Bailador/commi​t/e1d398acfd142d38411c91de120f3d632c6efa08
19:01 GlitchMr But I find this ugly
19:01 moritz diakopter: the benefit of doubt wears up quickly with the volume of negative statements
19:01 GlitchMr What if next day somebody would want to put "X-Destroyed-By" header
19:02 moritz diakopter: but if you're right, it would be more productive I simply /ignore'd folks that rub me the wrong way
19:02 masak diakopter: all this backlog, I've been giving GlitchMr the benefit of the doubt.
19:02 diakopter ok
19:03 moritz sadly /ignore sometimes lead to weirdly sensless conversations
19:03 masak note all the places where I didn't explode, rant all over him, or kick him out.
19:03 FROGGS GlitchMr: why not add a header method that can set every header?
19:03 GlitchMr Hmmm... yeah
19:03 masak I tried to put in enough smilies to make sure that my pointing out that his disgruntled complaining wasn't being productive didn't get read as being too negative, too.
19:04 FROGGS GlitchMr: you still can have other methods that set common headers, for usa- and readability
19:04 masak you're probably right in general about (many of) us being "too defensive". I still have trouble detecting when that happens.
19:05 GlitchMr But I guess this is worst HTTP header API - http://www.php.net/manual/en/function.header.php
19:05 masak as far as I know, that's a community defense mechanism, which has to be untrained for it not to happen.
19:05 GlitchMr Perhaps, header('Location', 'http://duckduckgo.com') would work
19:05 diakopter whether you're defensive or not, saying patches welcome in response to complaints more than 1 time comes across as rude
19:06 diakopter (or ignored)
19:06 diakopter (oh well) :)
19:06 FROGGS GlitchMr: or a Pair: header( 'Location' => '/foo' )
19:06 FROGGS looks nice to me
19:06 FROGGS both would work actually
19:06 masak diakopter: I'll think of that until next time.
19:07 masak thanks for pointing it out.
19:07 GlitchMr In Perl 5, => is fat comma. It would work instantly
19:07 GlitchMr But I guess implementing this in Perl 6 is more problematic
19:07 FROGGS masak: 2nd time a "please make a ticket" would be more constructive I suppose
19:08 GlitchMr https://github.com/GlitchMr/Bailador/commi​t/41d43bf01f088ad49b276eb381a4ace1b88329ea
19:08 FROGGS GlitchMr: no, thats not difficult in Perl6
19:08 TimToady diakopter: don't be so dismissive of masak for being so dismissive of GlitchMr for being so dismissive of...I forget who...  :)
19:08 GlitchMr Generic, you say?
19:08 masak TimToady: this reminds me of the time I called someone a troll :)
19:08 moritz accessing .key and .value isn't hard
19:09 * diakopter still feels badly for that occasion, even though I barely remember anything about it
19:09 FROGGS GlitchMr: you can have multi methods, one for ( Str, Cool ) the other for ( Pair )
19:09 TimToady hugme: hug everyone who needs it
19:09 * hugme hugs everyone who needs
19:09 TimToady hugme: hug it
19:09 * hugme hugs it
19:09 FROGGS GlitchMr: but I guess this can be done via some weird sign in front of the var names, like * or : or so
19:10 masak TimToady: this one, quite familiar to the above: http://irclog.perlgeek.de/​perl6/2010-03-06#i_2071590 :)
19:10 diakopter hugme: hug 1 2 3 4 5 6
19:10 * hugme hugs 1
19:12 diakopter :(
19:13 GlitchMr Well, "quite familiar" doesn't include kick :-)
19:13 GlitchMr https://github.com/tadzik/Bailador/pull/2
19:14 moritz GlitchMr++ # putting up, not shutting up :-)
19:15 masak \o/
19:15 masak GlitchMr++ # well-deserved karma
19:16 GlitchMr Well, I'm trying to do is a nice Wiki in Perl 6 :)
19:16 masak ooh
19:17 diakopter Camelia's shadow looms
19:17 GlitchMr Git based, I might add ;)
19:18 diakopter GlitchMr: where do you want to store the content?
19:18 TimToady masak++ and diakopter++ for, er, participating, yeah, participating...
19:18 GlitchMr diakopter: Probably GitHub :-)
19:18 diakopter heh, I meant the wiki content
19:18 stopbit joined #perl6
19:19 diakopter although
19:19 diakopter I suppose you could store wiki content in a git repo
19:19 awwaiid ya, that's what GlitchMr meant I bet :)
19:19 awwaiid github's wiki's are all stored in git, btw, diakopter
19:20 TimToady Ain't communication wunnerful, exceptin' when it ain't...
19:20 diakopter oh, I missed the "Git based"
19:22 benabik joined #perl6
19:24 masak I'm not getting anything done today, so taking an early night and hoping it gets better tomorrow. :)
19:24 masak 'night, #perl6
19:26 FROGGS gnight
19:28 GlitchMr But... the HTTP::Easy sounds annoying. It dies on request type it doesn't know.
19:28 GlitchMr And when you can catch exception, it's already too late - server has closed
19:28 moritz so, what kind of request does it not know about?
19:29 moritz but you're right, that's not very defensive
19:29 GlitchMr Well, for some reason it sees empty request, but technically, anybody could crash my app with request like SPAWN /creeper
19:29 [Coke] what, now we need to be MORE defensive?
19:30 [Coke] :)
19:31 GlitchMr Web app in Perl 6 would be fun
19:31 GlitchMr But it would have to be secure
19:32 Woodi btw. do $socket.recv() is allowed to segfault ?
19:32 GlitchMr I hope not
19:33 Woodi () segs, but (number) can be used
19:34 [Coke] rakudo should never segfault, no
19:34 [Coke] (nor expose parrot exceptions)
19:36 Woodi atm simple 'telnet' returns things like: "łąka\r\n\b\x[10] or "łąka\r\n\b\x[0]", etc or Segmentation fault
19:36 dalek Perlito: d7ae527 | (Flavio S. Glock)++ | / (3 files):
19:36 dalek Perlito: Perlito5 - parser: fix problem with "&" sigil
19:36 dalek Perlito: review: https://github.com/fglock/​Perlito/commit/d7ae527526
19:37 Woodi and server send only "łąka\r\n" part
19:37 [Coke] is this with rakudo?
19:38 [Coke] if you could open a ticket with a code sample that demonstrates the segfault (preferably with a gdb backtrace) that would be very helpful in tracking it down.
19:38 Woodi yes, 08. say $result.perl
19:38 Woodi ok
19:39 mtk joined #perl6
19:40 PerlJam \
19:42 moritz /
19:42 dalek nqp: 2651350 | moritz++ | src/QAST/Operations.nqp:
19:42 dalek nqp: [QAST] do not null something we still need
19:42 dalek nqp:
19:42 dalek nqp: Fixes RT #114836
19:42 dalek nqp: review: https://github.com/perl6/nqp/commit/265135051c
19:44 dalek rakudo/nom: 220a691 | moritz++ | tools/build/NQP_REVISION:
19:44 dalek rakudo/nom: bump to an NQP revision which fixes RT #11483
19:44 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/220a691e33
19:47 dalek roast: 88de4c9 | moritz++ | S04-statements/repeat.t:
19:47 dalek roast: RT #114836, shared variable between loop body and conditional
19:47 dalek roast: review: https://github.com/perl6/roast/commit/88de4c989c
19:47 tadzik FROGGS: under what circumstances do you need to install .c file?
19:47 tadzik also, I need to figure out some way to override/extend various build steps
19:48 tadzik Build.pm or so
19:48 tadzik seen leont?
19:48 aloha leont was last seen in #perl6 2 hours 29 mins ago leaving the channel.
19:48 benabik joined #perl6
19:48 FROGGS tadzik: I compile that .c file to a lib, and use it with NativeCall
19:49 tadzik you compile it in runtime?
19:49 FROGGS tadzik: right now I'm working on a patch for NativeCall that allows one (probably just me) to use some sort of inline c
19:49 tadzik hmm
19:49 FROGGS tadzik: right
19:49 tadzik I see
19:49 LlamaRider joined #perl6
19:49 tadzik okay. What do you thing about designing how Build.pm should behave with me?
19:49 tadzik designing with me, not behave with me
19:50 FROGGS well, I only know Module::Build, not MakeMaker
19:50 tadzik I don't know either
19:50 FROGGS so all I can say that M::B is working good
19:50 tadzik I never wrote a Perl 5 module
19:50 FROGGS you have a Build.PL with information like the one in META.info
19:51 FROGGS you can have hashes in that META.info where you can add extra files that wont get picked up usually
19:51 tadzik but it's still Module::Build responsibility to be able to handle them
19:51 FROGGS like: lib/mycustomfile.xyz => destinationdir/newfilename.abc
19:52 FROGGS right
19:52 tadzik now what I think we need is allow arbitrary actions in the separate steps
19:52 FROGGS you set up a big hash, a config
19:52 tadzik use cases: your SDL code, Rakudo::Debugger
19:52 tadzik so code, not metadata
19:52 * tadzik sketches
19:53 FROGGS M::B has subs like action_BUILD, action_INSTALL that you can replaxce with your own
19:53 tadzik https://gist.github.com/3709444
19:53 tadzik something of this sort
19:53 FROGGS simply by having a My::Module::Build module in inc, that has the same function names
19:53 tadzik you could do that with Build, Install, Test, whatever
19:54 FROGGS right
19:54 tadzik I discussed it with Schwern and Leon on the YAPC
19:54 FROGGS and you must be able to manipulate the list of  files that get installed
19:54 tadzik but I don't remember all the details
19:54 tadzik well, installer just copies everything from blib/ to DESTDIR
19:54 FROGGS one nice feature of M::B is share_dirs
19:54 tadzik so it's builder's responsibility to put stuff in blib/
19:55 FROGGS to tell 'em a dirname (usually 'share') which contents get installed, whatever files it contains
19:55 FROGGS and then you have a module called File::ShareDir, which gives you the path when its installed, so you can then acces your gfx or sounds again
19:55 FROGGS right
19:56 tadzik GlitchMr++ # Bailador patch
19:56 tadzik I applied it blindly without testing :)
19:56 tadzik hmm, interesting
19:59 FROGGS there a lot of stuff going on on M::B, can't get it out of my head right now
19:59 tadzik whoa, cowboy, let's not put too much intelligent design in Panda ;)
20:00 FROGGS ;o)
20:00 tadzik no, kidding
20:00 tadzik what do you think of the Build.pm thing for a start
20:00 tadzik we'll probably want _some_ Build.pm anyway
20:00 tadzik (optional of course)
20:01 tadzik people are happy with not having to do anything in simple cases
20:01 FROGGS ya, sounds good
20:01 tadzik so, want to implement it? :)
20:01 FROGGS you dont have to do much wich M::B, the simplest case is that you create your hash (10 lines max), then call "create_build_script"
20:02 FROGGS hmm, let me have a look at panda source
20:04 FROGGS okay, your gist would allow me to make a custom build method
20:04 FROGGS how would I let panda know to grab my Build.pm file at all?
20:06 FROGGS place it in inc?
20:06 rickatcox joined #perl6
20:08 tadzik maybe try require()?
20:08 tadzik I don't know :)
20:10 FROGGS well, you say if its stupid what I write but I just would do it like: if 'inc/Build.pm'.IO.e { use lib 'inc'; use 'Build.pm' }
20:10 FROGGS I know, use shouldnt work
20:11 FROGGS maybe unshifting 'inc' to $*INC?
20:11 FROGGS or was it $^INC?
20:12 Tanktalus joined #perl6
20:12 * Tanktalus looks around for how to delete a key from a hash, but isn't having any luck finding it so far :-/
20:12 FROGGS splice it?
20:13 Tanktalus oh, and piping, like perl5's "open my $fh, '|/bin/echo'" :-)
20:13 fgomez joined #perl6
20:14 Tanktalus FROGGS: ouch, really?  Is that because it won't be there ever, or that type of functionality just isn't there yet?
20:15 rickatcox cant you just "undef %hash{key}" im kind of a newbie but it sounds like it should work to me..
20:16 cosimo Tanktalus: %hash<key>.delete I think
20:16 FROGGS then you have undef as the value
20:16 [Coke] my %h; %h<a>=2; %h<b>=3; delete %h<b>; say %h.perl;
20:16 [Coke] r: my %h; %h<a>=2; %h<b>=3; delete %h<b>; say %h.perl;
20:16 p6eval rakudo 220a69: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&delete' called (line 1)␤»
20:16 FROGGS r: my %h; %h<a>=2; %h<b>=3; undef %h<b>; say %h.perl;
20:16 p6eval rakudo 220a69: OUTPUT«===SORRY!===␤Unsupported use of undef as a verb;  in Perl 6 please use undefine function or assignment of Nil␤at /tmp/Uzyh7CgQBJ:1␤»
20:16 FROGGS r: my %h; %h<a>=2; %h<b>=3; undefine %h<b>; say %h.perl;
20:16 p6eval rakudo 220a69: OUTPUT«("a" => 2, "b" => Any).hash␤»
20:16 Tanktalus [Coke]: yeah, that's what I was getting :-)
20:17 [Coke] my %h; %h<a>=2; %h<b>=3; %h<b> :delete; say %h.perl;
20:18 [Coke] r: my %h; %h<a>=2; %h<b>=3; %h<b> :delete; say %h.perl;
20:18 p6eval rakudo 220a69: OUTPUT«===SORRY!===␤Confused␤at /tmp/PbIU66082c:1␤»
20:18 [Coke] ah. 70:#?rakudo skip ':exists and :delete NYI'
20:18 cosimo r: my %h; %h<a>=2; %h<b>=3; %h<b>.delete; say %h.perl;
20:18 p6eval rakudo 220a69: OUTPUT«No such method 'delete' for invocant of type 'Int'␤  in block  at /tmp/85v8Hm4vx6:1␤␤»
20:18 FROGGS r: my %h; %h<a>=2; %h<b>=3; %h.delete('b'); say %h.perl;
20:18 p6eval rakudo 220a69: OUTPUT«("a" => 2).hash␤»
20:18 cosimo aha
20:19 FROGGS Tanktalus: about pipe: http://www.perl6.org/archive/rfc/14.html
20:19 cosimo r: my %h; %h<a>=2; %h<b>=3; %h.delete(:b); say %h.perl;
20:19 p6eval rakudo 220a69: OUTPUT«("a" => 2, "b" => 3).hash␤»
20:19 FROGGS Tanktalus: didnt tested though
20:20 tadzik FROGGS: why not require('file')?
20:20 FROGGS ohh, that would work too, ye
20:20 FROGGS ya
20:20 FROGGS (its late here)
20:21 * tadzik tries to run bailador on niecza
20:22 Tanktalus thanks, I see delete returns the value deleted, so that's useful... just trying to figure out the next issue with this sample :-S
20:24 tadzik woooo
20:24 tadzik sorear++
20:24 tadzik that's _FAST_
20:25 Tanktalus oh, delete returns something completely different.  Yikes.
20:26 tadzik Requests per second:    162.57 [#/sec] (mean)
20:27 FROGGS r: my %h; %h<a>=2; %h<b>=3; say %h.delete('b');
20:27 p6eval rakudo 220a69: OUTPUT«3␤»
20:27 FROGGS Tanktalur: looks good to me
20:27 FROGGS s/r/s
20:28 Tanktalus FROGGS: hmm - I'm getting a hash as an in parameter.  Maybe it's marked readonly, so that might be some sort of odd exception.
20:28 FROGGS apped " is copy " to the param
20:29 tadzik more: Bailador works on niecza, but not on Rakudo
20:30 rickatcox ok guys, so I just installed rakudo-star-2012.08 on RHEL 5 and when I do something like "perl6 -e '"abc" ~~ /(\w)+/ and say $/[0];'" I get ï½¢aï½£  ...  am I doing something wrong or is there something wrong?
20:30 fgomez joined #perl6
20:31 rickatcox any time I do a capture I get garbage..  but if i use something like $/[0].join it cleans it up..
20:32 tadzik hmm, no idea really
20:32 tadzik does it change if you put it in a script and run it there?
20:33 rickatcox nope
20:33 rickatcox this is my first experience with perl6
20:33 tadzik care to try? I see no reason why it would react this way, really
20:34 FROGGS my first thought was that you terminal might be ansi and you get unicode stuff back...
20:34 Tanktalus http://pastebin.ca/2203620
20:34 tadzik r: "abc" ~~ /(\w)+/ and say $/[0]
20:34 p6eval rakudo 220a69: OUTPUT«「a」␤ 「b」␤ 「c」␤␤»
20:34 tadzik oh
20:34 tadzik those characters
20:34 FROGGS r: "abc" ~~ /(\w)+/ and print $/[0]
20:34 p6eval rakudo 220a69: OUTPUT«abc»
20:34 Tanktalus FROGGS: I added is copy, and the output shows that things didn't work :-S
20:35 Tanktalus oh, maybe it doesn't like the <> syntax?
20:35 rickatcox initially i tried the perl 5 syntax: ($a)=$s=~/(\w+)/; and then started looking around when that was hosed..
20:35 FROGGS "say" is for human readable output, print is for machine readable stuff
20:36 rickatcox hmm..  print does work...  i guess I need to read up on the human interface..
20:36 tadzik rickatcox: I guess it's just your terminal that doesn't properly render those funny characters: 「」
20:37 rickatcox I hve my term set to ansi on both securecrt and $TERM
20:37 tadzik okay, what do you see: bździągwa
20:38 FROGGS Tanktalus: it is working when you use ('b') instead of <b>
20:38 [Coke] you need something utf8y.
20:38 FROGGS Tanktalus: but I dont know if that is a feature or not
20:38 rickatcox ok..  well at least I know I'm not completely crazy..  thanks for the help!
20:38 tadzik :)
20:38 PerlJam star: say "hi"
20:38 p6eval star 2012.07: OUTPUT«hi␤»
20:38 Tanktalus FROGGS: yeah, I made that change.  I'm not entirely clear on all the p6 brackets yet :-)
20:38 tadzik rickatcox: don't hesitate to complain loudly if something doesn't do what you expect :)
20:39 FROGGS Tanktalus: me neither ;o)
20:39 rickatcox thanks tadzik!
20:39 tadzik welcome :)
20:40 FROGGS hi PerlJam
20:40 Tanktalus and that rfc doesn't seem to suggest anything I didn't already try :-D
20:40 PerlJam greetings FROGGS
20:40 Tanktalus (for piping)
20:41 fgomez_ joined #perl6
20:41 FROGGS you already had a look at the spec or test repos on github? they show the current implementation
20:42 Tanktalus just the rfc, and just tried open '|/bin/echo' - that rakudo didn't like :-S
20:43 tadzik .u thumb
20:43 phenny tadzik: Sorry, no results for 'thumb'.
20:45 LlamaRider Is there a simple way to make P5 and P6 play together? I have a Perl5 framework and want to write some new modules in P6. How bad is that situation - is it the same as using P5 together with Java, for example?
20:46 tadzik LlamaRider: it's semi-possible in niecza, I think
20:47 LlamaRider that's kind of semi-vague :)
20:47 FROGGS LlamaRider: you might have a look at Object::Remote module mst writes
20:48 FROGGS he is going to add support so that you can talk from perl5 to 6 and vice versa
20:49 LlamaRider fancy. and nice!
20:49 PerlJam Yeah, but IIRC Object::Remote isn't quite there yet.  But maybe next week or the week after
20:50 rickatcox one more question, is there a document that describes the interactive mode and how to control it? (command line switches?)
20:50 fgomez joined #perl6
20:50 LlamaRider I am still gearing up to that until say mid-October, so I am in no super-rush. That's an interesting thing to look forward to.
20:51 tadzik rickatcox: not really
20:51 tadzik it's unspecced
20:51 rickatcox ok..  thanks..
20:51 tadzik it's mostly like writing code on the fly, not much command line switches there
20:52 LlamaRider I had also caught a note that someone (Larry?) is making Perl5 interpretable via Perl6. Not sure if that is a myth or not.
20:53 LlamaRider Ah yes, first FAQ answer here: http://www.perl6.org/archive/faq.html
20:53 LlamaRider it's a translation claim, my bad
20:54 PerlJam #perl6 is where magical people live.  What may seem like a myth to the outside world may indeed be reality to people here  :-)
20:55 FROGGS does somebody know how to access pod section in another module and if there is something like caller() (Perl5) ?
20:56 tadzik callframe()
20:56 tadzik as for Pod, that's a bit tricky now :/ What do you need to do?
20:56 FROGGS thanks
20:57 FROGGS my inline c is actually a pod block, and I can get it by $=pod[index]
20:57 FROGGS would it be $=MODULE::pod[index] then?
20:57 FROGGS its empty :/
20:57 tadzik that won't work, I'm afraid :
20:57 tadzik it's file-scopet
20:58 FROGGS hmmm
20:58 tadzik you could maybe write an accesor sub for it :P
20:58 FROGGS ya, another workaround :/
21:00 tokuhiro_ joined #perl6
21:00 tadzik yeah, I know
21:05 jnthn evening o/
21:05 FROGGS hi jnthn
21:05 * jnthn survived stressful conf day
21:07 tadzik good evening jnthn
21:08 jnthn hi tadzik, FROGGS
21:13 leont joined #perl6
21:40 FROGGS gnight
21:46 jnthn sleep &
21:49 Chillance joined #perl6
21:57 Tanktalus so far, no luck finding out how to pipe to a subprocess in p6 :-(
22:12 sorear Tanktalus: don't think it's possible currently
22:13 Tanktalus sorear: ok, that explains it then.  It's too bad because nearly everything I do in perl 5 is through pipes.
22:14 sorear Tanktalus: but see szabgab's latest blog post for "DOS pipes"
22:15 TimToady there's a whole bunch of stuff in nom's directory containing "pipe", but it's all down in parrotland
22:16 Tanktalus sorear: szabgab has a bazillion blog sites, I'm even subscribed to a few (!) but I'm not sure which one you're referring to :-)
22:20 sorear http://perl6maven.com/sending-email-using-perl6
22:21 Tanktalus sorear: that's the one I was trying to take issue with, actually, by trying to write it closer to how I'd do it in perl 5 ;-)
22:21 TimToady Tanktalus: are you trying to do this on windows or unix?
22:22 TimToady one could use a named pipe on unix
22:22 Tanktalus I'm on linux, but doing this as much to cement perl 6 ideas as anything else - I only learn by doing, not by reading, so I read that article in perl6maven and wanted to "improve" on it :-)
22:23 Tanktalus I'd actually rather use something like Net::SMTP, but I'm not sure that's available on perl6 yet either :-)
22:24 Tanktalus Of course, I'm going to end up getting myself into trouble again with Gabor - last time I critiqued something on perl5maven, he told me to write my own damned article. (Paraphrased, he didn't use the word "damned") :-D
22:24 TimToady shell 'mknod fifo p; mysubproc <c &'; my $pipe = open "fifo", :w; or some such
22:25 Tanktalus Right.  Ow.  :-)
22:26 TimToady or fiddle with PIR:: stuff
22:26 sorear TimToady: my darwin system here wants 'mkfifo', does not have 'mknod p' :|
22:26 TimToady how...darwinian...
22:26 TimToady it's a good think I hedged it
22:27 TimToady a good thing too
22:27 TimToady I guess linux has mkfifo too
22:28 TimToady I'm showing my age by remembering mknod instead
22:29 geekosaur mkfifo has the advantage that it can be run by ordinary users; mknod is root only
22:30 TimToady I almost said, "I'm dating myself", but I'd be dating myself to use that phrase nowadays without realizing it's become a double entendre, just like everything else has.  Get off my lawn!
22:30 * Tanktalus still thinks it'd be nicer just to be able to open pipes to subprocesses. :-P
22:30 TimToady someone has to be the tormented implementor
22:31 Tanktalus Is the syntax settled?  Not that I'm volunteering :-)
22:32 TimToady it's specced, so yes, but it's specced in IO, so, er, no, not exactly
22:32 Tanktalus .oO( TimToady is a manager? )
22:32 TimToady last I knew moritz++ was being the tormented IO speccer
22:33 TimToady I'd think it'd be nice to have *a* way, even if it's the wrong way
22:35 Tanktalus I was kind of expecting something like my $fh = open '|-' or exec '/usr/bin/sendmail'  ... "or some such" though maybe my $fh = open [ '/usr/bin/sendmail' ], :pipeto; would work, too. :-)
22:35 flussence joined #perl6
22:35 Tanktalus But what do I know, I only dabble in perl 6 once every couple of years :-)
22:36 TimToady we're trying to avoid putting modes into the same string as the filename these days; even Perl 5 thinks that's a bad plan...
22:36 Tanktalus Ever since TheDamian visited us in Toronto for a presentation on perl 6 ... back in 2001. :-)
22:37 TimToady I think prior art is the curse of IO
22:37 Tanktalus (And I moved away from Toronto in 2002.)
22:37 TimToady everything has to look like 'open'
22:37 TimToady or everything has to look like a constructor
22:38 TimToady I'd be happy with pipe-to() and pipe-from() functions for now
22:38 Tanktalus my $fh = readpipe <some command here>; # too perl 5-ish? :-)
22:38 TimToady that was an internal primitive that escaped :)
22:39 Tanktalus that'd work for me.  Probably better, really.  Though I can't quite state in words how pipe-* would be better. :-)
22:39 TimToady and it's not the same as pipe-from(), which would return a handle
22:39 TimToady readpipe was the name for `command`
22:40 Tanktalus Yes, I know perl5's readpipe returns text not an object :-P
22:40 TimToady pipe-from doesn't contain the morpheme "read"
22:40 Tanktalus I've tried to take a look at how to get perl 5's readpipe could take a list (like system) and failed :-)
22:41 diakopter what's the syntax for telling such a pipe to decode utf-16 to P6's internal string representation when reading?  or latin-1? etc
22:41 Tanktalus I'm just curious as to how pipe-from/pipe-to would look alongside a normal pipe() function that also seems missing so far :-)
22:42 TimToady presumable the same as other handle openers
22:42 TimToady that doesn't mean they all have to be called "open"
22:42 TimToady *bly
22:42 Tanktalus my $fh = pipe-from(<some command here>);  but my ($rh, $wh) = pipe(); # no command for pipe
22:43 TimToady p5 considers pipe() to be a syscall-level primitive
22:43 Tanktalus of course, if pipe accepted a command, too, it could do what IPC::Open2 does in p5 ;-)
22:44 TimToady pipe-through() or some such
22:45 TimToady though to set encodings differently on input/output would require something more than current open's named args
22:45 diakopter TimToady: was "presumably.." in response to my question? if so, what's that syntax
22:46 diakopter I seem to hav forgotten
22:46 TimToady me too, which makes it a good thing it's documented somewhere :)
22:47 TimToady probably in the source code, if nowhere else...
22:47 diakopter what
22:47 diakopter what's the syntax to change that encoding setting once you have the handle
22:47 TimToady r: say &open.^signature
22:47 p6eval rakudo 220a69: OUTPUT«No such method 'signature' for invocant of type 'Perl6::Metamodel::ClassHOW'␤  in block  at /tmp/fY1mH6_BEQ:1␤␤»
22:48 diakopter r: say &open.signature
22:48 p6eval rakudo 220a69: OUTPUT«:()␤»
22:48 TimToady I think IO says something about that
22:48 TimToady r: say IO.^methods
22:48 p6eval rakudo 220a69: OUTPUT«␤»
22:51 skids joined #perl6
22:51 TimToady IO specs :enc() on open, so presumably a similar arg on pipe opens
22:51 diakopter n: say IO.WHICH, IO.clone.WHICH
22:51 p6eval niecza v21-1-ga8aa70b: OUTPUT«[34C76880][34C76880]␤»
22:51 TimToady it specs IO::Encoded.encoding as a rw thing, which is funny
22:52 TimToady so $handle.encoding = "foo" would work, but only if it's already an IO::Encoded  :/
22:53 TimToady nr: say $*IN.WHAT
22:53 p6eval niecza v21-1-ga8aa70b: OUTPUT«TextReader()␤»
22:53 p6eval ..rakudo 220a69: OUTPUT«IO()␤»
22:54 diakopter n: say $*IN.WHO
22:54 p6eval niecza v21-1-ga8aa70b: OUTPUT«Stash.new(...)␤»
22:54 TimToady r: $*IN.encoding = "ISO-8859-1"; say lines()
22:54 p6eval rakudo 220a69: OUTPUT«No such method 'encoding' for invocant of type 'IO'␤  in block  at /tmp/5pQ6W8RYfG:1␤␤»
22:55 TimToady right...
22:55 TimToady r: binmode($*IN, "Latin-1")
22:55 p6eval rakudo 220a69: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&binmode' called (line 1)␤»
22:55 TimToady didn't expect that to work...
22:57 diakopter same for how to encode output/write/send
22:57 TimToady I suppose the only way to handle it currently is to use buffer read/write and encode by hand
22:58 diakopter if the current factoring remains, the std handles need to be IO::Encoded
22:59 TimToady kinda by definition, anything that reads or writes unicode strings is *coded
22:59 Tanktalus technically, anything that is intended to be consumed textually is coded :-P
23:00 diakopter (perhaps poorly/wrongly)
23:01 TimToady if the default is unicode text, then the default IO should consider itself to have a decoding/encoding
23:06 * diakopter assumes that would be utf8/ascii/ansi
23:06 TimToady and $*IN.encoding should maybe be $*IN.decoding
23:07 TimToady $*IN's decoding would usually be $*OUT's encoding, but this is not a guarantee
23:08 TimToady likewise for a pipe-through, we need to be able to supply those as separate layers (in P5-think)
23:09 TimToady I mean parallel for input and output, not layered on each other
23:14 diakopter hmm, twitter didn't translate my "/me"
23:14 diakopter I should've specified IRC encoding
23:17 TimToady or is that decoding?  who's to be master, that's all...
23:20 Tanktalus Oh, and dup'ing a filehandle, such as $*IN, shouldn't lose layers like in p5. :-P
23:25 Tanktalus for reference, in perl5, the bug I refer to is https://rt.perl.org/rt3/Tic​ket/Display.html?id=113982 and related is https://rt.perl.org/rt3/Tic​ket/Display.html?id=114334
23:26 benabik joined #perl6
23:26 TimToady .oO( $*IN.deepclone )
23:30 diakopter ambulate&

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

Perl 6 | Reference Documentation | Rakudo