Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2015-05-25

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:01 dayangkun joined #perl6
00:02 * [Coke] is back at his house, yay.
00:03 colomon hmmm, did Yapsi build freeze, or have I lost my SSH connection?
00:04 colomon Looks like Yapsi build maybe froze — certainly the SSH connection is still there.
00:04 laouji joined #perl6
00:07 ggoebel joined #perl6
00:19 colomon Eight minutes so far
00:21 tinyblak joined #perl6
00:22 tinyblak joined #perl6
00:27 laouji joined #perl6
00:31 colomon twenty minutes, and now I’m trying to take a closer look
00:39 andreoss timotimo: i've sent a report about this bug. thanks for helping me
00:39 laouji joined #perl6
00:41 colomon Yapsi is failing when asked to compile my $a; $a = 42;
00:41 tinyblak_ joined #perl6
00:48 kurahaupo1 joined #perl6
00:49 laouji joined #perl6
01:00 tinyblak joined #perl6
01:03 timotimo you're most welcome
01:07 colomon Yapsi problem is in the grammar
01:09 colomon possibly eat_terminator?
01:11 colomon masak: ^^
01:14 colomon y
01:14 colomon well, eat_terminator fails, and then the grammar hangs
01:19 Akagi201 joined #perl6
01:22 raydiak colomon: changing some suspicious-looking whitespace handling gets it through parse to runtime, but then has another unrelated crash
01:22 raydiak though I'd say the real problem is the line which reads "my $VERSION = '2011.05';" :)
01:24 kurahaupo1 joined #perl6
01:45 dolmen joined #perl6
01:53 Mouq o/ for the first time in a while
01:53 yoleaux 14 Apr 2015 22:47Z <psch> Mouq: TOML doesn't have provides yet, FYI
01:53 Mouq Well, good thing I'm working on it now >.<;
01:53 Mouq So, what does "Bytecode stream version too low" mean? Seems pretty LTA
02:00 * Mouq recompiles module. Duh. But still LTA
02:05 laouji_ joined #perl6
02:09 BenGoldberg joined #perl6
02:26 chenryn joined #perl6
02:50 noganex_ joined #perl6
02:54 araujo joined #perl6
02:57 vendethiel joined #perl6
03:01 TimToady Mouq!!! o/
03:02 Mouq Haha, hello! :)
03:03 yeahnoob joined #perl6
03:03 Mouq Finals came up, and after school ended I stopped coding for a while, but still tried to follow what was happening
03:03 TimToady well, we officially approve of not slacking off at school :)
03:04 Mouq heh :)
03:20 ssqq joined #perl6
03:30 kurahaupo1 I get fed the changelogs by email, and I was just reading "roots" in Numeric.pod. Can I ask, is the intention that it behave differently depending on whether the number is Complex or just Real (or Int, or whatever else)?
03:32 kurahaupo1 Also, it says "Returns NaN if $n <= 0" -- which is wrong, it should only do that if $n is even (or non-integral)
03:33 cibs joined #perl6
03:34 kurahaupo1 oh drat, I'm short of coffee, NaN if $n < 0 AND the number is 0, or if $n==0
03:36 laouji_ joined #perl6
03:38 kurahaupo1 (logically the -1th root of $x is simply 1/$x)
03:46 FROGGS__ joined #perl6
03:51 dalek ecosystem: cbf1111 | retupmoca++ | META.list:
03:51 dalek ecosystem: Add Syndication (RSS/Atom) parser/generator
03:51 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/cbf1111386
03:57 ssqq_ joined #perl6
03:58 dalek rakudo/nom: d7c9bfa | Mouq++ | src/Perl6/Actions.nqp:
03:58 dalek rakudo/nom: Enable typing via "has Type method …" (RT #115868)
03:58 dalek rakudo/nom:
03:58 dalek rakudo/nom: Copied verbatim from &def_routine.
03:58 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d7c9bfa2a3
04:05 jack_rabbit joined #perl6
04:08 jack_rabbit joined #perl6
04:15 chenryn joined #perl6
04:27 Sqirrel joined #perl6
04:27 jack_rabbit_ joined #perl6
04:28 jack_rabbit_ joined #perl6
04:30 jack_rabbit_ joined #perl6
04:32 jack_rabbit_ left #perl6
04:34 adu joined #perl6
04:37 laouji joined #perl6
04:41 jack_rabbit joined #perl6
04:43 xinming joined #perl6
04:47 quester joined #perl6
04:54 kaare__ joined #perl6
05:06 ssqq_ anyone use Tidy tools for perl6?
05:20 tony-o_ is there a tidy out there for p6?
05:25 vendethiel joined #perl6
05:30 chenryn joined #perl6
05:54 rindolf joined #perl6
05:55 diana_olhovik_ joined #perl6
06:09 zacts joined #perl6
06:10 Sqirrel joined #perl6
06:20 xfix joined #perl6
06:32 raydiak m: say @(Nil).IO.absolute
06:32 camelia rakudo-moar d7c9bf: OUTPUT«/home/camelia␤»
06:33 raydiak ^ and that, a while ago, was how the Nil change caused one of my projects to commit suicide and rm -rf itself :)
06:34 bartolin /o\
06:34 raydiak geekosaur++ gave me a tip about extundelete and saved it :)
06:35 bartolin geekosaur++ extundelete++
06:36 raydiak was wondering, though, if the empty string shouldn't fail or at least warn or something when coerced into a path with .IO
06:36 Sqirrel joined #perl6
06:36 andreoss joined #perl6
06:37 bartolin j: my @list = "a".."c" # broken with 24aca6a8
06:37 camelia rakudo-jvm d7c9bf: OUTPUT«control operator crossed continuation barrier␤  in block <unit> at /tmp/zQHABvJTJ_:1␤  in any <unit-outer> at /tmp/zQHABvJTJ_:1␤␤»
06:39 andreoss` joined #perl6
06:41 FROGGS[mobile] joined #perl6
06:41 RabidGravy joined #perl6
06:42 FROGGS[mobile] raydiak: +1 to die
06:42 FROGGS[mobile] (or fail)
06:44 raydiak neat...I'll make a PR before bed then, and maybe ask what lizmat thinks since she did so much of the IO work
06:45 raydiak FROGGS[mobile]: do you know how I would go about EVALing those :auth/:ver in a restricted setting?  do I have to start an entirely separate rakudo process just to parse them?
06:46 domidumont joined #perl6
06:46 FROGGS[mobile] hmmm
06:46 FROGGS[mobile] probably...
06:46 domidumont joined #perl6
06:47 FROGGS[mobile] maybe we can do something with slangs here?
06:48 raydiak I could manually parse a very limited subset like I already am but more variations, if that's not a pandora's box
06:49 raydiak you're the slang guy so if you think that's a good tool for the job, I'm happy to try it out with a few pointers to get started, unless you're volunteering yourself :)
06:52 FROGGS[mobile] aye :o)
06:52 raydiak wrt "like I already am": https://github.com/raydiak/panda/blob/authver/lib/Panda/Ecosystem.pm#L104-125
06:53 FROGGS[mobile] need to think about it this evening
06:54 raydiak indeed...it's a much deeper issue, this parsing of :auth and :ver than it seems like it would be at first glance :)
06:54 FROGGS[mobile] should be possible to invent a slang that disallows running code at compile time
06:54 FROGGS[mobile] and also filters statements in some way
06:54 FROGGS[mobile] raydiak: that's like it too often is, isnt it?
06:55 FROGGS[mobile] bartolin: do we have a test for that?
06:55 laouji_ joined #perl6
06:57 raydiak quite...some problems are like one of those orders-of-magnitude zooming in/out animations...always another layer/scale with another set of distinct features
07:01 fhelmberger joined #perl6
07:02 flaviusb joined #perl6
07:05 bartolin FROGGS[mobile]: there is a lot of spectest breakage for JVM: https://github.com/usev6/perl6-roast-data/blob/master/log/rakudo.jvm_summary.out#L1896
07:06 bartolin FROGGS[mobile]: yesterdays spectest on JVM was clean, so I think 24aca6a8 is the cause
07:14 RabidGravy morning
07:15 raydiak o/ RabidGravy
07:18 FROGGS[mobile] I see
07:19 laouji joined #perl6
07:20 Isp-sec joined #perl6
07:21 RabidGravy so I'm looking at a module and it has "unit class Foo;" and then in another file I'm doing "say Foo.^methods();" to debug some weirdness and getting "Method 'methods' not found for invocant of class 'Perl6::Metamodel::PackageHOW''  - how did it end up with that Metamodel class?
07:22 chenryn joined #perl6
07:23 laouji joined #perl6
07:24 RabidGravy very odd
07:27 virtualsue joined #perl6
07:27 laouji joined #perl6
07:28 al2o3-cr joined #perl6
07:29 sergot morning
07:29 sergot :)
07:33 DrForr Just barely, yeah.
07:33 raydiak .tell lizmat see an hour before now in the backlog, but I was wondering what you think of ''.IO being a failure with a message about 'use "." for the current dir'?
07:33 yoleaux raydiak: I'll pass your message to lizmat.
07:34 salva joined #perl6
07:35 raydiak .tell lizmat I tried to make a PR to that effect for consideration, but for some reason with the change it just gobbles all my RAM on stage parse
07:35 yoleaux raydiak: I'll pass your message to lizmat.
07:35 raydiak good night #perl6 o/
07:36 laouji joined #perl6
07:39 laouji joined #perl6
07:46 RabidGravy nighty nighty
08:05 mohij joined #perl6
08:05 masak antenoon, #perl6
08:05 laouji joined #perl6
08:07 jnthn o/ masak, *
08:08 darutoko joined #perl6
08:10 laouji joined #perl6
08:14 xinming joined #perl6
08:15 jnthn I've seen a couple of folks report isues involving a backtrace where we SEGV or similar doing a lookup in the method cache.
08:16 sunnavy joined #perl6
08:16 jnthn Or alternatively get a null method back
08:16 jnthn Curiously, this symptom is aggravated under concurrency.
08:16 jnthn I'd been looking for some kind of data race, but if it's happening in non-concurrent code too...well...
08:17 vendethiel joined #perl6
08:22 sunnavy joined #perl6
08:34 Alina-malina joined #perl6
08:36 jnthn Hmm, except now I look into it, the failure mode looks different. Aww.
08:44 laouji_ joined #perl6
08:51 vendethiel joined #perl6
08:52 RabidGravy does anyone have any feeling about https://gist.github.com/jonathanstowe/2eb6801204edbd877ef5 - looks wrong to me, especially the output of Pack.WHO
08:53 RabidGravy (leaving aside the less than ideal design, this is similar to code from the ecosystem which one worked)
08:56 DrForr Hrm. Any way to declare a compound return type? I want to return (Int, Int) - Should I just abandon the 'returns (Int, Int)'?
08:56 mohij joined #perl6
08:59 RabidGravy DrForr, doesn't seem to work in any number of variants
08:59 DrForr RabidGravy: yeah, I tried a few variants msyelf.
09:02 DrForr RabidGravy: I'd be tempted to say 'method singleton {...}' inside Pack::Util::Collection, call that in your constructor.
09:03 DrForr Or at least in your 'method collection', that'll have roughly the same laziness.
09:04 RabidGravy yeah, that was basically what I was thinking, but the weirdness isn't so much the design as the Pack.WHO returning "Util => (Util)"  which seems like all sorts of broken
09:04 RabidGravy and explains why it doesn't work
09:06 RabidGravy anyway off out now
09:06 DrForr Feels like the makings of a recursive include loop to me, actually. Also you're not bringing in the definition of Pack explcitly, which might make the loop more obvious.
09:09 cibs joined #perl6
09:09 laouji joined #perl6
09:17 FROGGS[mobile]2 joined #perl6
09:20 [Sno] joined #perl6
09:25 andreoss` can i pass metadata to pod code block?
09:29 Alina-malina joined #perl6
09:29 [Tux] joined #perl6
09:34 lizmat bartolin: looking at 24aca6a8 on JVM
09:34 yoleaux 07:33Z <raydiak> lizmat: see an hour before now in the backlog, but I was wondering what you think of ''.IO being a failure with a message about 'use "." for the current dir'?
09:34 yoleaux 07:35Z <raydiak> lizmat: I tried to make a PR to that effect for consideration, but for some reason with the change it just gobbles all my RAM on stage parse
09:35 lizmat raydiak: excellent idea, we don't want no unwanted rm -rfs
09:38 mohij joined #perl6
09:38 vendethiel joined #perl6
09:44 lizmat wow: control operator crossed continuation barrier
09:45 jnthn You may now proceed to read up on delimited continuations :P
09:46 lizmat https://gist.github.com/lizmat/0ff9b21d33a03837d736
09:46 jnthn gather/take are the only constructs using those, fwiw
09:48 andreoss` left #perl6
09:48 lizmat reverting 24aca6a8, seeing if that makes a difference
09:53 lizmat it does...  :(  but why?
09:54 dalek rakudo/nom: 0f3400c | lizmat++ | src/core/ (2 files):
09:54 dalek rakudo/nom: Revert "List|Parcel.eager should only work on instances"
09:54 dalek rakudo/nom:
09:54 dalek rakudo/nom: It breaks the JVM badly.
09:54 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0f3400c2ae
09:55 lizmat pasting jnthn's response from #moarvm for posterity:
09:55 lizmat [11:53:41]  <jnthn>lizmat: Not sure immediately...
09:55 lizmat [11:53:52]  <jnthn>lizmat: It probably shouldn't make a difference.
09:56 jnthn oops :)
09:59 aborazmeh joined #perl6
09:59 aborazmeh joined #perl6
10:04 vendethiel joined #perl6
10:11 lizmat hmmm... it appears we have spectests expecting IO::Path.new('') to succeed
10:11 [Sno] joined #perl6
10:12 lizmat I'm going to assume these are faulty
10:15 dalek rakudo/nom: e60f85c | lizmat++ | src/core/IO/Path.pm:
10:15 dalek rakudo/nom: Don't allow empty path specification, raydiak++
10:15 dalek rakudo/nom:
10:15 dalek rakudo/nom: It functioned as 'current directory' so far, but that can have dangerous
10:15 dalek rakudo/nom: implications, especially when trying to do an rm-rf on a directory, and you
10:15 dalek rakudo/nom: lost the directory name somewhere along the way.
10:15 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e60f85c275
10:17 cognominal joined #perl6
10:24 smls joined #perl6
10:28 kurahaupo1 joined #perl6
10:33 laouji_ joined #perl6
10:39 laouji joined #perl6
10:42 dalek roast: 7e0bc10 | lizmat++ | S32-io/io-path- (3 files):
10:42 dalek roast: Empty paths are no longer ok
10:42 dalek roast: review: https://github.com/perl6/roast/commit/7e0bc10e0c
10:43 smls Has lizmat's newio work been merged in Rakudo?
10:43 smls And has there been a blog about it?
10:43 lizmat nope
10:43 lizmat nope
10:43 smls ok
10:44 * smls will be patient
10:44 * lizmat doctor
10:46 laouji joined #perl6
10:46 dalek rakudo/nom: 8bff469 | lizmat++ | docs/ChangeLog:
10:46 dalek rakudo/nom: Mention empty path legality as incompatible change
10:46 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/8bff469d3b
10:49 spider-mario joined #perl6
10:50 chenryn joined #perl6
10:51 smls m: my $x = 1; say "foo_$x\_bar"
10:51 camelia rakudo-moar e60f85: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Uv4ZD3daxF␤Unrecognized backslash sequence: '\_'␤at /tmp/Uv4ZD3daxF:1␤------> 3my $x = 1; say "foo_$x\7⏏5_bar"␤    expecting any of:␤        postfix␤»
10:51 smls ^^ this used to work, didn't it?
10:51 smls it does in Perl 5
10:52 jnthn The typical Perl 6 idiom for that is {$x}
10:52 smls right
10:53 vendethiel joined #perl6
10:54 BenGoldberg joined #perl6
10:57 smls m: say (^10e6).pick
10:57 smls ^^ from the looooooooong time this takes to complete, I take it .pick is not special-cased for ranges?
10:57 camelia rakudo-moar e60f85: OUTPUT«(timeout)»
10:57 laouji_ joined #perl6
10:58 smls m: say 10e6.rand.Int
10:58 camelia rakudo-moar e60f85: OUTPUT«2756905␤»
10:58 smls this is fast, but less pretty
10:59 smls m: rand 10e6  # Also, this Perl5-ism error message suggests using pick
10:59 camelia rakudo-moar e60f85: OUTPUT«5===SORRY!5=== Error while compiling /tmp/k1tiE3K1WW␤Unsupported use of rand(N); in Perl 6 please use N.rand for Num or (^N).pick for Int result␤at /tmp/k1tiE3K1WW:1␤------> 3rand7⏏5 10e6  # Also, this Perl5-ism error mess␤»
10:59 lizmat smls: strange, looking
11:00 lizmat return self.list.pick($n) unless nqp::istype($!min, Int) && nqp::istype($!max, Int);
11:00 lizmat hmmm...
11:01 Ben_Goldberg joined #perl6
11:01 lizmat m: say (^10e6).roll
11:01 lizmat same issue
11:01 smls m: say (^10000000).pick   # huh, this is fast
11:02 smls (locally)
11:02 camelia rakudo-moar e60f85: OUTPUT«(timeout)»
11:02 camelia rakudo-moar e60f85: OUTPUT«3331991␤»
11:02 lizmat yeah, it's the Int check that forces it to generate the wole list
11:02 jnthn 10e6 is a Num
11:02 lizmat smls: it was waiting to timeout on mine
11:02 [ptc] tadzik: ping
11:05 lizmat one could argue that (^10e6).pick should fail
11:06 andreoss joined #perl6
11:06 tadzik [ptc]: hey
11:07 lizmat m: (^10e1.1).pick.say
11:07 camelia rakudo-moar e60f85: OUTPUT«5===SORRY!5=== Error while compiling /tmp/H5d31IblF6␤Confused␤at /tmp/H5d31IblF6:1␤------> 3(^10e1.7⏏1).pick.say␤»
11:07 [ptc] tadzik: I was wondering if you've got some time to answer a couple of questions about panda
11:08 [ptc] tadzik: sorry, rakudobrew...  (it has something to do with panda)
11:10 tadzik Email may be better, I have very scarce internet access for the next couple of weeks
11:10 tadzik The one in git log should be good :)
11:12 [ptc] well, I'm wanting to test modules and progs with Rakudo version 2015.04.  I can get 2015.04 to build nicely with rakudobrew, but panda uses the most current code
11:12 [ptc] which means that 2015.04 doesn't understand e.g. Empty...
11:12 aborazmeh joined #perl6
11:12 aborazmeh joined #perl6
11:13 [ptc] anyway, I've got a patch in the making to add a version option to build-panda, which would then allow one to use e.g `rakudobrew triple 2015.04 2015.04 2015.04` and then `rakudobrew build-panda 2015.04`
11:13 [ptc] and then hopefully I can install dependencies at that version
11:14 [ptc] the problem is, that I need to check out a particular version of panda, and I was wondering if you could tag the panda repo at a few commits
11:14 [ptc] I can find out the commit which would correspond to a given Rakudo so that it makes your life easier
11:15 [ptc] anyway, I was wondering what you thought of the idea and if it makes sense to do
11:16 tadzik Tagging panda by compatible rakudo releases is something I think I've already done, once or twice :!
11:17 [ptc] hrm, the last one which turns up in the repo is 2014.04
11:18 [ptc] https://github.com/tadzik/panda/tags
11:19 [ptc] tadzik: sorry if I've annoyed you!  Most certainly not the intention!
11:19 tadzik Oh, you did not, don't worry about it :)
11:20 colomon joined #perl6
11:20 tadzik And you're exactly right, I did it once or twice when introducing breaking changes that I recognized
11:21 vendethiel joined #perl6
11:22 [ptc] I don't know if it's possible to push just tags as a PR, however it'd be quite handy to use a Rakudo stack with panda all at the same version
11:23 [ptc] especially when trying to debug issues where the problem could be a Rakudo update, or a problem in the module/program being investigated
11:23 tadzik But panda doesn't have any specific release policy, if any :P People commit stuff that works quite often, and gods bless them for it, but there's not much attention given to backwards compatibility
11:23 tadzik Which I recognize as a problem and would like to change
11:24 andreoss could rakudo be shipped in binary by rakudobrew?
11:24 andreoss like it's done by rvm
11:24 tadzik If you'd like to take care of this issue, even if it's just this one time now, I'll happily provide you a commit bit :)
11:24 andreoss for rubies
11:25 [ptc] tadzik: ok, if you trust me with your repo :-)
11:25 [ptc] tadzik: I'll try my hardest not to break anything
11:25 tadzik [ptc]: don't break anything and don't touch bootstrap.pl and you'll be fine :)
11:25 * [ptc] grins
11:26 tadzik bootstrap.pl is hydras' nest
11:26 tadzik It's the reason why I wear glasses agaib
11:26 [ptc] tadzik: it's ok, I don't think bootstrap.pl is on the yak I'm currently trying to shave
11:26 tadzik What's your github username?
11:26 [ptc] tadzik: paultcochrane
11:27 tadzik oh, it's you! Then I totally trust you with the repo :)
11:29 [ptc] :-D
11:33 [ptc] mwaahaha
11:37 laouji joined #perl6
11:39 domidumont joined #perl6
11:42 telex joined #perl6
11:43 FROGGS[mobile] joined #perl6
11:47 * masak .oO( like "House of Cards" but for the panda repo ) :P
11:47 Ven joined #perl6
11:51 vendethiel o/,#perl6
11:54 masak \o
11:55 lizmat o/ vendethiel
12:12 Foxcool joined #perl6
12:26 Akagi201 joined #perl6
12:27 Akagi201_ joined #perl6
12:36 kaare_ joined #perl6
12:40 masak this is embarassing. the Haskell solution in http://blog.plover.com/prog/haskell/monad-search.html takes just under a second.
12:41 masak compare that with ~480 seconds for Perl 5 and ~1500 seconds for Perl 6.
12:41 masak can someone produce a *fast* solution, in either Perl 5 or Perl 6? my guess would be by removing all the recursion.
12:51 masak yeah, ok. I now have an iterative Perl 5 version that runs in 3.2 seconds.
12:51 masak but it highlights exactly the thing MJD is warning about. basically it sacrifices code elegance on the altar of performance.
12:54 Ven I'm guessing no tco is what's hurting here?
12:55 masak sounds possible to me, but I'm no expert on the internals of functional runtimes.
13:00 grondilu joined #perl6
13:02 masak corresponding Perl 6 iterative solution takes 429 seconds :/
13:12 masak added native int typing in strategic places. result 591 seconds :(
13:13 masak (yes, adding native types made it go slower)
13:23 laouji joined #perl6
13:28 btyler masak: did you apply TCO to the recursive perl 5 version? (e.g. goto &subname in tail call position)
13:29 masak no! good idea. I'll try that.
13:29 masak so far I've managed to get a Perl 6 version with while loops run in 324 seconds.
13:31 btyler goto &sub in perl5 is probably still not anywhere near the iterative version, since sub calls tend to be rather slow (when we're talking about 'slow' in the context of no IO happening)
13:31 yqt joined #perl6
13:32 ggoebel joined #perl6
13:35 masak hm, I don't think I can use `goto &NAME` in this program...
13:35 masak at least I don't see where it's applicable.
13:35 masak help appreciated.
13:38 chenryn joined #perl6
13:45 FROGGS[mobile] joined #perl6
13:47 masak ok, channel, I've got a puzzle for you.
13:47 masak https://gist.github.com/masak/ec8be246f58a1cc77be3
13:47 masak see line 10 of the output -- it should progress to 8 from 7, but it doesn't.
13:47 masak spot the error.
13:47 masak oh, argh!
13:47 masak never mind :P
13:48 masak (well, you can still spot the error -- but I just found it) :/
13:51 Akagi201 joined #perl6
13:53 Ven masak: `next ++$r` should work :P
13:54 masak ok, that optimization wasn't really worth it. (removing NEXT phasers and inlining the increments)
13:54 masak went from 324 seconds to 320 seconds.
13:55 Ven `my $money = :10[$m, $o, $n, $e, $y]` hahaha
13:55 masak isn't that a nice syntax? :)
13:55 * Ven still thinks of that Sufficiently smart compiler
14:01 masak similarly, removing the native typing from that script loses me 9 seconds. not worth quibbling about.
14:20 mchristo joined #perl6
14:21 masak wait, hm. what's the difference between <{ code }> and { code } inside the regex slang again?
14:21 * masak has a temporary brain lapse and can't remember
14:22 masak m: say "foo" ~~ / { say "oh hai" } foo /
14:22 camelia rakudo-moar 8bff46: OUTPUT«oh hai␤「foo」␤»
14:22 masak m: say "foo" ~~ / <{ say "oh hai" }> foo /
14:22 camelia rakudo-moar 8bff46: OUTPUT«oh hai␤oh hai␤oh hai␤oh hai␤Nil␤»
14:22 masak ok, at least they are different ;)
14:23 masak oh! <{ code }> means the code produces a regex that's evaluated. got it.
14:27 colomon joined #perl6
14:34 rmgk joined #perl6
14:35 beastd joined #perl6
14:37 skids joined #perl6
14:39 mchristo left #perl6
14:42 kst joined #perl6
14:49 smls What's the Perl 6 equivalent of 'readlink' (getting the target path of a symbolic link)?
14:49 masak m: "" ~~ m/ { say 1 } <{ say 2; "<?>" }> { say 3 } /
14:49 camelia rakudo-moar 8bff46: OUTPUT«1␤2␤3␤»
14:50 colomon joined #perl6
14:50 masak smls: S16 talks about readlink
14:50 masak (but I don't know how up-to-date that information is)
14:52 chenryn joined #perl6
14:54 moritz smls: it seems IO::Path.resolve is the only place in rakudo that calls nqp::readlink
14:54 smls .resolve seems to work
14:55 Khisanth joined #perl6
14:56 andreoss joined #perl6
14:56 andreoss »» is two times slower than map
14:57 smls http://doc.perl6.org/type/IO#sub_dd -- I didn't know dd was officially part of Perl 6? I saw it in Rakudo sources once, but thought it was just an internal debug helper.
14:58 molaf joined #perl6
15:00 espadrine joined #perl6
15:00 TimToady andreoss: try Xop
15:03 colomon joined #perl6
15:05 andreoss TimToady: 3 times slower than map
15:07 chenryn joined #perl6
15:07 koo6 joined #perl6
15:07 khisanth_ joined #perl6
15:07 * TimToady offline till evening...trying to go through Yosemite again...
15:07 Klaudioh joined #perl6
15:08 laouji joined #perl6
15:18 chenryn joined #perl6
15:19 molaf_ joined #perl6
15:22 atweiden joined #perl6
15:26 Ben_Goldberg joined #perl6
15:26 vendethiel joined #perl6
15:30 mr-foobar joined #perl6
15:32 dalek roast: 7539180 | usev6++ | S12-methods/syntax.t:
15:32 dalek roast: Add tests for RT #67700, use that ticket number
15:32 dalek roast: review: https://github.com/perl6/roast/commit/753918011e
15:37 andreoss why .map is exactly 2 times faster »» and 3 times faster X?
15:38 nwc10 andreoss: I have no idea, but if no-one else does, could you submit your 3 test cases that demonstrate this as a bug report, because it sounds like somethign that could be done better.
15:41 egrep joined #perl6
15:42 AlexDaniel joined #perl6
15:42 AlexDaniel m: say 'foo'; #`{ say 'bar;
15:42 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/eXX2weIxiT␤Couldn't find terminator }␤at /tmp/eXX2weIxiT:1␤------> 3say 'foo'; #`{ say 'bar;7⏏5<EOL>␤    expecting any of:␤        horizontal whitespace␤        whitespace␤»
15:42 AlexDaniel what this "expecting any of" thing is about? What kind of whitespace?
15:42 andreoss what do i use for benchmarking?
15:43 nwc10 andreoss: if you're on Linux or Unix, time is probably good enough, if you can get an example that's over about .2s for the fastest
15:43 nwc10 because a factor of 2 or 3 should be obvious, even from time
15:44 andreoss i got GNU
15:44 andreoss i meant like Benchmark module
15:44 nwc10 ah OK. I'm not aware of a Perl 6 benchmark module
15:44 andreoss i found one,  but it looks poor with features
15:44 nwc10 I was thinking just use time, for total program execution
15:45 nwc10 and 3 programs, one for each construct
15:45 andreoss http://paste.debian.net/183389/
15:45 timotimo the hyper operators try to mix the order of execution around so that you don't rely on it being sequential
15:45 timotimo (as it can be parallelized in the future)
15:45 timotimo m: (^5)>>.say
15:45 camelia rakudo-moar 8bff46: OUTPUT«4␤2␤0␤3␤1␤»
15:45 tony-o_ https://github.com/tony-o/perl6-bench
15:45 timotimo that costs a little bit
15:46 virtualsue joined #perl6
15:46 nwc10 OK. as it might be obvious, I'm about at the limit of how I can help now, because I don't know enough about the implementation (at the Rakudo level)
15:46 tony-o_ andreoss: ^^bench module
15:47 Ven joined #perl6
15:47 timotimo the bench module is really about having a set of benchmarks that we can measure the compiler's progress with
15:48 andreoss tony-o_: it lacks timethese routine
15:48 timotimo so its focus is on running the same benchmarks against multiple rakudo versions and comparing those
15:48 tony-o_ that has a timethese routine
15:48 timotimo what you want is really a code-oriented thing
15:48 timotimo oh, wait, that's tony-o/perl6-bench, not japhb/perl6-bench
15:48 timotimo never mind
15:49 AlexDaniel so, does anybody have any idea about this "expecting whitespace" error message?
15:49 andreoss hmm, i was thinking about japhb/perl6-bench as well
15:50 timotimo AlexDaniel: that's about what the parser was looking for when it encountered the problem
15:50 tony-o_ even the readme has timethese example :-)
15:50 timotimo sometimes it's not very helpful, like in this case
15:50 moritz AlexDaniel: it's misleading
15:50 moritz it's looking for the end of the #^{ ... } embedded comment
15:50 moritz but, comments are parsed as whitespace, it seems
15:50 timotimo yes
15:50 timotimo well, at least it does say "Couldn't find terminator }"
15:51 moritz and so the message ends up quite confusing
15:52 dalek roast: e774e01 | usev6++ | S04-declarations/state.t:
15:52 dalek roast: Use existing ticket number RT #102994
15:52 dalek roast: review: https://github.com/perl6/roast/commit/e774e010ee
15:52 moritz this is something that TimToady++ occasionally improves (parse error messages)
15:53 AlexDaniel timotimo: well, same thing as with the undeclared variable error message which was fixed some time ago. Does anybody else pay any attention to the last part of the error messages? :D
15:53 itz2 joined #perl6
15:53 timotimo usually not :P
15:54 timotimo i mean: i usually do not
15:54 AlexDaniel another thing is that it does not really tell where was this comment opened
15:55 AlexDaniel at least it says which terminator it expected, yeah, but maybe it can tell the line number as well?
15:55 moritz AlexDaniel: it does: "at /tmp/eXX2weIxiT:1"
15:55 moritz the :1 is the line number
15:56 timotimo that's not the line number of where the comment was *opened*, or is it?
15:56 AlexDaniel no, it is the number of lines in the file
15:56 AlexDaniel I mean, the error pops up in the end of the file, so it tells the last line
15:57 AlexDaniel in other words, completely useless
15:57 moritz AlexDaniel: please open a bug report for that
15:57 moritz mailto:rakudobug@perl.org
15:57 AlexDaniel moritz: ok
15:57 AlexDaniel will do it right now
15:59 AlexDaniel and it seems like there is one more bug with multiline comments... but gonna report this one first
16:07 andreoss https://paste.debian.net/183396/
16:08 andreoss still looks strange
16:10 AlexDaniel does anybody else get this error thing when trying to access the bug tracker? https://rt.perl.org/Public/Search/Results.html?Query=Queue=%27perl6%27%20AND%20Status=%27new%27
16:10 AlexDaniel I mean, these links are on http://rakudo.org/tickets/
16:10 andreoss AlexDaniel: links are broken at rakudo.org
16:10 timotimo the "possible CSRF" thing?
16:10 andreoss rt.perl.org/Public
16:10 timotimo it's to be expected; i had contacted the perlbug admins about this a few years back and didn't get a response
16:11 moritz https://rt.perl.org/Public/Search/Results.html?Query=Queue%20=%20%27perl6%27%20AND%20%28Status%20=%20%27new%27%20OR%20Status%20=%20%27open%27%20OR%20Status%20=%20%27stalled%27%29
16:11 AlexDaniel ok, so https://rt.perl.org/Public/Bug/Display.html?id=125247
16:13 AlexDaniel m: #`〈「 test 〉
16:13 camelia rakudo-moar 8bff46: ( no output )
16:13 AlexDaniel does this make any sense??
16:13 timotimo why not?
16:14 moritz .uni 〈
16:14 timotimo i think it's just .u
16:14 moritz .u 〈
16:14 yoleaux U+2329 LEFT-POINTING ANGLE BRACKET [Ps] (〈)
16:14 moritz .u 〉
16:14 yoleaux U+232A RIGHT-POINTING ANGLE BRACKET [Pe] (〉)
16:15 timotimo oh, i see now
16:15 AlexDaniel it does not have to be uniode
16:15 AlexDaniel m: #`{[ test }
16:15 timotimo there's no space after that 〈
16:15 camelia rakudo-moar 8bff46: ( no output )
16:15 timotimo i think we intentionally only allow the same opening character to be repeated
16:15 moritz aye
16:15 andreoss m: #`{[ }test{ ]}
16:15 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/KbyA5cZHLv␤Unable to parse expression in subscript; couldn't find final '}' ␤at /tmp/KbyA5cZHLv:1␤------> 3#`{[ }test{ 7⏏5]}␤»
16:16 atweiden i see a new error in my code since updating to rakudo 2015.05:
16:16 AlexDaniel timotimo: oh really? http://tablets.perl6.org/tablet-2-basic-syntax.html#multi-line
16:16 atweiden "Cannot look up attributes in a type object"
16:16 atweiden all looks ok up until the line:
16:16 atweiden my Price %xe{Date} = (%dates_and_prices_from_file, %dates_and_prices);
16:16 atweiden # subset Price of Rat is export where * >= 0;
16:16 timotimo the tablets are not authoritative, the test suite is
16:16 atweiden could it be related to using the subset?
16:17 AlexDaniel timotimo: is there a test case for that particular thing? :)
16:18 timotimo S02-lexical-conventions/comments.t
16:18 timotimo it looks like we have to add tests that require ({ to not require }) at the end
16:21 atweiden what is strange is that i declare %dates_and_prices as:
16:21 atweiden my Price %dates_and_prices{Date};
16:21 atweiden this variable is populated without issue, and i receive no error until this line:
16:21 atweiden my Price %xe{Date} = (%dates_and_prices_from_file, %dates_and_prices);
16:22 AlexDaniel timotimo: so what should I do?
16:22 AlexDaniel or somebody will handle this?
16:22 AlexDaniel
16:27 jdv79 will it ever be easy to edit a pm file that's next to the pre-comp'ed onn?
16:27 yoleaux 24 May 2015 18:38Z <tony-o_> jdv79: i have 29s for parsing yahoo.com , it does seem excessive but it's quite possibly because the code was meant to get us by until we had libxml bindings (or if someone needed a PP parser)
16:27 jdv79 *one
16:27 jdv79 its fairly irritating to not be able to modify an installed module
16:28 timotimo we'll have that at some point
16:28 timotimo well, hopefully
16:28 jdv79 i tried adding the lib path with -I and it still doesn't wokr
16:29 timotimo right
16:29 timotimo i'm also wishing for a way to specify "please rebuild modules" for the perl6-debug-m binary, because that'd mean you can debug into those
16:29 jdv79 what triggers or elides the "Missing or wrong version of dependency" issue?
16:31 raydiak morning #perl6
16:33 timotimo jdv79: when you compile a module that depends on another module through a "use", that can cause that
16:34 timotimo otherwise, the core setting is depended on by pretty much everything
16:35 raydiak lizmat++ # protecting us from any more "".IO -induced tragedies :)
16:36 smls indeed
16:38 smls no need to emulate design mistakes of the POSIX shell ;)
16:38 AlexDaniel m: say < #`{ test } foo bar >.perl
16:38 camelia rakudo-moar 8bff46: OUTPUT«("#`\{", "test", "}", "foo", "bar")␤»
16:38 AlexDaniel ummm
16:39 jdv79 so what's the easiest way to edit an installed module?
16:40 timotimo edit it and panda install the new version :S
16:40 AlexDaniel so does it look ok? Really I expected "test" to be commented out
16:41 AlexDaniel maybe I have wrong expectations, I don't know
16:41 raydiak we can't just rm the compiled .moarvm version and hack on the source any more b/c of CUR changes or something?
16:41 timotimo hm, don't you want << >> for that behavior? i'm not sure
16:42 AlexDaniel m: say << #`{ test } foo bar >>.perl
16:42 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/hmio6OgM67␤Undeclared routine:␤    test used at line 1␤␤»
16:42 timotimo raydiak: i think the manifest will still refer to the moarvm file existing and it may err out? i'm not sure, i haven't tried that
16:42 timotimo oh, it decides to interpolate that instead of treating it as a comment?
16:42 raydiak timotimo: idk how it works now with all the changes in that area but it used to work when I tried it
16:43 AlexDaniel timotimo: seems so. Does not look quite right, yes?
16:43 raydiak well, it quotes it, which arguably, could be the right thing
16:43 diana_olhovik_ joined #perl6
16:43 AlexDaniel m: say << #`{ } foo bar >>.perl
16:43 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/T2Zw9kK2dZ:1␤("#`", (), "foo", "bar")␤»
16:44 raydiak now that...that I don't see much argument for :)
16:45 raydiak I guess it's doing the same as "{}"
16:45 raydiak m: say "{}"
16:45 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/JejRmc3JIk:1␤␤»
16:45 AlexDaniel m: say << #`{ say 'ok' } foo bar >>.perl
16:45 camelia rakudo-moar 8bff46: OUTPUT«ok␤("#`", "True", "foo", "bar")␤»
16:47 smls What's the recommended Perl 6 idiom for creating a class attribute that is calculated when first accessed (rather than on object initialization)?
16:47 smls e.g. because calculating its value is resource-intensive and it might potentially never be accessed
16:48 jdv79 timotimo: uh, that kinda sucks
16:49 raydiak AlexDaniel: but essentially, < > and « » are quoting constructs, and so I wouldn't necessarily expect comments to work in them any more than I would expect '#`[ comment ]' (in single quotes) to be a comment instead of a string
16:51 AlexDaniel raydiak: this actually makse sense
16:52 AlexDaniel m: say « { #`[ test ] } foo bar ».perl
16:52 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/DTzrd8Yo_o:1␤((), "foo", "bar")␤»
16:52 AlexDaniel ok, didn't work
16:52 RabidGravy joined #perl6
16:52 raydiak m: say « { #`[ test ] 42 } foo bar ».perl
16:52 camelia rakudo-moar 8bff46: OUTPUT«("42", "foo", "bar")␤»
16:53 araujo_ joined #perl6
16:55 AlexDaniel m: say « { Any.new } foo bar ».perl
16:55 camelia rakudo-moar 8bff46: OUTPUT«("Any<139648825715968>", "foo", "bar")␤»
16:55 raydiak m: say « { #`[ test ] } foo bar ».flat.perl
16:55 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/YSqiitFLUe:1␤("foo", "bar")␤»
16:56 raydiak m: say « { #`[ test ] } foo bar ».list.perl
16:56 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/_TcZNqQu4I:1␤((), "foo", "bar")␤»
16:56 raydiak ah right, it's always going to try to stringify first
16:56 araujo_ joined #perl6
16:57 raydiak m: say « { #`[ test ] '' } foo bar ».flat.perl
16:57 camelia rakudo-moar 8bff46: OUTPUT«("foo", "bar")␤»
16:57 AlexDaniel right
16:57 raydiak that's an easy way to write a comment, right? :)
16:58 raydiak best advice off the top of my head is to just not expect to be able to put comments in quotes
16:59 * moritz has never felt the urge before
17:02 tony-o_ timotimo: did that bench module not do anything that andreoss or you were looking for?
17:02 raydiak I can see how someone might look at < > as a way to put TTIAR b/c it kinda sorta is (just for a very limited variety of terms), which could lead to this expectation of its contents being parsed like code...though I haven't tried it personally either I don't think
17:03 zakharyas joined #perl6
17:03 timotimo tony-o_: i didn't even look at your bench module so far, sorry!
17:04 Ulti what's changed in Rakudo since this morning because it altered my runtime by a second for some tests which was a 15% gain in perf this morning then back to normal this afternoon...
17:05 raydiak m: say « abc{'xyz'} ».perl
17:05 camelia rakudo-moar 8bff46: OUTPUT«("abc", "xyz")␤»
17:05 raydiak ^ though I do wonder if that shouldn't be 1 element instead of 2
17:07 raydiak Ulti: https://github.com/rakudo/rakudo/commit/0f3400c2aef6e9610d0bf598b39d215b91082121 maybe?  barely-educated guess...
17:08 raydiak other than the empty path change, the only other commit in the last 20 hours is https://github.com/rakudo/rakudo/commit/d7c9bfa2a37c152603512d844ecfced888f152ba
17:09 itz2 joined #perl6
17:09 * raydiak also notices 1 moar commit half an hour ago
17:09 Ulti raydiak: perhaps though I havent explicitly put eager anywhere
17:11 raydiak Ulti: much difference in tempurature of the room you're in between morning and now?
17:11 Ulti the biggest perf increase I've seen in one go is jumping from my laptop form 2011 to a modern one 30% :'(
17:11 Ulti in a lot of ways I think Perl 6 couldn't have come out before now it would have just been too slow for older CPUs
17:12 Ulti raydiak heh nope
17:12 bartolin raydiak: but we had no bump for Moar/nqp, so commits to those repos should have no effect
17:12 raydiak good point bartolin
17:12 Ulti though might be a difference in RAM usage so might have been in swap just now
17:12 Ulti yeah possible
17:13 smls Is it good practice to use submethod BUILD to map constructor arguments to *private* attributes? As in:   class A { has $!x;  submethod BUILD(:$!x) { }  ...  };  A.new(x => ...)
17:13 smls http://doc.perl6.org/language/objects#Object_Construction  only refers to "public attributes" in that context.
17:13 * raydiak doesn't pay much attention to performance fluctuations on complex modern hardware and software unless it's well past a certain noise threshold and repeatable
17:15 Akagi201 joined #perl6
17:16 Ven joined #perl6
17:17 masak m: say « { #`[ test ] } foo bar ».flat.perl
17:17 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/2iQkQUmLob:1␤("foo", "bar")␤»
17:17 masak did someone submit this as a rakudobug?
17:17 raydiak masak: is it?
17:17 masak I'd say so.
17:17 masak why would Nil be involved in that one?
17:18 raydiak the empty { } returns Nil
17:18 masak oh, hm.
17:18 raydiak and the « » tries to .Str it before the .flat sees it
17:18 masak m: say « { #`[ test ] "OH HAI" } foo bar ».flat.perl
17:18 camelia rakudo-moar 8bff46: OUTPUT«("OH", "HAI", "foo", "bar")␤»
17:18 masak oh, ok.
17:18 masak nothing-to-see-here-move-along
17:19 raydiak I did the same thing :)
17:21 raydiak smls: S12 talks about it, pretty sure it's allowed and intended...specifically "Note that the default BUILD will only initialize public attributes; you must write your own BUILD (as above) in order to present private attributes as part of your initialization API."
17:21 smls ok
17:24 jdv79 so what's a fix for something like .for({"foo:$_"}) ?  with the Nil change now it tries to string the Nil
17:25 raydiak .flat.for
17:25 raydiak oh wait, does .flat still get rid of nil?
17:25 raydiak m: (1, Nil, 3).flat.for: *.say
17:25 camelia rakudo-moar 8bff46: OUTPUT«1␤Nil␤3␤Saw 1 occurrence of deprecated code.␤Method for (from Any) seen at:␤  /tmp/ENVRCACXgx, line 1␤Deprecated since v2015.5, will be removed with release v2015.9!␤Please use flatmap instead.␤»
17:26 * raydiak hopes someone a little morecurrent on GLR changes jumps in here :)
17:26 jdv79 the warning went away.  ok.
17:27 raydiak m: (1, Nil, 3).flatmap: *.say
17:27 camelia rakudo-moar 8bff46: OUTPUT«1␤Nil␤3␤»
17:28 raydiak m: sub foo () {}; say foo().perl
17:28 camelia rakudo-moar 8bff46: OUTPUT«Nil␤»
17:29 * raydiak kinda wonders if that shouldn't be () now, since Nil doesn't flatten away
17:29 raydiak m: say (1, Nil, 3).grep(*.defined).flatmap: {"foo:$_"}
17:29 camelia rakudo-moar 8bff46: OUTPUT«foo:1 foo:3␤»
17:32 Mouq m: (1, Empty, 3).flatmap: *.say
17:32 camelia rakudo-moar 8bff46: OUTPUT«1␤3␤»
17:33 raydiak jdv79: the cleanest soltuion might be to look at where your Nil is coming from and make that thing return Empty or () instead
17:34 raydiak oh and...OHAI MOUQ!!!!11 :)
17:34 raydiak barely missed you dropping in yesterday, glad to see you around
17:34 timotimo yup, ohai Mouq :)
17:34 timotimo nice to see you're back
17:35 Mouq ohaii! (づ。◕‿‿◕。)づ
17:37 raydiak working on anything cool yet?  or still re-orienting yourself?
17:38 Mouq Heh, nothing yet. Still trying to figure out what hasn't already been done :P
17:39 tony-o_ is there a mechanism when i 'require' a file to figure out what it imported?
17:39 tony-o_ or what could be imported from the file
17:39 Mouq m: say "N̴͔̈F̷͚́G̶͔̈́ ̷̃͜i̴̡͘s̴̰͘ ̶̫̉a̵̬͆w̴̢͒ę̴̏s̴̱̋o̴̫̓m̸̜͐e̶̥̋".chars
17:39 camelia rakudo-moar 8bff46: OUTPUT«14␤»
17:40 jdv79 .tell tony-o yeah, its not deprecations or warnings - its just too slow:(
17:40 yoleaux jdv79: I'll pass your message to tony-o.
17:42 tony-o_ jdv79: yea it is slow
17:43 FROGGS joined #perl6
17:43 raydiak tony-o_: I don't think any such thing exists unless you count README
17:44 itz2 joined #perl6
17:45 grondilu "N̴͔̈F̷͚́G̶͔̈́ ̷̃͜i̴̡͘s̴̰͘ ̶̫̉a̵̬͆w̴̢͒ę̴̏s̴̱̋o̴̫̓m̸̜͐e̶̥̋ " wth
17:45 tony-o_ lol
17:46 raydiak m: say "NFG is awęsome".graphs
17:46 camelia rakudo-moar 8bff46: OUTPUT«Method 'graphs' not found for invocant of class 'Str'␤  in block <unit> at /tmp/y65HIqzMwL:1␤  in any <unit-outer> at /tmp/y65HIqzMwL:1␤␤»
17:47 grondilu weirdly enough Mouq had put diacritics on the last C<"> and yet it parsed fine.
17:47 grondilu m: say "N̴͔̈F̷͚́G̶͔̈́ ̷̃͜i̴̡͘s̴̰͘ ̶̫̉a̵̬͆w̴̢͒ę̴̏s̴̱̋o̴̫̓m̸̜͐e̶̥̋"
17:47 camelia rakudo-moar 8bff46: OUTPUT«N̴͔̈F̷͚́G̶͔̈́ ̷̃͜i̴̡͘s̴̰͘ ̶̫̉a̵̬͆w̴̢͒ę̴̏s̴̱̋o̴̫̓m̸̜͐e̶̥̋␤»
17:47 raydiak m: say "NFG is awęsome".codes
17:47 camelia rakudo-moar 8bff46: OUTPUT«14␤»
17:47 FROGGS m: say "N̴͔̈F̷͚́G̶͔̈́ ̷̃͜i̴̡͘s̴̰͘ ̶̫̉a̵̬͆w̴̢͒ę̴̏s̴̱̋o̴̫̓m̸̜͐e̶̥̋".NFD
17:47 camelia rakudo-moar 8bff46: OUTPUT«(signal SEGV)»
17:47 * Mouq just copypasted from http://lunicode.com/creepify
17:47 FROGGS ó.ò
17:48 geekosaur I see no diacritic on either of the quotes, fwiw
17:48 geekosaur but rendering errors are unfortunately very common
17:48 Mouq geekosaur: It appears that way to me when I look at the IR clog
17:49 tony-o_ raydiak: is it possible to realias any symbols in the file?
17:51 tony-o_ from the docs it might look like i could do ::('WHATEVER'):file('some file')  and then later do ::('WHATEVER').new ..
17:51 raydiak tony-o_: yes S11 talks all about it (though idk how much is implemented or not, haven't tried it myself)
17:52 Mouq m: say "ó.ò".NFD
17:52 camelia rakudo-moar 8bff46: OUTPUT«NFD:0x<006f 0301 002e 006f 0300>␤»
17:54 raydiak tony-o_: something about that looks confusing to me, but I don't really know these parts very well
17:57 tony-o_ trying to figure out how to autoload files and then create a new object without actually knowing the symbol names declared in the file, it's making the assumption there is only 1 symbol (a class)
18:01 smls Yet again, I trip over the fact that   ~~ s///  is mutating... :S
18:01 masak then use .subst
18:01 smls Whatever initial familiarity advantage it brings for people with a Perl 5 background (of which I am one), is IMO outweighed by how unexpected (and thus easy to forget) it feels *within* the context of Perl 6.
18:01 smls subst is less pretty :P
18:01 FROGGS masak: I RT'd the segfault btw...
18:02 masak FROGGS++
18:03 masak smls: "I'm using construct X and expecting it to work like Y, and I don't want to use Y because it's less pretty" -- I tend to use constructs for their effects, not their beauty :P
18:03 smls well, s/pretty/convenient or elegant/
18:03 masak I disagree. .subst is pretty darn convenient.
18:04 tony-o_ i have .subst all over the place
18:06 smls how do I even backreference in .subst
18:06 tony-o_ i like it, although i get smls' point - it's caused me a headache on a few occassions (where i meant .substr, though)
18:06 smls m: say "abcde".subst(/c(.)/, "$0")
18:06 camelia rakudo-moar 8bff46: OUTPUT«Use of Nil in string context  in block <unit> at /tmp/V13Sb4MG_o:1␤abe␤»
18:06 smls m: my $x = "abcde"; $x ~~ s/c(.)/$0/; say $x  # this works
18:06 camelia rakudo-moar 8bff46: OUTPUT«abde␤»
18:06 FROGGS m: say "abcde".subst(/c(.)/, { "$0" })
18:06 camelia rakudo-moar 8bff46: OUTPUT«abde␤»
18:06 tony-o_ m: say 'abcde'.subst/ 'c'(.)/$0/;
18:06 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/5BSxdprgCH␤Unsupported use of . to concatenate strings; in Perl 6 please use ~␤at /tmp/5BSxdprgCH:1␤------> 3say 'abcde'.subst/ 'c'(.)7⏏5/$0/;␤»
18:07 tony-o_ m: say 'abcde'.subst(/ 'c'(.)/$0/);
18:07 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/ZG7e0iVbfG␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/ZG7e0iVbfG:1␤------> 3say 'abcde'.subst(/ 'c'(.)/7⏏5$0/);␤    expecting any of:␤        infix␤        i…»
18:07 tony-o_ gah
18:07 tony-o_ gonna go ride my bike
18:07 smls FROGGS: thanks
18:07 smls though the extra set of braces make it even *more* unwieldy compared to s///
18:08 Mouq m: say "abcde".subst(/c(.)/, *[0])
18:08 camelia rakudo-moar 8bff46: OUTPUT«abde␤»
18:08 smls :P  well, in the general case the  backreference would be embedded in a larger substitution string
18:08 smls like in FROGGS solution
18:09 Mouq Yeah :9
18:10 masak mini-mini-challenge: what's the fastest way (in Perl 6) to do "elements from @a but not from @b"? answers in terms of benchmarks, kplz.
18:11 smls or, coming at it from another angle: Does anyone think that mutating replacement is useful more ofhten than non-mutating replacement in *Perl 6* code (where functional call chains are everywhere)?
18:11 smls If not, it means s/// is incorrectly huffmanized (and I think so)
18:12 masak m: my @a = 1..10; my @b = 3, 5, 6, 7; for ^100 { my @diff = @a.grep({ $_ == none(@b) }) }; say now - INIT now
18:12 camelia rakudo-moar 8bff46: OUTPUT«0.3916099␤»
18:12 masak about the same as I got locally.
18:12 masak can someone improve on that?
18:14 tony-o_ time wise?
18:14 masak yes.
18:14 smls masak:  did you try    @a (^) @b    ?
18:14 smls wait, that's wrong
18:14 masak m: my @a = 1..10; my @b = 3, 5, 6, 7; for ^100 { my %b = @b X=> 1; my @diff = @a.grep({ !%b{$_} }) }; say now - INIT now
18:14 camelia rakudo-moar 8bff46: OUTPUT«0.19906606␤»
18:14 masak ah, better.
18:15 masak this is the new record, using X=> and a hash :)
18:15 smls @a (-) @b
18:16 masak m: my @a = 1..10; my @b = 3, 5, 6, 7; for ^100 { my @diff = (@a (-) @b).list }; say now - INIT now
18:16 camelia rakudo-moar 8bff46: OUTPUT«0.1943261␤»
18:17 masak oh, that comes out about even, and is nicer :)
18:17 masak smls++
18:19 * raydiak is happy to see that the native int loop(;;) version doesn't really help noticably
18:21 Mouq m: my @a = 1..10000; my @b = 3, 5 ... 10001; my $start = now; my @diff = (@a (-) @b).list; say now - $start
18:21 camelia rakudo-moar 8bff46: OUTPUT«0.4033688␤»
18:21 Mouq m: my @a = 1..10000; my @b = 3, 5 ... 10001; my $start = now; my %b = @b X=> 1; my @diff = @a.grep({ !%b{$_} }); say now - $start
18:21 camelia rakudo-moar 8bff46: OUTPUT«0.7740584␤»
18:21 Mouq ^^ Wow
18:22 Mouq I tend to expect Sets to be slow
18:23 Mouq Oh, hm
18:23 Mouq m: my @a = 1..10000; my @b = 3, 5 ... 1001; my $start = now; my @diff = (@a (-) @b).list; say now - $start
18:23 camelia rakudo-moar 8bff46: OUTPUT«0.33197263␤»
18:24 Mouq m: my @a = 1..10000; my @b = 3, 5 ... 1001; my $start = now; my %b = @b X=> 1; my @diff = @a.grep({ !%b{$_} }); say now - $start
18:24 camelia rakudo-moar 8bff46: OUTPUT«0.1494794␤»
18:38 dalek roast: 2283c88 | usev6++ | S04-statements/gather.t:
18:38 dalek roast: Add test for RT #122114
18:38 dalek roast: review: https://github.com/perl6/roast/commit/2283c88fd3
18:49 mr-foobar joined #perl6
19:06 [Sno] joined #perl6
19:06 firecat joined #perl6
19:08 spider-mario joined #perl6
19:10 yqt joined #perl6
19:10 yqt joined #perl6
19:14 grondilu m: my @a = 1..10000; my @b = 3, 5 ... 1001; my $start = now; my %b = @b X=> 1; my @diff =
19:14 camelia rakudo-moar 8bff46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/9jfA9N5Weu␤Malformed initializer␤at /tmp/9jfA9N5Weu:1␤------> 3tart = now; my %b = @b X=> 1; my @diff =7⏏5<EOL>␤    expecting any of:␤        prefix␤        term␤»
19:14 grondilu m: my @a = 1..10000; my @b = 3, 5 ... 1001; my $start = now; my %b = @b X=> 1; my @diff = grep none(@b), @a; say now - $start
19:14 camelia rakudo-moar 8bff46: OUTPUT«16.2177687␤»
19:16 smls S16 recommends   temp $*CWD = chdir($dir)   for using a different working directory for one scope. Why is it not simply   temp $*CWD = $dir   instead?
19:16 smls Considering that chdir's job is merely to set $*CWD
19:18 dalek roast: 2c662e9 | usev6++ | S04-declarations/our.t:
19:18 dalek roast: Use existing ticket number RT #76450
19:18 dalek roast: review: https://github.com/perl6/roast/commit/2c662e9e35
19:22 ugexe maybe chdir($dir) wont let you set $*CWD to non-existant directory?
19:24 ugexe also may have to do with the binding involved
19:27 smls maybe $*CWD should have that logic built into its container?
19:28 smls could make the  chdir, homedir, tmpdir  functions redundant
19:28 raiph joined #perl6
19:29 smls (the latter two are not very intuitively named as setters, anyway)
19:30 itz2 joined #perl6
19:30 smls Scalar's already have support for running code on each assignment, right?
19:31 lizmat smls: I've considered just assigning $*CWD would be ok
19:31 lizmat *and* adding logic for checking validity of dir
19:32 lizmat that still wouldn't stop you from doing my $*CWD = "foo" and bypass everything
19:32 smls but why would you?
19:33 smls I mean, one could do that now too, right?
19:33 lizmat yes...
19:34 smls Would  temp $*CWD = $dir  work, or does temp create its own container?
19:34 lizmat not sure
19:35 smls If that would work, I don't see the downside compared to the current situation.
19:41 diana_olhovik_ joined #perl6
19:43 smls It would also mirror Perl 6's custom of assigning to object attributes instead of having setter methods like in Perl 5, so it wouldn't be anything unheard of really.
19:45 Ven joined #perl6
19:48 ugexe but normally dont you really want to do my $CWD := $*CWD
19:49 ugexe you cant do temp $var :=
19:51 dalek roast: 5bd323a | usev6++ | S06-multi/type-based.t:
19:51 dalek roast: Fix and unfudge test for RT #65674
19:51 dalek roast:
19:51 dalek roast: also use existing ticket number and rewrite one
19:51 dalek roast: occurrence of 'dies-ok' to 'throws-like'
19:51 dalek roast: review: https://github.com/perl6/roast/commit/5bd323a576
19:52 dalek rakudo/nom: 8693063 | lizmat++ | src/core/ListIter.pm:
19:52 dalek rakudo/nom: Fix various issues with typed hashes
19:52 dalek rakudo/nom:
19:52 dalek rakudo/nom: This is *really* a bandaid to prevent the actual error from occurring.  This
19:52 dalek rakudo/nom: is *not* to be considered a solution to a potentially deeper problem.  Since
19:52 dalek rakudo/nom: this will probably change during the course of the GLR, I thought bandaiding
19:52 dalek rakudo/nom: this would be a good temporary solution.
19:52 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/869306336f
19:52 ugexe i agree though, as id much rather write temp $*CWD = $dir
19:52 smls ugexe: What do you mean? Why would you want to bind $*CWD to a lexical?
19:53 lizmat One should realize that chdir() comes from an age where it would actually change the underlying cwd()
19:53 lizmat that changed about 2 years ago, when JVM became a backend
19:53 smls interesting :)
19:53 ugexe well on jvm if you dont bind $*CWD things break
19:54 lizmat so yes, perhaps we should just get rid of chdir
19:54 lizmat (after a deprecation cycle of course)
19:56 smls ugexe: I woudn't know anything about that. But it shouldn't matter, should it? Even if $*CWD becomes a "magic" Scalar it could still be bound like any other, right?
19:57 smls lizmat: And homedir/tmpdir too, right?
19:57 lizmat yep
19:57 lizmat apparently my latest commit fixes #125148
19:57 masak +1 to getting rid of chdir
20:01 dalek roast: 48fb065 | lizmat++ | S32-list/classify.t:
20:01 dalek roast: RT #125148 is fixed, as possible others
20:01 dalek roast: review: https://github.com/perl6/roast/commit/48fb065cf3
20:03 smls m: my @a; { temp @a[5] = 42; say @a[5] }; say @a[5]
20:03 camelia rakudo-moar 8bff46: OUTPUT«42␤(Any)␤»
20:03 smls ^^ looks like temp does just fine with magic Scalars
20:05 lizmat Ah, I remember why I wanted to keep chdir around:
20:05 lizmat things are made much easier if dirs have a / appended
20:05 lizmat direct assignment wouldn't enforce that
20:06 smls couldn't it silently add it?
20:06 lizmat wel...  perhaps...
20:06 smls Also: Torture the lizmats on behalf of the smlss :D
20:07 lizmat hehe
20:09 * masak is doing Cool Stuff™ to blog about
20:18 japhb ++masak
20:18 yoleaux 24 May 2015 19:38Z <tony-o_> japhb: i have these hilights in irssi doing what you're looking for, they could be improved but they work well enough (and you're right, it cleans up the channel quite a bit): https://gist.github.com/tony-o/968491d6430de41b3ae2
20:18 dalek Heuristic branch merge: pushed 164 commits to roast/newio by lizmat
20:19 Ven masak++ # more blag
20:19 masak almost done.
20:24 * lizmat hopes timotimo will have time this week
20:24 lizmat looks like 869306336fadd85320bfc1 also fixed #125242
20:25 bartolin lizmat++
20:26 dalek specs/newio: 4932a71 | moritz++ | S32-setting-library/Basics.pod:
20:26 dalek specs/newio: Correct signature, cognominal++
20:26 dalek specs/newio:
20:26 dalek specs/newio: also remove a redundant multi
20:26 dalek specs/newio: review: https://github.com/perl6/specs/commit/4932a71206
20:26 dalek specs/newio: 22fa8cd | lizmat++ | S32-setting-library/Basics.pod:
20:26 dalek specs/newio: Merge branch 'master' into newio
20:26 dalek specs/newio: review: https://github.com/perl6/specs/commit/22fa8cd3a2
20:28 kurahaupo1 joined #perl6
20:33 timotimo hurm
20:34 timotimo lizmat: i think i really ought to ask for backup this week
20:34 lizmat ok, I'll do it then, ok ?
20:36 lizmat timotimo: or do you have another backup in mind?
20:39 dalek roast: ac62893 | usev6++ | S04-declarations/my.t:
20:39 dalek roast: Fix and unfudge test for RT #125068
20:39 dalek roast:
20:39 dalek roast: direct lookup of 'our sub' needs sigil '&'
20:39 dalek roast: review: https://github.com/perl6/roast/commit/ac628936cc
20:40 timotimo you're free to do it or find someone else :)
20:41 lizmat ok, will start on it in a min
20:41 timotimo no need to do it today, FWIW
20:41 lizmat I'll start on it, didn't say I would finish it today  :-)
20:41 Ven lizmat++ # whichever option
20:41 timotimo fair enough :)
20:41 Peter_R joined #perl6
20:42 kurahaupo1 joined #perl6
20:44 skids m: my $*guard = 0; grammar Foo { regex TOP { [a | [ "[" <R> b? "]" ]]+ % b { die if $*guard++ > 500 } }; regex b { b }; regex R { <TOP>+ % [ <.b>? "/" ] } }; Foo.parse("[aba]").say; Foo.parse("[abab]").say;
20:44 camelia rakudo-moar 869306: OUTPUT«「[aba]」␤ R => 「aba」␤  TOP => 「aba」␤Died␤  in regex TOP at /tmp/8iN9r23p25:1␤  in regex R at /tmp/8iN9r23p25:1␤  in regex TOP at /tmp/8iN9r23p25:1␤  in block <unit> at /tmp/8iN9r23p25:1␤  in any <unit-outer> at /tmp/8iN9r23p25:1…»
20:44 skids star: my $*guard = 0; grammar Foo { regex TOP { [a | [ "[" <R> b? "]" ]]+ % b { die if $*guard++ > 500 } }; regex b { b }; regex R { <TOP>+ % [ <.b>? "/" ] } }; Foo.parse("[aba]").say; Foo.parse("[abab]").say;
20:44 camelia star-m 2015.03: OUTPUT«「[aba]」␤ R => 「aba」␤  TOP => 「aba」␤「[abab]」␤ R => 「aba」␤  TOP => 「aba」␤»
20:44 skids m: my $*guard = 0; grammar Foo { regex TOP { [a | [ "[" <R> b? "]" ]]+ % b { die if $*guard++ > 500 } }; regex b { b }; regex R { <TOP>+ % [ <b>? "/" ] } }; Foo.parse("[aba]").say; Foo.parse("[abab]").say;
20:44 camelia rakudo-moar 869306: OUTPUT«「[aba]」␤ R => 「aba」␤  TOP => 「aba」␤「[abab]」␤ R => 「aba」␤  TOP => 「aba」␤»
20:45 skids recent change of some sort ^^
20:45 virtualsue joined #perl6
20:48 masak .u ∖
20:48 yoleaux U+2216 SET MINUS [Sm] (∖)
20:49 dalek rakudo/nom: d5eabd4 | lizmat++ | src/core/Range.pm:
20:49 dalek rakudo/nom: Cleanup on Range.pick/roll
20:49 dalek rakudo/nom:
20:49 dalek rakudo/nom: Specifically, (^10e6).pick/roll should be much faster now, as it will not
20:49 dalek rakudo/nom: build the entire list before pick/rolling (it did before).  So in that case,
20:49 dalek rakudo/nom: it's several orders of magnitude faster.  This is at the expense of a small
20:49 dalek rakudo/nom: slowdown for the (^10000000).pick/roll case.
20:49 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d5eabd4158
20:49 lizmat that should make smls happy
20:50 telex joined #perl6
20:56 lizmat .tell atweiden re http://irclog.perlgeek.de/perl6/2015-05-25#i_10653322 problem was fixed with 8693063
20:56 yoleaux lizmat: I'll pass your message to atweiden.
20:59 lizmat .tell smls re http://irclog.perlgeek.de/perl6/2015-05-25#i_10653489 assuming you mean instance attribute: has $!a; method a { $!a //= init code }
20:59 yoleaux lizmat: I'll pass your message to smls.
21:00 Ven masak++ # blog post
21:00 timotimo have you ever wondered about the difference in factor between our-variable-lookup and my-variable-lookup?
21:00 Ven ( why yes, I saw that commit instantly ;-). )
21:00 timotimo timo@schmetterling ~> time perl6 -e 'my $a; for ^100_00_000 { $a++ }'
21:00 masak it's not up yet :)
21:00 timotimo 4.64user 0.01system 0:04.66elapsed 99%CPU (0avgtext+0avgdata 61308maxresident)k
21:00 timotimo timo@schmetterling ~> time perl6 -e 'for ^100_00_000 { $a++ }'
21:00 timotimo 188.12user 0.02system 3:08.23elapsed 99%CPU (0avgtext+0avgdata 87296maxresident)k
21:02 Ven .u ∖
21:02 yoleaux U+2216 SET MINUS [Sm] (∖)
21:02 timotimo since we emit a our-scoped lookup whenever you use the "variables implicitly defined" semantic you get from "no strict", we may want to have an optimization for that somewhere
21:02 masak lol! http://strangelyconsistent.org/blog/send-more-money-in-perl6 -- I blogged!
21:02 masak \o/
21:02 Ven masak: https://github.com/masak/strangelyconsistent-blog-posts/commit/b11d205329b3ff09786ab17a139f706c844d4843#diff-d1fd895358e4475c1de2ada6152b9f2dR172 does this display correctly for you?
21:03 masak Ven: yes.
21:03 Ven oh :o)
21:06 masak anyway -- been harboring this blog post inside of me for over a week. nice to finally have it out there.
21:06 Ven ws a nice read indeed.
21:06 Ven makes me wonder how to write a "backcall" in perl6
21:07 Ven (i.e. takes the rest of the block as a closure)
21:07 masak oh, is that a LiveScript term?
21:07 Ben_Goldberg joined #perl6
21:08 Ven masak: yes :P
21:08 masak anyway, yes, what I'm talking about near the end is basically the parsing/AST-level version of a backcall.
21:08 Ven (well, it's a coco one, but we use it)
21:08 raiph joined #perl6
21:19 Mouq masak: Would you mind running solution 1 with this Rakudo patch: https://gist.github.com/Mouq/e6ab6ff6acbfbc6dd032 and comparing the times?
21:20 masak Mouq: sure thing. give me a few minutes.
21:21 Mouq masak: I'm pretty sure it'll be slower, since it seems to improve (-) in all cases *except* where subtrahend << subtractors
21:22 Mouq masak: But… idk. Actually, in that case, maybe it isn't wothwhile running unless you have a shorter testcase
21:23 Mouq It seems like there should be a better way to merge sets than Set.new(eager @p.map(*.Set(:view).keys)), which is what makes this version (-) take longer if the subtractors are very large
21:23 Mouq *of (-)
21:23 Mouq and s/merge sets/merge objects into a single set/
21:23 masak I think the biggest reason version A is slower than version B is the for loops, though.
21:24 lizmat yeah, GLR should fix that :-)
21:24 lizmat it's a nice test case
21:24 lizmat I would say that as a goal, that piece of code should run like in 1:30 tops post YAPC::NA  :-)
21:29 * lizmat continues to work on the P6W tomorrow
21:29 colomon joined #perl6
21:29 lizmat good night, #perl6!
21:30 timotimo gnite lizmat!
21:30 Ulti seriously can we get rid of the comments on http://rakudo.org/how-to-get-rakudo/
21:30 Ulti can I get access to clean up rakudo.org if no one else wants to
21:31 Ulti there is a .deb and has been for ages, not that anyone should use it
21:32 Ulti as far as anyone knows landing on that page it hasn't changed since 2011
21:33 masak Ulti++ # reminding us about those comments
21:36 Zoffix joined #perl6
21:41 mohij joined #perl6
21:51 cygx joined #perl6
21:51 cygx o/
21:51 masak \o
21:52 cygx is it a windows problem that Rakudo does not respect \r when printing to stdout, or a general issue?
21:52 timotimo "does not respect \r"?
21:52 cygx timotimo: prints newlines instead of returning to the beginning of the line
21:53 timotimo all i know is windows does strange things with its newline
21:53 timotimo newlines
21:53 masak Windows has \r\n newlines.
21:53 cygx sure
21:54 cygx try to run -e 'print "$_\r" for 0..100000'
21:54 cygx run it with perl and perl6 and see if there's a difference
21:57 cygx masak: is it deliberate that you don't use loop(;;) in Version B?
21:58 masak cygx: oh! that would indeed have been better.
21:58 masak cygx: if you rewrite it in that style, I'm willing to replace Version B and credit you.
22:00 cygx masak: also, why is $s == 0 excluded from the get-go?
22:00 masak because of the nature of the problem.
22:00 masak if a letter occurs to the far left in the sum, it can't be 0.
22:03 cygx masak: https://gist.github.com/cygx/1e010facd65ddeb1065c
22:03 cygx haven't done a full run yet, though
22:04 masak nice! that does look better :)
22:05 masak hm, putting those three lexicals up top feels like a matter of taste... but I'm not going to fight you on that. :)
22:10 cygx masak: feel free to change the declarations if you prefer the original version
22:11 masak ah, kept it.
22:11 masak nah*
22:11 masak new version is up: http://strangelyconsistent.org/blog/send-more-money-in-perl6
22:11 masak cygx++
22:13 cygx masak: does my version still run in ~5 minutes on your machine?
22:13 masak lemme check.
22:14 dalek ecosystem: 07dd589 | tony-o++ | META.list:
22:14 dalek ecosystem: Simple routing mechanism for HTTP::Server::Threaded
22:14 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/07dd58920e
22:14 cygx it's taking quite a while over here
22:19 cygx time's up
22:19 cygx I wonder if it's the loops or the anys...
22:20 masak oh no, you introduced anys? :(
22:20 masak I didn't even see that
22:20 masak of course it's the anys :P
22:20 masak please fix and resubmit...
22:20 cygx so, the optimizer is not sufficiently smart yet...
22:22 timotimo masak: i expect the performance of that program would be much better in a version of rakudo that still does block inlining
22:22 masak possibly.
22:23 timotimo does --profile give something interesting?
22:24 masak no idea.
22:24 timotimo i guess i'll run that quickly
22:24 masak gah, I should've tested the new version before I updated the post... :)
22:24 timotimo uh oh, it doesn't run yet?
22:24 cygx don't trust code from random people on the internet ;)
22:25 masak timotimo: it's far slower.
22:25 colomon masak: did you look at the Yapsi thing?
22:25 cygx masak: https://gist.github.com/cygx/1e010facd65ddeb1065c#file-money2-p6
22:26 cygx it's still running, so no idea yet how slow it is...
22:26 masak colomon: no... and I seem to have forgotten what that was, too... :/
22:26 masak cygx: I'm running a fixed version here, too.
22:26 colomon masak: it hangs during tests now.  (Or at least, it did over the weekend.)
22:26 masak colomon: oh, right.
22:26 cygx masak: ups... forgot an any :(
22:26 masak colomon: I'll try to have a look tomorrow.
22:27 masak cygx: I didn't, so I'll get results first here :)
22:27 colomon masak: at least you’ve inspired me to work on improved facilities for skipping modules in the smoke test.  ;)
22:27 masak heh ;(
22:28 colomon masak: it’s not just you.
22:30 masak 5m17.805s
22:30 colomon basically, the smoke test has only successfully complete 14 times in the last month.
22:30 colomon *completed
22:31 colomon I think only the last six days are attributable to Yapsi.
22:31 cygx so comparable to the while variant
22:31 timotimo oh
22:31 timotimo you're using any(...)
22:32 masak not anymore.
22:32 masak uploading a new version now.
22:33 cygx masak++
22:35 timotimo using | used to be super fast; isn't any more, but the optimization can make a come-back still
22:40 vendethiel joined #perl6
22:46 masak cygx: I see your latest version puts the declarations back inside the loop. I'm going to borrow that back in...
22:46 masak cygx: ...but not the changed loop ranges, which assumes too much cleverness on the part of the code gen.
22:48 atweiden joined #perl6
22:51 cygx m: say [|] <1 2 3>
22:51 camelia rakudo-moar d5eabd: OUTPUT«any(1, 2, 3)␤»
22:52 masak m: say [\|] <1 2 3>
22:52 camelia rakudo-moar d5eabd: OUTPUT«any(1) any(1, 2) any(1, 2, 3)␤»
22:52 dalek rakudo-star-daily: 966b9b2 | coke++ | log/ (6 files):
22:52 dalek rakudo-star-daily: today (automated commit)
22:52 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/966b9b26c9
22:52 dalek perl6-roast-data: 05ec117 | coke++ | / (9 files):
22:52 dalek perl6-roast-data: today (automated commit)
22:52 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/05ec1173b8
22:54 atweiden is there a better way to have a line like this in a parser's Actions.pm:
22:54 yoleaux 20:56Z <lizmat> atweiden: re http://irclog.perlgeek.de/perl6/2015-05-25#i_10653322 problem was fixed with 8693063
22:54 atweiden my Str $eol_comment = try {substr($<eol_comment>, 1, *-0).trim} // Nil;
22:54 atweiden as i am seeing lots of warnings "Use of Nil in string context"
22:55 cygx the list of 'interesting' operators I've used in code now includes [|] ^..^ <<=><<
22:56 dwarring joined #perl6
23:01 atweiden tried replacing Nil with empty double quotes "" but get the same warning
23:02 masak atweiden: golfed camelia example?
23:02 timotimo what is your aim for this exact line?
23:04 atweiden grammar detects end-of-line comments: https://github.com/atweiden/nightscape/blob/develop/lib/Nightscape/Parser/Grammar.pm#L83
23:04 atweiden which are optional
23:04 atweiden if the eol comment exists, then substring out the leading '#'
23:05 atweiden (in Actions.pm)
23:05 timotimo you can if $<eol_comment>
23:05 cygx atweiden: do you want to get out an empty string or an undefined value if there's no comment?
23:06 atweiden either one would work
23:06 atweiden the parser isn't troubled by this; it is just outputting a warning message
23:07 cygx m: say (trim ''.substr(1) // '').perl
23:07 camelia rakudo-moar d5eabd: OUTPUT«""␤»
23:08 masak m: say ''.substr(1).^name
23:08 camelia rakudo-moar d5eabd: OUTPUT«Failure␤»
23:08 atweiden timotimo: i used to use that style: https://github.com/atweiden/nightscape/blob/cd7fcbfebe9af62e85704182a2106dc97924dcd6/lib/Nightscape/Parser/Actions.pm#L82
23:08 masak 'night, #perl6
23:09 cygx m: say ''.substr(1); say
23:09 camelia rakudo-moar d5eabd: OUTPUT«5===SORRY!5===␤Argument to "say" seems to be malformed␤at /tmp/5fUGxfOxUF:1␤------> 3say ''.substr(1); say7⏏5<EOL>␤Other potential difficulties:␤    Unsupported use of bare "say"; in Perl 6 please use .say if you meant $_, or use an exp…»
23:09 atweiden i guess i can go back to it
23:09 cygx m: say ''.substr(1); say ''.substr(1).Str
23:09 camelia rakudo-moar d5eabd: OUTPUT«Start argument to substr out of range. Is: 1, should be in 0..0; use *1 if you want to index relative to the end␤  in block <unit> at /tmp/ZN97rfsik8:1␤  in any <unit-outer> at /tmp/ZN97rfsik8:1␤␤␤»
23:09 raydiak good night masak \o
23:10 atweiden i should say, the warning being emitted is new in rakudo 2015.05
23:11 timotimo atweiden: i see
23:12 timotimo atweiden: also, you can substr($<eol_comment>, 1), too; the third argument is optional
23:12 timotimo ah, i think you already saw
23:16 vendethiel joined #perl6
23:23 avuserow .tell masak Re memory leak in rakudo with regexes, reminds me of RT#123974 which I filed a while ago
23:23 yoleaux avuserow: I'll pass your message to masak.
23:23 cygx night o/
23:25 cygx left #perl6
23:25 avuserow also, who was working on the most recent attempt at something like try.perl6.org? is there any code I could peek at? I saw rust's try site and was inspired to poke around a bit and see what they used, so was curious what the latest thing was for us
23:28 timotimo avuserow: last time i tried anything, i was blocked by Proc::Async flakyness
23:28 timotimo and HTT::Server::Async has a problem, too; it sometimes just hangs on one of the connections
23:28 avuserow is there a repo I could peek at?
23:29 timotimo but tony-o built HTTP::Server::Threaded, which will either work perfectly or crash at some point, which means you can guard for the process dying and restart
23:29 avuserow I'm interested in the sandboxing part of it, or is that part solved?
23:29 timotimo haven't done anything with that yet
23:30 avuserow Rust uses this: https://github.com/thestinger/playpen which is based off of seccomp to limit syscalls, but I wasn't able to get it actually set up on my machine
23:32 avuserow I also had the thought of taking advantage of the Docker image of Rakudo Star but from the look of it, they don't have seccomp implemented yet, and I don't know enough about their security model yet
23:43 carlin joined #perl6
23:53 carlin with some tweaks, version B of the send more money solution can be run as nqp, and takes 2 seconds vs 7 minutes as perl 6
23:59 timotimo holy wow.

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

Perl 6 | Reference Documentation | Rakudo