Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2015-04-18

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:00 lizmat joined #perl6
00:17 flussence alright, I tried replacing the big string concatenation in HLL/Backend.nqp, only to find it hits swap death *before* even reaching that part. Not sure what's going on yet...
00:24 anaeem1_ joined #perl6
00:26 nbdsp_ Submitted an issue report to Install::Perl5 git.
00:26 nbdsp_ *Inline::Perl5 git.
00:30 aborazmeh joined #perl6
00:30 aborazmeh joined #perl6
00:36 pippo joined #perl6
00:36 pippo m: grammar G {rule TOP {<:alpha>}}; G.parse("a");
00:36 camelia rakudo-moar a24488: ( no output )
00:37 pippo m: grammar G {rule TOP {<:alpha>}}; say ~ G.parse("a");
00:37 camelia rakudo-moar a24488: OUTPUT«a␤»
00:37 pippo j: grammar G {rule TOP {<:alpha>}}; say ~ G.parse("a");
00:37 camelia rakudo-jvm a24488: OUTPUT«cannot connect to eval server: Connection refused␤»
00:38 pippo my rakudo-j fails here ^^
00:38 pippo java.util.regex.PatternSyntaxException: Unknown character property name {alpha} near index 8
00:38 pippo \p{alpha} ^
00:38 pippo left #perl6
01:03 isBEKaml j: grammar G { rule TOP { [:alpha:] } }; say ~ G.parse("a");
01:03 camelia rakudo-jvm a24488: OUTPUT«cannot connect to eval server: Connection refused␤»
01:11 raiph joined #perl6
01:23 vendethiel joined #perl6
01:36 Su-Shee_ joined #perl6
02:08 noganex_ joined #perl6
02:14 tinyblak joined #perl6
03:00 labster m: supersede Cool {}
03:00 camelia rakudo-moar a24488: OUTPUT«5===SORRY!5===␤Type 'Cool' is not declared. Did you mean 'Bool'?␤at /tmp/8fQODkoU6J:1␤------> 3supersede Cool 7⏏5{}␤Malformed supersede␤at /tmp/8fQODkoU6J:1␤------> 3supersede Cool 7⏏5{}␤␤»
03:01 labster m: supersede Bool {}
03:01 camelia rakudo-moar a24488: OUTPUT«5===SORRY!5===␤Type 'Bool' is not declared. Did you mean 'Cool'?␤at /tmp/YQMsgXm0Lq:1␤------> 3supersede Bool 7⏏5{}␤Malformed supersede␤at /tmp/YQMsgXm0Lq:1␤------> 3supersede Bool 7⏏5{}␤␤»
03:02 labster can't win :/
03:03 labster also LTA error message
03:06 labster m: supersede class Cool { }
03:06 camelia rakudo-moar a24488: OUTPUT«5===SORRY!5=== Error while compiling /tmp/1FsdHYnu_S␤Cannot use 'supersede' with class declaration␤at /tmp/1FsdHYnu_S:1␤------> 3supersede class Cool7⏏5 { }␤    expecting any of:␤        generic role␤»
03:20 vendethiel joined #perl6
03:26 BenGoldberg joined #perl6
03:26 flussence .tell timotimo I've got --profile-compile working, by replacing all the array concatenation with nqp::printfh. And then I ctrl+c'ed it an hour later, because it's written a gigabyte of JSON and shows no sign of stopping.
03:26 yoleaux flussence: I'll pass your message to timotimo.
03:26 aborazmeh joined #perl6
03:26 aborazmeh joined #perl6
03:27 skids m: for (while 0 { }) { });
03:27 camelia rakudo-moar a24488: OUTPUT«5===SORRY!5===␤Word 'while' interpreted as a listop; please use 'do while' to introduce the statement control word␤at /tmp/zqnyfKdIGh:1␤------> 3for (while7⏏5 0 { }) { });␤Unexpected block in infix position (two terms in a row)␤at /tmp/…»
03:27 skids oops
03:28 skids m: for (while 0 { }) { };
03:28 camelia rakudo-moar a24488: OUTPUT«5===SORRY!5===␤Word 'while' interpreted as a listop; please use 'do while' to introduce the statement control word␤at /tmp/azTCdDLNYo:1␤------> 3for (while7⏏5 0 { }) { };␤Unexpected block in infix position (two terms in a row)␤at /tmp/a…»
03:28 skids std: for (while 0 { }) { };
03:28 camelia std 28329a7: OUTPUT«5===SORRY!5===␤Word 'while' interpreted as a listop; please use 'do while' to introduce the statement control word at /tmp/vnzbhx_Jwu line 1:␤------> 3for (7⏏5while 0 { }) { };␤Unexpected block in infix position (two terms in a row) at /tmp/vnzbhx…»
03:37 dalek specs: 20fd946 | skids++ | S04-control.pod:
03:37 dalek specs: Clarify comment in example.
03:37 dalek specs: Many people will take "useless" to mean redundant, rather than impotent.
03:37 dalek specs: review: https://github.com/perl6/specs/commit/20fd946a18
03:37 dayangkun joined #perl6
03:40 TimToady joined #perl6
03:54 lolisa joined #perl6
03:57 anaeem1 joined #perl6
04:07 kaare_ joined #perl6
04:24 vendethiel joined #perl6
04:34 mr-foobar joined #perl6
04:49 aborazmeh joined #perl6
04:49 aborazmeh joined #perl6
05:37 lizmat joined #perl6
05:45 Psyche^ joined #perl6
06:02 telex joined #perl6
06:21 vendethiel joined #perl6
06:28 konsolebox joined #perl6
06:43 yvan1 joined #perl6
06:51 timotimo flussence: hot damn, a gigabyte?
06:51 yoleaux 03:26Z <flussence> timotimo: I've got --profile-compile working, by replacing all the array concatenation with nqp::printfh. And then I ctrl+c'ed it an hour later, because it's written a gigabyte of JSON and shows no sign of stopping.
06:54 timotimo that's a bit more than i expected
07:05 [TuxCM] joined #perl6
07:06 RabidGravy joined #perl6
07:13 Ulti joined #perl6
07:13 alini joined #perl6
07:17 timotimo i've let the profile write-out run over night and it has only gathered up an hour of cpu time
07:17 timotimo flussence: did you turn --optimize=off for your profile run, ooc?
07:18 lizmat joined #perl6
07:19 petercommand joined #perl6
07:20 petercommand joined #perl6
07:23 timotimo .tell flussence --optimize=off would cut out a gigantic part of the call tree, most likely, as the optimizer goes through almost the whole QAST tree that's generated for the core setting and will reflect the structure of the QAST tree almost 1:1 in its call stacks ... except it'll have an additional "walk_children" (OSLT) frame in between layers of nodes
07:23 yoleaux timotimo: I'll pass your message to flussence.
07:28 timotimo i wonder where exactly these mmaps/munmaps come from
07:28 timotimo perhaps that's what malloc does for very, very big requests?
07:30 timotimo on my system the chunks that are being mmapped and munmapped are more like ¾ gigabytes big
07:33 timotimo yeah, i found evidence on the 'net that malloc will fall back to mmap for very big chunks of data. in this case, i expect that this comes from string memory handling
07:35 minde joined #perl6
07:36 timotimo and the long time between the mmaps and the following brk and munmap calls is quite likely the garbage collector running through a major collection which has to go through the entire gen 2 in order to work
07:37 timotimo on the other hand, if a gigantic chunk of the data is actually string data, that wouldn't have to be touched by the gen 2 traversal
07:37 timotimo very curious
07:37 timotimo but i'm not going to attach gdb and run the heap analyzer for moarvm on it, that thing is already slow enough for just a hundred megs of ram usage %)
07:37 minde left #perl6
07:40 Celelibi joined #perl6
07:42 rindolf joined #perl6
07:51 tadzik [Tux]: what was that panda error you got? With X::Panda
07:51 yoleaux 17 Apr 2015 19:56Z <[TuxCM]> tadzik: https://gist.github.com/Tux/eb7cdda3079bcec5f8e7
07:51 tadzik hah
07:51 FROGGS joined #perl6
07:53 Rounin joined #perl6
07:54 spider-mario joined #perl6
07:54 leont joined #perl6
07:57 gfldex joined #perl6
08:02 tinyblak_ joined #perl6
08:04 tadzik [Tux]: is that only jvm?
08:08 timotimo spam spam spam bacon eggs and spam :)
08:09 tadzik bacon lays eggs?!
08:09 tadzik :o
08:09 timotimo http://www.pbfcomics.com/117/
08:10 tadzik :D
08:12 darutoko joined #perl6
08:13 [TuxCM] joined #perl6
08:13 [TuxCM] o/
08:14 timotimo oh ... my lord ...
08:15 timotimo i can just lines() and ctrl-d
08:17 timotimo however, my @input = { get } ...^ ""  also has a certain ring to it
08:17 timotimo m: my @sizes = 100, 110, 120, 130; @sizes >>-=>> @sizes[0]; say @sizes
08:17 camelia rakudo-moar a24488: OUTPUT«0 110 120 130␤»
08:17 timotimo i wonder why this doesn't work as i expect?
08:17 timotimo m: my @sizes = 100, 110, 120, 130; @sizes = @sizes >>->> @sizes[0]; say @sizes
08:17 camelia rakudo-moar a24488: OUTPUT«0 10 20 30␤»
08:17 timotimo this does, however
08:27 petercommand joined #perl6
08:27 petercommand joined #perl6
08:33 lizmat .tell FROGGS the MoarVM fix for pipes did not affect flapping of Proc::Async tests
08:33 yoleaux lizmat: I'll pass your message to FROGGS.
08:37 dalek faq: 12623be | timotimo++ | answers.md:
08:37 dalek faq: turn a Type() into (Type)
08:37 dalek faq: review: https://github.com/perl6/faq/commit/12623bea7a
08:41 leont nine: how about this approach http://stackoverflow.com/questions/29563​832/why-dont-i-get-any-syntax-errors-whe​n-i-execute-my-python-script-with-perl, given an executable called rakudo instead of perl6
08:41 timotimo star-m: my @sizes = 100, 110, 120, 130; @sizes >>-=>> @sizes[0]; say @sizes
08:41 camelia star-m 2015.03: OUTPUT«0 110 120 130␤»
08:51 Ugator joined #perl6
08:51 Ugator left #perl6
08:57 sqirrel joined #perl6
09:00 nine leont: doesn't work right now either, because the word "perl" is contained in "perl6", so perl still tries to execute the script.
09:01 vendethiel joined #perl6
09:01 FROGGS joined #perl6
09:02 FROGGS :o(
09:02 yoleaux 08:33Z <lizmat> FROGGS: the MoarVM fix for pipes did not affect flapping of Proc::Async tests
09:02 FROGGS but yeah, that would have been too good to be true
09:02 leont that's why I suggested calling the executable rakudo ;-)
09:03 timotimo "the" executable is a shell script launcher right now anyway, so why not just cp it to two names?
09:03 timotimo just a thought
09:03 * timotimo is AFK now
09:03 timotimo someone feel free to rakudobug my problem from a few lines above?
09:09 leont Also, making perl5 threat perl6 special in the hashbang would not be unreasonable at all IMO
09:11 masak +1
09:11 espadrine joined #perl6
09:12 RabidGravy Okayeeeeee, "Stage parse      :  55.559" (with optimise=3)  It's going down every day :-D
09:12 masak RabidGravy: that's because the universe is expanding and time itself is slowing down. :P
09:13 RabidGravy :)
09:18 anaeem1_ joined #perl6
09:18 timotimo actually, now i have an opportunity to rakudobug it myself
09:18 * masak .oO( automatically flipping the bozo bit on any sentence talking about the speed of "time itself", as a service )
09:18 timotimo RabidGravy: has that always been that bad?
09:19 bartolin_ m: sub pascal { [1], { [0, @^p Z+ @^p, 0] } ... * }; .say for pascal[^10];
09:19 camelia rakudo-moar a24488: OUTPUT«1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤»
09:20 bartolin_ star-m: sub pascal { [1], { [0, @^p Z+ @^p, 0] } ... * }; .say for pascal[^10];
09:20 camelia star-m 2015.03: OUTPUT«1␤1 1␤1 2 1␤1 3 3 1␤1 4 6 4 1␤1 5 10 10 5 1␤1 6 15 20 15 6 1␤1 7 21 35 35 21 7 1␤1 8 28 56 70 56 28 8 1␤1 9 36 84 126 126 84 36 9 1␤»
09:20 nine leont: I clearly want both :) Fixing the mishandling of perl6 in the shebang line and support for use v6; Because the latter really has no disadvantages
09:20 RabidGravy timotimo, that's about half of the absolute worst it's been in the last couple of weeks
09:21 bartolin_ ^^ that's from http://rosettacode.org/wiki​/Pascal%27s_triangle#Perl_6 (and integration/advent2012-day04.t)
09:22 bartolin_ I remember breaking it a month ago (by improperly flattening values within SEQUENCE). but it was fixed afterwards.
09:22 bartolin_ seems to fail since 2015-04-10
09:23 timotimo RabidGravy: wow, i'm sorry about your weak computer ;)
09:25 RabidGravy I think I mash it up a bit too much "model name: Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz"
09:26 RabidGravy mind five years old now
09:27 dalek rakudo/nom: 52b2792 | lizmat++ | src/core/Array.pm:
09:27 dalek rakudo/nom: Make Array.elems an lvalue
09:27 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/52b27924fa
09:27 timotimo right
09:32 [TuxCM] any volunteer to browse what I have so far for perl6 sane-ness? https://github.com/Tux/CSV​/blob/master/Text-CSV.pod (stop at the ################### line)
09:32 masak m: say NaN == NaN; say NaN === NaN
09:32 camelia rakudo-moar a24488: OUTPUT«False␤True␤»
09:32 masak does anyone know of any other language that makes the above distinction? (I think it's great, btw.)
09:32 timotimo m: my @sizes = 100, 110, 120, 130; @sizes = @sizes >>-<< (@sizes[0] xx 4); say @sizes
09:32 camelia rakudo-moar a24488: OUTPUT«0 10 20 30␤»
09:32 timotimo m: my @sizes = 100, 110, 120, 130; @sizes = @sizes >>-=>> (@sizes[0] xx 4); say @sizes
09:32 camelia rakudo-moar a24488: OUTPUT«0 10 20 30␤»
09:34 timotimo oops
09:34 timotimo m: my @sizes = 100, 110, 120, 130; @sizes >>->> @sizes[0]; say @sizes
09:34 camelia rakudo-moar a24488: OUTPUT«100 110 120 130␤»
09:34 timotimo m: my @sizes = 100, 110, 120, 130; @sizes >>-=>> @sizes[0]; say @sizes
09:34 camelia rakudo-moar a24488: OUTPUT«0 110 120 130␤»
09:35 tadzik [TuxCM]: https://gist.github.com/ta​dzik/966a56e13c4318269302 ¯\_(ツ)_/¯
09:35 timotimo m: my @sizes = 100, 110, 120, 130; @sizes >>-=>> (@sizes[0] xx 4); say @sizes
09:35 camelia rakudo-moar a24488: OUTPUT«0 10 20 30␤»
09:40 timotimo since rakudo on moarvm tends to use much ram, maybe it'd be a good idea to detect the situation when moar has parts of its heap swapped out and do some extra work to make the gc run more swap-friendly
09:40 timotimo like sorting the worklists by address, roughtly?
09:40 dalek roast: c66a66c | usev6++ | integration/advent2012-day04.t:
09:40 dalek roast: Fudge test ('skip') for RT #124330
09:40 dalek roast: review: https://github.com/perl6/roast/commit/c66a66cdbf
09:40 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124330
09:44 eli-se joined #perl6
10:02 anaeem1 joined #perl6
10:07 anaeem1 joined #perl6
10:25 tadzik a look at the current state of qt profiler: http://imgur.com/OqfJuwg
10:26 nine tadzik: just epic!
10:28 tadzik :)
10:29 [Tux] joined #perl6
10:33 tadzik a fraction of the current set of features for a price of a day of work and 4k lines of C++ :P
10:33 tadzik [TuxCM]: ok, reproduced :)
10:36 rindolf joined #perl6
10:36 anaeem1 joined #perl6
10:40 kaare_ joined #perl6
10:41 dalek rakudo/nom: c894d84 | lizmat++ | src/core/Array.pm:
10:41 dalek rakudo/nom: Slightly less naive Array.elems as an lvalue
10:41 dalek rakudo/nom:
10:41 dalek rakudo/nom: Handles the case of increasing the size and making sure we have uninitialized
10:41 dalek rakudo/nom: values in there, rather than whatever was left behind before.
10:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c894d84746
10:46 dalek roast: 424a9fa | lizmat++ | S02-types/array.t:
10:46 dalek roast: Add some Array.elems as a lvalue tests
10:46 dalek roast: review: https://github.com/perl6/roast/commit/424a9fa018
10:55 _mg_ joined #perl6
10:55 dalek perl6-examples: c5e2c11 | paultcochrane++ | lib/Pod/Htmlify.pm6:
10:55 dalek perl6-examples: Extract html output dir into its own variable
10:55 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/c5e2c119bb
10:55 dalek perl6-examples: 9e6ea27 | paultcochrane++ | lib/Pod/Htmlify.pm6:
10:55 dalek perl6-examples: Extract repeated html-writing code into its own routine
10:55 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/9e6ea27066
10:57 lizmat m: for ^1000 { my @a = ^1000; @a.elems; @a.splice(500) }; say now - INIT now
10:57 camelia rakudo-moar 52b279: OUTPUT«4.4802118␤»
10:57 lizmat m: for ^1000 { my @a = ^1000; @a.elems; @a.elems=500 }; say now - INIT now
10:57 camelia rakudo-moar 52b279: OUTPUT«0.8500177␤»
10:57 lizmat m: for ^1000 { my @a = ^1000 }; say now - INIT now
10:57 camelia rakudo-moar 52b279: OUTPUT«0.5800326␤»
10:57 lizmat m: for ^1000 { my @a = ^1000; @a.elems }; say now - INIT now
10:57 camelia rakudo-moar 52b279: OUTPUT«0.59314455␤»
10:58 lizmat m: say (4.5 - .6) / (0.85 - .6)
10:58 camelia rakudo-moar 52b279: OUTPUT«15.6␤»
11:01 * Su-Shee gently pokes at the jnthn again.. ;)
11:02 anaeem1_ joined #perl6
11:04 lizmat tinita_++ # http://blogs.perl.org/users/tinita/2015/04/affin​itylive-is-sponsoring-the-perl-qa-hackathon.html
11:07 nine Is NativeCall actually safe to use on a 32 bit system?
11:12 dalek rakudo/nom: 1ce8732 | lizmat++ | src/core/MapIter.pm:
11:12 dalek rakudo/nom: Simplify Mapiter.BUILD
11:12 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1ce8732f31
11:14 nine What would be the equivalent to size_t in NativeCall?
11:17 FROGGS nine: yes, it should be mostly safe on 32bits... we dont know about any open issue I believe
11:17 FROGGS nine: size_t should be a long I guess
11:19 rurban_ joined #perl6
11:22 dalek rakudo/nom: 909dc43 | lizmat++ | src/core/Enum.pm:
11:22 dalek rakudo/nom: Simplify Enum.BUILD
11:22 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/909dc43c56
11:26 lizmat is it correct that we don't have any StrDistance spec tests ?
11:27 lizmat and do we need it as a class at all?  Why not a string-distance($a,$b) sub ?
11:28 lizmat or a $a.string-distance($b) method
11:28 moritz \o
11:28 lizmat moritz o/
11:29 petercommand joined #perl6
11:31 dj_goku joined #perl6
11:32 moritz huh, what's Enum.BUILD?
11:32 moritz it's a method, not a submethod, and takes positional arguments
11:32 dalek doc: f5cb7ae | paultcochrane++ | lib/Language/ (5 files):
11:32 dalek doc: Purge trailing whitespace
11:32 dalek doc: review: https://github.com/perl6/doc/commit/f5cb7ae3a1
11:33 moritz m: say 'x'.uniname
11:33 camelia rakudo-moar c894d8: OUTPUT«LATIN SMALL LETTER X␤»
11:33 lizmat moritz: I just simplified the code, there is no functional difference, and the spectest is clean
11:34 lizmat on the premise it would allow for better optimized code
11:34 lizmat (compiled code)
11:34 moritz lizmat: I gathered that from the diff, but I stilled hoped you had an idea why it's different
11:35 dalek Inline-Perl5: a768314 | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
11:35 dalek Inline-Perl5: Fix compatibility with 32 bit systems
11:35 dalek Inline-Perl5:
11:35 dalek Inline-Perl5: Fixes GH #19
11:35 dalek Inline-Perl5: Thanks to (Albert Berger)++ for reporting.
11:36 dalek Inline-Perl5: review: https://github.com/niner/Inl​ine-Perl5/commit/a7683147d8
11:38 psch lizmat: http://irclog.perlgeek.de/​perl6/2014-07-10#i_9002709 is where (parts of) the reasoning why we have StrDistance, and not a .distance method
11:39 sergot morning #perl6 \o
11:39 sqirrel joined #perl6
11:39 lizmat sergot o/
11:39 moritz m: say 'xy'.uniname
11:39 camelia rakudo-moar c894d8: OUTPUT«LATIN SMALL LETTER X␤»
11:39 psch lizmat: iirc before that jnthn++ suggested the class because we mostly don't need the actual distance, just "did tr/// change anything?", so we can defer calculating the distance
11:40 psch and just return .Bool
11:42 dalek doc: d741201 | moritz++ | lib/Type/Cool.pod:
11:42 dalek doc: Cool.uniname; uni* coercions
11:42 dalek doc: review: https://github.com/perl6/doc/commit/d741201991
11:52 sergot lizmat o/
11:56 timotimo bartolin_: i wonder why you marked the pascal's triangle test skip rather than todo? do we expect the test needs changing with the new semantics?
11:59 grondilu joined #perl6
11:59 grondilu m: constant primes = grep *.is-prime, 2 .. *; say primes[^10];
11:59 camelia rakudo-moar 909dc4: OUTPUT«2 3 5 7 11 13 17 19 23 29␤»
12:00 grondilu (something like that was hanging locally)
12:01 grondilu ah nevermind it was a silly mistake elsewhere.
12:12 anaeem1_ joined #perl6
12:21 dalek rakudo/nom: 37ec24f | lizmat++ | src/core/Mu.pm:
12:21 dalek rakudo/nom: Make a twiddleless Mu.clone 8% faster
12:21 dalek rakudo/nom:
12:21 dalek rakudo/nom: For 2 attribute case, larger number of attributes are probably faster still
12:21 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/37ec24f08b
12:22 anaeem1_ joined #perl6
12:29 raiph joined #perl6
12:29 anaeem1 joined #perl6
12:32 nine Please have a look at https://github.com/rakudo/rakudo/pull/410 Run S01-perl-5-integration spec test files if Inline::Perl5 is installed
12:35 bartolin_ timotimo: I skipped the test because the code dies atm (and the following tests are not executed). I'm not sure if the code is intended to die, now.
12:36 bartolin_ anyway, I opened ticket #124330 for this
12:36 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124330
12:37 isBEKaml joined #perl6
12:37 timotimo oh, ok
12:37 timotimo thanks for clarifying
12:38 bartolin_ yw :-)
12:45 aborazmeh joined #perl6
12:45 aborazmeh joined #perl6
12:51 psch nine: looks good from here, although the ===SORRY!=== from the system() maybe has too much of "huh, did something go wrong?"
12:52 psch nine: although afair you can't not print that and still get the exit code, except by relying on output redirects?
12:52 psch shell redirects, that is
12:54 psch hm, maybe «make install; panda rebootstrap.pl; panda install Inline::Perl5; make spectest» is a bit roundabout as well, but i don't think a integrated make target makes sense
12:54 cognominal joined #perl6
12:59 lizmat nine: it also broke Travis :-(
12:59 psch lizmat: that was just a timeout
12:59 lizmat ah...
12:59 psch https://travis-ci.org/rakud​o/rakudo/jobs/59024701#L185
13:00 sisar joined #perl6
13:03 vendethiel joined #perl6
13:04 timotimo nqp-m: say(NQPMu or "foobar");
13:04 camelia nqp-moarvm: OUTPUT«Confused at line 2, near "say(NQPMu "␤   at gen/moar/stage2/NQPHLL.nqp:493  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:panic:105)␤ from gen/moar/stage2/NQP.nqp:921  (/home/camelia/rakudo-inst-1/share/​nqp/lib/nqp.moarvm:comp_unit:872)␤ from gen/…»
13:04 timotimo nqp-m: say(NQPMu || "foobar");
13:04 camelia nqp-moarvm: OUTPUT«foobar␤»
13:04 timotimo nqp-m: say("barf" || "foobar");
13:04 camelia nqp-moarvm: OUTPUT«barf␤»
13:06 timotimo nqp-m: "foo bar baz" ~~ / ' bar ' /; say($/.pre);
13:06 camelia nqp-moarvm: OUTPUT«Cannot call method 'pre' on a null object␤   at /tmp/FzfxoJ3Y89:1  (<ephemeral file>:<mainline>:56)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/cameli…»
13:06 timotimo nqp-m: "foo bar baz" ~~ / bar /; say($/.pre);
13:06 camelia nqp-moarvm: OUTPUT«Cannot call method 'pre' on a null object␤   at /tmp/jyk6vLIeEF:1  (<ephemeral file>:<mainline>:56)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/cameli…»
13:06 timotimo nqp-m: my $/ := "foo bar baz" ~~ / bar /; say($/.pre);
13:06 camelia nqp-moarvm: OUTPUT«Cannot find method 'pre'␤   at /tmp/FjkVNZdo8K:1  (<ephemeral file>:<mainline>:56)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/camelia/rakudo-inst-1/s…»
13:07 timotimo nqp-m: my $result := "foo bar baz" ~~ / bar /; say($result.pre);
13:07 camelia nqp-moarvm: OUTPUT«Cannot find method 'pre'␤   at /tmp/kzwgczcsu7:1  (<ephemeral file>:<mainline>:56)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/camelia/rakudo-inst-1/s…»
13:07 timotimo how do i ...
13:08 psch nqp-m: my $result := "foo bar baz" ~~ / bar /; say(nqp::substr($result.CURSOR.target, 0, $result.CURSOR.from));
13:08 camelia nqp-moarvm: OUTPUT«foo ␤»
13:08 timotimo i'm pretty sure there used to be something like that?
13:09 psch timotimo: pre seems to be Perl 6 land
13:09 timotimo aaw
13:09 timotimo ok
13:09 RabidGravy m: class Foo { method bar(Str $f) { } }; Foo.new.bar;
13:09 camelia rakudo-moar 37ec24: OUTPUT«Too few positionals passed; expected 2 arguments but got 1␤  in method bar at /tmp/7HVSZplfb7:1␤  in block <unit> at /tmp/7HVSZplfb7:1␤␤»
13:09 sftp_ joined #perl6
13:09 dalek rakudo/newio: a244887 | lizmat++ | src/core/Str.pm:
13:09 dalek rakudo/newio: Stub missing unixxxx subs for JVM
13:09 dalek rakudo/newio:
13:09 dalek rakudo/newio: This unbusts the JVM build
13:09 dalek rakudo/newio: review: https://github.com/rakudo/rakudo/commit/a244887186
13:09 diana_olhovik_ joined #perl6
13:09 timotimo ah
13:09 timotimo prematch and postmatch
13:09 RabidGravy is it possible to change the message to say 1
13:09 cognominal joined #perl6
13:09 timotimo nqp-m: my $result := "foo bar baz" ~~ / bar /; say($result.prematch);
13:09 camelia nqp-moarvm: OUTPUT«Cannot find method 'prematch'␤   at /tmp/1oVRkqiPYy:1  (<ephemeral file>:<mainline>:56)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/camelia/rakudo-ins…»
13:09 timotimo aaw
13:09 dalek joined #perl6
13:09 timotimo but thanks, psch
13:10 timotimo nqp-m: my $result := "foo bar baz" ~~ / bar /; say($result.CURSOR.prematch);
13:10 camelia nqp-moarvm: OUTPUT«Cannot find method 'prematch'␤   at /tmp/hmtHLA9YR7:1  (<ephemeral file>:<mainline>:61)␤ from gen/moar/stage2/NQPHLL.nqp:1256  (/home/camelia/rakudo-inst-1/share​/nqp/lib/NQPHLL.moarvm:eval:181)␤ from gen/moar/stage2/NQPHLL.nqp:1454  (/home/camelia/rakudo-ins…»
13:10 dalek Heuristic branch merge: pushed 82 commits to roast/newio by lizmat
13:10 timotimo :(
13:10 RabidGravy I know *why* it says 2 but the user shouldn't care about the implcit one on methods
13:11 timotimo nqp-m: my $result := "foo bar baz" ~~ / bar /; say($result.from);
13:11 camelia nqp-moarvm: OUTPUT«4␤»
13:11 timotimo no need for the .CURSOR at least
13:11 psch m: my method foo (Str:U: $) { }; foo()
13:11 camelia rakudo-moar 37ec24: OUTPUT«Too few positionals passed; expected 2 arguments but got 0␤  in method foo at /tmp/RcebMyvClK:1␤  in block <unit> at /tmp/RcebMyvClK:1␤␤»
13:11 psch RabidGravy: considering you can do that ^^^, i think we should keep the implicit in the count
13:12 RabidGravy ah
13:12 * psch .oO( expected 1 argument but got -1 )
13:16 sisar left #perl6
13:17 * lizmat gives up again on trying to make @*INC lazy
13:18 lizmat .oO( would have been nice to get bare startup from 0.18 to 0.10 seconds )
13:26 dalek rakudo/nom: 914abb6 | peschwa++ | src/ (2 files):
13:26 dalek rakudo/nom: Simplify smart match code gen.
13:26 dalek rakudo/nom:
13:26 dalek rakudo/nom: Providing an accepts method for StrDistance allows removal of special casing
13:26 dalek rakudo/nom: for the tr/// in make_smartmatch. Additionally it seems to be negligibly
13:26 dalek rakudo/nom: faster (~.003 less D misses, according to cachegrind).
13:26 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/914abb6986
13:30 mr-foobar joined #perl6
13:31 psch timotimo: re #124331:
13:31 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124331
13:31 psch m: my @sizes = 100, 110, 120, 130; @sizes >>+=>> @sizes[0]; say @sizes
13:31 camelia rakudo-moar 37ec24: OUTPUT«200 310 320 330␤»
13:32 psch timotimo: i think that means the RHS doesn't get thunked?
13:32 psch m: my @sizes = 100, 110, 120, 130; @sizes >>+=>> @sizes[0]<>; say @sizes
13:32 camelia rakudo-moar 37ec24: OUTPUT«200 210 220 230␤»
13:32 travis-ci joined #perl6
13:32 travis-ci Rakudo build failed. Pepe Schwarz 'Simplify smart match code gen.
13:32 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59028423 https://github.com/rakudo/rakudo/c​ompare/37ec24f08bf7...914abb69866f
13:32 travis-ci left #perl6
13:32 psch those darn containers
13:33 psch *shakes fist*
13:33 psch "fatal: The remote end hung up unexpectedly" says travis
13:35 lizmat psch: shouldn't the ACCEPTS be self.Bool ?
13:35 skids m: say (-4 ~~ &abs); given -4 { when &abs -> $a { "$_ $a".say } } # Maybe this should be specced/designed to work?
13:35 camelia rakudo-moar 37ec24: OUTPUT«4␤Too few positionals passed; expected 1 argument but got 0␤  in block  at /tmp/2OZCKJ9lHF:1␤  in block <unit> at /tmp/2OZCKJ9lHF:1␤␤»
13:35 psch lizmat: i don't think so, consider: if $a ~~ tr/a/b/ > 2 { }
13:36 psch (potential precedence mixup aside)
13:37 grondilu joined #perl6
13:37 timotimo yo flussence, i may need your support, i'm getting strange errors regarding nqp::writefh
13:38 skids .oO(Hah, total coincidence othe folks were talking about closely related matter.)
13:38 grondilu first is very useful but I whish there was a quantitative adverb n to get "the n firsts"
13:39 lizmat psch: hmmm... looking at almost every other ACCEPTS method we have, I see Bool being returned
13:39 timotimo oooh, i am a giddy goat
13:40 psch lizmat: fwiw, i think $a ~~ tr/// a special case of $a ~~ &sub, and Code.ACCEPTS returns the result of the sub
13:41 lizmat psch: related question: why are you coercing :$!before, but not :$!after ?
13:42 psch lizmat: $!after is the result of the .trans call on $!before
13:42 psch around line 6180 in Actions.nqp
13:43 psch lizmat: and .trans returns nqp::p6box_s(...)
13:43 psch and nqp::join(...) respectively
13:44 psch i suppose that should be boxed too, right?
13:44 lizmat ok, but basically what StrDistance is, is the building block of the Levenshtein functionality, no ?
13:44 psch lizmat: right.  with defered distance calculation
13:44 lizmat so we could use this e.g. to find out methods to suggest when a method is not found
13:44 lizmat (at runtime)
13:45 psch yeah, definitely
13:45 lizmat ok, so maybe we should make it more general purpose and make sure :after is also coerced to Str  :-)
13:46 psch i think so, yeah.  i'd probably even rename the attributes
13:46 psch "before" and "after" only really make sense when it's tr/// specific
13:47 rivarun joined #perl6
13:48 lizmat psch: have you ever looked at src/Perl6/World.nqp, line 56 and following ?
13:49 psch lizmat: yeah, i have.  but i didn't think calling into world to get the distance was sensible
13:49 psch lizmat: considering i either 1) have to write a sub or class anyway or 2) generate a giant AST
13:49 psch that aside i'm also not quite sure how that's done in the first place, probably gethllsym('$*W') or something?
13:50 psch i do admit that it's a bit unfortunate to have the same algorithm in two places in CORE
13:51 lizmat yeah, I was thinking about lifting it to P6 level many times in the past and make it a generic Perl 6 functionality
13:53 psch wouldn't that delay some things to runtime that can be compile time with having it in World?
13:53 lizmat if it's in core, it's all precomped anyway
13:53 psch e.g. if "Did you mean...?" depends on having a Perl 6 runtime we can't error with that at compile time
13:54 * psch might be mixing up levels there
13:54 lizmat why not?
13:54 lizmat compile time for your module, is runtime for the CORE settings
13:54 psch oh, of course
14:03 lizmat museum&
14:06 dalek nqp: 466d719 | timotimo++ | src/vm/moar/HLL/Backend.nqp:
14:06 dalek nqp: write out json pieces directly; allow .json profile filenames
14:06 dalek nqp: review: https://github.com/perl6/nqp/commit/466d719b7f
14:10 travis-ci joined #perl6
14:10 travis-ci NQP build failed. Timo Paulssen 'write out json pieces directly; allow .json profile filenames'
14:10 travis-ci http://travis-ci.org/perl6/nqp/builds/59031120 https://github.com/perl6/nqp/com​pare/f51bf0e9e824...466d719b7fec
14:10 travis-ci left #perl6
14:11 timotimo hmm
14:11 psch impolite remote end...
14:12 timotimo is that what happened?
14:12 timotimo ah
14:12 psch yes, it hung up unexpectedly :P
14:13 timotimo it was so far away from the failure report that i didn't see
14:13 timotimo i wonder how long the core setting profile run is going to take still
14:13 timotimo it's at 1h 17m now
14:14 timotimo ^C2314.93user 2352.11system 15:06:20elapsed 8%CPU (0avgtext+0avgdata 7693936maxresident)k
14:14 timotimo i killed it, as you can see
14:14 eli-se joined #perl6
14:14 psch is that 7.6g ram?
14:14 eli-se .oO(multithreaded merge sort is a Divide & Concur approach to sorting)
14:15 timotimo yes, that's all the ram i have
14:15 timotimo plus a whole lot of swap
14:24 skids eli-se: you may also want to look at cubesort, it has some benefits.
14:24 eli-se I want to implement distributed merge sort.
14:25 skids eli-se: Why merge-sort in particular?
14:25 eli-se For fun!
14:25 eli-se I have only ever implemented a non-inplace quicksort ripoff.
14:25 eli-se Which was in APL. Nice but boring.
14:28 jnthn afternoon, #perl6
14:28 * jnthn is way behind on backlog...
14:33 * Su-Shee pushes everybody else aside.. :)
14:34 cschwenz joined #perl6
14:34 TimToady m: my @sizes = 100, 110, 120, 130; @sizes X-= @sizes[0]; say @sizes;
14:34 Su-Shee jnthn: I just need a yes or no and no code! ;) can you possibly switch talk times with me in oslo? I'm sunday later after noon and I have to catch a flight :)
14:34 camelia rakudo-moar 914abb: OUTPUT«0 10 20 30␤»
14:38 jnthn Su-Shee: I didn't even see the schedule yet :)
14:38 isBEKaml joined #perl6
14:38 jnthn Su-Shee: Provided it doesn't make me conflict with myself, it should be fine :)
14:39 Su-Shee jnthn: it should not, we have both two talks, with an hour in between and yours are sunday before noon and mine are sunday after noon. :)
14:39 jnthn Su-Shee: Just looked and seems like swapping actually gives me more time between my talks :)
14:40 Su-Shee jnthn: you wouldn't even have to get up early in the morning!1! :)
14:40 jnthn o.O :D
14:40 LonelyGM joined #perl6
14:40 jnthn Su-Shee: Which of my slots are you looking to swap with?
14:41 jnthn the 11:00 one of the 13:00 one?
14:41 jnthn *or
14:41 Su-Shee jnthn: well that is a selling point to many people :)
14:41 Su-Shee jnthn:ideally both :)
14:41 Su-Shee I have 14 and 16
14:41 jnthn Oh...
14:42 jnthn Sorry, was only looking at the Perl track, misunderstood you have two :)
14:42 jnthn OK, I'm totally fine with it.
14:42 jnthn That means I get a break between the two :)
14:42 Su-Shee jnthn: really? no flight to catch on sunday?
14:42 jnthn Su-Shee: No
14:43 Su-Shee jnthn: oh that is so awesome, thank you very much. I propose it to the oslo folks :)
14:43 jnthn Su-Shee: I've got a class in Gothenburg on Tuesday so will head down there sometime on Monday afternoon/evening.
14:44 jnthn Also the swap means I'm not talking at the same time as arnsholt++ :)
14:45 Perl7 joined #perl6
14:46 Perl7 Perl6 is badly done. Better clean up and launch Perl7
14:46 Su-Shee jnthn: and I wouldn't collide with abigail and markus ramberg which have related talks to my subjects..
14:46 Perl7 (If MS can jump from MS8 to MS10, why can't perl?)
14:46 Su-Shee jnthn: also, then I can see hopefully your concurrency talk :)
14:46 Perl7 (Badly done as in cannot sell)
14:47 isBEKaml OH HEY - someone from the future!?!?!
14:47 isBEKaml hello, Perl7!
14:47 Perl7 Oh yes, i have come back in time to tell you people some news!
14:47 Su-Shee jnthn: I told sjn and krunen and I hope they agree. oslo is so expensive for me that I had to cut my stay a bit short.
14:48 isBEKaml Su-Shee: don't organizers provide discounted/free stay for talk delegates?
14:48 Perl7 First, Java has turned into a kids toy, which they would rather play with Go.
14:50 Perl7 Second, Python and Ruby pretty much gone teeth to teeth, and they... merged together in a weird way
14:51 Su-Shee isBEKaml: that wouldn't make the stay more cheaply, some locations simply are really expensive and oslo is one of them.
14:51 Su-Shee isBEKaml: then it just hits somebody else's budget..
14:52 isBEKaml Su-Shee: Yeah, I heard Oslo being really expensive to stay - but I didn't know the difference to be huge compared to other European cities
14:52 Perl7 Third, HTML, CSS, JS etc. all turn into a single "Internet Language"
14:53 Perl7 Fourth, Lisp family will make a huge come back with Julia, Dylan etc.
14:53 isBEKaml Su-Shee: doesn't matter now - good that you were able to work out something
14:54 Su-Shee isBEKaml: well it's around 100 euros more or less and I try to stay within a for me affordable open source conference budget but still get a day of a nice location in to see some art :)
14:54 Su-Shee well. and in oslo to buy coffee.
14:55 arnsholt We do have excellent coffee
14:57 arnsholt Su-Shee: What are your planned coffee stops?
14:57 Perl7 isBEKaml: Remember, in a world of viral marketing, making yourself look good will give you the edge to win
14:57 jnthn Su-Shee: I think Oslo is expensive for everyone.
15:00 jnthn Su-Shee: Anyway, hopefully the swap works out. :)
15:01 petercommand joined #perl6
15:01 Su-Shee arnsholt: tim wendelbroe and I definitely need to bring home solberg & hansen
15:02 arnsholt Good picks, good picks
15:02 arnsholt Another good one is Java
15:02 Su-Shee arnsholt: it's even better, I'm like 15 minutes away on foot from wendelbroe/mathallen :)
15:03 arnsholt I think I prefer the cappuccino at Java over Tim Wendelboe's (but really hard to decide, really)
15:03 Su-Shee arnsholt: I can have about three large, strong coffees per day so I can certainly add more options :)
15:03 Su-Shee arnsholt: do you have a location for Java?
15:04 arnsholt It's in Ullevålsveien, don't remember the number off-hand. 'Sec
15:04 arnsholt Number 47
15:04 arnsholt By Sankthanshaugen, if you're familiar with the different parts of Oslo
15:06 Su-Shee arnsholt: no, I'm not, will be my first time in oslo..
15:06 Su-Shee arnsholt: I'm in sven bruns gate.
15:06 arnsholt It's a bit of a walk from Mathallen, but not too far
15:06 brrt joined #perl6
15:06 Su-Shee arnsholt: everything under 10km is "oh I just walk there" for me ;)
15:07 arnsholt Then it'll be fine, yeah =)
15:07 Su-Shee ah, ridiculous.. google maps says 10 minutes walking, so it's usally 8.
15:07 Su-Shee perfect :)
15:08 Su-Shee arnsholt: I also need to bring home walter's mandeler chocolate of course. ;)
15:09 arnsholt Oh, yes!
15:09 flussence o/
15:09 yoleaux 07:23Z <timotimo> flussence: --optimize=off would cut out a gigantic part of the call tree, most likely, as the optimizer goes through almost the whole QAST tree that's generated for the core setting and will reflect the structure of the QAST tree almost 1:1 in its call stacks ... except it'll have an additional "walk_children" (OSLT) frame in between layers of nodes
15:10 timotimo flussence: i've got it running locally and pushed a commit to nqp that makes things a bit nicer
15:10 timotimo among other things, you can --profile-filename=foo.json and get json without the html template
15:11 timotimo oh
15:11 timotimo it kind of seems like i broke that feature ?!
15:11 flussence timotimo: did you see the pull request I sent for nqp?
15:11 Perl7 Is the people who own the channel "dead?
15:11 timotimo i did not
15:12 flussence try that ;)
15:12 timotimo i see yours is better
15:13 timotimo especially the part in Compiler.nqp
15:13 timotimo i didn't notice that was missing in my implementation
15:14 dalek nqp: 783bf9a | timotimo++ | src/vm/moar/HLL/Backend.nqp:
15:14 alini joined #perl6
15:14 dalek nqp: Revert "write out json pieces directly; allow .json profile filenames"
15:14 dalek nqp:
15:14 dalek nqp: This reverts commit 466d719b7fec402f80f8291e237fb7a295e68fd3.
15:14 dalek nqp:
15:14 dalek nqp: flussence++ made a better pull request
15:14 dalek nqp: review: https://github.com/perl6/nqp/commit/783bf9a013
15:14 dalek nqp: f1837f7 | (Anthony Parsons)++ | src/HLL/Compiler.nqp:
15:14 dalek nqp: Pass profile-filename arg to profile-compile
15:14 dalek nqp: review: https://github.com/perl6/nqp/commit/f1837f7b86
15:14 dalek nqp: 1c4e73e | (Anthony Parsons)++ | src/vm/moar/HLL/Backend.nqp:
15:14 dalek nqp: Make dump_profile_data much less likely to OOM
15:14 dalek nqp:
15:14 dalek nqp: This alters the to-json logic so that, instead of building one massive list of
15:14 dalek nqp: string bits and writing it all in one go, it flushes chunks of 12KB or so to
15:14 dalek nqp: disk at a time. This makes it possible to --profile-compile the core setting in
15:14 dalek nqp: about 10GB of RAM rather than 40+.
15:14 dalek nqp:
15:14 dalek nqp: I've also added a feature where specifying a --profile-filename ending in .json
15:14 dalek nqp: causes it to write as plain JSON instead of using the HTML wrapper. This is a
15:14 dalek nqp: tiny bit faster, and may be useful if you want to poke at it with different
15:14 dalek nqp: tools. The aforementioned --profile-compile generates *hundreds* of megabytes of
15:14 dalek nqp: JSON; you're never going to get that to load in a browser.
15:14 dalek nqp: review: https://github.com/perl6/nqp/commit/1c4e73ea2f
15:14 dalek nqp: 4aff120 | timo++ | src/ (2 files):
15:14 dalek nqp: Merge pull request #233 from flussence/master
15:14 dalek nqp:
15:14 dalek nqp: An attempt to reduce --profile's memory usage
15:14 dalek nqp: review: https://github.com/perl6/nqp/commit/4aff1208fd
15:14 timotimo you said the profiler will build more than a gig of data?
15:14 flussence yay, dalek survived my essay
15:15 flussence and yeah, I gave up waiting after an hour or so...
15:15 timotimo well, at least it reaches almost 90% of cpu usage on my desktop now
15:15 flussence I didn't know about --optimize=off though, can go try that now.
15:15 timotimo 12.5 gig of virtual memory
15:15 timotimo oh, that'll make a very big difference
15:16 timotimo i suspect it'd basically cut the result in half
15:16 flussence yep, 12.5's exactly the number I got too
15:16 timotimo since you're already ankle-deep in the profiler, maybe you can have a look at the branch that introduces a maximum call graph depth after which nodes will be summarized
15:16 timotimo i couldn't get it to report accurate results
15:16 xfix joined #perl6
15:16 xfix joined #perl6
15:18 travis-ci joined #perl6
15:18 travis-ci NQP build failed. timo 'Merge pull request #233 from flussence/master
15:18 travis-ci http://travis-ci.org/perl6/nqp/builds/59036431 https://github.com/perl6/nqp/com​pare/783bf9a0132f...4aff1208fdf4
15:18 travis-ci left #perl6
15:18 timotimo "connection timed out"
15:19 travis-ci joined #perl6
15:19 travis-ci NQP build failed. Timo Paulssen 'Revert "write out json pieces directly; allow .json profile filenames"
15:19 travis-ci http://travis-ci.org/perl6/nqp/builds/59036412 https://github.com/perl6/nqp/com​pare/466d719b7fec...783bf9a0132f
15:19 travis-ci left #perl6
15:19 timotimo and again
15:28 b2gills m: my @a = ^100; @a.elems = (^*).pick; say @a;
15:28 camelia rakudo-moar 914abb: OUTPUT«Method 'Int' not found for invocant of class 'Any'␤  in block  at src/gen/m-CORE.setting:11077␤  in block <unit> at /tmp/xN6QNpVJhg:1␤␤»
15:28 b2gills m: my @sizes = 100, 110, 120, 130; @sizes >>-=>> my $ = @sizes[0]; say @sizes
15:28 camelia rakudo-moar 914abb: OUTPUT«0 10 20 30␤»
15:30 sqirrel joined #perl6
15:34 cschwenz Two questions for all of #perl6:  1) What modules from http://modules.perl6.org/ are considered to be good examples of how to author a Perl 6 module?  2) What modules from the same list exhibit good Perl 6 coding practice?  (I want to use the answers to both of these questions to learn the Perl 6 way of doing things.)
15:35 masak cschwenz: https://github.com/moritz/json/ comes up often as a nice, small "ideal module".
15:36 masak moritz++ # JSON::Tiny
15:36 DrForr Nod, that's the layout I followed (roughly) for my Grammar::ECMAScript.
15:37 masak by the way, I just saw the logo for Template::Mustache. that's now officially The Best Module Logo. :)
15:38 cschwenz @masak:  okay, thanks!  i'll checkout JSON::Tiny…  :-)
15:38 * masak is not @masak -- only when he needs to kick people off the channel :P
15:38 * isBEKaml blams twitter and github for @name-calling-everyone
15:39 isBEKaml *blames
15:39 cschwenz hmm, didn't known @ had a different meaning in IRC.  :-/
15:39 masak cschwenz: happy to contribute that knowledge :) it means "channel operator"
15:40 cschwenz ohhhh  :-D
15:40 masak and + before the name means "bot", I think.
15:40 psch + means +v, usually
15:41 RabidGravy yeah
15:41 psch which means when the channel has +m set, people with +v can still talk
15:41 psch where +m is "moderated"
15:41 DrForr +m - moderated, +v - voice
15:41 psch and +v voice
15:41 masak oh, nice. I didn't know that :)
15:42 masak anyway, only four bots on this channel have a + on them
15:43 masak m: say Promise.^methods
15:43 camelia rakudo-moar 914abb: OUTPUT«BUILD vow keep break result cause then start in anyof allof Bool -> (Mu:D \fles: *%_) { #`(Method+{<anon>}|66346952) ... } -> (Mu:D \fles: *%_) { #`(Method+{<anon>}|66347104) ... }␤»
15:44 psch \fles?
15:44 jnthn m: say 'fles'.flip
15:44 camelia rakudo-moar 914abb: OUTPUT«self␤»
15:44 jnthn Well, that's another way to do the "that" pattern :)
15:45 masak bleh.
15:46 eli-se joined #perl6
15:46 cschwenz sightly related to perl6, how would you convince someone to transition to Modern Perl (possibly as a stepping stone to perl6)?  (background: this person thinks 1998 to 2001 Perl 5 is where it's at and the more modern stuff is borderline heresy.  :-/ )
15:46 masak cschwenz: it's usually not a good idea to make convincing other people a necessary part of any larger plan.
15:47 isBEKaml \fles - jeez, just as I was thinking it can't read like "mud flies..."
15:47 masak cschwenz: the general solution to the problem you describe is to wait for the new generation of people to supplant the old.
15:48 cschwenz got it
15:48 isBEKaml cschwenz: masak++ here is talking about world domination!
15:48 masak I thought that much was obvious.
15:48 cschwenz i was hoping there was a path i hadn't thought of to gently guide someone down to enlightenment
15:49 masak cschwenz: can't change other people. sorry.
15:49 moritz give 'em a copy of Modern Perl, and hope they read and like it?
15:49 isBEKaml masak: world domination is rough - kinda like blasting earth to create the new express hyperspace
15:49 jnthn People *can* learn and change, but only if they care to.
15:50 DrForr The lightbulb has to *want* to change.
15:52 RabidGravy :)
15:52 ugexe lead by example. let them figure out on their own they are hurting themselves. otherwise let them hurt themselves, because there is nothing wrong with wanting to learn from your own mistakes
15:52 Su-Shee cschwenz: find out what it is exactly they like about that kind of perl 5 style (I have a couple of suspicions) and show them that style (cleaned up version) in modern p5 and p6.
15:53 Su-Shee cschwenz: usally it's about the directness of the old style, the ease of procedural programming and such.
15:58 RabidGravy there are some people who just don't *get* OO programming, there was nothing stopping you from doing it in the period mentioned - "Object Oriented Perl" was published in 2000
15:59 Su-Shee modern perl isn't necessarily about OO.
15:59 Su-Shee also, old school programs aren't necessarily bad, they're possibly just old school.
16:01 psch if it ain't broke...
16:02 RabidGravy now but I would say Modern Perl is about OO
16:02 psch although perl5 from ~2000 might be considered somewhat broke i think?  i'm not terribly familiar with that era of perl
16:03 psch i guess that's reiterating ugexe++'s advice
16:04 Su-Shee RabidGravy: considering that much perl is about evented stuff and functional principles and not OO at all..
16:05 Su-Shee also, many people don't want the heavy weight magic super featurezz stuff anymore, so there's also a different school of modern perl...
16:07 b2gills m: my @a = ^100; #`( this needs to be here for it to work) @a.elems; @a.elems = (^*).pick; say @a;
16:07 camelia rakudo-moar 914abb: OUTPUT«␤»
16:07 b2gills m: my @a = ^100; #`( this needs to be here for it to work) @a.elems; @a.elems = (^*).pick; say @a;
16:07 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71␤»
16:07 b2gills m: my @a = ^100; @a.elems = (^*).pick; say @a;
16:07 camelia rakudo-moar 914abb: OUTPUT«Method 'Int' not found for invocant of class 'Any'␤  in block  at src/gen/m-CORE.setting:11077␤  in block <unit> at /tmp/GaQrypwFyR:1␤␤»
16:08 b2gills lizmat: ^^ the .elems code still needs some work
16:11 jnthn @a.elems is an l-value?!
16:12 * jnthn never knew :)
16:12 b2gills It is now on Array
16:12 jnthn Is that in the design docs somewhere?
16:12 b2gills I doubt it
16:12 masak we just *implemented* it?
16:12 psch m: my @a = ^10; @a.elems = 5; say @a # ...?
16:12 camelia rakudo-moar 914abb: OUTPUT«(Any) (Any) (Any) (Any) (Any)␤»
16:13 jnthn Well, maybe there was good discussion at some point :)
16:13 * jnthn is behind on backlog
16:13 masak was it a good discussion if it ended up making .elems an l-value? :P
16:13 * masak is probably biased or something
16:14 b2gills m: my @a = ^10; @a.elems; @a.elems = 5; say @a # ...?
16:14 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4␤»
16:14 psch huh
16:14 ab5tract RabidGravy: inasmuch as Modern Perl centers on OO, it does so with Moose or a Moose-a-like. Which, incoincidentally, started as a backporting of Perl 6 OO into Perl 5.
16:14 psch Array::elems is a Proxy that calls List::elems in FETCH
16:14 b2gills The same construct is an lvalue in Perl5 ` $#array = 5 `
16:15 psch and List::elems calls self.gimme(*)
16:15 masak maybe there were spectests that wanted this...
16:15 psch m: my @a = ^10; @a.gimme(*); @a.elems = 5; say @a # ...?
16:15 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4␤»
16:15 psch so i guess Array::elems STORE has to call that too
16:15 ab5tract I hadn't quite thought about it in those terms before.
16:17 psch m: my @a = ^10; @a.gimme(*, :sink); @a.elems = 5; say @a # ...?
16:17 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4␤»
16:18 psch i suppose $!nextiter.reify should be enough, actually
16:18 psch in Array::elems STORE
16:18 jnthn Yes, .elems on a lazy list has side-effects
16:19 psch jnthn: right, but Array::elems STORE doesn't call List::elems, while FETCH does, which is why the rvalue elems is needed once to not empty the list
16:19 masak there does not seem to be any preceding discussion in the backlog.
16:19 psch but i guess that means having a reify in the STORE is perfectly fine, 'cause we bail anyway if it's infinite
16:20 flussence joined #perl6
16:20 MARTIMM joined #perl6
16:20 masak I also don't see any spectests about .elems being an lvalue.
16:24 b2gills It is something that was occasionally useful in Perl 5
16:27 cschwenz joined #perl6
16:30 Su-Shee left #perl6
16:32 b2gills It certainly seems easier to do `@a.elems = { $_ * 2 }` than `@a.push( Any xx @a.elems )` and `@a.elems = */2` vs `@a.splice(*/2)` seems like a tie.
16:33 timotimo why do you write = { $_ * 2 } instead of *= 2? is that about not causing a FETCH before the STORE?
16:33 colomon joined #perl6
16:33 b2gills also you wouldn't have to figure out if @a was bigger or smaller than 5 for `@a.elems = 5`
16:35 b2gills ` { $_ * 2 } ` seemed cleaner than ` * + * ` or ` * * 2 `
16:35 timotimo right, but the = operator doesn't work like that :)
16:35 psch m: my @a = ^5; @a.elems; @a.elems = { $_ * 2 }; say @a
16:35 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4 (Any) (Any) (Any) (Any) (Any)␤»
16:36 b2gills it does if its implemented with a Proxy ( which it is )
16:36 timotimo um ... well i guess elems does work like that
16:36 psch m: my @a = ^5; @a.elems *= 2; say @a
16:36 camelia rakudo-moar 914abb: OUTPUT«0 1 2 3 4 (Any) (Any) (Any) (Any) (Any)␤»
16:37 timotimo it allows passing a callable, that part i've missed
16:38 ab5tract It seems like something that would be more appropriately implemented as a method.  @list.trim(50) ~~ @list = @list[^50] # something like this?
16:39 ab5tract Hmm... or I am totally missing what is happening to @a when @a.elems is an l-value
16:40 psch m: my @a = ^10; +@a; +@a = 5; say @a
16:40 camelia rakudo-moar 914abb: OUTPUT«WARNINGS:␤Useless use of "+" in expression "+@a" in sink context (line 1)␤0 1 2 3 4␤»
16:40 psch m: my @a = ^10; +@a = 5; say @a # the warning is wrong!
16:40 camelia rakudo-moar 914abb: OUTPUT«(Any) (Any) (Any) (Any) (Any)␤»
16:42 jnthn If you write code that makes the warning wrong, then it's you that's wrong, not the warning.
16:42 psch jnthn: no, there's a bug in Array::elems :/
16:42 jnthn I can with with .elems being assignable sort of, but it should in no way leak to .Numeric.
16:42 psch jnthn: Numeric calls elems
16:43 jnthn Right, but Numeric should be decontainerizing the result...
16:43 jnthn (e.g. not be marked "is rw")
16:43 jnthn It's possible that that doesn't happen correctly on a Proxy, mebbe.
16:43 jnthn So that's probably the bug.
16:43 b2gills perhaps a simple ` my $ = self.elems ` in List.Numeric would fix that
16:44 jnthn Does List.Numeric have "is rw" on it?
16:44 jnthn If not, I think it's simply a "we fail to decontainerize" bug.
16:44 b2gills It just returns the proxy from Array.elems
16:44 jnthn But the proxy should not escape if it's not marked "is rw"
16:44 jnthn It should have its FETCH called at the point of Numeric returning the value
16:45 jnthn We may be cheating somehow though.
16:45 b2gills I can see it being useful both ways
16:45 jnthn Well, if you want the Proxy to escape then you must write "is rw"
16:45 jnthn If it's escaping without that it's a bug.
16:46 jnthn And it certainly should not be escaping from Numeric.
16:46 timotimo we should have a recont_ro?
16:46 jnthn Yes, but I think that may only know what to do with a Rakudo Scalar.
16:46 b2gills I think of `is rw` as basically just a nice way of writing a Proxy
16:47 timotimo ah
16:47 timotimo perhaps that's the problem, yeah
16:47 jnthn b2gills: Then you think wrong.
16:48 b2gills I didn't think that was how it was implemented
16:48 jnthn If you return a Proxy from something not marked "is rw" then you're (by design, though maybe not in Rakudo yet) asking for FETCH to be called on it.
16:48 flussence joined #perl6
16:51 b2gills I don't remember coming across a single Routine in Rakudo that has both `is rw` set and Proxy.new
16:52 jnthn Then I'd better fix things sooner rather than later so we can flush out the mistakes. :)
16:53 timotimo ah!
16:53 timotimo the profile of core setting compilation is through
16:53 _mg_ joined #perl6
16:53 timotimo just 1.4 gigs of json
16:54 flussence timotimo: I've just gave up on the --optimize=off run, it messed things up to the point where I needed a reboot
16:55 timotimo oh wow
16:55 timotimo sorry to hear that
16:55 flussence I wonder, would deleting bits of the data as they're written out help much?
16:55 timotimo now how do i get the beginning of the data thrown out?
16:55 timotimo i don't understand what you mean?
16:55 timotimo oh, i do understand what you mean
16:55 timotimo i had that thought at the beginning, too
16:55 timotimo would be interesting to try
16:55 * flussence does
16:56 timotimo could potentially make things shrink, except that stuff lands in the gen2 for sure
16:56 timotimo and the gen2 doesn't get compacted, so it only shrinks by virtue of the free list and perhaps throwing out completely empty pages
16:57 flussence my hope there is that it'll free enough empty pages that the OS will have enough breathing room to not fall over
16:57 flussence .oO( maybe we should've just used CSV and post-processed that into json... )
16:57 timotimo i don't know if the gen2 will throw out *any* data at all
16:58 timotimo rather than just making space free for new data
16:58 timotimo but the working set will shrink for the GC runs
16:59 b2gills .oO( when I see flussence and timotimo talking to each other it seems like someone talking to themselves since they are both purple on my irc client )
16:59 FROGGS joined #perl6
17:00 timotimo at least there's a letter more in flussence than there is in timotimo
17:00 lizmat joined #perl6
17:00 timotimo the 1.4G big profile shrinks to 54 megabytes when gzip'd
17:01 flussence b2gills: I thought upgrading to 256 colours would fix that on my end, it just gives me very subtly different shades of the same colours now :(
17:03 b2gills well you are a slightly lighter shade of purple, but on a white background its fairly negligible.
17:05 lizmat_ joined #perl6
17:08 masak I think assigning .elems to a callable is way too much magic.
17:08 jnthn I could see it on a .resize(callable) method or so.
17:09 masak I'm surprised that the introduction of such a feature was preceded by zero discussion.
17:09 lizmat_ masak: it was -OFun
17:09 jnthn Well, remember there's a hackathon in Berlin with many 6-folks there.
17:09 jnthn So it may have been discussed there.
17:09 jnthn Anyway, I suspect TimToady++ will weigh in with something insightful.
17:09 masak hope so.
17:10 davido_ joined #perl6
17:10 masak "you think it's cute today" is my review of `@a.elems = { $_ * 2 };`
17:10 zakharyas joined #perl6
17:10 dalek rakudo/nom: 3474e0f | lizmat++ | src/core/Array.pm:
17:10 dalek rakudo/nom: Increase my commit rate
17:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3474e0ff1e
17:11 ab5tract I do have to say, as -OFun it is an impressive bit of code
17:11 dalek roast: 0c7ef0c | lizmat++ | S02-types/array.t:
17:11 dalek roast: Increase my commit rate some more
17:11 dalek roast: review: https://github.com/perl6/roast/commit/0c7ef0cc89
17:12 _mg_ joined #perl6
17:12 jnthn Indeed. I'm really not so sure .elems as an l-value is the right place for the functionality *but* I don't know we have an existing good way to do the $#foo = 42 thing either.
17:13 nine Yes, we did discuss it.
17:13 [TuxCM] joined #perl6
17:13 psch if nothing else it showed that a Proxy leaks through a not-is-rw method
17:13 jnthn Yes, that's a bug.
17:14 lizmat well, not any more
17:15 jnthn lizmat: No, there's still a Rakudo bug that your work uncovered that needs fixing independent of what happens with .elems.
17:17 lizmat #124341
17:17 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124341
17:17 psch lizmat++
17:17 ab5tract lizmat++
17:18 jnthn lizmat: Thanks. Will fix it on Monday, if not sooner. :)
17:18 jnthn FROGGS: I saw your EVAL/BEGIN one too; I need to ponder how to deal with that one.
17:19 moritz do we really have to make Array.elems return a Proxy?
17:19 travis-ci joined #perl6
17:19 travis-ci Rakudo build passed. Elizabeth Mattijsen 'Increase my commit rate'
17:19 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59046148 https://github.com/rakudo/rakudo/c​ompare/914abb69866f...3474e0ff1e42
17:19 travis-ci left #perl6
17:19 moritz that sounds bad performance-wise
17:20 lizmat moritz: don't worry about it, it is no more
17:20 FROGGS jnthn: currently I am trying to (de)serialize as single object directly
17:20 FROGGS jnthn: because .perl=>EVAL is icky anyway
17:21 jnthn *od*
17:21 jnthn *nod*
17:21 jnthn FROGGS: Well, you can always create a unique SC
17:21 _mg_ joined #perl6
17:21 jnthn FROGGS: And construct an object and shove it in that SC, and then ask it to be serialized.
17:21 FROGGS yes, that gave me headache also
17:22 jnthn Oh?
17:22 jnthn Did you see the serialization tests in NQP? They basically do that.
17:22 nine Would someone dare to merge https://github.com/rakudo/rakudo/pull/410?
17:22 FROGGS jnthn: https://gist.github.com/FR​OGGS/c82f5d98d957d5240d15
17:23 FROGGS jnthn: they do not shove the result into a file though
17:23 FROGGS jnthn: the tests re-use the string head list...
17:24 FROGGS heap*
17:24 FROGGS and even when I create the exact same string heap list, it fails
17:26 flussence timotimo: I've stuck an «$obj := nqp::null_s()» at the bottom of to_json() and it seems to have worked - memory usage is going *down* as it runs
17:26 flussence (more importantly, I'm able to type that in my irssi window at all...)
17:30 nine tadzik: my prototype is still online: http://niner.name/icycles.html
17:30 tadzik cool!
17:30 _mg_ joined #perl6
17:32 lizmat_ joined #perl6
17:32 dalek rakudo/nom: b6405a8 | (Stefan Seifert)++ | t/ (2 files):
17:32 dalek rakudo/nom: Run S01-perl-5-integration spec test files if Inline::Perl5 is installed
17:32 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b6405a8b81
17:32 dalek rakudo/nom: aa99dd4 | lizmat++ | t/ (2 files):
17:32 dalek rakudo/nom: Merge pull request #410 from niner/nom
17:32 dalek rakudo/nom:
17:32 dalek rakudo/nom: Run S01-perl-5-integration spec test files if Inline::Perl5 is installed
17:32 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/aa99dd4009
17:35 flussence this profiler still seems abnormally slow though, 300-400KB/s on an i7
17:36 flussence I think fixing that is probably beyond my level of understanding.
17:36 telex joined #perl6
17:38 timotimo flussence: way cool!
17:39 timotimo tadzik: "Malformed input file" - why? :(
17:39 travis-ci joined #perl6
17:39 travis-ci Rakudo build failed. lizmat 'Merge pull request #410 from niner/nom
17:39 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59047807 https://github.com/rakudo/rakudo/c​ompare/3474e0ff1e42...aa99dd4009e6
17:39 travis-ci left #perl6
17:39 tadzik timotimo: you need to extract the JSON
17:40 timotimo i did
17:40 tadzik it doesn't eat the .html
17:40 tadzik huh
17:40 timotimo with a hex editor
17:40 tadzik can you upload it?
17:40 flussence timotimo: that's not gonna work, the JSON inside the html is double-escaped
17:40 tadzik or, as Star Trek characters put it, download it onto my computer
17:40 timotimo hehe.
17:41 timotimo flussence: oh god fucking damn it
17:41 timotimo you're right
17:41 timotimo how do i fix it?
17:41 tadzik I copypasted it in vim
17:41 timotimo yeah ... vim doesn't really eat that file
17:41 tadzik :syntax off either?
17:42 flussence sed might be the only option here
17:42 flussence you'd need to replace \\" with \", \\\\ with \\, and \' with '
17:42 timotimo huh, so in tadziks case it just worked without fixing the escaping?
17:43 flussence hm, it might work as is actually, but you'd get a lot of stray \s in the output
17:43 tadzik timotimo: I always copypaste the JSON and it works :(
17:43 tadzik I dunno what's in yours
17:43 timotimo 1.4 gig of data :)
17:43 tadzik lol wat
17:43 timotimo core setting --profile-compile
17:43 tadzik I wrote my profiler frontend because 20MB was too big for angular...
17:44 tadzik now a challenger appears for the good old C++
17:44 tadzik so that's why you can't upload it :P
17:44 tadzik actually, you know what?
17:44 raiph joined #perl6
17:44 tadzik I wonder if Qt's readAll() isn't crapping out on it
17:45 timotimo it compresses down to only ~55 megabyte
17:45 tadzik if the first thing in the toplevel array is an object it would not have produced that message
17:45 tadzik what is it then?
17:46 timotimo 0000000: 5b7b 2274 6f74 616c 5f74 696d 6522 3a31  [{"total_time":1
17:46 tadzik looks good
17:46 tadzik huh
17:46 timotimo does it have to end in a newline or something?
17:46 tadzik nah
17:47 tadzik oh, wait
17:47 tadzik can you identify which "malformed input file" message is it from? :D
17:48 tadzik I suspect main.cpp:28, and in turn that qt was unable to parse the thing
17:48 timotimo it opens the file, stats it a few times, then closes it
17:48 dalek rakudo/nom: 8eaf2ee | lizmat++ | src/core/ (7 files):
17:48 dalek rakudo/nom: Mark all Proxy use as "is rw"
17:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/8eaf2eedc0
17:48 brrt joined #perl6
17:48 tadzik reads its size and nopes out of it? :D
17:49 timotimo the size of the QByteArray is 0
17:49 tadzik ah
17:50 tadzik so readAll() probably not up to the task
17:50 timotimo This function has no way of reporting errors; returning an empty QByteArray can mean either that no data was currently available for reading, or that an error occurred.
17:50 tadzik that's not the worst I've seen of Qt
17:50 FROGGS jnthn: it seems to just work now O.o (creating an SC, serializing and deserializing that with a single object)
17:50 tadzik it also said (yes, said) "out of memory", when sqlite database was in a file with no write permissions
17:51 timotimo :(
17:51 tadzik timotimo: oh, you can try errorString()
17:51 tadzik on 'profile'
17:51 timotimo ok
17:52 timotimo "Unknown error" both before readAll and after
17:52 tadzik oh ffs
17:52 tadzik qt, y u do dis
17:53 tadzik how long did that profiling took, timotimo?
17:53 timotimo i didn't "time" it, sadly
17:53 tadzik or can you send me the 55meg gzip
17:53 timotimo sure
17:54 timotimo damn, i only have the gzip on my laptop
17:54 tadzik I wonder if you can have such big a QByteArray
17:54 timotimo could you deal with the html file?
17:54 tadzik 14G big?
17:54 timotimo like, use okteta or something locally?
17:55 timotimo gzipped of course
17:55 tadzik oh, I'll manage
17:55 timotimo good
17:55 timotimo then i'll have more up bandwidth
17:55 xfix joined #perl6
17:55 travis-ci joined #perl6
17:55 travis-ci Rakudo build passed. Elizabeth Mattijsen 'Mark all Proxy use as "is rw"'
17:55 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59048878 https://github.com/rakudo/rakudo/c​ompare/aa99dd4009e6...8eaf2eedc000
17:55 travis-ci left #perl6
17:55 tadzik I can write a perlscript that'll get to JSON.parse and give me what's between '''s or so
17:56 timotimo sure
17:56 timotimo doing it with okteta was super easy
17:56 tadzik ed
17:56 timotimo i'm not good at ed
17:57 tadzik me neither
17:57 sjn ingy: https://github.com/sjn/perl6-example-dist
17:57 tadzik I once learned how to hello world with it
17:59 psch isn't ed just vi without a visible buffer?
17:59 psch (also probably plus something to show the not-really-a-buffer)
18:00 tadzik :ex in vim is pretty much ed
18:00 tadzik or something
18:00 tadzik but you sometimes get stuck in it, and typing '.' in empty line helps. ed taught me that :P
18:02 dalek rakudo/nom: 4f65a34 | lizmat++ | lib/NativeCall.pm:
18:02 dalek rakudo/nom: Missed one Proxy -> is rw omission
18:02 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/4f65a347b0
18:02 dalek rakudo/nom: ba4964e | lizmat++ | t/harness:
18:02 dalek rakudo/nom: Made Inline::Perl5 check silent if not installed
18:02 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ba4964e816
18:02 psch ah, right, '.' on empty line is somewhat the "show the buffer" thingy
18:02 psch well, it shows the current line apparently
18:03 * psch doesn't really want to imagine editing long (FSVO long) code files with ed/ex
18:04 psch j: say "hi"
18:04 camelia rakudo-jvm aa99dd: OUTPUT«cannot connect to eval server: Connection refused␤»
18:04 tadzik hah
18:05 psch i went back to something on the jvminterop side of things, and i have troubles figuring out how to proceed
18:05 psch consider: «use java::lang::System:from<Java>; say System.get_out.WHAT»
18:06 psch that currently dies with "java.lang.ClassCastException: org.perl6.nqp.sixmodel.TypeObject cannot be cast to org.perl6.nqp.sixmodel.reprs.JavaObjectWrapper"
18:07 psch which, i think, is semi-sensible, cause there's no point in wrapper a *sixmodel*.TypeObject in a repr
18:07 psch at least if i'm not misunderstanding sixmodel...
18:07 jnthn FROGGS: Sorry, the cooking needed attention...
18:07 timotimo tadzik: http://t.h8.lv/p6bench/core_se​tting_compile_profile.html.gz
18:08 FROGGS jnthn: no problem chef
18:08 jnthn FROGGS: But...rly, you gisted me the code and then it was scared and started working? :D
18:08 psch but checking with Ops.concrete if i could have a TypeObject gives me an ArrayIndexOutOfBoundsException somewhere in ASM, i.e. bad bytecode
18:08 FROGGS jnthn: no, I went to the computer games museum *and then* it started to work
18:08 psch it's hard to debug through these layers of indirection :/
18:09 jnthn FROGGS: Oh, cool :)
18:09 jnthn FROGGS: A new debugging technique!
18:09 FROGGS hehe
18:09 FROGGS yeah :o)
18:09 * psch googles if there's computer game museums nearby
18:10 FROGGS jnthn: I updated it.... what do you think? https://gist.github.com/FR​OGGS/c82f5d98d957d5240d15
18:13 travis-ci joined #perl6
18:13 travis-ci Rakudo build failed. Elizabeth Mattijsen 'Made Inline::Perl5 check silent if not installed'
18:13 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59049932 https://github.com/rakudo/rakudo/c​ompare/8eaf2eedc000...ba4964e816b6
18:13 travis-ci left #perl6
18:14 _mg_ joined #perl6
18:16 flussence joined #perl6
18:16 jnthn FROGGS: The string heap handling aint so robust
18:17 jnthn FROGGS: But otherwise looks in the right direction.
18:17 flussence bah, spoke too soon... I just spent half an hour trying to unwedge my box :D
18:20 FROGGS jnthn: yeah, though atm I can serialize and deserialize $*DISTRO... so I try now to put it into CUR::Installation
18:24 timotimo flussence: your box is strange
18:24 Rounin joined #perl6
18:25 rurban_ joined #perl6
18:26 timotimo readAll() just seems to give up and not even try. I looked into it more closely and it looks like it fails to resize the QByteArray to 2.5gb. I would have expected an error but I guess that makes sense.
18:26 timotimo ^- tadzik
18:27 flussence it's the fastest one I have, but the power button is a few miles too far away to hit when things go awry...
18:27 lizmat gist with lazy @*INC patch: https://gist.github.com/li​zmat/a10b3e6b659cfe7dd762
18:29 timotimo :)
18:31 timotimo lizmat: are you posting this because it works again?
18:33 FROGGS it did install panda \o/
18:33 nine timotimo: no, so I can have a look at it
18:35 jnthn FROGGS: OK, fingers crossed :)
18:36 jnthn dinner &
18:36 anaeem1 joined #perl6
18:37 timotimo nine: nice
18:40 FROGGS jnthn: okay, my string heap causes trouble it seems
18:42 yqt joined #perl6
18:45 masak has anyone tried building a websockets server in Perl 6 yet?
18:45 masak I don't see anything on http://modules.perl6.org/
18:45 FROGGS jnthn: is my problem just with newlines in strings of the string heap or something else?
18:50 RabidGravy masak, I've thought about it.  As a plugin for some existing module prbably.
18:51 masak would be cool to have it work with Bailador.
18:51 masak I have a use case for websockets -- but in the short term, I suspect I'll end up doing client-side polling instead.
18:51 psch ISTR that timotimo had been poking at websockets
18:52 masak I'm willing to help.
18:52 psch http://irclog.perlgeek.de/p​erl6/2015-03-26#i_10343167
18:52 psch doesn't look like much came of it, from skimming clog google results
18:54 RabidGravy also an Event Source server thing, I'm modifying HTTP::UserAgent as we speak so it can operate as a client
18:56 RabidGravy they're pretty much the same except web sockets are bi-directional
19:01 masak oh, an Event Source server thing would work for my use case as well. would probably be more suitable, even.
19:01 masak all I need is basically for the server to send the client a ping (so it can auto-reload).
19:02 leont joined #perl6
19:02 nbdsp joined #perl6
19:02 [TuxCM] TimToady, can I please have -Mstrict do as expected from the command line? (the I can put that in my alias)
19:03 masak |Tux|: I feel your pain.
19:03 nbdsp Greetings! I try to use Perl 5 DBI with the 'use DBI:from<Perl5>;'. The '$sth.execute()' returns True (that is OK), but 'my $arrayref = $sth.fetchall_arrayref()' freezes. Is there some additional/special syntax or methods for using Perl 5 modules functionality or this 'fetchall_arrayref()' function?
19:03 yoleaux 17 Apr 2015 07:07Z <nine> nbdsp: Inline::Perl5 is passing binary strings from Perl 5 to Perl 6 as CArray[int8] followed by manually copying to a Buf element by element. Sounds horrible but at least it works until NativeCall gets improved.
19:03 * masak is not a big fan of non-strict -e by default
19:04 * [TuxCM] is in masak's camp
19:04 psch fwiw, the synopses actually mentioned -e as strict *and* non-strict in two different locations respectively
19:04 psch i don't remember if that got changed, but i suspect it did
19:04 nbdsp youleaux, great news. thanks.
19:05 * psch would also prefer strict -e because he doesn't do unstrict things anyway
19:05 [TuxCM] I'd accept -E for strict (hint)
19:07 nbdsp .tell nine thanks, for advise about CArray[int8]!
19:07 yoleaux nbdsp: I'll pass your message to nine.
19:08 masak I don't think we should overload -E with another meaning than Perl 5's.
19:11 timotimo psch: poking at websockets from very far with a long stick
19:13 timotimo was what i did some time ago
19:13 RabidGravy masak, can't work out easily how to persuade HTTP::Easy and by extension Bailador to do chunked and not close the client socket
19:14 RabidGravy not suggesting it isn't possible though
19:14 timotimo i've built an EventSource server as a middleware for HTTP::Server::Async
19:14 masak I think we should start by writing an independent prototype.
19:15 masak and then connect it to whatever.
19:16 psch huh
19:16 psch what happened to the Cairo module?
19:16 spider-mario joined #perl6
19:16 psch panda still finds it, but modules.perl6.org doesn't
19:16 psch and installing with panda fails with "*fetch stage failed for Cairo: source-url meta info missing"
19:16 timotimo oh?
19:16 timotimo yeah
19:16 timotimo same for my JSON::Fast
19:16 timotimo i have no idea what i did wrong :(
19:17 timotimo also: yay! somebody wants to use my cairo module!
19:17 timotimo AFK
19:17 psch haha
19:18 psch well, local install works
19:28 raydiak looks like spec changes..."source-url" was the old place to declare it, now specs say it goes in "source" in a "support" subobject...but Cairo's meta has "source-url" inside "support", so not valid either the old or new way I guess
19:29 raydiak specs...designs...whatever
19:29 lizmat keep speculating  :-)
19:31 brrt joined #perl6
19:32 dalek rakudo/nom: 66a640b | lizmat++ | src/Perl6/Grammar.nqp:
19:32 dalek rakudo/nom: Allow -Mstrict to enable strictnes for -e
19:32 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/66a640bbe3
19:32 dalek rakudo/nom: 4be9900 | lizmat++ | t/harness:
19:32 dalek rakudo/nom: Shorten "Inline::Perl5" not installed message
19:32 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/4be9900c83
19:32 * raydiak considers referencing roast first instead of the design docs so he can go back to saying "the specs say..." :)
19:32 lizmat FROGGS++  # inspiration for 66a640b
19:33 FROGGS jnthn: okay, my problem does not seem to be about newlines...
19:34 psch raydiak: imo, "specs" is fine for the synopses/design.perl6.org — it's the name of the repo after all
19:34 psch i tried not to use "spec" at all, but instead say "roast" and "designs" though, because the ambiguity does exist...
19:35 psch s/tried/try/
19:37 psch timotimo: using Cairo seems difficult.  neither shoot_em_up.p6 nor livecoding.p6 seem to work: "Internal error: Unwound entire stack and missed handler"
19:38 psch and i'd hope those should work, because otherwise i have no idea where to look to have an idea how to use it... :)
19:39 FROGGS psch: that sounds like jvm
19:40 psch FROGGS: it does?  i'm calling perl6-m
19:40 FROGGS hmmm, that msg sounded so jvm-ish... must be me being tired
19:41 psch frame.c:835 panics like that apparently
19:42 travis-ci joined #perl6
19:42 travis-ci Rakudo build failed. Elizabeth Mattijsen 'Shorten "Inline::Perl5" not installed message'
19:42 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59056629 https://github.com/rakudo/rakudo/c​ompare/ba4964e816b6...4be9900c8340
19:42 travis-ci left #perl6
19:44 dolmen joined #perl6
19:50 raydiak same error here with livecoding.p6 (on moar from about a week ago)...shoot_em_up.p6 gives me an unrelated-looking error about some undeclared cairo constants
19:51 psch raydiak: yeah, the constants are declared our without «is export»
19:51 psch raydiak: i prefixed the namespace locally
19:52 psch i also get "(A totally cool shooter game!:11638): Gdk-CRITICAL **: gdk_window_get_events: assertion 'GDK_IS_WINDOW (window)' failed" for shoot_em_up.p6
19:52 psch after fixing the undeclared constants via explicit namespace
19:53 raydiak I've always gotten "** (Cairo Live-Coding environment:4338): WARNING **: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files" for GTK::Simple even the tests, though I get similar from some other gtk stuff too entirely outside of perl
19:54 raydiak but idk much about gtk, just that it spits stuff like that all over the place :P
19:54 psch heh
19:54 raydiak looks very different now that I read closer though
19:59 [TuxCM] lizmat++, FROGGS++ -Mstrict
20:02 aborazmeh joined #perl6
20:02 aborazmeh joined #perl6
20:04 raydiak psch: yep I get the same Gdk error when I fix those constants too...wonder what changed, I'm pretty sure I've tried these out earlier this year and they worked
20:10 psch raydiak: thanks for confirming.  i was wondering if it could be some WM or X11 misconfiguration on my end
20:12 raydiak psch: you're welcome
20:13 timotimo psch: that's just when an exception flies that doesn't get caught inside a callback that we passed to C land
20:17 psch timotimo: and the Gdk-CRITICAL?  googling that doesn't tell me much, except that it gets reported to debain and ubuntu bugtrackers...
20:17 timotimo Gdk-critical is unimportant
20:18 timotimo everything based on gtk or gobject or something will spout between five and a hundred critical errors on startup
20:18 dalek rakudo/nom: a6314d3 | TimToady++ | src/core/operators.pm:
20:18 dalek rakudo/nom: respect containers returned from seq iterator
20:18 dalek rakudo/nom:
20:18 dalek rakudo/nom: fixes 124330
20:18 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/a6314d3ff9
20:18 timotimo that's to be expected and harmless
20:18 psch oh, okay
20:18 dalek roast: daf1198 | TimToady++ | integration/advent2012-day04.t:
20:18 dalek roast: pascal's triangle works again
20:18 dalek roast: review: https://github.com/perl6/roast/commit/daf1198720
20:21 psch hm, the example code in cairos Readme works at least
20:21 timotimo i kind of sort of invented the API on top of cairo ...
20:21 timotimo and i didn't invent docs to go with it :P
20:22 psch :/
20:22 dolmen joined #perl6
20:22 masak why did we mark as 'skip' something that had stopped working? isn't that just a way to hide test regressions?
20:23 psch masak: iirc it crashed the test file, but bartolin couldn't fix the regression off hand
20:23 psch which is why he skipped it
20:23 masak ok, I see.
20:23 TimToady well...there's something to be said for a keeping the test run clean, but there's also something to be said for not hiding regressions
20:23 masak maybe quarantining the test in a separate file would work better, so that the test isn't forgotten.
20:24 brrt left #perl6
20:24 brrt joined #perl6
20:25 TimToady now the odd thing is that the reason I never saw the regression when working on ... is that the test in question is marked #stress
20:25 travis-ci joined #perl6
20:25 travis-ci Rakudo build passed. TimToady 'respect containers returned from seq iterator
20:25 travis-ci http://travis-ci.org/rakudo/rakudo/builds/59060042 https://github.com/rakudo/rakudo/c​ompare/4be9900c8340...a6314d3ff93c
20:25 travis-ci left #perl6
20:25 masak heh.
20:25 masak another way to hide tests ;)
20:27 nbdsp Well, what I thought was program freeze, actually was very slow work. Fetching ang outputting one row with one text field containing several KB of text took maybe 5 minutes or so. The code is as follows: my $arrayref = $sth.fetchall_arrayref; for @$arrayref -> $q { say $q[0].decode('utf8'); } What can cause such slowness?
20:28 timotimo try perl6 --profile myscript.p6 ?
20:29 nbdsp will try, thanks.
20:30 timotimo that'll give us a bit of a chance to figure out what's going wrong
20:30 timotimo better than flying blind in any case
20:32 tadzik timotimo: I reproduced your problem. I now see that QByteArray is mutale and has an append() method, so you can possibly read the file chunk by chunk and slowly build a beast of QByteArray
20:32 tadzik but I'm two tired now,I'll try it tomorrow :)
20:34 timotimo thank you
20:41 nbdsp On the 'Routines' tab of profile report, the following 3 entries take 33.33% time each:  THE_END src/gen/m-CORE.setting:847  exit src/gen/m-CORE.setting:836  <unit> ./tst2.pl6:1
20:42 timotimo ... THE_END ... ?!
20:42 timotimo how much time each?
20:43 nbdsp The profiled code ran for 111949.11ms. Of this, 5213.15ms were spent on garbage collection and dynamic optimization (that's 4.66%)
20:48 nbdsp Each of those entries took about: "(18446744073700.9ms)
20:48 timotimo that seems very wrong
20:50 dalek rakudo/nom: 1edd514 | lizmat++ | src/Perl6/ModuleLoader.nqp:
20:50 dalek rakudo/nom: Add some more RAKUDO_MODULE_DEBUG messages
20:50 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1edd514076
20:51 timotimo did froggs already leave the hackathon venue?
20:53 nbdsp I hope so. ) Here the copy-paste: http://pastebin.com/wMwAsJLv
20:56 grondilu joined #perl6
21:06 [TuxCM] joined #perl6
21:08 masak tadzik++ # panda
21:08 masak tadzik++ # Bailador
21:09 [TuxCM] does panda now work on jvm?
21:10 * masak doesn't know
21:10 * [TuxCM] tries (might take a while :)
21:11 tadzik [TuxCM]: not really
21:11 tadzik but it's JVM's fault!
21:11 tadzik I am without fault
21:11 masak this is all true
21:11 tadzik my only fault is tormenting my co-hackathoners with espeak
21:11 [TuxCM] ok, /me stops trying (waste of resources then)
21:11 tadzik but they started!
21:12 masak ooh, neat. espeak.
21:12 tadzik "wwwwwwwwwwwwwwwwwwwwwwwww​wwwwwwwwwwwwwwwwwwwwwwww. Visit us at www.wwwwwwwwwwwwwww.com/wwwwwwwwwwwwwwwww"
21:12 * [TuxCM] checks panda git log ...
21:12 tadzik twitch.tv's favourite source of laughter, now absolutely free of donation fee
21:13 * psch grmls a bit more at jvm byte code gen
21:13 avalenn joined #perl6
21:14 FROGGS[mobile] timotimo: I did
21:14 FROGGS[mobile] still sitting in a train :o(
21:15 [TuxCM] tadzik, you left yesterday before my wife answered: she visited Wrozłav
21:16 masak Wrocław
21:16 [TuxCM] yeah, that
21:16 [TuxCM] :P
21:16 [TuxCM] at least I got the ł right
21:16 * masak scores [TuxCM] fractional points
21:17 [TuxCM] Who should I poke to fix RT#124298?
21:17 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124298
21:17 [TuxCM] and RT#124191
21:17 synbot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=124191
21:18 tadzik [TuxCM]: I don't remember the conversation :o
21:18 timotimo FROGGS[mobile]: i wish you the best of luck with the serialization stuff
21:18 [TuxCM] I didn't drink *that* much :)
21:19 tadzik apparently I did...
21:22 arnsholt Le sigh. Zero operator string concatenation is a bit of a misfeature *grumblegrumblegrumle*
21:23 masak arnsholt: using awk again? :P
21:24 FROGGS[mobile] timotimo: thanks :o)
21:25 arnsholt masak: Python, actually. I had a varargs method taking a list of strings and got weird results
21:26 timotimo FROGGS[mobile]: it's probably a few orders of magnitude faster than json once it works?
21:26 timotimo but significantly harder to pull out of the file, nah?
21:28 FROGGS[mobile] I've posted a gist, it is quite simple but still has a bug
21:30 timotimo right, the string heap is probably quite sensitive
21:31 timotimo i'd suggest a length + raw string format, as that ought to be very robust and doesn't require escaping or such
21:31 zakharyas joined #perl6
21:38 masak arnsholt: like TimToady pointed out, it's a rather low-leverage feature with many negative consequences.
21:43 psch $ ./perl6-j -e'use java::lang::System:from<Java>; say System.WHAT'
21:43 psch org.perl6.nqp.sixmodel.TypeObject@6349f468
21:43 psch better than a java-level exception, but still kind of useless :/
21:43 * psch gives up for today
21:43 * lizmat follows suit
21:57 masak 'night, #perl6
22:56 vendethiel o/
22:57 BenGoldberg joined #perl6
23:18 [TuxCM] joined #perl6
23:27 avalenn joined #perl6
23:51 eli-se vendethiel: hello
23:51 vendethiel o/ eli-se!

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

Perl 6 | Reference Documentation | Rakudo