Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6-dev, 2016-05-26

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

All times shown according to UTC.

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

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