»ö« | 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 Whiteknight left 00:02 eternaleye joined
TimToady diakopter: and you can think of multiple dispatch as a dispatch to the lexical scope rather than to the object 00:02
00:06 cdarroch left 00:07 tak11 joined 00:20 crythias joined
pugs_svn r28485 | diakopter++ | [vijs/sprixel] sigh 00:27
diakopter vijs: my $a = 333333333333333333333333333333/444444444444444444444444444444; $a++; say $a; 00:28
p6eval vijs 28484: OUTPUT«777777777777777777777777777777/444444444444444444444444444444␤»
diakopter no idea whether that's correct
[particle] vijs: say 777777777777777777777777777777/444444444444444444444444444444 - 333333333333333333333333333333/444444444444444444444444444444; 00:29
p6eval vijs 28484: OUTPUT«execute(): execute error: Rat Additive not yet implemented; srsly!??!?! at vijs line 85.␤»
[particle] and no easy way to check :) 00:30
diakopter I meant the stringification :P I know the operation is correct
colomon diakopter: actually, Rakudo stringifies Rats to decimal numbers. I believe that is intended to be the way it works in the spec as well, though I don't know if the spec reflects that yet. 00:32
rakudo: say 333333/444444;
p6eval rakudo 0331d6: OUTPUT«0.75␤»
diakopter looks for LCM operation in the libBigInt.js library 00:33
diakopter wonders whether Rats should be reduced...
colomon Rakudo reduces Rats, and I wrote the spectests that way, too. 00:34
I don't think the spec actually says yet....
rakudo; say (333333/4444444).perl; 00:35
rakudo: say (333333/4444444).perl;
p6eval rakudo 0331d6: OUTPUT«333333/4444444␤»
colomon rakudo: say (333333/444444).perl
p6eval rakudo 0331d6: OUTPUT«3/4␤»
diakopter oh
colomon woo-hoo! My make spectest passed! Matt-W++ 00:36
00:36 cj_ joined
colomon .... on reflection, that makes me think the spectest might be missing some tests, because the prefix:<+> I added is pretty darned stupid... 00:37
eternaleye I've been MIA for the last month or so, and Google isn't getting any result - what's vijs? 00:38
colomon diakopter: The numeric portions of the spec are pretty sketchy right now, and the intent is to track Rakudo's implementation, so far as I know.
diakopter ok 00:40
eternaleye: it uses TimToady's STD parser in Perl 5, emits the AST to JS, and interprets it using a JS runtime in V8 (C++/linked in process to perl) 00:41
colomon Oh !@#!$!$@#@#!, I somehow didn't save my changes to op.pir, so that make spectest was completely pointless. Time to start over again.... 00:42
eternaleye Oooh, shiny!
diakopter eternaleye: I'm just today getting it to sorta run the spectests...
diakopter adds .lcm() method [one-liner] to libBigInt.js function lcm(b){ return this.multiply(b).divide(this.gcd(b)) } 00:44
00:46 jauaor left 00:48 cj left 00:50 zerhash left 00:54 zerhash joined
pugs_svn r28486 | diakopter++ | [vijs/sprixel] add lcm method to libBigInt.js; implement Rat Additive (also subtraction) 00:57
diakopter vijs: say 777777777777777777777777777777/444444444444444444444444444444 - 333333333333333333333333333333/444444444444444444444444444444; # for [particle] 00:58
p6eval vijs 28485: OUTPUT«444444444444444444444444444444/444444444444444444444444444444␤»
pugs_svn r28487 | diakopter++ | [vijs/sprixel] make Rats reduce upon instantiation 01:03
diakopter vijs: say 777777777777777777777777777777/444444444444444444444444444444 - 333333333333333333333333333333/444444444444444444444444444444; # for [particle]
p6eval vijs 28485: OUTPUT«1/1␤»
diakopter heh 01:04
01:04 japhb left
diakopter vijs: say 3333/4444 01:05
p6eval vijs 28485: OUTPUT«3/4␤»
01:07 stephenlb left
colomon diakopter++ 01:08
pmichaud: ping? 01:09
01:13 TiMBuS joined
crythias sprixel: Sixth Perl Revision Is Xquisitely Enticing. LOL 01:18
diakopter ++crythias 01:19
01:23 SmokeMachine left 01:33 japhb joined 01:42 rhr joined
pugs_svn r28488 | diakopter++ | [vijs/sprixel] implement "constant folding" for divisions of (only) two literal integers, coercing it to a Rat. 01:47
diakopter also fixed a bug in libBigInt.js.
(not my bug, even!)
java transliteration error.
vijs: say say -3 / 4 01:48
p6eval vijs 28487: OUTPUT«-3/4␤1␤»
diakopter vijs: say 6 / 9 01:49
p6eval vijs 28487: OUTPUT«2/3␤»
01:55 rhr_ left 02:02 meppl left 02:07 zaphar_ps joined
pugs_svn r28489 | diakopter++ | [vijs/sprixel] implement Rat.toString() as decimal stringification (in Rat.toNum()) 02:13
diakopter vijs: say -6 / 9
p6eval vijs 28487: OUTPUT«-0.6666666666666666␤»
diakopter whee
vijs: say 5589162039876590823/38392635986432 02:14
p6eval vijs 28487: OUTPUT«145579.12648462242␤»
diakopter vijs: say 5589162039876590823552352332/38392635986432
p6eval vijs 28487: OUTPUT«145579012648462.25␤»
diakopter hmmmmm 02:15
looks like it lost a leading zero there in the decimal part of the 2nd-to-last quotient 02:16
02:17 rfordinal joined
diakopter vijs: say 1/50 02:17
p6eval vijs 28487: OUTPUT«0.2␤»
diakopter yep
colomon rakudo: say -6 / 9; 02:18
p6eval rakudo 0331d6: OUTPUT«-0.666666666666667␤»
diakopter so JS has a couple more precision 02:19
but didn't round
up
02:19 rhr left
colomon is jealous of vijs's bignums. 02:20
diakopter well
don't be too jealous
02:20 payload left
diakopter since it's not stringifying correctly yet 02:21
vijs: say ((1/50) * 50) 02:22
p6eval vijs 28489: OUTPUT«execute(): execute error: Rat Multiplicative not yet implemented; srsly!??!?! at vijs line 85.␤»
diakopter vijs: say (9/100 + 1/100) 02:23
p6eval vijs 28489: OUTPUT«0.1␤»
02:23 rhr joined
colomon diakopter: speaking as someone who works with numbers all the time, I don't care about a number being off by 0.0000000000000001. 02:23
diakopter colomon: it's not 02:24
it's off by as much as 0.9
colomon oh, it's the missing leading 0 in the decimal place? I thought you'd already fixed that. :)
diakopter no; I'm blanking on how to stringify a quotient's remainder into decimal... having never done it before. :) 02:25
my trick was to multiply it by 1e31 then divide by the divisor
colomon ooooo
diakopter but obviously that doesn't work
that gets all the sigdigs except the leading zeroes. :) 02:26
actually
it just needs to pad on the left up to the number of digits in the divisor times 1e31
colomon that seems right
diakopter hm 02:27
zpmorgan vijs: say abs((4.9-5) / 0.4)' 02:29
p6eval vijs 28489: OUTPUT«===SORRY!===␤Confused at /tmp/jd4SQYnPWK line 1:␤------> say abs((4.9-5) / 0.4)⏏'␤ expecting any of:␤ POST␤ bracketed infix␤ infix stopper␤ postfix␤ postfix_prefix_meta_operator␤ standard stopper␤ statement 02:30
..modifier loop␤ terminator␤ whitespa…
zpmorgan vijs: say abs((4.9-5) / 0.4)
p6eval vijs 28489: OUTPUT«Undef␤»
diakopter it doesn't know about abs
zpmorgan ok
diakopter it's not currently throwing on missing subroutine, too :)
zpmorgan do you know why perl5 would give 0.249999999999999 instead of .25? 02:31
02:31 rhr left
colomon that's the magic of floating point math 02:31
diakopter yeah; b/c of the way floats/doubles are stored...
vijs: say (4.9-5) / 0.4 02:32
p6eval vijs 28489: OUTPUT«-0.2499999999999991␤»
diakopter see? :)
even wrongisher
zpmorgan i've heard that 1/10 can't be represented in floatimg point
somehow, perl does it correctly 02:33
colomon rakudo: say (49/10 - 5) / (2 / 5);
p6eval rakudo 0331d6: OUTPUT«-0.25␤»
diakopter afk
02:33 rhr joined
zpmorgan vijs: say (4.9-5) / (2/5) 02:34
p6eval vijs 28489: OUTPUT«-0.2499999999999991␤»
diakopter vijs: say (4.9-5)/(2/5)
p6eval vijs 28489: OUTPUT«-0.2499999999999991␤»
diakopter vijs: say (9.8/2-5/1)/(2/5) 02:36
p6eval vijs 28489: OUTPUT«-0.2499999999999991␤»
02:36 rfordinal left
diakopter vijs: say (98/20-5/1)/(2/5) 02:36
p6eval vijs 28489: OUTPUT«execute(): execute error: Rat Multiplicative not yet implemented; srsly!??!?! at vijs line 85.␤»
02:37 justatheory left 02:38 __ash__ left 02:41 hercynium left 02:49 __ash__ joined
diakopter vijs: say (98/20-5/1) / (2/5) 02:50
p6eval vijs 28489: OUTPUT«execute(): execute error: Rat Multiplicative not yet implemented; srsly!??!?! at vijs line 85.␤»
02:54 zerhash left 02:59 molaf joined 03:01 zerhash joined
Tene Yay, I'm getting github failures! Pages refusing to load with "502 Bad Gateway -- nginx" messages. 03:03
03:12 payload joined 03:22 __ash__ left
carlin On OpenSolaris, S03-operators/arith test 163 fails because 1**Inf = NaN, on Ubuntu 1**Inf = 1 03:36
03:36 crythias1 joined 03:46 jauaor joined 03:54 crythias left 03:59 Student left 04:00 Student joined, tak11 left 04:07 crythias1 left 04:11 envi^office joined
carlin rakudo: say $*OSVER; say $*EXECUTABLE_NAME; 04:14
p6eval rakudo 0331d6: OUTPUT«#1 SMP Sun Feb 24 18:08:45 EST 2008␤../p/bin/perl6␤»
04:15 justatheory joined 04:17 eternaleye left
carlin What would it take to get $*OSVER to work on OpenSolaris? (its currently defined but blank) 04:33
04:35 justatheory left 04:45 reqamst left, reqamst joined
mberends carlin: needs a parrot solution, not fulfilling 'sysinfo .SYSINFO_PARROT_OS_VERSION' (rakudo/src/builtins/globals.pir:32) 04:48
04:51 Woodi joined 05:05 Student left 05:27 mberends left 05:31 synth^3 left 05:32 Woodi left 05:34 rfordinal joined 05:42 Confield left 06:08 NorwayGeek|Away left 06:20 rfordinal left 06:21 rfordinal joined 06:22 zev left 06:24 zev joined 06:27 ihrd joined 06:34 mberends joined 06:35 NorwayGeek joined
mberends moritz_: ready to commit rename vijs -> sprixel at the request of diakopter++, will do it when you're here to manage the evalbot end 06:40
06:40 rfordinal left
moritz_ mberends: go right ahead 06:42
pugs_svn r28490 | mberends++ | [sprixel] new name replacing vijs, see sprixel.blogspot.com 06:45
mberends moritz_, diakopter asked if you could give sprixel prefix s: in evalbot 06:47
:) 'sprixel' is an anagram of 'perlsix' 06:48
moritz_ so what's the new incantation to start sprixel? 06:49
mberends perl sprixel.pl -e '...' 06:50
06:52 ihrd left, flip214 joined
mberends 'make -f sprixel.mk test' passes two tests in t/01-sanity/04-if.t without fudging :) 06:52
diakopter yay
flip214 Help, please?
diakopter my local passes the first 34 tests of num.t
mberends hiya diakopter
flip214 rakudo: our $c=0; class T { has $.me=$c++; has T $.left; has T $.right; }; my T $t .= new;
pugs_svn r28491 | moritz++ | [src/perl6] adapt 'make snap' to new name
mberends \o/ 06:53
p6eval rakudo 0331d6: OUTPUT«Null PMC access in find_method()␤in Main (/tmp/jHMTiFuXGa:2)␤»
06:53 lmc left
flip214 I'd think that's more or less directly from S12. 06:53
moritz_ flip214: yes, "Null PMC access" is alwasy a bug
flip214 Is $t still undef, so that .new can't be called?
diakopter null pointer exception
null reference exception
flip214 So? my error, or when will that be fixed? 06:54
;-)
diakopter NEVER NEVER NEVER
:>
kidding. sorry.
flip214 np
I'm used to that
moritz_ diakopter: are you sure that 's:' as the prefix for sprixel is a good idea?
diakopter: people will ask 'what's "s"' all the time 06:55
diakopter moritz_: no, but I'd like to try it, and r: for rakudo and p: for pugs and e: for elf and m: for mildew
mberends can we have a long and a short alias?
moritz_ not yet 06:56
mberends later today?
;)
moritz_ and I'm not sure if I get to it today, but evalbot.pl is in the repo after all, so you can patch it yourself
diakopter moritz_, mberends: oh, it's morning to you two
so g'morning
moritz_ :-) 06:57
mberends "patches welcome" [tm]moritz_
pugs_svn r28492 | moritz++ | [evalbot] s/vijs/sprixel/
mberends sprixel: say "alive and kickin'" 06:58
diakopter at least I didn't go with splerix or splixer or sexripl
06:59 barney joined
mberends thank goodness for that 06:59
diakopter crythias came up with sprixel
++num.t 07:01
flip214 What should I do about my "Null PMC access"?
rakudo: our $c=0; class T { has $.me; }; my T $t=T.new 07:02
this works
p6eval rakudo 0331d6: ( no output )
flip214 this doesn't
rakudo: our $c=0; class T { has $.me=$c++; }; my T $t=T.new
p6eval rakudo 0331d6: OUTPUT«Null PMC access in find_method()␤in Main (/tmp/9VV78Lrwsz:2)␤»
diakopter evalbot control restart
07:02 p6eval left, p6eval joined
flip214 rakudo: our $c=0; class T { has $.me=$c++; }; my T $t=T.new 07:02
p6eval rakudo 0331d6: OUTPUT«Null PMC access in find_method()␤in Main (/tmp/MX0Cn4ima5:2)␤»
diakopter perl6: say 4,3,2,1
p6eval vijs: ( no output ) 07:03
..elf 28492, pugs, rakudo 0331d6: OUTPUT«4321␤»
flip214 The only difference is the initialization to the global counter variable
With =0 it's ok
diakopter moritz_: you missed one... (yesterday I added it to perl6:
)
mberends nothing shy about our diakopter ;) 07:05
mikehh rakudo (0331d60) builds on parrot r41546 - make test / make spectest_smolder (up to r28490 -> #28284) PASS - Ubuntu 9.04 amd64 07:06
carlin I couldn't get rakudo to build with gcc in Solaris, it worked with Sun CC and it worked with gcc a few weeks ago. Problem is that --optimize is now default 07:07
moritz_ diakopter: go ahead then
07:07 mariuz joined
moritz_ carlin: then build parrt yourself, without --optimize 07:07
carlin: and please open a parrot bug for not building on your platform with --optimize
TimToady rakudo: our $c = 0; class T { has $.me = GLOBAL::<$c>++; }; my T $t .= new; 07:08
p6eval rakudo 0331d6: OUTPUT«Null PMC access in getprop()␤»
moritz_ rakudo doesn't do GLOBAL or PROCESS yet 07:09
TimToady rakudo: module X { our $c = 0; class T { has $.me = $X::c++; }; my T $t .= new;
p6eval rakudo 0331d6: OUTPUT«Unable to parse block; couldn't find final '}' at line 2, near ""␤in Main (src/gen_setting.pm:3469)␤»
carlin moritz_: that's what I did (to find that --optimize was the problem), I'll open a parrot ticket now
TimToady rakudo: module X { our $c = 0; class T { has $.me = X::<$c>++; }; my T $t .= new;
p6eval rakudo 0331d6: OUTPUT«Unable to parse block; couldn't find final '}' at line 2, near ""␤in Main (src/gen_setting.pm:3469)␤»
diakopter evalbot control restart 07:10
07:10 p6eval left
pugs_svn r28493 | diakopter++ | [evalbot] one last rename of vijs to sprixel 07:10
07:10 p6eval joined
TimToady flip214: rakudo doesn't see lexicals outside of classes yet 07:10
flip214 But AFAIK it should, right?
TimToady and class T is a different package
yes, it should 07:11
flip214 So it's just a matter of time.
Thanks a lot.
Does state already work?
moritz_ s/time/effort/
flip214: yes
carlin Would it be possible to have rakudo not --optimize on certain platforms or would it not be worth worrying about?
diakopter perl6: say 4,3,2,1
p6eval elf 28493, pugs, rakudo 0331d6, sprixel 28492: OUTPUT«4321␤»
mberends \o/
flip214 thanks: 07:12
rakudo: class T { state $c=0; has $.me=$c++; method P { say $.me }; }; my T $t .= new; $t.P
moritz_ carlin: that really depends on how hard it is for the parrot folks to fix it
diakopter elf is one revision ahead of sprixel
p6eval rakudo 0331d6: OUTPUT«0␤»
07:12 rfordinal joined
moritz_ diakopter: the STD build, actually 07:13
diakopter ah, oh
makes sense
07:26 iblechbot joined 07:29 Woodi joined
flip214 Does "role Each" already work? I'd like to test the hyper-operator. 07:30
Matt-W Morning 07:35
moritz_ flip214: I don't think so. Hyper operators work on infixes though 07:38
07:41 ejs joined 07:50 ejs1 joined 07:57 ejs left
pugs_svn r28494 | lwall++ | [STD] 08:02
r28494 | package name refactor; stashes now know their own unique id name
r28494 | conflicting package symbols now report which package they conflict in
r28494 | (lexicals are always assumed to conflict in the current scope)
08:10 masak joined
masak ahoj, #perl6! 08:10
moritz_ \o/ 08:11
08:20 ihrd joined, ihrd left
Matt-W yo masak 08:21
mberends masak: hi, sorry about not working on proto lately, sprixel is a much nicer toy at the moment ;) 08:33
Matt-W totally failed to successfully move any operators into the setting last night 08:36
08:37 NorwayGeek left
moritz_ Matt-W: which one(s) did you try? 08:37
Matt-W infix:<xx>, which has signature problems 08:38
infix:<~>, which looked entirely plausible but I ran into a null PMC access, threw my hands in the air and went to play with the cat instead 08:39
08:39 NorwayGeek joined
Matt-W So that one may well be possible, but I gave up 08:40
08:43 Lorn joined 08:49 Lorn_ left
masak de-meetings 08:55
mberends: hi, no worries.
mberends: (what's sprixel?)
moritz_ vijs' new name
masak Matt-W: oh, you didn't try infix:<< < >> and infix:<< > >> ?
moritz_: ah, cool.
Matt-W masak: no, sorry 08:57
masak then maybe I'll try today.
colomon Matt-W: I failed to move prefix:<+> into the setting last night as well.... 09:01
09:17 PerlJam left
Matt-W :( 09:18
I think all the really easy ones are done
masak
.oO( high-hanging fruit )
09:18 NorwayGeek left, PerlJam joined
carlin what would cause 1**Inf to return different values on different platforms? 09:23
09:23 NorwayGeek joined
moritz_ colomon: I just pushed the branch native-complex to github... 09:25
colomon moritz_: woah
moritz_ colomon: the idea is to implement the Complex class fully in Perl 6, and use the parrot Complex class through delegation
colomon: currently there's just one commit in it, which rips out the old thing and adds a constructor , $.re and $.im to Complex
colomon Will "git pull" pull it, or do I need to do something special?
moritz_ git pull 09:26
colomon and then switch to the branch to use it, I presume.
moritz_ yes
git checkout --track origin/native-complex
git checkout -b native-complex
I'm sure there's an easier invocation which does these two things in one... 09:27
colomon I'm presuming this breaks lots of spectests at the moment? 09:28
moritz_ it does
I haven't even bothered running them :-)
colomon :) 09:29
moritz_ but since the parser doesn't emit proper Complex.new it's obvious that everything breaks
colomon When I try "git checkout --track origin/native-complex", I get "git checkout: --track and --no-track require -b" 09:30
09:30 pdcawley joined
colomon Pro Git makes it look like "git checkout -b native-complex origin/native-complex" might do it? But I don't see a mention of --track at all. 09:31
moritz_ colomon: I think --track is on by default in newer gits
colomon: but it doesn't hurt to use it anyway :-) 09:32
colomon "git checkout -b native-complex origin/native-complex" replies 09:33
Branch native-complex set up to track remote branch refs/remotes/origin/native-complex.
Switched to a new branch "native-complex"
moritz_ then all is well
colomon \o/
moritz_ since Makefile.in has changed, you need to run Configure.pl again
colomon Answering my questions before I can even ask them, moritz_++ 09:35
building now, I should probably go back to bed... 09:36
09:36 huf_ joined 09:39 clintongormley joined
masak Woodi: oh hai, I read in the backlog that you 'hate proto'. we need more people like you! :) could you elaborate on what exactly it was you hated (something about 'already installed')? then maybe I can make the experience less hateful for the next customer. 09:40
09:42 payload left 09:44 huf left
masak rakudo: our $c; class T { $c++ }; T.new 09:45
p6eval rakudo 0331d6: OUTPUT«Null PMC access in find_method()␤»
masak submits rakudobug
Matt-W another day, masak found another forty bugs 09:57
nice to know the world keeps turning even when my brain's melting
masak this one was courtesy of flip214, actually.
but he doesn't seem to have processed it, so I did. 09:58
Matt-W naughty flip214
09:58 meppl joined
masak hugme: hug flip214 09:58
hugme hugs flip214
Matt-W although finding it is good
masak actually, I suspect it's part of a larger, known set of issues. 10:00
10:04 ruoso left
Matt-W I never want to write a network app ever again 10:06
Just too much pain
carlin is having fun with cross-platform weirdness
Matt-W I'd like the ability to time out a TCP send if it doesn't complete within a given period 10:08
Unfortunately Solaris doesn't support the socket flags for that
This is why I'd rather be writing Perl 6 stuff
10:11 huf_ is now known as huf 10:12 NorwayGeek left 10:16 am0c left 10:17 hanekomu joined 10:18 pmichaud left 10:20 pmichaud joined 10:24 dakkar joined
colomon is back 10:33
10:35 arthur-_ left 10:48 arthur-_ joined
colomon are there Complex arith tests somewhere in t/spec? 11:06
flip214 masak: while you're reporting bugs, here's another
working:
rakudo: class Int is also { multi method f(Int $self: Int $arg) { return $self-$arg;}; multi method infix:<+>(Int $self: Complex $arg) { return 0; } }; say 5.f(2)
p6eval rakudo 0331d6: OUTPUT«3␤» 11:07
flip214 rakudo: class Int is also { multi method f(Int $self: Int $arg) { return $self-$arg;}; multi method infix:<+>(Int $self: Complex $arg) { return 0; } }; say 5.&infix:<+>(2)
p6eval rakudo 0331d6: OUTPUT«Parameter type check failed; expected Complex, but got Int for $a in call to infix:+␤in sub infix:+ (src/gen_setting.pm:876)␤called from Main (/tmp/BtSPjqelO3:0)␤»
flip214 For a plain method name that works ... using operators doesn't.
what gender is hugme? 11:08
11:11 iblechbot left
moritz_ it's botgender 11:14
flip214: you won't ever be able to declare infix methods 11:15
infixes are looked up as subs, not as methods.
mikehh rakudo (0331d60) builds on parrot r41551 - make test / make spectest_smolder (up to r28494 -> #28300) PASS - Ubuntu 9.04 amd64 11:20
11:20 redicaps joined 11:24 am0c joined
masak submits flip214's rakudobug 11:29
colomon moritz_: the bot that announces commits to rakudo doesn't announce those to branches? 11:32
TiMBuS can rakudo take multi-type function sigs? eg. foo(Int|Str $a){...} 11:34
Juerd notices that planet.perl6.org works now. Thanks, whoever made this work. (I forgot.) 11:35
masak TiMBuS: no, I don't think so. 11:39
TiMBuS yeah, i tried but the error wasnt telling me if i was doing something wrong or not 11:41
11:41 kst` joined, tylerni7 left, dukeleto left, simcop2387 left, buubot left, BooK left, moritz_ left, Grrrr left, pjcj left, mdxi left, arnsholt left, hcchien left, mspauldi1g left, Rint left, sjohnson left, avar left, kst left, allbery_b left, Intensity left, KatrinaTheLamia left 11:43 simcop2387 joined, moritz_ joined, BooK joined 11:44 mspaulding joined, pjcj joined 11:45 ejs2 joined
masak rakudo: sub foo(Int|Str $) {} 11:45
p6eval rakudo 0331d6: OUTPUT«Unable to parse multisig; couldn't find final ')' at line 2, near "|Str $) {}"␤in Main (src/gen_setting.pm:3469)␤»
wolverian do feed operators not work with scalars at all?
masak TiMBuS: it's telling you that it can't parse the '|'
moritz_ rakudo: say 1 ==>> 2
p6eval rakudo 0331d6: OUTPUT«Feed operators are not yet implemented in Rakudo, sorry␤in sub infix:==>> (src/gen_setting.pm:1668)␤called from Main (/tmp/gz6vOFa9g7:0)␤» 11:46
TiMBuS fair enough, masak
moritz_ Juerd: Daniel Wright made us a catch-all subdomain for perl6.org, and I did the redirect
TiMBuS that makes sense actually.
moritz_ if anybody else wants to perl6.org subdomains, talk to me.
Juerd moritz_: Thanks :) 11:47
pugs_svn r28495 | colomon++ | [t/spec] Test that the two ways of making a Rat actually do make a Rat.
TiMBuS i do! not that id have anything perl6-ish to contribute but man it would be cool to have one
Juerd perl6.nl subdomains are available too. Even free-er! :D 11:48
TiMBuS depending on how you define 'cool'
Juerd And much dutchier
moritz_ :-)
moritz_ can also offer subdomains of perl-6.de and rakudo.de 11:49
masak flip214: oh wait. your bug is odd, because the .f method takes an Int, whereas the infix:<+> method takes a Complex.
flip214: so it's kinda apples and oranges.
Juerd Ooh, I almost forgot I also have rakudo.nl :D 11:50
carlin On OpenSolaris, my rakudo compiled with gcc thinks log(-Inf) = -Inf, my rakudo compiled with SunStudio CC thinks log(-Inf) = NaN
TiMBuS rakudo: class Int is also { multi method f(Int $self: Int $arg) { return $self-$arg;}; multi method infix:<+>(Int $self: Int $arg) { return 0; } }; say 5.&infix:<+>(3);
p6eval rakudo 0331d6: OUTPUT«Parameter type check failed; expected Complex, but got Int for $a in call to infix:+␤in sub infix:+ (src/gen_setting.pm:876)␤called from Main (/tmp/SiFN4iqq4G:0)␤»
TiMBuS errr
flip214 masak: yeah, but try it with an Int - doesn't work either
rakudo: class Int is also { multi method f(Int $self: Int $arg) { return $self-$arg-1;}; multi method infix:<+>(Int $self: Int $arg) { return 0; } }; say 5.&infix:<+>(2) 11:51
masak now, that's a bug.
p6eval rakudo 0331d6: OUTPUT«Parameter type check failed; expected Complex, but got Int for $a in call to infix:+␤in sub infix:+ (src/gen_setting.pm:876)␤called from Main (/tmp/H9mrDeSBVN:0)␤»
flip214 Well? What did I say?
Listen to me, man...
masak submits rakudobug
flip214: sure, but write it right the first time. :)
moritz_ flip214: I'll repeat it one last time: defining an infix operator as a method makes no sense at all.
TiMBuS also, where is $a
masak moritz_: but if you do, shouldn't you be able to call it?
flip214 moritz_: so if I do that some more, you won't complain? 11:52
TiMBuS i guess its from the 'real' infix:<+>
moritz_ flip214: no, I'll just ignore you
masak: no idea
11:52 NorwayGeek joined
flip214 So, for me it's indistinguishable ... I won't hear from you ;-) 11:52
masak doesn't know whether to submit the bug anymore
moritz_ masak: it boils down to the question whether you can attache attributes to a method as part of the long name 11:53
flip214 moritz: how would I define operators on my classes? I'd thought that's the way to go. 11:54
11:54 Grrrr joined
flip214 I guess I'll be off to S13 11:54
masak moritz_: I don't understand.
11:55 ejs1 left
masak moritz_: 'attributes' as in Perl 6 OO attributes? 11:55
or in some other sense?
moritz_ in some other sense, I assume 11:56
flip214 I think that's about the signature of the function/method
moritz_ just like :auth and :version are some kind of attributes
which are part of the long name
flip214 "Does the signature of a function take place in the long name of a method" or something like that
masak moritz_: I think you need another name for those than 'attribute'.
today, t/spec/integration/99problems-21-to-30.rakudo failed in the spectest harness. when run standalone, it passes. 11:57
it prints what looks like debug information before test 10.
11:57 christine left
moritz_ masak: and I think we need more specs for that too (hilighting TimToady here :), just like for the :sym<...> part of proto regexes. I think too much of that is either implied by other parts of the spec, or just in some people's head 11:58
11:58 KatrinaTheLamia joined
masak moritz_: oh, I agree fully. 11:58
call it 'epigenetic specification' :)
masak is a bioinformatician 11:59
11:59 christine joined 12:00 allbery_b joined 12:02 buubot joined
moritz_ pmichaud, jnthn: we'd need some help from one of you in the native-complex branch: 3.5i should emit a call to Complex.new(0, 3.5) - that would greatly help us to actually test what we're doing right now :-) 12:03
12:04 rblasch joined
moritz_ currently I can't even find where that case is handled 12:04
flip214 Is there a complex Rat, too? 12:06
Or a ratty Complex.
masak guesses 'no'
just like there's not an integral Complex 12:07
flip214 What's that?
masak they're called 'gaussian integers', I believe.
it's (m + ni) where m and n are integers.
they're interesting; they have their own definition of primality, for example. 12:08
flip214 oh, ok
colomon Actually, the current "new" implementation of Complex on the branch allows for any sort of numeric component to be the real and imaginary parts of a Complex.
masak oh?
it's a parameterized role?
colomon All my tests so far have involved complexes made of two Ints.
moritz_ no
colomon No, it's just Any.
moritz_ it's just untyped
flip214 back to the question: masak | it's a parameterized role? 12:09
masak it could as well be Num, because Num covers Int and Rat.
Juerd masak: I'm reading your Squerl journal post. How do you decide between $foo.bar: ...; and $foo.bar(...);?
masak Juerd: usually I'm very much in favor of the latter.
flip214 and if it is, does it make sense to give two different types for .re and .im? 12:10
colomon Num doesn't cover Int and Rat right now, they are all distinct types.
masak Juerd: in this case, it was an urge to make it look more like the Ruby code I was copying that made me use :
12:10 ejs2 left
Juerd masak: Oh. I was hoping for some nice chunk of wisdom :) 12:11
colomon moritz_: Just to avoid duplication of effort, I should point out I've already checked in some stuff for Complex on the branch.
12:11 ruoso joined
masak Juerd: that would be 'avoid the invocant colon as much as possible' :) 12:11
moritz_ colomon: yes, I've seen that
colomon: thanks
masak um, in invocations. it's fine in declarations, of course. 12:12
TiMBuS feature request: Match objects can be smartmatched against regexes
colomon I was starting up a separate test file for it -- I haven't spotted anywhere in the spectests that actually test basic complex arithmetic.
Juerd masak: I dunno. $fh.print: LIST; does still sound really convincing.
colomon (But I wasn't looking that hard -- I was doing everything while holding a sleeping child, limiting my typing speed significantly.)
masak Juerd: you have a point there. 12:13
12:13 awwaiid joined, ejs2 joined
Juerd masak: But I don't know why I do like $fh.print: ...; while at the same time I dislike Class.new: ...; 12:13
masak: Maybe it's just a perl5ism, that print thing. 12:14
masak Juerd: it's a bit like some of the practices in PBP, where the Bad Thing isn't so much the syntaxtic feature itself, but the syntactic feature in combination with a lot of other things which make the situation more complex.
moritz_ colomon: oh, I think you're right, there's a significant lack of those tests
masak Juerd: so, using 'unless' becomes bad when the thing being tested becomes a complicated expression...
colomon moritz_: They're easy enough to add, of course. My theory was to grab rat.t, then go through it and make complex versions of the tests for starters, just to have a framework. 12:15
Juerd Especially *when* the thing being tested becomes complicated, I tend to start using "unless".
masak Juerd: in the same way, I've been bitten by the invocant colon when I'd made further calls in the list of arguments. then the parentheses are really useful, and not having them leads to easy logic bugs.
Juerd And for the simple cases, I use "if not $foo" 12:16
Never "unless $foo"
colomon moritz_: but now my theory is it's a good time to walk the dog, so it may be a while before I actually accomplish anything along those lines. :)
masak Juerd: I think I use 'if !' almost 100% nowadays.
but de gustibus.
Juerd I avoid !. 12:17
! is too narrow and tiny for something that has such a huge impact.
Especially when used right next to a $
masak use three of them :P
Juerd Heh.
Then "not" is prettier than "!!!" :)
moritz_ colomon: sure, don't hurry
Juerd Besides that, !!! already means something in P6 :)
masak aye, I realized that.
you'd have to write ! ! ! 12:18
flip214 I'm using "if", "unless", "if !" depending on what I'd expect them to do the most time over ...
moritz_ colomon: that branch was mostly meant to get us started, not as something that has to land soon
masak I think I use 'unless' sometimes in conjunction with 'next' and 'last'...
12:18 payload joined
flip214 so "die if ! $object", "print unless $found{$_}++", and so on 12:18
so that it's reads easily (for me)
12:19 Lorn_ joined
moritz_ next unless /\d/ 12:19
;
or so
is quite readable 12:20
cognominal rakudo: eval( 'sub A::t { print @{$_[1]}, "\n" }; bless {}, A', :lang<perl5> ).t( < j a p h > ) 12:21
p6eval rakudo 0331d6: OUTPUT«japh␤Scalars leaked: 1␤»
cognominal rakudo: eval( 'sub A::t { 1..100 }; bless {}, A', :lang<perl5> ).t 12:25
12:25 arthur-_ left
p6eval rakudo 0331d6: OUTPUT«Scalars leaked: 100␤» 12:25
Woodi masak: just found request for opinion on proto... so i had problems and impressions on what i expected (1. -MCPAN -e shell; 2. apt-get) 12:27
masak Woodi: sure.
not at all unreasonable. 12:28
what I'm trying to take away from your feedback is whether what you experienced as a flaw is something we can fix or not. 12:29
Woodi the biggest problem happen during install; eg. "./proto install web" after installing perl-sqlite failed becouse sqlite was installed (file exists). usully installation fails when dependencies are not installed :) 12:31
masak oh!
well, that certainly shouldn't happen.
I'll see if I can reproduce that.
Woodi and instaling perl6-examples failed becouse there was Test/Harnes.pm in place 12:32
masak Woodi: and you're using the 'master' branch of proto, yes?
Woodi at first then installed-modules 12:33
but maybe not - maybe i created installed-modules with -b switch...
masak uhm.
Woodi i get git://.+ from github page 12:34
masak oh well, I'll see if I can reproduce your bug reports with either branch.
Woodi and if you include urls in project.list would be superb 12:35
masak I doubt we'll do that.
Woodi little tutorial would be nice
masak so now's the time I say 'thanks for volunteering'? :) 12:36
moritz_ Woodi: my current, inofficial master plan is to create an external website that reads the projects.list, and assmebles informations and links about all these projects
masak writes down "Woodi will do a little proto tutorial"
Woodi np man, i can torture you little more later :)
moritz_ but I'm very short on tuits, so it'll take some months to do that 12:37
masak Woodi: looking forward to it. :) Woodi++
moritz_: looks a bit like the yet-unnamed Cheese Speleology project.
moritz_: I was going to call it Mozarella, but I realized it needs to be a cheese type with holes. 12:38
moritz_ :-)
Woodi masak: and for dev project -v would be realy nice... later it can be as planned... 12:39
moritz_ tries to remeber if that geit oost had any holes in it.. probably not
Woodi i mean: more verbousity
masak Woodi: sure. I've tried to keep proto minimal so far, not adding bells and whistles. but I see what you mean. 12:40
Woodi masak: problem is that technical ppls like messages ala linux booting :)
masak Woodi: I personally like installers which don't blabber, like CPAN. but when something goes wrong, one definitely wants the output.
Woodi: I didn't write proto for technical ppls. 12:41
Woodi: I wrote it for people who dislike pain.
Woodi do just debug mode :)
masak patches welcome.
pmichaud moritz_: until we're able to parse 3.5i as a complex constant, it'll have to be handled as (3.5)i
which shouldn't be a call to Complex.new
moritz_ pmichaud: so do I just need a method i in Num? 12:42
12:43 rfordinal left
Woodi is there way to croscompile rakudo for i386/i686 ? 12:43
pmichaud well, that would be (3.5).i 12:46
(3.5)i is postfix:<i>
(assuming there still is such a best)
*beast
over the weekend s1n created a patch for .i during our local hackathon. I didn't get a chance to spectest it. 12:47
looking for the ticket.
12:47 arthur-_ joined
pmichaud RT #62382 12:47
lisppaste3 masak pasted "I've gotten this far in moving infix:<< < >> et al into the Setting" at paste.lisp.org/display/87887 12:49
masak pmichaud: the spectests mostly pass, but I've lost the functionality of gen_junction and gen_whatever.
moritz_ pmichaud: uhm, that doesn't really help here 12:50
masak I'm unsure how to add that back in the Setting, and looking for suggestions.
pmichaud masak: gen_junction ought to be "automatic"
moritz_ in the method i it just multiplies with 1i
masak pmichaud: it is.
pmichaud moritz_: right
brb -- gotta take daughter to school
moritz_ but how and where is 1i transformed into $anything?
masak pmichaud: the trouble is that I need to remove all non-Setting declarations of the ops just to avoid the Null PMC access I'm trying to fix in the first place. 12:51
and that includes the ones in gen_junction and gen_whatever.
moritz_: at parsetime?
12:52 crythias joined
moritz_ masak: sure, somehow at parse time. But where and how? 12:52
masak in actions.pm and by magic? :P
moritz_ oh, it really seems to be parsed as postfix:i already 12:53
12:54 synth joined, synth left 12:56 redicaps left, elmex left 12:57 ejs1 joined, elmex joined
masak Tene: out of curiosity, what's the status of the manga-girl-with-Camelia-wings picture? 12:57
12:59 orafu joined
pmichaud back, briefly 13:00
yes, postfix:<i> is already implemented
13:00 am0c left
moritz_ that's enough to get us started, thanks 13:00
just pushed to the branch 13:01
pmichaud++
pmichaud but in particular, note that ($a)i isn't always the same as Complex.new(0, $a)
unless the constructor knows how to deal with a complex $a :-)
moritz_ good point 13:02
we should have tests for that :-)
flip214 What about (3+3i)i? 13:06
pmichaud rakudo: say (3+3i)i
p6eval rakudo 0331d6: OUTPUT«-3+3i␤» 13:07
masak rakudo++
flip214 rakudo: say ((((1+2i)i)i)i)i
p6eval rakudo 0331d6: OUTPUT«1+2i␤»
flip214 rakudo: say ((1+2i)i)i)
p6eval rakudo 0331d6: OUTPUT«Syntax error at line 2, near ")"␤in Main (src/gen_setting.pm:3469)␤»
flip214 rakudo: say ((1+2i)i)i
p6eval rakudo 0331d6: OUTPUT«-1-2i␤»
13:08 ejs2 left
flip214 So .i is more a "*Complex(0,1)" than a "Complex.new(0, $a)" 13:08
Fine
13:09 ejs2 joined
dalek kudo: 9792a2e | moritz++ | :
Merge branch 'master' of [email@hidden.address]
13:09
13:13 SmokeMachine joined 13:15 crythias left 13:18 ejs1 left
pmichaud I'm okay if .i does something more direct than simply multiplying by 1i; it was just an easy solution at the time. 13:19
in some ways having the method rely on the operator is kinda backwards, I think. 13:20
13:20 payload left
moritz_ isn't the method gone now? 13:21
moritz_ lost of track of what exists and what's gone 13:22
Woodi flip214: look on Complex numbers like on numbers in coordinate system (x,y). x is real part and y is (i)maginary
moritz_ I'll re-read S03 later today, I think
13:23 Lorn left, Gothmog_ joined
Woodi so (0,1) eq 0 + 1i and it is point in coordinate system 13:23
+ is just notation; i * i = -1 13:24
masak rakudo: say i * i
p6eval rakudo 0331d6: OUTPUT«src/call/context.c:1526: failed assertion 'Parrot_pcc_get_regs_used(interp, ctx, REGNO_PMC) > idx'␤Backtrace - Obtained 30 stack frames (max trace depth is 32).␤/home/p6eval//p1/lib/libparrot.so.1.6.0
..[0x2b6a505aedb3]␤/home/p6eval//p1/lib/libparrot.so.1.6.0(Parrot_confess+0x68) [0x…
masak whoa. 13:25
rakudo: say 1i * 1i
p6eval rakudo 0331d6: OUTPUT«-1+0i␤»
masak submits rakudobug
moritz_ i * i should just call sub i(), and fail at that
13:26 payload joined
moritz_ just 12 failing tests files in the native-complex branch :-) 13:28
Matt-W yay 13:30
does that include every single file which uses complex numbers?
13:30 __ash__ joined
moritz_ basically, yes :-) 13:31
Matt-W :)
As long as it's not randomly breaking everything else, things arep proceeding within expected lines
moritz_ aye
getting infix:<**> to work should give us back some of them 13:32
Matt-W :)
moritz_ but $other_job first
13:37 molaf left
Woodi masak: what if i install parrot and rakudo into /usr/local ? proto assumes rakudo is nasted in parrot or vice versa 13:40
so dir is /ur/local/bin
s/ur/usr/
moritz_ in the installed-modules branch you can just tell it where rakudo is installed 13:41
masak Woodi: proto cannot know magically where you have your Rakudo/Parrot. therefore, you have to edit config.proto manually.
Woodi ah right, i'm on master again...
masak Woodi: when you do that, it won't install Rakudo/Parrot.
it works like that because that's the way it has to work, save for some magical way. 13:42
13:46 NorwayGeek is now known as NorwayGeek|Away 13:49 cj_ is now known as cj, Rint joined 13:50 sjohnson joined 13:52 KyleHa joined 13:53 flip214 left, arnsholt joined 13:55 Lorn_ left 13:56 Lorn joined
masak heh, only two test files fail under my patch. :) I can't help thinking that I'm fairly close to a solution. 13:57
moritz_ hm, patch for what? 13:58
masak moving <, >, <=, >= to the Setting.
moritz_ ah, cool 13:59
masak paste.lisp.org/display/87887
but it fails somewhat because I cannot reproduce in the Setting what gen_whatever does.
moritz_ I think you have to manually write Whatever versions 14:01
masak yes, I think so too.
I'll try that.
Matt-W it looks plausible 14:03
moritz_ maybe I should try to write an automatic whatever-operator generator... :-)
masak it feels like a waste to roll out a for loop like this... 14:04
diakopter sprixel: g'morning 14:17
p6eval sprixel 28495: OUTPUT«Undeclared routine:␤ g'morning used at line 1␤»
diakopter o_O
masak rakudo: g'day 14:18
p6eval rakudo 9792a2: OUTPUT«Could not find non-existent sub g'day␤»
masak rakudo: optimal
p6eval rakudo 9792a2: OUTPUT«Could not find non-existent sub optimal␤»
masak is there any precedent to Rakudo's "Could not find non-existent" choice-of-words? 14:19
it still feels borderline tautological to me. 14:20
14:20 zloyrusskiy joined 14:22 Confield joined 14:24 ejs2 left
[particle] could not find non-existent precedent masak 14:24
masak that's right, I don't have any non-existent precedents. :) 14:25
only tighter and looser precedents.
PerlJam masak: you just want to drop "non-existent"? 14:26
masak I haven't thought much about how best to formulate it. 14:27
"Could not call non-existent sub foo" would also work.
moritz_ "could not call sub foo: it does not exist"
PerlJam Well .. it's got to do the name lookup before it gets to the call. 14:28
moritz_ "could not call sub foo: no suitable candidate found"
PerlJam: that's a detail the user is not interested in
masak moritz_: that's actually less informative than not existing.
14:28 Psyche^ joined, pdcawley_ joined
masak moritz_: if it's an only sub, I as a user does not want to hear about candidates. 14:29
s/does/do/
moritz_ masak: that second example was for a different error condition
masak oh, ok.
moritz_ I just think that similar errors should look similar 14:30
"could not call sub foo: ambiguous dispatch"
and so on
14:30 iblechbot joined
moritz_ maybe s/sub/subroutine/ 14:30
14:32 TiMBuS left
masak 'sub' rather than 'subroutine' is not so bad, since there's the keyword 'sub'. 14:33
'curly' instead of 'curly brace' is worse. 14:34
14:44 Patterner left 14:45 pdcawley left, pdcawley_ is now known as pdcawley
[particle] "Error while attempting to call subroutine 'foo': subroutine not found" 14:47
or 'subroutine does not exist' 14:48
mberends "Cannot call subroutine 'foo': not found"
masak likes
[particle] 'not found' and 'does not exist' mean different things 14:49
14:49 __ash__ left
[particle] one assumes the compiler is omnicient. i argue it is not. 14:49
14:50 __ash__ joined
mberends diakopter: how is num.t doing? will it affect interp.js much? 14:51
[particle] mmm... ecmaperl. 14:52
moritz_ [particle]: I don't like the "does not exist", because it might exist, just not in the current scope
[particle] moritz_: i agree
diakopter mberends: some 14:53
[particle] i also believe compiler error messages should be humble and polite, not harsh and terse
14:53 ejs joined
moritz_ agreed 14:54
[particle] how would a butterfly tell you something's wrong?
diakopter METHOD_MISSING NOT FOUND
moritz_ [particle]: it'd flap its wings in some particular angle :-)
[particle] it's all in the hips. 14:55
moritz_ "can't call 'foo': no such sub" # that would be a Unix style error message
diakopter "Undeclared routine" - "you may have declared this routine somewhere, but in the input you gave me!"
masak 'Tried to call &foo, but could not find it'
moritz_ without the sigil please 14:56
masak fair enough.
14:56 nihiliad joined, __ash__ left
moritz_ we should also decide if we want proper sentences 14:56
"... but *I* could not find it"
masak I doubt we'd want that. 14:57
rakudo: sub foo(Int $a) {}; foo("OH HAI")
p6eval rakudo 9792a2: OUTPUT«Parameter type check failed; expected Int, but got Str for $a in call to foo␤in sub foo (/tmp/F9UYeIf5T1:1)␤called from Main (/tmp/F9UYeIf5T1:0)␤»
masak it also bothers me very slightly that 'foo' is mentioned twice in a row in that message. 14:58
is there any situation when those two mentions will differ?
mberends de-commute &
moritz_ well, the 'in foo' is part of the back trace
but as a user I'd expect that it doesn't get that far 14:59
14:59 mberends left
masak then leave it out the first time. 14:59
moritz_ ie that the argument list binding happens before the call
masak: no, that's the wrong solution (IMHO)
[particle] moritz_: i think phrases by default, with a cpan module for more expressive errors
masak moritz_: do you see a way to only say 'foo' once? 15:00
moritz_ masak: yes, have the error occur at the position of the caller, not the callee
diakopter my suggestion: "Unexpected Str $a; expected Int $a NL in sub foo (...
15:00 pmurias joined
masak submits rakudobug 15:01
diakopter (implying that "Str $a" would be the signature if it would have succeeded
)
or 15:02
15:03 mdxi joined
diakopter "Expected Int $a, but got Str for parameter $a in sub foo..." 15:03
masak nice one.
diakopter basically just moves 'parameter' to the end and more concise 15:04
diakopter wades through pugs/src/perl6 changes from TimToady 15:05
colomon moritz_: did your merge to master merge the complex branch 15:08
diakopter ahah! 15:09
sprixel: my $b = { say $b; my $b = 4 }; $b();
p6eval sprixel 28495: OUTPUT«===SORRY!===␤Lexical symbol $b (from line 1) is already bound to an outer scope implicitly␤ and must therefore be rewritten explicitly as OUTER::<$b> before you can␤ unambiguously declare a new $b in the same scope at /tmp/qqcruiX0RZ line 1:␤------> my
..$b =…
TimToady diakopter: one difference is that PARENT:: became symbolic, which cuts down cycles
that's the longest error message (not counting expectation lists) 15:10
diakopter SORRY! (c) Milton Bradley
after all, this is a game, right? :) 15:11
masak there's a beautiful discussion going on at the google-summer-of-code-mentors-list about inappropriate jokes, cultural stereotypes, and open-source communities. it's beautiful because people, while visibly disapproving of the originator's behaviour, are also quite empathic.
15:12 pmurias_ joined
pmichaud ("Could not find non-existent sub...") ...that message is actually coming from Parrot. 15:12
15:12 hanekomu left
pmichaud so "Rakudo" didn't have anything to do with the word choice :) 15:12
diakopter sprixel: package Foo { my Int $b = 4; }; package Foo { my Str $b = "hiya"; }; 15:13
p6eval sprixel 28495: OUTPUT«===SORRY!===␤Illegal redeclaration of symbol Foo (from line 1) at /tmp/1G9uRw1qye line 1:␤------> kage Foo { my Int $b = 4; }; package Foo⏏ { my Str $b = "hiya"; };␤»
15:13 jauaor left
diakopter sprixel: package Foo { my Int $b = 4; my Str $b = "hiya"; }; 15:14
p6eval sprixel 28495: OUTPUT«Potential difficulties:␤ Useless redeclaration of variable $b (from line 1) at /tmp/cqiR5AU5iO line 1:␤------> package Foo { my Int $b = 4; my Str $b⏏ = "hiya"; };␤execute(): execute error: noun__S_package_declarator not yet implemented; srsly!!?!?␤last:
..stateme…
masak by the rules of the game, it's still a Rakudobug. just as a Null PMC access is a Rakudobug.
TimToady diakopter: conformance test is still just a comment :) 15:15
pmichaud masak: I was simply answering the question above...
14:19 <masak> is there any precedent to Rakudo's "Could not find non-existent" choice-of-words?
masak oh, ah. I meant something more like "the words that are displayed there when Rakudo is run". 15:16
:)
pmichaud right
that's the question I was answering... Rakudo didn't choose those words, Parrot did :)
diakopter sprixel: package Foo { Foo::bar }; 15:17
p6eval sprixel 28495: OUTPUT«Undeclared name:␤ Foo::bar used at line 1␤execute(): execute error: noun__S_package_declarator not yet implemented; srsly!!?!?␤last: statement␤T,T__noun__S_package_declarator,BEG,_specific,SYM,END,package_declarator,M,phase,postDo,eval_args,invoker,context at sprixel.pl line
..84.␤»
diakopter sprixel: package Foo { Foo::bar 4 };
p6eval sprixel 28495: OUTPUT«Undeclared name:␤ Foo::bar used at line 1␤execute(): execute error: noun__S_package_declarator not yet implemented; srsly!!?!?␤last: statement␤T,T__noun__S_package_declarator,BEG,_specific,SYM,END,package_declarator,M,phase,postDo,eval_args,invoker,context at sprixel.pl line
..84.␤»
TimToady took it as a post-declared function, I guess 15:18
diakopter std: package Foo { Foo::bar 4; sub bar {} };
p6eval std 28495: OUTPUT«ok 00:02 95m␤»
pmichaud TimToady: I have a question for you about protoregexes, when you get a chance...
nopaste.snit.ch/18112
TimToady are you in a snit? :)
diakopter is sniveling
pmichaud apparently :)
for some reason gist.github.com isn't accepting my nopaste, so I went to the snit.ch one instead :)
sorry, I screwed up the syntax 15:19
let me renopaste
TimToady I see what you meant
15:20 rfordinal joined
pmichaud better one 15:20
nopaste.snit.ch/18113
argggggh
nopaste.snit.ch/18114 # "This time for sure!" 15:21
TimToady I don't believe it should match. The alternatives are constructed by calling the "PEEK" for each known method name, and only the derived one will answer with a B-ish token/fate 15:24
diakopter TimToady: std does seem to parse num.t more quickly 15:25
TimToady maybe you're just getting used to it :)
15:25 Psyche^ left, Psyche^ joined 15:26 Psyche^ is now known as Patterner, am0c joined
pmichaud are something:foo and something:sym<foo> the same "known method name" ? 15:27
or are they different?
TimToady anyway, wrt globals, I think you should find that $*DECLARAND<inpkg inpad> hold the names of the package or pad that it is being declared in
pmichaud does S05 talk about the "regex something:foo { ... }" syntax? 15:28
I don't see it there... I only see "regex something:sym<foo> { ... }"
TimToady pmichaud: STD considers them the same, but it's just sugar, and possibly rots the teeth
15:29 pmurias left
pmichaud so, one(True, False) ? 15:29
;-)
15:29 abra joined
TimToady "Go not to the elves for advice, for they will say both 'yes' and 'no'." 15:30
pmichaud I'm fine with regex something:foo { ... } being sugar for something:sym<foo>
TimToady I've unwanted it a time or two, but not so much as to take it back out :) 15:31
dalek kudo: c8181aa | masak++ | (5 files):
Moved <, >, <=, and >= into the Setting

had to be removed. This includes the nice autogeneration of subs in gen_whatever_pir, which unfortunately translates to eight quite similar methods in the Setting. Improvements welcome.
15:32 envi^home joined
TimToady on your example, if you want to match, the derived rule should offer <nextsame> as an alternative 15:33
pmichaud so, is having a separate "PEEK" method for each protoregex a semi-standard of some sort... i.e., the "expected" solution for P6 implementations?
TimToady STD does this with Regex::ws for instance
well, originally I was going to have it be an attribute of the method itself 15:34
but P5 doesn't really support that
however, it must reflect the actual dispatch
pmichaud that's the way I've been heading as well
TimToady so I made the parallel PEEK method
pmichaud essentially I think I end up keeping track of which method names I've already visited and skip the ones already seen 15:35
that shouldn't be a problem
TimToady presumably P6's .can returns the subs that can be asked for their "peekage"
but the _PEEK solution also works okay 15:36
so I don't think we need to spec it one way or the other
pmichaud right, I agree
so the answer to my original question is that protoregex only considers the most-derived candidates by name (more)
and each most-derived candidate can delegate to its less-derived version by using <nextsame> 15:37
...or does <nextsame> throw things back to the protoregex for the "next longest match"?
diakopter yay: nopaste.snit.ch/18116
TimToady I suspect that STD currently only really handles ||<nextsame>, not |<nextsame>
pmichaud okay. 15:38
pugs_svn r28496 | diakopter++ | [sprixel] first 35 of num.t pass
pmichaud wfmfn.
TimToady so <nextsame>'s LTM is invisible outside
or another way to say it is that we'd have to implement nextsame_PEEK to get the latter 15:39
oh, I guess it'd really be nextsame__PEEK :) 15:40
can't remember my own implementation from moment to moment...
pmichaud I know what you mean :) 15:41
diakopter++ # impressive work
masak diakopter++
diakopter pmichaud: thanks :)
masak: thanks :) 15:42
TimToady ++diakopter :)
masak ++TimToday :)
spread the hypocritical love!
TimToady ++mäsak 15:43
15:43 ChanServ sets mode: +o pmichaud
masak "if a prefix karma autoincrement falls in the forest..." 15:43
15:43 ChanServ sets mode: +o masak, pmurias_ is now known as pmurias, ChanServ sets mode: +o diakopter 15:44 ChanServ sets mode: +v p6eval
pmurias diakopter: how will/does method call work in sprixel? 15:44
diakopter pmurias: it's currently modelling the Perl6 objects as JS objects directly (single-inheritance only), but 15:47
15:48 abra left
diakopter another dispatch/resolution layer (or four) could be added without much difficulty 15:48
so for test 36 of num.t
I'm trying to figure out to what it's resolving .Int 15:49
of $a
15:49 ejs1 joined
diakopter you can enable global trace to see the enter/leave of node type labels 15:50
nopaste.snit.ch/18118
so, variable is not looking in the proper context 15:52
15:53 zloyrusskiy left
diakopter Methodcall needs to alter its childrens' context to be the invocant object instead of the lexical context(-tree) 15:53
15:56 abra joined 15:57 rfordinal left
PerlJam diakopter: you could use Joose to get to Perl 6 objects in JS quickly I think. 15:59
masak synergy++ 16:00
16:00 Student joined
diakopter oh, I see, Methodcall knows nothing about method calls; only sub calls. :) I see... /me writes responder protocol 16:00
TimToady: the dotty ( Methodcall['.'][1] ) isn't lifted to a property of the Methodcall obj.. should it be? 16:02
TimToady method calls are considered a postfix operator 16:03
so in theory it the object should show up as an arg
s/it//
diakopter the .arg is the $a
mikehh rakudo (c8181aa) builds on parrot r41559 - make test / make spectest_smolder (up to r28496 -> #28316) PASS - Ubuntu 9.04 amd64 16:04
diakopter the POST is the '.'[0], and the .dotty of the POST is dotty__S_Dot, and the .methodop of that is... 16:05
methodop,BEG,arglist,longname,args,END,M
I mean, the POST is the '.'[1] 16:06
and so forth
I can find the method name by descending into this.M[1].dotty.dottyop.methodop.longname.name.identifier 16:09
which is fine..
16:10 ejs left
moritz_ colomon: no, that merge commit was unrelated (and an accident) 16:14
colomon moritz_: gotcha 16:16
16:16 justatheory joined
colomon I see there are plenty of failures in the spectest to work on for the complex branch. 16:17
moritz_ an implementation of infix:<**> would help
colomon I'm looking at that.
(among other things) 16:18
16:22 cdarroch joined
moritz_ I hope you saw my other commits in that branch 16:23
colomon moritz_: I keep pulling before I do anything. :) 16:25
moritz_ great 16:26
colomon Actually, once exp and ln work, we get ** for free. 16:29
I've got a quick implementation of exp (not tested or checked in), ln will be trickier.
moritz_ I know ;-)
16:29 ejs1 left
moritz_ no, ln is not much trickier, with inline PIR 16:30
just generate a Complex, set the re and im part
$P1 = $P0.'ln'()
generate a Perl 6 complex 16:31
return that
colomon Hmmmm...
moritz_ I might give it a shot
colomon multi method exp() { Complex.new($.re.exp * $.im.cos, $.re.exp * $.im.sin); }
(I have to be afk for a bit...)
16:32 pmurias left, pmurias joined 16:36 stephenlb joined
diakopter pmurias: to more accurately answer your question, method calls aren't implemented :) 16:36
I just made type coercions work.. 16:37
implemented bigint ** 16:45
moritz_ tries to implement Complex.log 16:46
16:52 mberends joined
masak mberends: oh hai. I expect to give you a Temporal flux draft tonight. 16:55
mberends jipee!
pugs_svn r28497 | diakopter++ | [sprixel] 40/48 pass in num.t 16:59
17:00 ejs joined
colomon moritz_: just realized that exp(Complex) is failing even though I've defined Complex.exp... 17:04
masak does Parrot emply CPS for function calls? 17:05
moritz_ masak: I'm pretty sure it does
colomon: did you add the 'is export' trait?
colomon trying that now...
masak that's yet another strange mismatch between Rakudo and Parrot, then. 17:06
today it was the re-invention of Complex, and lately it's been something with calling conventions.
I increasingly long for first-class continuations in Perl 6, and it just feels so ironic that Rakudo then is built upon a VM that has'em. 17:07
and still they're not even planned to be reachable, except awkwardly through gather/take!
colomon moritz_: "is export" makes exp(Int) fail! 17:08
moritz_ masak: I think TimToady's plan is that not every Perl 6 implementation needs "real" continuations, because not every VM has them
colomon: I just experience the same for log() here
colomon I guess we can define Any.exp and export that? Maybe? 17:09
masak moritz_: which means that one can never write platform-indep Perl 6 which uses continuations. I understand TimToady's rationale, but I still think it's very sad.
17:09 Woodi_ joined
moritz_ colomon: isn't there an Any.exp already? 17:10
colomon: I think the 'is export' doesn't properly add the type constraint to the first arg of the multi... 17:11
colomon: I'm trying now to use an explict multi sub log(Complex $x) { $x.log } instead
there used to be such a bug, but I thought it was fixed.
masak </rant>
moritz_ I might very well be wrong
colomon moritz_: I don't see any sign of Any.exp in Any-num.pm 17:12
17:12 envi^home left
moritz_ bah, now I did this I get a Null PMC access in find_method 17:12
*sigh* 17:13
colomon Trying Any.exp right now... 17:14
17:15 crythias joined
colomon No go. 17:16
moritz_ somehow this is all very strange 17:17
ah
it's because the ordinary sub log() is still in PIR
the multi dispatcher doesn't like that.
colomon exp too, I bet?
moritz_ aye 17:18
src/builtins/math.pir
masak that's the same issue I had today with infix:<< < >> et al.
colomon moritz_: take the obvious approach to getting them out? 17:19
moritz_ colomon: aye
I'm going to take care of log()
colomon I'm trying exp. 17:20
diakopter 47/48 pass in num.t. lazyirc: would someone tell me what this means: is +^1, -2, '+^1 == -2 as promised'; 17:21
moritz_ numerical bitwise negation?
moritz_ guessing 17:22
diakopter numeric xor 17:23
but with what
masak xor is binary.
moritz_ +^1 certainly looks like a prefix operator 17:24
diakopter oh, numeric complement
masak it's two complements' negation.
17:24 pdcawley_ joined
diakopter so in bigints that means... 17:24
moritz_ fun! 17:25
diakopter heh
17:25 ejs left
diakopter downsample/cast to an int? then +^ ? 17:25
colomon moritz_: Huh. Now exp(int) works again, but exp(Complex) is back to failing (even with "is export" on it) 17:26
pugs_svn r28498 | mberends++ | [sprixel.mk] updated 'test' and 'spectest' targets
masak diakopter: that sounds slightly evil.
diakopter masak: ok, but.. 17:27
17:27 pmurias left, pmurias joined
masak diakopter: throw an overflow exception? 17:27
diakopter if the int is bigger than 2 ** 31 you mean? 17:28
pugs_svn r28499 | diakopter++ | [sprixel] 47/48 pass in num.t. Well, one is TODO (b/c lives_ok and dies_ok aren't implemented yet)
masak diakopter: aye.
moritz_ pugs: say +^2**33 17:29
p6eval pugs: OUTPUT«-8589934593␤»
17:29 mariuz left
moritz_ pugs: say +^2**34 17:29
p6eval pugs: OUTPUT«-17179869185␤»
diakopter hrm
pugs: say +^2**65
p6eval pugs: OUTPUT«-36893488147419103233␤»
diakopter wow
diakopter goes hunting in the bigint lib 17:30
moritz_ pugs does real bigints.
pugs: say 2**65
p6eval pugs: OUTPUT«36893488147419103232␤»
moritz_ you see they differ by a sign and 1
+^$x == -$x - 1 or so 17:31
pugs: say +^0
p6eval pugs: OUTPUT«-1␤»
moritz_ pugs: say +^1
p6eval pugs: OUTPUT«-2␤»
moritz_ pugs: say +^-1
p6eval pugs: OUTPUT«0␤»
moritz_ pugs: say +^-2
p6eval pugs: OUTPUT«1␤»
moritz_ yap, that's it.
diakopter ok, easy then
heh
moritz_: thanks
moritz_ diakopter: yw 17:32
17:32 rblasch left
diakopter didn't take a compsci or electrical engineering class 17:32
17:33 barney left
moritz_ the more I touch here, the more shatters to pieces 17:33
$ ./perl6 -e 'say (30).log'
0
./perl6 -e 'say (30.3 + 2i ).log'
3.41114771251532 + 1.5707963267949i
17:34 pdcawley left, pdcawley_ is now known as pdcawley
moritz_ $ ./perl6 -e 'say (30.3 + 0i ).log' 17:34
3.41114771251532 + 1.5707963267949i
why don't i believe that? ;-)
pmichaud I don't think that Rakudo methods do mmd dispatched based on the invocant type yet
*dispatch
moritz_ so I should forget all about 'is export' for that right now?
pmichaud probably
colomon moritz_: ah, the problem I'm looking at is that the test uses Complex *, also not working yet. can fix that quickly.
moritz_ that's easy, yes 17:35
pmichaud and even if it did understand invocant types, I'm not sure that 'is export' knows how to combine multisubs yet
17:35 crythias left
pugs_svn r28500 | diakopter++ | [sprixel] 47/48 in num.t pass (and 1 TODO); moving on to another .t 17:36
pmichaud there's a lot of namespace-management code that tends to want to rebind symbols instead of merge multisubs
and that's a problem for multis
typically I've been simply creating global subs that then redispatch to the first argument
moritz_ and I'm having fun with that (fsvo fun)
pmichaud i.e.,: multi sub log($x) { $x.log }
moritz_ still I don't see why the method form doesn't work 17:37
pmichaud oh, the method form should work, definitely.
lisppaste3 moritz_ pasted "method log() in class Num" at paste.lisp.org/display/87906
moritz_ is there any big WTF in there? 17:38
pmichaud that $N0 = self looks wtfish
moritz_ what's wrong with it?
and how to do it better?
pmichaud why do $N0 = self only to throw the result away on the next statement? 17:39
perhaps you mean $N0 = log $N0 on the next line?
(or ln, or whatever)
moritz_ erm, yes
or should I call self.'ln'() directly? 17:40
diakopter in radix.t, basically :10('0b1110') is synonymous with :10('0b1110'.Int)
pmichaud only if you expect all objects to have a .'ln' method
(which I wouldn't expect)
moritz_ only all Num objects ;-)
pmichaud I wouldn't even expect that, necessarily :-) 17:41
if we know we're wanting to get to a floating-pointish thing, I'd go through the $N0 registers to get there.
moritz_ ok
pmichaud $N0 = self; $N0 = ln $N0; %r = box $N0
at least I'd start there, as it has the least chance of doing bizarr-o things. 17:42
moritz_ bizzaro - the name of the next Perl 6 compiler ;-)
pmichaud or the next phase of Rakudo development after "Rakudo *"
i.e., the "Rakudo Bizarro" series 17:43
moritz_ or that, yes ;-9
pugs_svn r28501 | mberends++ | [sprixel] partial Replication - "A" x 3 gives "AAA" (but so does "A" xx 3)
moritz_ s/9/)/
17:45 abra left 17:46 abra joined
pugs_svn r28502 | lwall++ | [S02,S03,S32] 17:50
r28502 | add Stringy role
r28502 | attempt to distinguish numeric objects from Numeric, Real, Integral, etc roles
r28502 | split Pair into immutable PairVal and mutable Pair
r28502 | split Mapping into immutable PairValSet and mutable PairSet
r28502 | general typological housekeeping that will doubtless gobsmack the implementors
colomon ye heavens, that commit log entry looks scary.... 17:51
mberends implementors, watch your gobs!
ruoso runs to the hills 17:53
moritz_ TimToady++
is the Class class gone?
anyway, that cleans up a lot of things, IMHO 17:56
TimToady there never was a Class class really
moritz_ ok
is Buf ~~ Stringy? 17:57
TimToady I think so
but not Unicodey :)
moritz_ :-)
so how does a function like say() treats its arguments? by calling .encode() on them? or .Stringy, and encode if it's not a buffer? 17:58
TimToady say requires a very low-level stringification that can even stringify a junction
I think that neither ~ nor .Str will work 17:59
since both of those should probably autothread
so, .forcestr or some such
or maybe it's .Buf that that force is :) 18:00
*forces
PerlJam what differentiates .Str and .forcestr such that one autothreads and the other doesn't?
18:00 NorwayGeek|Away is now known as NorwayGeek
moritz_ the one that doesn't needs to be in Object 18:00
TimToady well, but it's Object that actually does autothreading when it notices a junction that wasn't handled by the junction class 18:01
oddly enough 18:02
*notices a method that 18:03
moritz_ I thought that was the dispatcher, and in my mental model that belonged to the meta class, not to Object
PerlJam I told a student today that anyone doing anything new is generally in a state of confusion most of the time. That's how #perl6 often makes me feel. :-)
TimToady well, whatever it is that would say "no such method" otherwise 18:04
it seems more general to put the backstop into Object as a generic CANDO anything rather than making every possible dispatcher handle it 18:05
anyway, under that model, there would be a .forcestr (or whatever) in the junction class itself that says how to stringify a junction 18:07
you can't really write a generic forcestr in Object; each type has to know how to forcestr itself
but anyway, the real name of .forcestr might actually be .Buf 18:09
or some such
moritz_ hm 18:10
TimToady or .Buf calls .forcestr
moritz_ that sounds saner
18:10 |Jedai| joined
TimToady probably should be .FORCESTR since it's often called implicitly, and is less likely to conflict with normal methods if we shout 18:12
moritz_ wfm
PerlJam TimToady: +1
(I always think such special subs should be marked with some symbol, but perl already has the history of shouting) 18:13
18:13 jaldhar left
PerlJam it still bugs me that import isn't all-caps in perl 5 even. 18:13
18:14 nihiliad left, nihiliad joined
TimToady I think I'll change Foo defines * to import Foo just to pull the keyword out front 18:15
even it it does make it look like Python
18:16 alester joined
masak there are worse things than looking like Python. 18:17
moritz_ looking like cobol, or Fortran 77 ;-) 18:18
PerlJam perhaps it's just my mathematical bent, but F77 doesn't look *that* bad. COBOL on the other hand ... ick!
moritz_ PerlJam: well, if you like meaning based on the column position... 18:19
(yes, F77 is still column based)
18:19 jjore left
PerlJam moritz_: only before the 8th column; everything from there on is "free form" 18:20
moritz_ up to the... 78ths?
PerlJam Herman Hollerith's legacy lives on! :) 18:21
moritz_ and identifier length limited to 8, what happens when you use longer ones is up to the compiler
TimToady maybe they should add line numbers to Python on the right
moritz_ :-)
18:22 barney joined
PerlJam They'll be a time in the not-too-distant future when you'll utter something like that and someone will churn out a slang that does it. 18:22
18:23 pmurias left
PerlJam Hmm. making the barrier to entry of language design low enough and we may see a combinatorial explosion of new (but very familiar ;) languages 18:24
s/making/Make/
araujo TimToady, it will look like Haskell! 18:25
18:25 pyrimidine joined 18:26 Jedai left
colomon moritz_: you having any luck with Complex.ln there? I'm still running in circles with Complex.exp, though I have defined some other useful stuff... 18:26
moritz_ colomon: yes, pushed 18:27
18:29 am0c left
colomon moritz_: \o/ 18:29
now to figure out how to merge what I've got with what you pushed... 18:30
18:30 abra left
moritz_ git pull --rebase; # manually merge what git couldn't; 18:33
git add $merged_files
git rebase --continue
diakopter feels slightly blameworthy for r28502 18:34
PerlJam moritz_: why rebase exactly?
18:35 nihiliad left, nihiliad joined
moritz_ PerlJam: it's "a way", not "the way" 18:35
PerlJam sure, and I'm asking what your reasoning is for that way :)
plus I've generally got a "rebase bad, merge good" thing in my head since rebasing is very much like svn 18:36
Tene PerlJam: it avoids the large number of mostly useless merge commits. 18:37
moritz_ well, it creates a linear history which is very easy to inspect
Tene right.
run 'gitk' in rakudo's repo 18:38
colomon darn, do we need basic complex arithmetic tests.... 18:39
moritz_ d.hatena.ne.jp/ku-ma-me/20090916/p1
Tene PerlJam: They don't really *hurt* anything much, just a little less than ideal. 18:40
18:45 zloyrusskiy joined 18:46 zloyrusskiy left
colomon moritz_: Did you do Complex.ln or Complex.log? I seem to only get the latter.... 18:47
moritz_ colomon: .log
there's no .ln, iirc 18:48
colomon moritz_: ah, default base for log is e, eh?
moritz_ it is 18:50
18:50 jjore joined
colomon scrambling to get what I've got into non-embarrassing shape so I can push it. 18:51
I think we're going to have to move abs to the setting before we can get the Complex tests running correctly. 18:52
moritz_ (public code review)++ # makes you care a bit more about your stuff
colomon: that might very well be possible, yes 18:53
colomon moritz_: In this case it just doesn't quite work yet...
is_approx calls abs, if I recall correctly.
moritz_ colomon: that's fine - that's why it's a branch
it's OK to break stuff in branches
(that's how I started it all ;-) 18:54
18:56 NorwayGeek left 18:57 NorwayGeek joined
colomon Okay, I've just pushed what I've got. Complex.exp still fails with a mysterious error message in exp.t, but seems to work okay from REPL. 18:58
oh, duh, failure probably is because of abs.
moritz_ that shouldn't be so hard to move to the setting, shouldn't it? 19:04
rakudo: say abs(-3).WHAT 19:06
p6eval rakudo c8181a: OUTPUT«Use of type object as value␤0␤»
moritz_ WTF? 19:07
colomon moritz_: I was just bracing myself to try it, now I just want to run away gibbering.
moritz_ colomon: I can do it (or at least trying)
colomon go for it!
19:11 pdcawley_ joined 19:12 zerhash left 19:17 pdcawley left, pdcawley_ is now known as pdcawley
moritz_ colomon: done, and pushed 19:19
diakopter doesn't believe in fudging
(anymore/yet) 19:20
radix.t takes 38s to parse
moritz_ does
diakopter for sprixel, I mean
mberends go diakopter! 19:21
pugs_svn r28503 | diakopter++ | [sprixel] 71/195 tests pass from radix.t so far 19:22
19:25 Woodi_ left
pugs_svn r28504 | diakopter++ | [sprixel] 75/195 radix.t 19:31
19:33 pdcawley_ joined
diakopter this test isn't correct, I think: is(:16('0o377'), 0o377, ":16('0o255') converts from octal"); 19:34
19:36 dakkar left
TimToady it's correct according to S02:2630 19:36
19:38 jauaor joined
diakopter the comment says 0o255 but there's 0o377 in the arg 19:39
mberends the description could be made to match the test data
diakopter, you clobbered commit 28501 (partial Replication) 19:40
diakopter mberends: :( sorry 19:41
oh, b/c of the file move/rename
I meant to check for that before I committed; I lapsed
mberends forgiven :) will re-do
I'll ask for a hint how to complete it 19:42
19:44 __ash__ joined
pugs_svn r28505 | mberends++ | [sprixel] partial Replication again - "A" x 3 gives "AAA" (but so does "A" xx 3) 19:46
19:46 Lorn_ joined, Lorn_ left 19:47 barney left
mberends diakopter, in interp.js:232, what member of 'this' indicates whether the function is processing an x or an xx ? 19:47
19:47 szabgab joined
diakopter svn ups 19:48
mberends: put a line at the top of that function that says: throw keys(this); 19:49
that will tell you the members
(and the first member will contain the "Type") 19:50
in its name
mberends ok, thanx :)
diakopter then you can descend each of the members if you want
incl .eval_args
mberends I saw you sometimes descending M.M.M.M etc - confusing! 19:51
19:51 pdcawley left, pdcawley_ is now known as pdcawley
diakopter yeah 19:51
mberends I did try 'this.keys' but that b0rked 19:52
diakopter those highly particularized/tailored paths are usually specific to some pattern of reduction/match, and will of course need to be further generalized as the implementation discovers different varieties of match patterns
moritz_ rakudo: say sqrt(-4 + 0i) 19:53
p6eval rakudo c8181a: OUTPUT«0+2i␤»
mberends diakopter: yes. shall I add radix.t to 'make -f sprixel.mk spectest'? 19:54
diakopter sure :)
it dies at test 86 or something
87
mberends hence the question, do you expect the death to be temporary? 19:55
diakopter oh
no, but nor do I expect otherwise. I don't know
mberends spectest should lock in what has been passed, I was being too hasty 19:56
diakopter oh
19:57 Lorn left, Lorn joined
Tene masak: you has IM? 19:59
19:59 zerhash joined
colomon moritz_: Just pushed working exp. exp.t now passes, ** should work, I suspect a spectest will give us much more interesting results now. 20:05
moritz_ colomon: and I pushed a (partially working) move of sqrt to the setting 20:06
$ ./perl6 -e 'say (-4+0i).sqrt' 20:08
0 + 2i
though misteriously the sub form still fails 20:09
mberends sprixel: say "V8 " x 8 20:11
p6eval sprixel 28505: OUTPUT«V8 V8 V8 V8 V8 V8 V8 V8 ␤»
diakopter neet 20:12
sprixel: say 8 x "V8"
p6eval sprixel 28505: OUTPUT«␤»
diakopter heh
20:12 stephenlb left
moritz_ do you have lists yet? 20:12
diakopter yeah a teeny bit 20:13
sprixel: my @a = 1,2,3; say @a;
p6eval sprixel 28505: OUTPUT«123␤»
diakopter see, sorta
20:13 stephenlb joined
diakopter array, anyway 20:13
moritz_ sprixel: my @a = 1,2,3; say @a[1] 20:14
p6eval sprixel 28505: OUTPUT«execute(): execute error:
..sigil,name,context,value,WHAT,set,toString,increment,decrement,do_Additive,do_Multiplicative,toBool,do_infix__S_Lt,do_infix__S_LtEqual,do_infix__S_Gt,do_infix__S_GtEqual,do_infix__S_EqualEqual,do_infix__S_BangEqual,do_infix__S_lt,do_infix__S_le,do_infix__S…
diakopter doesn't know what that would do
in sprixel, I mean. :) 20:18
moritz_ call method postcircumfix:<[ ]> on the Array object? ;-) 20:19
oh wait, you don't have methods yet
no methods, no cookies
diakopter moritz_: ok, I'm persuaded.. but what about a partial-fudging... that is, only certain files (the ones that even work at all) 20:21
20:22 ruoso left
moritz_ diakopter: sure, that's basically what rakudo does 20:23
diakopter: there's a list of files in t/spectest.data that are supposed to pass (when run through fudge)
diakopter oh ok
maybe mberends or anyone else wants to tackle enabling that? 20:24
:) 20:26
mberends diakopter: maybe :)
the Rakudo t/harness script would need a bit of a rewrite, then I thought it would be better to specify the fudging outside of the test files themselves (somehow, I have the beginnings of a plan) 20:28
moritz_ mberends: the accuracy of meta data is inversely proportional to the distance of data and meta data 20:29
mberends: if you keep the fudging outside, and somebody changes the test, the fudging will break.
masak meta data is just pretentious normal data. :)
diakopter I'm almost tempted to instead mark the tests that *do* pass
with what revision they started passing 20:30
moritz_ diakopter: won't work easily for tests that depend on other code to run first
diakopter runs spec/S03-operators/arith.t 20:31
cj Trey: what's the name of your perl module that does rollbacks? 20:33
cj notes that he is OT again 20:34
masak hugme: hug cj 20:37
hugme hugs cj
20:39 cst2703 joined 20:40 cst2703 left, cst2703 joined
Trey cj: Commands::Guarded 20:41
cst2703 hi there
mberends moritz_: I'm against the current implementation of fudging for the long term, because it pollutes the P6 specification with the deficiencies of poor implementations. I'm thinking of a way to anchor the fudging to the TAP calls (ok, is etc). Admittedly it separates the spec from the fudge, but by just a small distance. I'd like to try anyhow, and if nothing comes of it, at least I'll learn not do it that way ;)
masak cst2703: hi there! welcome to #perl6. 20:42
mberends hi cosimo
20:42 pyrimidine left
moritz_ mberends: looking at TAP output doesn't help with the problem that skip() solves 20:42
mberends TAP input: still fudge, but annotating outside the file.t 20:43
moritz_ hm
mberends: if you come up with a good solution I'm happy to try it out
cst2703 masak: i just read your blog post on use.perl about Squerl. COOL! 20:44
masak cst2703: thanks. :) 20:45
cst2703 i can has?
masak cst2703: go right ahead.
I look forward to someone else using it.
cst2703 masak: where is it? 20:48
masak cst2703: in the Web.pm repo.
cst2703 ok 20:49
cj thanks Trey :) 20:50
pmichaud mberends: why does fudging "pollute the p6 specification?" The test files are still valid Perl 6, even with the fudge markers present. :)
and it's semi-trivial to grep -v the '#?' lines
20:51 cst2703 left
pmichaud I agree that perhaps the test files don't look as "clean" as they otherwise might, but it's very easy to produce "clean" ones whenever we want them. 20:52
mberends pmichaud: fudging looks so hacky, and the t/spec repo is our "official" suite
pmichaud mberends: even the p5 suite has skips and todos :) 20:53
mberends so I don't like that either :)
pmichaud :)
mberends I believe a more elegant approach can work, and I'll try to write a P6 based harness to demonstrate 20:54
TimToady I think fudging is great motivation to make the tests pass :)
mberends heh
TimToady and good for competition :) 20:55
and it's very clear if you're cheating 20:56
if the cheats are hidden, then they can be done secretly
mberends hmm, interesting food for thought... 20:57
masak the previous Temporal synopsis was overspecific. I find that the current one makes the reverse mistake in places. "=item formatter\n\nThe object that will stringify this specific object." yes, and what default does it provide?
and what's the API for the formatter, and the base class/role?
mberends masak: you noticed too! I thought the vagueness was our chance to go crazy! 20:58
masak I guess it is.
I'm in ur Temporal.pod, goin crazy.
mberends go man go!
btw, are all the authors listed at the top signed up to the current revision? 20:59
masak I don't understand the question? 21:00
s/\?/./
cosimo masak: about Squerl again, sorry, going back and forth, what SQLite3.pm are you using?
masak cosimo: the one in perl6-sqlite. 21:01
cosimo weird, that didn't work for me
masak cosimo: the dependencies are listed in deps.proto in Web.pm.
cosimo: in what way didn't it work?
the first =head1 says 'Roles', and then there's no 'Classes' in the whole Temporal.pod. surely that's wrong? 21:02
masak renames it 'Classes' until he hears loud protests
mberends masak: I followed the debate leading to the current revision, which changed huge parts, but most of the authors listed did not participate this time around.
masak mberends: I'm not sure I feel empowered to remove authors. 21:03
mberends masak: the previous version was also role-centric. The roles pun into classes when required.
cosimo masak: sqlite-test.pl died on SQLite3::open()
masak: I don't remember right now the exact error message, but I think can reproduce it 21:04
masak mberends: forgive me if I don't immediately see the benefit of that.
mberends masak: absolutely, each author should decide individually whether to participate.
masak cosimo: I haven't run sqlite-test.pl in a while. 21:05
but I know the Squerl tests all pass.
pugs_svn r28506 | lwall++ | [S06,S11] kill infix:<defines>, replace with statement_control:<import>
mberends masak: I don't see the benefit either, but that's the way it was. The implementation didn't suffer (too much).
masak mberends: I stand by my change s/Roles/Classes/. if someone feels they should be roles, they can explain why first. :) 21:06
pugs_svn r28507 | lwall++ | [STD] replace defines with import
Tene masak: gf has a sketch; she's going to scan and work on it more tonight, she says. 21:07
mberends masak: no objection
masak mberends: then I get either a saner spec or a good explanation.
Tene: cool!
mberends masak: the author I'd like to hear from most is Dave Rolsky, because his experience with the P5 DateTime.pm would be very valuable. 21:09
masak indeed.
I have a slight inclination to do s/DateTime/Time/, for esthetic and Huffman reasons. Ruby seems to do fine calling an equivalent object Time. 21:11
but I'll hold back for now.
Tene inclined to s/DateTime/Cookies/, 'cos kinda hungry 21:13
masak :)
we're trying to have a serious d... did you say cookies? 21:14
21:14 szabgab left
mberends one of the catalysts for this revisionizing was frettled++ fretting about leap seconds and the difference between TAI and UTC. Are we going to address that in Perl 6 land, or in Parrot? 21:15
pmichaud Perl 6 land, likely 21:16
masak it will be fun!
mberends fsvo fun :/
pmichaud I mean, Parrot might address it there also, but somehow I doubt it. Regardless, it'll be nice if we have the Perl 6 stuff in place to address it
(for other implementations not based on Parrot)
mberends ok 21:17
masak Let's Do The Time Warp Again!
mberends :)
moritz_ ;-) 21:18
pmichaud it would also be good to have some p6 code that we can point to when people say "tai wtf?"
21:18 icwiener joined
PerlJam masak: regarding s/DateTime/Time/, I say go for it. 21:23
DateTime makes me think it's implying something about the calendaring system. 21:24
diakopter TimToady: the ast for the following is incomplete: 21:25
std: /i/
p6eval std 28507: OUTPUT«ok 00:01 95m␤»
moritz_ OMG I HAZ BLOGGED: perlgeek.de/blog-en/perl-6/lots-of-momentum.html
diakopter rakudo: say /i/ 21:27
lisppaste3 moritz_ pasted "test summary in the native-complex branch" at paste.lisp.org/display/87918
p6eval rakudo c8181a: OUTPUT«_block50␤»
masak OMG, Temporal.pod specified year-of-week! srsly!
PerlJam heh 21:28
masak moritz_++ # a fine post of blog indeed 21:29
mberends moritz_++ # we live in exciting times 21:34
masak: week-of-year is ISO8601, but what does year-of-week mean?
masak mberends: it means that no-one ever reads Temporal.pod :/ 21:35
except when they want to change it, like me.
mberends: this is what I have so far: github.com/masak/temporal-flux-perl...2edd541371 21:37
frettled mberends: Thanks, but I like to think of my self as frettling, not fretting. ;)
masak I'll make another, similar one for Gregorian::Duration.
PerlJam masak++ 21:38
mberends frettled: I'll remember that
frettled hee-hee
21:38 PacoLinux left
frettled I don't know what to frettle means, though. 21:38
mberends frettled: you may spec it, implement it and copyright it 21:39
21:39 PacoLinux joined
frettled and then eat some cake 21:39
mberends I thought some might have frettled you in the past 21:40
*someone
frettled :) 21:42
masak: FWIW, s/DateTime/Time/ seems sensible enough. Less typing, no loss.
21:42 hercynium joined
masak frettled: I'll count that as one vote and stand by for a while longer. 21:43
frettled Hmm, Temporal.pod has had a few changes since last I had time (pun intended). 21:44
mberends hesitates to vote. Date is date-only, Time is time-only, DateTime is both. Ok, vote against.
frettled Well, that's one way to look at it. 21:45
mberends timtowtlai 21:46
frettled Another is to say that Time is the superset, Date is a specific subset of Time, TimeOfDay is another subset.
moritz_ colomon: Complex.new($.re.Num.exp * $.im.Num.cos, $.re.Num.exp * $.im.Num.sin); - is that correct? I somehow can't see how it would...
frettled I think that it's a little bit problematic - but only a little bit - that specifications etc. say «time» when the meaning is «time of day». 21:47
mberends the bikeshed is over there...
frettled haven't got the time ;)
mberends lol 21:48
21:49 Whiteknight joined
frettled Hmm, so the current draft of S32/Temporal only allows TAI seconds as input, references an epoch of some kind, but doesn't say what that epoch is. 21:51
I suspect that it would be natural to use the point in time when TAI and UT2 were in sync, 1958-01-01 00:00:00.000 21:52
in which case, it would also be natural to add sugar to handle the 32-bit Unix epoch 1970-01-01 00:00:00 UTC, since people are still quite fond of that. 21:53
Oooh, neat, there's a module on CPAN for lots of this stuff: Time::UTC 21:54
(and Time::TAI and and and)
Andrew Main has done quite a bit of work on this.
mberends frettle: verb 1. to change one's mental state from calm competence to progressively worse confusion; 2. to impose that state change on others 21:55
frettled lovely!
masak mberends: next load: github.com/masak/temporal-flux-perl...a8e67f70b4
21:55 tak11 joined
mberends I am frettled 21:56
masak mberends: I'm done now.
mberends reloads
21:56 FCO joined, SmokeMachine left
masak let's spend the rest of the week writing spectests and Rakudo implementation! :) 21:56
mberends can it be done with 2.5 tuits?
frettled are those metric tuits or imperial? 21:57
masak if you just nibble on them each time, yes.
colomon moritz_: what are you questioning there?
masak
.oO( unladen tuit )
colomon I'm pretty sure the math is correct, unless a typo has snuck in.
frettled masak++
moritz_ colomon: the mathematical correctness - it's not obvious to me where it comes from
colomon moritz_: complex exp and trig functions are all tied together. 21:58
masak sleep &
moritz_ colomon: that much I know ;-)
colomon en.wikipedia.org/wiki/Exponential_f..._complex_z
21:59 masak left
colomon is where I got it from. :) 21:59
frettled masak: I concur, but allow me to amend it a little bit: sleep(3600*7.5)
colomon exp.t passes with it, but probably isn't thorough enough to be really confident. :)
frettled g'night, I'll try to be a good boy and do something useful this week
moritz_ colomon: eek, it's so simple ;-)
frettled (besides, tomorrow night is blogging night again ;)
moritz_ colomon: thanks for the link 22:00
colomon moritz_: math is beautiful. 8)
moritz_ unless when it's not
22:00 |theJackal| joined
moritz_ and your Green's functions all have major poles 22:00
and you have to resolve to all sorts of trickery 22:01
colomon: just pushed a fix for .sqrt which in turn also fixed .abs on Complex 22:02
and by the same token is_approx 22:03
colomon \o/
moritz_ arith.t and perl.t pass again
as well as the integration tests
colomon you haven't fixed complex division, have you?
moritz_ just 11 files left
colomon: no 22:04
colomon yeah, we definitely need to add tests for Complex. :)
moritz_ there are basically two ways we can implement infix:</> 22:05
one is via inline PIR
the other is to do the basic math in Perl 6
colomon It's a reasonably simple formula.
22:06 mberends left
moritz_ aye 22:06
I think I'll go for it
colomon rakudo 22:07
rakudo: my $x; $x = $x + 1i; say $x;
p6eval rakudo c8181a: OUTPUT«Use of uninitialized value␤0+1i␤»
moritz_ comples division pushed (untested) 22:10
that was a mistake ;-)
oh wait
just didn't finished compiling yeet ;-)
at least Complex / Real works ;-) 22:11
22:13 iblechbot left
moritz_ and Real / Complex too 22:15
22:17 ascent_ left
moritz_ ok, Complex / Complex also works now. Bed time here. 22:17
colomon moritz_++ 22:18
22:18 kent\n left
colomon rakudo: say 1i == 1i; 22:20
p6eval rakudo c8181a: OUTPUT«1␤»
colomon rakudo: say 1i == 1;
p6eval rakudo c8181a: OUTPUT«1␤»
colomon ah, the suck of Rakudo's complex handling. 22:21
moritz_ easy to fix in the setting - by adding hundreds of multis ;-)
22:22 ascent_ joined
colomon rakudo: my $x; $x *= 1i; say $x; 22:24
p6eval rakudo c8181a: OUTPUT«0+1i␤»
colomon that there is crazy.
moritz_ but it's a good way to be crazy 22:25
pugs_svn r28508 | colomon++ | [t/spec] Change complex tests to use is_approx rather than ==.
moritz_ undef is interpreted as the neutral element of the operation
colomon It figures out to autovivify as 1 if you're multiplying and 0 if you're adding.
I assume the zero-argument operators are involved somehow... 22:26
So, autovivification.t works with those changes to the test.
22:30 icwiener left
colomon Just pushed a fix to make minmax.t work. 22:34
22:37 KyleHa left 22:40 nihiliad left 22:42 jauaor left
moritz_ not quite in bed... made log10 working (and pushed) 22:45
22:53 nErVe joined 23:09 nErVe left 23:15 clintongormley left 23:22 arthur-_ left 23:26 ihrd joined 23:27 ihrd left, FCO left 23:32 cdarroch left 23:40 meppl left 23:41 patspam joined 23:42 patspam1 joined, patspam left, ruoso joined
diakopter zipadeedoodah 23:49
23:50 TiMBuS joined