»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo: / pugs: / std: | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by Juerd on 28 August 2009.
00:01 payload joined 00:04 lanny left 00:10 envi^office joined, quietfanatic left 00:12 rhr_ left 00:23 Lichtkind left, eternaleye left 00:24 eternaleye joined 00:38 kidd left 00:40 ayrnieu joined 00:48 Chillance left 00:59 hercynium joined 01:08 eternaleye left 01:13 eternaleye joined 01:16 orafu left, orafu joined 01:26 wknight8111 left 01:42 Gratz474 left 01:56 TiMBuS joined
ShaneC perl6: our $foo = 'a'; eval q~say $foo~; 01:56
p6eval sprixel 28613: OUTPUT«execute(): execute error: TypeError: Cannot call method 'call' of undefined at sprixel.pl line 89.␤» 01:57
..rakudo 1ca164: ( no output )
..pugs: OUTPUT«a␤»
..elf 28613: OUTPUT«/home/p6eval/pugs/misc/STD_red/match.rb:117:in `block in to_dump0': undefined method `to_dump0' for nil:NilClass (NoMethodError)␤ from /home/p6eval/pugs/misc/STD_red/match.rb:117:in `map'␤ from /home/p6eval/pugs/misc/STD_red/match.rb:117:in `to_dump0'␤ from
../home/p6eval/pugs/misc/S…
ShaneC my $foo = 'a'; eval q~say $foo~;
perl6: my $foo = 'a'; eval q~say $foo~;
p6eval sprixel 28613: OUTPUT«execute(): execute error: TypeError: Cannot call method 'call' of undefined at sprixel.pl line 89.␤»
..pugs, rakudo 1ca164: OUTPUT«a␤»
..elf 28613: OUTPUT«/home/p6eval/pugs/misc/STD_red/match.rb:117:in `block in to_dump0': undefined method `to_dump0' for nil:NilClass (NoMethodError)␤ from /home/p6eval/pugs/misc/STD_red/match.rb:117:in `map'␤ from /home/p6eval/pugs/misc/STD_red/match.rb:117:in `to_dump0'␤ from
../home/p6eval/pugs/misc/S…
ShaneC why does the 'my' version work but the 'our' doesnt? 01:58
01:58 ihrd joined
ShaneC ah nm, pugs gets it right, guessing it's a rakudo thing then 02:00
marines 02:02
02:08 ShaneC left 02:14 eternaleye left, eternaleye joined 02:15 am0c joined, ayrnieu left 02:22 ihrd left
diakopter TimToady: std/viv bug: repeat aaa until/while condition - doesn't preserve whether it was 'until' or 'while' 02:27
02:37 zaphar_p1 left
diakopter std: my $x=0; repeat { say $x } while(3) # space not required between while and (3) ? 03:24
p6eval std 28613: OUTPUT«ok 00:02 103m␤»
pugs_svn r28614 | diakopter++ | [sprixel] implement print 03:33
r28614 | [sprixel] implement statement_control__S_repeat
r28614 | [sprixel] implement statement_control__S_until
r28614 | [sprixel] restore "not yet implemented" error message for primary nodes
diakopter TimToady: in the following, only the 'i' comes through in the ast - 03:39
std: /hi/ 03:40
p6eval std 28613: OUTPUT«ok 00:02 96m␤»
diakopter std: /[/]/ # unending recursion hilite TimToady 03:45
p6eval std 28613: OUTPUT«Deep recursion on subroutine "Cursor::_BRACKETr" at STD.pm line 41532.␤Deep recursion on subroutine "Cursor::_BRACKETr" at STD.pm line 41953.␤Deep recursion on subroutine "STD::panic" at STD.pm line 41950.␤»
diakopter wow. I left that running in another window, and now my linux VM will apparently be unswapping forever... 03:51
03:57 quietfanatic joined 04:11 tak11 left 04:25 abbe joined 04:30 zloyrusskiy joined
diakopter makes like a control exception and returns 04:46
04:46 bionoid left
crythias git r under ctrl 04:46
sjohnson get 04:48
heheh
04:48 abbe left
sjohnson sorry, writing "get" was actually a typo 04:49
now i look stupid. oops 04:50
04:52 justatheory left 04:53 alanhaggai joined 04:54 bionoid joined 04:55 bionoid is now known as Guest1287
diakopter NOOPS DNA KROF 04:56
05:07 nihiliad left 05:10 patspam joined 05:12 eternaleye_ joined 05:13 eternaleye left 05:29 abbe joined 05:41 jferrero joined 05:43 crythias left, patspam left
pugs_svn r28615 | lwall++ | [STD] 05:44
r28615 | /abc/ now includes a and b atoms in match/ast
r28615 | /[/]/ no longer recurses forever
r28615 | repeat while/until now requires ws after keyword
05:44 patspam joined, jferrero left 05:45 jferrero joined, jferrero left
diakopter whee 05:45
std: wait while fork 05:52
p6eval std 28615: OUTPUT«ok 00:03 97m␤»
06:07 alanhaggai left
diakopter sprixel: wait while fork 06:07
p6eval sprixel 28615: ( no output )
diakopter heh
06:08 ssm joined 06:10 kcwu left
pugs_svn r28616 | diakopter++ | [sprixel] finish implement repeat while/until thanks to ++TimToady 06:13
Caelum the parrot rakudo pulls with --gen-parrot is a bit older than the current one right? 06:32
moritz_ Caelum: right 06:33
Caelum thank you
06:36 jrtayloriv left 06:38 rfordinal joined, jrtayloriv joined 06:48 mikehh left
carlin say ^.^methods 06:50
rakudo: say ^.^methods # oops
p6eval rakudo 1ca164: OUTPUT«0123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120␤»
moritz_ rakudo: say +undef.^methods
p6eval rakudo 1ca164: OUTPUT«121␤» 06:51
abbe carlin: i replied to your mail.
carlin abbe: Oh, thanks :-) I'll fix that now 06:52
Caelum what am I doing wrong here: scsys.co.uk:8001/34582
abbe you're welcome carlin .
pugs_svn r28617 | carlin++ | [t/spec/S02-magicals/config.t] Fix the FreeBSD test, the OS name should be in lowercase. Thanks to abbe++ for confirming. 06:53
Caelum it only counts the first number 06:54
moritz_ for $fh.lines -> $num 06:57
.get just returns one line
06:57 rfordinal left
pugs_svn r28618 | moritz++ | [t/spec] fudge two new tests for rakudo 06:58
06:58 jferrero joined
Caelum moritz_: works, thank you :) 07:01
I'm reading szabgab.com/talks/perl6/index.html which is no longer accurate 07:02
07:17 mariuz joined 07:20 Guest1287 is now known as bionoid, patspam left 07:22 iblechbot joined 07:32 SmokeMachine left 07:40 mikehh joined
Caelum so "foo" xx 3 always makes a list 07:41
moritz_ right 07:42
and $thing x 3 always makes a Str
07:47 rfordinal joined 07:53 rgrau joined 07:58 NorwayGeek left
pugs_svn r28619 | Darren_Duncan++ | Spec S03 : added cases where a Range is considered empty 08:00
08:03 xenoterracide left, xenoterracide joined
Caelum you can't do, %foo{$word}++ for @words -> $word; that kinda sucks 08:05
moritz_ Caelum: I think prefix:<++> might work 08:07
++%foo{$word}
Caelum nope, though $_ works, just like in perl5 :) 08:08
moritz_ oh, that's what you mean 08:09
moritz_ thought the autovivification didn't work
08:11 alanhaggai joined 08:13 am0c left
Caelum wow, rakudo is incredibly slow 08:18
29s to count words in a file, versus 0.02s in perl5 08:19
moritz_ yes, 3 orders of magnitude is currently the usual difference :( 08:20
sjohnson *sad face* 08:32
i think speed might be a by product in SMOP
Matt-W There will be speed 08:36
But functionality first
moritz_ has large hopes in the PCC refactoring 08:37
Matt-W That's going to be a big help
moritz_ and in the signature binding thing that jnthn++ is going to re-work
Matt-W PCC is currently a big source of slow
I believe pmichaud++'s PGE rework should also lead to speedups 08:38
moritz_ jnthn: speaking of which, did you get any update on your Hague grant? was it accepted?
Matt-W: yes, but mostly parsing speedup, not so much runtime (except maybe when matching user-defined regexes)
Matt-W but still, parse/compile is a significant hit on startup at the moment 08:42
just witness the massive difference in performance if you precompile your modules 08:43
not runtime performance, but time before it does something
08:44 dakkar joined 08:46 rfordinal left, NorwayGeek joined 08:48 abbe left
sjohnson im actually willing to sacrifice speed for functionality, if it's not speed-critial 09:05
critical
09:14 eternaleye_ left 09:17 pmurias joined 09:34 pmurias left 09:40 masak joined 09:50 am0c joined
carlin github.com/carlins/mwbot # release early ... but maybe not this early, oh well 10:02
masak carlin++ # cool! 10:05
Caelum szabgab.com/talks/perl6/perl6-class...tance.html <-- is there really no $self->next::method like equivalent? 10:06
masak possible combinable with what MediaWiki syntax parser November has already.
carlin Oh cool 10:07
carlin takes a look
I want to get it functional enough to get it doing a bot task on Wikipedia
masak Caelum: I'd use nextsame() for that. I think that's correct.
Caelum ahh cool :) 10:08
Matt-W nextsame() goes to the next candidate in multi dispatch 10:11
masak rakudo: class Point { has ($.x, $.y) is rw; method reset { $!x = $!y = 0 } }; class Point3D is Point { has $.z is rw; method reset { $!z = 0; nextsame } }; my $p = Point3D.new(:x(23), :y(42), :z(12)); say [.x, .y, .z].fmt given $p; $p.reset; say [.x, .y, .z].fmt given $p
p6eval rakudo 1ca164: OUTPUT«23 42 12␤0 0 0␤»
masak Matt-W: you're not wrong.
Matt-W it would make sense if in inherited methods it goes to the parent class's
masak well, it does. see above.
Matt-W indeed
you proved it while I was typing 10:12
presumably nextwith() also works 10:13
although probably less useful in this case
masak hm, interesting. nextwith would only see a limited set of the original multies. 10:14
rakudo: class A { multi method foo(Str $) { say "A Str" }; multi method foo(Int $) { say "A Int" } }; class B is A { multi method foo(Int $) { say "B Int"; nextwith("OH HAI") } }; B.new.foo(42) 10:16
p6eval rakudo 1ca164: OUTPUT«B Int␤»
masak I guess it reaches the end of the list of candidates without finding a match, and gives up.
if jnthn were here, he could confirm.
moritz_ that does look like a bug to me 10:19
masak why?
moritz_ because it should find the multi from class A, no?
masak can I bikeshed a bit about .excl_min and .excl_max? I don't think core routines should have underscores in them, I think 'excl' is an ugly shortening of 'exclude', and I don't immediately see why we should use the negative 'exclude' instead of 'include'.
moritz_: well, think of how/when the chain of candidates is constructed. 10:20
moritz_ masak: (re bikeshedding) agreed with everything (maybe except the last one) 10:21
masak: when/how is it constructed?
masak moritz_: before the call to the narrowest one. 10:22
at that time, only the Int candidates remain.
moritz_ oh.
masak the Str variant is not a candidate.
moritz_ right
so... what would you do to dispatch to the Str candidate?
masak that's what I mean when I said 'hm, interesting. nextwith would only see a limited set of the original multies.'
moritz_: probably the .HOW.dispatch thing that szabgab did in his code. 10:23
10:27 alanhaggai_ joined
moritz_ if we get confirmation from TimToady or jnthn, that would make an excellent test case 10:28
masak TimToady might roll over the horizon soon. jnthn is probably making the best of hist last few days in .kr right now. 10:29
10:30 alanhaggai left, alanhaggai_ is now known as alanhaggai
moritz_ massak++ # " roll over the horizon", I like that 10:30
sjohnson is it okay to talk OT on this chan? 10:31
masak sjohnson: as long as people are not annoying, we tend to enjoy OT. but it's always subordinate to real Perl 6 discussion, of course.
10:32 hanekomu joined
moritz_ sjohnson: if the off-topic amount is much smaller than your overal on-topic talk, yes 10:32
masak funnily enough, discussions tend to derail into being about Perl 6. :)
sjohnson just that i get really irritated when random people on the ircs who think they are smarter than me call me an idiot
masak it's amazing how often you can turn OT talk into a one-liner which turns up a bug or an interesting corner case.
sjohnson i'm sure this has happened to everyone here at least a dozen times in their lives at one point or another 10:33
masak not on this channel, but people can be quite brusque elsewhere, yes.
moritz_ sjohnson: yes, it did. Though I tend to stay only in channels where that happens rarely or not at all
like here :-)
sjohnson yeah i have found some friendly ppl here 10:34
moritz_ many channels on irc.perl.org are also very friendly, IME
10:34 patspam joined
masak people on #bash are knowledgeable, but they also seem infinitely bored with the FAQs. they have a bot which churns out links for people asking them. and they answer a bit dismissively sometimes. 10:35
sjohnson even the perl chan is kind of mean from time to time
masak oh yes. 10:36
it's a tricky problem: how to avoid introducing hierarchical-mindedness and meanness when the community grows beyond the size of a village? 10:37
hanekomu split off into specialized subchannels. leave the original channel for the newcomers 10:38
masak en.wikipedia.org/wiki/Dunbar's_number
hanekomu so someone who wants to coach them can, but others can discuss higher-level topics somewhere else
masak yes, perhaps.
what I've always liked about #perl6 is that it's decidedly not a channel for newcomers (just as Perl 6 is more of a 'last language' than a 'first language'). the years 2005-2007 changed my programming path forever. 10:39
lunch & 10:40
moritz_ and it still embraces newcomers
I still remember my "huh?" when I suddenly had a commit bit email in my inbox
just because I went here to tell people that a link on pugscode.org was broken :-) 10:41
10:43 payload left
Caelum sjohnson: I think channels should have rules about people not being dicks, which would be enforced by people who know what that means. Maybe harder to accomplish than it sounds, I dunno 10:46
carlin meta.wikimedia.org/wiki/Don%27t_be_a_dick 10:47
Caelum wow 10:48
carlin Wikipedia; is there anything they don't have a policy for?
Matt-W Probably not 10:49
They're very good at producing policy, and then arguing about it
Or arguing about it, producing it, then arguing about it some more
carlin Or just arguing 10:51
moritz_ bikeshedding.
Matt-W Yup 10:52
I suppose their major problem is that the community's really big
moritz_ aye
Matt-W Perl 6 is still fairly manageable in that we can actually convince each other of things
moritz_ or if not, nobody really minds if Larry decides :-)
Caelum I've worked on very small projects where people are dicks too
not entirely a size isssue 10:53
Matt-W No this is true, but it's usually worse in a larger group 10:54
11:03 xinming left, xinming_ joined 11:13 NorwayGeek left 11:14 ruoso left 11:18 colomon left
masak I think smaller groups have more of a chance of producing more sustainable relations between people. it definitely helps to meet people face-to-face on YAPCs and NPWs. one is not as likely to commence a flame war with someone one's met in meatspace. 11:22
Juerd s/one\'s/once/? 11:23
moritz_ "one has met in meatspace"?
Juerd Oh 11:24
Yeah, that seems logical.
11:33 patspam left, Jedai joined
masak t/spec/S32-array/splice.t bailed out after test 26 in the spectest harness, but runs fine standalone. 11:36
but apart from that, all spectests pass. committing. 11:37
pugs_svn r28620 | masak++ | [t/spec/S32-array/delete.t] unfudged two tests for Rakudo 11:39
dalek kudo: d91717d | masak++ | src/ (2 files):
moved Array.delete to setting

