Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2015-08-14

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:13 jferrero joined #perl6
00:17 caymanboy joined #perl6
00:20 dalek rakudo/glr: eb88103 | lizmat++ | src/core/ (2 files):
00:20 dalek rakudo/glr: Fix X::Cannot::Lazy / .infinite mismatches
00:20 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/eb881030d0
00:26 laouji joined #perl6
00:35 mr-foobar joined #perl6
00:36 tinyblak joined #perl6
00:40 laouji joined #perl6
00:44 laouji joined #perl6
00:46 ggoebel joined #perl6
00:47 tinyblak joined #perl6
00:50 japhb timotimo: It is *so* nice to be able to look at profile output without getting reify/gimme-induced rage face
00:55 llfourn joined #perl6
00:56 aborazmeh joined #perl6
00:56 aborazmeh joined #perl6
00:58 colomon ooo, profile improvements?
00:58 colomon or rakudo improvements?
00:58 ShimmerFairy joined #perl6
01:01 tinyblak joined #perl6
01:02 sjn_phone joined #perl6
01:04 timotimo rakudo improvements; that's what the glr branch is about :)
01:04 ShimmerFairy Heh, now I remember why I stopped compiling against the JVM :P
01:13 timotimo because it takes a whole lot of time?
01:13 timotimo oh wait ... compiling C code against the jvm? :)
01:13 sjn_phone_ joined #perl6
01:14 ShimmerFairy yep :) (talkin' bout nqp, haven't got to rakudo yet!)
01:15 ShimmerFairy "yep" to taking a whole lot of time, to be clear
01:15 timotimo yes
01:23 skids .tell jnthn modified GLR Array.unshift PR (now PR#493) per comments on previous PR.
01:23 yoleaux skids: I'll pass your message to jnthn.
01:23 BenGoldberg joined #perl6
01:24 b2gills I just tested the GLR branch against my solution to the "send more money" problem, and it went from 24s to 15s. ( unfortunately that doesn't include finding the first two numbers which I hard-coded as that would have made it take way longer than I wanted to let it run )
01:26 timotimo cool
01:27 timotimo i was hoping for a 10x improvement, but still nice :P
01:28 ShimmerFairy I think nqp-j could use an eval server :)  'make test' on nqp-m was 24 wallclock secs, on nqp-j it was 980.
01:29 skids I think it already uses one?
01:29 ShimmerFairy There's one for rakudo, but not nqp
01:29 timotimo .tell smls is it a good idea - design-wise - to make the code samples "interactive on mouse-hover"?
01:29 yoleaux timotimo: I'll pass your message to smls.
01:30 dalek rakudo/nom: e0f7259 | peschwa++ | src/vm/jvm/runtime/org/perl6/rakudo/RakOps.java:
01:30 dalek rakudo/nom: Fix type hint for Routine.
01:30 dalek rakudo/nom:
01:30 dalek rakudo/nom: Apparently the fact that hoelzro++ moved $!why from Routine to block changed
01:30 dalek rakudo/nom: the order of the fields.
01:30 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e0f725929b
01:30 dalek rakudo/glr: b89ff06 | FROGGS++ | / (2 files):
01:30 dalek rakudo/glr: care about nqp stubs in global merging, fixes RT #125729
01:30 dalek rakudo/glr:
01:30 dalek rakudo/glr: When we merge global symbols when importing from other compilation units, we go ahead
01:30 dalek rakudo/glr: when we detect that the to be imported symbol and the already imported symbols are
01:30 dalek rakudo/glr: just stubs. We did take care about these stubs coming from Perl 6 land, now we also
01:30 dalek rakudo/glr: take care of stubs coming from NQP.
01:30 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/b89ff06533
01:30 dalek rakudo/glr: 0d75e06 | lizmat++ | / (2 files):
01:30 dalek rakudo/glr: Merge branch 'nom' into glr
01:30 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/0d75e0624d
01:30 psch skids: r-j uses an evalserver
01:31 skids Ah.
01:31 timotimo oh, psch, good catch on the type hint
01:32 timotimo how did you figure out the problem?
01:33 lizmat_ m: my @a = 1,2,3; @a.push(4..Inf)  # should this work post GLR ?
01:33 camelia rakudo-moar 98df93: OUTPUT«Cannot push an infinite list onto a Array␤  in any call_with_capture at src/gen/m-Metamodel.nqp:3512␤  in any call_with_capture at src/gen/m-Metamodel.nqp:3512␤  in block <unit> at /tmp/BAYX23XVJw:1␤␤Actually thrown at:␤  in block <unit> at /tm…»
01:33 psch timotimo: mostly just with looking around in jdb and the decompiled .class files
01:35 psch timotimo: i started looking in the general direction of Attribute at first, because that's where the error during build happened
01:35 psch which i still find confusing :)
01:35 dayangkun joined #perl6
01:36 psch but then i wrapped the RTE from P6OpaqueBaseInstance.badNative() in a RTE subclass and put a bp there
01:36 psch 'cause stopping on RTE in nqp-j is gruesome :)
01:36 psch and that lead to p6decontrv, from where it was a somewhat lucky pattern match
01:37 skids lizmat_: I'm not sure.  But if the lazy thing that was pushed can be altered before the push target reifies it, that would be bad.  Unshift does not have that semantics problem.
01:37 psch i.e. "those labels look like they match the field_n's that the P6Opaque has..."
01:40 khw joined #perl6
01:41 skids lizmat: I guess it is a matter of whether we want the eagerness of the args of push and unshift to match for consistency purposes, and what is "least surprise"
01:41 ShimmerFairy .tell smls I just came across your mock-up, and I can't help but wonder why a redesign is necessary. I like perl6.org's design as it stands, so I strongly suggest not messing with it :)
01:41 yoleaux ShimmerFairy: I'll pass your message to smls.
01:45 telex joined #perl6
01:46 ilbot3 joined #perl6
01:46 Topic for #perl6 is now »ö« Welcome to Perl 6! | http://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: http://irc.perl6.org | UTF-8 is our friend!
01:47 b2gills That 24s to 15s reduction was 12730 iterations. Running the full thing under GLR does 829210 iterations in 20m 25s
01:48 psch m: say (20 * 60 + 25) * (24/15)
01:48 camelia rakudo-moar 98df93: OUTPUT«1960␤»
01:48 psch m: say (20 * 60 + 25) * (24/15) / 60
01:48 camelia rakudo-moar 98df93: OUTPUT«32.666667␤»
01:48 ShimmerFairy .tell smls fwiw I wouldn't mind if more of perl6.org looked like docs.perl6.org (since I find that to be really nicely designed), what I'm against is a change in the theming, color choices, and so on :)
01:48 yoleaux ShimmerFairy: I'll pass your message to smls.
01:57 mr-foobar joined #perl6
02:07 skids m: multi sub a ($i) { 1.say }; multi sub a (**@i) { 2.say }; a(1,)
02:07 camelia rakudo-moar e0f725: OUTPUT«1␤»
02:07 lizmat m: my $a = 42; $_ = 666 with $a; say $a
02:07 camelia rakudo-moar e0f725: OUTPUT«42␤»
02:07 lizmat this feels like it should either work or complain
02:08 skids I would argue that with the "single item" rule in lay in GLR that :(1,) should find the **@ candidate.
02:08 skids *play
02:09 skids because it is less awkward to explain "things get crazy when you delete the last comma" than "things get crazy when you delete an item from a 2-item list"
02:09 skids But I don't know if that is especially implementable.
02:10 ShimmerFairy m: my $a = 42; $a ~~ ($_ = 54); say $a;
02:10 camelia rakudo-moar e0f725: OUTPUT«54␤»
02:11 ShimmerFairy lizmat: huh, it _does_ work with the ~~ topicalizer. I... didn't expect that, honestly.
02:11 aborazmeh joined #perl6
02:11 aborazmeh joined #perl6
02:11 skids m: my $a = 42; $a = 666 with $a; say $_
02:11 camelia rakudo-moar e0f725: OUTPUT«(Any)␤»
02:11 ShimmerFairy m: my $a = 42; $a ~~ ($_ = 54); say $_;
02:11 camelia rakudo-moar e0f725: OUTPUT«(Any)␤»
02:12 ShimmerFairy $_ is set only within the statement in each case.
02:12 ShimmerFairy m: $_ = 3; my $a = 42; $a ~~ ($_ = 54); say $_;
02:12 camelia rakudo-moar e0f725: OUTPUT«3␤»
02:12 ShimmerFairy But I don't expect writing to $_ in these cases to go back to $a
02:13 ShimmerFairy m: my $a = 42; given $a { $_ = 52; }; say $a;
02:13 camelia rakudo-moar e0f725: OUTPUT«52␤»
02:13 dalek rakudo/glr: 796b896 | lizmat++ | src/core/Array.pm:
02:13 dalek rakudo/glr: Give Array its own is-lazy, and use it
02:13 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/796b896b13
02:13 dalek rakudo/glr: b2609e9 | lizmat++ | src/core/Hash.pm:
02:13 dalek rakudo/glr: Fix one more X::Cannot::Lazy / .infinite mismatch
02:13 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/b2609e9259
02:13 ShimmerFairy I guess that's just how it works. Like I said though, I don't expect $_ to affect another variable without any explicit := on my part
02:14 psch ShimmerFairy: ~~ has to topicalize like that for ~~ s/// if nothing else
02:14 ShimmerFairy psch: of course, I'm not arguing that it does, it was just the first other thing that topicalizes that came to mind :)
02:14 skids damn that'll give my unshift PR a merge conflict.
02:14 lizmat skids: will look
02:15 ShimmerFairy (_although_ the chaining version of ~~ wouldn't topicalize, and s///.ACCEPTS($thing) works just fine without using $_ ☺)
02:16 psch but s///.ACCEPTS($thing) doesn't $thing.subst-mutate, but $_.subst-mutate($thing)
02:17 psch i do think ~~ is somewhat weirdly overloaded, but i neither can formulate my issue clearly nor do i expect it to change
02:18 ShimmerFairy considering we have S/// (I think?) , why not make their ACCEPTSes match their uses?
02:19 ShimmerFairy psch: AFAICT the issue is that ~~ is the only operator around for testing equivalence to a regex, but ~~ isn't meant for that specifically.
02:19 psch ShimmerFairy: yeah, that's kind of what bugs me as well
02:19 ShimmerFairy (also I think there's an issue that the m// stuff works on $_ when it appears on its own, but that's because I'm so used to the  $thing ~~ m//  version instead of  given $thing { m// }  )
02:20 lizmat skids: basically lines 230-236 and 252-258 are replaced by fail X::Cannot::Lazy.new(action => 'unshift to') if self.lazy;
02:21 skids .oO(use fatal :!failures :lazyiterations(1000))
02:21 psch ShimmerFairy: as in, i find the RtoL-iness of ~~ just plain weird, and s/// and m// are the two big things there
02:21 lizmat I feel too unsure about the rest of your PR to merge it: feel it needs jnthn's eye on it
02:22 skids Yeah, so jnthn agreed with the initial patch that unshift should be eager, and the current implementation thinks it is being eager but stops when things get lazy.
02:22 psch ShimmerFairy: because i doubt that breaking the p5 (and probably earlier) << str op regexlit >> would've gone over well
02:23 psch and =~ parses as = ~ in p6 and a dedicated regex match op would've been silly too
02:23 skids (and currently it is otherwise very broken)
02:23 psch well, as i said, it's somewhat incoherent what bugs me :)
02:23 lizmat afk for a bot&
02:23 ShimmerFairy psch: I think it'd be nice if we had a =//= operator for regexes (and then it could be symmetric)
02:23 lizmat *bit
02:24 ShimmerFairy /regex/ =//= $thing would theoretically work too :)
02:25 psch m: multi infix:<=//=>(Str:D $str, Regex:D $rx) { $str.match($rx) }; multi infix:<=//=>(Regex:D $rx, Str $str) { $str.match($rx) }; my $tx = "foo bar"; say /foo/ =//= $tx;
02:25 camelia rakudo-moar e0f725: OUTPUT«「foo」␤»
02:25 psch vOv
02:25 psch s/// takes more effort
02:25 psch that'd have to sit in the parser i suppose
02:26 ShimmerFairy psch: sure, something mutate-y would require more effort. (And btw, I could've also spelled it /==/ , but I think that's too easily confused with actual regexes ☺)
02:27 psch ShimmerFairy: yeah, between =//= and /==/ i'd prefer the former as well.  i'm wondering if that should stretch to grammars too
02:27 psch the op that is
02:27 psch we don't ~~ magically for grammars afair
02:27 ShimmerFairy psch: Although, if you think of =//= as "just another equality op", it doesn't necessarily have to handling the mutating nature of s///
02:27 ShimmerFairy psch: what are you referring to with ~~ and grammars? I'm not sure I understand exactly.
02:28 kaare_ joined #perl6
02:28 psch ShimmerFairy: we have $grammar.parse($str) instead of $str ~~ $grammar
02:28 ShimmerFairy psch: Ah :)  Well, if you think of grammar as a special kind of class, .parse would make more sense. OTOH, since it's a special kind of class, perhaps there's no reason not to give it an ACCEPTS method :P
02:29 psch ShimmerFairy: =//= without assignment makes me think up << /rx/ R[=//=]= $str >>
02:29 psch not sure that's a good thing :)
02:29 ShimmerFairy m: grammar G { token TOP { abc }; method ACCEPTS(Str:D $target) { self.parse($target) } }; say "abc" ~~ G
02:29 camelia rakudo-moar e0f725: OUTPUT«「abc」␤»
02:30 ShimmerFairy psch: ^^^ ta-da! :)
02:31 psch ShimmerFairy: of course :)  grammars are the metaclass and not the class after all
02:31 ShimmerFairy psch: to be fair, I generally prefer non-mutating methods where they make sense, so that you can choose it's mutation-y nature by use of $thing.meth or $thing.=meth . I'm sure my thinking extends to other types of functions too :)
02:31 psch i.e. we don't need to default to a sensible ACCEPTS
02:32 psch fsvo "sensible"...
02:32 ShimmerFairy In fact, I sometimes wish C++ had .= too, because I think it's a nice and convenient way to choose if a method mutates or not :)
02:32 psch i think i'll try and rest a bit
02:32 ShimmerFairy ♞ psch o/
02:32 psch \o
02:33 noganex joined #perl6
02:46 llfourn joined #perl6
02:51 MadcapJake joined #perl6
03:07 * skids closes PR, deletes branch, redoes changes, opens new PR
03:08 bin_005 joined #perl6
03:08 skids .tell jnthn unshift PR is now #494 due to later merge conflicts with .is-lazy work.
03:08 yoleaux skids: I'll pass your message to jnthn.
03:33 dha joined #perl6
03:35 eam joined #perl6
03:40 simcop2387 joined #perl6
04:13 kurahaupo joined #perl6
04:16 skids $ perl6 -e 'multi sub a ($a) { "\$".say }; multi sub a (*@) { "*".say }; a(1,)' # on GLR
04:16 skids $
04:16 skids $ perl6 -e 'multi sub a ($a) { "\$".say }; multi sub a (*@) { "*".say }; a(1,Slip.new())' # on GLr
04:16 skids *
04:17 skids Hrm, OK so it would be implementable if hanging commas were equivalent to  ",Slip.new()"
04:18 skids Which would be a better escape hatch for finding slurpy candidates than <== IMO.
04:18 kurahaupo left #perl6
04:19 skids But on the downside, large constant arrays where people tend to accidentally leave hanging commas... but passing those to arity methods would be rare.
04:23 skids Hrm but... $ perl6 -e 'sub a ($a) { "\$".say }; a(Slip.new(),1)'
04:23 skids Too many positionals passed; expected 1 argument but got 2
04:31 sjohnson joined #perl6
04:33 davido___ joined #perl6
04:40 raiph joined #perl6
04:49 dustinm` joined #perl6
04:50 laouji joined #perl6
05:03 dalek roast: 17d9681 | usev6++ | S02-types/range.t:
05:03 dalek roast: Make test for RT #125791 pass on JVM
05:03 dalek roast: review: https://github.com/perl6/roast/commit/17d9681a22
05:03 dha .
05:04 breinbaas joined #perl6
05:20 tinyblak joined #perl6
05:45 tinyblak joined #perl6
05:45 dayangkun joined #perl6
05:48 zgrep left #perl6
05:49 laouji joined #perl6
05:59 araujo joined #perl6
06:00 [Tux] FROGGS++ # RT125729 fixed
06:07 [Sno] joined #perl6
06:07 diana_olhovik_ joined #perl6
06:08 [Tux] test             50000    45.123    45.033
06:08 [Tux] test-t           50000    42.535    42.444
06:08 cognominal joined #perl6
06:14 coffee` joined #perl6
06:19 ecocode joined #perl6
06:47 rurban joined #perl6
06:52 RabidGravy joined #perl6
07:00 jack_rabbit joined #perl6
07:00 rindolf joined #perl6
07:03 jack_rabbit joined #perl6
07:03 zakharyas joined #perl6
07:10 lizmat joined #perl6
07:11 dalek rakudo/glr: 4ef8859 | skids++ | src/core/Array.pm:
07:11 dalek rakudo/glr: Remove spurious laziness checks.  Please.
07:11 dalek rakudo/glr:
07:11 dalek rakudo/glr: It is neither specced nor tested for that an unshift to a lazy
07:11 dalek rakudo/glr: construct should be illegal.  There are commented out tests
07:11 dalek rakudo/glr: in roast, but they are obviously just copies from when someone
07:11 dalek rakudo/glr: cut and pasted push-related code to make the unshift test file,
07:11 dalek rakudo/glr: and it is quite likely that the actual tests in current code is
07:11 dalek rakudo/glr: likewise just leftover from not noticing that this test is not
07:11 dalek rakudo/glr: needed for unshift.
07:11 dalek rakudo/glr:
07:11 dalek rakudo/glr: (It is specced that *infinite* things fail when they are the
07:11 dalek rakudo/glr: things being unshifted onto the target, but this is not
07:11 dalek rakudo/glr: implementable unless we have some sort of depth limiter pragma.)
07:11 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/4ef8859ecd
07:11 dalek rakudo/glr: 52252c8 | skids++ | src/core/Array.pm:
07:11 dalek rakudo/glr: Fix Array.unshift, and optimize it some.
07:11 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/52252c8f4f
07:11 dalek rakudo/glr: e710088 | lizmat++ | src/core/Array.pm:
07:11 dalek rakudo/glr: Merge pull request #494 from skids/glr
07:11 dalek rakudo/glr:
07:11 dalek rakudo/glr: GLR Array.unshift corrections and optimization
07:11 dalek rakudo/glr: review: https://github.com/rakudo/rakudo/commit/e710088844
07:20 notch joined #perl6
07:21 ecocode joined #perl6
07:24 cibs joined #perl6
07:27 yeahnoob joined #perl6
07:39 rindolf joined #perl6
07:50 espadrine_ joined #perl6
07:50 cibs joined #perl6
07:52 darutoko joined #perl6
07:54 laouji joined #perl6
07:58 laben joined #perl6
08:00 laben hello p6'ers
08:01 laben how do i debug a module which fails to build with "Cannot invoke this object (REPR: Null, cs = 0)"?
08:09 ShimmerFairy laben: that's an NQP-level error, so have you tried --ll-exception yet? (It dumps a backtrace for under-Perl6 errors)
08:10 laben right away!
08:11 laben ok, now i got something useful, thanks
08:12 laben it's this if someone is interested https://gist.github.com/ano​nymous/78d1e39d60ac0ac72974
08:15 tinyblak joined #perl6
08:15 ShimmerFairy Do you know what in your code breaks things?
08:15 laben inside the "apply_handles" method, problably the "handles" keyword
08:15 laben not my code, is the Flower module
08:16 laben https://github.com/supernovus/flower/
08:16 laben fails to build
08:18 laben btw i get the same error when trying to build Template6 from https://github.com/supernovus/template6/
08:18 ShimmerFairy Which files break during compilation?
08:18 laben Flower.pm6, the last one and central
08:21 ShimmerFairy Seems to me like it's the 'handles' keyword in this case, at first glance
08:22 dakkar joined #perl6
08:22 laben seems like it's crashing when trying to coerce the $expr with $expr.list
08:22 laben $expr should contain the methods to handle
08:23 mtj_ joined #perl6
08:23 brrt joined #perl6
08:26 ShimmerFairy just curious, are you using the 'nom' or 'glr' branch ?
08:26 laben nom
08:26 FROGGS jnthn: now I understand what you meant by case folding... there can be several alternatives to a single codepoint, some of them perhaps more than one character...
08:26 arnsholt Yep. Unicode case-insensitive comparison is very non-trivial
08:26 FROGGS 00DE; C; 00FE; # LATIN CAPITAL LETTER THORN
08:26 FROGGS 00DF; F; 0073 0073; # LATIN SMALL LETTER SHARP S
08:27 FROGGS err
08:28 FROGGS that one:
08:28 FROGGS 1E9E; F; 0073 0073; # LATIN CAPITAL LETTER SHARP S
08:28 FROGGS 1E9E; S; 00DF; # LATIN CAPITAL LETTER SHARP S
08:28 jnthn morning o/
08:28 yoleaux 01:23Z <skids> jnthn: modified GLR Array.unshift PR (now PR#493) per comments on previous PR.
08:28 yoleaux 03:08Z <skids> jnthn: unshift PR is now #494 due to later merge conflicts with .is-lazy work.
08:28 jnthn FROGGS: Yeah, it's...interesting. :)
08:28 ShimmerFairy FROGGS: not to jump in the middle of a convo, but yes, it is non-trivial :)  I'm surprised .fc hadn't been implemented (and seems to be not very spec'd)
08:28 laben ShimmerFairy: maybe its wrong to check for Positional since it doesnt have .list in method list
08:29 nine 318/1034 spec test files fail. t/spec/S03-operators/repeat.rakudo.moar is the first to hang and eat memory.
08:29 ShimmerFairy laben: yeah, I was just going to say, Positional doesn't actually guarantee a .list method :)
08:29 jnthn I think we should have .fc
08:29 * jnthn needs to work on $other-thing today, but a few answers from backlog
08:29 FROGGS but why is 'ß'.uc not the same as 'ß'.fc?
08:29 laben what type should go there, maybe List?
08:29 ShimmerFairy FROGGS: for ß and ẞ, I think Unicode still messed that up :)
08:30 FROGGS ShimmerFairy: it is not unicode, it is the german regulatories... they don't yet specify ẞ as the uppercase ß
08:30 ShimmerFairy m: say "ß".uc; # bad Unicode! Bad!
08:30 camelia rakudo-moar e0f725: OUTPUT«ß␤»
08:31 jnthn 1) .push(1..Inf) correctly fails to work; that one'd need to be .plan(1..Inf) which puts it into the $!todo (and sets up a todo if needed)
08:31 ShimmerFairy FROGGS: I _thiiiink_ their stability policies would prohibit changing the casing between the two (boo). And in any case I did read once that ẞ didn't get created way back when only because the typographers couldn't agree and said they'd get back to it :)
08:32 cibs joined #perl6
08:32 ShimmerFairy *agree on its look
08:32 jnthn 2) No, we can't make trailing comma in an argument list significant, because an argument list is really forming a Capture
08:32 nine Err...where is the xx= operator defined?
08:33 arnsholt It's a metaop
08:33 jnthn nine: It isn't, it's an assign metaop that'll call the xx and then do an =
08:34 nine jnthn: my @a = (4, 2); @a xx= 2; say @a[0]; hangs...on the @a[0]!
08:34 brrt \o
08:34 nine Ok, my @a = (4, 2); @a = @a xx 2; say @a[0]; does the same
08:35 ShimmerFairy But regardless, I think unicode supremely messed up by saying ß.uc -> SS (not the simple mapping, mind) and thus specifying an implicit & required NFKD for that character  e_e
08:36 laben how do rakudo devs recompile rakudo itself often?
08:36 jnthn "make"? :)
08:37 laben i mean, you use a script? or simply make and manually test?
08:37 brrt make test
08:37 DrForr I just use 'rakudobrew nuke moar && rakudobrew build moar' but I'm not a developer.
08:38 brrt actually, i just try to make nqp. and if that works i'm usually 90% there
08:38 jnthn laben: make test for sanity tests, or make spectest to run the big (tens of thousands of tests) suite, or make fulltest now and then to run including stresstests (over 100,000)
08:39 laben jnthn: so you mean clone git repo, config, make, make test?
08:39 laben i wanted to try a simple change
08:40 brrt laben; that's basically how i do it, yes
08:40 jnthn laben: Yes, you may need to add --gen-moar if you don't want to separately check out and build nqp and mor
08:40 jnthn *moar
08:40 jnthn laben: Uh, to Configure.pl I mean
08:41 ShimmerFairy laben: also, I'd try  nqp::can($expr, "list")  for the test I think you're looking to fix (replace the "Positional" type check with that); I'm not sure which type should be checked there (though anyone else is welcome to suggest), and it's something that'll likely be changed in GLR anyway :P
08:42 laben brrt: is it enough to put --backends=moar if i already have moar installed and dont want to install this git checked rakudo?
08:42 jnthn laben: Yes, but you'll also need to do --prefix=... to specify where your moar is, and you'll need an NQP to be installed there too
08:43 brrt if you have moar installed you probably want --prefix=$installation-prefix for nqp to find moar
08:43 ShimmerFairy of course, the alternative quick-fix might be to just add a '(multi?) method list' to the Positional role :P
08:45 laben ShimmerFairy: make'ing right now with the change you suggested :)
08:46 ShimmerFairy laben: if you wanted to be a little stricter you could do  [whatever the Positional's test was] && [the nqp::can one]  to avoid accidentally calling .list on the totally wrong things :)
08:47 laben mmh, failed this one t/04-nativecall/16-rt125408.t
08:48 laben let's try the second suggestion
08:48 RabidGravy yeah, it has been failing for a week
08:48 laben ah, so it's not this change fault?
08:48 RabidGravy no
08:48 ShimmerFairy laben: one good practice (though it eats up more of your time) is to run a spectest before you make changes too, so you know what your changes did :)
08:49 RabidGravy but it was broken and then worked without anyone actively fixing it and broke again
08:52 espadrine_ joined #perl6
08:56 laben i get "Unhandled exception: Missing or wrong version of dependency 'src/Perl6/Grammar.nqp'", is it because i have another rakudo alreay installed?
08:56 RabidGravy yes
08:56 laben i'm using now the modde one
08:56 laben at least in the makefile
08:56 laben how can i tell it to search in the git directory?
08:58 ShimmerFairy you can try ./perl6 in the top directory of the repo (though in my experience a Grammar.nqp issue will break on Test.pm with ./perl6 too before installing)
09:00 ShimmerFairy jnthn: by the way, I don't think I'll currently be able to implement NFG on JVM :( I tried compiling nqp-j and r-j, but they were much slower, and for whatever reason the r-j core step failed for me (both with and without the changes I've made to rakudo locally)
09:01 ShimmerFairy e.g. ~105s on average for parsing CORE on moar, 365s for parsing CORE on jvm. (additionally, nqp's "make test" was 24 wallclock secs on moar, around 980 on jvm)
09:03 magistr joined #perl6
09:04 magistr perl6 supports definitions own types?
09:05 RabidGravy yes
09:07 llfourn joined #perl6
09:10 laben got past that with a little mod to the script ./perl6, but now it hangs on ModuleLoader.moarvm
09:10 laben --libpath="blib" doesnt seem to work
09:16 laben ok, fixed that, now i get "Unhandled exception: Cannot call method 'load_setting' on a null object", what does it mean? what files is it missing?
09:16 jnthn ShimmerFairy: Urgh, yes...my r-m time is more close to 35s these days, which means r-j is more tolerable...
09:27 domidumont joined #perl6
09:29 ShimmerFairy jnthn: don't worry, my computer isn't the best in the first place :) (I'm also using IcedTea 1.7, if that makes any difference)
09:32 domidumont joined #perl6
09:36 laben left #perl6
09:42 Ven joined #perl6
09:43 * Ven waves from the countryside – again :)
09:45 FROGGS_ joined #perl6
09:58 magistr left #perl6
10:00 spider-mario joined #perl6
10:09 spacebat joined #perl6
10:09 bin_005 joined #perl6
10:10 tinyblak joined #perl6
10:18 domidumont joined #perl6
10:23 laouji joined #perl6
10:24 Begi joined #perl6
10:25 Begi my $x = '2'; How can I know if my varaible is a number ? thanks
10:26 DrForr $x.WHAT maybe?
10:26 ShimmerFairy you can either put a constraint on the variable (my Int $x) or check with  $x ~~ Int
10:27 ShimmerFairy m: my Int $a = '2'
10:27 camelia rakudo-moar e0f725: OUTPUT«Type check failed in assignment to '$a'; expected 'Int' but got 'Str'␤  in block <unit> at /tmp/9jrwpOaMtj:1␤␤»
10:27 ShimmerFairy m: my $a = '2'; say $a ~~ Int
10:27 camelia rakudo-moar e0f725: OUTPUT«False␤»
10:27 ShimmerFairy (different typenames for different kinds of numbers, of course)
10:34 rurban joined #perl6
10:42 RabidGravy Begi, or do you mean something like:
10:42 RabidGravy m: my $a = "foo";  say so try Num($a); $a = 99; say so try Num($a)
10:42 camelia rakudo-moar e0f725: OUTPUT«False␤True␤»
10:44 RabidGravy not convinced that's the best way to do it, but hey
10:45 Begi RabidGravy : it works thanks. If there is a better way, i take it
10:45 tinyblak joined #perl6
10:45 jnthn defined +$a
10:48 Begi m: my $a ='2'; if defined +$a { say 'A number !'; }
10:48 camelia rakudo-moar e0f725: OUTPUT«A number !␤»
10:49 tinyblak joined #perl6
10:52 rurban joined #perl6
10:55 RabidGravy is it guaranteed that  Class.^attributes will always return the attributes in the order the are defined?
10:55 cdc joined #perl6
10:56 cdc m: my $a ='2'; with +$a { say 'A number !'; }
10:56 camelia rakudo-moar e0f725: OUTPUT«A number !␤»
10:56 JimmyZ it is not
10:56 cdc m: my $a ='two'; with +$a { say 'A number !'; }
10:56 camelia rakudo-moar e0f725: ( no output )
10:58 jnthn RabidGravy: Yes
10:59 jnthn RabidGravy: We maintain the order because we need to apply the defaults in order.
10:59 jnthn (We years ago stored them in a hash keyed on name and had that bug... :))
11:00 jnthn I *think* we even keep methods ordered too now
11:00 jnthn Because order of declaration serves as an LTM tie-break
11:01 llfourn joined #perl6
11:01 RabidGravy coolio,  I'm thinking of some abstraction of "read some data from a file into a Buf, then unpack into attributes of a Class" which I've got quite a few times now
11:02 jnthn nice :)
11:16 laouji joined #perl6
11:22 mattp_ joined #perl6
11:23 nine jnthn: when can $!reified.DEFINITE ever be false in Array? I only find code paths that will initialize it with an IterationBuffer.CREATE when the Array is created.
11:34 laouji joined #perl6
11:41 jnthn nine: my @a;
11:41 jnthn nine: Which is handled by lexical lazy viv magic
11:41 jnthn (That may change in the future, but it's a bigger change than I want to take on at the same time as the glr)
11:44 eternaleye joined #perl6
11:45 nine m: my @a = (4, 2); @a xx= 2; say @a.perl;
11:45 camelia rakudo-moar e0f725: OUTPUT«[4, 2, 4, 2]<>␤»
11:45 nine is this supposed to stay the same after GLR ^^^? Or do we expect [[4, 2], [4, 2]]?
11:50 jnthn Given [...] doesn't itemize, and we probably want my @x = [0,0,0] xx 3; to do the right thing, I think we'll have to go for the latter option
11:50 jnthn You'd have to @a = @a.Slip xx 2 to get the other thing
11:51 nine Ok, so my little workaround that gives me [$[4, 2], $[4, 2]] would be correct.
11:54 jnthn yes
11:55 jnthn Though a slight pity we get the spurious $ signs in the...I guess .perl...output.
11:55 jnthn Though it's the safe/easy way :)
11:56 nine I can't wait for the documentation updates, so I can read up on how all of this is actually supposed to work. Would make fixing things much easier at times :)
11:56 smls joined #perl6
11:56 smls o/
11:56 yoleaux 01:29Z <timotimo> smls: is it a good idea - design-wise - to make the code samples "interactive on mouse-hover"?
11:56 yoleaux 01:41Z <ShimmerFairy> smls: I just came across your mock-up, and I can't help but wonder why a redesign is necessary. I like perl6.org's design as it stands, so I strongly suggest not messing with it :)
11:56 yoleaux 01:48Z <ShimmerFairy> smls: fwiw I wouldn't mind if more of perl6.org looked like docs.perl6.org (since I find that to be really nicely designed), what I'm against is a change in the theming, color choices, and so on :)
11:57 nine jnthn: I guess, you would sometimes cry out in horror if you saw the things I try before coming up with a working solution :)
11:57 smls timotimo: That depends on the kind of interactivity... For the kind i have in mind, it makes sense I think. (Note that I *don't* indend for it to become an editable textbox. That kind of thing needs its own page and subdomain.)
11:58 smls ShimmerFairy: "wonder why a redesign is necessary" -- Because with the release of Perl 6 (beta), perl6.org will have to transition from a "passively coordinating a smallish volunteer project" website to a "presenting a ready-to-use programming language to the world" website.
11:58 smls ShimmerFairy: While the current content & structure served reasonable well for the former, it is very much inadequate for the latter. And presenting the new content in an optimal way, requires a layout and design that is optimized for it.
11:58 smls ShimmerFairy: Not to mention that the current design looks crude by 2015 standards - we really should try to make a more elegant and polished first impression on people coming to check out what Perl 6 is all about.
11:58 smls ShimmerFairy: Please read http://chrisdone.com/posts/haskell-lang (by the guy who redisigned the Haskell website) - he makes many insightful points about what a programming language website should be.
11:59 timotimo hm
11:59 smls ShimmerFairy: I think we, too, should make every effort to make our language website as useful and pleasant as possible to the kind of people who will visit it, rather than settle for the status quo.
11:59 smls TL;DR: Change is good... :P
12:00 smls timotimo: There will be a link to that page of course; ideally with "open this snippet for editing" support
12:00 ShimmerFairy I just don't like the heavy nature of the mockup you have. It feels too much like a website to me, if that makes any sense. I just don't care much for the feel of a website that's trying super hard to be a website.
12:00 timotimo mhm
12:01 timotimo jnthn: do we have a cool answer for .pick and .roll for things we know we can do super cleverly? like the result of an X metaop?
12:04 [Coke] smls: where's the current mockup?
12:04 smls [Coke]: http://i.imgur.com/xd3FKqH.png (but it only contains the top of the front page)
12:05 * smls should probably write a blog about once the mockup is a little forther along
12:06 ShimmerFairy smls: I certainly don't mind trying to improve the layout and everything (like I said, I _really_ like docs.perl6.org), but I really don't like how the mockup throws away the white + pastels thing we've had for a long time now.
12:07 smls I wouldn't call those pastel colors :P
12:08 [Coke] smls: I like it. I think it keeps the friendly vibe, but looks more professional. I think the background color could be a little lighter, but I am not a UI designer.
12:08 smls [Coke]: Yeah I actually made it even lighter, but adding the texture made it a little darker again. Might have to adjust.
12:09 * jnthn likes it overall, though misses a download button somewhere prominent
12:09 ShimmerFairy [Coke]: interesting how you see it as friendly, to me it feels quite a bit more sterile and commercial.
12:10 [Coke] anyway, +1 from me.
12:10 ShimmerFairy The camelia logo looks out of place to me, which I would consider a bad thing for the rest of the mockup :) .
12:10 [Coke] ShimmerFairy: yes, well, we need it to be slightly more commercial. not a lot, but a little, which I think this does nicely.
12:10 [Coke] out of place - do you have a concrete suggestion for where to put it in the mockup?
12:11 ShimmerFairy I don't know, I'm just a big fan of the white background and light colors. Having the color scheme be noticably darker feels quite a bit more "stuffy" to me, and I don't like that.
12:11 ShimmerFairy [Coke]: not positionally, thematically.
12:12 ShimmerFairy In my eyes, the logo clashes with the "such modern, so wow" look the mockup has, and I don't recommend changing the logo :)
12:12 [Coke] changing the logo isn't an option.
12:12 rurban joined #perl6
12:13 [Coke] I find the fact that it looks every so slightly "stuffier" a good thing.
12:13 * JimmyZ likes http://i.imgur.com/xd3FKqH.png  except the background color :P
12:13 ShimmerFairy Of course changing the logo isn't an option :)
12:14 smls The logo does stick out more, but it's supposed to be the highlight of the page (not part of the background) so I think that's okay.
12:14 ShimmerFairy smls: I think specifically the issue is that all the colors around it have texture, while the logo doesn't (and the logo cannot change)
12:16 JimmyZ most because purple seems noble
12:19 JimmyZ hmm, lighter seems ok :)
12:19 orafu joined #perl6
12:20 ShimmerFairy Something about the dark-ish colors (in particular the dark-ish red-ish background) makes me think to much of an old, cramped study, with everything constructed out of dark wood, chairs with only red cushions (adding to the already warm white balance), and bookshelves for decoration.
12:21 [Coke] That sounds like a weirdly oddly specific complaint.
12:23 ShimmerFairy [Coke]: I was trying to describe what pops up in my head because I'm having quite a time trying to find the right adjectives :)
12:24 ShimmerFairy smls: your mockup front page definitely is better organized, taking a look at the current front page. I think the reason why I dislike the mockup is because I find the color palette darker and more oppressive than before, and more so than I'd prefer.
12:25 smls Yeah I'm still tweaking the lightness of some colors.
12:25 smls btw, [Coke]++ created #perl6-site - we should probably take future bikeshedding there.
12:25 smls Though to be clear, here's my position:
12:25 smls 1) We definitely need a redesign (see explanation above), one way or the other.
12:26 smls 2) As long as I'm the one doing most of the work to make that happen, I reserve the right to heed or disregard any bikeshedding at my discretion. Not everyone can get in their favorite color(s), sorry... ;)
12:26 * JimmyZ agrees
12:27 [Coke] is the working going on it git, or just locally?
12:28 smls For now locally.
12:28 smls Should I make a new repo?
12:28 smls A branch in the official repo might be a little weird considering it's mostly SVG work so far, not yet HTML/CSS.
12:29 [Coke] dunno. just know getting feedback in patches is sometimes nicer than in chat.
12:35 jnthn smls: +1 on your position, fwiw. Sometimes folks here really do need to be told to Just Cope by those who're Getting Stuff Done.
12:37 ShimmerFairy I will admit that I've been objecting a bit loudly, but only because I seem to be the only one who has issues with the current mockup :)
12:40 telex joined #perl6
12:46 * llfourn likes the mockup. Even likes the background color.
12:48 nine smls: The Features list in the mockup may be an accessibility barrier due to the low contrast
12:48 ShimmerFairy I recall there being tools that check for contrast of things on webpages, but I couldn't offer any off-hand
12:51 rurban joined #perl6
12:57 ecocode joined #perl6
12:58 RabidGravy is the EXPORTHOW stuff documented anywhere?  I think I've inferred the broad gist of it, but I feel like I'm missing something :)
13:01 nine Is there a generic way to get a copy of a Mu? I really can't see how @a xx= 2; can avoid ending up as [@a, @a] otherwise, which is must lead to endless recursion in for example .perl
13:02 nine jnthn: do you have a little hint for me about this^^^? Been stuck for hours on this now.
13:03 * TimToady --> YVR --> KIX in a few minutes
13:03 jnthn ...YVR?
13:03 [Coke] safe travels.
13:04 TimToady Vancouver, BC
13:04 jnthn Aha
13:04 jnthn Have a good flight. :)
13:04 jnthn nine: Um...urgh
13:05 brrt joined #perl6
13:05 nine Binding x to every List slot in sub infix:<xx>(Mu \x, Int() $n) definitely won't fly... I wonder how this even worked pre-GLR
13:06 jnthn Probably by copying the data around multiple times every array assignment...
13:06 jnthn Thinks like @a = 1, @a; do work
13:07 jnthn *Things
13:07 nine Yes, but how do I copy a Mu \x?
13:07 nine I really feel like a bloody beginner at such times :)
13:07 jnthn Well, note that:
13:07 jnthn my @a = 1, 2; @a = @a, @a; say @a.elems # 2
13:07 jnthn Do you get @a xx 2 to do that?
13:08 jnthn Grr, but then yeah, accessing it in any way seems to hang
13:08 nine indeed
13:09 nine So no template for a solution there :/
13:09 jnthn I wonder if xx is somehow marking itself lazy
13:10 nine It depends. Some of the multi candidates use GATHER. The one that xx= ends up using doesn't. But it still creates a self referencing list
13:10 jnthn So does @a = @a, @a; though
13:11 jnthn This, of course works fine:
13:11 jnthn > my @a = 1, 2; @a = flat @a, @a; say @a
13:11 jnthn 1 2 1 2
13:11 nine Note that my @a = 1, 2; @a xx= 2; my $b = @a[0]; actually doesn't hang. The hang is in
13:11 nine .perl or stringification or whatever that tries to iterate deeply
13:12 jnthn I don't see how @a = @a, @a; can be reasonably expected to end well
13:12 nine That's probably the reason why after hours of staring at the STORE-ITERABLE and infix:<xx> and friends code, I haven't found an obvious mistake there.
13:12 rmgk_ joined #perl6
13:12 jnthn I think it only works in nom because of the "flat" that's happening
13:12 [Coke] .perl is known to hang on self-referential structures pre-glr. i wouldn't let that block you.
13:13 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a
13:13 jnthn Aha!
13:13 camelia rakudo-moar e0f725: OUTPUT«(timeout)»
13:13 jnthn So it's not a regression
13:14 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a.elems
13:14 camelia rakudo-moar e0f725: OUTPUT«2␤»
13:14 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a[0].elems
13:14 camelia rakudo-moar e0f725: OUTPUT«2␤»
13:14 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a[0].WHAT
13:14 camelia rakudo-moar e0f725: OUTPUT«(Array)␤»
13:14 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a[0][0].WHAT
13:14 camelia rakudo-moar e0f725: OUTPUT«(Array)␤»
13:14 jnthn m: my @a = 1, 2; @a = $@a, $@a; say @a[0][0][0].WHAT
13:14 camelia rakudo-moar e0f725: OUTPUT«(Array)␤»
13:14 jnthn *lol*
13:14 nine m: use Test; my @a = 1, 2; @a = $@a, $@a; is @a[0], 1;
13:14 [Coke] jnthn, I don't think that's a LoL. I think it's an Array.
13:14 * [Coke] ducks
13:14 nine That's what the spectest does ^^^
13:14 camelia rakudo-moar e0f725: OUTPUT«(timeout)»
13:14 jnthn :P
13:15 timotimo NO LOL
13:15 jnthn OK, that can just...never work
13:15 nine So it's just the spectest that's wrong here?
13:15 jnthn Yeah, I think so
13:15 jnthn I don't see any way that can sensibly work
13:15 nine Oh I can delete spec test code just fine :)
13:16 jnthn I wonder if anyone did use @a xx= 2
13:16 rurban joined #perl6
13:16 jnthn Guess it has to be @a = |@a xx 2; after GLR if so
13:17 jnthn Or flat
13:19 smls or .clone :P
13:20 tinyblak joined #perl6
13:20 skids joined #perl6
13:24 virtualsue joined #perl6
13:28 davido___ joined #perl6
13:32 dalek perl6-examples: c266ada | paultcochrane++ | categories/euler/prob288-shlomif.p6:
13:32 dalek perl6-examples: Document Euler problem number 288
13:32 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/c266ada88c
13:32 dalek roast/glr: 06b5ba0 | (Stefan Seifert)++ | S03-operators/repeat.t:
13:32 dalek roast/glr: Fix hang in S03-operators/repeat.t
13:32 dalek roast/glr:
13:32 dalek roast/glr: xx= can never work on lists as it creates a self-referencial data structure
13:32 dalek roast/glr: that will trip up endless loops in many situations.
13:32 dalek roast/glr: review: https://github.com/perl6/roast/commit/06b5ba03d6
13:32 dalek roast/glr: 3b2fbc9 | (Stefan Seifert)++ | S03-operators/repeat.t:
13:32 dalek roast/glr: Fix a couple of infix:<xx> spec test failures after GLR
13:32 dalek roast/glr:
13:32 dalek roast/glr: Tests assume flattening semantics that are no longer there.
13:32 dalek roast/glr: Need to explicitly ask for flattening now.
13:32 dalek roast/glr: review: https://github.com/perl6/roast/commit/3b2fbc975a
13:33 nine Well, I guess my work was not completely useless today :)
13:33 nine Though I would have hoped for much more progress...
13:34 skids So last night it occured to me it might be useful to have a pragma that sets a limit past which to throw in .push-all for any iterator defined in its scope.
13:36 awwaiid joined #perl6
13:40 khw joined #perl6
13:46 orafu joined #perl6
13:54 llfourn RabidGravy: EXPORTHOW isn't documented anywhere AFAIK. I was going to put a basic EXPORTHOW example in modules.pod. Along with package EXPORT::DEFAULT.
13:54 jnthn I thought I explained it in S12
13:55 llfourn jnthn: stand corrected thanks!
13:55 jnthn http://design.perl6.org/S1​2.html#Custom_Meta-objects
13:55 jnthn gah, why the heck to Pod renders think that clicking headings should take me to the top of the page, not give me a link anchored at the heading :/
13:55 jnthn *do
13:56 jnthn I really hope we didn't replicate this "feature" in Perl 6's Pod to HTML :)
13:56 RabidGravy ahah! cheers!
13:56 [Coke] jnthn: I suspect a design choice made ages ago in p5 land. I'm not a fan either.
13:56 [Coke] oh, i thought you meant you saw this in p6 also
13:57 jnthn I think design.perl6.org is written mostly in Perl 5 Pod
13:57 timotimo yup, except for the part on pod6
13:57 skids It would not be so bad if it sent you to the top with a link achored on the index item which you clicked.  But yeah that's less than useful.  I think it may come from GNU doc browsing traditions.
13:58 jnthn I think we'll break that tradition :)
13:59 [Coke] +1
14:00 ShimmerFairy timotimo: and S15, and whatever else I've created (because I staunchly refuse to learn P5 until absolutely necessary :P)
14:00 timotimo :)
14:02 dalek perl6-examples: f90df37 | paultcochrane++ | categories/euler/prob (68 files):
14:02 dalek perl6-examples: Remove expected results from Euler problem docs
14:02 dalek perl6-examples:
14:02 dalek perl6-examples: The people at the Euler Project discourage the publication of the results as
14:02 dalek perl6-examples: it detracts from the competition.
14:02 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/f90df37416
14:02 dalek perl6-examples: d04a606 | paultcochrane++ | categories/euler/prob0 (2 files):
14:02 dalek perl6-examples: Strip trailing whitespace and add vim coda
14:02 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/d04a6068fb
14:02 ShimmerFairy jnthn: I also hope Perl 6's doesn't have the same "Twigils" bug in S02  (basically, S02 has two headers named "Twigils", so the P5's output gets horribly confused and has both TOC links lead to the first header, _and_ concats the two sections in one and puts them under both Twigils headers)
14:04 nine jnthn: I guess @a = 1, 2; @a ,= 3, 4; is really the same case as @a = @a, @a or @a xx= 2?
14:04 nine jnthn: in other words, not supposed to work out well?
14:05 llfourn jnthn: is exporting a declarator in EXPORTHOW meant to remove the current slang?
14:05 llfourn it gets replaced with: Perl6::Grammar+{PackageDeclarator}
14:09 jnthn llfourn: Well, it certainly has to derive the grammar
14:09 jnthn llfourn: I'd have thought it derives from the current language
14:09 llfourn jnthn: but shouldn't it be: Perl6::Grammar+{PackageDeclarator}+{MySlang}
14:09 PerlJam good morning #perl6
14:10 jnthn llfourn: Your slang would have had to be in scope first surely
14:10 jnthn nine: Well, not sure how it can work out well at least...
14:10 jnthn nine: Though that we have two such examples where things to go too well is...interesting.
14:10 nine jnthn: S03 says it should essentially do the same as push(@a, 3, 4)
14:11 jnthn nine: I'd not pay too much attention to anything the design docs say about lists... :)
14:11 llfourn jnthn: well I'm applying a grammar in sub EXPORT and also doing EXPORTHOW for the declarator. not sure if doing them in separate imports will help. Will check.
14:12 nine jnthn: I guess, what I'm saying is, that we could probably special case this during compilation to DWIM
14:12 llfourn if I comment out the EXPORTHOW i get Perl6::Grammar+{MySlang} in the importer
14:13 jnthn llfourn: I fear the way the slang is being applied tweaks %*LANG but EXPORTHOW works against the current cursor
14:13 llfourn jnthn: I thought %*LANG was the current cursor
14:14 jnthn No, it only determines the type of the cursor at the point of the next statement
14:14 llfourn is there any better way to apply a slang so that it doesn't get wiped by EXPORTHOW?
14:16 jnthn llfourn: Don't know; another option maybe is that we tweak EXPORTHOW to also manipulate %*LANG instead
14:16 jnthn llfourn: You might try patching the EXPORTHOW handling in Rakudo to see if that helps
14:16 llfourn jnthn: kk will give it a shot. thanks.
14:17 dalek roast/glr: ad5ef8a | (Stefan Seifert)++ | S03-operators/assign.t:
14:17 dalek roast/glr: Fix S03-operators/assign.t hang by adopting GLR semantics
14:17 dalek roast/glr: review: https://github.com/perl6/roast/commit/ad5ef8a917
14:19 llfourn hmm doing it in separate imports actually works. like use MySlang; use MyDeclarator;
14:19 nine t/spec/S05-transliteration/with-closure.t is now the first hang
14:19 jnthn llfourn: That probably confirms the thing I suggested patching will help
14:20 llfourn jnthn: sweet
14:21 tinyblak joined #perl6
14:23 dalek perl6-examples: 9031b75 | paultcochrane++ | util/update-and-sync:
14:23 dalek perl6-examples: Get examples on hack to build rakudo/panda itself
14:23 dalek perl6-examples:
14:23 dalek perl6-examples: At present the examples require the most up to date Rakudo, so it's better
14:23 dalek perl6-examples: to let the examples environment on hack build its own version so that the
14:23 dalek perl6-examples: website can be built correctly.
14:23 dalek perl6-examples: review: https://github.com/perl6/perl​6-examples/commit/9031b75f24
14:24 nine m: say ([<X Y>] => [1, 2]).perl;
14:24 camelia rakudo-moar e0f725: OUTPUT«["X", "Y"] => [1, 2]␤»
14:25 jnthn I think that one should be unchanged under GLR
14:27 ShimmerFairy so quotewords produce Arrays then, right?
14:28 jnthn List
14:28 nine jnthn: it is. But $s.trans([<X Y>] => [{++$x},{++$y}]) hangs
14:28 jnthn Must be some other reason
14:28 ShimmerFairy I had a feeling I'd mess that up :) (I _really_ need to brush up on the GLR soon)
14:29 jnthn ShimmerFairy: Given my weekly progress report would basically be "I worked on the GLR. See you next week!", I might use the words I normally write to explain it a bit ;)
14:30 jnthn nine: If you can attach a debugger to Moar and break execution, MVM_dump_backtrace(tc); can hint where it hangs
14:30 ShimmerFairy heh :)
14:31 camelia joined #perl6
14:33 nine Looks like an endless recursion between Str and join
14:34 RabidGravy ah EXPORTHOW::COMPOSE is NYI?
14:35 jnthn RabidGravy: yes
14:36 virtualsue itz++ # gave a perl 6 talk at our tech meet last night
14:36 RabidGravy is SUPERSEDE?
14:36 RabidGravy itz++ # just for ity-ness
14:36 RabidGravy itzy-ness even
14:37 jnthn RabidGravy: I think I did SUPERSEDE, yes
14:37 RabidGravy lets try
14:47 RabidGravy yep, SUPERSEDE works
14:59 perlbaa joined #perl6
14:59 hoelzro o/ #perl6
15:05 nine \o hoelzro
15:09 RabidGravy is making a class trait that applies a role to the classes HOW a valid alternative to EXPORTHOW::COMPOSE or does it happen to late?
15:09 RabidGravy too late rather
15:10 jnthn RabidGravy: Probably early enough
15:10 jnthn RabidGravy: I mean, traits are applied in order, so you can get into ordering issues
15:12 orafu joined #perl6
15:13 hoelzro o/ nine
15:13 * RabidGravy tries
15:18 sunnavy joined #perl6
15:25 perlbaa joined #perl6
15:47 RabidGravy every single time I make a trait I forget the 'multi' and spend ten minutes wondering where I went wrong
15:48 RabidGravy I think I need a gravy-proof perl6 that tells me that I did that
15:49 lizmat RabidGravy: what is the error message that you get?
15:50 * lizmat just back from quite some sightseeing
15:50 RabidGravy "Parameter '$doee' requires a type object of type Sub, but an object instance was passed"
15:50 RabidGravy because it calls it for everything
15:51 RabidGravy I think I just need to work on my memory a bit ;-)
15:52 RabidGravy making the same mistake over and over again is not ideal
15:52 lizmat joined #perl6
15:52 lizmat grrr   flaky connectivity
15:52 RabidGravy :)
15:54 lizmat how about adding:   Did you forget a 'multi'?
15:54 lizmat to that error message ?
15:54 hoelzro RabidGravy: I've done that too!  Every time something like that happens to me, I make a note on what to add to a perl6 linter someday =)
15:55 RabidGravy :)
15:55 RabidGravy lizmat, that could work
15:57 dalek rakudo/nom: ad062f4 | lizmat++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
15:57 dalek rakudo/nom: Add hint to error message, RabidGravy++
15:57 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ad062f4ab1
15:58 RabidGravy lizmat++ # fabulous!
15:58 tinyblak joined #perl6
16:00 * TimToady sitting in YVR waiting for mall chinese place to finish waking up so we can have breakfast
16:03 eiincbz left #perl6
16:08 lizmat TimToady: tasty breakfast and safe travels!
16:11 lizmat $ 6 'my @a = (4,2); say @a[0].WHAT; @a xx= 2; say @a[0].WHAT'
16:11 lizmat (Int)
16:11 lizmat (Array)
16:11 lizmat The reason t/spec/S03-operators/repeat.t hangs
16:12 lizmat xx apparently doesn't flatten its RHS
16:13 lizmat oops, LHS
16:18 TimToady they were just talking about that earlier
16:18 * lizmat goes backlogging more scrutinously
16:24 domidumont1 joined #perl6
16:28 domidumont joined #perl6
16:29 nine lizmat: I "fixed" a couple of those in roast/glr this afternoon
16:31 nine lizmat: I'd appreciate some review :) I'm very unsure wrt expected semantics
16:40 lizmat joined #perl6
16:41 ugexe glr: [{}].perl = '[]'; [{},].perl = '[${}]' # in case someone needs to hack their way through such a module test for the time being
16:42 lizmat nine: but the xx induced hang cannot be fixed by changing the tests?
16:50 nine lizmat: consensus was that xx= is a dubious concept that cannot give a sensible result
16:51 nine the only possibility I see would be to clone the args before adding to the result list. That doesnt cimpose well with lazyness however
16:54 TimToady well, we might end up with some metaops that control flattening and slippage
16:55 nine lizmat: if you've got some ideas I'd love to hear them :)
16:57 beastd joined #perl6
16:58 b2gills What is the GLR way to iterate over the elements of a Set? ( I currently have $set.list.map ... )
17:00 hoelzro so I was looking at test failures in S26-documentation/ on the GLR branch, and this line is failing: my $wool-attr = Sheep.^attributes.grep({ .name eq '$!wool' })[0];
17:01 hoelzro and I get the "cannot index a Seq" error; should I change the test to do .list[0], or should I hold off until Seq *is* indexable?
17:01 lizmat well, the word's not out on that yet
17:01 lizmat afaik
17:02 nine .list[0] for now
17:02 nine Though I'd very much like to have Seq indexable. Can't see a downside
17:03 nine And Seq is supposed to be nearly invisible to the user
17:03 lizmat so it would just need to generate the index(es) specified, right?
17:03 nine yes
17:03 nine ir up to the index
17:03 lizmat I mean, you're throwing away the other values anyway then
17:03 nine exactly
17:03 lizmat well, up to the highest index, as it could be a slice  :-)
17:04 skids It will end up being an interesting implementation what with $thing.map[255,3,1,2,254]
17:04 lizmat yeah, but that is exactly what is needed
17:04 lizmat take e.g. an example I gave to a newbie lately:
17:04 nine A first implementation could just delegate to list
17:04 lizmat .words[1] for parsing a ps line
17:05 lizmat if you would want more columns of the ps line, in another order
17:05 lizmat that could well be .words[10,1] then
17:05 nine Just keep the user from havung to do it manually and optimize later
17:05 skids Oh, I'm all for having interesting implementations of complicated things made available for general purpose use :-)
17:05 lizmat yup, my idea as well
17:07 lizmat in case of xx and xx=, maybe we should have a separate infix:<xx=> handler ?
17:07 skids The question may be whether they "do Positional" or do something more lightweight than "Positional"
17:08 lizmat Sliceable
17:08 hoelzro lizmat: so maybe I should've written "until it's decided whether Seq will be indexable" ;)
17:09 lizmat yeah  :-)
17:09 lizmat Sliceable  = Throwaway Indexable
17:10 lizmat anyways, it's late again already...  I'll sleep on it
17:10 jnthn On the xx= question, I wonder if we should mark operators like xx as slippy (to go with iffy, diffy, and so on)
17:10 jnthn And then we call a different version of the METAOP_ASSIGN
17:10 jnthn Just as we do with reduce for different assocs, etc.
17:10 jnthn BTW, Seq isn't supposed to be nearly invisible at all.
17:11 jnthn Whether something keeps values around or noms them has to be user facing; hiding it has been one of our past mistakes.
17:12 skids $thing.map[|crazy_lazy_indices()] might make a "Sliceable" need to enforce eager inside [].
17:13 jnthn If you're not going to enforce monotonic, then it's pointless to have Sliceable
17:13 jnthn You might as well just .list and be done with it
17:13 jnthn uh, have AT-POS delegate to .list.AT-POS, I mean.
17:15 jnthn But then we're getting dangerously close to throwing the towel in and having Seq being "does Positional"
17:15 jnthn Which we can't do otherwise we break the memoize-on-::=-bind thing
17:16 skids Hrm, Positional itself seems to just be a marker role (with the bonus of .of)
17:16 jnthn I guess so long as we don't make a seq as "does Positional" then we're OK
17:16 jnthn skids: Yes, but it is - critically - the constraint on an @sigil thing
17:19 skids Right so the question is is there a use case for a marker role that says "you can .[] me" but isn't Positional.
17:19 nine jnthn: delegating to .list.AR-POS is what I have in mind
17:20 jnthn ARRRR-POS! It's index like a pirate day, mateys!
17:20 jnthn skids: I don't see one, off hand... :)
17:20 b2gills Too bad we're not currently supporting Parrot :P
17:31 jnthn dinner &
17:41 bin_005 joined #perl6
17:51 llfourn joined #perl6
17:52 skids I guess it has to be decided whether the semantics of a_lazy.map[|b_lazy()] is "we store all the values from b_lazy, then iterate a_lazy while throwing away unused values" or... "it's just .list[|b_lazy] and we'll store 5 billion values from a_lazy if that is what it takes until we get to the end of b_lazy.
17:55 skids I'd argue the first since both are useful and the second already available via .list[].
18:01 jnthn skids: Trouble is, you can't do that with a delegating AT-POS
18:01 skids Right it would haveto be its own thing.
18:01 skids Is that so bad?
18:02 nine Bur isn't that just an optimization? I see no difference in semantics, just in performance
18:02 jnthn It's a memory optimization, yeah
18:03 pmichaud joined #perl6
18:03 jnthn Well
18:03 skids Well, with side effects semantics would be different.
18:03 jnthn It's not quite that simple
18:03 pmichaud r: (12,24,13,97,11,10,100).pick(*)
18:03 yoleaux 3 Jul 2015 17:52Z <TimToady> pmichaud: I'm going to assume that, if you're prototyping the new efficient underpinnings as a module, I can safely work on removing most flatteners from the API, so we have more time to work out the programmer-visible gotchas (or in other words, Break All The Things sooner rather than later)
18:03 camelia rakudo-{moar,jvm} ad062f: ( no output )
18:03 pmichaud r: (12,24,13,97,11,10,100).pick(7).say
18:03 camelia rakudo-jvm ad062f: OUTPUT«97 12 13 100 11 10 24␤»
18:03 camelia ..rakudo-moar ad062f: OUTPUT«10 100 13 97 12 11 24␤»
18:04 jnthn skids: Which "different" are you thinking about, ooc? :)
18:05 jnthn skids: We'd still have to evaluate everything up to the maximum index, and that's what'd happen anyway
18:06 skids Right, but ordering of destructors and any side effects upstream would be different.
18:06 jnthn Concrete example?
18:06 jnthn We don't promise anything on timely destruction so that's a non-issue :)
18:08 nine Neither timely nor in order ;)
18:09 jnthn Indeed
18:09 jnthn Currently you get allocation order
18:09 skids I could see if the sources of a_lazy and b_lazy were interdependent, one form would be possible, the other a dealocker, depending on scenario.
18:09 skids *deadlocker
18:10 jnthn skids: That would be...and odd situation. I grant it's almsot certainly constructable.
18:10 jnthn *an
18:13 nine If we fear a possible semantic change in the future, why not restrict use to the simple cases for now an error outvon encountering lazy indices? That would help the majority of users and spectests while keeping our option open
18:14 jnthn nine: Good point
18:14 skids Right "put a pin in it" by not allowing lazy things inside .map.[] but .list.[] is fine.
18:15 jnthn I could go with that. I think it's clear enough by now that we're not going to get away with making people write .list there
18:15 skids Maybe have a combo Lazy/NYI error message.
18:16 nine no, it's a real pain and not a solution anyone not involved in the glr process is likely to comw up with
18:20 nine it's almost as obscure as having to write (split /,/, @a)[1] in Perl 5 ;)
18:20 jnthn Sure, it just means we add one more thing to the "list of cases a Seq memoizes"
18:20 b2gills m: say (^3).permutations.perl # doesn't work on glr at the moment, and I had a great use for it too ( it is way too slow for 0..9 which is what I really want it for )
18:20 camelia rakudo-moar ad062f: OUTPUT«((0, 1, 2), (0, 2, 1), (1, 0, 2), (1, 2, 0), (2, 0, 1), (2, 1, 0))␤»
18:21 b2gills ( way to slow on nom i mean )
18:22 TimToady boarding for KIX &
18:22 [Coke] yikes, heck of a lyaover.
18:22 [Coke] ~~
18:48 breinbaas joined #perl6
18:52 bin_005 joined #perl6
18:53 mr-foobar joined #perl6
19:00 telex joined #perl6
19:09 FROGGS m: sub _fetch_sub { %::{'$pack'}; }
19:09 camelia rakudo-moar ad062f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/N0k_yH08IJ␤Variable '%' is not declared␤at /tmp/N0k_yH08IJ:1␤------> 3sub _fetch_sub { 7⏏5%::{'$pack'}; }␤»
19:10 FROGGS DrForr: I cannot reproduce RT #125772
19:13 rurban joined #perl6
19:20 virtualsue joined #perl6
19:24 yqt joined #perl6
19:28 nowan joined #perl6
19:34 flussence m: sub a { True ?? return !! Nil }
19:34 camelia rakudo-moar ad062f: OUTPUT«===SORRY!===␤Cannot find method 'ann'␤»
19:34 FROGGS ohh nice one
19:35 flussence m: sub a { True ?? return () !! Nil }
19:35 camelia rakudo-moar ad062f: ( no output )
19:35 FROGGS probably easily to track down
19:35 flussence those ternary operators have always been a bit flaky...
19:55 diana_olhovik_ joined #perl6
19:56 llfourn joined #perl6
19:59 synbot6 joined #perl6
19:59 diana_olhovik_ joined #perl6
20:03 PerlJam [Coke]: Happy Birthday!
20:10 bartolin_ FROGGS: the output for DrForr's code changed with commit 68f20f4c11
20:10 FROGGS ohh
20:10 bartolin_ FROGGS: there was some discussion here: http://irclog.perlgeek.de/p​erl6/2015-08-09#i_11030267
20:21 espadrine_ joined #perl6
20:25 FROGGS bartolin_: I added that to the ticket
20:27 bartolin_ FROGGS++
20:29 rurban joined #perl6
20:34 dalek rakudo/nom: cee1a80 | FROGGS++ | src/Perl6/Actions.nqp:
20:34 dalek rakudo/nom: fix typo in comment
20:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/cee1a8047d
20:34 dalek rakudo/nom: ab73b0a | FROGGS++ | src/Perl6/Grammar.nqp:
20:34 dalek rakudo/nom: mark blocks like { .foo } as "$_ is used"
20:34 dalek rakudo/nom:
20:34 dalek rakudo/nom: This fixes RT #125767
20:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ab73b0ade1
20:34 synbot6 Link:  https://rt.perl.org/rt3/Publi​c/Bug/Display.html?id=125767
20:35 dalek ecosystem: 6bc5ddf | RabidGravy++ | META.list:
20:35 dalek ecosystem: added Staticish
20:35 dalek ecosystem: review: https://github.com/perl6/e​cosystem/commit/6bc5ddf24d
20:36 RabidGravy not quite right, but kinda useful
20:40 MilkmanDan joined #perl6
20:42 dalek roast: bbe6a8c | FROGGS++ | S04-declarations/implicit-parameter.t:
20:42 dalek roast: add tests for RT #125767, { .sqrt => .sqrt }
20:42 dalek roast: review: https://github.com/perl6/roast/commit/bbe6a8c2c9
20:42 synbot6 Link:  https://rt.perl.org/rt3/Publi​c/Bug/Display.html?id=125767
20:46 llfourn joined #perl6
20:49 bartolin_ m: say (* < 7 and * > 5)(6)
20:49 camelia rakudo-moar ad062f: OUTPUT«True␤»
20:50 bartolin_ is that supposed to be the same as 'say (6 < 7 and 6 > 5)'?
20:50 bartolin_ m: say (6 < 7 and 6 > 5)
20:50 camelia rakudo-moar ad062f: OUTPUT«True␤»
20:50 bartolin_ m: say (* < 7 and * > 5)(7)
20:50 camelia rakudo-moar ad062f: OUTPUT«True␤»
20:53 FROGGS m: say (* < 7 and * > 5)(7)
20:53 camelia rakudo-moar ab73b0: OUTPUT«True␤»
20:53 FROGGS m: say (* < 7 and 7 > 5)(7)
20:53 camelia rakudo-moar ab73b0: OUTPUT«Cannot find method 'postcircumfix:<( )>'␤  in block <unit> at /tmp/TTAXdxnzeL:1␤␤»
20:53 FROGGS ?
20:53 FROGGS ahh
20:54 FROGGS the 'and' is not part of the code that is invoked via (7)
20:55 FROGGS say (* < 7 and * > 5)(7) turns into m: say (WhateverCode and * > 5)(7), so the 7 is passed to the code after the 'and'
20:56 bartolin_ ahh, that explains it.
20:56 bartolin_ it's from RT #116208
20:56 synbot6 Link:  https://rt.perl.org/rt3/Publi​c/Bug/Display.html?id=116208
20:57 bartolin_ ... which doesn't look quite right (closable) to me
20:57 FROGGS aye
20:59 muraiki joined #perl6
21:00 * bartolin_ has to sleep now
21:00 bartolin_ g'night #perl
21:00 FROGGS gnight bartolin_
21:11 bin_005 joined #perl6
21:33 dalek perl6-most-wanted: 77875b9 | (Erik Colson)++ | most-wanted/modules.md:
21:33 dalek perl6-most-wanted: Update modules.md
21:33 dalek perl6-most-wanted:
21:33 dalek perl6-most-wanted: wxwidgets GUI added
21:33 dalek perl6-most-wanted: review: https://github.com/perl6/perl6​-most-wanted/commit/77875b9238
21:33 dalek perl6-most-wanted: 0727681 | RabidGravy++ | most-wanted/modules.md:
21:33 dalek perl6-most-wanted: Merge pull request #6 from ecocode/patch-1
21:33 dalek perl6-most-wanted:
21:33 dalek perl6-most-wanted: Update modules.md
21:33 dalek perl6-most-wanted: review: https://github.com/perl6/perl6​-most-wanted/commit/07276815ba
22:15 dha joined #perl6
22:41 geekosaur joined #perl6
22:45 TEttinger joined #perl6
22:47 llfourn joined #perl6
22:49 notostraca joined #perl6
23:00 RabidGravy nighty night all
23:01 timotimo nn RabidGravy
23:03 dakkar joined #perl6
23:44 notostraca joined #perl6

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

Perl 6 | Reference Documentation | Rakudo