»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
cotto Every single time I see what's getting implemented in Rakudo I get sad that most of the people who are hiring are looking for someone to maintain a pile of crappy PHP code. 00:45
timotimo jnthn: that looks beautiful 00:57
colomon jnthn++ 01:55
benabik jnthn++ # "I’m still not sure if this is beautiful or horrifying, but now it’s in place." 02:22
cotto I liked that quote. 02:23
gfldex i cheated a little but beaten the python folks: codegolf.stackexchange.com/question.../8925#8925 02:26
colomon gfldex++ 02:31
diakopter .. that thing where you can't find a bit of code you wrote in a program, but you swear is there somewhere 03:56
benabik deja code? 03:57
cotto I usually end up rewriting it then finding the original version 30 seconds later. 04:17
diakopter this is a new one. Vince Vaughn and Bruce Willis in the same movie.. 06:19
diakopter </[OT]> 06:28
sorear doesn't even know the topic 06:29
diakopter heh 06:32
FROGGS morning 08:03
diakopter o/
tadzik good morning 08:07
grondilu r: my &plus = *+*; sub infix:<+> { ($^a + $^b) % 10 }; say 7+6 08:08
p6eval rakudo f81716: OUTPUT«maximum recursion depth exceeded␤current instr.: 'print_exception' pc 88987 (src/gen/CORE.setting.pir:42692) (src/gen/CORE.setting:9121)␤called from Sub 'infix:<+>' pc 175 ((file unknown):202) (/tmp/J_sp9SzpJl:1)␤called from Sub 'infix:<+>' pc 201 ((file unknown):2…
grondilu r: my &plus = *+*; sub infix:<+> { &plus($^a,$^b) % 10 }; say 7+6 08:09
p6eval rakudo f81716: OUTPUT«maximum recursion depth exceeded␤current instr.: 'print_exception' pc 88987 (src/gen/CORE.setting.pir:42692) (src/gen/CORE.setting:9121)␤called from Sub 'infix:<+>' pc 175 ((file unknown):234) (/tmp/FfE0FdoDB5:1)␤called from Sub '' pc 168 ((file unknown):226) (/tmp…
grondilu r: BEGIN { our &plus = *+* }; sub infix:<+> { &plus($^a,$^b) % 10 }; say 7+6 08:09
p6eval rakudo f81716: OUTPUT«No such method 'Nil' for invocant of type 'Parcel'␤ in at src/gen/BOOTSTRAP.pm:845␤ in at src/gen/BOOTSTRAP.pm:839␤ in any at src/gen/BOOTSTRAP.pm:836␤ in sub infix:<+> at /tmp/2NSTCA9RJ1:1␤ in block at /tmp/2NSTCA9RJ1:1␤␤»
diakopter r: my &plus = BEGIN { &infix:<+> }; sub infix:<+> { &plus($^a,$^b) % 10 }; say 7+6 08:10
p6eval rakudo f81716: OUTPUT«3␤»
grondilu diakopter: thanks! 08:11
diakopter yw
diakopter anyone happen to know of any fancy spiffy novel queue lock algorithms? 08:14
unbounded concurrency, no timeouts
diakopter unbounded concurrency (so no array-based, unless it's an ever-doubling two-level array), don't need abortable/timeouts 08:17
azawawi hi 08:28
jnthn: ping
star: sub ncurses_initscr() is native('libncurses') { ... }; 08:29
p6eval star 2012.10: OUTPUT«===SORRY!===␤Cannot call 'trait_mod:<is>'; none of these signatures match:␤:(Mu:U $child, Mu:U $parent)␤:(Attribute:D $attr, :rw(:$rw)!)␤:(Attribute:D $attr, :readonly(:$readonly)!)␤:(Attribute:D $attr, :box_target(:$box_target)!)␤:(Routine:D $r, :rw(:$rw)!)␤:(Routi…
azawawi star: use NativeCall; sub ncurses_initscr() is native('libncurses') { ... };
p6eval star 2012.10: ( no output )
azawawi star: use NativeCall; sub ncurses_initscr() is native('libncurses') { ... }; ncurses_initscr;
p6eval star 2012.10: OUTPUT«Cannot locate native library 'libncurses.so'␤ in method postcircumfix:<( )> at /home/p6eval/star/lib/parrot/4.6.0/languages/perl6/lib/NativeCall.pm6:122␤ in at src/gen/BOOTSTRAP.pm:827␤ in any at src/gen/BOOTSTRAP.pm:811␤ in block at /tmp/oUculDXx6J:1␤␤»… 08:30
azawawi star: use NativeCall; sub ncurses_initscr() is native('libncurses.5.so') { ... }; ncurses_initscr; 08:40
p6eval star 2012.10: OUTPUT«Cannot locate native library 'libncurses.5.so'␤ in method postcircumfix:<( )> at /home/p6eval/star/lib/parrot/4.6.0/languages/perl6/lib/NativeCall.pm6:122␤ in at src/gen/BOOTSTRAP.pm:827␤ in any at src/gen/BOOTSTRAP.pm:811␤ in block at /tmp/h_35n0nGGt:1␤␤»…
azawawi star: use NativeCall; sub initscr() is native('libncurses.5.so') { ... }; initscr;
p6eval star 2012.10: OUTPUT«Cannot locate native library 'libncurses.5.so'␤ in method postcircumfix:<( )> at /home/p6eval/star/lib/parrot/4.6.0/languages/perl6/lib/NativeCall.pm6:122␤ in at src/gen/BOOTSTRAP.pm:827␤ in any at src/gen/BOOTSTRAP.pm:811␤ in block at /tmp/RmwsfE_Qvp:1␤␤»…
diakopter if I can find/discover an appropriate scalable queue lock, I can get rid of 5million failed CAS/s 08:56
bonsaikitten why is the locking needed? (iow, are lockless algos maybe useful here?) 08:58
diakopter the "lock" is really just access to the memory each wants to CAS. So, to remove contention on that location, a queue lock can be used. it's for implementing a lock-free algorithm 09:00
heh. 09:01
well hmm, never mind, seems I confused myself there again. a queue lock wouldn't help. sry nm 09:02
but I need something to reduce CAS contention. simple exponential backoff is helping a little, but it's constraining throughput 09:03
diakopter heads out for a midnight snack 09:04
Woodi diakopter: google for "linked list lazy concurent" in pdf by Nir Shavit, there is nice explanation. Shavit is good source for new concurency things :) 10:49
i can paste link if you want 10:50
diakopter sure 10:53
flussence wants fork() just to write sane http server tests... I'm half tempted to use NativeCall 10:58
arnsholt Well, the good news are that it won't require any NativeCall hacks =) 10:59
But I'm not sure how happy Parrot is with random forking
flussence I tried it on the repl once. It works, fsvo "work" :) 11:00
Woodi diakopter: link: www.google.pl/url?sa=t&rct=j&am...FNb67_vPrg 11:06
or better this: people.csail.mit.edu/shanir/publica...urrent.pdf :) 11:08
flussence just got a nice shock at $dayjob: I ran "grep cron /var/log/*" on an old debian 3.0 box to try and figure out if it was in use. It ran aptitude and passed a bunch of garbage input to it... 11:27
huf wha 11:28
flussence: how did this happen?
flussence dunno, probably seriously screwed up handling of control characters
huf heh :) 11:29
flussence (this thing is so old bash doesn't even have *readline support*)
moritz wtf? 11:30
grondilu posted a question about style for plural form for names of variables: perlmonks.org/?node_id=1002881 11:56
^ what dyou think about this, guys? 11:57
I know it's not a big problem but it's kind of annoying me each time I have to chose a name for an array variable. 11:58
cognominal grondilu, where are you living? 11:59
grondilu France. Why?
cognominal near Paris?
grondilu No. I left Paris a few months ago. I live in Picardie, now. 12:00
cognominal do you know the mongueurs?
grondilu Not much.
cognominal ha, too bad.
I have seen you are taking over the French wp article about Perl 6. that's good because I have not updated it much the last few years 12:01
there is some crap (about history mostly) added by well intentionned people I did not remove to not discourage further collaboration that did not materialize. I hope you will be more drastic than I was. 12:03
grondilu, there is a french channel #perlfr on irc.perl.org 12:05
grondilu "taking over" is not the right expression. I just thought is need a sreious update indeed. But I don't have much more ideas about what to add now. 12:05
grondilu 'thought it needed a serious' (cold fingers) 12:06
cognominal grondilu: about the plural for arrays, I think it is considered as a best practice in Damian's book 12:07
I don't think there is anything about roles because they were not implemented when I wrote the article. 12:08
grondilu If I were to change something, I would probably split the whole big section in two. One part for the differences with P5, and an other for the totally new features. 12:09
grondilu rn: my $pos = 0; for <G T A> { "ACGTACGTGACG" ~~ m:c($pos)/$_/; say $pos = $/.from; } 12:47
p6eval rakudo f81716, niecza v22-19-gd874a8e: OUTPUT«0␤0␤0␤»
moritz grondilu: don't use $_ on the RHS of ~~ 12:49
because ~~ sets $_ to the LHS
grondilu rn: my $pos = 0; for <G T A> -> $l { "ACGTACGTGACG" ~~ m:c($pos)/$l/; say $pos = $/.from; }
p6eval rakudo f81716, niecza v22-19-gd874a8e: OUTPUT«2␤3␤4␤»
grondilu indeed. Thanks
jnthn afternoon o/ 12:50
moritz \o jnthn
bowtie hi, could some please kick me in the direction some documentation on how to implement __DATA__ and extract in perl6 please 12:51
moritz bowtie: see S26, it's supposed to be done with POD directives
=for DATA or so 12:52
it mostly works, but the variables for installing the stuff aren't installed yet
bowtie moritz, thanks, but what is S26
FROGGS the tests in roast are helpful too about $=pod (DATA)
bowtie: S26 is the spec of that feature; how it should be implemented 12:54
daxim perlcabal.org/syn/S26.html
FROGGS have a look at these files: github.com/perl6/roast/blob/master...mentation/
lumi__ r: role Disposing { method dispose { say self ~ " disposed" } }; macro RAII($res, $code) { quasi { my $x = {{{$res}}}; {{{$code}}}($x); LEAVE $x.dispose } }; class C does Disposing {}; RAII C.new, -> $res { say "Processing..." } 13:06
p6eval rakudo f81716: OUTPUT«Cannot assign into a PMCNULL container␤ in at /tmp/QtyefRqAMZ:1␤ in block at /tmp/QtyefRqAMZ:1␤␤»
bowtie thanks for the info on 'Data Blocks' in S26, when I tried the examples they don't work, is that to be expected at this time 13:12
lumi__ r: macro foo($res) { quasi { my $x := {{{$res}}} } }; foo []
p6eval rakudo f81716: OUTPUT«Lexical '$x' not found␤ in at /tmp/kiHqOaE_vO:1␤ in block at /tmp/kiHqOaE_vO:1␤␤» 13:13
jnthn bowtie: I seem to recall seeing that on the roadmap, so I guess it's in need of some implementation. 13:15
bowtie jnthn, thanks for that, I will go and look at some other bit's of 6 for now :) 13:16
lumi__ So what's up with those weird errors? 13:17
Is that the blocks-in-macros thing?
jnthn lumi__: More generally, declarations in macros. 13:19
lumi__: Though I think masak knows a bit of why this happens now, so hopefully it can be fixed a bit... :) 13:20
isBEKaml [Coke]: (backlogs) I see that you had failed pugs builds. Are you on an updated GHC, by any chance? 14:33
isBEKaml weird, I can't seem to access jnthn++'s blog. 14:40
I only got back a google-cached version.
GlitchMr isBEKaml: You can read it on Planet Six 14:41
Also, I can read jnthn's blog...
isBEKaml yeah, that's what I'm doing now. 14:42
but it takes a long time to load for me (too much content there...)
more weirdness: this page doesn't give me any results either -> en.search.wordpress.com/?q=6guts 14:44
I can view wordpress.com fine, though.
brrt hi #perl6 15:18
[Coke] phenny: tell isBEKaml that I'm using whatever is installed on feather. 15:34
phenny [Coke]: I'll pass that on when isBEKaml is around.
Ulti bowtie one thing to be aware of is $=pod doesn't work from compiled modules atm unless someone has fixed that in the last couple of months 15:55
tadzik good evening #perl6 18:10
diakopter o/ 18:13
[Coke] quiet today. jnthn must be recuperating after filling up the changelog. :)
PerlJam Maybe everyone is busy writing posts for the 2012 Perl 6 Advent Calendar ... 18:15
jnthn spent most of the day resting, since last night's headache turned into an everythingache by this morning. 18:16
[Coke] fluish? 18:21
jnthn I seem to lack any other flu symptoms. 18:22
PerlJam The dreaded oldage virus? :) 18:23
masak .oO( jnthn? old? ) :P 18:24
jnthn Yeah, seems a bit early for that one :P 18:26
masak old age doesn't hit until 28 or 29... :) 18:31
huf that age is certainly the "oldest" 18:32
in the sense that they complain most about being old
at least in my experience :)
PerlJam It's all downhill after age 25 ... luckily the downslope is quite a bit shallower than the upslope
daxim iunex with 30 (or 32 when counting base 2), senex with 60 (or 64)
bowtie Ulti, thanks for the heads up 19:16
masak a person has sent me an email in my role as "an author of a web-master program writen in perl6". 19:28
jnthn The word "web-master" is still used? :) 19:29
masak he's planning to write a web application (in Perl 6) that uses mysql.
he's asking about prior art and whether anything in my program is stealable.
(not sure if he's referring to November or psyde, but nevermind)
masak I have half a mind to just refer him to github.com/tadzik/zblog -- any other suggestions? 19:30
tadzik well, źblog is hardly a good example of a proper web application :) 19:30
tadzik but probably is a short, useful example 19:32
masak it's small. it uses Bailador and DBIish. it works.
tadzik true 19:33
masak sent a short, working reply :) 19:36
sorear o/ 19:53
masak sorear! \o/
masak 'night, #perl6. 20:25
colomon \o
felher jnthn++ # latest blog post 21:10
felher r: say << a b c d 'ab cd' >>.perl; 23:44
p6eval rakudo f81716: OUTPUT«(("a", "b", "c", "d"), "ab cd")␤»
felher Not what i expected. Is this correct? 23:46
r: << a b c d e 'ab cd' >>.tree>>.say
p6eval rakudo f81716: OUTPUT«ab cd␤a b c d e␤»
sorear not really correct but not really wrong either 23:47
.tree is one of those "I know what I'm doing" buttons 23:48
I don't think you're supposed to care about parcel layout except in some specific cases, like zip operators
felher sorear: okay, thanks :) 23:49