hey, all the old tests pass, plus two TODO'd ones.
11:42
masak rakudo: my @a = 0..1; @a.delete(0); say @a.perl
p6eval rakudo 1ca164: OUTPUT«Null PMC access in isa()␤in method Any::map (src/gen_setting.pm:182)␤called from method List::perl (src/gen_setting.pm:1851)␤called from Main (/tmp/vKCPJWlRpW:0)␤»
masak guess I should wait a while. 11:43
11:44 colomon joined, jrtayloriv left 11:45 jrtayloriv joined 11:46 NorwayGeek joined
moritz_ rakudo: my @a = 0..1; @a.delete(0); say @a.perl 11:49
p6eval rakudo 1ca164: OUTPUT«Null PMC access in isa()␤in method Any::map (src/gen_setting.pm:182)␤called from method List::perl (src/gen_setting.pm:1851)␤called from Main (/tmp/CYRNRg6jLr:0)␤»
moritz_ it should have rebuilt at 13:45
masak it works locally. 11:50
colomon Huh. Any ideas why "git pull" has stopped working for me on Rakudo? It's saying "You asked me to pull without telling me which branch you want to merge with," but that never was an issue before? 11:53
colomon should have known better than to reboot his MBP. (79 days uptime before reboot.)
masak colomon: I've not fully figured out that part of git-pull yet. but 'git pull origin master' should do what you want.
colomon: mine's up 100 days today. :) 11:54
Juerd Speaking of uptime. Feather's almost at 200 days.
moritz_ colomon: what does 'git branch' say?
colomon masak: Thank you, that worked.
Juerd So you guys have been treating it well for a while now :)
colomon Oh, * is pointing to "no branch".
git checkout master?
bingo 11:55
masak there you go.
Juerd Oh, and feather0, the actual computer, is at 359 days
slavik2 masak/moritz: how much of spec does rakudo implement?
Juerd >1 year :)
slavik2 Juerd: week short :P
colomon must have been while I was messing around with Lanny's patch yesterday.
Juerd Oh, right, it's 365, not 356 per day.
moritz_ slavik2: "a good chunk", but we have no real numbers on that one
Juerd <1 year :(
moritz_ <3 years :-) 11:56
Juerd Heh
slavik2 moritz_: fair enough ... I am still waiting for assertions in grammars :P and there was some other thing that was not implemented for smart matchers ...
moritz_ slavik2: assertions in grammars might come soonish, when pmichaud++ finishes his work of refactoring PGE 11:57
slavik2 pmichaud: chop chop :P
masak slavik2: yes, but it's spelled 'pmichaud++ # keep up the good work!' :P 11:58
slavik2 pmichaud++ # keep up the good work!
:)
12:01 rgrau left
slavik2 masak: any idea if zip works on a list of objects? 12:03
masak sure, why not?
slavik2 I submitted that as a bug long time ago
masak URL?
slavik2 zip would not work on a list of matcher objects
masak oh, Match objects.
slavik2 can't find it in rt
masak no, those are known to be wonky. 12:04
slavik2 aww
:(
masak better to convert their contents to something else and zip on that.
slavik2 my %hash = $/<blah> Z $/<glah>; #this does not work
masak I'm not surprised. 12:05
Don't Do That, Then.
12:05 envi^home joined
slavik2 :( 12:05
carlin doctor, doctor it hurts when I do this!
moritz_ well yes, list context on match objects is a bit broken, I think
masak slavik2: you're an early adopter; this is what it's like. :) remember that you'll still get the reward of being the first to do many things. 12:06
slavik2 I know
I am an early adopter, because I can't wait any longer
masak slavik2: there's also a certain sense of satisfaction in working around things.
slavik2 hmm, I am also thinking of submitting "absence of Programming Perl6" as a bug ... 12:07
12:07 NorwayGeek left 12:08 iblechbot left
masak I still want to write something. I'd be happy to pair up with someone for great justice. my idea is producing 5 or so mid-sized Perl 6 programs, each of which shows off the strengths of Perl 6 in some way. 12:09
moritz_ raises hand
masak moritz_: you're on.
slavik2 I wrote a grammar example
masak the book can easily be collaboratively written using a wiki or Google Docs or something.
slavik2 except now it doesn't work :(
bcacm.org/~slavik/ 12:10
moritz_ or a github repository :-)
moritz_ doesn't really like wikis for writing larger stuff
Matt-W would find some tuits for help
slavik2 so, I have some perl6 code that worked way long ago, but is broken now ... 12:11
it doesn't output anything
moritz_ masak: I'm kinda busy tonight and tomorrow, but maybe we could organize a brainstorming IRC meeting for Wednesday evening (GMT-zone evening, that is)?
slavik2 why not take the spec and write code samples? 12:12
moritz_ because the spec is more of a reference
masak moritz_: I'd like that. 12:13
slavik2 hmm, then take key points from each "chapter" and write code samples?
moritz_ shall we say 18H UTC?
slavik2 today?
moritz_ Wednesday
moritz_ busy tonight 12:14
table tennis needs to be played :-)
Matt-W heh 12:21
my usual table tennis partner is off work
moritz_ training tonight, match tomorrow, match on Thursday :-) 12:22
12:26 jaldhar left
Matt-W :) 12:26
recorders tonight, taking the cat to the vet tomororw (Then aikido if there's time), gaming on wednesday, viols on thursday, aikido on friday... 12:27
I'll just keep an eye on what you're writing and complain about your grammar
moritz_ as long as you also fix it, that's great :-) 12:29
12:31 takadonet joined
takadonet morning all 12:31
moritz_ \0/
12:32 meppl joined
slavik2 Matt-W: how is aikido? 12:37
masak moritz_: Wednesday 18:00 UTC works great.
moritz_ \𝚯/ 12:38
masak :) 12:39
rakudo: my @a = 0..1; @a.delete(0); say @a.perl 12:40
p6eval rakudo d91717: OUTPUT«[undef, 1]␤»
masak closes ticket 12:41
colomon masak: shouldn't that be my @a = 0...1; now? 12:42
moritz_ ranges still listify in list context 12:43
you need series for more fancy stuff, though
colomon Do ranges still have by?
masak no.
colomon that's a step in the right direction, then! :) 12:44
moritz_ happily deleted quite a few tests over the weekend 12:45
but under the storm of colomon++'s new tests nobody really noticed
colomon the sad thing is, there's still an entire way of calling trig functions not yet tested (because it's in the spec but NYI). 12:46
moritz_ the one with the enum? 12:47
colomon yes
you're supposed to be able to set $?TRIGBASE (or whatever the sigil is) to change the base as well as doing it on a call-by-call basis.
12:48 jaldhar joined
moritz_ $<[?*!^]>TRIGBASE :-) 12:48
12:48 jaldhar left
colomon it will be easy enough to add the tests for that, but it will bump up the number of trig tests again. 12:49
12:49 jaldhar joined
colomon hmmm.... 12:49
rakudo: say pi.sin(:base("degrees"))
p6eval rakudo d91717: OUTPUT«1.22464679914735e-16␤»
moritz_ well, one call for each function and base should be enough 12:50
colomon that case isn't tested either. (and obviously it doesn't work).
moritz_ assuming the value is semi-random
colomon Hmmm... that's a good idea for refactoring a bit, actually.
moritz_ yes, calling positional params by name isn't implemented
colomon I thought it would fail instead of just ignoring the param. 12:51
moritz_ method calls generally ignore superfluous named arguments 12:52
12:52 kcwu joined
colomon that seems icky 12:54
doesn't it mean typos for optional named arguments will be silently ignored?
moritz_ yes :(
colomon or is that just a rakudo bug?
moritz_ no, it's a specced feature 12:55
12:55 jaldhar left
colomon that seems very odd.... 12:55
12:55 jaldhar joined
moritz_ TimToady had some good reasons for it, but I'm still not sure if it's worth it 12:56
13:02 frederico joined 13:06 SmokeMachine joined 13:07 zloyrusskiy left
slavik2 angry russian left ... 13:08
13:08 jaldhar left
Matt-W moritz_: I'm not either 13:11
13:13 jaldhar joined 13:18 jaldhar left
carlin needs to parse either JSON, XML or YAML ... hm ... 13:21
13:23 jaldhar joined
masak carlin: check out moritz_++'s JSON grammar. 13:24
github.com/moritz/json
carlin masak: Oh cool :-) Thanks 13:25
13:25 pmurias joined 13:27 nihiliad joined 13:35 PZt left, iblechbot joined 13:40 jaldhar left
carlin \o/ I think I've got JSON::Tiny figured out. moritz_++ 13:43
13:43 jaldhar joined
masak that's great. reuse rocks! 13:43
13:49 jferrero left
moritz_ and viklund++, he applied those fixes that made it pass its tests :-) 13:49
13:50 jferrero joined 13:51 TheHatter joined, jaldhar left 13:55 TheHatter left 13:56 mberends joined 13:57 PacoLinux joined 14:01 payload joined
mberends diakopter: which sprixel functions should I now try to spectest manually? 14:05
phenny mberends: 04 Oct 21:57Z <diakopter> tell mberends I'm redoing the entirety of sprixel's builtins in Perl 6 (with embedded JS for some things) after I redo the interpreter engine to treat everything as an .invoke(), with proper captures and signatures and the like.
mberends aha. never a dull moment :) 14:06
pmichaud good morning, #perl6 14:08
moritz_ good localtime pmichaud
mberends good day pm
Matt-W oh hai pmichaud 14:09
14:19 crythias joined
masak hi pmichaud++ 14:20
14:21 Psyche^ joined 14:23 jaldhar joined 14:33 jaldhar left 14:38 Patterner left, Psyche^ is now known as Patterner
pugs_svn r28621 | pmurias++ | [mildew-js] Code uses the m0ld block from re-smop Code 14:39
masak carlin: I added your mwbot to proto's projects.list. you already have a proto commit bit, I see.
14:40 Woody2143 joined
carlin masak: Thanks :-) The name will probably change at some point though 14:40
masak then you'll even have use for your commit bit. :) 14:41
14:41 jaldhar joined 14:42 xinming joined
carlin heh yeah, outside of that and the tab-completion I don't think I could help much with proto 14:43
moritz_ every small bit is very welcome. 14:44
oh, and writing projects helps us to exercise proto :-)
14:47 iblechbot left 14:51 NorwayGeek joined, TiMBuS left, _jaldhar joined
carlin gist.github.com/202158 # and the output: gist.github.com/202159 14:52
\o/
moritz_ \o/ indeed 14:53
carlin++
carlin moritz_++ and viklund++ # JSON::Tiny++ 14:55
14:55 _jaldhar left
Matt-W carlin++ 14:56
that's neat
14:58 _jaldhar joined
masak carlin++ # today's cool script 14:58
14:58 jaldhar left 15:00 xinming_ left 15:02 crythias left 15:03 Eevee joined, payload left 15:04 _jaldhar left, payload joined, alanhaggai left 15:05 _jaldhar joined
diakopter mberends: repeat while/until 15:05
and all the other control structures 15:06
mberends diakopter++: great! limited connectivity this week so I may have to batch lots of updates offline. 15:07
carlin I think I'll leave making MWBot.pm use JSON::Tiny until after I've slept. 'Night all.
15:07 lanny joined
moritz_ mberends: I can strongly recommend git-svn then :-) 15:07
diakopter carlin: 'nite
lanny colomon: you get that message from git when you aren't on a branch that is tracking anything.
15:08 KyleHa joined
mberends thank moritz_, will look into git-svn :) 15:08
lanny mberends: git-svn is really good but it doesn't handle svn props.
15:08 justatheory joined 15:09 justatheory left, NorwayGeek left, abra joined 15:10 _jaldhar left, abra left, abra joined 15:11 abra left 15:12 abra joined, abra left 15:13 abra joined, pmurias_ joined, abra left 15:14 abra joined 15:16 mberends left, bionoid left
diakopter pmurias: you around? 15:19
15:23 ruoso joined
diakopter afk& 15:26
15:29 pmurias left 15:30 PZt joined
pugs_svn r28622 | lwall++ | [S03] dehuffmanize excl_* slightly to emphasize boolean nature to reader 15:32
r28622 | [S32] add i as constant
15:32 iblechbot joined 15:33 _jaldhar joined 15:36 zaphar_ps joined 15:39 jferrero left 15:40 jferrero joined, NorwayGeek joined, kidd joined, _jaldhar left 15:41 _jaldhar joined 15:43 pmurias_ is now known as pmurias
pmurias diakopter: pong 15:43
ruoso: hi 15:44
15:44 dakkar left, rfordinal joined
pugs_svn r28623 | pmurias++ | [re-mildew] some refactoring 15:52
15:53 alanhaggai joined 15:57 rfordinal3643 joined 15:58 rfordinal left
diakopter pmurias: I was curious why your dispatch uses the non-mangled 'infix<blah>' as the identifiers instead of STD's mangled editions? 15:59
15:59 alfieANDfred joined
diakopter (was that a decision you made or is there something inherent in smop/mold that requires that) 15:59
pmurias diakopter: why should i mangle my identifiers? 16:01
if i mangled them i would have to unmangle them when i want to display them 16:02
diakopter: does newer STD mangle identifiers by default? 16:04
diakopter: by mangled editions you mean the ones with special characters replaced by alphanumerics? 16:06
16:11 ejs joined 16:12 sparc left, alfieANDfred left
lanny rakudo: class Foo { has @!nums = 2,3,4; method postcircumfix:<[ ]>(*@ns) { my @v = gather for @ns { take(@!nums[$_] + 1) }; @v.elems == 1 ?? @v[0] !! @v; }; }; my Foo $f .= new; $f[3].say; 16:15
p6eval rakudo d91717: OUTPUT«No such attribute '@!nums'␤in method Foo::postcircumfix:[ ] (/tmp/fiztnU3av4:2)␤called from method Foo::postcircumfix:[ ] (/tmp/fiztnU3av4:2)␤called from Main (/tmp/fiztnU3av4:0)␤»
16:16 stephenlb joined
lanny I don't find any bugs for [] losing knowledge of the objects attributes. Is this a known issue (that is tribal knowledge vs in RT). 16:16
diakopter pmurias: yes that's what I mean
TimToady I don't think I've seen that bug before 16:17
moritz_ lanny: I don't recognize it, feel free to submit
diakopter pmurias: yes, sprixel gets the ast with the names mangled
lanny ok.
diakopter (mangle.pl)
whether that's done in viv or std or cursor, I don't know 16:18
TimToady the P5 types are mangled by necessity, but if we provided a link into the symbol table, the key there would be unmangled
the unmangled name should certainly be made available one way or another 16:19
16:20 cdarroch joined
diakopter std: wait while fork 16:20
p6eval std 28623: OUTPUT«ok 00:01 97m␤»
TimToady well, Str on the correct node gives back the unmangled form 16:21
diakopter ok.. ToJS.pm could do that
pmichaud lanny: rakudo doesn't like that formulation because the default postcircumfix:<[ ]>(Int) is more specific than the method defined in Foo
16:22 stephenlb left
diakopter but stabs linked to nodes would be great too :) 16:22
or at least their identifiers
the pads' identifiers, I mean
pmichaud i.e., I'm not sure what the call chain there should look like
16:23 stephenlb joined
pmichaud rakudo: class Foo { method postcircumfix:<[ ]>($x) { say $x; } }; my Foo $f .= new; $f[3]; 16:25
p6eval rakudo d91717: OUTPUT«3␤»
lanny grr. I've been playing with signatures for a while now. Spec suggests that *@@slice is the correct sig 16:26
16:27 masak left
lanny rakudo: class Foo { has @!nums = 2,3,4; method postcircumfix:<[ ]>($ix) { @!nums[$ix]}; }; my Foo $f .= new; $f[3].say; 16:27
p6eval rakudo d91717: OUTPUT«No such attribute '@!nums'␤in method Foo::postcircumfix:[ ] (/tmp/V7vyWpXmYU:2)␤called from method Foo::postcircumfix:[ ] (/tmp/V7vyWpXmYU:2)␤called from Main (/tmp/V7vyWpXmYU:0)␤»
lanny However...
pmichaud rakudo: class Foo { has $!x = 4; method postcircumfix:<[ ]>($y) { say $!x; } }; my Foo $f .= new; $f[3]; 16:28
p6eval rakudo d91717: OUTPUT«4␤»
pmichaud ohhhhh, I know the problem. 16:29
TT #389
moritz_ which desugars to trac.parrot.org/parrot/ticket/389 ;-) 16:30
lanny Thanks. :)
16:30 ejs left
pmichaud because methods are automatically entered into the namespace, and because Parrot's IMCC compiler automatically short-circuits name lookups when there's a same-named method in the compilation unit, the @!num[...] call is thinking that @!num is an instance of Foo 16:30
s/same-named method/same-named sub/
moritz_ (the IRC logs advertised in the /topic also turn TT #389 into a link) 16:31
16:31 NorwayGeek left
lanny The sub named '[ ] 16:31
moritz_ I sometimes use them for following links, even when I have no need to backlog ;-)
lanny '[ ]'?
16:31 NorwayGeek joined, xinming_ joined
pmichaud this is a bit tricky to explain, but here goes 16:32
the method declaration produces
.namespace ['Foo']
lanny sits closer to the campfire.
pmichaud .sub 'postcircumfix:[ ]' :method
... code for method
... code for @!nums[$ix] looks like:
$P0 = getattribute self, '@!nums'
'postcircumfix:[ ]'($P0, $ix) 16:33
....
okay so far?
lanny Yep. I'm with you.
pmichaud okay, there are two bugs at play
first, the Parrot sub itself gets entered into the ['Foo'] namespace 16:34
lanny That was even my first thought but then figured that @num would have been handled by Array.pcf<[ ]>
pmichaud i.e., Parrot currently treats all methods as being automatically exported into the namespace
the second bug is that Parrot automatically short-circuits any function call lookups if there's a same-named sub in the current namespace
so that call to 'postcircumfix:[ ]'($P0, $ix) ends up being recursive
and then complains that @!num doesn't have a @!num attribute 16:35
lanny Makes sense.
moritz_ but why is 'postcircumfix:[ ]' called as a sub, not as a method?
pmichaud moritz_: hll interop
moritz_ pmichaud: ok
pmichaud if we're dealing from objects from another world, they don't have a "postcircumfix:[ ]" method
so we currently do postcircumfix:[ ] as a function call, and that call takes care of dispatching as a method or going through the vtable interface 16:36
TimToady seems like it's something that should be translated when one dispatcher delegates to a different language's dispatcher 16:37
and not before that
pmichaud I'm not sure that I follow
TimToady I think parrot is making probably making unwarranted assumptions about the various language's dispatchers here 16:38
pmichaud I follow that and agree. :)
16:39 iblechbot left
pmichaud parrot hasn't completely come to grips with the idea of per-language dispatchers 16:39
at any rate, the fix here is probably for Rakudo to have a private function that handles postcircumfix:[ ]
and to call that function something other than postcircumfix:[ ] 16:40
TimToady and a p6 single dispatch may want to delegate to a different foreign mechanism than a p6 function call would
pmichaud in fact, I suspect that if I simply renamed it to !postcircumfix:[ ] then this issues would go away
*issue
TimToady so coalescing the dispatchers into one API feels wrongish
16:40 justatheory joined
pmichaud TimToady: btw, I think that you'll be pleased to know that the regex and tools refactor is eliminating the angle-less names :) 16:42
TimToady the reason p6 gets away with making everything a function call underneath is that we can track which dispatcher is invoking us; the parrot approach seems like a bottleneck on that from your description
pmichaud: :D
16:42 mspauldi1g left
ruoso trying to review pmichaud's notes on S08 16:42
TimToady :D xx *
pmichaud TimToady: yes, I agree that the parrot approach bottlenecks things; I haven't found an alternative yet 16:43
given $x[...]
I'm not sure what code to generate to handle the postcircumfix
if we generate
$x."postcircumfix:<[ ]>"(...)
16:43 mariuz left
pmichaud that somewhat depends on the target $x (which could be a foreign object) understanding the "postcircumfix:<[ ]>" method 16:43
TimToady unless the dispatcher does the translation at delegation time 16:44
pmichaud which dispatcher?
ruoso is the irclog down?
TimToady the . dispatcher
pmichaud right
TimToady the one that understands nextsame :)
pmichaud so then the p6 dispatcher needs a way to map p6-named methods into Parrot's underlying vtable interface? 16:45
TimToady the one that sees that the next candidate is off in lala-land, and translates the call to lala-ese
moritz_ ruoso: it was over the weekend
pmichaud the notes I linked to were from a week or so ago
ruoso not being able to reach it right now 16:46
pmichaud anyway, I fully admit that our current postcircumfix:<[ ]> handling is hackish, but I haven't come up with a better way to deal with non-Rakudo objects 16:48
TimToady the single dispatcher will need to be taught somehow so that you are not tempted to use the wrong dispatcher 16:49
pmichaud that makes sense
especially since it means I throw it over to jnthn++ for now :)
TimToady wfm :)
16:50 xinming left 16:51 kidd left
TimToady Juerd: if feather has been up for a year, it almost certainly means there are known security vulnerabilities you haven't patched. :) 16:54
pmichaud TimToady: over the weekend while working on regex engine, I came across a place where Regexp::Grammar's <MATCH=xyz> syntax could be useful. Is there a p6 equivalent? Is it just $/=<xyz> ? 16:55
16:55 jferrero left 16:56 szabgab joined
TimToady it'd be something more like { $¢ = $<xyz> }, assuming $<xyz> is a Cursor 16:57
but that might screw up in other ways 16:58
pmichaud yeah, that doesn't seem exactly the same
the example from Regexp::Grammars would be something like <left_paren> <MATCH=expr> <right_paren>
TimToady anyway, the invariant is that the return of the rule has to be a Cursor, but the Cursor nature doesn't care which match nature it carries along 16:59
pmichaud which returns the result of <expr> as the match object, but still does the tests for left_paren and right_paren
return of rule always being Cursor is working out very well for me, btw
moritz_ wouldn't that just be <( expr )> ?
TimToady well, that's just <.left_paren> <expr> <.right_paren>, except for the expr nesting 17:00
moritz_ but we have no way to inline the expr call, right?
pmichaud moritz_: I want to capture more than just the text -- I think that <( and )> only set the from/to points of the match
what <MATCH=expr> does is say *this* is my match object
i.e., it hoists a subrule's match object to be the match returned from the current rule 17:01
TimToady but which current pos do you advertise as the result?
pmichaud (technically: the match contained in the cursor returned from the current rule)
I think the cursor pos is still at the end of <right_paren>
17:01 hercynium left
pmichaud I'm not sure what Regexp::Grammars does there -- might need to play with it a bit or ask TheDamian 17:02
ruoso TimToady, why would "my $x = (1, (2, 3))" flatten?
pmichaud anyway, not pressing at the moment, but I might come back and ask about the feature again
(and others have asked me about it as well)
TimToady it feels/smells like include semantics 17:03
17:03 pmurias left
TimToady ruoso: I don't know, why would it? 17:03
17:03 quietfanatic left
ruoso TimToady, you said it would 17:03
:)
TimToady when? 17:04
pmichaud TimToady: irclog.perlgeek.de/perl6/2009-09-23#i_1532822 17:05
moritz_ everything you say can and will be used against you ;-) 17:06
TimToady I did threaten to change my mind the next day. How do you know I didn't? :)
pmichaud We don't. Thus the question. :)
17:08 hanekomu left
pmichaud I've just decided to leave links in the synopses to clarifying points from irc conversations (or mailing list items) 17:08
so that someone remembers to go and verify or clean up the synopsis point, and so that people reading the synopsis are aware of things "under discussion"
17:08 eternaleye joined
pmichaud afk, lunch for me 17:10
17:12 envi^home left 17:19 hercynium joined 17:20 cotto left
jnthn hi folks 17:26
Back home.
Mostly needing sleep. 17:27
Will be back onto Rakudo things tomorrow.
17:27 Chillance joined 17:34 alanhaggai left 17:41 NorwayGeek left 17:42 japhb left
pmichaud jnthn: wb 17:46
jnthn: get rest :)
jnthn pmichaud: Yes, will do. 17:48
17:53 NorwayGeek joined 17:57 fridim joined
Juerd TimToady: Regarding feather I only care about known *remote* vulnerabilities :) 17:57
TimToady: I work under the assumption that feather can crash or be compromised at any time. 17:58
slavik2 feather? 18:02
diakopter Camelia lost her feathers 18:03
TimToady pmichaud: I'm considering that, for symbol table keys, operator names should not canonicalize to :<> form but rather all the way to mangled form
this would enhance language interop, I think
so instead of cicumfix:<\< \>> it would it would be circumfix__S_Lt__Gt or some such 18:06
pmichaud is there a canonical mangled form, then?
TimToady STD currently uses src/perl6/mangle.pl
pmichaud yes, but is that going to be "spec" ? ;-) 18:07
TimToady that's what I'm asking myself
pmichaud by "language interop" you're referring to interoperability among ... ?
TimToady mangle.pl isn't quite right, since it doesn't distinguish <a b> from <ab>
how a Python program might call a Perl operator
pmichaud got it
TimToady since we need to canonicalize symbol table keys anyway 18:08
and decanonicalize for readability sometimes
and assuming our mangling is round-trippable
mapping to standard identifiers seems friendlier to other cultures 18:09
oh wait, it does distinguish those already 18:11
18:11 xinming joined
TimToady :<[ ]> is S_Bra_Ket, whild :<[]> is S_BraKet 18:11
*whilst 18:12
almost certainly STD is borken wrt symtab canonicalization of ops 18:14
std: my sub infix:<XX> () {...}; my sub infix:«XX> () {...} 18:15
p6eval std 28623: OUTPUT«===SORRY!===␤(Possible runaway string from line 1)␤Malformed block at /tmp/K7mOxGlcz0 line 1 (EOF):␤------> XX> () {...}; my sub infix:«XX> () {...}⏏<EOL>␤ expecting escape␤FAILED 00:03 107m␤»
TimToady std: my sub infix:<XX> () {...}; my sub infix:«XX» () {...}
p6eval std 28623: OUTPUT«ok 00:02 102m␤»
TimToady shoulda caught that
18:17 japhb joined
TimToady course, by that argument, we should mangle the sigils too 18:19
slavik2 I have a grammar example I wrote long time ago, it doesn't work anymore (no output at all).
lanny class Foo { has @.xs; method Str { "{@.xs}" }; }; my @ys = 2,3,4; my Foo $f .= new(:stuff(@ys)); $f.say; 18:20
rakudo: class Foo { has @.xs; method Str { "{@.xs}" }; }; my @ys = 2,3,4; my Foo $f .= new(:stuff(@ys)); $f.say;
p6eval rakudo d91717: OUTPUT«␤»
lanny Should there be a warning there about 'no attribute :stuff'?
rakudo: class Foo { has @.xs; method Str { "{@.xs}" }; }; my @ys = 2,3,4; my Foo $f .= new(:xs(@ys)); $f.say;
p6eval rakudo d91717: OUTPUT«2 3 4␤»
18:22 cxreg2 is now known as cxreg
pugs_svn r28624 | diakopter++ | [STD setting] parse setting files with names containing CORE with the NULL setting 18:26
jnthn lanny: The signature of that just takes a slurpy hash. 18:27
(of the default new)
lanny ok. 18:28
18:28 stephenlb left
colomon I actually ran into the same thing with sin today: 18:28
rakudo: say pi.sin("degrees");
p6eval rakudo d91717: OUTPUT«0.0548036651487895␤» 18:29
lanny neat
colomon rakudo: say pi.sin(:base("degrees"));
p6eval rakudo d91717: OUTPUT«1.22464679914735e-16␤»
18:29 xinming_ left, stephenlb joined
lanny Odd. Why did "degrees" work. I would have thought at the least you'd get something like 'Str can't be Num' 18:30
colomon using named positionals doesn't work in rakudo right now, I guess, and extra parameters in the slurpy hash are ignored, so the :base is ignored.
lanny ah, ok.
colomon lanny: all the trig methods take an optional parameter which specifies the base to use.
which is why the first one works. 18:31
the second, in theory, should do the same thing, but instead it silently ignores the parameter.
lanny Ah got it.
Ok. Next up is...
TimToady fix is waiting on parrot fix, expected in a week or so, I believe
lanny rakudo: my $q = 5; my @cf = gather while $q > 0 { $q.say; take($q); --$q; }; ";;{@cf}".say; 18:32
p6eval rakudo d91717: OUTPUT«5␤4␤3␤2␤1␤;;0 0 0 0 0␤»
colomon (In theory it should be an enum rather than a string, but when I tried adding the enum a few weeks back all of rakudo blew up.)
lanny, that's a known gather / take bug.
lanny ah. Darn me. That's what I get for getting tired of looking in RT before I speak. :)
colomon I'm with you all the way, I hate trying to look stuff up in RT. 18:33
you can get around it by doing something which forces a copy of the value. 18:34
rakudo: my $q = 5; my @cf = gather while $q > 0 { my $qq = $q; $qq.say; take($qq); --$q; }; ";;{@cf}".say; 18:35
p6eval rakudo d91717: OUTPUT«5␤4␤3␤2␤1␤;;5 4 3 2 1␤»
colomon TimToady: moritz_ implied (earlier today) there is a good reason named parameters which are not actual parameters are ignored? 18:36
diakopter Use of uninitialized value $b in numeric gt (>) at viv line 499. 18:37
lanny colomon: yes. was using take(my $v=$q); Just thought I'd discovered an (uknown) bug
colomon lanny: yeah, I think that bug was already known when I discovered it a few months back. :) 18:38
pmichaud colomon: in methods 18:45
colomon pmichaud: yes
18:46 mberends joined
colomon pmichaud: (is it different with subs?) 18:48
rakudo: sin(pi, :base("degrees)); 18:51
p6eval rakudo d91717: OUTPUT«Confused at line 2, near "(pi, :base"␤in Main (src/gen_setting.pm:3468)␤»
colomon rakudo: say sin(pi, :base("degrees"));
p6eval rakudo d91717: OUTPUT«FixedIntegerArray: index out of bounds!␤in sub sin (src/gen_setting.pm:559)␤called from Main (/tmp/vjd09tuJ77:0)␤»
colomon ooooo, that's exciting. 18:52
pmichaud yes, it's different with subs 18:53
methods have an implied slurpy hash argument, subs do not
18:54 eternaleye left
pmichaud (at least, that was my last reading of the spec) 18:54
colomon All these subtleties are making my head spin. Good thing I trust TimToady... 18:55
18:57 masak joined
pmichaud I'd be happy if methods didn't have an implied slurpy hash 18:58
for a variety of reasons
otoh, the implied slurpy hash might be needed for callnext, nextwith, etc. 18:59
jnthn yes, the reason they have it is deferal. 19:01
See Interface Consistency section of S12.
19:01 abra left
jnthn You can suppress it with "is hidden" and stuff. 19:01
colomon S12 is as clear as mud to me. I fear I still need to study up on the subtleties of p6 OO. 19:05
19:06 justatheory left
colomon jnthn++ # pointing out the exact point of the spec, so I could go from ignorant to uncomprehending. 19:06
:)
PerlJam yeah, I don't understand either. 19:10
Does "is hidden" remove the methods from ordinary dispatch?
jnthn No
Just from deferral.
PerlJam okay 19:11
jnthn There is a test file that may be clearer.
ah, here you go
svn.pugscode.org/pugs/t/spec/S12-cl...sistency.t
colomon rakudo: say Num::sin.signature.perl 19:12
p6eval rakudo d91717: OUTPUT«No applicable candidates found to dispatch to for 'sin'␤in Main (/tmp/8NagkNCqm9:0)␤»
colomon Oh! Actually, the test answers my question in a completely different direction. 19:14
jnthn & needed
(Num::sin calls it)
colomon rakudo: say &Num::sin.signature.perl 19:15
p6eval rakudo d91717: OUTPUT«undef␤»
colomon I was worried about "uncaptured named parameters", and rather than being an important part of the design that I didn't understand, it turns out they are simply a Parrot bug. 19:16
jnthn colomon: Yeah, there be bugs there.
colomon: Hopefully ex-bugs soon.
19:17 SmokeMachine left
colomon rakudo: say; 19:17
p6eval rakudo d91717: OUTPUT«say requires an argument at line 2, near ";"␤in Main (src/gen_setting.pm:2562)␤» 19:18
pugs_svn r28625 | lwall++ | [S03] more tidying of ranges
19:19 masak left 19:20 SmokeMachine joined 19:29 justatheory joined 19:31 user_4812 joined 19:32 user_4812 left
pugs_svn r28626 | diakopter++ | [sprixel] lots of preparation for bootstrapping namespace/object/type system in the (tiny) subset of Perl 6 that sprixel has already implemented. Builtins for deriving scopes/context and creating/modifying/introspecting members of scopes/objects. Essentially hashes, but 19:33
..without the P6 syntax for hashes b/c they're really JS object [prototype-chains] underneath.
mberends diakopter++ :-) 19:36
jnthn Sheesh...wow. 19:39
mberends diakopter: have you updated/will you update Test.pm.js since r28616/in the next 12 hours? I feel like implementing skip and todo, but cannot commit right now... 19:42
diakopter r28626 contained one diff line for that file, but I don't have any uncommitted local changes now 19:43
sprixel: my $core = get_core; say $core; member $core,"answer",42; say member $core,"answer"; say $core; 19:44
p6eval sprixel 28624: OUTPUT«Scope with keys: [ ]␤42␤Scope with keys: [ answer (Int()) ]␤»
mberends diakopter: ok, can patch one line manually. under a revised harness-fudging.pl, sprixel passes 192/445 tests in 15 files 19:46
diakopter kewl 19:47
well, does that include the "passes" that are actually todos?
19:48 meppl left
mberends hmm, yes. but that's only about half the passes, the other half are proper passes 19:48
diakopter ok :D
++mberends 19:49
19:52 Guest15333 is now known as ezra
pugs_svn r28627 | diakopter++ | [STD Makefile] add 2 more symlinks (setting and lib) TimToady plz correct if necessary 19:55
r28628 | diakopter++ | [sprixel] fix the what() and derive_context() builtins some more 19:56
19:56 xinming_ joined 19:58 NorwayGeek left, takadonet left
mberends moritz_: it looks like lambdabot has stopped irclogging again :( 19:59
19:59 lanny left
moritz_ lambdabot? 20:00
mberends whateverbot
moritz_ the irc logs seem to be still updated 20:01
irclog.perlgeek.de/perl6/2009-10-05#i_1571239
mberends moritz_: "seem", it must be the clever firewall/proxy between this computer and the interweb doing some cacheing. thankx 4 looking :) 20:03
s/seem/looks like/ 20:04
moritz_ I could try to emit some non-caching headers for the 'today' page
mberends it's non urgent 20:05
20:09 xinming left
pugs_svn r28629 | moritz++ | [irclog] emit Cache-Control: no-cache for today's pages 20:14
20:14 justatheory left
mberends moritz_++ 20:14
20:15 am0c left
moritz_ mberends: let me know if it makes any difference, in case you find out 20:15
20:16 _jaldhar left
mberends moritz_: it makes no difference, but Novell BorderManager may be to blame. Thanks for the workaround, I can click on any recent timestamp as a different url :) 20:17
moritz_ Novell BorderLine? ;-) 20:18
mberends :-)
20:19 ruoso left 20:20 fridim left 20:25 wmoxam joined, wmoxam left 20:29 justatheory joined 20:42 _jaldhar joined 20:51 _jaldhar left 20:52 colomon left 20:54 _jaldhar joined 20:55 japhb left 20:56 pmurias joined 20:58 _jaldhar left 21:01 _jaldhar joined
pugs_svn r28630 | diakopter++ | [sprixel] additional function jseval() - analogous to Q::PIR {}, except for JavaScript. the this object in the function is the ast/expression tree node, which has .context as one of its members 21:02
21:03 meppl joined
diakopter sprixel: say jseval 'this.result = Type(this.context)' 21:05
p6eval sprixel 28629: OUTPUT«Scope␤»
diakopter tee hee
sprixel: say jseval 'this.result = this.invoker.T' 21:06
p6eval sprixel 28629: OUTPUT«term__S_identifier␤»
diakopter sprixel: say jseval 'this.result = this.invoker.identifier.TEXT' 21:07
p6eval sprixel 28629: OUTPUT«jseval␤»
diakopter suh-weet
21:08 _jaldhar left 21:09 _jaldhar joined
diakopter begins cooking with gas 21:09
sjohnson lights the flame for diakopter 21:10
mberends looks for fireproof gloves 21:11
pmurias runs away screaming... 21:12
diakopter hah
mberends "program ended abruptly: code too hot"
moritz_ goes for the extinguisher and smashes it on the floor 21:16
people always react illogical when panicking ;-)
21:17 _jaldhar left 21:18 _jaldhar joined
diakopter sprixel: sub stack_trace { jseval 'var res=[],node=this; do { res.push(node.T) } while (node=node.invoker); this.result = res.join("->")' }; say stack_trace; 21:19
p6eval sprixel 28630: OUTPUT«identifier->term__S_identifier->noun__S_term->statement->statementlist->Sub_invocation->term__S_identifier->noun__S_term->arglist->args->eval_args->term__S_identifier->noun__S_term->statement->statementlist->compilation_unit␤»
21:21 lanny joined
diakopter TimToady: now you can see the tree path for anything that std can parse.. ^^ (just call stack_trace at the point you want to see the path) 21:21
mberends when you relate that to the viv output, it looks beautiful
21:23 colomon joined
diakopter well, I'm wrong on that.. sprixel also has to implement it, too.. although I guess I can add a primitive that'll dive down into an unimplemented tree to look for such things 21:23
lanny With pretty simple classes, loops, and array access should rakudo be some 400 X slower than perl5? 21:24
I believe I heard roughly 3 X slower earlier.
21:24 googe joined
mberends lanny: the tinier the operations, the greater the performance difference will be. it varies a lot. 21:25
lanny ah. darn 21:26
I'm doing euler prob 7. compute the 10001st prime. perl5 = 1.5s, rakudo=11.5m 21:27
Ok. Well that makes sense anyway. Thank you.
mberends Parrot is undergoing some major refactoring that *should* help performance quite a lot. nobody knows how much though. 21:28
lanny Well, at this point it should be hard to make it worse for this app. :) 21:30
mberends heh 21:31
diakopter pika FIRE
21:33 pmurias left
colomon lanny: I've seen 5000x speed difference between Perl 5 and Rakudo. 21:33
dukeleto colomon: on what?
colomon scanning a large text file
dukeleto lanny: do you know about euler_bench? 21:34
lanny No I don't
colomon perl 5 is super-optimized to handle it, and rakudo is painfully slow.
dukeleto lanny: github.com/notbenh/euler_bench/
lanny: euler_bench is a way to run the euler problems as benchmarks across languages and versions of languages 21:35
21:35 _jaldhar left
lanny Interesting. 21:35
dukeleto lanny: please contribute any euler prob's that you have 21:36
lanny: we have implementation in perl5,rakudo,parrot,ruby,haskell and probably more
lanny Although by their nature Euler problems are pretty heavily into just the mathematical portion of a language
dukeleto lanny: you would be surprised
lanny: if you have a github account, I can add you as a committer 21:37
lanny Sure. Account name is LannyRipple
At the very least I can add this primes generator and your perl5 code is going to see a goodly jump in speeds 21:38
dukeleto lanny: very recently we have abstracted euler_bench to use arbitary files, so it is no longer directly tied to euler prob #'s. I use it to benchmark parrot scripts across all released versions as well as trunk
lanny: we already have a few implementations for that probably, but you can add yours as well
lanny: we are more concerned with showing performance differences between different implementations than finding the most performant solution to each problem 21:39
lanny While that's true if you are using poor algorithms then difference in the languages will just be compounded 21:41
dukeleto lanny: we treat all implementations of a single problem as useful for benchmarking, even if they are dog slow. 21:43
diakopter lanny: 'showing performance differences between different implementations' is distinct from 'showing performance differences among the optimization abilities of the implementations'.. if you have to give the optimizing compiler lots of hints to make it recognize places/ways to optimize (and the program is equivalent), then there's a spot for more potential optimization in the compiler. 21:44
lanny No, I agree there. Looking at the haskell implementations for the Language shootout game and how I would address them shows that difference. 21:45
But for instance if you have an O(N^2) algorithm then you get a compounding problem in the relative speeds between perl5 and 6 (for example)
Ideally you'd just test O(N) algorithms to determine the speed gap which could be applied to other Orders of complexity 21:46
diakopter right, or if the method of evaluating the algorithm adds additional time complexity to the algorithm itself (instead of just linear overhead... ) 21:47
lanny yes
And then there is the joy of keeping things in sync. I'm not picking on prob7 here but that's the one I was just noticing the gap on myself.
21:47 KyleHa left, NorwayGeek joined
diakopter the pidigits algorithm on the language shootout was a fun one (in JS) 21:48
lanny Looks like perl6 is using O(N * log N) since someone introduced the sqrt() optimization for finding the 10001st prime while perl5 is still using O(N^2)
21:50 _jaldhar joined
lanny dukeleto: I'll look around it more. Right now though wife just walked in the door and gotta figure out what we'll do for supper. 21:52
21:53 lanny left 21:55 hercynium_ joined, hercynium left, hercynium_ is now known as hercynium 21:56 hercynium left, hercynium joined 21:57 _jaldhar left 22:04 patspam joined 22:06 patspam left, _jaldhar joined, Whiteknight joined 22:12 mberends left, justatheory left 22:22 _jaldhar left 22:26 _jaldhar joined 22:28 quietfanatic joined 22:30 _jaldhar left, _jaldhar joined 22:31 japhb joined 22:32 _jaldhar left, _jaldhar joined
quietfanatic rakudo: our Int @A1; our @A2; @A2[0] = "Str" 22:34
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Int, but got Str␤in Main (/tmp/TaI3DQoZtV:0)␤»
22:34 justatheory joined
diakopter rakudo: our Int @A1; our Str @A2; @A2[0] = "Str" 22:37
p6eval rakudo d91717: ( no output )
diakopter rakudo: our Int @A1; our Str @A2; @A2[0] = "Str"; @A1[0] = 3;
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/TDAowkMj7A:0)␤»
diakopter rakudo: our Int @A1; our Str @A2; @A2[0] = "Str"; our Int @AInt; @A1[0] = 3; 22:38
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/dnYNmw7095:0)␤»
diakopter rakudo: our Int @A1; our Str @A2; @A2[0] = "Str"; our Int @AInt = 0,0; @A1[0] = 3;
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/4VwEBmi3JL:0)␤»
diakopter hm 22:39
quietfanatic It took me a long time to figure out where that message was coming from.
because it's spooky action at a distance 22:40
diakopter rakudo: our Int @A1; our Str @A2; our Int @AInt; @A2[0] = "Str"; 22:41
p6eval rakudo d91717: ( no output )
diakopter rakudo: our Int @A1; our Str @A2; our Int @AInt; @A2[0] = "Str"; @A1[0] = 3;
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/fiW0vmiDze:0)␤»
quietfanatic rakudo: my Str @A1; my @A2; @A2[0] = 5
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/lIidfhTdOH:0)␤»
quietfanatic rakudo: my Int @A; my Str @B; @A[0] = 3 22:43
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/Uvj5lbmYvv:0)␤»
quietfanatic rakudo: my Int @A; my Str @B; my Int @C; @A[0] = 3
22:43 ruoso joined
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/wp1yjkexoc:0)␤» 22:43
quietfanatic rakudo: my Int @Z; my Int @A; my Str @B; my Int @C; @A[0] = 3 22:44
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/H9ECLUKMVj:0)␤»
quietfanatic rakudo: my Str @Z; my Int @A; my Str @B; my Int @C; @A[0] = 3
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: my Str @Z; my Int @A; my Code @B; my Int @C; @A[0] = 3
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Code, but got Int␤in Main (/tmp/7ip1O8GO4x:0)␤»
quietfanatic The last unique type constraint, it seems, is picked as the constraint for all arrays. 22:45
rakudo: my Str @Z; my Int @A; my Code @B; my Int @C; @C[0] = 3
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Code, but got Int␤in Main (/tmp/qRgmORdzrp:0)␤»
quietfanatic rakudo: my Str @Z; my Code @B; my Int @C; @C[0] = 3
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: my Str @A; my @B; @B.push: 3 22:46
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: my Str @A; my @B; @B[0] 3
p6eval rakudo d91717: OUTPUT«Confused at line 2, near "3"␤in Main (src/gen_setting.pm:3468)␤»
quietfanatic rakudo: my Str @A; my @B; @B[0] = 3
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/NCwktDIvUq:0)␤»
quietfanatic rakudo: my Str @A; my @B; @B.push: 3; say @B[0].WHAT 22:47
p6eval rakudo d91717: OUTPUT«Int()␤»
quietfanatic rakudo: my Str @A; my @B; @B.push: 3; @B[0] = @B[0];
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: my Str @A; my @B; @B.push: 3; @B[1] = 4
diakopter ah, the last one that hasn't been done before (like you said)
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/g4WNr1jzmx:0)␤»
diakopter what about in a block 22:48
(my )
quietfanatic rakudo: do {my Int @A; my @B; @B[0] = 3}
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: my Int @A; my @B; @B[0] = 3
p6eval rakudo d91717: ( no output )
quietfanatic rakudo: do {my Str @A; my @B; @B[0] = 3}
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/LlDmQ1mGn5:1)␤»
quietfanatic Oh, and it only does that for arrays too. 22:49
I mean, for postcircumfix:<[ ]> 22:50
diakopter lol at 'thoughtful'
'patient' 22:51
by that measure, sprixel is downright fixated
pmichaud rakudo: my Str @a; my @b; @b.push(3); say @b; 22:53
p6eval rakudo d91717: OUTPUT«3␤»
pmichaud rakudo: my Str @a; my @b; @b[0] = 3; say @b; 22:54
p6eval rakudo d91717: OUTPUT«Assignment type check failed; expected Str, but got Int␤in Main (/tmp/MnBiEOzY98:0)␤»
pmichaud wtf
rakudo: my Str @a; my @b; say @a =:= @b;
p6eval rakudo d91717: OUTPUT«0␤»
pmichaud rakudo: my Str @a; my @b; say @a.PARROT;
p6eval rakudo d91717: OUTPUT«␤»
pmichaud rakudo: my Str @a; my @b; say @b.PARROT;
p6eval rakudo d91717: OUTPUT«Perl6Array␤»
pmichaud that's.... weird 22:55
23:15 colomon left 23:22 ihrd joined 23:26 SmokeMachine left
Tene phenny: tell masak You should add weblocks to your list of web frameworks to look at. 23:29
phenny Tene: I'll pass that on when masak is around.
23:30 colomon joined 23:31 Confield joined 23:34 tak11 joined 23:46 quietfanatic left 23:51 eternaleye joined
pugs_svn r28631 | lwall++ | [perl6/Makefile] preserve copy semantics on snapshots 23:51
23:56 xinming joined
diakopter rakudo: my $a=0; 1 while ++$a < 40000; say $a 23:59
p6eval rakudo d91717: ( no output )
diakopter rakudo: my $a=0; 1 while ++$a < 20000; say $a
p6eval rakudo d91717: OUTPUT«20000␤»