Camelia, the Perl 6 bug

IRC log for #perl6, 2011-02-04

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs

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

All times shown according to UTC.

Time Nick Message
00:03 stifynsemons left #perl6
00:04 felliott joined #perl6
00:10 icwiener left #perl6
00:14 Chillance left #perl6
00:23 rgrau left #perl6
00:39 vmspb left #perl6
00:45 felliott left #perl6
00:51 felliott joined #perl6
00:53 bluescreen left #perl6
00:55 felliott left #perl6
00:56 lichtkind left #perl6
00:59 snarkyboojum how (im)possible would it be to write a Perl 6 parser in C? :D
01:00 sjohnson snarkyboojum: SMOP
01:00 sjohnson http://www.perlfoundation.org/perl6/index.cgi?smop
01:01 sjohnson not sure how far along it's coming, however.
01:01 sjohnson maybe it wasn't as simple as they thought ;)
01:01 snarkyboojum sjohnson: how much of Perl 6 does it parse? :D
01:01 snarkyboojum sjohnson: cheers for linkage
01:01 sjohnson ruoso / pmurias could tell you  :)
01:03 snarkyboojum there doesn't seem to be a smop target for evalbot
01:13 snarkyboojum Parsing Perl 6 (in any language) sounds like an interesting thesis topic :P
01:21 colomon flussence: fixing << >> quoting has been on my to-do list for about five months now, I think.  :)
01:25 patspam left #perl6
01:28 Limbic_Region joined #perl6
01:29 drbean joined #perl6
01:31 ab5tract joined #perl6
01:38 patspam joined #perl6
01:41 stifynsemons joined #perl6
01:42 sorear good * #perl6
01:42 phenny sorear: 03 Feb 10:18Z <jnthn> tell sorear type check cache is presntly exhaustive. May or may not change that when I do subsets or other bits. May be a flag. Sometimes we want to reject ast too.
01:42 phenny sorear: 03 Feb 10:20Z <jnthn> tell sorear the thing that handles the boxing/unboxing is NYI, as I mentioend yesterday. P6str is used as the repr of str. In the case you mention "foo" should never get boxed, as it's a waste.
01:42 phenny sorear: 03 Feb 10:21Z <jnthn> tell sorear best thing on the native types is to wait a bit before copying it. I've some pieces still to work out the precise details of.
01:43 sorear jnthn: on now?
01:46 colomon \o
01:50 patspam left #perl6
01:51 sorear ruoso is back in #perl6?
01:52 dukeleto left #perl6
01:53 dukeleto joined #perl6
02:00 sjohnson looks like it
02:00 noganex_ joined #perl6
02:03 jevin joined #perl6
02:04 noganex left #perl6
02:14 ab5tract left #perl6
02:16 felliott joined #perl6
02:20 cdarroch left #perl6
02:29 _jaldhar joined #perl6
02:29 colomon huh
02:29 sjohnson o
02:29 sjohnson oops, hi
02:30 colomon sjohnson: hello
02:30 colomon so, when I try to add infix:<+> for two FatRats, I get "Can't import symbol &infix:<+> because it already exists in this lexical scope"
02:31 colomon my declaration is "multi sub infix:<+>(Math::FatRat $a, Math::FatRat $b) is export(:DEFAULT)"
02:31 colomon Is there something obvious I'm missing?  Because it sure seems like that error is not appropriate for multi...
02:33 whiteknight left #perl6
02:33 colomon If I switch it to infix:<FR+>, it works fine...  :\
02:36 drbean left #perl6
02:38 Tene colomon: sounds like rakudobug to me.
02:39 colomon Tene: That's what I'm thinking too, but I've been confused by import / export issues before...
02:47 snarkyboojum what does is export(:DEFAULT) do?
02:47 sjohnson looks like it exports default symbols
02:47 sjohnson could be wrong though :)
02:47 Tene adds it to the default list of symbols to export to scopes that use that module.
02:47 snarkyboojum sjohnson: what does "exports default symbols" mean?
02:48 colomon it says "export this sub from this module."
02:48 snarkyboojum what's the difference between that and just 'is export'?
02:48 colomon snarkyboojum: as far as I know, there is none.
02:48 Tene None.
02:48 colomon :DEFAULT is just a little more explicit.
02:49 Tene You can give other tags for it to be in, though.
02:49 snarkyboojum ok
02:49 Tene :MANDATORY, iirc, is always exported even if you ask for a different tag set, or nothing.
02:49 Tene or is export(:foo)
02:49 Tene then it's only imported when you ask for the :foo tags
02:49 Tene etc.
02:50 snarkyboojum colomon: does it work if you don't specify 'is export'? (newbie questions here) :)
02:51 stifynsemons left #perl6
02:52 colomon without "is export", it doesn't complain, but it doesn't get that operator, either.
02:53 colomon so it converts the FatRats to Nums before doing the math.
02:53 snarkyboojum how about just using 'is export' without the :DEFAULT adverb or whatever it's called
02:54 colomon trying...
02:54 colomon "Can't import symbol &infix:<+> because it already exists in this lexical scope"
02:55 snarkyboojum how bizarro
02:56 colomon believe me, I'm not enjoying it.  :\
02:56 sjohnson let the good times roll, with perl 6
02:56 snarkyboojum what would 'our multi sub infix:<+>(Math::FatRat $a, Math::FatRat $b) is export' do?
02:56 snarkyboojum package scope or some such?
02:56 colomon adding our, you mean?
02:56 snarkyboojum yeah
02:57 colomon exact same result as without the our.
02:57 snarkyboojum ok. thanks for entertaining my questions :)
02:57 colomon thanks for thinking systematically!  my brain is pretty fried tonight.
02:57 snarkyboojum shouldn't 'our' install the operator in a different scope or something?
02:59 colomon yes, or something.  (I've never quite understood what it does in this context.)
02:59 colomon and I don't think it does what it's supposed to in this context yet.
02:59 snarkyboojum another permutation would be to use our without 'is export' hehe :)
02:59 colomon trying...
02:59 snarkyboojum I seem to remember it needing to be there for rakudo, but that's fuzzy and probably totally wrong :)
03:00 colomon it's exactly the same as leaving off is export without our -- no complaints, but the code doesn't see the new operator, either.
03:01 colomon guess I should be trying to golf this.
03:01 snarkyboojum oh well, should make for entertaining (if not annoying) reading for anyone backlogging :)
03:01 colomon :)
03:01 snarkyboojum and I should probably read S11
03:01 colomon me too.  ;)
03:07 patspam joined #perl6
03:13 colomon huh.  My super-simple golf doesn't duplicate the problem.  :\
03:13 patspam left #perl6
03:13 colomon aha!
03:13 mkramer1 joined #perl6
03:17 snarkyboojum me neither, but my super simple golf doesn't do what I expected it to do either :)
03:18 Sarten-X left #perl6
03:19 stifynsemons joined #perl6
03:22 snarkyboojum colomon: e.g. https://gist.github.com/810690
03:23 snarkyboojum colomon: but then, nfi :)
03:23 colomon I don't think "is Num" works yet.
03:24 snarkyboojum colomon: doesn't work without it.. and I get max recursion errors if I do 'does Numeric'
03:24 colomon one sec
03:24 snarkyboojum if I just do class A {} I get 'Can't take numeric value for object of type A'
03:24 snarkyboojum k
03:26 Sarten-X joined #perl6
03:27 colomon okay, one step at a time, I guess.
03:27 colomon rakudo: https://gist.github.com/810690
03:27 p6eval rakudo 2666b6:  ( no output )
03:28 snarkyboojum didn't know evalbot could run gists - cool :)
03:29 colomon it's a new feature, I'm not even sure if it worked there.  :)
03:30 snarkyboojum that's what I get locally :P
03:30 colomon it actually looks like the is Num part there is working.
03:30 snarkyboojum rakudo: https://gist.github.com/810690
03:30 p6eval rakudo 2666b6: OUTPUT«maximum recursion depth exceeded␤  in 'Numeric' at line 3159:CORE.setting␤  in 'Numeric' at line 3159:CORE.setting␤  in 'infix:<+>' at line 7454:CORE.setting␤  in 'infix:<+>' at line 502:CORE.setting␤  in 'infix:<+>' at line 502:CORE.setting␤  in 'infix:<+>' at line
03:30 p6eval ..502:CORE.settin…
03:30 snarkyboojum looks it works :)
03:31 snarkyboojum though it'd be confusing aligning backlogged output with versions of a gist, but anyway :)
03:31 snarkyboojum perhaps p6eval, could spit out the version of the gist is ran ;)
03:32 snarkyboojum it*
03:33 colomon Okay, now with "does Numeric", what you're doing is saying "this class will do the Numeric role".
03:33 colomon I'm pretty sure you'll find that Numeric.Numeric is implemented as { self; }
03:33 snarkyboojum :S
03:33 colomon since if you have a Numeric type and you ask for a Numeric type, then all you need to do is return yourself.
03:33 snarkyboojum rakudo: https://gist.github.com/810690
03:33 p6eval rakudo 2666b6: OUTPUT«Can't take numeric value for object of type A␤  in 'Any::Numeric' at line 1456:CORE.setting␤  in 'infix:<+>' at line 7454:CORE.setting␤  in main program body at line 29:/tmp/uuwoAO3tI2␤»
03:33 snarkyboojum that's just class A {}
03:34 snarkyboojum rakudo: https://gist.github.com/810690
03:34 p6eval rakudo 2666b6:  ( no output )
03:34 snarkyboojum :)
03:34 colomon wait, the explanation I was embarking on makes no sense.  sigh.
03:35 colomon too tired, should be going to bed.
03:35 snarkyboojum I'll stop stirring the muddy water then :)
03:35 lopnor is now known as lopaway
03:36 szbalint oh joy, time to catch a flight
03:40 colomon snarkyboojum: I don't think your infix:<+> declarations are doing anything there.
03:40 snarkyboojum yeah, not sure they're being used :D
03:40 colomon I've just deleted them and gotten the same results in two of the cases.  :)
03:41 snarkyboojum colomon: hehe. muddy. water. etc.
03:42 snarkyboojum apparently S13 talks about an 'is exported'
03:42 snarkyboojum is that a typo?
03:43 colomon presumably.
03:43 colomon okay, the "does Numeric" case.
03:44 colomon You're supposed to have arithmetic operators for classes that do Numeric.
03:44 colomon when you don't, it calls
03:44 colomon our multi sub infix:<+>($a, $b) {
03:44 colomon +$a + +$b;
03:44 colomon }
03:45 colomon ie, converts $a and $b to Numeric and then calls infix:<+> on them again.
03:45 colomon since $a and $b already are Numeric, this creates an infinite loop.
03:45 snarkyboojum colomon: ah - nasty error in that case
03:47 patspam joined #perl6
03:47 patspam left #perl6
03:47 patspam joined #perl6
03:47 colomon so, your case where it's not Num or Numeric.
03:48 snarkyboojum yeah...
03:48 colomon In that case, you still call the above infix:<+>
03:48 snarkyboojum oh, so it still wants a Numeric type?
03:49 colomon but this time +$a calls Any.Numeric, which dies with the "Can't take numeric value" message you got.
03:49 snarkyboojum so you're not truly overriding the op..
03:50 colomon you didn't override the op, you just declared it without a body, so it called the default Any version.
03:51 snarkyboojum colomon: same errof if a body is provided
03:51 snarkyboojum and { ... } is a body isn't it?
03:51 snarkyboojum a "not implemented" body :D
03:51 colomon apparently not, based on what we've just done!  :)
03:51 snarkyboojum well even providing a body still results in the same error "Can't take numeric value for object of type A"
03:52 colomon you're right about the same error if a body is provided, I don't understand that.
03:52 snarkyboojum maybe it's is exported not doing the right thing - nfi
03:52 sorear good * #perl6
03:52 snarkyboojum o/
03:52 colomon \o
03:53 masonkramer joined #perl6
03:53 snarkyboojum sorear will be able to put his finger on the issue :P
03:54 snarkyboojum but I don't want to distract him from hacking on Niecza :D
03:55 benabik joined #perl6
03:55 Limbic_Region left #perl6
03:57 colomon if you take infix:<+> out of class A, it works as you'd expect.
03:58 felliott left #perl6
03:58 colomon actually, I think I'm gonna report this as a bug as well.
04:00 lopaway is now known as lopnor
04:03 snarkyboojum colomon: yeah, it's just not registering the infix op
04:03 colomon bug submitted.
04:04 VXZ joined #perl6
04:05 colomon BTW, if you call infix:<+> in the class body, it does call the infix:<+> defined there.
04:05 colomon rakudo: https://gist.github.com/810730
04:05 p6eval rakudo 2666b6: OUTPUT«hello␤Bool::True␤Can't take numeric value for object of type A␤  in 'Any::Numeric' at line 1456:CORE.setting␤  in 'infix:<+>' at line 7454:CORE.setting␤  in main program body at line 35:/tmp/v0KEVEd_Ea␤»
04:05 colomon afk # bed
04:06 snarkyboojum colomonČ laku noć
04:06 snarkyboojum eek
04:08 patspam_ joined #perl6
04:09 patspam_ left #perl6
04:09 patspam_ joined #perl6
04:12 patspam left #perl6
04:12 patspam_ is now known as patspam
04:13 Sarten-X left #perl6
04:17 sorear snarkyboojum: niecza is blocking on jnthn++'s tuits; I have spare cycles; what do you want?
04:18 mtk left #perl6
04:18 snarkyboojum sorear: just something colomon was trying to work out with rakudo as you said good * earlier.. feels like we're missing something obvious :)
04:23 Su-Shee_ joined #perl6
04:24 Su-Shee left #perl6
04:25 satyavvd joined #perl6
04:26 mtk joined #perl6
04:28 patspam left #perl6
04:28 patspam joined #perl6
04:38 patspam left #perl6
04:42 snearch joined #perl6
04:47 snarkyboojum Who's doing future rakudo releases? Schedule looks MT.
04:54 Sarten-X joined #perl6
04:54 karb joined #perl6
04:58 karb left #perl6
05:00 sorear MT?
05:01 jdhore Michael Tiemann?
05:01 jdhore :P
05:17 snarkyboojum empty ;)
05:23 Grimnir_ left #perl6
05:25 Topic for #perl6 is now »ö« Welcome to Perl 6! | http://perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: http://irc.perl6.org/ | UTF-8 is our friend!
05:26 Grimnir_ joined #perl6
05:46 Chat8090 joined #perl6
05:47 Chat8090 left #perl6
05:48 stifynsemons left #perl6
05:52 envi joined #perl6
05:56 simcop2387 left #perl6
05:57 simcop2387 joined #perl6
06:05 cjk101010 joined #perl6
06:19 snearch left #perl6
06:22 uniejo joined #perl6
06:24 uniejo left #perl6
06:24 uniejo_ joined #perl6
06:41 * sorear -> sleep
06:52 Chillance joined #perl6
06:55 Chat7352 joined #perl6
06:56 Chat7352 left #perl6
07:00 kaare_ joined #perl6
07:05 dalek std: fe05c9c | larry++ | STD.pm6:
07:05 dalek std: warn on Useless use of [] around infix op
07:05 dalek std: review: https://github.com/perl6/std/commit/fe05c9c6b2
07:19 diakopter TimToady!
07:19 cognominal left #perl6
07:19 TimToady we got back from India, it would appear
07:20 cafesofie left #perl6
07:20 diakopter You probably didn't travel by apparition
07:21 wtw joined #perl6
07:21 * diakopter hopes masak & moritz read this
07:23 TimToady we were one day late returning, due to Chicago shutting down for a few snow snifters, the wimps
07:23 TimToady oh, I see sorear++ added a similar patch to niecza
07:24 TimToady though I think I prefer my reading...
07:24 TimToady and mine will also complain on 1 [+](1,2,3)
07:28 benabik is now known as benabik_sleep
07:30 cosimo joined #perl6
07:31 cosimo left #perl6
07:32 cosimo joined #perl6
07:32 moritz_ good morning
07:32 jnthn morning
07:32 TimToady o/
07:32 jnthn TimToady: Welcome back. Ö=
07:33 jnthn TimToady: Hope you had a good trip.
07:33 jnthn oops, ESWEDISHKEYBOARD
07:33 * TimToady is back from the land of http proxies...
07:33 jnthn :-)
07:39 drbean joined #perl6
07:41 TimToady phenny: tell sorear a couple days ago I noticed a !%foo{$x}:exists or some such, which is a precedence thinko
07:41 phenny TimToady: yeah, sure, whatever
07:42 diakopter o_.
07:43 TimToady (makes the :exists apply to the ! rather than the subscript)
07:48 IllvilJa left #perl6
07:48 am0c joined #perl6
07:53 [particle] left #perl6
07:53 [particle] joined #perl6
07:54 jnthn When did phenny turn rebellious? :)
08:07 Su-Shee_ is now known as Su-Shee
08:09 uniejo_ is now known as uniejo
08:21 lopnor is now known as lopaway
08:21 lopaway is now known as lopnor
08:26 abraxxa joined #perl6
08:29 justatheory left #perl6
08:36 Intensity left #perl6
08:53 cosimo left #perl6
09:01 colomon TimToady: Rat's source uses a pir call for a GCD function all over the place.  I'm finding I also want a (BigInt) GCD function for the Math::FatRat implementation, of course.  And it's a pretty common number theory function anyway.  Can we go ahead and add a gcd sub to p6?
09:03 moritz_ (maybe in a namespace, like Math::gcd)
09:03 moritz_ but in general, +1 from me
09:04 moritz_ rakudo: say  2 minmax 5
09:04 p6eval rakudo 2666b6: OUTPUT«2345␤»
09:04 * moritz_ surprised
09:04 moritz_ rakudo: say  (2 minmax 5).perl
09:04 p6eval rakudo 2666b6: OUTPUT«2..5␤»
09:05 moritz_ rakudo: sub gcd(Int $x, Int $y) { (($x max $y), ($x min $y), * % * ... 0)[*-2] }; say gcd 24, 16
09:06 p6eval rakudo 2666b6: OUTPUT«8␤»
09:09 colomon moritz_: minmax returns a Range.
09:09 moritz_ yes, so I noticed :-)
09:10 colomon rakudo: sub gcd(Int $x, Int $y) { ($x, $y, * % * ... 0)[*-2] }; say gcd 24, 16; say gcd 16, 24
09:10 p6eval rakudo 2666b6: OUTPUT«8␤8␤»
09:10 cafesofie joined #perl6
09:11 moritz_ ah right, no need for sorting
09:12 colomon I was just thinking about that Sequence... and that the inner loop of a Mandelbrot set script could also be expressed as a Sequence.  :)
09:13 moritz_ well, for the Mandelbrot thing you also need to limit the number of iterations, iirc
09:13 colomon rakudo: multi sub foo(Int $a, Int $b) { say "Foo!"; }; multi sub foo(Num | Int $a, Num | Int $b) { say "Fancy foo!"; }; foo(2, 5)
09:13 p6eval rakudo 2666b6: OUTPUT«===SORRY!===␤Malformed multi at line 22, near "sub foo(Nu"␤»
09:13 moritz_ urks. use Numeric
09:14 colomon moritz_: yes, you make a lazy list of the Sequence and then check to see if it goes (say) 50 elements or not.
09:14 flatwhatson_ left #perl6
09:14 moritz_ colomon: ah, clever idea
09:15 colomon moritz_: Int and Num in the above example are proxies for the real types that I'm thinking of doing something like this with.
09:15 colomon std: multi sub foo(Int $a, Int $b) { say "Foo!"; }; multi sub foo(Num | Int $a, Num | Int $b) { say "Fancy foo!"; }; foo(2, 5)
09:15 p6eval std 625303c: OUTPUT«[31m===[0mSORRY![31m===[0m␤Unable to parse signature at /tmp/VYhxakYClQ line 1:␤------> [32m, Int $b) { say "Foo!"; }; multi sub foo[33m⏏[31m(Num | Int $a, Num | Int $b) { say "Fanc[0m␤Couldn't find final ')'; gave up at /tmp/VYhxakYClQ line 1:␤------> [32m $b) { say
09:15 p6eval .."Foo!…
09:16 colomon std: multi sub foo(Int $a, Int $b) { say "Foo!"; }; multi sub foo(Numeric $a where Num | Int, Numeric $b where Num | Int) { say "Fancy foo!"; }; foo(2, 5)
09:16 p6eval std 625303c: OUTPUT«Potential difficulties:␤  $b is declared but not used at /tmp/JQjbehX4i4 line 1:␤------> [32mmulti sub foo(Int $a, Int [33m⏏[31m$b) { say "Foo!"; }; multi sub foo(Numer[0m␤  $a is declared but not used at /tmp/JQjbehX4i4 line 1:␤------> [32mmulti sub foo(Int [33m⏏[31m$a,
09:16 p6eval ..Int…
09:16 moritz_ colomon: there are no disjunctive types
09:16 colomon rakudo: multi sub foo(Int $a, Int $b) { say "Foo!"; }; multi sub foo(Numeric $a where Num | Int, Numeric $b where Num | Int) { say "Fancy foo!"; }; foo(2, 5)
09:16 p6eval rakudo 2666b6: OUTPUT«Foo!␤»
09:17 colomon oh?
09:17 moritz_ that works, but note that the multi dispatch behavior is different than a hypthetical "real" Int | Num
09:18 moritz_ because here the nominal type is Numeric, and the Int | Num is just a constraint which can contribute an epsilon of tightness
09:19 colomon What I'm really wanting here is the Rational role.  :)
09:20 moritz_ that's what Rat is supposed to be
09:20 colomon you mean, Rat is supposed to be "does Rational"?  yes.
09:21 colomon I mean, class Rat does Rational
09:21 flatwhatson_ joined #perl6
09:22 moritz_ I can't remember exactly
09:23 moritz_ but there should be a role that basically does what Rat does, which is parameterized by the type of numerator and denominator
09:24 colomon Rational[Int,uint64] for example, is our standard Rat.  (this is from S02)
09:24 moritz_ ok
09:25 colomon FatRat is just Rational[Int,Int]
09:25 moritz_ right
09:25 colomon the reason I'm looking at it closely is infix:<+> for Math::FatRat.
09:25 colomon you should be able to add a normal Rat to a FatRat and get a FatRat.
09:26 moritz_ colomon: if it helps you, feel free to add a Rational role to Rakudo, even if it doesn't do much yet
09:26 colomon and the code involved is *exactly* the same in the sub body as adding two FatRats
09:27 colomon Thing is, it feels a little bit funky to me.
09:28 moritz_ that's probably because there are lots of missing pieces in Rakudo
09:28 colomon If you add Rational[A, B] to Rational[C, D], how do you figure out the resulting type?
09:29 moritz_ by dispatchting to the * and + and / operations of types A, B, C and D
09:29 colomon and the rules are actually different depending on that type, because if your add two Rats and they overflow, you get a Num, but if you add two FatRats you always get a FatRat.
09:29 colomon moritz_: that doesn't work, because of the FatRat thing
09:30 moritz_ why not?
09:30 moritz_ if there's a FatRat made of two BigInts, and BigInt * Int returns a BigInt, what's wrong with automatically creating a Rational[BigInt, BigInt] as the result?
09:30 colomon because, $a / $b is always either Rat or Num
09:31 colomon you have to explicitly create a FatRat.
09:31 moritz_ only if $a and $b are Ints
09:31 moritz_ there's no rules that says BigInt / BigInt needs to be Rat or Num
09:31 colomon In p6, Int *is* BigInt
09:32 colomon and BigInt / BigInt does have to be Rat or Num.
09:32 colomon *therefore
09:32 moritz_ or another (Big)Int
09:32 colomon no
09:32 moritz_ rakudo: say (10/5).What
09:32 p6eval rakudo 2666b6: OUTPUT«Method 'What' not found for invocant of class 'Rat'␤  in main program body at line 22:/tmp/63_LygbAwq␤»
09:32 moritz_ rakudo: say (10/5).WHAT
09:32 p6eval rakudo 2666b6: OUTPUT«Rat()␤»
09:33 colomon interesting way to get your answer even with an error.  :)
09:33 colomon rakduo: say (10/5).dghsjkghsdjghsd
09:33 colomon rakudo: say (10/5).dghsjkghsdjghsd
09:33 p6eval rakudo 2666b6: OUTPUT«Method 'dghsjkghsdjghsd' not found for invocant of class 'Rat'␤  in main program body at line 22:/tmp/fqmJrce2PW␤»
09:33 jnthn Perl 6. So awesome even the errors contain the answer you wanted. :P
09:34 colomon "Dividing two Integral objects using infix:</> produces a a Rat, which is generally usable anywhere a Num is usable, but may also be explicitly cast to Num."
09:34 colomon jnthn: \o
09:34 moritz_ colomon: you're right. Actually you need div for dividing by the gcd
09:35 colomon though actually, that should say "Rat or perhaps Num" or something like that.
09:35 colomon moritz_: yup
09:35 moritz_ so the internal Rational code doesn't need to use infix:</>, unless in the case of overflow
09:35 colomon yeah, that's where it gets tricky
09:36 moritz_ what we need is code like   if $a * $b ~~ none($a.WHAT, $b.WHAT) { # degrade to Num }
09:39 colomon hmmm.  "A Rat64 that would require more than 64 bits of storage in the denominator is automatically converted either to a Num or to a lesser-precision Rat, at the discretion of the implementation."
09:40 dakkar joined #perl6
09:40 colomon that's an odd statement, because the Rat64 cannot have more than 64 bits of storage.
09:40 colomon it's more like, if the result of a Rat64 calculation would result in a rational with more than 64 bits of storage...
09:40 moritz_ that's more like it
09:41 moritz_ there should be a create-rat-if-possible($numerator, $denominator, $storage-size) or so
09:42 colomon the way it's written in the spec makes it sound like Rat.new($a, $b) should create a Num in some circumstances, which strikes me as a very odd notion.
09:42 colomon moritz_: yes, create-rat-if-possible.
09:43 colomon needs storage size for numerator and denominator, but the basic notion is dead on.
09:45 Tedd1 left #perl6
09:47 envi_laptop joined #perl6
09:51 envi_laptop left #perl6
09:55 Mowah joined #perl6
09:58 Tedd1 joined #perl6
10:00 masak joined #perl6
10:01 masak greetings, zebras.
10:01 moritz_ \o masak
10:03 colomon afk # back to bed
10:04 daxim joined #perl6
10:04 masak diakopter: fwiw, the technical term is "Apparating" :P
10:05 masak by the way, I think minmax is useless/evil and shoould be destroyed while we have the chance.
10:06 moritz_ why is it evil?
10:07 masak min and max are nice because they extend to min= and max= and other metaops.
10:07 masak minmax, as far as I can see, extends too but extends uselessly.
10:07 masak and serving up the *promise* of extending but failing to deliver is evil.
10:08 moritz_ if [minmax] returned a range from the minimum to maximum value of a list, would you find that better?
10:09 masak what I'm after is a kind of consistency that makes minmax useful even in its meta forms.
10:10 masak there might be one, but neither the current semantics nor the former quite fits the bill.
10:11 moritz_ agreed
10:12 masak another point: minmax returns a Range. that's the same kind of infraction as using Complex for storing 2d coordinates. not necessarily wrong, just... unwarranted.
10:13 masak one surprising consequence is that the return value of minmax stringifies to all the values in the range, as you found in the backlog.
10:17 moritz_ speaking of backlog...
10:18 moritz_ snarkyboojum, sjohnson: smop is "just" an object model + runtime, it doesn't parse Perl 6 by itself at all
10:18 moritz_ there is/was a compiler named 'mildew' that used STD to parse Perl 6, and emitted smop code
10:21 tadzik o/
10:21 moritz_ \o tadzik, how are the exams going?
10:22 masak tadzik! \o/
10:22 tadzik moritz_: cute! There is a chance I passed electronics today. It's a bit tough, and I expected that the second attempt (next thursday) will maybe be succesful
10:22 tadzik moritz_: the worst part now is, sorry, but Physics :)
10:23 moritz_ tadzik: believe me, I know how bad physics can be :-)
10:23 tadzik moritz_: I'm totally dumb from all this, I just can't get my head around stuff
10:24 * masak guesses that has to do with the elasticity of the head :)
10:24 tadzik OTOH, they even changed the rules of passing after they saw how many people passed the exercises
10:24 moritz_ tadzik: that's a common reaction to having to learn too much at a time
10:25 tadzik moritz_: maybe. I'm probably the only one who didn't even take a physics exam after High School, I managed to get on the Uni using CS only, so my lack of knowlegde is alredy covered with dust
10:27 tadzik but, as I expected Electronics will be tough-as-hell, and they turned out to be tough-a-bit, I may even focus for this week and try to pass this Physics instead of abandoning all hope :)
10:28 moritz_ tadzik: I'd happily offer to explain physics stuff, but I found that it's quite hard in a text-only medium. Still if there's something you need explained, it might be worth an attempt
10:29 tadzik moritz_: I think the main thing I need is solving a bunch of exercises, maybe a bigger bunch. I don't have much problem understanding the concepts
10:30 moritz_ tadzik: then you're heading in the right direction :-)
10:31 tadzik yeah, I hope so :)
10:37 cafesofie left #perl6
10:41 tadzik moritz_: how is Ronja?
10:43 moritz_ tadzik: fine, thanks. She's still not heavy enough, but gathers weight faster than expected
10:56 ruoso left #perl6
10:57 shortcircuit left #perl6
11:07 IllvilJa joined #perl6
11:07 am0c left #perl6
11:27 coldhead left #perl6
11:29 kensanata joined #perl6
11:37 lopnor is now known as lopaway
11:42 skangas left #perl6
11:42 skangas joined #perl6
11:45 satyavvd left #perl6
11:45 VXZ left #perl6
11:48 REPLeffect left #perl6
11:54 masak so, a brief revisit to the Yapsi refactor this morning finally took me into the tricky part (having to do with blocks and variable lookups, unsurprisingly). I put it on ice for this evening, but I'm still generally hopeful that I'll be able to finish the refactor in a day or so. especially since there's a weekend coming up.
11:55 REPLeffect joined #perl6
11:55 ruoso joined #perl6
11:55 masak it's very noticeable how the FUTURE layer between the grammar/actions and the SIC serializer steps in an fills a real void in terms of absorbing complexity.
11:58 flussence before I continue this .indent thing, I think I'll go get Text-Tabs-Wrap itself working. In particular the test files seem broken :(
12:00 flussence (also "prove -e perl6" is fast becoming my favourite command line)
12:00 masak :)
12:00 masak I tend to run 'perl6 t/somefile.t' a lot when I'm not just running 'make test'.
12:05 mtk left #perl6
12:07 Trashlord left #perl6
12:07 flussence .oO( the one advantage of having to use CGI.pm is that I get a lot of code golf practice )
12:11 masak flussence: it would seem to me that not golfing, but abstracting yourself up a bit, would be the important priority.
12:11 masak unless additional abstraction layers, even homegrown, count as "cruft".
12:11 flussence they both make the code shorter :)
12:13 masak can't argue with that :)
12:13 mtk joined #perl6
12:27 tadzik I don't quite get dynamic variables: http://nopaste.snit.ch/30466 why is the last one 'undef'?
12:28 tadzik ...and what is undef doing in Perl 6? :)
12:28 moritz_ rakudo: say Failure.new.perl
12:28 p6eval rakudo 2666b6: OUTPUT«too few positional arguments: 1 passed, 2 (or more) expected␤  in main program body at line 1␤»
12:29 moritz_ rakudo: say Failure.new(1).perl
12:29 p6eval rakudo 2666b6: OUTPUT«1␤»
12:29 flussence "undef" is just a stringification
12:29 moritz_ rakudo: say Failure.new(1)
12:29 p6eval rakudo 2666b6:  ( no output )
12:29 moritz_ hm, I recall that it's something to do with failures
12:30 flussence rakudo: say ~(...)
12:30 p6eval rakudo 2666b6:  ( no output )
12:30 flussence hm
12:30 flussence oh
12:30 masak 'undef' is leaking through from Parrot.
12:30 flussence rakudo: say (...).perl
12:30 p6eval rakudo 2666b6:  ( no output )
12:30 flussence pretty sure I saw it from a dotdotdot
12:30 * masak is sad that &say isn't reliable
12:31 moritz_ tadzik: the 'dynamic' part of dynamic variables comes into play when you declare a new  my %*FOO in the inner sub
12:31 moritz_ masak: not leaking through, src/builtins/Exception.pir line 93
12:31 moritz_ masak: and it's not about say(), its about a fail() during a stringification
12:32 masak oh, ok.
12:32 flussence rakudo: sub a { ... }; a().perl.say
12:32 masak I don't think any .perl method in Rakudo should return 'undef'.
12:32 p6eval rakudo 2666b6: OUTPUT«undef␤»
12:32 moritz_ one could argue about whether say() should be specially fail()-prove
12:33 flussence if anything, that should probably return "..."
12:33 moritz_ masak: yep, that's a bug (and a long standing bug)
12:34 flussence it's in src/builtins/Exception.pir:93 btw
12:34 moritz_ 13:31 < moritz_> masak: not leaking through, src/builtins/Exception.pir line 93
12:34 flussence I'm not paying attention today :)
12:39 flussence anyway the best thing I can think of is stringifying it as "fail('self.exception'
12:39 flussence er
12:39 flussence "fail('{self.exception'
12:39 flussence without the typing fail().
12:39 flussence you get the idea :)
12:39 masak gah, there are two 'views' to what a block is during FUTURE traversal. in one view, a block is something to be called or stored into a variable. in another view, a block is something to be serialized as SIC.
12:40 moritz_ doesn't that apply to all things that represent Perl 6 level objects?
12:47 masak perhaps. but it's especially noticeable with blocks, since they nest in FUTURE but not in SIC.
12:47 jnthn masak: Unnested tends to be needed.
12:47 jnthn *unnesting
12:47 jnthn masak: PAST2DNST implements it. PAST -> POST also.
12:48 masak I will probably spend the day thinking about unnesting.
12:49 masak the iteration of Yapsi I'm moving away from does a lot of manually initiated top-down/bottom-up traversal. I'd prefer if things just blended in.
12:49 bluescreen joined #perl6
12:49 * moritz_ still waits for p4 review
12:50 masak I haven't forgot about it :)
12:50 masak (and I'm eager to write it, too)
12:50 arnsholt Excellent! =)
12:56 masak if my free time were more abundant, I'd have snuck in the second preparatory blog post before the Yapsi release. then again, if my free time were more abundant, I'd have started the Yapsi refactor in time. :)
12:56 jnthn masak: Note that the PAST to DNST is written in NQP, so it should be fairly accessible if you want to see hwo it's done there.
12:57 hirschnase joined #perl6
12:57 Vlavv` left #perl6
12:57 Intensity joined #perl6
12:57 jnthn masak: It's with a contextual array and pushing onto it, iirc.
13:00 masak hm, that way of doing things has croseed my mind.
13:00 maja left #perl6
13:03 takadonet mornign all
13:04 masak takadonet: \o
13:05 takadonet flussence: ping
13:06 * moritz_ has now rejected ownership of his RT tickets, and insteaded added the tag 'testneeded' to them
13:07 plobsing_ left #perl6
13:07 masak moritz_++
13:07 masak the days of moritz_ as a human 'testsneeded' tag are over ;)
13:07 moritz_ an era ends. A new one begins.
13:08 Vlavv` joined #perl6
13:12 flussence takadonet: pong!
13:12 takadonet flussence: I saw in the backlog that you wanted to get Text::Wrap-Tabs working?
13:13 masonkramer left #perl6
13:13 flussence yeah, seems like a good place to start in figuring out the last bit of .indent
13:15 takadonet a few quick notes about that module
13:15 takadonet It was my first real attempt of writing a perl 6 module and I was just doing a straight line by line convert from the p5 cpan version
13:17 takadonet I just added you as a collaborator to the project
13:17 flussence cool, thanks :)
13:17 flussence I noticed the t/* files looked a bit perl5ish, maybe that's why they didn't work...
13:24 MayDaniel joined #perl6
13:27 szabgab /wg 17
13:27 masak hugme should hug irssi users, too :)
13:27 moritz_ masak: patches welcome :-)
13:28 masak good to know :)
13:28 colomon rakduo: say ([minmax] 2, 5, 3, 6, 13, -4, 231, 544, 2, 4, 5).perl
13:29 szbalint szabgab: in Brussels yet? :)
13:29 colomon rakudo: say ([minmax] 2, 5, 3, 6, 13, -4, 231, 544, 2, 4, 5).perl
13:29 p6eval rakudo 2666b6: OUTPUT«-4..544␤»
13:29 szabgab szbalint: yes I am here already
13:30 szabgab oh now I see why /wg 17 did not work earlier :)
13:30 colomon rakudo: say ([max] 2, 5, 3, 6, 13, -4, 231, 544, 2, 4, 5).perl
13:30 p6eval rakudo 2666b6: OUTPUT«544␤»
13:30 colomon rakudo: say ([min] 2, 5, 3, 6, 13, -4, 231, 544, 2, 4, 5).perl
13:30 p6eval rakudo 2666b6: OUTPUT«-4␤»
13:31 szabgab szbalint: are you also coming?
13:31 szbalint I'm here already :)
13:31 szabgab oh nice
13:31 moritz_ sounds like an sz.* meeting :-)
13:32 plainhao joined #perl6
13:32 szabgab moritz_: will you come to LinuxTag and give a Perl 6 talk?
13:33 moritz_ szabgab: no. I've abandoned all travel plans for this year
13:33 moritz_ family first
13:34 stifynsemons joined #perl6
13:34 moritz_ ... unless I can't stand it anymore at home, and need to get out :-)
13:34 masak szabgab: when's LinuxTag?
13:34 moritz_ Chemnitz, I think
13:34 szabgab May
13:34 bluescreen left #perl6
13:34 moritz_ oh
13:34 * moritz_ can't read
13:34 tadzik Chemnitz, almost like Chełm :)
13:35 masak unless it clashes with YAPC::Russia, I could go. sounds like fun.
13:35 szbalint moritz_: oh, did your fork() materialize already? :)
13:35 szabgab wasn't that you discussed on the perlde channel?
13:35 moritz_ szbalint: yes
13:35 szabgab last year I gave an ad-hoc Perl 6 talk
13:36 szabgab it would be nice to have one now planned a nd scheduled up-front
13:36 szbalint d'oh, I missed the event. Congrats belatedly :)
13:36 szabgab so more people know about it
13:36 moritz_ szbalint: thank you
13:36 takadonet flussence: do a pull on the master branch and it should compile and run the test under the newest rakudo verison
13:36 takadonet please note some will still fail
13:36 szabgab 11-14 May
13:36 szabgab moritz_: http://www.linuxtag.org/2011/
13:37 moritz_ szbalint: I'm confused. There's linuxtag in Berlin, and Linux-Tage in Chemnitz
13:37 moritz_ sorry, meant szabgab
13:37 moritz_ the Berlin one is in May
13:37 szabgab and linux tages all over Austria :)
13:37 szabgab or sg similar
13:37 szabgab linux wochen
13:38 szabgab close :)
13:38 moritz_ well, just a factor of 7 :-)
13:38 MayDaniel left #perl6
13:38 masak szabgab: I'll get back to you on availability, but it sounds like a definite possibility.
13:38 szabgab the talk dead-line is in a few days
13:39 szabgab I forgotten to announce it in time
13:39 bluescreen joined #perl6
13:40 szabgab masak: moritz_ dead-line is 8 Feb
13:40 szabgab http://wiki.linuxtag.org/w/vp:Main_Page
13:40 masak ok, I'll check availability now.
13:41 bluescreen left #perl6
13:42 bluescreen joined #perl6
13:47 bluescreen left #perl6
13:48 bluescreen joined #perl6
13:48 stifynsemons left #perl6
13:50 bluescreen left #perl6
13:50 bluescreen joined #perl6
13:50 shortcircuit joined #perl6
13:52 [Coke] rant: google should not be hitting the "today" link when going through the irc logs.
13:52 flussence why not?
13:52 [Coke] could we add that to the robots.txt ? (force it to index content based on a url with the date in it?)
13:52 flussence oh
13:52 [Coke] flussence: because tomorrow, the data it's searched is wrong.
13:53 moritz_ [Coke]: I'd hate to forbid indexing /today because that's an often used link
13:53 flussence I guess you could have it set an Expires header for midnight...
13:53 cognominal joined #perl6
13:53 moritz_ [Coke]: maybe have 'today' doing a (temporary) redirect to today's date?
13:53 [Coke] moritz_: often used, but should it be indexed??
13:54 moritz_ [Coke]: there's no reason to not index it, just not under that URL
13:54 [Coke] <shrug> as long as I don't have to manually fixup google's search, IDC.
13:54 fhelmberger joined #perl6
13:54 [Coke] moritz_: that is what I'm saying. don't index THAT URL.
13:54 fhelmberger left #perl6
13:54 [Coke] I obviously still want to find that page worth of data, but only if it's using a unique url.
13:54 fhelmberger joined #perl6
13:55 moritz_ actually I have no idea which URL then indexes, the redirected to, or the original one
13:55 moritz_ I know it's the target for permanent redirects, but I can't use a permanent one here
13:55 [Coke] which is why I sugested an easy solution. :)
13:55 tzhs joined #perl6
13:55 moritz_ ... which I don't like at all
13:56 [Coke] it'll still find the unique URL by date, (or we can update the nagivation to make it so.)
13:56 [Coke] moritz_: why don't you like it?
13:56 [Coke] aloha, aloha?
13:57 [Coke] phenny, aloha?
13:57 [Coke] ETOOMANYBOTS.
13:57 [Coke] is there an infobot in here?
13:57 masak szabgab: I'll get back to you later today. I had a slight feeling there was a Russian conf in May, but unable to drag up any dates for it.
13:57 moritz_ [Coke]: because forbidding the URL that is most often used as a link target goes against all SEO principles
13:57 drbean left #perl6
13:58 [Coke] Who is most often linking to today?
13:58 [Coke] google? because that's the WRONG LINK. ;)
13:58 moritz_ no, other websites
13:58 [Coke] I know if I'm sending someone to the archives, it's because I want them to find something specific.
13:58 moritz_ like perl6.org/community/
13:58 moritz_ and if you want to link to the logs in general, the "today" page is usually the best
13:59 [Coke] Ok.
14:00 flussence if it's only google you're worried about, putting a <link rel=canonical> in there should be enough.
14:01 moritz_ flussence: that sounds like a great idea
14:01 * moritz_ didn't know about that one
14:01 szbalint moritz_: how about canonical naming today to the $current_date?
14:01 pmurias joined #perl6
14:01 flussence it's relatively new, they made it up for this exact reason :)
14:01 moritz_ szbalint: how?
14:02 szbalint doh. slow wifi.
14:02 moritz_ ah
14:02 szabgab masak: https://www.socialtext.net/perl5/index.cgi?events
14:03 szabgab for all the event I know about :)
14:03 szbalint I was first! :D
14:05 szabgab masak: so YAPC::Russia overlaps with LinuxTag in Berlin :(
14:05 szbalint anyway moritz_: <link rel="canonical" href="http://irclog.perlgeek.de/perl6/2011-02-04" />
14:06 szbalint easy pease
14:06 szbalint *y
14:06 moritz_ this is one of those changes where the commit message is about 4x longer than the actual patch :-)
14:07 moritz_ https://github.com/moritz/ilbot/commit/4​0e78d08e1085f5a1b15aa316566b2f9f414a068
14:08 moritz_ [Coke]++ flussence++ szbalint++
14:11 abraxxa left #perl6
14:15 Trashlord joined #perl6
14:22 shortcircuit moritz_: You might have the Today link HTTP 301 to the current index-date link. Any indexer should update its internal representation appropriately.
14:22 moritz_ shortcircuit: 301 is "permanent", and the link for "today" changes every 24h - not very permanent
14:23 moritz_ anyway, looking at the referrers I don't get any search engine traffic besides google
14:24 Eevee hey, cool, didn't know about rel="canonical"
14:24 Juerd That's only for ubuntu links :)
14:25 moritz_ Eevee: neither did I. #perl6 is a constant source of new knowledge and quotes :-)
14:25 wamba joined #perl6
14:25 Juerd Perl domains are slow at getting ipv6 :(
14:25 Juerd http://ip6.nl/tester.plp
14:26 moritz_ Juerd++
14:27 moritz_ my site works, but the NS doen't have v6 addresses
14:27 szbalint I added ipv6 to my personal domain this week.
14:27 szbalint bytemark++
14:29 Juerd szbalint: What domain?
14:29 Juerd moritz_: Same question :)
14:29 moritz_ Juerd: perlgeek.de
14:29 Juerd Nice name :)
14:30 szbalint x0r.be
14:31 moritz_ well, I don't have any control of the perl6.org domain
14:31 moritz_ so not much I can do on that front
14:32 Juerd Who does?
14:32 Juerd 'cause feather2 is 2a02:2308:10::f:2
14:32 flussence takadonet: pushed fixes for those broken tests. If I get time later today I might look into making them use Test.pm
14:33 moritz_ Juerd: Daniel Wright
14:33 takadonet flussence: I could do that as well . depend on time at work
14:33 moritz_ Juerd: but if we'd start with IPv6, we should have a v6 address per subdomain
14:33 Juerd Why?
14:34 Juerd There's really no reason for that, except https.
14:34 moritz_ name based virtual hosts suck for secu... exactly
14:34 Juerd And if anyone wants to host ssl sites on feather, that's great.
14:34 tadzik https://github.com/tadzik/neutro/issues#issue/3 -- hrm. Isn't that a Parrot issue?
14:35 Juerd Find someone to pay for the certificate and ask me for extra IP addresses, 4 and 6
14:35 flussence huh, doesn't SSLv3 allow for name-based hosts?
14:35 flussence I thought they fixed that.
14:35 szbalint yeah, well I wouldn't mind pushing for an effort where http means https is also available when using IPv6
14:36 szbalint with self-signed certs
14:36 Juerd szbalint: Sounds insane. Why?
14:37 szbalint Just because it's annoying me that major websites are lacking https and I have to tunnel everything through ssh to get security when using a public wifi for example.
14:37 stifynsemons joined #perl6
14:37 Juerd You'd still have that with the self signed certs.
14:37 hirschnase left #perl6
14:37 szbalint https is underutilized :S
14:37 Juerd No protection against MITM unless you verify the fingerprints.
14:38 szbalint Juerd: not really. If it's a site that I visited before
14:38 cjk101010 left #perl6
14:38 moritz_ Juerd: yes, but protection against ordinary evesdropping
14:38 Juerd I have a better idea. Make https the default when http:// is left out.
14:38 moritz_ and little protection > no protection
14:38 Juerd Unless it's not available, then fall back to http
14:38 Juerd Even better: add TLS negotiation to HTTP itself, on port 80
14:39 szbalint that's more aggressive than what I had in mind, I just want more sites available through https
14:39 szbalint but I could live with it :)
14:40 felliott joined #perl6
14:40 xinming_ joined #perl6
14:41 * moritz_ has some trouble with TLS
14:41 moritz_ one of my mail provides overs IMAP over TLS
14:41 moritz_ and some stupid network providers don't let me use it, because they think it's insecure... they just block the port
14:42 moritz_ no wait, smtp over tls, not imap
14:42 Juerd You can do STARTTLS negotiation over the normal ports
14:42 stifynsemons left #perl6
14:42 moritz_ unless the stupid network provider blocks the port.
14:43 szbalint they're not going to block port 80.
14:43 Juerd That's why we have 587
14:43 xinming left #perl6
14:43 Juerd And it's not TLS's or SSL's fault, or even SMTP's fault, that your ISP sucks and blocked the port... :)
14:43 moritz_ Juerd: I know
14:44 Juerd szbalint: That's be even more annoying than being on an ipv6-only link...
14:44 * Juerd created an ipv6-only server for the ipv6-only DNS test in http://ip6.nl/tester.plp
14:45 Juerd Trying to browse web pages on that thing is very frustrating. No google, no facebook
14:45 Juerd Amazon.com resolves but they don't have an ipv6 webserver, etc.
14:45 moritz_ Juerd: could you please check if embedded images work on sudokugarden.de?
14:46 Juerd What's an "embedded" image?
14:46 moritz_ Juerd: last time I tried it via IPv6 the images didn't show up, but I couldn't find a reason for that
14:46 moritz_ Juerd: those via <img> tags
14:46 Juerd http://juerd.nl/i/c166c67f4​8d507fd260563d42dcdeff2.jpg
14:46 moritz_ Juerd: thanks, looks fine
14:46 moritz_ must have been a client side fuckup
14:47 Juerd But the site won't work in pure ipv6 world :)
14:47 Juerd Your nameserver still needs ipv4 connectivity in order to even get the IPv6 address for the site.
14:47 moritz_ I know... same DNS as perlgeek.de
14:47 Juerd This is not a problem, for at least another decade, I guess
14:48 moritz_ but the one who hosts the DNS is also a geek. He'll want to know :-)
14:48 szbalint yeah, everyone's dual stacking, except the next gen mobile guys
14:48 Juerd Send 'em the link to http://ip6.nl/tester.plp and complain that you want green instead of red, for your domains.
14:49 moritz_ szbalint: well, I guess the mobile ISPs will do the recursive DNS lookups for the mobile devices
14:49 szbalint and then they're running a dual-stacked dns resolver
14:49 Juerd Say something about that it makes you feel inadequately geeky to see those red boxes :P
14:50 Juerd They'll understand and add ipv6 support within a few hours!
14:50 moritz_ or I'll promise him a nice, self-made lasagne :-)
14:51 Juerd Do both1
14:51 Juerd s/1/!/
14:51 moritz_ (which I'd do anyway sooner or later)
14:51 Juerd Pointing a gun would probably work too
14:51 Juerd But don't  do that
14:52 * moritz_ wouldn't do that to his best man :-)
14:53 dual joined #perl6
14:53 szbalint I'm pointing the gun: "Verizon guys are saying: 'We'll have a bunch of mobile devices on IPv6 only from 2011, do you want to add the AAAA records or should we do it for you?'"
14:54 szbalint (paraphrased a bit)
14:54 kaydsoft left #perl6
14:56 moritz_ how would verizone add AAAA records to .de domains?
14:57 szbalint they control the resolving dns server
14:57 szbalint for their mobile users.
14:57 moritz_ then I don't have a problem with that, if they use v4 to query "my" DNS server for an AAAA record
15:00 kaare_ left #perl6
15:00 szbalint v4 content gets the proxy treatment
15:04 pmurias tell sorear does niecza support lexical classes? why do they appear in the stash?
15:06 moritz_ pmurias: talk to phenny :-)
15:06 bluescreen left #perl6
15:10 cafesofie joined #perl6
15:10 colomon left #perl6
15:22 kaydsoft joined #perl6
15:22 bluescreen joined #perl6
15:23 cafesofie left #perl6
15:24 pmurias phenny: tell sorear does niecza support lexical classes? if so why do they appear in the stash?
15:24 phenny pmurias: I'll pass that on when sorear is around.
15:24 masak (rel="canonical")++
15:24 pmurias ?
15:25 * pmurias googled it
15:25 moritz_ pmurias: see backlog... we hope it fixes an indexing problem with the IRC logs
15:28 am0c joined #perl6
15:30 sorear good * #perl6
15:30 phenny sorear: 07:41Z <TimToady> tell sorear a couple days ago I noticed a !%foo{$x}:exists or some such, which is a precedence thinko
15:30 phenny sorear: 15:24Z <pmurias> tell sorear does niecza support lexical classes? if so why do they appear in the stash?
15:30 c1sung joined #perl6
15:30 sorear pmurias: yes; simplicity
15:35 benabik_sleep is now known as benabik
15:37 wtw left #perl6
15:38 fhelmberger left #perl6
15:39 kaare_ joined #perl6
15:41 masak o/, sorear
15:43 sorear Juerd: you think you have it bad?  my ISP won't route outgoing IPv6 packets
15:43 Juerd My ISP doesn't do IPv6 at all
15:43 Juerd But I'm using a tunnel (sixxs)
15:52 pmurias sorear: simplicity?
15:53 szbalint my isp is doing a trial IPv6 run atm
15:53 szbalint I wish they'd deploy fully.
15:53 colomon joined #perl6
15:53 gfldex they will
15:55 szbalint eventually.
15:55 pmurias sorear: it's in a package with a generate name right?
15:57 pmurias sorear: how am i supposed to distinguished what is a global and what was just put there for simplicity of implementation?
15:58 colomon left #perl6
15:58 wamba left #perl6
15:58 pmurias sorear: did the debugging name put into nam actually help with debugging?
15:59 pmurias * names
15:59 allbery_b left #perl6
16:01 colomon joined #perl6
16:01 colomon stupid library basement internet.
16:07 colomon left #perl6
16:09 kaydsoft left #perl6
16:09 colomon joined #perl6
16:10 plobsing joined #perl6
16:13 * colomon is having a crisis of confidence about the denominators of Rats in p6.
16:13 kaydsoft joined #perl6
16:14 masak confidence? denominators?
16:14 allbery_b joined #perl6
16:14 Patterner left #perl6
16:16 Psyche^ joined #perl6
16:16 Psyche^ is now known as Patterner
16:17 colomon the standard has language about preserving the denominator in cases where it could be simplified.
16:17 colomon it's not at all implemented in Rakudo, which always simplifies if it can.
16:18 colomon rakudo: say (1/100 + 9/100).perl
16:18 p6eval rakudo 2666b6: OUTPUT«1/10␤»
16:19 colomon the spec sort of implies that should be 10/100
16:19 colomon rakudo: say (1/3 + 1/6).perl
16:19 p6eval rakudo 2666b6: OUTPUT«1/2␤»
16:19 colomon and it's very explicit that that should be 3/6
16:20 colomon but what about
16:20 colomon rakudo: say (3/6).perl
16:20 p6eval rakudo 2666b6: OUTPUT«1/2␤»
16:20 colomon should that be 1/2 or 3/6?
16:20 Mowah left #perl6
16:21 [Coke] I would imagine that if 1/3+1/6 = 3/6, then 3/6.perl == 3/6
16:21 colomon not simplifying feels very wrong to me.
16:21 [Coke] perhaps add an explicit .simplify() for rats.
16:21 Kovensky left #perl6
16:21 [Coke] or, change the spec to always simplify, sure. ;)
16:22 colomon and the spec does imply that (3 * 1/6) should be 1/2; the denominator is only preserved for addition and subtraction.
16:22 colomon it feels to me like the spec is trying to solve a problem that I don't see at all.
16:22 pmurias sorear: i could seperate anonymous entries with a regex but that's not very elegant
16:23 benabik colomon: Trying to keep it from simplifying repeatedly on [+] @list-of-rats ?
16:23 justatheory joined #perl6
16:25 [Coke] colomon: I'd find out if there was a rational for that -perhaps to avoid unnecessary computation (but you have to do computation to figure out what the GCD is...)
16:25 colomon benabik: it only prevents it in certain cases.
16:25 colomon *rationale, I hope.  ;)
16:26 [Coke] FWIW, I wouldn't expect perl to keep track of the GCD on that for me
16:26 colomon I should add, it does simplify in many cases.  It only doesn't simplify (in addition) if one denominator is divisible by the other.
16:26 [Coke] (I'd not care if it did; I'd leave it up to the implementations)
16:26 moritz_ colomon: where does the spec says it needs to preserve the denominator?
16:27 colomon S02.
16:27 colomon I can't be more specific, my internet is pretty hosed here.
16:27 colomon so for instance, if you add 1/15 + 1/20, it will simplify as much as it can.
16:28 colomon rakudo: say (1/15 + 1/20).perl
16:28 p6eval rakudo 2666b6: OUTPUT«7/60␤»
16:28 colomon not a great example there.  :)
16:28 slavik1 rakudo: say 2**64
16:28 p6eval rakudo 2666b6: OUTPUT«1.84467440737096e+19␤»
16:28 slavik1 D:
16:28 slavik1 no bignum?
16:28 colomon rakudo: say (1/15 + 3/20).perl
16:28 p6eval rakudo 2666b6: OUTPUT«13/60␤»
16:28 masak slavik1: no, not yet.
16:29 slavik1 rakudo: say (2**64).WHAT
16:29 p6eval rakudo 2666b6: OUTPUT«Num()␤»
16:29 slavik1 rakudo: say (2**64).perl
16:29 p6eval rakudo 2666b6: OUTPUT«1.84467440737096e+19␤»
16:29 slavik1 would Num() itself be bignum or would there be a BigNum() ?
16:29 tzhs left #perl6
16:30 Kovensky joined #perl6
16:31 felliott left #perl6
16:32 colomon left #perl6
16:33 moritz_ slavik1: do you need more than 1e308?
16:35 colomon joined #perl6
16:35 colomon how much of what I last said got lost there?
16:37 risou joined #perl6
16:37 benabik colomon: Last thing I see from you is "rakudo: say (1/15 + 3/20).perl"  I don't know how much I didn't see.
16:37 colomon benabik++
16:37 colomon colomon: slavik1: nope.  but I've created Math::BigInt for the time being
16:37 colomon [11:29am] colomon: slavik1: it's a bit of a pain to install, alas.
16:37 colomon [11:29am] colomon: slavik1: and I don't know if it works on Windows at all.
16:37 colomon [11:30am] colomon: rakudo: say (3/15 + 3/20).perl
16:38 colomon rakudo: say (3/15 + 3/20).perl
16:38 p6eval rakudo 2666b6: OUTPUT«7/20␤»
16:39 colomon rakudo: say (3/15 + 4/20).perl
16:39 p6eval rakudo 2666b6: OUTPUT«2/5␤»
16:39 felliott joined #perl6
16:40 colomon okay, I think here's where it gets weird:
16:40 colomon rakudo: say (3/15 + 1/20 + 3/20).perl
16:40 p6eval rakudo 2666b6: OUTPUT«2/5␤»
16:41 colomon by the spec, I think the denominator there depends on the order of the additions.
16:44 felliott left #perl6
16:44 risou_ joined #perl6
16:45 colomon here we go, an even better example
16:45 colomon rakudo: say (1/15 + 2/15 + 1/20 + 3/20).perl
16:45 p6eval rakudo 2666b6: OUTPUT«2/5␤»
16:45 risou left #perl6
16:46 colomon if you add 1/15 + 1/20 before adding the others, the answer should be 24/60
16:46 benabik colomon:
16:46 colomon if you add 1/15 + 2/15 and 1/20 + 3/20 first, the answer can be 2/5
16:46 * benabik is still not used to the IRC client.
16:47 benabik colomon: It seems like simplifying sometimes is far stranger than the options of never and always.
16:47 colomon yes
16:47 colomon I think I need to do a blog post on this.  :)
16:48 colomon (And I'm not going to try that until I'm on a stable Internet connection.)
16:48 benabik Titled "Why do we do this, it's too crazy"?
16:48 * moritz_ now reads S02 to verify or falsify colomon's claim
16:48 colomon moritz_: I'd love to hear I'm wrong about this.  :)
16:48 pmurias left #perl6
16:49 kensanata left #perl6
16:50 moritz_ C<Rat> addition and subtraction should attempt to preserve the
16:50 moritz_ denominator of the more precise argument if that denominator is
16:50 moritz_ an integral multiple of the less precise denominator.
16:51 pecastro joined #perl6
16:52 moritz_ Hence, if you are adding a bunch of C<Rat>s that
16:52 moritz_ represent, say, dollars and cents, the denominator may stay 100 the
16:52 moritz_ entire way through.
16:52 IllvilJa left #perl6
16:52 moritz_ "may" vs. "should"
16:53 envi left #perl6
16:54 moritz_ I think this is insane, because the example of dollars and cents are already covered by stringification rules of Rats
16:54 masak how so?
16:55 colomon left #perl6
16:58 colomon joined #perl6
16:59 moritz_ if the denominator contains only powers of 2 and 5, it's guarantueed to return an exact string
16:59 moritz_ ie 1/5 stringifies to 0.2 without going through Num
16:59 colomon sorry, moritz_ I lost the lead up to that?
17:00 colomon 2, 5, exact string, yes.
17:00 * colomon will hopefully be able to go home in a few minutes, to a blessedly stable internet connection.
17:00 moritz_ so I argue that there's no need to preserve the denominator
17:00 colomon ah!
17:00 colomon simplify!  ;)
17:01 moritz_ because what TimToady++ cares about is that if you add exact decimals, the result looks similar
17:01 moritz_ so 20.2 + 50.1  =>  70.3 (with that stringification)
17:02 pecastro left #perl6
17:02 moritz_ the question is whether 1.07 + 2.03 stringifies to 3.1 or 3.10
17:02 colomon yes
17:02 masak nod
17:02 colomon but as far as I know, it's 3.1 by spec
17:03 colomon even though it's 310 / 100 by spec
17:03 moritz_ I thought it's 3.10, becaue the denom is 100?
17:03 masak if I cared about the stringification, I'd use a formatting routine anyway.
17:03 colomon masak: +1
17:03 masak but I guess that's not very relevant to this discussion... :P
17:03 colomon moritz_: can you find language to that effect?  I've never looked for it, I admit.
17:04 moritz_ colomon: I quoted two parts of the spec in the backlog
17:04 colomon moritz_: sorry, that must have been a bit I missed.  and I think going for the log will kill my internet connection.
17:05 colomon I'll take your word for it.
17:05 masak colomon: I don't think we're in a rush; we can wait until you get home.
17:06 moritz_ aye
17:13 colomon It's always good to have your arguments in order before TimToady shows up.  :)
17:14 colomon anyway, we're packing up here
17:14 * masak .oO( ...because TimToady plays bowling with one's arguments? ) :P
17:16 colomon "smashing" is the metaphor I would use.  :p
17:16 masak "strike!"
17:18 [Coke] (*#&@$ turkey.
17:20 colomon left #perl6
17:22 colomon joined #perl6
17:27 dukeleto left #perl6
17:27 colomon left #perl6
17:27 dukeleto joined #perl6
17:27 MayDaniel joined #perl6
17:33 daxim left #perl6
17:34 takadonet flussence: ping
17:34 flussence pong!
17:35 alester joined #perl6
17:35 cdarroch joined #perl6
17:35 cdarroch left #perl6
17:35 cdarroch joined #perl6
17:36 takadonet flussence:
17:36 takadonet flussence: almost done converting all tests to use Test.pm
17:36 flussence ah, ok :)
17:36 guidj0s joined #perl6
17:37 V15170R joined #perl6
17:38 takadonet flussence: changes pushed
17:40 colomon joined #perl6
17:41 flussence ok, now to see what can be done about those 4 failures :)
17:44 takadonet I thought that project was dead so thanks for showing interest in finishing it
17:45 flussence no prob, it'll keep me busy by the looks of things
17:46 takadonet I lost interest since well... I don't really care about tabs and wraps of text
17:46 takadonet I started it b/c it's one of the most used cpan modules
17:46 risou_ left #perl6
17:46 MayDaniel left #perl6
17:46 takadonet http://ali.as/top100/
17:47 takadonet under Volatile 100
17:47 flussence wow, that's a lot
17:48 risou joined #perl6
17:48 takadonet surprisingly  we have a huge chuck of those modules builtin perl6 already
17:48 sftp left #perl6
17:48 dakkar left #perl6
17:48 risou left #perl6
17:51 sftp joined #perl6
17:51 Guest84197 left #perl6
17:52 Util To bind $x and $y to the first and second elements of each inner array (like in S06), this works for me:
17:52 Util rakudo: my @AoA = [3,5], [7,9]; for @AoA -> [ $x, $y ] { say "$x/$y" }
17:52 p6eval rakudo 2666b6: OUTPUT«3/5␤7/9␤»
17:52 Util To do the same kind of binding to particular keys of inner hashes, this works:
17:52 Util rakudo: my @AoH = { X => 3, Y => 5 }, { X => 7, Y => 9 }; for @AoH -> ( :X($x), :Y($y) ) { say "$x/$y" }
17:52 p6eval rakudo 2666b6: OUTPUT«3/5␤7/9␤»
17:52 Util To do the same kind of binding to the key and value of inner Pairs, none of this works:
17:52 Util rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP ->  ( :key($k), :value($v) ) { say "$k/$v" }
17:52 p6eval rakudo 2666b6: OUTPUT«Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤»
17:52 Util rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP ->  ( $key, $value ) { say "$key/$value" }
17:52 p6eval rakudo 2666b6: OUTPUT«Not enough positional parameters passed; got 0 but expected 2 in sub-signature␤  in <anon> at line 2:/tmp/pKAZLJnsz2␤  in main program body at line 1␤»
17:52 Util rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP -> :( $key, $value ) { say "$key/$value" }
17:52 p6eval rakudo 2666b6: OUTPUT«Not enough positional parameters passed; got 0 but expected 2 in sub-signature␤  in <anon> at line 2:/tmp/hjmVnhGQx6␤  in main program body at line 1␤»
17:52 Util rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP ->  [ $key, $value ] { say "$key/$value" }
17:52 p6eval rakudo 2666b6: OUTPUT«Nominal type check failed for parameter ''; expected Positional but got Pair instead␤  in <anon> at line 22:/tmp/6mnystwRWq␤  in main program body at line 1␤»
17:52 Util Is there a syntax I am missing, or is binding-to-Pair just NotYetImplimented in Rakudo?
17:53 * takadonet looks at masak
17:57 Util The relevant part of S06 is "Unpacking tree node parameters", where this kind of binding is used on sub params, but `for` uses arrow-subs, so the bind syntax should be the same for this use-case.
18:02 moritz_ Util: [ ] unpacking only works for arrays, iirc
18:02 moritz_ Util: it's () for objects in general
18:04 rgrau joined #perl6
18:06 _jaldhar left #perl6
18:06 Util I tried it because I had a vague memory that a Pair could also be dereferenced like a two-element array. Looks like I mis-remembered.
18:07 Util Since a Pair is an object, ($key,$value) should call the .key and .value methods on the Pair.
18:12 benabik Util: Shouldn't ($:key, $:value) work?
18:13 Util benabik: did you mean (:$key, :$value) ?
18:13 sorear benabik: when you set the topic yesterday, the first three characters got garbled, just so you know.
18:13 benabik Util: Probably.
18:13 benabik sorear: Apologies.  They looked fine to me, but the encoding probably got changed somewhere.
18:14 Util rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP ->  ( :$key, :$value ) { say "$key/$value" }
18:14 p6eval rakudo 2666b6: OUTPUT«Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤»
18:15 jaldhar joined #perl6
18:15 Util benabik: yes, it should also work; S06 just gives the even shorter version in its binding examples.
18:16 sftp left #perl6
18:16 sftp joined #perl6
18:17 sorear jnthn: ping
18:17 benabik sorear: I hadn't meant to change it at all, but Conversation has this big button that sets the topic to your current input line... which was empty. :-P
18:18 sorear yeah. irssi has a similar flaw...
18:18 benabik Somewhere between copying from the online log and Conversation, it probably ended up being in some wrong encoding.
18:19 sorear actually...
18:19 sorear nobody has needed to change the topic for a while
18:19 kjeldahl joined #perl6
18:19 benabik I first removed that button and then switched clients entirely. :-D
18:20 benabik ChanServ didn't like that idea, apparently.
18:21 benabik sorear++ for protecting everyone from my tendency to press random buttons.  :-D
18:22 bpa joined #perl6
18:22 bluescreen left #perl6
18:22 vmspb joined #perl6
18:25 bluescreen joined #perl6
18:30 guidj0s left #perl6
18:41 moritz_ rakudo: my @AoP =  X => 3, Y => 5 , M => 7, N => 9; for @AoP -> (:$key, :$value) { say "$key/$value" }
18:41 p6eval rakudo 2666b6: OUTPUT«Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤Mu()/Mu()␤»
18:42 moritz_ Util: in principle it works, but not with Pair, which is set up from PIR code (and thus the introspection doesn't learn that .key and .value are accessors)
18:44 Util moritz_: So the syntax you just used will work correctly someday, after introspection learns about the accessors?
18:47 colomon moritz_: I don't see where the quotes you pulled from S02 say that 310/100 should stringify to 3.10.  Dunno if I missed a quote or not.
18:47 Util thanks, everyone!
18:47 markmont joined #perl6
18:48 colomon moritz_: but I did backlog, anyway.  :)
18:48 tadzik ~~
18:52 pmichaud good morning, everyone, from the great frozen home of Super Bowl XLV
18:52 pmichaud er, good afternoon, I guess
18:52 colomon \o
18:53 pmichaud We're now on snow day #4 for this week, with a fresh coating of snow :-)    https://picasaweb.google.co​m/patrick.michaud/20110204
18:54 colomon how many inches?
18:54 pmichaud 6 inches overnight.  we were forecast for 1-3 inches
18:54 pmichaud (and it's still snowing lightly here)
18:54 colomon nice
18:54 colomon we got 8 or 9 earlier this week.
18:54 pmichaud can't even see the steps from our front door down to the street
18:55 pmichaud like, it's one smooth surface down to the street -- no "bumps" where the edges of the steps would be
18:55 bluescreen left #perl6
18:56 snearch joined #perl6
18:58 moritz_ \o pmichaud
18:58 bluescreen joined #perl6
18:58 moritz_ colomon: you're right, it doesn't explicitly follow
18:58 vmspb left #perl6
18:59 moritz_ but if not, I see even less point in preserving the denominator
18:59 colomon moritz_: on the whole, it strikes me as a very wrong-headed attempt to make dollars and cents "easy".
18:59 pmichaud afk, lunch
19:12 dalek rakudo: 953b982 | felliott++ | src/ (3 files):
19:12 dalek rakudo: implement infix:<orelse> based off Kodi++'s xor work
19:12 dalek rakudo:
19:12 dalek rakudo: Signed-off-by: Moritz Lenz <moritz@faui2k3.org>
19:12 dalek rakudo: review: https://github.com/rakudo/rakudo/commit/953b982d7f
19:17 Tene pmichaud: I thought you were in Texas?
19:18 kaare_ left #perl6
19:18 pmichaud Tene: Yes, Texas.
19:18 Tene Huh.  I'm surprised that you get snow there.
19:18 pmichaud We get snow usually about once or twice a year.  But rarely do we get enough to close schools; and I don't know the last time we had four snow days in a row
19:18 pmichaud (if ever)
19:20 pmichaud http://maps.google.com/maps?q=33.087892,-9​6.761291&amp;ie=UTF8&amp;ll=33.100745,-96.​723633&amp;spn=22.372932,33.09082&amp;z=5  # my location
19:21 arnsholt Apparently the university in Austin is closed. Just because there's snow =)
19:22 jaldhar left #perl6
19:24 pmichaud well, keep in mind that the roads and cars (and drivers) in Texas aren't built for snow
19:24 pmichaud so even a light freeze makes things more than a little treacherous
19:31 bluescreen left #perl6
19:39 arnsholt That's a very good point. Still a bit weird for a Norwegian, TBH
19:52 mtk left #perl6
19:56 benabik masak: BTW, I blame you, Less Wrong and MoR for any mistakes I just made in my homework due to lack of sleep.
19:57 coldhead joined #perl6
19:58 mtk joined #perl6
19:59 moritz_ blaming is easy :-)
20:01 sbp I blame masak for being easily blameable
20:02 masak yeah, sorry about that.
20:02 bpa perl6: sub infix:<zero> ($a, $b) { return 0; } say(1 zero 3);
20:02 p6eval rakudo 2666b6: OUTPUT«===SORRY!===␤Confused at line 22, near "sub infix:"␤»
20:02 p6eval ..niecza v2-4-gf3cce73: OUTPUT«[31m===[0mSORRY![31m===[0m␤␤Strange text after block (missing comma, semicolon, comment marker?) at /tmp/ahdHS8WkLl line 1:␤------> [32msub infix:<zero> ($a, $b) { return 0; }[33m⏏[31m say(1 zero 3);[0m␤Other potential difficulties:␤  $b is declared but not
20:02 p6eval ..used at /tmp/ahd…
20:02 p6eval ..pugs: OUTPUT«0␤»
20:03 bpa perl6: sub infix:<zero> ($a, $b) { return 0; } say(1 Xzero 3);
20:03 p6eval niecza v2-4-gf3cce73: OUTPUT«[31m===[0mSORRY![31m===[0m␤␤Strange text after block (missing comma, semicolon, comment marker?) at /tmp/tEGYFdYqCm line 1:␤------> [32msub infix:<zero> ($a, $b) { return 0; }[33m⏏[31m say(1 Xzero 3);[0m␤Other potential difficulties:␤  $b is declared but not
20:03 p6eval ..used at /tmp/tE…
20:03 p6eval ..rakudo 2666b6: OUTPUT«===SORRY!===␤Confused at line 22, near "sub infix:"␤»
20:03 p6eval ..pugs: OUTPUT«*** ␤    Unexpected "Xzero"␤    expecting operator, ":" or ")"␤    at /tmp/c_YmP3CS3f line 1, column 47␤»
20:03 bpa Is this a scope issue? or I just misunderstanding the X operator?
20:04 moritz_ rakudo: class MyPair { has ($.key, $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> (:$key, :$value) { say "$key/$value" }
20:04 p6eval rakudo 2666b6: OUTPUT«===SORRY!===␤Unable to parse declarator, couldn't find final ')' at line 22␤»
20:04 moritz_ bpa: read the eorror mesasge
20:04 pmichaud bpa: need a semicolon after the closing brace
20:04 pmichaud closing brace ends a statement only if it's the last thing on the line
20:04 moritz_ std: class MyPair { has ($.key, $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> (:$key, :$value) { say "$key/$value" }
20:04 benabik masak: I think the piles of laughter my wife and I got are worth being a little tired.  :-D
20:04 p6eval std 625303c: OUTPUT«[31m===[0mSORRY![31m===[0m␤Unable to parse declarator at /tmp/Vsh16l4vIg line 1:␤------> [32mclass MyPair { has [33m⏏[31m($.key, $.value }; for MyPair.new(key =>[0m␤Couldn't find final ')'; gave up at /tmp/Vsh16l4vIg line 1:␤------> [32mclass MyPair { has ($.key,
20:04 p6eval ..$.value …
20:05 bpa perl6: sub infix:<zero> ($a, $b) { return 0; }; say(1 Xzero 3);
20:05 p6eval pugs: OUTPUT«*** ␤    Unexpected "Xzero"␤    expecting operator, ":" or ")"␤    at /tmp/0LiapCcPdo line 1, column 48␤»
20:05 p6eval ..niecza v2-4-gf3cce73: OUTPUT«Potential difficulties:␤  $b is declared but not used at /tmp/vP0P2eLAJr line 1:␤------> [32msub infix:<zero> ($a, [33m⏏[31m$b) { return 0; }; say(1 Xzero 3);[0m␤  $a is declared but not used at /tmp/vP0P2eLAJr line 1:␤------> [32msub infix:<zero> ([33m⏏[31m$a,
20:05 p6eval ..$b) { return …
20:05 p6eval ..rakudo 2666b6: OUTPUT«===SORRY!===␤Could not find sub &infix:<zero>␤»
20:05 bpa there, the rakudo error I was looking for... sub not found
20:05 moritz_ std: class MyPair { has $.key; has $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> (:$key, :$value) { say "$key/$value" }
20:05 p6eval std 625303c: OUTPUT«ok 00:01 125m␤»
20:06 moritz_ bpa: that's a problem with rakudo not doing lexical lookups in the X meta operator
20:06 moritz_ bpa: 'our sub infix:<zero>' would be a workaround
20:06 bpa so, known issue then
20:06 moritz_ rakudo: class MyPair { has $.key; has $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> (:$key, :$value) { say "$key/$value" }
20:06 p6eval rakudo 2666b6: OUTPUT«1/2␤1/10␤»
20:06 moritz_ yes
20:06 moritz_ Util: see above for a working example of unpacking in signature
20:08 masak benabik: #perl6: fun times for the whole family.
20:09 flussence hm, I'm looking at Text::Wrap and wondering if a straight port is really such a good idea. Behaviour controlled by global variables? blegh
20:10 bpa the our fixes that nicely, thank you for the tip
20:10 takadonet flussence: it's not a good idea but I just wanted to work first then improve it later
20:10 moritz_ flussence: if there are good defaults, just use (named) parameters with defaults
20:11 takadonet change anything that you see fit
20:12 flussence I'm still trying to figure out what most of these 1..3 char variables are for :)
20:13 flussence (first thing I'm going to do is translate them into english)
20:24 nadim_ left #perl6
20:25 masak benabik: anyway, I'm glad you seem to like MoR. yet another convert. ;)
20:26 benabik masak: I'm trying to spread it through my little corner of the country/'net. ;)
20:26 masak \o/
20:26 snearch left #perl6
20:27 masak I've probably told about 20 friends about it by now, with varying degrees of persuasion depending on the friendship.
20:27 moritz_ the better the friendship, the less persuasive? :-)
20:27 masak guess again... :P
20:27 moritz_ :-)
20:31 kaare_ joined #perl6
20:32 nadim_ joined #perl6
20:37 plainhao left #perl6
20:37 colomon moritz_: okay, this is weird.  I'm starting to think the spec might imply that (310/100).perl has to be 3.10, while I don't see anything about what (310/100).Str does.
20:38 colomon basically, the rules in the spec seem insane to me.
20:38 colomon or perhaps more nicely, a valiant attempt to imply fuzzy DWIM logic to things.
20:38 arnsholt Wouldn't a Rat simplify to 31/10?
20:39 colomon arnsholt: that's what we're looking at right now.
20:39 colomon under the current implementation, yes.
20:39 colomon (in Rakudo, I mean)
20:39 colomon but by spec, there are times when it is not supposed to simplify.
20:39 arnsholt If you don't always simplify, comparing Rats would get kinda complicated, at a guess
20:39 * arnsholt goes to read the spec
20:40 colomon s/imply/impart/ back a few lines.
20:40 colomon arnsholt: S02
20:40 colomon moritz_: I might be wrong about the .perl being 3.10 thing.
20:41 colomon because the .perl function is supposed to normalize the fraction unless it's exactly representable as a decimal number.
20:42 colomon which means if $a is a Rat, $a == $a.perl.eval, but $a.numerator does not have to equal $a.perl.eval.numerator.
20:43 masak that sounds, if not insane, then at least cruel and unusual :)
20:45 flussence I get a feeling I'm porting Perl 4 code to Perl 6...
20:45 colomon Here's the rationale, I think: "Although most rational implementations normalize or "reduce" fractions to their smallest representation immediately through a gcd algorithm, Perl allows a rational datatype to do so lazily at need, such as whenever the denominator would run out of precision, but avoid the overhead otherwise."
20:45 arnsholt Well, it says "allows a rational datatype to lazily [reduce] at need", which I guess means that $a.perl.eval.numerator may or may not be the same as $a.numerator
20:46 colomon arnsholt: right, that's what I said.
20:47 colomon but how weird is it that using .perl.eval doesn't produce the same Rat value, just a Rat with the equivalent numerical value?
20:47 molaf joined #perl6
20:48 arnsholt Yeah, that sounds like an FAQ item
20:48 colomon but then there's also "Rat addition and subtraction should attempt to preserve the denominator of the more precise argument if that denominator is an integral multiple of the less precise denominator."
20:48 shortcircuit left #perl6
20:48 moritz_ .perl ends the laziness, no?
20:48 colomon Which seems to imply there are cases where it is more likely (but still not necessary) that the fraction simplifies.
20:49 arnsholt Sounds like something that should either be implementation-dependent, or be concretised a bit
20:50 shortcircuit joined #perl6
20:53 colomon perhaps part of the source of my confusion is this: If the Rat automatically lazily simplifies, what is the point of the language about preserving the denominator from the second quote above?
20:55 colomon That is, is the Rat implementation allowed to be lazy for the purposes of efficiency, or is it required to be lazy in some cases?
20:55 colomon s/required to be lazy/required to "attempt" to be lazy/
21:01 flussence the way I read the spec is that it's not a requirement, just a warning to the user not to expect it to always be normalised
21:02 moritz_ we'll just leave it as-is in Rakudo until somebody submits a bugreport with a sensible interpretation of the spec :-)
21:02 tadzik /o\
21:02 * tadzik 's phone just took a bath in yoghurt
21:03 moritz_ remove the batterie, and wash it
21:03 tadzik It's sad how something so ridicolous can have such a sad effects
21:03 MayDaniel joined #perl6
21:03 tadzik moritz_: in water? I tried to remove the yoghurt from everywhere I reached
21:03 masak what kind of yoghurt was it?
21:03 tadzik uhm, strawberry. With these...
21:03 tadzik phenny: "nasiona"?
21:03 phenny tadzik: "seeds" (pl to en, translate.google.com)
21:04 flussence strawberry and telephone flavour, delicious.
21:04 tadzik yeah, that's it. Although I think they didn't get inside
21:04 moritz_ tadzik: yes. But only if you think that the water doesn't go in deeper than the jogurth
21:04 tadzik I wouldn't bet on that
21:04 moritz_ I've had success with a laptop keyboard + orange juice
21:04 tadzik it was working just a moment after I took it out of the pocket, then stopped
21:04 moritz_ removed battery, cleaned it with water, dried it
21:04 flussence depends how long it was in there. I'd imagine a phone has some moisture resistance for rain and stuff...
21:09 * masak finds himself writing A::B(...) instead of A::B.new(...) far too often
21:09 colomon masak: same here
21:10 colomon probably about every third or fourth time I try to call .new, I'd guess.
21:10 masak yeah, it happens often.
21:10 masak in one of my projects I defined postcircumfix:<( )> to delegate to .new
21:10 masak probably not a good habit, but it felt like it helped. :)
21:11 arnsholt Nice trick =)
21:13 Util tadzik: You know those little packets or cans of mosture-absorbants that are packed in pill bottles and shoeboxes?
21:13 Util Some company make envelopes completely lined with that stuff, to if you drown your watch or laptop, you can dry it in overnight instead of over-weeks.
21:13 Util moritz_: Thanks! I see that it also works without the colon (as a shortcut), and as :key($k), :value($v) to assign to vars with different names:
21:13 Util rakudo: class MyPair { has $.key; has $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> ($key, $value)         { say "$key/$value" }
21:13 p6eval rakudo 953b98: OUTPUT«1/2␤1/10␤»
21:13 Util rakudo: class MyPair { has $.key; has $.value }; for MyPair.new(key => 1, value => 2), MyPair.new(key => 1, value => 10) -> (:key($k), :value($v)) { say "$k/$v" }
21:13 p6eval rakudo 953b98: OUTPUT«1/2␤1/10␤»
21:13 tadzik Util: silica gel, yes
21:14 flussence rakudo: #= :(
21:14 p6eval rakudo 953b98: OUTPUT«===SORRY!===␤Whitespace character is not allowed as a delimiter at line 22, near " :("␤»
21:14 flussence known?
21:14 uvtc joined #perl6
21:14 tadzik I should have one in a camera bag
21:14 masak flussence: I think so, yes.
21:15 uvtc tadzik: Hi. Any tips on that segfault I'm seeing while installing neutro? I filed a report on github.
21:19 ashleydev left #perl6
21:20 ashleydev joined #perl6
21:21 tadzik uvtc: yeah, saw that. And I'm quite sure this is a Parrot issue. I assume that's reproducible?
21:22 TimToady colomon: I'm fine with any standard math function being in the user's namespace directly
21:22 kaydsoft left #perl6
21:23 kaydsoft joined #perl6
21:23 moritz_ \o/
21:23 colomon TimToady: so gcd is okay?  \o/
21:23 TimToady gcd is fine; we should merely try to avoid polluting the namespace with N slightly incompatible variants of every function like PHP does
21:23 uvtc tadzik: on my system, yes. If I run it again, I get
21:24 TimToady but the setting is an outer lexical scope so that it can be overridden
21:24 uvtc tadzik: 2 "fatal: ..." about mt and ft already existing,
21:24 TimToady so it doesn't matter so much if we prepopulate the namespace with useful stuff
21:24 uvtc tadzik: but then get the Segfault again.
21:24 TimToady esp if it can be loaded lazily
21:25 tadzik uvtc: huh, strange. Do you use some longer-running Perl 6 programs?
21:25 tadzik comparable to neutro
21:26 uvtc tadzik: no, no Perl 6 programs running at the moment.
21:26 tadzik the segfault is most definitely not my fault, still it's worth investigating, I've had segfaulting Perl 6 some time ago too
21:26 tadzik uvtc: what if you try to bootstrap neutro piece by piece, so:
21:26 tadzik PERL6LIB=mt/lib:ft/lib:jt/lib bin/neutro File::Tools
21:26 uvtc tadzik: could you please tell me how I'd go about manually installing perl6-File-Tools (the way...
21:27 moritz_ uvtc: please try to rm -rf ~/.perl6/lib
21:27 tadzik I mean, perl6-File-Tools, then perl6-Module-Tools, then neutro
21:27 tadzik maybe it'll run fine in smaller portions
21:27 TimToady colomon: I'm not sure it's worth doing all the min/max stuff in gcd, if the first % will automatically invert the pair as necessary
21:27 moritz_ having precompiled but outdated .pir files can lead to weird errors
21:27 uvtc tadzik: right. Could you please tell me how to do that?
21:28 uvtc moritz_: I've got no ~/.perl6 dir.
21:28 tadzik uvtc: sure thing. Look at the last line of bootstrap.sh script. It installs 'from the current directory', so a dot. Now instead of the dot, supply the module name, so perl6-File-Tools first
21:28 moritz_ uvtc: ok, one possible error source down
21:28 colomon TimToady: actually, we probably don't want to calculate the gcd in Perl 6.  Parrot has a gcd opcode, and the big digits library does as well.
21:28 uvtc moritz_: Oh, I guess I'd assumed that neutro would create it if necessary...
21:28 TimToady rakudo: say (12, 15, *+* ... 0).Str
21:29 uvtc moritz_: will create and try again...
21:29 p6eval rakudo 953b98: OUTPUT«(timeout)»
21:29 TimToady whoops
21:29 colomon That's part of the reason I wanted a gcd function available, so that the fast magic could happen in just one place.
21:29 tadzik moritz_: https://github.com/tadzik/neutro/issues#issue/3 -- it segfaults after some time
21:29 TimToady rakudo: say (12, 15, * % * ... 0).Str
21:29 p6eval rakudo 953b98: OUTPUT«12 15 12 3 0␤»
21:29 tadzik hmm, or maybe not
21:29 tadzik uvtc: let me know how is installing everything piece by piece going
21:30 uvtc tadzik: after manually creating my own ~/.perl6 dir, and then trying again, it seems to have worked.
21:31 TimToady colomon: nevermind, I see you figgered that out later
21:31 tadzik that's strange as hell
21:31 dalek rakudo: 9242428 | moritz++ | build/PARROT_REVISION:
21:31 dalek rakudo: bump PARROT_REVISION to get some testing on newer birds
21:31 dalek rakudo: review: https://github.com/rakudo/rakudo/commit/92424287bd
21:31 tadzik uvtc: could you try again and confirm that all the problem is caused by a lack of ~/.perl6 directory?
21:32 uvtc tadzik: sure, just a sec... (`rm -fr ~/.perl6` and trying again...)
21:33 uvtc tadzik: hm. This time there's no ~/.perl6/lib directory present after bootstrap.sh finishes running.
21:33 uvtc tadzik: will try again, this time starting with a fresh neutro...
21:34 tadzik it gets stranger every time :)
21:34 tadzik uvtc: could you add --v to neutro options in bootstrap.sh? It shouldn't affect anything, it'll just give us more info
21:35 uvtc tadzik: ran everything again from scratch. No ~/.perl6/lib dir created, so I don't know where it thinks it installed those prereqs.
21:35 uvtc tadzik: trying again with --v...
21:36 MayDaniel left #perl6
21:36 V15170R left #perl6
21:37 uvtc tadzik: no difference that I can see when running with --v.
21:37 tadzik huh
21:37 vmspb joined #perl6
21:37 tadzik uvtc: ooc, could you checkout the metainfo branch, and try on that version?
21:41 uvtc tadzik: just a sec. I added my ~/.perl6/bin to my PATH, and tried `neutro perl6-Acme-Meow` and it worked.
21:41 tadzik cool
21:41 tadzik could you try something with some dependencies, like Math-Model?
21:43 uvtc tadzik: where is it finding perl6-File-Tools and perl6-Module-Tools?
21:43 tadzik uvtc: is ~/.perl6/lib, it should
21:44 uvtc tadzik: no, the only thing in there is Acme/Meow.*
21:44 uvtc tadzik: (and JSON -- that worked too)
21:44 tadzik I wonder how did it work
21:45 tadzik what does echo $PERL6LIB give you?
21:45 uvtc tadzik: I tried renaming my ~/temp/tadzk-neutro-xyz dir (thinking that neutro was using the modules from there), but neutro still works.
21:45 uvtc tadzik: nothing. Not set.
21:46 tadzik magic
21:46 uvtc How can I ask perl6 what it's module search path is?
21:47 tadzik rakudo: say @*INC.perl
21:47 p6eval rakudo 953b98: OUTPUT«["lib", "/home/p6eval/.perl6/lib", "/home/p6eval//p1/lib/parrot/3.​0.0-devel/languages/perl6/lib", "."]␤»
21:48 uvtc Looks like R* comes with perl6-File-Tools and perl6-Module-Tools. :)
21:48 tadzik oh, that's *
21:49 uvtc tadzik: yes
21:49 tadzik yeah, that explains a lot
21:49 uvtc tadzik: Sorry, perhaps I should've explicitly mentioned it here. I did so in the bug report.
21:49 tadzik No, not your fault
21:50 uvtc tadzik: Perlhaps I should file a new issue, requesting that neutro check first if those two packages are already installed?
21:50 sorear good * #perl6
21:50 tadzik looks to me that I've never installed Star, so I have no idea how neutro works there
21:50 tadzik uvtc: it has no way to check for presence of modules it hasn't installed by itself
21:51 tadzik I think neutro was included in Star some time ago too
21:51 uvtc tadzik: I don't see it in my /usr/local/rakudo/bin dir.
21:52 tadzik that's correct, it Was included, not it's not
21:52 tadzik * now it's not
21:55 uvtc tadzik: I think the solution for now is: 1. have bootstrap check for the presence of ~/.perl6 (if it's not there, create it)
21:55 tadzik uvtc: I'm quite sure neutro creates .perl6 internally if it's not present, will look into this tomorrow
21:56 uvtc tadzik: thanks!
21:56 tadzik thank you!
21:56 uvtc tadzik: Sure, yw. :) Also, perhaps (for now) a note in the readme to just run "neutro ." to bootstrap if using R*.
21:57 tadzik uvtc: well volunteered :)
22:00 uvtc tadzik: Ok. Will do, soon (need to make some time to learn git/github first). I fork neutro and send you a pull-request, correct?
22:01 sorear moritz_: is it bad of me to think people shouldn't be using perl6: if they only care about rakudo: ?
22:01 tadzik uvtc: can be. Or just a patch, what's easier for you
22:01 sorear TimToady: What do you mean by the !%foo<bar>:exists thinko?
22:01 jnthn sorear: pong
22:01 TimToady it applies the adverb to the !, not the subscript
22:01 jnthn sorear: But just back from a week's teaching and tired. So ask easy questions. :P
22:02 TimToady adverbs are at assignment precedence, give or take
22:02 sorear TimToady: is this a problem with Perl?
22:02 TimToady you were wondering why it was producing a funny result, iirc
22:02 TimToady was several days ago
22:03 sorear ok.
22:03 TimToady but couldn't reply from behind my http proxy
22:03 uvtc tadzik: ok, will get back to you (here, on irc -- I don't see an email address for you anywhere).
22:04 TimToady though, come to think of it, we might be able to make 5foo<bar>:!exists work
22:04 sorear jnthn: I'd just like help understanding native types and stuff
22:04 TimToady s/5/%/
22:04 mtk left #perl6
22:04 tadzik uvtc: irc is fine too
22:04 sorear jnthn: in nqp-nom, is "foo" supposed to make a parrot;Str?
22:05 jnthn sorear: It does at the moment.
22:06 jnthn sorear: I suspect that the dotnet impl is a better example of how things should be. Sort of. But only sort of.
22:06 jnthn sorear: Nominally, "foo" makes a native string that gets boxed if the context needs it to be.
22:09 sorear native string = str, boxed string = Str?
22:10 molaf left #perl6
22:10 jnthn sorear: Yes
22:10 jnthn sorear: Note that the type object for str is an object
22:10 sorear what I'm most fuzzy on is the concept of inlinable representations
22:10 jnthn sorear: But we never end up with instances of it.
22:11 jnthn It's kinda a "placeholder"
22:11 jnthn Though that's a bad word I guess. But I don't have a better one to hand :)
22:11 uvtc left #perl6
22:11 sorear so, str !=== Str
22:11 sorear does str ~~ Str?
22:12 jnthn (str !=== Str) correct
22:12 jnthn str ~~ Str - not sure, off hand. Feasibly.
22:12 jnthn I'm quite sure that str ~~ Stringy
22:12 jnthn People tend to write Str in multiple dispatchy contexts.
22:13 jnthn I think we'll end up with str ~~ Str, int ~~ Int, num ~~ Num and so forth.
22:13 jnthn Unless TimToady++ feels otherwise. :)
22:13 jnthn But it's probably most natural that way.
22:13 masak +1
22:13 sorear I suppose str has to become Str when placed in a parcel.
22:13 sorear er
22:13 sorear capture
22:13 jnthn It'd be unfortunate if you boxed something - or more important it got boxed for you due to context - and then your multi candidates boxed differently. :)
22:14 jnthn sorear: Actually Parrot's calling captures are smart enough to do otherwise.
22:14 jnthn sorear: And I was expecting to make that the case in nqpclr too.
22:14 jnthn sorear: Otherwise you can't make a call without boxing, which would probably suck.
22:15 TimToady especially if you're calling a C function...
22:15 jnthn Of course, you could rely on aggressive inlining coming to the rescue (I mean inlining the optimization here, not the REPR inlining - which maybe I shoudl call something else...)
22:15 sorear What do you call the smallest runtime type which contains object and unboxed native types?
22:15 sorear If I have my Mu $x; is it possible for $x.WHAT === str?
22:16 jnthn I've been pondering that. Some of me wonders if Scalar is meant to end up as a parametric role, just like Array and Hash are kinda meant to be.
22:16 TimToady native types are really container types, so it can't also be Mu
22:16 jnthn Depends if that can be made efficient enough I guess.
22:17 jnthn TimToady: I could see $x.WHAT === str being true in some case though, given that .WHAT is a macro, not a method.
22:17 TimToady s/container types/container types known to the compiler so they don't have be known to the runtime/
22:17 TimToady jnthn: nod
22:18 jnthn TimToady: my Mu $x - I guess that would box on assignment because the container forces it to.
22:18 mkramer1 left #perl6
22:18 TimToady to me it becomes clearer with a type like int, which obviously has no internal typeness
22:18 jnthn *nod*
22:19 jnthn Yeah, strings are...kinda weirder in that sense. :)
22:19 sorear I think ints are weirder because Int and int have vastly different domains
22:19 jnthn Every backend will probably have some notion of string that's lighter than what Str entails though.
22:19 * TimToady is still not sure that str exists at the P6 level
22:20 TimToady sorear: in that sense, int is a subset type of Int
22:20 TimToady native storage implies extra arbitrary constraints on the type
22:21 pmurias joined #perl6
22:21 pmurias sorear: hi
22:22 pmurias jnthn: re lowlevel string, the question if the notion is shared across backends if not we might want to leave using backend specific lowlevel type to the optimizer
22:23 sorear pmurias: putting lexical stashes in the stash tree means that there is a single unified stash tree
22:23 TimToady the question I think is whether one might want to write generic code against some abstract 'str' type
22:24 felliott joined #perl6
22:24 TimToady one would have to see a good use case
22:24 TimToady we also start getting into notions of a Foo type that can be foo on some machines but has to be Foo on others
22:25 TimToady so maybe abstract types can be uppercase but optimizable to lowercase types in some cases
22:25 TimToady and maybe Str is good enough without str
22:25 jnthn TimToady: That may well be the case.
22:26 slavik1 TimToady: something similar to java's Integer and int but being able to drop Integer down to int?
22:26 TimToady as currently defined, for instance, Num can always optimize to num
22:26 TimToady I am not sufficiently familiar with java types to say
22:27 slavik1 TimToady: same here, but java has Integer as an object and int as a primitive type ...
22:27 pmurias sorear: what do we need a single unified stash tree for?
22:28 slavik1 http://mindprod.com/jgloss/intvsinteger.html
22:29 pmurias hmm, json doesn't support cycles
22:30 pmurias sorear: i'll implement more of the lisp backend and we will see how the design works out for a different target
22:30 sorear pmurias: I don't understand your issue with globalness
22:30 sorear pmurias: it makes stash merging a lot simpler
22:31 * TimToady has just realized that you could define fixed-point numbers with implied denominators with Rat[Int,100]
22:32 TimToady it's a very useful notion to have constants be degenerate subset types
22:32 pmurias sorear: by issue was how do we determin if it's a global stash entry named SAFE:7 or a lexical one
22:33 pmurias s/by/my
22:33 sorear global stash entries have names like GLOBAL::Foo
22:33 sorear if it doesn't start with GLOBAL, it's not global
22:33 pmurias so all of the stash entries are lexical
22:34 sorear the topmost stash contains the following children: GLOBAL, PROCESS, UNIT:NUMBER
22:34 pmurias it seems ok then
22:35 pmurias i didn't consider the fact that json has no cycles too
22:35 sorear is something making cycles?
22:37 pmurias no, just refering to things by names instead of just having reference to that seems strange
22:38 pmurias STD had a lot of bugs because it was using a strange refer to stuff by name scheme
22:41 sorear TimToady: What is the .WHAT.perl of 37/100?  Can it be assigned to a variable of type Rat[Int,Int64]?  Rat?  How about Rat[Int,Int]?  Rat[Int,100]?
22:41 stkowski joined #perl6
22:42 pmurias sorear: re debugging names which are part of an xref do they help you with anything?
22:45 sorear yes
22:45 colomon sorear: my interpretation of the spec is that 37/100 is a Rat.  (ie Rational[Int,Int64])  I think other Rational types have to be created explicitly with .new
22:48 jferrero left #perl6
22:52 jferrero joined #perl6
23:08 s1n left #perl6
23:08 s1n joined #perl6
23:14 alester left #perl6
23:17 flussence well, here's a start: https://github.com/flussence/Text-Tab​s-Wrap/blob/cleanup/lib/Text/Wrap.pm
23:20 pmurias sorear: how can i specify an empty setting?
23:23 masak rakudo: (say "OH HAI" if $_ > 4 for 1, 2, 3) or say "empty!"
23:23 p6eval rakudo 924242: OUTPUT«empty!␤»
23:24 masak rakudo: (for 1, 2, 3 { if $_ > 4 { say "OH HAI" } }) or say "empty!"
23:24 p6eval rakudo 924242:  ( no output )
23:24 * masak submits rakudobug
23:24 drbean joined #perl6
23:26 masak rakudo: say (for 1, 2, 3 { if $_ > 4 { say "OH HAI" } }).perl
23:26 p6eval rakudo 924242: OUTPUT«(Bool::False, Bool::False, Bool::False)␤»
23:27 masak rakudo: say (say "OH HAI" if $_ > 4 for 1, 2, 3).perl
23:27 p6eval rakudo 924242: OUTPUT«()␤»
23:34 pmurias left #perl6
23:35 sorear phenny: tell pmurias -L NULL
23:35 phenny sorear: I'll pass that on when pmurias is around.
23:36 bpa left #perl6
23:39 pecastro joined #perl6
23:44 vmspb left #perl6
23:46 masak all Yapsi tests now pass again locally.
23:47 masak I'll do some cleanup tomorrow morning, and then a release.
23:47 jnthn masak++
23:47 masak Yapsi is now brimming with extensibility :)
23:47 jnthn .oO( Official Perl 6 compiler release officially delayed to ensure it's continuing completeness )
23:47 jnthn *its
23:48 lopaway is now known as lopnor
23:49 masak I'm going to brag about FUTURE having being more streamlined by having one fewer node type than PAST, and much more informative by having ten or so more nodetypes. :P
23:49 wooden left #perl6
23:50 whiteknight joined #perl6
23:52 sorear jnthn: is my Mu $x = int; legal?  What methods does $x respond to then?
23:52 sjohnson anyone here a GPL expert?
23:53 jnthn sorear: It'd compile and assign. I guess the method call on it should make it box to Int before the dispatch though. It's a kinda edge case. :/
23:53 jnthn Because the type object is the only place where that's really a possibility.
23:54 masak 'night, #perl6
23:54 masak left #perl6
23:57 cafesofie joined #perl6

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

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs