»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg camelia perl6: ... | irclog: irc.perl6.org | UTF-8 is our friend! Set by sorear on 25 June 2013. |
|||
00:02
kurahaupo left,
Guest33296 left
00:07
tmtwd joined
00:10
hoverboard left
|
|||
tmtwd | whoami | 00:16 | |
00:22
rurban joined
00:26
rurban left
00:31
takesako____ left
00:47
takesako____ joined
00:54
rurban joined,
rurban left
01:05
Su-Shee_ joined
01:09
Su-Shee left
01:14
berekuk left
01:17
Sqirrel left
01:18
FROGGS left
01:20
klapperl_ joined
01:23
klapperl left
01:30
FROGGS joined
01:34
Sqirrel joined
01:43
raiph joined
01:51
kurahaupo joined
|
|||
dalek | p: 5f942fc | (Andrew Egeler)++ | src/vm/parrot/6model/reprs/CStruct.c: Serialize CStruct on parrot |
01:56 | |
p: 948999a | (Andrew Egeler)++ | src/vm/parrot/6model/reprs/CArray.c: Fix memory corruption on CArray resize |
|||
01:57
dayangkun left
02:06
kurahaupo left
02:14
btyler joined
02:21
plobsing joined
02:34
berekuk joined
|
|||
retupmoca | r: say $_ for 1,2,3; say "{$_}" for 1,2,3 | 02:45 | |
camelia | rakudo-parrot 698d20: OUTPUT«123123» | ||
..rakudo-{jvm,moar} 698d20: OUTPUT«123» | |||
retupmoca | I think parrot is correct on that one | ||
p: say Date.new; say Date.new.succ; | 02:51 | ||
camelia | rakudo-parrot 698d20: OUTPUT«2014-12-244015-24006-23» | ||
retupmoca | m: say Date.new; say Date.new.succ; | ||
camelia | rakudo-moar 698d20: OUTPUT«2014-12-242014-12-25» | ||
retupmoca | o.O parrot obviously doesn't understand dates | 02:53 | |
03:07
takesako____ left
03:11
berekuk left
03:20
skids joined
03:23
takesako____ joined
03:24
rurban joined
03:25
Alula left
03:33
anaeem1_ joined,
btyler left
03:36
BenGoldberg left,
Alula joined
03:38
anaeem1_ left
03:54
rurban left
04:03
nick___ joined
04:08
btyler joined
04:13
nick___ left
04:16
btyler left
04:25
rurban joined
04:32
rurban left
04:51
raiph left
04:54
anaeem1 joined
04:58
anaeem1 left
05:00
stux left
05:01
bjz joined
05:04
stux joined
05:29
rurban joined
05:33
rurban left
05:54
anaeem1_ joined
06:03
tmtwd left
06:09
anaeem1_ left
06:18
telex left
06:20
telex joined
06:24
Sqirrel left,
Sqirrel joined
06:32
rurban joined
06:36
rurban left
06:44
Sqirrel left
|
|||
Woodi | good morning everyone :) | 06:44 | |
r: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a += %b; | |||
camelia | rakudo-moar 698d20: OUTPUT«Odd number of elements found where hash expected in method STORE at src/gen/m-CORE.setting:9340 in block at src/gen/m-CORE.setting:17119 in block at /tmp/tmpfile:1» | ||
..rakudo-parrot 698d20: OUTPUT«Odd number of elements found where hash expected in method STORE at gen/parrot/CORE.setting:9302 in block at gen/parrot/CORE.setting:17316 in block at /tmp/tmpfile:1» | |||
..rakudo-jvm 698d20: OUTPUT«Odd number of elements found where hash expected in method STORE at gen/jvm/CORE.setting:9281 in block at gen/jvm/CORE.setting:17059 in block at /tmp/tmpfile:1» | |||
06:44
Sqirrel joined
|
|||
Woodi | is maybe some shortcut to sum hashes ? | 06:45 | |
06:52
virtualsue left
06:53
virtualsue joined,
darutoko joined
|
|||
Timbus | m: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; say (%a (+) %b).hash | 06:56 | |
camelia | rakudo-moar 698d20: OUTPUT«("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
Woodi | \o/ thanx Timbus++ :) | 06:58 | |
m: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a = (%a (+) %b).hash; say %a | 07:01 | ||
camelia | rakudo-moar 698d20: OUTPUT«("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
Timbus | m: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; for %a.kv -> $k, $v is rw { $v += %b{$k}//0 }; say %a | 07:03 | |
camelia | rakudo-moar 698d20: OUTPUT«("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
Woodi | .kv is why I wanted "just" PerlScript :) but I needed to do such merge in loop and second loop looked ugly... | 07:06 | |
07:14
nnunley left
07:24
thou left
07:33
rurban joined
07:34
baest_ joined,
bjz_ joined,
takesako_____ joined
07:36
eternaleye_ joined
07:37
rurban left
07:41
takesako____ left,
baest left
07:45
eternaleye left,
eternaleye_ is now known as eternaleye
07:47
bjz left
|
|||
FROGGS | I dunno if + should ever do more that numeric addition.... if you make it sum hashes, than somebody also wants it to concat strings | 07:50 | |
07:50
berekuk joined
|
|||
FROGGS | so, hash + hash should only return the sum of the number of keys | 07:50 | |
Woodi | I didn't thinked about it :) but short syntax for merging/sum hashes would be convenient | 07:53 | |
FROGGS | m: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; say %(%a (+) %b) # that is short enough for me | 07:55 | |
camelia | rakudo-moar 698d20: OUTPUT«("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
FROGGS | std: my (%a, %b); %a (+=) %b # I wonder if this should be allowed... TimToady? | 07:57 | |
camelia | std ec3d853: OUTPUT«===SORRY!===Confused at /tmp/TXVgCyiubl line 1:------> my (%a, %b); %a ⏏(+=) %b # I wonder if this should be all expecting any of: feed_separator infix or meta-infix infixed function statement modifie…» | ||
Woodi | it's works for me. note: it's Bag and that new types are very new features | ||
btw PATRICIA trees are sometimes better then hashes, maybe we can have them too ? | 07:59 | ||
FROGGS | Woodi: that sounds like an awesome thing for modules.perl6.org :o) | 08:03 | |
even if that means that it will went into core, it is a good place to prototype it | 08:04 | ||
masak | good mornin', #perl6 | ||
lizmat | mood gornin', #perl6! | ||
FROGGS | o/ :o) | 08:05 | |
lizmat | FROGGS masak Woodi o/ | ||
Woodi: if you're using hashes like that, you probably should use Bag's :-) | |||
Bags have the added feature that you can haz objects as keys without them being stringified | 08:06 | ||
r: class A {}; (A.new => 1).Bag.say | 08:07 | ||
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«bag(A.new())» | ||
lizmat | r: class A {}; (A.new => 1).hash.say # alas, A.new is gone | ||
camelia | rakudo-parrot 698d20: OUTPUT«("A<7818003069261027125>" => 1).hash» | ||
..rakudo-jvm 698d20: OUTPUT«("A<496755591>" => 1).hash» | 08:08 | ||
..rakudo-moar 698d20: OUTPUT«("A<139845920269608>" => 1).hash» | |||
08:09
nnunley joined
|
|||
Woodi | lizmat: as I was trying to say: I have no idea what to expects from that new types :) except Sets of course :) but S32 already opened ! | 08:10 | |
I thinked hashes could have object as keys too... | |||
ah, but with ~... | |||
lizmat | only if you specify them like : my %h{Any} | ||
with .hash you only get stringified keys | 08:11 | ||
08:13
nnunley left
08:18
Su-Shee_ is now known as Su-Shee,
virtualsue left,
clkaoud left,
pnu left,
flussence left,
_sri left
|
|||
Woodi is still thinking %a +=h %b is common case... | 08:22 | ||
moritz | m: my %a = a => 1; my %b = b => 2; %a ,= %b; say %a.perl | 08:25 | |
camelia | rakudo-moar 698d20: OUTPUT«("a" => 1, "b" => 2).hash» | ||
FROGGS | ohh! | ||
moritz++ | |||
Woodi | r: my Sethash $a = <a 1 b 2 c 3 d 4>; my SetHash $b = <b 2 c 1>; $a += $b; | 08:26 | |
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«===SORRY!===Type 'Sethash' is not declared. Did you mean any of these? SetHash Stashat /tmp/tmpfile:1------> my Sethash⏏ $a = <a 1 b 2 c 3 d 4>; my SetHash $b =Malformed myat…» | ||
Woodi | r: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a ,= %b; | ||
camelia | ( no output ) | ||
Woodi | r: my %a= <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a ,= %b; say %a | ||
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«("a" => "1", "b" => "2", "c" => "1", "d" => "4").hash» | ||
FROGGS | m: my SetHash $a = <a 1 b 2 c 3 d 4>; my SetHash $b = <b 2 c 1>; $a += $b; | ||
camelia | rakudo-moar 698d20: OUTPUT«Type check failed in assignment to '$a'; expected 'SetHash' but got 'Parcel' in block at /tmp/I7KIPB8S8A:1» | ||
lizmat | FROGGS, Woodi : you probably want BagHash instead of SetHash | 08:27 | |
Woodi | a bit a mess we have with that types :) | 08:28 | |
lizmat | m: my $a = <a a b b c>.Bag; $a (+)= <b b c c>.Bag; say $a # would have expected this to work | ||
camelia | rakudo-moar 698d20: OUTPUT«===SORRY!=== Error while compiling /tmp/E2ZKwnJFmxTwo terms in a rowat /tmp/E2ZKwnJFmx:1------> my $a = <a a b b c>.Bag; $a ⏏(+)= <b b c c>.Bag; say $a # would have expecting any of: postfix…» | ||
08:29
virtualsue joined,
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
lizmat | m: my $a = <a a b b c>.Bag; $a = $a (+) <b b c c>.Bag; say $a | 08:29 | |
camelia | rakudo-moar 698d20: OUTPUT«bag(a(2), b(4), c(3))» | ||
lizmat | guess we need to add set operators to some list that allow = postfix? | 08:30 | |
Woodi | r: my BagHash $a = <a 1 b 2 c 3 d 4>; my BagHash $b = <b 2 c 1>; BagHash $c = $a + $b; say $c | ||
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileTwo terms in a rowat /tmp/tmpfile:1------> 4>; my BagHash $b = <b 2 c 1>; BagHash ⏏$c = $a + $b; say $c expecting any of: postfix…» | ||
Woodi | r: my BagHash $a = <a 1 b 2 c 3 d 4>; my BagHash $b = <b 2 c 1>; BagHash $c = $a (+) $b; say $c | 08:31 | |
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileTwo terms in a rowat /tmp/tmpfile:1------> 4>; my BagHash $b = <b 2 c 1>; BagHash ⏏$c = $a (+) $b; say $c expecting any of: postfix…» | ||
lizmat | Woodi: my missing with $c | ||
Woodi | r: my BagHash $a = <a 1 b 2 c 3 d 4>; my BagHash $b = <b 2 c 1>; my BagHash $c = $a (+) $b; say $c | 08:32 | |
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«Type check failed in assignment to '$a'; expected 'BagHash' but got 'Parcel' in block at /tmp/tmpfile:1» | ||
Woodi | r: my BagHash $a = <a 1 b 2 c 3 d 4>; my BagHash $b = <b 2 c 1>; my BagHash $c = $a + $b; say $c | ||
camelia | rakudo-{parrot,jvm,moar} 698d20: OUTPUT«Type check failed in assignment to '$a'; expected 'BagHash' but got 'Parcel' in block at /tmp/tmpfile:1» | ||
Woodi | anyone blogged about XxYy types maybe ? :) | 08:33 | |
lizmat | I did, for the advent, if I remember correcly | 08:35 | |
Woodi | ook | ||
lizmat | hmmm... one could argue that the result of (+) of two BagHashes should also be a BagHash, and not a Bag | 08:36 | |
08:38
skids left
08:44
skids joined
08:57
bjz_ left,
bjz joined
08:58
plobsing left
|
|||
moritz | then you depart from p6's principle that operators should coerce to the type they operate on | 09:01 | |
though there's precedence | |||
+ on two Ints vs on two Rats | |||
09:09
kivutar joined
09:25
virtualsue left,
clkaoud left,
pnu left,
flussence left,
_sri left
09:31
daniel-s left,
rindolf joined
09:32
daniel-s joined
09:33
molaf joined
09:35
rurban joined
09:36
virtualsue joined,
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
dalek | kudo/nom: 71411c9 | (Elizabeth Mattijsen)++ | src/core/signals.pm: Make sure we send Signal to executed code Rather than just the int that we got from the OS |
09:38 | |
09:39
rurban left
|
|||
FROGGS | jnthn: I need your support :/ gist.github.com/FROGGS/a80aabefe5e39fb553b4 | 09:46 | |
jnthn: I am rethrowing wrongish it seems, but I don't know why because I rethrow like I create the ex in the first place in "last FOO" | |||
09:53
dmol joined
|
|||
FROGGS | hmmm, I think I should have a close look ad handlerDynamic() | 09:55 | |
09:58
nnunley joined
|
|||
jnthn | FROGGS: Just underneath where you added the label checkis: | 10:00 | |
# Wraps a handler with code to set/clear the current handler. | |||
I wonder if the clear needs to happen first | |||
nwc10 | good almost-UGT-violation, jnthn | ||
jnthn | But not convinced it's that... | ||
o/ nwc10 | 10:01 | ||
dalek | ecs: f47db42 | (Elizabeth Mattijsen)++ | S17-concurrency.pod: Spec signal() and some POSIX signals cleanup |
||
10:02
nnunley left
|
|||
lizmat | jnthn: is there an equivalent of "kill -l" under Win ? | 10:03 | |
10:04
baest joined
|
|||
FROGGS | hmmmm | 10:05 | |
jnthn | lizmat: Not afaik | ||
I mean, there's a taskkill program but it's not really about signals in any way...Windows doesn't do signals really. libuv emulates a few. | |||
10:06
baest_ left
|
|||
jnthn | (As in, turns other Windows things into signal-y things) | 10:06 | |
lizmat | ah, ok... hmmm... so qx/kill -1 $*PID/ to test signalI() functionality, is not going to work | 10:07 | |
reliably anyway | |||
would libuv support kill() ? | |||
FROGGS | jnthn: the unwind_check happens within the catch of the delemit_handler | 10:08 | |
jnthn | Not sure it does | ||
Woodi | lizmat: msdn.microsoft.com/en-us/library/xdkz3x12.aspx | ||
lizmat | can we fudge tests depending on OS ? | 10:09 | |
jnthn | Not sure about fudge, but you check OS in a test. | 10:10 | |
And you've got a plan *; then you don't even need to emit skips I guess. | |||
lizmat | I assume you mean $*OS right> | ||
jnthn | Right | ||
lizmat | hmmm... that appears to be a Str atm | 10:11 | |
jnthn | FROGGS: if (vmex.payload.hashCode() == where) { | 10:12 | |
FROGGS | yes? | ||
jnthn | I'm not sure if hashCode is stable over an object's lifetime... | 10:13 | |
vendethiel | lizmat: taskkill /F /PID N ? | ||
FROGGS | jnthn: but that is what nqp::where does... and I was thinking it will never move... :/ | 10:14 | |
okay, I'll keep in mind that I have to keep the label object, and not its address | |||
lizmat | vendethiel++ will put that in the MSWin32 case | ||
$*OS doesn't seem specced | 10:15 | ||
jnthn | FROGGS: Was gonna say.. | ||
$il.append(JAST::PushIVal.new( :value($label ?? nqp::where($label.value) !! 0) )); | |||
That could potentially we doing a wval thingy instead | |||
FROGGS: What is making me curious, though, is we never seem to event hit the outer exception ahdnler at all | 10:16 | ||
That is, I'd expect we'd see another call to _is_same_label | 10:17 | ||
FROGGS | jnthn: me too, that is why I look closer at handlerDynamic | ||
jnthn | yeah. Get it to dump out what it actually puts into the unwindexception, maybe | 10:18 | |
lizmat | perl6: say $*OS # not a lot of consistency :-( | 10:19 | |
jnthn | FROGGS: oooh | ||
camelia | rakudo-{parrot,moar} 698d20: OUTPUT«linux» | ||
..niecza v24-109-g48a8de3: OUTPUT«Unix» | |||
..rakudo-jvm 698d20: OUTPUT«Linux» | |||
jnthn | FROGGS: One important thing you might want to know... | ||
FROGGS: There's a single unwindException per thread | |||
public UnwindException unwinder; | |||
in ThreadContext | |||
Which is re-used | |||
FROGGS | ohhh, I am setting the result in one case.... so I need to clear it in other cases I guess | 10:20 | |
jnthn | Well, also that clearup code I mentioned earlier | ||
oh, maybe not... | 10:21 | ||
But anyway, that could be your problem | |||
FROGGS | but as I said, the unwind_check is being put into the catch of the delimit handler, so this happens first, no? | 10:26 | |
10:31
denis_boyun_ joined
10:35
itz2 joined
|
|||
itz2 | twitter.com/bin3ry/status/46507198...04/photo/1 | 10:35 | |
FROGGS | nice :o) | 10:37 | |
dalek | kudo/nom: c5ac807 | (Elizabeth Mattijsen)++ | src/core/signals.pm: Make sure we do each given signal once |
10:40 | |
10:47
Rotwang joined
|
|||
FROGGS | jnthn: in invokes the same handler again | 10:49 | |
jnthn | FROGGS: So, that bit of logic that places us outside of the handled region I mentioend might fix that... | 10:50 | |
10:52
itz2 left
|
|||
jnthn | Wow, Perl ukulele :) | 10:52 | |
10:54
virtualsue left,
clkaoud left,
pnu left,
flussence left,
_sri left
10:59
nnunley joined
11:05
virtualsue joined,
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
lizmat | I'm seeing all sorts of OS related information spread out in several IO modules, and test-files | 11:22 | |
and $*OS just being s atring | 11:23 | ||
would it be a plan to make $*OS a bit smarter and e.g. add a method "is-win" , "FSTYPE" etc | 11:24 | ||
.name -> .gist / .Str so the current behaviour would still work | |||
does that make sense? Or am I too soon? or do I need to spec first? | |||
11:25
kivutar left
|
|||
jnthn | lizmat: I think S02 does specify various other special vars like $*DISTRO and $*KERNEL that might be worth considering into this | 11:27 | |
colomon | wow, Perl 6 stickers?!! | ||
lizmat | colomon: we'll be taking them to YAPC::NA | 11:28 | |
otherwise, if you want any, please contact woolfy | |||
colomon | will do. ;) | 11:29 | |
lizmat | perl6: say $VM<name> | 11:30 | |
camelia | rakudo-jvm 71411c: OUTPUT«(timeout)» | ||
..niecza v24-109-g48a8de3: OUTPUT«===SORRY!===Variable $VM is not predeclared at /tmp/tmpfile line 1:------> say ⏏$VM<name>Unhandled exception: Check failed at /home/p6eval/niecza/boot/lib/CORE.setting line 1502 (die @ 5) …» | |||
..rakudo-{parrot,moar} 71411c: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileVariable '$VM' is not declaredat /tmp/tmpfile:1------> say $VM<name>⏏<EOL> expecting any of: postfix» | |||
lizmat | perl6: say $*VM<name> # sigh | 11:31 | |
camelia | rakudo-moar 71411c: OUTPUT«moar» | ||
..rakudo-jvm 71411c: OUTPUT«jvm» | |||
..rakudo-parrot 71411c: OUTPUT«parrot» | |||
..niecza v24-109-g48a8de3: OUTPUT«(Any)» | |||
dalek | ecs: 1cba1e7 | (Elizabeth Mattijsen)++ | S02-bits.pod: Fix straggling META.info reference |
11:38 | |
FROGGS | jnthn: I think I understand now | 11:39 | |
lizmat | afk for a few hours& | 11:42 | |
11:44
kaare_ joined
11:51
kaare_ left
12:04
virtualsue left
|
|||
colomon | m: my @a = 1..10; say @a.pairs | 12:05 | |
camelia | rakudo-moar c5ac80: OUTPUT«0 => 1 1 => 2 2 => 3 3 => 4 4 => 5 5 => 6 6 => 7 7 => 8 8 => 9 9 => 10» | ||
12:10
virtualsue joined
|
|||
FROGGS | nice... all nqp's pass the labels test... | 12:20 | |
jnthn | \o/ | ||
FROGGS++ | |||
FROGGS | in theory perl6-j should already be fine, and perl6-p needs the nqp::handle adjustments in the pir block in MapIter.reify | 12:22 | |
but spectests first :o) | |||
ewww | 12:23 | ||
12:23
rurban joined
|
|||
FROGGS | its lets an exception slip when building Perl6::Pod | 12:23 | |
it* | |||
12:24
new6er joined
|
|||
dalek | p/loop_labels: f44aaab | (Tobias Leich)++ | src/vm/jvm/ (3 files): add loop labels support for jvm backend |
12:34 | |
p/loop_labels: 18d11f7 | (Tobias Leich)++ | t/nqp/84-loop-labels.t: add test for labeled for loop |
|||
p/loop_labels: 9dd4604 | (Andrew Egeler)++ | src/vm/jvm/runtime/org/perl6/nqp/runtime/Ops.java: Add write barrier to JVM push ops This was done on moarvm a while back, and fixes a precompilation issue. |
|||
p/loop_labels: 5f942fc | (Andrew Egeler)++ | src/vm/parrot/6model/reprs/CStruct.c: Serialize CStruct on parrot |
|||
p/loop_labels: 948999a | (Andrew Egeler)++ | src/vm/parrot/6model/reprs/CArray.c: Fix memory corruption on CArray resize |
|||
p/loop_labels: 63910f6 | (Tobias Leich)++ | src/vm/ (3 files): Merge branch 'master' of github.com:perl6/nqp into loop_labels |
|||
Heuristic branch merge: pushed 18 commits to rakudo/loop_labels_test by FROGGS | |||
masak | FROGGS++ | 12:38 | |
FROGGS | we're not quite there yet | 12:41 | |
12:45
new6er left,
anaeem1_ joined
|
|||
masak | m: class B { ... }; class A { method foo(B) { "A.foo(B)" } }; class B is A { method foo(A) { "B.foo(A)" } }; my $b = B.new; say $b.foo(A) | 13:16 | |
camelia | rakudo-moar c5ac80: OUTPUT«B.foo(A)» | ||
masak | why is it again that this favors B.foo(A), and doesn't result in a dispatch ambiguity? | 13:17 | |
oh, I didn't declare them proto, for one thing. | 13:18 | ||
jnthn | masak: Did you mean to write "multi"? | ||
masak | um, multi. | ||
masak tries again | |||
m: class B { ... }; class A { multi method foo(B) { "A.foo(B)" } }; class B is A { multi method foo(A) { "B.foo(A)" } }; my $b = B.new; say $b.foo(A) | |||
jnthn | You're just getting normal method dispatch behavior there :) | ||
camelia | rakudo-moar c5ac80: OUTPUT«B.foo(A)» | ||
masak | ok, question repeated. :) | ||
FROGGS | you are calling foo(A), so the foo(A) is narrower than foo(B) | 13:19 | |
m: class B { ... }; class A { multi method foo(B) { "A.foo(B)" } }; class B is A { multi method foo(A) { "B.foo(A)" } }; my $b = B.new; say $b.foo(B) | |||
camelia | rakudo-moar c5ac80: OUTPUT«Ambiguous call to 'foo'; these signatures all match::(A: B, *%_):(B: A, *%_) in block at /tmp/pkM9YolUOD:1» | ||
jnthn | Yeah, but the invocant type should play into it also... | 13:20 | |
masak | FROGGS++ | ||
jnthn | ah, right | ||
masak | right. | ||
jnthn | Yeah, the other candidate doesn't even count. :) | ||
masak | ok, everything's fine. | ||
I think I'm in love with Perl 6's multi dispatch. | 13:21 | ||
FROGGS | ohh yes, I love it too | 13:23 | |
it is totally DWIM and very flexible | |||
even moar with the power of the signatures | 13:24 | ||
13:25
anaeem1_ left
|
|||
jnthn | m: say 5.20 / 5.84 | 13:25 | |
camelia | rakudo-moar c5ac80: OUTPUT«0.890411» | ||
dalek | p/loop_labels: 5e3e216 | (Tobias Leich)++ | src/vm/jvm/runtime/org/perl6/nqp/runtime/ExceptionHandling.java: add accidently removed comments |
13:26 | |
masak | I do wish I could use signatures for destructuring, though. | ||
hoping to write a language extension for that sometime. | |||
jnthn | You...can't? | ||
r: class A { has $.b; has $.c }; my (:$b, :$c) := A.new(b => 1, c => 2); say $b; say $c; | 13:27 | ||
camelia | rakudo-jvm c5ac80: OUTPUT«(timeout)» | ||
..rakudo-{parrot,moar} c5ac80: OUTPUT«12» | |||
jnthn | bah, shoulda m: :) | ||
Granted, you should not do that on any hot path as it's heavily unoptimized. | 13:28 | ||
masak | m: my %struct = name => "Gabriel", addr => ["Pearly Gates", "1", "Heaven"]; my (:$name, :addr([$l1, $l2, $l3])) = %struct; say $name; .say for $l1, $l2, $l3 | 13:29 | |
camelia | rakudo-moar c5ac80: OUTPUT«"name" => "Gabriel"(Mu)(Mu)(Mu)» | ||
masak | :/ | ||
jnthn: like that. | |||
jnthn: but (more crucially), if done in a 'when' expression, the variables should be available inside the block. | 13:30 | ||
jnthn | m: my %struct = name => "Gabriel", addr => ["Pearly Gates", "1", "Heaven"]; my (:$name, :addr($) [$l1, $l2, $l3]) := %struct; say $name; .say for $l1, $l2, $l3 # maybe | 13:31 | |
camelia | rakudo-moar c5ac80: OUTPUT«GabrielPearly Gates1Heaven» | ||
jnthn | Just gotta use sub-sig syntax correct, and remember to bind :P | 13:32 | |
masak | ooh | ||
\o/ | |||
well, that takes care of use case 1. | |||
the syntax is kinda wonky, but fine. | |||
jnthn | About when, I think something is spec'd there wrt sig matching, but not sure I remember implementing it. | ||
masak | oki | 13:33 | |
anyway, jnthn++ | |||
13:39
araujo left
14:09
benabik joined
14:19
skids left,
skids joined
14:20
virtualsue left
14:22
virtualsue joined
14:23
daniel-s left,
daniel-s_ joined
|
|||
dalek | p/loop_labels: 50cae66 | (Tobias Leich)++ | src/vm/jvm/ (3 files): fix regressions by adding exception category for labels |
14:31 | |
14:35
skids left,
skids joined
|
|||
masak | r: package Foo; say "alive" | 14:42 | |
camelia | rakudo-{parrot,jvm,moar} c5ac80: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileThis appears to be Perl 5 code. If you intended it to be Perl 6 code, please use a Perl 6 style package block like "package Foo { ... }", or "module Foo; ...".at /tmp/tmpfi…» | ||
skids | Darn. Actions.nqp line 5543 looked like the perfect explanation for the 0x0123456789abcdef bug, but I changed that to ".0" and no dice. | ||
Still looks fishy, maybe there is another copy of that lying around. | 14:43 | ||
r: 0x123456789abcdef.base(16).say | |||
camelia | rakudo-moar c5ac80: OUTPUT«123456789ABCDF0» | 14:44 | |
..rakudo-{parrot,jvm} c5ac80: OUTPUT«123456789ABCDEF» | |||
skids | see it is adding a zero. | ||
r: Int("0x0123456789abcdef").base(16).say # but not here. | |||
camelia | rakudo-{parrot,jvm,moar} c5ac80: OUTPUT«123456789ABCDEF» | ||
skids | r: 0x00020000000000001.base(16).say; 0x00020000000000000.base(16).say; # and only above this boundary. | 14:46 | |
camelia | rakudo-{parrot,jvm} c5ac80: OUTPUT«2000000000000120000000000000» | ||
..rakudo-moar c5ac80: OUTPUT«2000000000000020000000000000» | |||
skids | oh. | ||
hmm. | |||
and under this boundary: r: 0x10020000000000001.perl.say; | 14:48 | ||
well, anyway there sure are a lot of different codepaths for parsing code/text into Numeric. | 14:49 | ||
14:49
logie_ joined
14:55
logie_ left
15:01
SamuraiJack_ joined
|
|||
dalek | kudo/loop_labels_test: 96e3bdc | (Tobias Leich)++ | src/core/Any.pm: unbreak build caused by a partial fine branch merge |
15:06 | |
p/loop_labels: 748ef15 | (Tobias Leich)++ | src/vm/jvm/QAST/Compiler.nqp: add nqp constant for CONTROL_LABELED |
15:15 | ||
timotimo | could more people try building their moarvm with --optimize=3? | 15:16 | |
retupmoca | timotimo: it worked fine for me last week or so | 15:17 | |
timotimo | i wonder if it's the gcc version? | 15:18 | |
flussence | r: printf('%x', 0x123456789abcdef +& 0xFFFF_FFFF) | 15:30 | |
camelia | rakudo-moar c5ac80: OUTPUT«89abcdf0» | ||
..rakudo-{parrot,jvm} c5ac80: OUTPUT«89abcdef» | |||
flussence | r: printf('%x', 0x123456789abcdef +& 0xFFFF_FFFF_0000_0000) | 15:31 | |
camelia | rakudo-{parrot,jvm,moar} c5ac80: OUTPUT«123456700000000» | ||
skids | r: say nqp::atpos(nqp::radix_I(16, "0123456789abcdef", 0, 2, Int),0).base(16); # this codepath seems to be clean | 15:41 | |
camelia | rakudo-{parrot,jvm,moar} c5ac80: OUTPUT«123456789ABCDEF» | ||
skids | Oh, it isn't adding a zero. It is clobbering a nybble. | 15:43 | |
flussence++ | |||
flussence | seems like a weird range to have an off-by-one in... | 15:45 | |
r-m: say 0x00020000000000000..0x00020000000000005 X+& 0xFFFF_FFFF | 15:46 | ||
r: say 0x00020000000000000..0x00020000000000005 X+& 0xFFFF_FFFF | |||
camelia | rakudo-moar c5ac80: OUTPUT«(timeout)» | 15:47 | |
rakudo-{parrot,moar} c5ac80: OUTPUT«(timeout)» | |||
..rakudo-jvm c5ac80: OUTPUT«0 1 2 3 4 5» | |||
flussence | r-m: say 0x00020000000000000..0x00020000000000005 | ||
camelia | rakudo-moar c5ac80: OUTPUT«9007199254740992..9007199254740996» | ||
flussence | r-m: say 0x00020000000000000...0x00020000000000005 | ||
camelia | rakudo-moar c5ac80: OUTPUT«9007199254740992 9007199254740993 9007199254740994 9007199254740995 9007199254740996» | 15:48 | |
flussence | r-m: say 0x00020000000000000...0x00020000000000005 X+& 0xFFFF_FFFF | ||
camelia | rakudo-moar c5ac80: OUTPUT«(timeout)» | ||
flussence | r-m: say $_ +& 0xFFFF_FFFF for 0x00020000000000000...0x00020000000000005 | ||
camelia | rakudo-moar c5ac80: OUTPUT«01234» | ||
15:49
guru joined,
guru is now known as ajr_
|
|||
flussence | r-m: for 0x00020000000000000..0x00020000000000005 { say $_; say $_ +& 0xFFFF_FFFF } | 15:49 | |
camelia | rakudo-moar c5ac80: OUTPUT«(timeout)900719925474099209007199254740992090071992547409920900719925474099209007199254740992090071992547409920900719925474099209007199254740992090071992547409920900719925474099209007199254740992…» | ||
flussence | oh I get it... that number problem is making the range iterator horribly confused... | 15:50 | |
r-m: for 0x00020000000000000...0x00020000000000005 { say $_; say $_ +& 0xFFFF_FFFF } | |||
camelia | rakudo-moar c5ac80: OUTPUT«9007199254740992090071992547409931900719925474099429007199254740995390071992547409964» | ||
flussence | r-m: for 0x00020000000000000...0x00020000000000005 { say ($_, $_ +& 0xFFFF_FFFF)».fmt('%x') } | 15:51 | |
camelia | rakudo-moar c5ac80: OUTPUT«20000000000000 020000000000001 120000000000002 220000000000003 320000000000004 4» | ||
flussence | ...but not the sequence op, for some reason. | 15:52 | |
15:52
spider-mario joined
|
|||
flussence | r-m: for 0x123456789abcdef...0x123456789abcdff { say ($_, $_ +& 0xFFFF_FFFF)».fmt('%x') } | 15:53 | |
camelia | rakudo-moar c5ac80: OUTPUT«123456789abcdf0 89abcdf0123456789abcdf1 89abcdf1123456789abcdf2 89abcdf2123456789abcdf3 89abcdf3123456789abcdf4 89abcdf4123456789abcdf5 89abcdf5123456789abcdf6 89abcdf6123456789abcdf7 89abcdf7123456789abcdf8 89abcdf8123456789abcd…» | ||
flussence | r-m: for 0x123456789abcdef..0x123456789abcdff { say ($_, $_ +& 0xFFFF_FFFF)».fmt('%x') } | ||
r-p: for 0x123456789abcdef..0x123456789abcdff { say ($_, $_ +& 0xFFFF_FFFF)».fmt('%x') } | |||
camelia | rakudo-moar c5ac80: OUTPUT«(timeout)123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf01234…» | 15:54 | |
rakudo-parrot c5ac80: OUTPUT«(timeout)123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf0123456789abcdf0 89abcdf012…» | |||
flussence | r-j: for 0x123456789abcdef..0x123456789abcdff { say ($_, $_ +& 0xFFFF_FFFF)».fmt('%x') } | ||
camelia | rakudo-jvm c5ac80: OUTPUT«123456789abcdef 89abcdef123456789abcdf0 89abcdf0123456789abcdf1 89abcdf1123456789abcdf2 89abcdf2123456789abcdf3 89abcdf3123456789abcdf4 89abcdf4123456789abcdf5 89abcdf5123456789abcdf6 89abcdf6123456789abcdf7 89abcdf7123456789abcdf…» | ||
flussence | r: say 0x123456789abcdef.succ | 15:55 | |
camelia | rakudo-{parrot,jvm} c5ac80: OUTPUT«81985529216486896» | ||
..rakudo-moar c5ac80: OUTPUT«81985529216486897» | |||
flussence | r: say 0x123456789abcdef.succ.succ | ||
camelia | rakudo-moar c5ac80: OUTPUT«81985529216486898» | ||
..rakudo-{parrot,jvm} c5ac80: OUTPUT«81985529216486897» | |||
flussence | r: say 0x123456789abcdf0.succ | 15:56 | |
camelia | rakudo-{parrot,jvm,moar} c5ac80: OUTPUT«81985529216486897» | ||
flussence | bignum scary. | ||
flussence goes back to his nice sane html regexing... | 15:57 | ||
skids | Yeah who needs numbers anymore :-) | ||
16:16
araujo joined,
araujo left,
araujo joined
16:26
clkaoud left,
pnu left,
flussence left,
_sri left
|
|||
TimToady | m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; say %a »+« %b | 16:32 | |
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
TimToady | that should likely suppress those warnings | ||
it should probably just copy over values that are in only one hash or the other | 16:35 | ||
16:38
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
colomon | +1 | 16:41 | |
TimToady | m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a »+=« %b; say %a | 16:42 | |
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 1, "b" => 4, "c" => 4, "d" => 4).hash» | ||
16:42
thou joined
|
|||
TimToady | m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a »+«= %b; say %a | 16:42 | |
camelia | rakudo-moar c5ac80: OUTPUT«===SORRY!=== Error while compiling /tmp/OvaiRAfr97Preceding context expects a term, but found infix = insteadat /tmp/OvaiRAfr97:1------> b 2 c 3 d 4>; my %b = <b 2 c 1>; %a »+«=⏏ %b; say %a» | ||
TimToady | ah, yes, rakudo don't parse assignops correctly yet | 16:43 | |
n: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1>; %a »+«= %b; say %a | |||
camelia | niecza v24-109-g48a8de3: OUTPUT«Use of uninitialized value in numeric context at /home/p6eval/niecza/lib/CORE.setting line 1389 (warn @ 5)  at /home/p6eval/niecza/lib/CORE.setting line 301 (Any.Numeric @ 8)  at <unknown> line 0 (ExitRunloop @ 0)  at /home/p6eval/niec…» | ||
colomon | which of the two forms is correct? »+«= vs »+=« | 16:44 | |
TimToady | niecza++ does but has even more verbose warnings | ||
they are both correct :) | |||
16:49
daniel-s_ left
16:50
daniel-s_ joined
16:51
zakharyas joined
|
|||
colomon | There's more than one way, eh? | 16:57 | |
16:59
xinming joined
|
|||
TimToady | they mean different things, but achieve the same result, assuming standard hash semantics | 17:02 | |
well, maybe not, now that I think about it more | 17:05 | ||
17:05
anaeem1 joined
|
|||
TimToady | there's nothing in »+=« that will make sure the keys of the right side will end up in the left side's hash | 17:06 | |
unless the hyper somehow notices it's a mutating operator | |||
I guess if it's careful to iterate the right hash'es keys, autoviv will work on the left side appropriately | 17:10 | ||
m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1 e 5>; %a »+=« %b; say %a | 17:12 | ||
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 1, "b" => 4, "c" => 4, "d" => 4, "e" => 5).hash» | ||
TimToady | ha, works already, somehow | 17:13 | |
m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1 e 5>; %a »R[+=]« %b; say %b | 17:14 | ||
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric context("a" => 1, "b" => 4, "c" => 4, "d" => 4, "e" => 5).hash» | ||
TimToady | and works with a reversed op even, but that's why we get the warning, because it's always calling the 2-arg form (which is what allows autoviv, I guess) | 17:15 | |
so the correct thing is to suppress the warning, not introspect the args to try to figure out which ones are there vs never there vs maybe there through autoviv | 17:16 | ||
17:16
denis_boyun_ left,
denis_boyun_ joined
|
|||
TimToady | introspecting is once again a code smell | 17:16 | |
17:18
firnsy left
|
|||
lizmat wishes warnings worked more like "is DEPRECATED" | 17:18 | ||
instead of just mumbling, keeping the into until the end and then show where they happened (and how many times) | 17:19 | ||
*info | |||
17:27
btyler joined
|
|||
dalek | p/lexopts: c9e9e90 | jnthn++ | src/vm/moar/stage0/ (11 files): Update stage0 for MoarVM. The previous bootstrap contained mis-generated code that upset a more aggressive spesh. Furthermore, the generated code is far better these days. Between spesh and the better stage0 (meaning we build stage 1 faster), the NQP build is now down to 41s (from around 50s) for me. |
17:28 | |
lizmat | jnthn++ | 17:29 | |
jnthn | Faster NQP builds for all. Once that merges... :) | 17:31 | |
masak | the above discussion about »+=« reminds me of rt.perl.org/Ticket/Display.html?id=118223 | ||
r: my %l = foo => 1, bar => 2; my %r = bar => 3, baz => 4; say %l >>+<< %r | |||
camelia | rakudo-{jvm,moar} c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("bar" => 5, "baz" => 4, "foo" => 1).hash» | ||
..rakudo-parrot c5ac80: OUTPUT«use of uninitialized value of type Any in numeric context in block at /tmp/tmpfile:1use of uninitialized value of type Any in numeric context in block at /tmp/tmpfile:1("bar" => 5, "baz" => 4, "foo" => 1).hash» | |||
masak | shouldn't warn. | 17:32 | |
timotimo | jnthn: ŷay! \o/ | 17:33 | |
lizmat | masak jnthn : looking into it now | ||
but short of implementing "no warnings" I don't really see an easy fix yet | 17:34 | ||
I see some optimizations | |||
17:35
daniel-s_ left
17:36
daniel-s_ joined
17:38
hoverboard joined
17:41
firnsy joined,
firnsy left,
firnsy joined,
thou left
17:42
btyler_ joined
|
|||
tadzik | aww yiss | 17:43 | |
17:45
btyler left
|
|||
TimToady | lizmat: well, you need something like a CONTROL that traps warnings dynamically, since the code in question is handed to you by reference | 17:46 | |
alternately, we need some way for warn to know its context and refrain from warning in the first place | 17:48 | ||
17:49
anaeem1 left
|
|||
lizmat tries to grok CONTROL better | 17:50 | ||
TimToady | but HOP basically requires dynamic scoping for indirect function control, since you don't have textual control of the, er, text | 17:51 | |
the only other alternative is to parameterize everything | |||
and when you need to parameterize everything, that usually is a design smell that you need dynamic scoping instead | 17:52 | ||
17:53
Zaegnair left
|
|||
FROGGS | ohh | 17:56 | |
jnthn++ | |||
masak | m: say lines>>.comb.grep("a".."z").Bag.format("%s: %s") | 17:57 | |
17:57
MikeFair_ joined
|
|||
camelia | rakudo-moar c5ac80: OUTPUT«No such method 'format' for invocant of type 'Bag' in block at /tmp/1CVFQCnVST:1» | 17:57 | |
masak | requested: .format on Bag objects. | ||
m: say lines>>.comb.grep("a".."z").Bag.Hash.format("%s: %s") | 17:58 | ||
camelia | rakudo-moar c5ac80: OUTPUT«No such method 'Hash' for invocant of type 'Bag' in block at /tmp/4S2S9dbKOr:1» | ||
masak | hm. | ||
TimToady | lizmat: otoh, I can argue myself out of doing by warning supression, since that doesn't fix the case of »*=« wanting to default to multiplying by 1 rather than 0 | ||
so some degree of introspection is probably required in hypers | 17:59 | ||
we really need to be able to ask an operator which argument or arguments it expects to be rw | 18:00 | ||
colomon wonders if there is overlap with the Bag operators here... | |||
TimToady | yes, but a Bag only does +=, not *= | 18:01 | |
masak | m: .say for lines>>.comb.grep("a".."z").Bag.pairs | ||
camelia | rakudo-moar c5ac80: OUTPUT«"h" => 103"e" => 150"r" => 71"w" => 23"t" => 95"m" => 44"n" => 84"c" => 18"a" => 67"o" => 81"u" => 23"f" => 12"s" => 51"i" => 55"y" => 25"d" => 56"l" => 55"v" => 18"p" => 11"g" => 10"z" => 1"k"…» | ||
masak | ok, that works. | ||
m: .say for lines>>.comb.grep("a".."z").Bag.pairs.sort | |||
camelia | rakudo-moar c5ac80: OUTPUT«"a" => 67"b" => 17"c" => 18"d" => 56"e" => 150"f" => 12"g" => 10"h" => 103"i" => 55"k" => 8"l" => 55"m" => 44"n" => 84"o" => 81"p" => 11"r" => 71"s" => 51"t" => 95"u" => 23"v" => 18"w" => 23"x"…» | ||
masak | \o/ | 18:02 | |
TimToady | m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1 e 5>; %a »*=« %b; say %a | 18:03 | |
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 0, "b" => 4, "c" => 3, "d" => 0, "e" => 5).hash» | ||
18:03
daniel-s_ left
|
|||
TimToady | see, those 0's are probably wrong | 18:04 | |
timotimo | retupmoca: thanks :) | ||
masak | timotimo: yes, those 0s are wrong. | 18:05 | |
er, TimToady* | |||
TimToady | but we can't just default undefineds to the identity element, or be break autoviv | 18:06 | |
s/be/we/ | |||
so we really need to know which args are being modified | 18:07 | ||
masak | oh, I meant they're wrong because »*=« should only act on keys that are in both hashes, not at-least-one. | ||
«*=» should act on all possible keys. | 18:08 | ||
TimToady | no, that would be «*=» instead, according to spec | ||
masak | oh, ok. | ||
timotimo | does/should that factor in "is default"? | 18:09 | |
TimToady | that should be invisible to the hyper | ||
you fetch from the hash, and it gives you a value | |||
you don't care if it was the default | |||
lizmat | but the * is the problem there, not the *=, right? | ||
m: my %a = <a 1>; my %b = <b 2>; say %a »*« %b | 18:10 | ||
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 0, "b" => 0).hash» | ||
TimToady | which is why that case should probably just copy over such values | ||
much as reduce on a single arg just copies it, on the assumpion that applying the identity would end up with result | 18:11 | ||
lizmat | would that then be special cased for &infix:<*> ? | ||
how would that work for a custom op "foo" | |||
TimToady | it's a special case for hypers | ||
the op doesn't have to care | |||
lizmat | but suppose an op "foo" has a multiplcative component | 18:12 | |
then %a >>foo<< %b would do the wrong thing | |||
TimToady | m: my %a = <a 1 b 2 c 3 d 4>; my %b = <b 2 c 1 e 5>; %a «*=« %b; say %a | 18:13 | |
camelia | rakudo-moar c5ac80: OUTPUT«("a" => "1", "b" => 4, "c" => 3, "d" => "4", "e" => 5).hash» | ||
lizmat | because hyper wouldn't know to copy the value if one of the sides is missing | ||
TimToady | I guess using «« is a workaround | ||
lizmat: I don't understand your objection, can you give an example | 18:14 | ||
note that «« doesn't warn either | 18:15 | ||
lizmat | m: sub infix:<foo> { $^a * $^b }; my %a=<a 1>; my %b = <b 2>; say %a >>foo<< %b | 18:16 | |
camelia | rakudo-moar c5ac80: OUTPUT«use of uninitialized value of type Any in numeric contextuse of uninitialized value of type Any in numeric context("a" => 0, "b" => 0).hash» | ||
18:16
rurban left,
molaf left
|
|||
lizmat | if we special case infix:<*> to copy if one side is missing, it wouldn't know how to do that with "foo" as an operator | 18:17 | |
TimToady | I never said to special-case * | ||
I said to special-case hyper | |||
if one side is missing, it would just copy the other side | |||
lizmat | ah, in that way, regardless of op | ||
TimToady | (except that doesn't work well with autoviv) | ||
since it wouldn't trigger the = part of the op | 18:18 | ||
lizmat | hmmm..... | ||
TimToady | m: sub infix:<foo> { $^a * $^b }; my %a=<a 1>; my %b = <b 2>; %a <<foo=<< %b; say %a | ||
camelia | rakudo-moar c5ac80: OUTPUT«Not enough positional parameters passed; got 0 but expected 2 in sub infix:<foo> at /tmp/36S8cT_EtP:1 in block at src/gen/m-CORE.setting:17119 in sub hyper at src/gen/m-CORE.setting:17365 in sub hyper at src/gen/m-CORE.setting:17474 in…» | ||
TimToady | hmm, that's maybe another bug | 18:19 | |
lizmat | possibly :-) looks like | ||
TimToady | m: sub infix:<foo> { $^a * $^b }; my %a=<a 1>; my %b = <b 2>; %a «foo=« %b; say %a | 18:20 | |
camelia | rakudo-moar c5ac80: OUTPUT«Not enough positional parameters passed; got 0 but expected 2 in sub infix:<foo> at /tmp/sbwdG2o9ck:1 in block at src/gen/m-CORE.setting:17119 in sub hyper at src/gen/m-CORE.setting:17365 in sub hyper at src/gen/m-CORE.setting:17474 in…» | ||
TimToady | something is trying to look up the identity value, I think | ||
m: multi infix:<foo> () { 1 }; multi infix:<foo> { $^a * $^b }; my %a=<a 1>; my %b = <b 2>; %a «foo=« %b; say %a | |||
camelia | rakudo-moar c5ac80: OUTPUT«("a" => "1", "b" => 2).hash» | ||
TimToady | yup | 18:21 | |
masak | m: sub MAIN($year = Date.today.year) { sub last-day-of-month($month) { my $d = Date.new($year, $month, 1); $d.clone(:day($d.days-in-month)) }; say last-day-of-month($_) for 1..12 } | ||
camelia | rakudo-moar c5ac80: OUTPUT«2014-01-312014-02-282014-03-312014-04-302014-05-312014-06-302014-07-312014-08-312014-09-302014-10-312014-11-302014-12-31» | ||
masak | can anyone think of a nicer, more idiomatic way to implement last-day-of-month? | ||
specifically, does it really have to be two statements like that? | |||
lizmat | well, the last day of the month is one day before the first day of the next month | 18:22 | |
TimToady | add one month, change to 1, back up one day | ||
masak | not sure we have "add one month" :) | ||
18:22
anaeem1 joined
|
|||
masak | oh wait, we have .delta :P | 18:22 | |
TimToady | yeah, somebody implemented that once upon a time, I FORGET WHO!!! | 18:23 | |
masak | :P | ||
m: sub MAIN($year = Date.today.year) { sub last-day-of-month($month) { Date.new($year, $month, 1).delta(1, month).delta(-1, day) }; say last-day-of-month($_) for 1..12 } | |||
camelia | rakudo-moar c5ac80: OUTPUT«2014-01-312014-02-282014-03-312014-04-302014-05-312014-06-302014-07-312014-08-312014-09-302014-10-312014-11-302014-12-31» | ||
masak | delta++ | ||
dalek | kudo/nom: aff2a66 | (Elizabeth Mattijsen)++ | src/core/metaops.pm: Move tests outside of loops for better performance |
||
TimToady still kinda hates that API | 18:24 | ||
18:24
bjz left
|
|||
lizmat | jnthn: ^^^ does it make sense to make this type of optimization | 18:24 | |
or is that something that will be optimized automagically in the future ? | |||
FROGGS | TimToady: is there a DateTime API out there taht you don't hate? | ||
DateTime always sucks | 18:25 | ||
lizmat | fwiw, I agree DateTime sucks :-) | ||
TimToady | I'd rather have N different deltas than to have weird constants that use up namespace without provided any other value | 18:26 | |
FROGGS | I mean, drolsky++ did a great job, but there are so many absurdities you must take are of that make it hard to create a nice API | ||
TimToady | .add-month(1) is better than .delta(1,month) | ||
18:27
anaeem1 left
|
|||
FROGGS | yeah, days => 1 as in P5 is slightly nicer I think | 18:27 | |
masak | still not too late to change. | 18:28 | |
TimToady | well, .delta(month => 1) would be better than the current form, I think | ||
lizmat | .delta( :day ) # one day | ||
FROGGS | True | ||
TimToady | smelly | ||
FROGGS | :P | ||
masak | yeah. | ||
TimToady | .add-day | ||
masak | .add-days ? | ||
jnthn | lizmat: Probably worth it for the time being | ||
TimToady | I'd make it singular so that the default of 1 makes more sense | ||
jnthn | lizmat: Maybe one day we'll be able to auto-opt it, but it's not trivial and won't happen soon | 18:29 | |
lizmat | jnthn; I also timed %k{a.keys} = () | ||
but that was twice as slow (at least) | |||
I guess because it's building the result list | |||
%keys{a.keys} = () | 18:30 | ||
wouldn't need the result list | |||
masak | I suggest .add and .subtract (just like CPAN's DateTime), and then day => 1 and days => 1 both work. | ||
lizmat | since this is the core setting, I couldn't use Set :-) | ||
masak | all unknown keys give an error. | ||
TimToady | not sure add/subtract is the best refacter of delta | 18:31 | |
18:31
SamuraiJack_ left
|
|||
TimToady | it's like reinventing signs | 18:31 | |
but if we did, .later/.earlier might make more sense | 18:32 | ||
or some other more time-oriented metaphor | |||
FROGGS | I like later/earlier somehow | ||
TimToady | .forward/.back | 18:33 | |
but that's backwardly huffmanized, perhaps | |||
TimToady wonders what's the opposte of "ago"... | |||
lizmat | If we're talking about dates, wouldn't a "string" like object like "2014-05-10" become a datetime object automatically? | ||
18:34
hoverboard left
|
|||
lizmat | or something like "2014y05m10d" ? | 18:34 | |
TimToady | not by itself it won't | ||
you need some context to indicate that the string is meant as a date. Just looking like a date is insufficient | 18:35 | ||
it's fine if a function wants to interpret a string that way, but a bare string shouldn't | |||
FROGGS | we have Str.path... so Str.date feels right, but I don't like ending up with a thousand methods on Cool | 18:36 | |
lizmat | how about "0D20140510" | ||
FROGGS | but it would be nice if it was short | ||
lizmat: that is still a string | |||
TimToady | Introspection of Strings Considered Harmful | ||
lizmat | m: say 0d12345.WHAT, | ||
18:36
daniel-s_ joined
|
|||
camelia | rakudo-moar c5ac80: OUTPUT«===SORRY!=== Error while compiling /tmp/MWrCtt_BTfTwo terms in a rowat /tmp/MWrCtt_BTf:1------> say 0d12345.WHAT,⏏<EOL> expecting any of: method arguments postfix infix sto…» | 18:36 | |
FROGGS | ahh | 18:37 | |
hmmm | |||
lizmat | 0D prefix indicates a Date | ||
FROGGS | I dunno | ||
weird :o) | |||
masak | sounds like something a module would do, not core. | 18:38 | |
FROGGS | a datetime literal... I mean, the idea is nice | ||
dalek | ecs: 337f433 | masak++ | S32-setting-library/Temporal.pod: [S32/Temporal] retire TimeUnit enum and .delta Use strings in .truncate-to instead. .delta now becomes .later and .earlier, and they expect string keys as named arguments. |
||
masak | kudos to whoever updates Rakudo to follow the above change :) | ||
hint: not so hard. | |||
FROGGS | we have version literals that are like \d.\d.\d, we could also parse \d-\d-\d[T\d:\d:\d] | 18:39 | |
lizmat | nonono | ||
TimToady | m: say 1.2.3 | ||
camelia | rakudo-moar c5ac80: OUTPUT«===SORRY!=== Error while compiling /tmp/KO5aMMqosEConfusedat /tmp/KO5aMMqosE:1------> say 1.2.⏏3 expecting any of: postfix dotty method or postfix» | ||
FROGGS | leading v, yeah | ||
TimToady | std: say 1.2.3 | ||
camelia | std ec3d853: OUTPUT«===SORRY!===Number contains two decimal points (missing 'v' for version number?) at /tmp/T101xqeoFz line 1:------> say 1.2⏏.3Check failedFAILED 00:01 122m» | ||
lizmat | I think version literals are not a good model | ||
TimToady | the rakudo message is LTA | ||
FROGGS | lizmat: but that is the most similar thing we have | 18:40 | |
lizmat | true | ||
FROGGS | and I like consistency | ||
in P5 I have a dt() sub that understands some datetime strings and epoch and returns a DateTime object | 18:41 | ||
I use that everywhere and it is enough... | |||
TimToady | std: say d2014-05-10 | ||
18:41
Crazylemon64 joined
|
|||
camelia | std ec3d853: OUTPUT«===SORRY!===Undeclared routine: 'd2014' used at line 1Potential difficulties: Leading 0 does not indicate octal in Perl 6; please use 0o5 if you mean that at /tmp/7AFDeyre_M line 1:------> say d2014-05⏏-10…» | 18:41 | |
18:42
bjz joined
|
|||
TimToady | well, specific dates seem like an unlikely thing to want to hardcode into a program | 18:42 | |
FROGGS | problem is that you sometimes want/need to specify the timezone as well | ||
not at all | |||
I calculate fees at $work, and there are a lot of hardcoded datetimes in there | |||
like where the bosses decide that something gets handled differently from a given date | 18:43 | ||
TimToady | seems like something that would make a program go obsolete rather quickly | ||
lizmat | like 20% VAT before d2014-01-01 and 21% after | ||
TimToady | not sure it's worth the huffman cost | ||
lizmat | well, in a business like Booking.com, pretty much everything revolves around dates | 18:44 | |
FROGGS | sure, I dunno if it is important enough to have that, or just nice now | ||
TimToady | well, modules will happen, once we actually have a compiler that can derive slangs | ||
lizmat | anybody doing any logging: dates | ||
TimToady | or it'd be a pretty trivial macro once we have is-parsed | 18:45 | |
btyler_ | date literals seem like an invitation to put something in code that should probably live in a database of some sort | ||
not that perl has ever been in the business of laying down laws like that :) just a feeling | |||
lizmat | btyler_: you underestmate the about of ad-hoc processing of logs that occur in companies | ||
*amount | 18:46 | ||
btyler_ | that's fair | ||
was thinking about it from a business logic point of view, log processing is a good counterexample | |||
lizmat | and we don't want Hadoop to take that all :-) | ||
masak | I agree that literal dates in core don't carry their weight enough to bother. | ||
TimToady | a date comparison routine could certainly upgrade strings to date | ||
FROGGS | especially in one-liners a date(time) literal would make sense, aye | ||
masak | even one-liners could load a module. | 18:47 | |
FROGGS | but but... it is extra typing :P | ||
not saying it has to be in core though | |||
TimToady | .oO(autoloading any language tweaks that recognize the current syntax error...) |
18:48 | |
"Oh, hey, you just wrote some COBOL, I'll switch to that for you." | |||
lizmat | TimToady: regarding $*OS, is that a keeper or should that be deprecated in favour of $*DISTRO ? | 18:49 | |
dalek | kudo-star-daily: dc31b7b | coke++ | log/ (5 files): today (automated commit) |
||
rl6-roast-data: 5b09b57 | coke++ | / (6 files): today (automated commit) |
|||
rl6-roast-data: 3bf8de5 | coke++ | / (6 files): today (automated commit) |
|||
TimToady | "This looks like both Fortran and Python. I'll just run it both ways for you." | ||
FROGGS | *g* | ||
lizmat | the only mention in the spec is in S32/IO:836 | 18:50 | |
vendethiel | was it VB that had a syntax for date S? | ||
TimToady | $*OS is a zombie, it just keeps coming back after we kill it | ||
FROGGS | lizmat: ethercalc.org/wrwsbhvuim | ||
vendethiel | #01/01/2014# | ||
18:50
Sqirrel left
|
|||
TimToady | either you want $*KERNEL or you want $*DISTRO, generally | 18:50 | |
FROGGS | lizmat: last time TimToady admitted that we might are allowed to keep $*OS for some reason... but $*KERNEL was preferred I think | 18:51 | |
lizmat | vendethiel: if we do that, please let us stick to YYYY-MM-DD | 18:52 | |
vendethiel | please don't, though :P | ||
lizmat | because your format is ambiguous as to MM-DD-YYYY or DD-MM-YYYY | ||
btyler_ | "day month or month day? arrrgh!" | ||
FROGGS | vendethiel: we will stick to YYYY-MM-DD! :P | ||
vendethiel | I'm french, so it's always dd/mm/yyyy here. | ||
not the bad one with day in the middle | 18:53 | ||
TimToady | the only thing $*OS has going for it is its brevity | ||
lizmat | well, that me be logical in some way, but no wrt to e.g. sorting :-) | ||
well, $*OS could be short for $*KERNEL.name ? | |||
tadzik | new game ready to test at github.com/tadzik/steroids | ||
this time it needs SDL2_ttf too | 18:54 | ||
18:54
rurban joined
|
|||
btyler_ | tadzik: somehow your Makefile was categorized as R, heh | 18:54 | |
FROGGS | tadzik: sounds like you need Alien::SDL2 :o) | ||
tadzik | heheh | ||
oh, btw, makefiles are a mess | |||
btyler_ | I really wish github would let authors just correct the language detection. I have several repos that github thinks are 2/3rds COBOL because some files have a .cob extension | 18:55 | |
tadzik | since you need to run both | ||
and I forgot to update the firsst one | |||
ok all good now | |||
TimToady | lizmat: it's still not what people usually thing of when you say "OS", so it'll confuse people that think it should mean $*DISTRO.name, or something nebulous between distro and kernel | ||
lizmat | so, deprecate $*OS ? | 18:56 | |
18:56
clkaoud left,
pnu left,
flussence left,
_sri left
|
|||
TimToady | like that portion of your distro that came from GNU, which is the part properly called GNU/Linux, but that's neither the distro nor the kernel | 18:56 | |
FROGGS | TimToady: it would be the kernal.auth in my book: ethercalc.org/wrwsbhvuim | 18:57 | |
TimToady | gah, that's a commodore spelling | ||
avoiding that misspelling is a good reason to shorten it to $*KERN, while teaching people the correct spelling is a good reason to keep it $*KERNEL :) | 18:58 | ||
18:58
rurban left
|
|||
FROGGS | this list was intended to be a start to sort things out... but I was the only editor, so.... :/ | 18:58 | |
ohh, that is what you mean :o) | 18:59 | ||
masak | m: say Date("2014-05-10") | 19:00 | |
camelia | rakudo-moar c5ac80: OUTPUT«Cannot find method 'Date' in block at /tmp/Higo_XFrZW:1» | ||
TimToady | I'm sure that Linus would pitch a complete fit if you told him that GNU was the auth of his kernel | ||
masak | m: say Date.new("2014-05-10") | ||
camelia | rakudo-moar c5ac80: OUTPUT«2014-05-10» | ||
lizmat | afk for a few hours for some mindless entertainment: en.wikipedia.org/wiki/Eurovision_So...ntest_2014 | ||
masak | oh, that's today? | 19:01 | |
TimToady | the GNU part of GNU/Linux is only the add-ons outside the kernel | ||
the part that $*KERNEL is specifically meant to exclude, because those things are added by the $*DISTRO | 19:02 | ||
tadzik sees the polish song participating and cringes a little | |||
TimToady | or perhaps by the $*VM | ||
19:03
darutoko left
19:04
Khisanth left
|
|||
TimToady | $*ARCH < $*KERNEL < $*DISTRO < $*VM # more or less | 19:06 | |
assuming we can include $*VM as part of a $*DISTRO, even if it wasn't originally supplied on the .iso :) | 19:07 | ||
presumably the $*DISTRO gave you the means of installing the $*VM | |||
19:07
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
TimToady | we may get other layers in that stack eventually, given virtualization of kernels | 19:07 | |
though anything called "virtual" is introducing a feedback loop of some sort | 19:08 | ||
so a VM is trying to pretend to be the root of a new $*ARCH, in a way | 19:09 | ||
and the VM will have its own kernel and utilities built on its architecture, so maybe we need something a bit more recursive here | 19:10 | ||
19:11
rurban joined
|
|||
btyler_ | tadzik: trying to get space invaders going...makefile needed tweaking to include SDL2_ttf so sdlwrapper would compile; now Steroids::Colour seems to be missing? | 19:12 | |
TimToady | so $*ARCH on a vm might say "JVM" but there's some way to get to $*JVM.native-arch | ||
TimToady suspects we will only get more layers of machine emulation in the future | 19:13 | ||
tadzik | btyler_: hmm | 19:14 | |
btyler_: makefile-sdlwrapper should be fine | |||
the other makefile was just updated 20 minutes aog | |||
after I said "ready for testing", sorry :) | |||
19:14
plobsing joined
|
|||
btyler_ | tadzik: Configure.pl seems to want to work on Makefile, rather than makefile.sdlwrapper (which contains some paths from your machine). anyways, that's a super easy tweak. where can I grab steroids::colour? | 19:18 | |
19:18
Khisanth joined
|
|||
tadzik | oh, I didn't commit it! Stupid me | 19:18 | |
Configure.pl may be outdated, yeah :/ | |||
btyler_: fixed, thansk :) | 19:19 | ||
just pull | |||
rindolf | Hi all. | ||
Happy Saturday. | |||
btyler_ | tadzik: is there also an assets/font.ttf waiting to be pushed? :) | 19:21 | |
19:21
clkaoud left,
pnu left,
flussence left,
_sri left,
molaf joined
|
|||
TimToady | so, obviously openbsd, netbsd, freebsd, etc are diffierent distros, but are they different kernels? | 19:23 | |
at what point does the species known as 'bsd kernel' turn into multiple species? | |||
or maybe those are different kernels now, with multiple distros on top of each of those? | 19:24 | ||
19:24
rurban left
|
|||
TimToady | Linnean hierarchies don't deal all that well with evolutionary branching... | 19:25 | |
one might posit that the kernel is most like the actual genome, but distros are in the business horizontal gene transfer | 19:26 | ||
but all these analogies break down sooner or later in the face of reality | |||
the taxonomy of execution contexts is not a solved problem, sigh... | 19:27 | ||
FROGGS | I dunno, that is why I tried to make up that list and put in real values... | 19:28 | |
tadzik | btyler_: oh, of course :O | 19:29 | |
btyler_: it should all be there now :o | |||
nwc10 | TimToady: I don't know either. and Debian/kfreebsd messes it all up further | 19:30 | |
I tend to think of the *BSDs as rabbits, because they seem to be breedng like ... | |||
19:32
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
|
|||
btyler_ | tadzik: yay! got it working :) good stuff | 19:32 | |
explosions look excellent, and it runs very smoothly | 19:33 | ||
tadzik | smoothly? Neat :D | 19:35 | |
btyler_: if you have an xbox controller, it should work too | |||
btyler_ | oh! sadly no, but that's awesome | ||
tadzik | not on the menu though :D I need to update that | ||
19:36
anaeem1 joined
|
|||
colomon | url? | 19:36 | |
colomon has been playing a good bit of Galaga '88 lately.... | 19:37 | ||
btyler_ | a few things I had to tweak to get it going: configure.pl needed -lSDL2_ttf added to line 31; $*VM<config><dll> for OSX includes "lib" in the name, so after the %s subst the makefile produces sdlwrapperlib.dylib (and, of course, lib/Steroids/SDL.pm is looking for sdlwrapper.dylib) | ||
tadzik | colomon: github.com/tadzik/steroids | 19:38 | |
btyler_: yeah, Configure.pl is a bit rusty, I need to update it | |||
thanks for playtesting :) | |||
btyler_ | and (this is just me being a newb, I'm sure), SpaceInvaders sets blib/lib as the lib location, but the repo just has a /lib; I just tweaked the 'use lib' line in spaceInvaders, but I suspect there's a way I'm supposed to turn lib into blib/lib :) | 19:39 | |
I've been really enjoying the various steroids-based games, really exciting to see how concise and straightforward the game logic is | 19:40 | ||
19:41
molaf_ joined
19:43
clkaoud left,
pnu left,
flussence left,
_sri left
|
|||
TimToady | btyler_: perhaps there are some graphical RosettaCode entries that you're ready to write now :) | 19:43 | |
19:44
molaf left
|
|||
tadzik | btyler_: makefile should generate blib/lib for you | 19:45 | |
precompile all the things | |||
btyler_ | TimToady: what kind of entries? I always thought the idea with RC was to avoid problems that likely required substantial external libs | 19:46 | |
TimToady | well, most language require external libs for a lot more than Perl does, so external libs are fine | 19:47 | |
rosettacode.org/wiki/Image_noise is an example of something that's really an animation sort of task | 19:48 | ||
colomon | tadzik: SDL_image.h ? | 19:50 | |
btyler_ | hm, neat. heh, looks like some of the entries are pretty thin wrappers around openGL | ||
TimToady | most of the languages pull in libraries for that tsk | 19:51 | |
task too | |||
only languages that try to enforce a particular graphical context are exempt, like basic, icon, and such | 19:52 | ||
most language know better than to try to do thta | |||
tadzik | colomon: what abou tit? | ||
TimToady | that too | ||
tadzik | oh, may need sdl2-image installed | ||
colomon | tadzik: that would probably be it | ||
19:54
clkaoud joined,
pnu joined,
flussence joined,
_sri joined
19:56
daniel-s_ left
|
|||
nwc10 | where should I look to find out which dynamic vars are implemented, such as $*OS ? | 19:56 | |
colomon | tadzik: SDL_ttf? | ||
tadzik | colomon: yeah, that too :) | 19:57 | |
19:57
daniel-s_ joined
|
|||
moritz | m: say PROCESS::.keys | 19:58 | |
camelia | rakudo-moar aff2a6: OUTPUT«$FATAL &cwd &chdir $IN $OUT $ERR $INITTIME $TZ @ARGS $ARGFILES %ENV $VM $PERL %CUSTOM_LIB @INC $CWD $OS $OSVER $PID $EXECUTABLE $EXECUTABLE_NAME $PROGRAM_NAME $TMPDIR $THREAD $SCHEDULER» | ||
moritz | nwc10: ^^ | ||
nwc10 | mmm, bother. that's just going to say "linux" | 19:59 | |
and "moarvm" | |||
I was rather hoping to show the architecture | |||
colomon | tadzik: library not found for -lrt? | 20:00 | |
nwc10 | OK. This will do: | 20:01 | |
$ ./perl6-m -e 'shell("uname -a")' | |||
Linux gcc1-power7.osuosl.org 3.8.8-202.fc18.ppc64p7 #1 SMP Thu Apr 18 14:11:12 MST 2013 ppc64 ppc64 ppc64 GNU/Linux | |||
running spectests | |||
tadzik | colomon: lrt? That doesn't ring a bell. What happens if you remove it? | 20:02 | |
colomon | it's librt, realtime stuff? | ||
tadzik | I don't recall using it :) | ||
ah | |||
it's probably from Linux makefile | 20:03 | ||
I should really fix Configure.pl :< | |||
colomon | looks like it builds with it removed. | ||
nwc10 | jnthn: patches for dancing bears coming soon. | ||
20:03
pecastro joined
|
|||
colomon | argh, Cannot locate native library './sdlwrapper.dylib' | 20:04 | |
because the makefile generates a .so instead | |||
btyler_ | colomon: look for "sdlwrapperlib.dylib" in that dir | 20:05 | |
rename it sdlwrapper.dylib --> success | |||
colomon | no such file | ||
nwc10 | logistics/location fail. There is no tonic here, and whilst at home the whisky isn't fantastic, it is a better choice than here | 20:06 | |
btyler_ | colomon: oh...did 'make' finish successfully? | 20:07 | |
jnthn | nwc10: Oh, I've got a nice big bottle of Yeti to drink here :) | ||
colomon | yes? | ||
or no? | 20:08 | ||
btyler_ | colomon: bizarre. osx 10.9.2 here on latest moar/nqp/rakudo, makefile spat out sdlwrapperlib.dylib, changing makefile or renaming (to ditch the 'lib' suffix) got lib/Steroids/SDL to find it | 20:09 | |
ls | |||
erg, ww | |||
20:09
clkaoud left,
pnu left,
flussence left,
_sri left
|
|||
colomon | I can see -o sdlwrapperlib.dylib in the Makefile | 20:10 | |
okay, I touched sdlwrapper.c and now I get the error load and clear. | |||
20:11
daniel-s__ joined
20:12
daniel-s_ left
|
|||
colomon | I had to add -lSDL2_ttf to the Makefile | 20:13 | |
Cannot locate native library './sdlwrapper.dylib' | 20:15 | ||
grrrr | |||
20:16
daniel-s__ left
20:18
zakharyas left
|
|||
tadzik | :o | 20:18 | |
I'll goan fix that Configure.pl | |||
20:19
pippo joined
20:21
ajr_ left
|
|||
colomon | it's right there, I cannot imagine why it cannot find it. | 20:22 | |
20:22
daniel-s__ joined
20:24
guru joined,
guru is now known as Guest87084,
rurban joined,
colomon left
20:25
hoverboard joined,
Guest87084 is now known as ajr_
20:26
_sri joined,
flussence joined,
clkaoud joined,
pnu joined
20:27
rindolf left
20:30
rurban left
20:32
btyler_ left
20:33
daniel-s__ left,
dotslashb joined
20:36
dwarring joined
|
|||
jnthn just did a patch to optimize out unused %_ using the var stuff in the optimizer | 20:38 | ||
nwc10 | faster dancing bears? | 20:39 | |
20:39
daniel-s__ joined
|
|||
jnthn | Saves the Hash allocation | 20:39 | |
And in theory the low level hash alloc and op to fetch it too | |||
Still need to check that spesh's unused detection spots that and kills it | |||
20:41
SevenWolf joined
20:43
Crazylemon64 left
20:44
daniel-s__ left
20:46
daniel-s__ joined
20:52
ajr_ left
20:53
Crazylemon64 joined
20:57
hoverboard left
|
|||
jnthn | hah, with adding some missing :pure it does :) | 21:01 | |
21:10
colomon joined
|
|||
FROGGS | jnthn: another percent faster? :o) | 21:19 | |
jnthn | Takes off some more of the GC pressure. | 21:20 | |
It's not actually a huge win, though... | |||
If the GC sucked more it'd be easier to get wins by reducing allocation... :P | |||
FROGGS | hehe | 21:21 | |
jnthn sees what the latest profile tells him | |||
darn, p6decontrv is costly... | 21:24 | ||
21:25
rurban joined
21:29
rurban left
|
|||
timotimo | aye, the low-level allocation is a pointer bump and a little thing | 21:31 | |
decont return value? | |||
jnthn | Yeah, but really it's "if it has an rw container take it away and put an ro one there instead" | ||
Meaning it allocates that ro container | 21:32 | ||
Which is actually down to flattening. | |||
I think I once only bothered to do it on non-Iterable things | 21:33 | ||
But then itemized Parcel got sad | |||
'cus Parcel ain't Iterable | |||
dalek | kudo/nom: b2b6b19 | jnthn++ | src/Perl6/ (2 files): Optimize out %_ when unused. |
21:36 | |
jnthn | I should probably try it again including Parcel in the check | 21:37 | |
Or even better | |||
Should do away with the C op entirely | |||
So that spesh can make the checks cheaper. | |||
timotimo | that sounds like a good idea | 21:44 | |
21:45
daniel-s__ left
|
|||
FROGGS | java.lang.ClassCastException: __P6opaque__72 cannot be cast to org.perl6.nqp.sixmodel.reprs.VMExceptionInstance | 21:46 | |
I am throwing from rakudo... do I need to decont there? | |||
jnthn | Uh..hm | 21:47 | |
I doubt it | |||
Where are you getting the thing you're trying to cast? | |||
FROGGS | well, I am creating it this way: my Mu $ex := nqp::newexception(); | ||
so no decont needed | |||
in a handler made by nqp::handle | 21:48 | ||
ahh, perhaps it is the payload / the label | |||
hmmm, that does not make much sense either | |||
jnthn | yeah...the payload will typically be a P6opaque | ||
FROGGS | but it is unlikely that I want to cast that to a VMEx | 21:49 | |
jnthn | Yeah | ||
21:50
daniel-s__ joined
21:54
rurban joined
21:56
xenoterracide__ joined
21:58
rurban left
22:05
rurban joined
|
|||
FROGGS | gnight all | 22:05 | |
22:06
xenoterracide__ left
22:09
rurban left,
SHODAN left
|
|||
jnthn | 'night, FROGGS++ | 22:10 | |
22:10
SHODAN joined
22:12
xenoterracide__ joined
|
|||
dalek | p/lexopts: 03349b2 | (Stéphane Payrard)++ | src/QRegex/Cursor.nqp: Fixing --target=parse on nqp Was working fine on rakudo |
22:17 | |
22:17
dalek left,
rurban joined
22:18
dalek joined,
ChanServ sets mode: +v dalek
|
|||
masak | m: (1, 2, 3).permutations | 22:20 | |
camelia | ( no output ) | ||
masak | m: say (1, 2, 3).permutations.perl | ||
camelia | rakudo-moar aff2a6: OUTPUT«([1, 2, 3], [1, 3, 2], [2, 1, 3], [2, 3, 1], [3, 1, 2], [3, 2, 1]).list» | ||
22:21
rurban left
22:28
spider-mario left
22:31
daniel-s__ left
22:32
daniel-s__ joined
22:38
denis_boyun_ left
|
|||
dalek | kudo/nom: ccddd17 | jnthn++ | src/vm/moar/ops/perl6_ops.c: Avoid unrequired container allocs in p6decontrv. |
22:41 | |
masak | 'night, #perl6 | 22:43 | |
lizmat | well, that was close :-) | 22:52 | |
22:52
anaeem1 left
|
|||
jnthn didn't watch it, but heard Austria won and Poland resorted to striptease... | 22:55 | ||
22:56
hoverboard joined
22:57
xenoterracide__ is now known as xenoterracide
|
|||
lizmat | yes, Poland was, what shall I say, blond airheads? | 22:58 | |
jnthn: I just pulled and ran a spectest | 22:59 | ||
so far, no immediately gains to be seen | |||
one failure, and 2 todo's passing | |||
jnthn | Yeah, you probably need something a bit longer running than spectests for that. | ||
lizmat | not ok 6 - :(:a($x), :b($y)) ~~ :(:a(:b(:c($x)))) | 23:00 | |
in S03-smartmatch/signature-signature.t | |||
jnthn | hmm | 23:01 | |
I didn't see that fail here... | |||
(As in, just re-checked my last spectest output with latest matches and that file passed) | |||
lizmat | going back 1 commit, see the result then | ||
seems to be the %_ commit | 23:04 | ||
double checking | |||
yup, reverting to aff2a6618ee3d746a4d4f5bdfa91854f54f0f91d makes the pb go away | 23:06 | ||
jnthn | *sigh* | ||
I really don't fancy losing that opt. | 23:07 | ||
lizmat | well, maybe the test is bogus (it feels pretty weird to me, anyway) | ||
jnthn wonders how on earth it realtes to that test | |||
No matter how many times I run it here, I can't get it to fail | 23:08 | ||
lizmat | odd | 23:11 | |
well, I guess we have to wait for a roast from [Coke] then | |||
jnthn | *nod* | ||
lizmat | m: say :(:a($x), :b($y)) ~~ :(:a(:b(:c($x)))) | ||
camelia | rakudo-moar b2b6b1: OUTPUT«True» | ||
jnthn | I'm also running with spesh_trace, but that's not meant to make behavior differences... | ||
lizmat | $ perl6 -e 'say :(:a($x), :b($y)) ~~ :(:a(:b(:c($x))))' | ||
False | |||
jnthn | uh | 23:12 | |
I get it to say False too | |||
But the tests passes?! | |||
lizmat | hmmm.. it is supposed to be False , I see now in the test | 23:13 | |
jnthn | oh... | ||
uh, so why does evalbot get it here as true... | |||
m: say :(:a($x), :b($y)) ~~ :(:a(:b(:c($x)))) | |||
camelia | rakudo-moar b2b6b1: OUTPUT«True» | ||
jnthn | m: say :(:a($x), :b($y)) ~~ :(:a(:b(:c($x)))) for ^20 | ||
camelia | rakudo-moar b2b6b1: OUTPUT«FalseFalseFalseFalseFalseFalseFalseFalseFalseFalseFalseFalseTrueFalseFalseFalseFalseFalseFalseFalse» | ||
jnthn | o.O | ||
lizmat | seems like an artefact in the test | 23:15 | |
if I make it the *only* test in the list, it passes | |||
ok 1 - :(:a($x), :b($y)) ~~ :(:a(:b(:c($x)))) | 23:16 | ||
jnthn | OK. I think that given we're getting unstable behavior from it here on channel too, we might conclude it's not that particular patch... | ||
23:18
rurban joined
|
|||
lizmat | If I leave in the last 4 tests, it fails | 23:19 | |
there *is* one test in there for *%_ | |||
:(:$x, Int :$y, Cool :$z, *%_), :(*%_), False, | 23:20 | ||
m: say :(*%_) ~~ :(:x($x), Int :y($y), Cool :z($z), *%_) | |||
camelia | rakudo-moar b2b6b1: OUTPUT«False» | ||
23:21
Rotwang left
|
|||
lizmat | gist.github.com/lizmat/f8f7377b36849a473013 | 23:21 | |
is the diff of the test file that is needed to make it fail | 23:22 | ||
23:22
rurban left
|
|||
lizmat | taking out the line with ":(:$x, Int :$y, Cool :$z, *%_), :(*%_)," makes it pass again | 23:23 | |
so it seems to be related to :(*%_) | |||
jnthn | I'm unconvinced. | ||
The patch you reverted was the one about p6decontrv, not *%_? | 23:24 | ||
Also, the nature of the *%_ thing I did wouldn't give unstable behavior, more likely explosive behavior 'cus it'd removed something. | |||
lizmat | I first reverted ccddd17f8538343247623fd076882ca3643c0995 and the pb was still there | ||
I then reverted b2b6b19ac74509ff30aee7ef74a1ca142bfe5a81 and the problem went away | 23:25 | ||
jnthn | Hmm | ||
But then, why do I not see the issue here... | 23:26 | ||
lizmat | all the tests around the *%_ test are supposed to be False | ||
so if they are false for the *wrong* reason, we wouldn't see it | |||
I just noticed another test with *%_ | 23:27 | ||
if I activate that one, and disable the other one, it also fails the test | |||
jnthn | Weird | 23:28 | |
lizmat | hmmm.... other combinations also fail | ||
seems I'm too tired for this now | |||
jnthn | Yeah. Thing is, I think I've seen that test fail randomly in the past too... | ||
*nod* | |||
We had one other sparodic failure in first.t for a while under spesh | |||
During the last days work I've fixed the odd thing that could potentially have caused metastable behavior. I'm running on spesh_trace here, which has those fixes. So maybe it's something around that... | 23:29 | ||
Hard to know. | |||
23:29
dmol left
|
|||
lizmat | ok, let's wait for those changes to merge and see what gives afterwards, ok? | 23:29 | |
jnthn | Works for me | 23:30 | |
We've got a spesh slot corruption issue to resolve before it can merge, it seems. | |||
lizmat | for me as well... :-) so gnight jnthn and #perl6! | ||
jnthn | 'night, lizmat | ||
23:31
BenGoldberg joined
23:48
xenoterracide left
23:51
berekuk left
23:59
xragnar is now known as Guest66156,
xragnar_ joined,
Guest66156 left,
xragnar_ is now known as xragnar
|