dalek | ast: 9c57b43 | lizmat++ | S32-num/rat.t: Fix now passing tests |
09:56 | |
lizmat | (finally *something* on the perl6-dev channel today) | 09:57 | |
hmmm... RT #126391 | 09:58 | ||
m: say 42/(.1+.2-.3) # TimToady : how do you feel about this not throwing an exception anymore ? | 10:01 | ||
camelia | rakudo-moar a5c46b: OUTPUT«Inf» | ||
dalek | kudo/nom: 7afeb68 | lizmat++ | src/core/Rational.pm: Simplify Rational.new Part of a cunning plan to handle Inf.Rat better |
10:57 | |
ilmari | lizmat: re. (±Inf|NaN).Rat, would it make sense to normalise the numerator to ±1|0? | 11:10 | |
lizmat | ilmari: that's what it basically does now | ||
which makes us lose 42/0 | |||
ilmari | but is that meaningfully different from 1/0? | 11:11 | |
both the old and the new code in Rationa.new preserve the numerator when the denominator is zero, afaict | 11:12 | ||
lizmat | ilmari: that last change was only to make the next changes possible :-) | ||
spectesting that now | |||
ilmari waits and sees | |||
lizmat | m: say Rational[Num,Int].new(Inf,0) | ||
camelia | rakudo-moar 7afeb6: OUTPUT«Inf» | ||
lizmat | it was to allow that | 11:13 | |
grrr.... we don't have a way to stub a role, do we? | 11:14 | ||
ilmari | m: say Rational[Int,Int].new(42, 0) | ||
camelia | rakudo-moar 7afeb6: OUTPUT«Inf» | ||
ilmari | m: say Rational[Int,Int].new(42, 0) eqv Rational[Int,Int].new(1,0) | 11:15 | |
camelia | rakudo-moar 7afeb6: OUTPUT«True» | ||
jnthn | m: role Foo { ... }; role Foo { } | ||
camelia | ( no output ) | ||
jnthn | Seems OK | ||
Note that you must define it before you compose it into anything | |||
But you can refer to it beforehand as a constraint etc. | 11:16 | ||
lizmat | ok | 11:20 | |
dalek | kudo/nom: 498d0a4 | lizmat++ | src/core/ (2 files): Better solution to Inf/-Inf/NaN.Rat This basically creates a special purpose Rat in which the numerator is a Num rather than an Int. This preserves the normal Failure behaviour of dividing by zero, while keeping the isnanorinf information when coercing to a Rat. |
12:00 | |
lizmat | this makes the spectest clean again | 12:01 | |
travis-ci | Rakudo build failed. Elizabeth Mattijsen 'Simplify Rational.new | 12:04 | |
travis-ci.org/rakudo/rakudo/builds/133079966 github.com/rakudo/rakudo/compare/a...feb68bee12 | |||
lizmat | one could argue that the special Rat should maybe have a denominator of 1 | ||
m: say 42/(.1+.2-.3) | 12:10 | ||
camelia | rakudo-moar 7afeb6: OUTPUT«Inf» | ||
lizmat | (not yet 498d0a4) | ||
(not yet 498d0a4) | 12:42 | ||
m: say 42/(.1+.2-.3) | |||
camelia | rakudo-moar 498d0a: OUTPUT«Attempt to divide 42 by zero using div in block <unit> at /tmp/7Xg5wtvMhZ line 1Actually thrown at: in block <unit> at /tmp/7Xg5wtvMhZ line 1» | ||
travis-ci | Rakudo build failed. Elizabeth Mattijsen 'Better solution to Inf/-Inf/NaN.Rat | 13:06 | |
travis-ci.org/rakudo/rakudo/builds/133091879 github.com/rakudo/rakudo/compare/7...8d0a4ae457 | |||
tomboy64 | oh joy | 13:22 | |
Files built without respecting CFLAGS have been detected: /usr/share/perl6/runtime/dynext/libperl6_ops_moar.so | 13:23 | ||
:D | |||
psch | aha, nqp commit d751661 never was tested against rakudo, it seems | 13:54 | |
that's the NoSuchFileException i mentioned yesterday | |||
'cause before we had IO::Path.dir check whether it's moar or jvm and react accordingly | 13:55 | ||
but since that path changed nqp-j return only a filename instead of the absolute path it returned previously... | |||
hopefully it's as easy as tossing the preprocessor directives from IO::Path... | 13:59 | ||
otherwise i'd rather revert that commit, unless someone else wants to figure out what IO::Path has to do instead with it | |||
nope, tossing the #?if jvm bits and only running the moar path doesn't work | 14:11 | ||
apparently nqp-j doesn't support chdir, and never really can support it platform independently | |||
i suppose someone could try porting the nqp-j behavior to moar, so we can use only the #?if jvm path... | 14:12 | ||
but until that i'll revert the PR that broke it | |||
contingent on "it doesn't get worse", of course :) | |||
dalek | p: 8e10572 | peschwa++ | src/vm/jvm/runtime/org/perl6/nqp/runtime/Ops.java: Revert "Merge pull request #287 from MasterDuke17/master" This reverts commit 62d0dbad096e9969b2fd082e6b2d020b1daba617, reversing changes made to ca37f08f9a9f633c72e967e6a0a6b9308788db6b. Rakudo's IO::Path relies on absolute paths returned from nextfiledir, and since we cannot emulate the solution moar uses in IO::Path (because Java does not support changing the CWD, at least not without platform-dependent hacks) we will have to accept this inconsistency until someone rewrites IO::Path. This reverts the failure mode for install-core-dist.pl on Rakudo-j back to "setcodeobj can only be used with a CodeRef", from leaking a Java-level NoSuchFileException. |
14:42 | |
psch | now if i just had a clue how to fix the setcodeobj failure mode :| | 14:43 | |
lizmat | psch++ # sorry for the confusion | 14:49 | |
psch | lizmat: no worries. i had strongly hoped we could just toss the #?if jvm part of IO::Path, but alas... :) | 14:53 | |
dalek | kudo/nom: 1ab1fb6 | lizmat++ | src/core/Rational.pm: Remove now unnecessary test, Brad Gilbert++ |
15:00 | |
lizmat wonders where the code for nqp::p6for lives | 15:31 | ||
psch | lizmat: in Perl6::Grammar iirc | 15:33 | |
lizmat: ah, no, Actions :) | |||
line 391 on HEAD | 15:34 | ||
lizmat | psch++ | 15:35 | |
dalek | p: c3122aa | (Pawel Murias)++ | src/vm/js/ (3 files): [js] Instead of writing Chunk parts to a file and slurping, collect them into an array and then nqp::join them together. |
15:58 | |
kudo/js: bf34614 | (Pawel Murias)++ | src/vm/js/perl6-runtime/runtime.js: [js] Add the js runtime for the p6* ops. |
16:25 | ||
kudo/js: 79abb4e | (Pawel Murias)++ | src/vm/js/Perl6/Ops.nqp: [js] Fix bug. |
|||
kudo/js: bccb2c8 | (Pawel Murias)++ | src/vm/js/ (2 files): [js] Stub ops. |
|||
kudo/js: 1ef5a97 | (Pawel Murias)++ | src/Perl6/Metamodel/BOOTSTRAP.nqp: [js] Enable the signature binder on the js backend. |
|||
rakudo/js: 0ec08b6 | (Pawel Murias)++ | src/Perl6/ (2 files): | |||
rakudo/js: [js] some temporary #if's to work around some misssing nqp-js features. | |||
lizmat | decommute& | 17:14 | |
brrt for one would love to get rid of dynamic extension ops | 18:46 | ||
psch | brrt: what's that? | 18:47 | |
brrt | it's basically a set of, or address space for, extension opcodes for MoarVM | ||
stuff like perl6_invoke, perl6_return, perl6_getthis, perl6_stuffthat | |||
psch | huh | 18:48 | |
i assume that's motivated by your JIT work? | |||
brrt | imho, and i'm probably wrong in some important way, it defeats the purpose of having a VM purpose-made for the compiler | ||
and yes, they are - slightly - annoying on the JIT level | 18:49 | ||
specifically because they assume to be running in an interpreter | |||
tadzik | . o O ( perhaps rakudo should fork moarvm :P ) | ||
brrt | which is a wider problem | ||
there is probably a good reason that i just don't know | |||
:-) | |||
psch | i don't think i have a sufficient grasp on the connotations :) | 18:50 | |
brrt | that is not unreasonable :-) | 18:51 | |
basically, the JIT just wants to run code and get on with it | |||
the interpreter, in contrast, looks at a stream of data at each point to decide what to do | |||
we call this stream of data the 'bytecode', although a moarvm opcode is 16 bits wide | |||
when you're running inside an interpreter, you can quite explicitly move about in the program simply by updating pointers | 18:53 | ||
moreover, you can tell where you are simply by comparing pointers | 18:54 | ||
now in comparison, JIT compiled code is /operated on/ by the CPU, and while the CPU has a register that tells you where it is, there is a): no way to explicitly read it, b): no way to update it directly | 18:55 | ||
so all the fancy manipulations of your current position and bounds checks etc.... they are impossible, or at the very least, considerably more tricky | 18:56 | ||
psch | yeah, that sounds quite beyond my understanding... :) | ||
brrt | hmm, that means i didn't explain it well :-) | ||
oh well | |||
it is all very possible to deal with these things. it's just not a fun thing to do | 18:57 | ||
jnthn | .tell brrt I'm not that keen on them either, fwiw. If they go away we get to remove the code supporting them from MoarVM too. Alternative is we have API for JITting them. | 19:30 | |
skids | Those would be needed if a 3rd party (like a rakudo module) wanted to add support for a low-level data type, right? | 20:21 | |
jnthn | skids: That'd more be custom REPRs, which we don't do at all yet | 20:24 | |
[Coke] | jnthn: I'm all for not having moarvm support custom opcodes. | 20:29 | |
the only goal is to support rakudo, no? | |||
ugexe | m: sub foo(--> Array|Str) { }; | 20:49 | |
camelia | rakudo-moar 1ab1fb: OUTPUT«===SORRY!=== Error while compiling /tmp/WDh4DWFasWType 'Array' is not declared. Did you mean 'array'?at /tmp/WDh4DWFasW:1------> sub foo(--> Array⏏|Str) { };» | ||
jnthn | [Coke]: Pretty much | 20:55 | |
Think that's a confused error :) | |||
Heuristics don't always go so well... :) | 20:56 | ||
brrt | jnhtn: you mean like, insert expr fragments for extension ops? we could do that, but it is not very high on the priority list | 21:02 | |
oh well, too tired today :-) | 21:08 | ||
AlexDaniel | ugexe: rt.perl.org/Ticket/Display.html?id=125902 | 21:17 | |
m: my Int; | 21:18 | ||
camelia | rakudo-moar 1ab1fb: OUTPUT«===SORRY!=== Error while compiling /tmp/bbnrsiWAAYMalformed myat /tmp/bbnrsiWAAY:1------> my Int⏏;» | ||
AlexDaniel | hmmm, the error message is different now | ||
ah, it is mentioned in the ticket | |||
bisect: use Test; exit 1 if throws-like { EVAL ‘my Str where 'foo' $test’ }, X::Syntax::Malformed | 21:30 | ||
bisectable | AlexDaniel: (2015-12-25) github.com/rakudo/rakudo/commit/07fecb5 | ||
AlexDaniel | bisect: use Test; exit 1 if throws-like { EVAL ‘my Str where 'foo' $test’ }, X::Syntax::Malformed; exit 0 | 21:31 | |
bisectable | AlexDaniel: (2015-12-25) github.com/rakudo/rakudo/commit/07fecb5 | ||
AlexDaniel | meh | 21:32 | |
ah right, the change was before 2015.12 | 21:34 | ||
tomboy64 | how far along is the node.js backend? | 21:40 | |
psch | tomboy64: blogs.perl.org/users/pawel_murias/ is the latest status report | 21:47 | |
tomboy64: there's been a few more nqp-js commits since then, but i gather if anything notable happened pmurias++ would have blogged again | 21:48 | ||
tomboy64: note though that it's not so much intended as a node.js backend, but as a javascript backend - note.js is currently just the easiest way to try and make it run | 21:49 | ||
tomboy64 | :) i see | ||
so "experimental pre-alpha" describes it best, huh? | |||
psch | fwiw i'm somewhat curious how the performance difference between e.g. asm.js rakudo-moar and native rakudo-js in a browser turns out | 21:50 | |
...i think that's a bit loaded. i'd call it "in development" :) | |||
tomboy64 | :p | ||
hmmm. in a browser? | 21:51 | ||
be careful what you wish for :p | |||
psch | nah :P | ||
imagine rakudo.js with similar perseverance as jquery.js \o/ | |||
the world would be a better place :P | |||
tomboy64 | :D | 21:52 | |
tomboy64 bites his tongue | |||
psch | yeah, i know | ||
the better solution would of course be convince the w3c that every browser needs a perl6 compat scripting engine :P | |||
+to | 21:53 | ||
tomboy64 | HAH | ||
psch | in all seriousness, i don't know what would be the best mandated HLL for browsers | 21:54 | |
i do know that ECMAScript is weird as hell | |||
tomboy64 | well, ECMAScript was an attempt to standardize browser-js | ||
psch | and tacking lots of expressive features onto it doesn't help the fundamental weirds that are around | ||
yeah, but that's the thing | 21:55 | ||
tomboy64 | the problem is that js in itself is aimed at hobby-devs | ||
psch | there's something around that's weird and broken | ||
and then the commitee comes and says "we need these extra features to make it good" | |||
tomboy64 | with all kinds of stuff that's supposed to make "programming" easier - but instead makes the whole shebang more complicated to get it right | 21:56 | |
and introduces all kinds of errors | |||
psch | exactly, because of a wonky foundation | ||
i mean, sure, Perl 6 has its share of WATs as well | |||
tomboy64 | dash was a good concept - that never took off | ||
psch | but they're almost exclusively hidden in obscure features | ||
and the ones that aren't - like binding vs assignment - are easy to explain | |||
...although i suppose binding could be argued to be an obscure feature already vOv | 21:57 | ||
tomboy64 | WAT? | ||
psch | yes, after gary bernhardts talk | ||
www.destroyallsoftware.com/talks/wat | |||
it's a good talk | |||
not even 5 minutes :) | 21:58 | ||
well, unless "binding is an obscure feature" was a WAT to you :) | 22:02 | ||
AlexDaniel | well, there are also some hopes for WebAssembly | 22:05 | |
tomboy64 | and extraordinarily entertaining | 22:07 | |
really enjoyed that, thank you | |||
psch | there's a few more free talks by him, they're all good | 22:08 | |
not quite as humorous as the WAT talk, but still good | |||
lizmat | m: my @a = ^5; @a[2]:delete; $_++ for @a; dd @a # continuing from this afternoon, will look at this tomorrow | 22:20 | |
camelia | rakudo-moar 1ab1fb: OUTPUT«Cannot call postfix:<++>(Any); none of these signatures match: (Mu:D $a is rw) (Mu:U $a is rw) (Int:D $a is rw) (int $a is rw) (Bool:U $a is rw) (Bool:D $a is rw) (Num:D $a is rw) (Num:U $a is rw) (num …» | ||
lizmat | good night, #perl6-dev | 22:24 | |
psch | m: say ++Any | ||
camelia | rakudo-moar 1ab1fb: OUTPUT«Cannot call prefix:<++>(Any); none of these signatures match: (Mu:D $a is rw) (Mu:U $a is rw) (Int:D $a is rw) (int $a is rw) (Bool $a is rw) (Num:D $a is rw) (Num:U $a is rw) (num $a is rw) in block <uni…» |