Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2014-04-13

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs

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

All times shown according to UTC.

Time Nick Message
00:04 BenGoldberg joined #perl6
00:10 dalek roast: f57331b | (David Warring david.warring@gmail.com)++ | integration/advent2012-day06.t:
00:10 dalek roast: adding advent 2013 day 06
00:10 dalek roast: review: https://github.com/perl6/roast/commit/f57331b2df
00:13 rurban joined #perl6
00:17 hoverboard joined #perl6
00:45 Mouq joined #perl6
00:46 dalek roast: 7b9c4db | Mouq++ | S32-list/uniq.t:
00:46 dalek roast: Add test for RT #121434
00:46 dalek roast: review: https://github.com/perl6/roast/commit/7b9c4dba31
00:46 synopsebot Link: https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=121434
00:47 Mouq Oh...
00:47 Mouq Add another test :P
00:47 Mouq I suppose more tests can't hurt…
00:50 TimToady better too many than too few :)
00:55 Mouq : while my $x = $*IN.get { say $x; last if Bool.roll }; say $x
00:55 Mouq j: while my $x = $*IN.get { say $x; last if Bool.roll }; say $x
00:55 camelia rakudo-jvm 11a693: OUTPUT«(Str)␤»
00:55 adu joined #perl6
00:56 Mouq :/
00:56 adu :\
00:57 timotimo :|
00:59 Mouq :╽
01:08 klapperl_ joined #perl6
01:12 Mouq method samespace(Str:D: Str:D $pat) { my @self-chunks = self.split(rx/\s+/, :all);
01:13 Mouq ^^ Uhhm
01:13 Mouq Is that correct?
01:14 rurban joined #perl6
01:14 Mouq Actually.. how does that work in the first place? it returns @self-chunks.join
01:14 baest joined #perl6
01:14 Mouq m: say "a b c".samespace("a b c")
01:14 camelia rakudo-moar 11a693: OUTPUT«ab  b c␤»
01:14 Mouq O_o
01:15 Mouq roast $ ack samespace
01:15 Mouq roast $
01:15 Mouq :(
01:15 anaeem1_ joined #perl6
01:15 lue r: say "a b c".samespace("a b c")
01:15 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«ab  b c␤»
01:16 Mouq m: say "a b c".split(/\s+/, :all)
01:16 camelia rakudo-moar 11a693: OUTPUT«a 「 」␤ b 「 」␤ c␤»
01:16 Mouq m: say "a b c".split(/\s+/, :all).perl
01:16 camelia rakudo-moar 11a693: OUTPUT«(("a", Match.new(orig => "a b c", from => 1, to => 2, ast => Any, list => ().list, hash => EnumMap.new())), ("b", Match.new(orig => "a b c", from => 3, to => 4, ast => Any, list => ().list, hash => EnumMap.new())), "c").list␤»
01:16 lue At least it's Consistent across backends, and Strangely so ;) .
01:17 * Mouq tries stringifying the match…
01:19 Mouq m: sub SS ($orig, $space) {$orig.split(/\s+/, :all)[0,*+2..*] Z~ $space.split(/\s+/, :all)[1,*+2..*]}
01:19 camelia rakudo-moar 11a693: ( no output )
01:19 Mouq m: sub SS ($orig, $space) {$orig.split(/\s+/, :all)[0,*+2..*] Z~ $space.split(/\s+/, :all)[1,*+2..*]}; say SS "a b c", "a b c"
01:20 camelia rakudo-moar 11a693: OUTPUT«(timeout)»
01:20 timotimo does the samespace modifier work on s/// or where-ever it may be appropriate?
01:20 Mouq timotimo: It works on ss///
01:21 lue r: my $a = "a b c"; $a ~~ s:ss/[<.alpha> <.ws>?]+/d  e f/;
01:21 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: ( no output )
01:21 lue r: my $a = "a b c"; $a ~~ s:ss/[<.alpha> <.ws>?]+/d  e f/; say $a;
01:21 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«db  e f␤»
01:21 rurban joined #perl6
01:22 lue r: my $a = "a b c"; $a ~~ s:ss/[<.alpha> <.ws>?]+/d    e f  /; say $a;
01:22 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«db  e f  ␤»
01:22 lue r: my $a = "a b c"; $a ~~ s:ss/[<.alpha> <.ws>?]+/d    e  f /; say $a;
01:22 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«db  e  f ␤»
01:22 lue Mouq: Looks like the first space substitution is messed up, and seemingly the rest are fine.
01:23 Mouq m: sub SS ($orig, $space) {$orig.split(/\s+/, :all)[0,*+2...*] Z~ $space.split(/\s+/, :all)[1,*+2...*]}; say SS "a b c", "a b c"
01:23 camelia rakudo-moar 11a693: OUTPUT«ab   ␤»
01:24 Mouq Oh wait
01:24 lue r: my $a = "α β γ"; $a ~~ s:ss/[<.alpha> <.ws>?]+/δ    ε  ζ /; say $a;
01:24 Mouq m: say "a b c".split(/\s+/, :all)[0]
01:24 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«δβ  ε  ζ ␤»
01:24 camelia rakudo-moar 11a693: OUTPUT«a 「 」␤␤»
01:25 Mouq ^^ *that's* what's causing the regression
01:25 lue ah
01:25 timotimo huh ,ouchies!
01:25 timotimo oh, these were in the source
01:25 timotimo that's fine then %)
01:26 lue (me using greek characters was to make sure that the extraneous "b" was coming from the string, and not possibly some internal process)
01:27 * Mouq tries a fix
01:27 timotimo i didn't look closely at all, so i thought that was garbage memory or something :)
01:28 Mouq :) timotimo++, jnthn++, people++
01:28 * Mouq hasn't been online much but has been excitedly watching the work being done recently
01:32 * Mouq abandons trying to fix .split, and just calls .flat on it in .samespace instead
01:36 * Mouq forgot to git pull -_-
01:36 dalek rakudo/nom: e13671e | Mouq++ | src/core/Str.pm:
01:36 dalek rakudo/nom: Fix Str.samespace (and with it ss///)
01:36 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e13671e352
01:36 dalek rakudo/nom: 25c75c0 | Mouq++ | / (3 files):
01:36 dalek rakudo/nom: Merge branch 'nom' of https://github.com/rakudo/rakudo into nom
01:36 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/25c75c08b0
01:39 snarkyboojum joined #perl6
01:43 dalek roast: 5004da4 | Mouq++ | S05-substitution/subst.t:
01:44 dalek roast: Unfudge ss/// test on Rakudo
01:44 dalek roast: review: https://github.com/perl6/roast/commit/5004da4f00
01:46 lue r: my @a = "a b c".split(/\s+/, :all); say @a.map: {"({$_.gist})"}; say "[" ~ @a[0].gist ~ "]"
01:46 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«(a) (「 」␤) (b) (「 」␤) (c)␤[a]␤»
01:47 lue r: say "a b c".split(/\s+/, :all).map: {"({$_.gist})"}; say "[" ~ "a b c".split(/\s+/, :all)[0].gist ~ "]"
01:47 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«(a) (「 」␤) (b) (「 」␤) (c)␤[a 「 」␤]␤»
01:47 lue Mouq: apparently, storing the split in a variable fixes @thing[0] (?)
01:48 Mouq lue: I think the problem may have been the binding
01:48 Mouq r: my @a := "a b c".split(/\s+/, :all); say @a.map: {"({$_.gist})"}; say "[" ~ @a[0].gist ~ "]"
01:48 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«(a) (「 」␤) (b) (「 」␤) (c)␤[a 「 」␤]␤»
01:50 lue Using the commandline, I see now that split returns something in the form of  (("thing", Match.new(what was split on)), ("thing2", Match.new()), ... "last thing")
01:50 lue r: say "a b c".split(/\s+/, :all)[0]; say "a b c".split(/\s+/, :all)[0][0]
01:50 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«a 「 」␤␤a␤»
01:51 lue Huh, I think I just found out why this one script of mine broke all of a sudden a short while ago :) [it uses split(:all), so this is likely the issue]
01:53 timotimo split :all gives you not only the pieces, but also the splittings?
01:53 lue timotimo: yes
01:53 timotimo that's nice
01:53 lue Nope, not what broke my script though :/
01:53 timotimo i remember being excited i can capture the part after the % operator
01:53 timotimo (or even inside that part)
01:58 Mouq TimToady: Opinion wrt RT #71544
01:58 synopsebot Link: https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=71544
01:58 Mouq ?
01:59 Mouq I.e., is that indeed the desired behaviour?
01:59 TimToady looking
02:02 TimToady well, I could also argue for about 3 other behaviors...
02:03 Mouq Lurkers: LHF: https://rt.perl.org/Search/Results.html?Q​uery=Queue%20%3D%20%27perl6%27%20AND%20%2​8%20%20Status%20%3D%20%27open%27%20OR%20S​tatus%20%3D%20%27new%27%20OR%20Status%20%​3D%20%27stalled%27%20%29%20AND%20%27CF.{Tag}%27%20%3D%20%27testneeded%27&RowsPerPage=0
02:03 Mouq Hm
02:03 Mouq http://yo.io/c2a
02:03 Mouq ^^ less godawful link
02:05 lue r: sub foo(@Y, @Z) { say @Y.perl; say @Z.perl }; my @a = [1,2],[3,4]; my @b = @a[0]; my @c = @a[1]; foo(@b, @c); foo(@a[0], @a[1]);
02:05 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«Array.new([1, 2])␤Array.new([3, 4])␤Array.new(1, 2)␤Array.new(3, 4)␤»
02:06 TimToady but that's probably a reasonable behavior for multi-arg grep, if we decide it should have one
02:06 lue Please tell me I'm not wrong for thinking @b = @a[0] should DWIM ? (It used to work, in any case :/)
02:06 TimToady if the original was saved with a [], it's an item
02:06 adu joined #perl6
02:07 Mouq TimToady: I imagine grep should at least complain when given a >1arity argument
02:07 * TimToady just had to fix an RC entry for that
02:07 lue TimToady: The array ultimately is a return'd (@old, @new).lol
02:08 lue (using := makes it DWIM, by the way)
02:10 lue TimToady: I assume this newfangled behavior is the right one, correct?
02:12 Mouq r: sub foo(@Y, @Z) { say @Y.perl; say @Z.perl }; my @a = [1,2],[3,4]; sub n(\p) { p }; my @b = n(|@a[0]); my @c = n(|@a[1]); foo(@b, @c); foo(@a[0], @a[1]);
02:12 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤  in sub n at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
02:12 Mouq r: sub foo(@Y, @Z) { say @Y.perl; say @Z.perl }; my @a = [1,2],[3,4]; sub n(|p) { return |p }; my @b = n(|@a[0]); my @c = n(|@a[1]); foo(@b, @c); foo(@a[0], @a[1]);
02:12 camelia rakudo-parrot 11a693, rakudo-jvm 11a693, rakudo-moar 11a693: OUTPUT«Array.new(1, 2)␤Array.new(3, 4)␤Array.new(1, 2)␤Array.new(3, 4)␤»
02:12 timotimo isn't that what || is for?
02:12 lue @b := @a[0] does the trick
02:13 Mouq @b = |@a[0] should do it as ^^ above I think shows, but NYI :(
02:20 dalek roast: 1119261 | Mouq++ | S02-lexical-conventions/one-pass-parsing.t:
02:20 dalek roast: Copy Brent Laabs' tests for RT #76988
02:20 dalek roast: review: https://github.com/perl6/roast/commit/1119261c17
02:20 synopsebot Link: https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=76988
02:22 rurban joined #perl6
02:24 rurban1 joined #perl6
02:29 xragnar_ joined #perl6
02:29 xenoterracide joined #perl6
02:34 hoverboard joined #perl6
02:42 dalek roast: 27d6be5 | Mouq++ | S02-literals/adverbs.t:
02:42 dalek roast: Add adverbs tests
02:42 dalek roast: review: https://github.com/perl6/roast/commit/27d6be5cc2
02:42 dalek roast: a503ffa | Mouq++ | S02-literals/adverbs.t:
02:42 dalek roast: Add test for RT #74492
02:42 dalek roast: review: https://github.com/perl6/roast/commit/a503ffa39a
02:42 synopsebot Link: https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=74492
03:15 Mouq r: say [foo => (1,2,3).map: {$_}].perl; say {foo => (1,2,3).map: {$_}}.perl # RT #120620
03:15 synopsebot Link: https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=120620
03:15 camelia rakudo-jvm 25c75c: OUTPUT«(timeout)»
03:15 camelia ..rakudo-parrot 25c75c: OUTPUT«["foo" => (1, 2, 3).list.item]␤{"foo" => (1, 2, 3).list.item}␤»
03:15 camelia ..rakudo-moar 25c75c: OUTPUT«["foo" => (1, 2, 3).list.item]␤{"foo" => ().list.item}␤»
03:16 Mouq Looks like JVM gets it right too, locally
03:17 Mouq So, MoarVM bug :(
03:17 Mouq Though if that bug was reported in November, it had to be failing on the other backends originally… hm
03:18 Mouq (Obviously needs a test)
03:18 Mouq (But I'm going to bed)
03:18 Mouq ((So g'night #perl6)
03:18 Mouq )
03:39 anocelot joined #perl6
03:42 anaeem1 joined #perl6
04:33 cotto joined #perl6
04:40 masak Mouq: re expected behavior of https://rt.perl.org//Public​/Bug/Display.html?id=71544 -- .map can work with n-ary blocks; it just slurps n elements per invocation. seems to me there's no reason .grep couldn't/shouldn't do the same.
05:02 masak oh, and the PDF I linked the other day was also the first time I felt I grok'd the Axiom of Choice.
05:18 ilogger2 joined #perl6
05:18 kshannon joined #perl6
05:18 robinsmidsrod joined #perl6
05:18 silug____ joined #perl6
05:18 ashleydev joined #perl6
05:18 Util joined #perl6
05:18 LordV joined #perl6
05:18 stevan_ joined #perl6
05:18 tadzik joined #perl6
05:18 xybre joined #perl6
05:18 [Coke] joined #perl6
05:18 SHODAN joined #perl6
05:18 salv0 joined #perl6
05:18 sjn joined #perl6
05:18 JimmyZ joined #perl6
05:18 Pleiades` joined #perl6
05:18 molaf joined #perl6
05:18 telex joined #perl6
05:18 klapperl_ joined #perl6
05:18 xenoterracide joined #perl6
05:18 Grimnir_ joined #perl6
05:18 Celelibi joined #perl6
05:18 jlaire joined #perl6
05:18 larks joined #perl6
05:18 logie_ joined #perl6
05:18 segomos joined #perl6
05:18 Bryanstein joined #perl6
05:18 adu joined #perl6
05:18 snarkyboojum joined #perl6
05:18 14WACHE1C joined #perl6
05:18 obra_ joined #perl6
05:18 simula67 joined #perl6
05:18 sunnavy joined #perl6
05:18 awwaiid joined #perl6
05:18 felher joined #perl6
05:18 gfldex joined #perl6
05:18 ascent_ joined #perl6
05:18 yakudza joined #perl6
05:18 jdv79 joined #perl6
05:18 renormalist joined #perl6
05:18 hugme joined #perl6
05:18 Timbus joined #perl6
05:18 eiro joined #perl6
05:18 breinbaas joined #perl6
05:18 revdiablo joined #perl6
05:18 Ulti joined #perl6
05:18 lue joined #perl6
05:18 Rounin joined #perl6
05:18 rjbs joined #perl6
05:18 apejens joined #perl6
05:18 Woodi joined #perl6
05:18 camelia joined #perl6
05:18 frettled joined #perl6
05:18 integral joined #perl6
05:18 amkrankruleuen joined #perl6
05:18 pdcawley joined #perl6
05:18 FOAD joined #perl6
05:18 nebuchadnezzar joined #perl6
05:18 effbiai joined #perl6
05:18 Exodist joined #perl6
05:18 slavik joined #perl6
05:18 djanatyn joined #perl6
05:18 mtk joined #perl6
05:18 lizmat joined #perl6
05:18 cooper joined #perl6
05:18 araujo joined #perl6
05:18 Juerd joined #perl6
05:18 mathw_ joined #perl6
05:18 cosimo_ joined #perl6
05:18 brother joined #perl6
05:18 ggoebel11119 joined #perl6
05:18 rurban_ joined #perl6
05:18 hummeleB1 joined #perl6
05:18 PZt joined #perl6
05:18 daxim_ joined #perl6
05:18 risou joined #perl6
05:18 itz joined #perl6
05:18 clkao joined #perl6
05:18 sorear joined #perl6
05:18 flussence joined #perl6
05:18 TimToady joined #perl6
05:18 aindilis joined #perl6
05:18 eternaleye joined #perl6
05:18 DarthGandalf joined #perl6
05:18 woolfy joined #perl6
05:18 plobsing joined #perl6
05:18 thou joined #perl6
05:18 Gothmog_ joined #perl6
05:18 sftp joined #perl6
05:18 FROGGS joined #perl6
05:18 simcop2387 joined #perl6
05:18 clkaoud joined #perl6
05:18 broquaint joined #perl6
05:18 cognominal joined #perl6
05:18 Alina-malina joined #perl6
05:18 mattp__ joined #perl6
05:18 Psyche^_ joined #perl6
05:18 mtj_ joined #perl6
05:18 IllvilJa joined #perl6
05:18 d^_^b joined #perl6
05:18 cxreg joined #perl6
05:18 Vlavv joined #perl6
05:18 dagurval_ joined #perl6
05:18 avar joined #perl6
05:18 kst joined #perl6
05:18 pmichaud joined #perl6
05:18 Maddingue joined #perl6
05:18 felipe joined #perl6
05:18 ingy joined #perl6
05:18 moritz joined #perl6
05:18 BooK joined #perl6
05:18 rhr joined #perl6
05:18 corecatcher joined #perl6
05:18 BinGOs joined #perl6
05:18 charsbar_______2 joined #perl6
05:19 BenGoldberg joined #perl6
05:19 xragnar joined #perl6
05:19 baest joined #perl6
05:19 PerlJam joined #perl6
05:19 bcode joined #perl6
05:19 isacloud__ joined #perl6
05:19 yogan joined #perl6
05:19 timotimo joined #perl6
05:19 pnu joined #perl6
05:19 _sri joined #perl6
05:19 Alula_ joined #perl6
05:19 thilp joined #perl6
05:19 prammer joined #perl6
05:19 ggherdov joined #perl6
05:19 jnthn joined #perl6
05:19 sergot joined #perl6
05:19 Khisanth joined #perl6
05:19 ponbiki joined #perl6
05:19 sivoais joined #perl6
05:19 erdic joined #perl6
05:19 pecastro_ joined #perl6
05:19 dalek joined #perl6
05:19 lee_ joined #perl6
05:19 [particle] joined #perl6
05:19 ldthien0 joined #perl6
05:19 Bucciarati joined #perl6
05:19 geekosaur joined #perl6
05:19 mkz joined #perl6
05:19 dylanwh joined #perl6
05:19 tokuhirom joined #perl6
05:24 sivoais joined #perl6
05:27 anaeem1 joined #perl6
05:30 cibs joined #perl6
05:30 xfix joined #perl6
05:30 mhasch joined #perl6
05:30 go|dfish joined #perl6
05:30 takesako____ joined #perl6
05:30 yeltzooo joined #perl6
05:30 synopsebot joined #perl6
05:30 REPLeffect joined #perl6
05:30 labster joined #perl6
05:30 lestrrat joined #perl6
05:30 arnsholt joined #perl6
05:30 huf joined #perl6
05:30 yoleaux joined #perl6
05:30 Tene joined #perl6
05:30 raydiak joined #perl6
05:30 zamolxes joined #perl6
05:30 bowtie joined #perl6
05:31 xiaomiao joined #perl6
05:38 xiaomiao joined #perl6
05:48 eMBee joined #perl6
05:50 Ven_ joined #perl6
05:54 ivan`` joined #perl6
06:03 rurban joined #perl6
06:48 masak rule #1 of floating-point arithmetic: avoid floating-point arithmetic.
07:04 rurban joined #perl6
07:06 rurban1 joined #perl6
07:06 darutoko joined #perl6
07:13 adu masak: lol
07:15 rurban joined #perl6
07:18 sivoais joined #perl6
07:19 rurban joined #perl6
07:19 ClarusCogitatio joined #perl6
07:30 erdic joined #perl6
07:33 naderghanbari joined #perl6
07:33 naderghanbari Hi all
07:35 Guest34297 naderghanbari: hi!
07:35 kurahaupo joined #perl6
07:37 xiaomiao joined #perl6
07:48 rurban joined #perl6
07:50 rurban1 joined #perl6
07:56 rindolf joined #perl6
07:59 molaf_ joined #perl6
08:07 anaeem1 joined #perl6
08:10 Rotwang joined #perl6
08:19 adu hi
08:21 masak hi adu
08:21 adu how goes?
08:22 adu I'm having trouble building rakudo
08:24 masak building rakudo works fine here, thanks.
08:24 masak bbl
08:24 xiaomiao adu: what doesn't work?
08:25 adu http://pastie.org/9076678
08:26 xiaomiao segmentation fault? how rude
08:26 xiaomiao can you reproduce that?
08:26 adu I'm not sure, but nqp-[mpj] build fine
08:26 adu xiaomiao: yes, every time
08:26 xiaomiao hmm, that's "nice"
08:27 adu but I'm trying to build perl6-[mpj] and that's not working so well
08:27 adu I could try to build each backend separate, to see if it's only one of them
08:29 xiaomiao what exactly segfaults? make ?
08:29 adu i dunno
08:30 adu it looks like ExtUtils::Command is the last to run
08:31 xiaomiao what platform are you on? linux?
08:31 adu macosx
08:31 adu 10.9
08:33 xiaomiao hmm, then I have to claim ignorance ;)
08:33 xiaomiao one of these platforms I have no idea how to debug
08:38 tomaw joined #perl6
08:50 rurban joined #perl6
08:51 klapperl joined #perl6
08:59 SamuraiJack__ joined #perl6
09:19 cibs joined #perl6
09:19 xfix joined #perl6
09:19 mhasch joined #perl6
09:19 go|dfish joined #perl6
09:19 takesako____ joined #perl6
09:19 yeltzooo joined #perl6
09:19 synopsebot joined #perl6
09:19 REPLeffect joined #perl6
09:19 labster joined #perl6
09:19 lestrrat joined #perl6
09:19 arnsholt joined #perl6
09:19 huf joined #perl6
09:19 yoleaux joined #perl6
09:19 Tene joined #perl6
09:19 raydiak joined #perl6
09:19 zamolxes joined #perl6
09:19 bowtie joined #perl6
09:40 klapperl_ joined #perl6
09:41 spider-mario joined #perl6
09:43 vendethiel joined #perl6
09:51 rurban joined #perl6
10:33 dmol joined #perl6
10:35 rurban joined #perl6
10:45 bjz_ joined #perl6
10:50 FROGGS[mobile] joined #perl6
11:02 anaeem1 joined #perl6
11:12 kaare_ joined #perl6
11:22 anaeem1_ joined #perl6
11:25 vendethiel joined #perl6
11:26 itz_ I'm getting a MoarVM link error on NetBSD linking moar
11:26 itz_ ./libmoar.so: undefined reference to `pthread_yield'
11:26 itz_ I think that should be sched_yield on that platform
11:29 * jnthn wonders if that's a Moar or libuv thing.
11:29 tadzik seems like libuv's fault
11:29 lizmat wow: Files=801, Tests=31026, 173 wallclock secs ( 7.89 usr  3.52 sys + 1148.80 cusr 78.54 csys = 1238.75 CPU)
11:29 itz_ I think it's not linking a fixes file under libuv
11:29 jnthn ah
11:29 lizmat below 3 minutes!
11:29 jnthn No, it's ours I think...
11:30 jnthn itz_: It may be that also
11:30 jnthn itz_: But see src/platform/threads.h
11:31 jnthn itz_: There's a #elif on line 3 that likely wants a netbsd or other appropriate entry too
11:32 itz_ ok I see
11:32 jnthn lizmat: Latest Moar exits faster, so I suspect we got the win from there. :)
11:32 lizmat aha...   ok  :-)
11:32 spider-mario joined #perl6
11:33 jnthn lizmat: Still, nice you can do it in under 3 mins :)
11:34 lizmat indeed  :-)
11:34 lizmat although CPU usage has also dropped
11:34 jnthn Good for your battery? :)
11:35 lizmat yesterday: 1317.74, now 1238.75
11:35 itz_ adding defined(__NetBSD__) to that line fixes it .. will run tests too
11:35 jnthn Well, we're doing a lot less work at exit
11:36 rurban joined #perl6
11:36 jnthn So that's probably why it's down :)
11:36 lizmat and that's just way cool
11:37 jnthn The same work landed a fix for the "abort at exit" issue some threaded things ran into
11:37 jnthn m: Thread.start({ sleep 1; say 'kthxbai' }); say 'oh hai';
11:37 camelia rakudo-moar 25c75c: OUTPUT«oh hai␤kthxbai␤»
11:37 jnthn That also now works
11:37 jnthn m: Thread.start({ sleep 1; say 'kthxbai' }, :app_lifetime); say 'oh hai';
11:37 camelia rakudo-moar 25c75c: OUTPUT«oh hai␤»
11:37 jnthn And that. :)
11:37 lizmat cool cool cool!
11:47 tadzik took 6 minutes here, but failed some tests :(
11:47 G-one joined #perl6
11:47 tadzik https://gist.github.com/tadzik/10580661
11:47 tadzik damn, I remember when it was close to an hour :D
11:49 colomon joined #perl6
11:51 lizmat tadzik: same here
11:52 timotimo o/
11:52 lizmat concurrency/lock is mine, I guess I will fudge / remove them
11:52 lizmat main-usage I have no idea
11:52 lizmat phasers/first apparently only happens on OSX
11:52 tadzik only happens positively? :)
11:52 lizmat not been able to golf it yet
11:52 jnthn I'm...thinking tadzik ain't on OSX?
11:52 tadzik nope
11:53 lizmat then it *can* be reproduced elsewhere
11:53 tadzik :)
11:53 jnthn lizmat: And it was only failing sometimes, yes?
11:53 tadzik happy to help
11:53 lizmat it seems to fail more often now
11:53 tadzik when I run that individual test, it consistently passes
11:53 lizmat indeed, it only fails if part of a parallel spectest
11:53 lizmat so it appears to be CPU load-related
11:54 lizmat which is strange for a non-threaded feature
11:55 jnthn lizmat: nwc10++ gave me an ASAN backtrace and mentioned some things are giving those in spectest.
11:55 jnthn lizmat: I didn't managed to figure it out yet, but memory randomization is enough if we're reading stuff we shouldn't be.
11:56 lizmat ok
11:57 jnthn Sadly, MSVC's heap analysis doesn't trigger it.
11:59 anaeem1__ joined #perl6
12:05 dalek star: de33c20 | jnthn++ | / (2 files):
12:05 dalek star: Switch over to FROGGS MIME::Base64 module.
12:05 dalek star:
12:05 dalek star: Has fixes for running on Moar/JVM.
12:05 dalek star: review: https://github.com/rakudo/star/commit/de33c20b2a
12:11 tadzik uh, Digest::MD5 :)
12:12 dalek star: e0657f2 | jnthn++ | modules/ (3 files):
12:12 dalek star: Bump various modules.
12:12 dalek star:
12:12 dalek star: With this, we can now build a Rakudo Star that passes module tests on
12:12 dalek star: MoarVM.
12:12 dalek star: review: https://github.com/rakudo/star/commit/e0657f2cfe
12:12 timotimo ooooh yay :)
12:12 jnthn Oh!!
12:12 jnthn tadzik: yeah...what was I thinking :)
12:12 tadzik aww yiss
12:12 timotimo then you can get even more optimizations into the star before it lands :D
12:13 jnthn Well, or we may want to look at the state of r-j :)
12:13 jnthn In Star.
12:13 timotimo oh, of course
12:13 timotimo so, what's our stance on 32bit moarvm?
12:13 jnthn But this does mean we can at least have a distar. :)
12:13 jnthn timotimo: 32-bit on what arch?
12:13 timotimo linux, intel
12:13 denis_boyun joined #perl6
12:13 jnthn timotimo: I'd hope it'd work out on x86.
12:13 jnthn Yeah, shoudl work. If not, wants but hunging
12:14 jnthn ...
12:14 jnthn bug hunting
12:14 timotimo someone on reddit pointed out that x86 gives trouble with NativeCall
12:14 timotimo the array tests are like "hey, you wanted a 5, but this is a 324985724309857, what gives?"
12:14 timotimo so kinda looks like two pieces of the puzzle have a different opinion on what an int is?
12:15 jnthn Ah, it's probably "long"...
12:15 jnthn Guess I'll need to try and get myself a 32-bit VM
12:15 jnthn Oh, I may have one on my laptop...
12:15 jnthn And I'm heading away from home soon anyway for teaching trip. So will look on that while I'm away.
12:16 dalek rakudo/nom: 80171d8 | (Elizabeth Mattijsen)++ | docs/ChangeLog:
12:16 dalek rakudo/nom: Some Changelog additions
12:16 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/80171d8111
12:22 * lizmat just spectested the 2014.03 release: 220 wallclock (vs 173 now), 1589.9 CPU versus 1238.75 now.
12:22 lizmat We've come a long way in this month!
12:23 jnthn Well, especially if you remember that 2014.03 wasn't running the threads tests, or unival tests... :)
12:24 jnthn Anyway, yeah, productive month :)
12:26 moritz and it's not over yet :-)
12:26 moritz though I notice that release day is early this month
12:27 moritz (on 17th, that is, this week; because 1st was a Tue)
12:27 jnthn I don't think we'll do anything too risky opt wise ahead of release.
12:28 jnthn I've decided I'm going to focus on async stuff in the next week: getting timers working on Moar, then adding I/O event notification supplies and async socket I/O.
12:28 jnthn (Not saying I'll manage it all in a week. otoh, stranger things have happened...)
12:29 jnthn I should actually have some non-"oh look a contrived demo" things to show off related to reactive programming in Perl 6 for my nlpw talk... :)
12:30 timotimo when is that?
12:30 jnthn Later this month...
12:30 jnthn Couple of weeks or so.
12:30 timotimo and that'll be on HEAD?
12:30 jnthn yeah :)
12:30 jnthn Well
12:31 jnthn All my live demos ever done on Rakudo I think have run on HEAD
12:31 timotimo sounds wise
12:31 jnthn Well, no, it's dangerous, you never know what mighta sneaked in :P
12:31 timotimo well ... yeah
12:31 timotimo that's why you write out your presentation in the form of tests before you do it :)
12:32 jnthn But generally things work out fine. We don't do too badly at keeping HEAD working well.
12:32 timotimo aye
12:34 masak release day is on Thursday, by masak, jetlagged. :>
12:34 jnthn ahaha
12:34 jnthn That was some clever planning :P
12:34 masak :>
12:34 masak clever or not, it *was* planning.
12:36 rurban joined #perl6
12:41 zakharyas joined #perl6
12:42 klapperl joined #perl6
12:46 FROGGS[mobile] that is compiler release day, right?
12:47 timotimo are we going to bump parrot revision this month?
12:47 timotimo there was some performance improvements this month, no?
12:47 FROGGS[mobile] because I will have no time on monday and tuesday to fix things for r-j*
12:47 jnthn timotimo: Are there things there to make it worth it, and are we willing to do the testing?
12:47 timotimo did it get the environment fix?
12:47 timotimo environment for qx?
12:47 jnthn That'd sound worth bumping for.
12:48 xenoterracide joined #perl6
12:48 FROGGS[mobile] timotimo: no
12:48 timotimo i think so. though the project i wanted it for is now fine to run on moar, so ... :P
12:48 FROGGS[mobile] there was just an issue, not working parrot and rakudo code and a discussion
12:49 timotimo who tried to fix it? it was rurban_, wasn't it?
12:49 FROGGS[mobile] yes
12:49 timotimo and then pmichaud voted against the inclusion of more parrot-specific code to the core setting
12:49 timotimo vetod*
12:49 klapperl_ joined #perl6
12:49 FROGGS[mobile] yes, because it was the wrong approach
12:49 timotimo aye
12:50 jnthn Ah, I recall now. I think there were multiple issues with that fix...
12:50 timotimo nobody, not even me, came up with a proper fix yet, though
12:50 jnthn "use moar"? :P
12:50 FROGGS[mobile] *g*
12:50 timotimo yeah, i've been doing that for now
12:50 nwc10 it's not actually a state secret
12:50 nwc10 rn: class A{}; A::boom(:foo)
12:51 camelia rakudo-parrot 25c75c: OUTPUT«Could not find symbol '&boom'␤  in method <anon> at gen/parrot/CORE.setting:12574␤  in any  at gen/parrot/Metamodel.nqp:2710␤  in any find_method_fallback at gen/parrot/Metamodel.nqp:2698␤  in any find_method at gen/parrot/Metamodel.nqp:949␤  i…»
12:51 camelia ..niecza v24-109-g48a8de3: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type Any␤  at /tmp/tmpfile line 1 (mainline @ 5) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4595 (ANON @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 4596 (module-CO…»
12:51 camelia ..rakudo-jvm 25c75c: OUTPUT«Could not find symbol '&boom'␤  in method <anon> at gen/jvm/CORE.setting:12553␤  in any  at gen/jvm/Metamodel.nqp:2627␤  in any find_method_fallback at gen/jvm/Metamodel.nqp:2626␤  in any find_method at gen/jvm/Metamodel.nqp:948␤  in any  at gen/j…»
12:51 camelia ..rakudo-moar 25c75c: OUTPUT«===SORRY!===␤Could not find symbol '&boom'␤»
12:51 nwc10 that's a read 1 beyond a malloc'd area, as reported by valgrind and ASAN on MoarVM
12:51 nwc10 yes, it's a Perl 6 runtime error
12:52 masak nwc10: looks fine above, though.
12:52 timotimo well, you could be doing it in an eval, so that could still be problematic
12:52 jnthn nwc10: It goes away if MVM_SPESH_DISABLE=1 is set in the env?
12:52 nwc10 masak: run it under valgrind
12:52 jnthn nwc10: Or still there?
12:52 jnthn That'll give a sizable clue...
12:52 nwc10 same error with MVM_SPESH_DISABLE=1
12:52 jnthn ok, I didn't think it was gonna be that...
12:53 timotimo doesn't valgrind also give you a stack trace for the wrong read?
12:53 nwc10 timotimo: yes. Here's one from ASAN: http://paste.scsys.co.uk/346819
12:53 nwc10 it's trying to copy subroutine argument flags
12:53 jnthn nwc10: http://paste.scsys.co.uk/346819
12:53 jnthn oops, too slow :)
12:53 nwc10 arg_count is one more than it should be
12:53 nwc10 it is not clear how that happens
12:54 jnthn arg_count = 3, num_pos = 1,
12:55 jnthn That implies a positional and a named
12:55 dalek rakudo/nom: f9c9487 | (Elizabeth Mattijsen)++ | src/core/Bag (2 files):
12:55 dalek rakudo/nom: Introduce direct .min/.max on Bags/BagHashes
12:55 dalek rakudo/nom:
12:55 dalek rakudo/nom: Actually inspired by a code example of TheDamian that looked hacky, since one
12:55 dalek rakudo/nom: of the more common uses of Bags/BagHashes are to find out the frequence of
12:55 dalek rakudo/nom: things, and hence you probably want to know the lowest/highest frequency quite
12:55 dalek rakudo/nom: often as well.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f9c948774e
12:55 nwc10 the stacktrace is for something like
12:56 nwc10 m: class TestA { }; TestA::frobnosticate(3, :foo)
12:56 camelia rakudo-moar 25c75c: OUTPUT«===SORRY!===␤Could not find symbol '&frobnosticate'␤»
12:56 jnthn Yeah. That'd be a call with a positional and a named.
12:56 nwc10 it seems that it's only the named that matters
12:56 timotimo some part of the thing isn't noticing that the sub doesn't exist? :)
12:57 jnthn Well, what's also to note is that it's in the tweak_cs codepath.
12:57 timotimo the callsite stuff has a potential source of confusion where the amount of flags is one less per named than the arg count
12:58 clkao w/win 7
12:58 nwc10 x
12:58 nwc10 :-)
13:00 jnthn yeah, and I think that's exactly what's happening
13:01 jnthn MVM_args_proc_to_callsite does the calc correctly.
13:02 jnthn find_invokee_internal does it wrong
13:06 jnthn nwc10: https://gist.github.com/jnthn/10583405
13:06 jnthn nwc10: That's to try, though not for applying; I'm going to factor the calc out into one place.
13:20 jnthn nwc10: Actually, I can't; the two places are calc'ing on values from different types.
13:20 jnthn nwc10: So if that patch helps I think it goes in :)
13:24 dalek rakudo/nom: 4f3553d | (Elizabeth Mattijsen)++ | src/core/Set (2 files):
13:24 dalek rakudo/nom: Add .min/.max to Sets/SetHashes for consistency
13:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/4f3553d34e
13:24 dalek rakudo/nom: 3ba878f | (Elizabeth Mattijsen)++ | src/core/Mix (2 files):
13:24 dalek rakudo/nom: Add .min/.max to Mixes/MixHashes for consistency
13:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3ba878f8ca
13:24 rindolf joined #perl6
13:25 raiph joined #perl6
13:25 moritz m-spectest summary (2 test failures): http://perlpunks.de/paste/show/534a9046.1568.2cb
13:26 dalek perl6-roast-data: 73c7e3e | coke++ | / (6 files):
13:26 dalek perl6-roast-data: today (automated commit)
13:26 dalek perl6-roast-data: review: https://github.com/coke/perl6​-roast-data/commit/73c7e3e2c9
13:30 lizmat moritz: again, the concurrency/lock.t, I have tests 6 or 8 fail, randomly
13:30 lizmat unfamiliar with S29-os/system: that's a new one to me
13:30 moritz same here
13:31 moritz it's fixed by 'make install'
13:31 moritz Unhandled exception: Missing or wrong version of dependency 'gen/moar/stage2/QRegex.nqp' at <unknown>:1  (/home/moritz/p6/rakudo/install/langu​ages/perl6/runtime/perl6.moarvm::295)
13:32 moritz not ok 1 - run() to an existing program does not die (and returns something true)
13:32 crazedpsyc joined #perl6
13:32 moritz seems that something prefers the installed libs over the local ones
13:32 guru joined #perl6
13:32 lizmat ah, I always do "make install" before "make spectest"
13:33 FROGGS[mobile] moritz: I merged a PR about the order of home and site or so
13:35 moritz FROGGS[mobile]: I have no ~/.perl6/, so home shouldn't matter
13:36 jnthn I've got a new failure in t\spec\S05-substitution\subst.rakudo.moar
13:37 * moritz runs p-spectest now, and is amazed how long it takes (compared to m-spectest) :_)
13:38 dalek rakudo/nom: fe27557 | (Elizabeth Mattijsen)++ | t/spectest.data:
13:38 dalek rakudo/nom: Add advent2012 tests that were sitting in roast
13:38 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fe27557064
13:38 jnthn nwc10: I gotta go catch a train soon, so pushed the patch anyway. Fairly sure it'll help.
13:38 rurban joined #perl6
13:46 telex joined #perl6
13:47 vendethiel r: class A { method ary { <a b c> } handles push; }; my $a = A.new; $a.push 1; say $a.ary;
13:47 camelia rakudo-jvm f9c948: OUTPUT«(timeout)»
13:47 camelia ..rakudo-parrot f9c948, rakudo-moar f9c948: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Two terms in a rowâ�¤at /tmp/tmpfile:1â�¤------> [32mclass A { method ary { <a b c> } [33mâ��[31mhandles push; }; my $a = A.new; $a.push [0mâ�¤    expecting any o…»
13:47 vendethiel fair enough
13:48 lizmat r: class A { method ary { <a b c> } handles push; }; my $a = A.new; $a.push: 1; say $a.ary;
13:48 camelia rakudo-parrot f9c948, rakudo-jvm f9c948, rakudo-moar f9c948: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Two terms in a row�at /tmp/tmpfile:1�------> [32mclass A { method ary { <a b c> } [33m�[31mhandles push; }; my $a = A.new; $a.push:[0m�…»
13:48 vendethiel look at the error message :). The two terms is `} handles`
13:48 lizmat :-)
13:48 vendethiel not related to `.push` vs `.push:`
13:49 lizmat well, that was wrong too:
13:49 lizmat r: my @a; @a.push 1
13:49 camelia rakudo-parrot f9c948, rakudo-jvm f9c948, rakudo-moar f9c948: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Two terms in a rowâ�¤at /tmp/tmpfile:1â�¤------> [32mmy @a; @a.push [33mâ��[31m1[0mâ�¤    expecting any of:â�¤        method argumentsâ�¤      â€¦Â»
13:49 lizmat you need the : there or parens
14:01 SamuraiJack__ joined #perl6
14:01 jnthn commute &
14:02 dalek rakudo/nom: dca5394 | (Elizabeth Mattijsen)++ | src/core/ (4 files):
14:02 dalek rakudo/nom: Inf/-Inf are not Int's but Num's
14:02 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/dca5394ba8
14:03 masak 'night, #perl6
14:04 pippo joined #perl6
14:05 jtpalmer joined #perl6
14:05 masak lizmat: why do .min and .max on a Set return a Num? isn't the type of Set elements more or less arbitrary? (including non-orderable things)
14:08 Alina-malina joined #perl6
14:08 lizmat an empty set returns Inf on .min
14:08 lizmat to be consistent
14:08 lizmat and -Inf on .max
14:09 lizmat the *number* of elements is always an integer
14:09 moritz shouldn't the return value be Real then?
14:09 lizmat in Sets, they can only be 1
14:09 moritz then it can be Int or +-Inf
14:09 lizmat well, the error I git was: Type check failed in assignment to '$!min'; expected 'Int' but got 'Num'
14:09 lizmat so I made it a Num
14:09 masak right, something is weird. Int !~~ Num.
14:10 lizmat *got
14:10 masak so any non-infinite return value will not be a Num, but an Int.
14:10 masak r: say Int ~~ Num
14:10 camelia rakudo-parrot f9c948, rakudo-jvm f9c948, rakudo-moar f9c948: OUTPUT«False␤»
14:11 lizmat hmmm....
14:11 masak 'sides, I'm pretty sure that the spec still is of the opinion that Inf *is* an Int. as well as a Num. and a Str, when it feels so inclined.
14:11 masak now, I'm not saying that that's sane. but that's what it says currently.
14:12 masak food for thought :) really 'night
14:16 dalek rakudo/nom: 2a30681 | (Elizabeth Mattijsen)++ | src/core/ (4 files):
14:16 dalek rakudo/nom: We need Real to support Inf/-Inf right now
14:16 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2a30681886
14:19 Rotwang joined #perl6
14:28 Sptsh joined #perl6
14:28 Sptsh Hello!
14:29 Sptsh Say me pls, Learn perl6 as my first programing language is good idea?
14:32 rurban joined #perl6
14:34 jnthn lizmat: Yes, Real seems like a righter choice there.
14:34 jnthn Sptsh: Probably not as a first one. Not because of the language, but because of a lack of good introductory-level material for new programmers.
14:36 Sptsh introductory-level material of?
14:38 pippo m: say (a => 1.1, b => 2.2).MixHash (+) (a => 0.5).MixHash;
14:38 camelia rakudo-moar f9c948: OUTPUT«bag(a, b(2))␤»
14:39 pippo ^^ why convert to bag?
14:39 jnthn Sptsh: There's things to read if you're a Perl 5 programmer coming to Perl 6. There's things to read if you're coming to Perl 6 with knowledge of other languages. There's not really tutorials for those coming to Perl 6 who never programmed before.
14:43 lizmat pippo: that looks like a bug to me
14:43 cognominal Sptsh, I agree with jnthn++. On the other hand, it provides an interactive shell to play with. That's a good way to learn small scale parts of the language.
14:45 dalek rakudo/nom: 36e316d | (Elizabeth Mattijsen)++ | src/core/Set.pm:
14:45 dalek rakudo/nom: Fix two Num stragglers to Real
14:45 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/36e316d9c0
14:45 jnthn cognominal: btw, it seems I may make the French Perl workshop after all this year...
14:46 pippo m: say (a => 1.1, b => 2.2).MixHash (|) (a => 0.5).MixHash;
14:46 camelia rakudo-moar dca539: OUTPUT«bag(a, b(2))␤»
14:48 pippo lizmat: also to me :-)
14:48 cognominal jnthn, you are welcome. Please submit talk proposals so we can advertise them soon enough.  This suggestion goes for other people who want to talk about Perl 6.
14:48 lizmat pippo: must check spec first
14:49 Sptsh left #perl6
14:49 cognominal I hope I can go too but my parents are often in hospitals these days and I may have to take care of them.
14:51 vendethiel jnthn: where'd it be :-) ?
14:51 vendethiel lizmat++: spacing in 36e316d9c0 seems off ?
14:52 jnthn vendethiel: The FPW? Thinks it's in a nice modern building of an ugly suburb of Paris, iirc :)
14:53 vendethiel jnthn: I'll watch out then :)
14:53 lizmat jnthn: the ugliness is mostly gone now, with even
14:54 lizmat a tram now stopping in front of the place
14:54 jnthn oh wow :)
14:54 * lizmat considers trams/trollies a sign of civilisation
14:54 jnthn I was gonna be going to the conf in Kiev instead.
14:54 jnthn But it got moved to Russia.
14:54 lizmat indeed
14:55 lizmat .oO( well, how things are going now, Kiev might be Russia anyway by the time of the Perl Mova)
14:55 lizmat *sigh*
14:56 jnthn Let's hope not. :/
14:56 vendethiel r: class A { has Real$!max; }
14:56 jnthn Russia is quite big enough already, thanks.
14:56 camelia rakudo-jvm dca539: OUTPUT«(timeout)»
14:56 camelia ..rakudo-parrot dca539, rakudo-moar dca539: ( no output )
14:56 jnthn I know 'cus I took the train end to end :P
14:57 * vendethiel just thinks it reads poorly
14:57 jnthn vendethiel: Yes, well, don't write it then :P
14:57 vendethiel jnthn: https://github.com/rakudo/rakudo/pull/256
14:58 vendethiel this isn't a IHDWDDIT
14:59 vendethiel DIHWIDT*
14:59 dalek rakudo/nom: 2837807 | Nami-Doc++ | src/core/Set.pm:
14:59 dalek rakudo/nom: Fix spacing
14:59 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2837807cc0
14:59 dalek rakudo/nom: 7d2e554 | jonathan++ | src/core/Set.pm:
14:59 dalek rakudo/nom: Merge pull request #256 from Nami-Doc/patch-1
14:59 dalek rakudo/nom:
14:59 dalek rakudo/nom: Fix spacing
14:59 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/7d2e5547df
14:59 jnthn yeah, it's just unpretty :)
15:00 hoelzro joined #perl6
15:02 lizmat hehe. almost simultaneous fix, vendethiel++
15:04 dalek roast: 02346c6 | (Elizabeth Mattijsen)++ | S02-types/ (6 files):
15:04 dalek roast: Add tests for .min/.max on (Set|Bag|Mix)Hash
15:04 dalek roast: review: https://github.com/perl6/roast/commit/02346c690c
15:06 jnthn vendethiel: http://journeesperl.fr/fpw2014/
15:06 FROGGS joined #perl6
15:07 vendethiel and it's free !
15:08 vendethiel thanks jnthn :-)
15:13 jnthn I may only be able to make the Fridya evening/Saturday.
15:15 cognominal jnthn, that would be great
15:17 jnthn (My schedule currently suggest I have an evening lecture to do on Thursday in Sweden)
15:17 FROGGS o/ from my couch!
15:17 jnthn FROGGS: o/ :)
15:18 FROGGS :o)
15:18 * jnthn is on a train with FREE CAKE
15:18 cognominal jnthn, that's not a very nice part of Paris. But at last, most of the construction work is finished. Because of that, one year ago, going out of the subway, I thought first I was in the wrong place.
15:18 jnthn cognominal: Yes, it was under construction last time I was there. :)
15:18 jnthn cognominal: Venue has always been a nice place, though.
15:18 cognominal yes, and it is free!!
15:19 cognominal now, there is fablab there too.
15:20 dalek specs: 9213b13 | (Elizabeth Mattijsen)++ | S32-setting-library/Containers.pod:
15:20 dalek specs: Spec .min/.max on Bags
15:20 dalek specs: review: https://github.com/perl6/specs/commit/9213b13820
15:22 cognominal lizmat, I hope you will come too to fpw and propose Perl 6 talks or do you have other engagements?
15:24 lizmat we'll probably make it to FPW this year
15:24 lizmat but are not sure yet
15:24 lizmat as soon as we are, we will register and I will propose "How The Camel Is De-Cocooning" as a presentation
15:28 colomon joined #perl6
15:33 cognominal With all the IO stuff going on, that could be "Perl 6 not autist anymore"
15:33 vendethiel website says "[...] in bold (they paid their ticket or will be doing a presentation)" (?)
15:34 guru joined #perl6
15:35 lizmat some presenters insist on paying their ticket  :-)
15:38 lizmat one of the few things that Damian discussed in Zürich and which didn't work (yet), was "is cached"
15:38 cognominal speaking of moving to Russia, that may happen to a forthcoming conference in Kiev.  :(
15:38 moritz nr: try { say $_ } given 2
15:38 lizmat cognominal: if you're referring to Mova, that *is* already moved, afak
15:39 camelia rakudo-jvm 7d2e55: OUTPUT«(timeout)»
15:39 camelia ..rakudo-parrot 7d2e55, niecza v24-109-g48a8de3: OUTPUT«2␤»
15:39 camelia ..rakudo-moar 7d2e55: OUTPUT«Nil␤»
15:39 lizmat oops, that feels wrong
15:39 moritz RT 111704
15:39 moritz passing TODO on p-spectest
15:40 lizmat r: given 2 { try { .say } }
15:40 camelia rakudo-parrot 7d2e55, rakudo-jvm 7d2e55, rakudo-moar 7d2e55: OUTPUT«2␤»
15:40 lizmat seems only postfix given is affected
15:40 jnthn Ah, it's one of those broken thunk things I'll get.
15:40 jnthn *bet
15:40 cognominal vendethiel, where in the site to you see a mention of paying? this is probably boilerplate from the ACT software that handles the conference.
15:41 vendethiel cognominal: http://journeesperl.fr/fpw2014/search
15:41 lizmat cognominal: a free conference is where one has automatically paid when registered ?
15:42 dalek roast: 64d2ee6 | moritz++ | S04-statements/try.t:
15:42 dalek roast: refudge test for rakudo
15:42 dalek roast:
15:42 dalek roast: passes on parrot, so only needs TODOing on JVM and Moar
15:42 dalek roast: review: https://github.com/perl6/roast/commit/64d2ee60e9
15:46 dalek roast: 627aae5 | moritz++ | / (2 files):
15:46 dalek roast: remove some outdated rakudo.parrot fudges
15:46 dalek roast: review: https://github.com/perl6/roast/commit/627aae5e38
15:47 dalek rakudo/nom: 3e1f329 | moritz++ | t/spectest.data:
15:47 dalek rakudo/nom: advent2013-day19.t is a concurrency test
15:47 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3e1f329592
15:48 lizmat moritz++
15:49 * moritz tries to get clean {m,p} spectest runs for the release
15:52 FROGGS moritz++
15:54 cognominal vendethiel, lizmat, fpw is free, even more though for people who do talks
15:54 vendethiel cognominal, I'm registered :). Glad it's free, else I wouldn't be able to attend it
15:55 cognominal s/though/so/
15:57 dalek roast: caeebea | (Elizabeth Mattijsen)++ | S17-concurrency/lock.t:
15:57 dalek roast: Fudge Thread stress test for now
15:57 dalek roast: review: https://github.com/perl6/roast/commit/caeebea1f8
16:12 lizmat r: my $r = sub ($x) {}; say $r.signature.returns
16:12 camelia rakudo-parrot 7d2e55, rakudo-jvm 7d2e55, rakudo-moar 7d2e55: OUTPUT«(Mu)␤»
16:12 lizmat shouldn't that be (Any) ?
16:13 moritz lizmat: no
16:13 moritz lizmat: that'd mean you can't return junctions without explicit declaration
16:14 lizmat ah, ok I guess :-)
16:14 jnthn yeah, Mu is right by spec, afaik
16:15 lizmat I'm trying to implement a production grade "is cached"  :-)
16:16 lizmat I guess what I need is a .WHICH on the signature
16:16 lizmat to be used as a key in the hash
16:16 moritz t/spec/S02-types/mixhash.rakudo.jvm .......................... Failed 1/199 subtests  (less 26 skipped subtests: 172 okay)
16:16 lizmat am I on the right path here?
16:16 moritz why on the signature?
16:16 vendethiel moritz: shouldn't that "less" be "minus" ?
16:17 moritz vendethiel: where?
16:17 vendethiel "less 26 skipped"
16:17 lizmat well, because that's where the parameters live ?
16:18 moritz lizmat: I still don't see why you need it
16:18 jnthn lizmat: On the capture surely?
16:18 lizmat duh
16:18 moritz lizmat: you need to cache per routine and capture
16:18 lizmat that's what I meant  :-)
16:19 jnthn It's the arguments you want to cache on, rather than the parameters :)
16:19 jnthn Anyway, yes, a Capture.WHICH sounds like a sane approac.
16:19 jnthn *approach
16:19 lizmat parameters / arguments , what's the difference  :-)
16:20 moritz property / debt, what's the difference :-)
16:20 jnthn callee / caller, what's the difference :-)
16:20 moritz ugh, the j-spectest takes 2.5GB RAM
16:21 moritz (single process)
16:22 lizmat r: my $r = sub ($x) { say $r.Capture.perl }; $r("foo")   # interesting
16:22 camelia rakudo-jvm 7d2e55: OUTPUT«java.lang.NullPointerException␤  in method list at gen/jvm/CORE.setting:6905␤  in method perl at gen/jvm/CORE.setting:6973␤  in sub  at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
16:22 camelia ..rakudo-parrot 7d2e55: OUTPUT«Null PMC access in clone()␤  in method list at gen/parrot/CORE.setting:6909␤  in method perl at gen/parrot/CORE.setting:6977␤  in method perl at gen/parrot/CORE.setting:1060␤  in sub  at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
16:22 camelia ..rakudo-moar 7d2e55: OUTPUT«(signal )»
16:23 vendethiel r: say $*DIR; say $*EXECUTABLE;
16:23 camelia rakudo-jvm 7d2e55: OUTPUT«Dynamic variable $*DIR not found␤  in method gist at gen/jvm/CORE.setting:12548␤  in sub say at gen/jvm/CORE.setting:13461␤  in block  at /tmp/tmpfile:1␤␤»
16:23 camelia ..rakudo-moar 7d2e55: OUTPUT«===SORRY!===␤Dynamic variable $*DIR not found␤»
16:23 camelia ..rakudo-parrot 7d2e55: OUTPUT«Dynamic variable $*DIR not found␤  in method gist at gen/parrot/CORE.setting:12569␤  in method gist at gen/parrot/CORE.setting:1056␤  in sub say at gen/parrot/CORE.setting:13503␤  in block  at /tmp/tmpfile:1␤␤»
16:23 moritz well, coercing a routine to a routine a Capture doesn't make much sense
16:23 FROGGS r: say $*CWD; say $*EXECUTABLE;
16:23 camelia rakudo-jvm 7d2e55: OUTPUT«IO::Path</home/p6eval_eval>␤IO::Path​</home/p6eval/rakudo-inst-1/bin/perl6-j>␤»
16:23 camelia ..rakudo-parrot 7d2e55: OUTPUT«IO::Path</home/p6eval>␤IO::Path<​/home/p6eval/rakudo-inst/bin/perl6-p>␤»
16:23 camelia ..rakudo-moar 7d2e55: OUTPUT«IO::Path</home/p6eval>␤IO::Path</​home/p6eval/rakudo-inst-1/bin/perl6-m>␤»
16:24 vendethiel m: say $*CWD.Str;
16:24 camelia rakudo-moar 7d2e55: OUTPUT«/home/p6eval␤»
16:24 thilp joined #perl6
16:25 vendethiel r: say "a\nb".lines;
16:25 camelia rakudo-parrot 7d2e55, rakudo-jvm 7d2e55, rakudo-moar 7d2e55: OUTPUT«a b␤»
16:25 vendethiel r: say "a\nb".lines.perl; say "a\r\nb".lines.perl;
16:25 camelia rakudo-parrot 7d2e55, rakudo-jvm 7d2e55, rakudo-moar 7d2e55: OUTPUT«("a", "b").list␤("a\r", "b").list␤»
16:26 vendethiel r: say "a\nb".lines.perl; say "a\r\nb".subst("\r" -> "").lines.perl;
16:26 camelia rakudo-parrot 7d2e55, rakudo-jvm 7d2e55, rakudo-moar 7d2e55: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Unable to parse expression in argument list; couldn't find final ')' �at /tmp/tmpfile:1�------> [32mnb".lines.perl; say "a\r\nb".subst("\r" […»
16:26 vendethiel r: say "a\nb".lines.perl; say "a\r\nb".subst("\r" => "").lines.perl;
16:26 camelia rakudo-moar 7d2e55: OUTPUT«("a", "b").list␤Cannot call 'subst'; none of these signatures match:␤:(Cool: Any $matcher, Any $replacement, *%adverbs)␤:(Str: Any $matcher, Any $replacement, Any :ii(:samecase($samecase)), Any :ss(:samespace($samespace)), Any :SET_CALLER_DOLLAR_SLAS…»
16:26 camelia ..rakudo-parrot 7d2e55: OUTPUT«("a", "b").list␤Cannot call 'subst'; none of these signatures match:␤:(Cool: Any $matcher, Any $replacement, *%adverbs)␤:(Str: Any $matcher, Any $replacement, Any :ii(:samecase($samecase)), Any :ss(:samespace($samespace)), Any :SET_CALLER_DOLLAR_SL…»
16:26 camelia ..rakudo-jvm 7d2e55: OUTPUT«("a", "b").list␤Cannot call 'subst'; none of these signatures match:␤:(Cool: Any $matcher, Any $replacement, *%adverbs)␤:(Str: Any $matcher, Any $replacement, Any :ii(:samecase($samecase)), Any :ss(:samespace($samespace)), Any :SET_CALLER_DOLLAR_SLASH…»
16:26 lizmat r: sub foo ($x) { say &?ROUTINE.Capture.list }; foo("bar")  # moritz: should this work then?
16:26 camelia rakudo-parrot 7d2e55: OUTPUT«Null PMC access in clone()␤  in method list at gen/parrot/CORE.setting:6909␤  in sub foo at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
16:26 camelia ..rakudo-jvm 7d2e55: OUTPUT«java.lang.NullPointerException␤  in method list at gen/jvm/CORE.setting:6905␤  in sub foo at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
16:26 camelia ..rakudo-moar 7d2e55: OUTPUT«(signal )»
16:26 moritz lizmat: no
16:27 lizmat so how would I get at the values in the capture then?
16:27 moritz lizmat: there's an nqp:: op for getting the arglist as capture
16:27 jnthn lizmat: |c in the parameter list.
16:28 jnthn The capture is *about the current invocation*.
16:28 moritz that would have been my second suggestion
16:28 jnthn Not something static about the routine.
16:28 moritz m: sub f(|c) { say c.^name }; f 2
16:28 camelia rakudo-moar 7d2e55: OUTPUT«Capture␤»
16:28 moritz lizmat: ^^
16:28 lizmat but I need the current invocation to create a .WHICH from, to be used as a key?
16:28 moritz m: sub f(|c) { say c.WHICH }; f 2
16:28 camelia rakudo-moar 7d2e55: OUTPUT«Capture|139644193353720␤»
16:28 moritz I'm just afraid you have to patch Capture.WHICH to be something more useful
16:29 lizmat but that WHICH is just an type/address of the capture and not value based
16:29 moritz aye, that's what you have to change first
16:29 lizmat indeed, and that's what I'm trying to do
16:29 jnthn lizmat: Yes, that's what needs changing.
16:29 moritz Capture acts as a value type
16:29 jnthn Yes, but you do it by looking at $!list and $!hash inside of the Capture.
16:29 lizmat ok
16:29 moritz lizmat: just write a multi method WHICH (for :D invocant) in class Capture
16:30 lizmat yup, that far I was conceptually
16:30 lizmat now to turn the ... into something useful  :-)
16:30 jnthn To a first approximation, just taking the WHICH of each of the things in list and hash togehter with the names for the hashes is the key
16:30 moritz and of course sort the hash keys
16:31 lizmat yup, similar to Set.WHICH  :-)
16:32 jnthn With that done, then the rest is sub trait_mod:<is>(Routine:D $r, :$cached!) { my %cache{Capture}; $r.wrap(-> |c { %cache{c} //= callsame }) } or so.
16:32 lizmat yeah, I already copy pasted that from moritz++ blogpost a few years ago
16:35 timotimo jnthn: do you have ideas for making rakudo-debugger useful for multi-threaded things?
16:35 rurban joined #perl6
16:35 timotimo maybe it would be a good start to just check in what $*THREAD the hooks are being invoked and perhaps skipping them if it's not the right one?
16:35 timotimo i suspect the way it's currently doing things it'd try to run multiple prompts for commands that listen on the same stdin or something?
16:35 jnthn timotimo: I need to spend a good chunk of time thinking that through.
16:35 timotimo i feared as much
16:36 jnthn I mean, what I really want is not the "just work" solution, but something useful and awesome.
16:36 timotimo aye
16:36 timotimo a split terminal that offers one split for every thread ;)
16:36 moritz tmux integration!
16:37 xinming joined #perl6
16:37 guru joined #perl6
16:37 timotimo :3
16:37 jnthn :)
16:37 timotimo also, something that'd work on windows would be nice
16:37 jnthn Well, the other thing I want to look at is how you can understand what things are in flight at a given point in time too
16:38 timotimo yeah, that seems like a particularly tricky aspect of the whole thing
16:40 colomon joined #perl6
16:40 jnthn Right, but if we can provide a really good debugging experience there then we get a strong offering.
16:41 jnthn One of the things .Net devs tell me is they find Rx queries hard to debug, because you can't trace an items progress through it. I'm wondering if we can do better with our supplies.
16:41 timotimo that would be fantastic
16:42 timotimo hmpf. i really have to spend some time trying to grok Rx, i haven't done anything in that style so far
16:43 jnthn I'll have some Perl 6 sample programs in a couple of weeks, but if you're impatient I've some C# ones you can see now :)
16:43 timotimo it'd certainly help to figure out where applying Rx is a good idea :)
16:44 jnthn Where you have things happening asynchronously and there's a stream of them.
16:45 timotimo Rx don't introduce their own asynchrony, just like supplies, right?
16:46 jnthn Right
16:46 timotimo at each point where there's a fork in the chain, like two taps on the same supply, they't just be executed to completion in some order?
16:46 plobsing joined #perl6
16:46 vendethiel m: my @foo = [loop { 1; last; }]; say @foo;
16:46 camelia rakudo-moar 3e1f32: OUTPUT«WARNINGS:␤Useless use of constant integer 1 in sink context (line 1)␤True␤»
16:46 jnthn Yeah. It's things where time comes in, for example, where concurrency is introduced.
16:47 timotimo m: my @foo = [loop { LEAVE last; 1; }]; say @foo;
16:47 camelia rakudo-moar 3e1f32: OUTPUT«True␤»
16:47 vendethiel m: my $last = False; my @foo = [loop { if ($last) last else { $last = True; 1 } }]; say @foo;
16:47 camelia rakudo-moar 3e1f32: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/UCNFIucJzkâ�¤Missing blockâ�¤at /tmp/UCNFIucJzk:1â�¤------> [32mt = False; my @foo = [loop { if ($last) [33mâ��[31mlast else { $last = True; 1 } }]; say @f[0mâ�¤    expecting any of:â�¤        p…»
16:47 vendethiel m: my $last = False; my @foo = [loop { if $last { last } else { $last = True; 1 } }]; say @foo;
16:47 camelia rakudo-moar 3e1f32: OUTPUT«True␤»
16:47 timotimo o_O
16:47 * vendethiel is starting to feel dizzy
16:48 vendethiel brane hurts. Somebody mind explaining ?
16:48 timotimo m: my @foo = loop { LEAVE last; 1; }; say @foo;
16:48 camelia rakudo-moar 3e1f32: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/OUl9BVgkuMâ�¤Undeclared routine:â�¤    loop used at line 1â�¤â�¤Â»
16:48 timotimo m: my @foo = do loop { LEAVE last; 1; }; say @foo;
16:48 camelia rakudo-moar 3e1f32: OUTPUT«True␤»
16:48 timotimo m: my @foo = do loop { NEXT last; 1; }; say @foo;
16:48 jnthn vendethiel: Putting any loop other than a for loop in r-value context at present doens't make a huge amount of sense to Rakudo.
16:48 camelia rakudo-moar 3e1f32: OUTPUT«(timeout)»
16:48 timotimo it does not? huh.
16:48 timotimo well, maybe if it's a gather-loop
16:48 retupmoca joined #perl6
16:49 jnthn yeah, but then you're doing a gather. :)
16:49 vendethiel m: my @foo = [while False {}]; say @foo;
16:49 camelia rakudo-moar 3e1f32: OUTPUT«False␤»
16:49 punter joined #perl6
16:49 timotimo nobody commented on my number guessing game one-liner :(
16:49 vendethiel k, just returns True if it actually ran
16:49 jnthn yes, but please don't rely on that
16:50 vendethiel I won't :-)
16:50 vendethiel that's just from S04
16:51 lizmat jnthn: just got a spurious error in spectest:
16:51 lizmat t/spec/S17-concurrency/thread.rakudo.moar                   (Wstat: 0 Tests: 25 Failed: 1)
16:51 lizmat Failed test:  6
16:51 lizmat which is "Thread 1 got non-zero ID"
16:51 jnthn lizmat: hmm
16:51 lizmat can't reproduce
16:51 lizmat but that should never ever fail, so I guess there is a path where it can
16:52 jnthn Right.
16:53 vendethiel timotimo: how'd you search for "LEAVE", "NEXT" etc ? syn search won't help, doc.perl6 won't help, etc
16:54 timotimo "phaser"
16:54 timotimo or this: http://perlcabal.org/syn/index_X.html
16:54 timotimo http://perlcabal.org/syn/index_C.html i meant this
16:57 vendethiel should "LEAVE" get the same comment as "ENTER" wrt loops ?
16:58 timotimo you mean "repeats on loop blocks"?
16:58 vendethiel yes
16:59 timotimo hm, i don't see a big piece of text on the exact semantics of the LEAVE queue
17:00 vendethiel m: my $i = 0; loop { NEXT $i++; say $i; };
17:00 moritz http://perlpunks.de/paste/show/534ac2bb.6b06.15d # j-spectest output, 2 fails
17:00 camelia rakudo-moar 3e1f32: OUTPUT«(timeout)0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤10␤11​␤12␤13␤14␤15␤16␤17␤18␤19␤20␤21␤22␤23␤24␤2​5␤26␤27␤28␤29␤30␤31␤32␤33␤34␤35␤36␤37␤38␤​39␤40␤41␤42␤43␤44␤45␤46␤47␤48␤49␤50␤51…»
17:01 vendethiel And what's the difference of `UNDO { stuff; }` vs `CATCH { stuff; }` ?
17:01 timotimo the undo will not cause exceptions to be considered handled, or rethrow
17:01 jnthn CATCH catches an exception. UNDO runs when you leave a block unsuccessfully.
17:02 vendethiel well,`CATCH { stuff }` will not consider exceptions to be handled either, would it ?
17:02 jnthn Depends on stuff :P
17:02 timotimo if you have a when inside, then yes
17:02 timotimo oh, i've been meaning to ask
17:02 vendethiel yeah, *if you have a when inside* :p^
17:02 timotimo what's the exact mechanism that makes that work? is it something that's defined only for catch blocks? is it "magical"?
17:03 vendethiel I'm asking if CATCH without a when/default is the same as UNDO
17:03 timotimo i'm kind of not terribly fond of such cases of magic if they seem to come out of nowhere
17:03 jnthn timotimo: Not really. A CATCH has an implicit rethrow at the end of it.
17:03 timotimo ah, and the when, when it gets triggered, will skip the rest of its outer block
17:03 jnthn timotimo: If you write a when or a default, then you succeed out of the CATCH block.
17:04 timotimo great
17:04 jnthn r: sub foo() { die 'omg a manatee'; CATCH { succeed; } }; foo()
17:04 camelia rakudo-jvm 3e1f32, rakudo-moar 3e1f32: ( no output )
17:04 camelia ..rakudo-parrot 3e1f32: OUTPUT«succeed without when clause␤  in block  at gen/parrot/CORE.setting:559␤  in block  at gen/parrot/CORE.setting:623␤  in sub foo at /tmp/tmpfile:1␤  in block  at /tmp/tmpfile:1␤␤»
17:04 timotimo oh?
17:04 timotimo well, that's certainly interesting
17:04 jnthn uh, dunno what's going on with Parrot there. I think JVM and Moar have it right.
17:04 vendethiel m: sub foo { die 'foo'; CATCH { default } }; foo
17:05 camelia rakudo-moar 3e1f32: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/aCcLQqOObVâ�¤Missing blockâ�¤at /tmp/aCcLQqOObV:1â�¤------> [32msub foo { die 'foo'; CATCH { default [33mâ��[31m} }; foo[0mâ�¤    expecting any of:â�¤        statement listâ�¤        scoped bloc…»
17:05 vendethiel m: sub foo { die 'foo'; CATCH { default {} } }; foo
17:05 camelia rakudo-moar 3e1f32: ( no output )
17:05 jnthn vendethiel: UNDO is different; fail out of a block will trigger it also
17:06 timotimo right, like return Any?
17:06 jnthn Or that.
17:06 vendethiel jnthn: that's very, very confuse in my mind, when you say, "fail out of a block", you mean using `fail` itself ?
17:06 timotimo m: sub foo { return Any; UNDO { say "welp, that was fantastic." } }; foo();
17:06 camelia rakudo-moar 3e1f32: OUTPUT«welp, that was fantastic.␤»
17:06 timotimo m: sub foo { return 1; UNDO { say "welp, that was fantastic." } }; foo();
17:06 camelia rakudo-moar 3e1f32: ( no output )
17:06 timotimo http://perlcabal.org/syn/S04​.html#Definition_of_Success
17:06 timotimo ^ vendethiel
17:07 jnthn vendethiel: fail(...) counts too, yes
17:07 vendethiel timotimo++
17:08 timotimo i don't think i understand the piece about list context in "Definition of Success"
17:08 vendethiel r: try foo(); foo { fail "oh noes"; UNDO { say "alive" } }
17:08 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Undeclared routine:â�¤    foo used at line 1â�¤â�¤Â»
17:08 vendethiel m: try foo(); sub foo { fail "oh noes"; UNDO { say "alive" } }
17:08 camelia rakudo-moar 3e1f32: OUTPUT«alive␤»
17:08 japhb joined #perl6
17:08 vendethiel m: try { fail "oh noes"; UNDO { say "alive" } }
17:08 camelia rakudo-moar 3e1f32: OUTPUT«alive␤Unhandled exception: oh noes␤   at <unknown>:1  (/home/p6eval/rakudo-inst-2/languages/perl6/r​untime/CORE.setting.moarvm:throw:4294967295)␤ from src/gen/m-CORE.setting:12613  (/home/p6eval/rakudo-inst-2/language​s/perl6/runtime/CORE.setting.moarv…»
17:08 * vendethiel doesn't understand why this isn't catched
17:09 jnthn vendethiel: Because you didn't catch it.
17:09 jnthn UNDO is nothing to do with catching
17:09 jnthn It's all about how you leave the block
17:09 vendethiel jnthn: I know, but in my previous code, I didn't CATCH it either
17:09 jnthn KEEP/UNDO are about transactionality.
17:09 vendethiel and there were no exceptions
17:09 jnthn vendethiel: You did, you wrote "try"
17:09 vendethiel I wrote try in my last one as well
17:10 jnthn Oh...
17:10 jnthn But you weren't inside a sub.
17:10 vendethiel yeah
17:10 jnthn fail is a kind of return.
17:10 jnthn It's like return Failure.new(...) or so
17:11 vendethiel Hmm-mmh. I'm having a bit of a hard time trying for it to make sense, but this helps :D.
17:11 vendethiel I tried to look for `fail`'s doc on doc.perl6, but with no luck
17:15 japhb So ... thoughts on debugging concurrent perl6.  I have a mental image of having notional panels that can be filled with different things.  Depending on the smarts of the UI driver class, this could be multiplexed screens, split screens, just plain scrolling panels into view as needed (for a dumb terminal), tabs in a tabbed UI, whatever.  The point is panels can contain a debugging view of a particular task, similar to rakudo-debugger's current interface, but also
17:16 japhb active state of I/O handles (and the things they are connecting to), state of each Supply tree and Channel, task -> thread mapping, etc.
17:18 japhb When a task puts something into a Supply or Channel, the user can see the item go to a given Supply or Channel ID, and then in the Supply/Channel panel, see the progress of the item as it moves through, gets forked on taps, and so on.
17:19 japhb When it exits a Supply/Channel, that panel shows which task ID it goes to, and the user can switch to that task's debugging panel to see it come in and get processed.
17:19 rurban joined #perl6
17:19 japhb (And in a tiled UI with a small enough number of active tasks, you could just watch things move from panel to panel without having to switch manually.)
17:21 Rotwang joined #perl6
17:27 japhb I *think* this can be separated into layers relatively easily, but probably one more than we have now, where there is the debug binary and then a UI class.  Perhaps something like this: the debug binary providing API and hooks, several panel-generation classes that can output a rectangular panel of a particular type (debug, task map, channels/supplies, etc.) to a particular backend (ANSI text, HTML, and so on), and a panel management and UI interaction class per
17:27 japhb Not sure that's ideal, but could do the job.
17:28 jnthn Hm, lots of good ideas :)
17:28 jnthn It needs some more sophisciated UI-building mechanism than we hav enow :)
17:30 japhb True.  And I recognize it's a lot more work to do.  I'm just trying to think from the point of view of A) a hopefully quite useful UI and interaction model for the poor bastard doing concurrent debugging, and B) not *horribly* painful to write
17:30 rindolf joined #perl6
17:32 Rotwang joined #perl6
17:34 raiph joined #perl6
17:34 jnthn japhb: aye. :)
17:34 timotimo mhhh ... libcatui
17:34 jnthn Well, nice tools take effort
17:34 guru joined #perl6
17:34 timotimo i should get started on the actual design of that bloody thing at some point
17:34 jnthn timotimo: I...don't think we need to put cat pictures all over it :P
17:35 timotimo with all due respect
17:35 timotimo we totally do.
17:35 jnthn :D
17:39 japhb .oO( cat panel for HTML backend is just a YouTube feed )
17:39 timotimo :D
17:40 timotimo m: sub gimme_a_class { UNDO { say "undo triggered" }; my Mu \c := class Test { }; return c but role { method defined { True }; method unpack { c } }; }; gimme_a_class.unpack.new()
17:40 camelia rakudo-moar 3e1f32: OUTPUT«undo triggered␤»
17:40 timotimo :o
17:40 japhb I took a quick glance at what Go is doing (not searching super hard yet, so I may have missed something) but it looks like they're just doing thin wrappers over gdb, so ... eww.
17:41 jnthn ah crap...my train seems to have broken down :/
17:42 japhb Ouch, fail.
17:43 timotimo you should call railside assistance to tow you to the next garage
17:44 hoverboard joined #perl6
17:44 jnthn "have you tried turning it off and on again"
17:46 timotimo "are you sure it's plugged in?"
17:46 Mouq joined #perl6
17:47 japhb "Well, it's sitting on the electrified third rail, so ... yes."
17:48 jnthn Overhead cable in this case
17:48 rindolf joined #perl6
17:49 timotimo .o( like in most of germany )
17:50 colomon joined #perl6
17:50 jnthn yes, but your trains seem to run more reliably there :P
17:50 jnthn well, we're moving again, it seems
17:51 kurahaupo joined #perl6
17:52 jnthn But apparently can no longer achieve "full fart"
17:54 timotimo hmm
17:54 japhb halvfart is good enough for anyone
17:54 timotimo https://twitter.com/selenamar​ie/status/455345018711326722 - not sure i understand correctly
17:54 btyler joined #perl6
17:56 Mouq .tell adu FWIW I use osx 10.9 and am not having issues (just built [rakudo|nqp|moarvm]-HEAD). Usually if the build segfaults, it's because I needed to reconfigure something, so you may want to doublecheck that
17:56 yoleaux Mouq: I'll pass your message to adu.
17:57 vendethiel timotimo: basically, the guy can't even handle hearing about perl6 (I think)
17:58 vendethiel (if you tell him p6 is good, he wont get any sleep from the horror)
17:58 timotimo why would gvr say something like that?
17:59 vendethiel timotimo: because he hates perl6, probably ?
17:59 vendethiel oh, and python 2.7 until 2020. haha
17:59 anaeem1 joined #perl6
17:59 timotimo oh well. can't win 'em all.
17:59 Mouq lizmat++: While you're adding things to Bag, would you consider a method that replicates the keys by their values? Right now you have to do .pick(*).sort, which is kinda silly IMO
18:00 cognominal there is many ways to do it, now including the choice between Perl 5 and Perl 6. The nightmare gets even worse.
18:01 Mouq It came up writing this: http://codegolf.stackexchange.com/a/25716/15012 (note that the sort is necessary anyway here, but the .pick(*) doesn't feel right)
18:01 vendethiel timotimo: some ppl are answering (to the 2.7 => 2020 extention) "Python 2.7 is the Perl 5 of Python"
18:02 timotimo strange.
18:02 timotimo well, i'm going to head out for now
18:02 timotimo be back in a few
18:02 geekosaur but it's probably true. and like perl 5, it's gonna stick around whether the cool kids want it to or not, because somehow cool has yet to trump operational
18:05 vendethiel which is why some people wanted to change perl6's name, I guess
18:06 geekosaur (also the flip side of that comparison might not be something they want to think about: that python3 is python's perl6...)
18:06 Mouq geekosaur: As if python3 were that cool ;) :P
18:07 ajr joined #perl6
18:07 cognominal to their credit python3 is already there; but apparently does not bring enough to justify compatibility breaking.
18:08 geekosaur well, I get the impression that for many python2 folks, python3 is *not* realy there yet, at least not to the point that it's worth adopting
18:09 cognominal so that's even worse than I thought
18:09 geekosaur so you might see python3 as their rakudo-star
18:11 cognominal And it will stay so if they want to copy nice Perl 6 features... before realizing it is easier to adopt Perl 6 wholesale than steal from it.
18:11 _sri problem is that all the good stuff has been backported to python2
18:13 vendethiel cognominal: what did they steal ?
18:14 _sri if p5p was in a better state perl6 would be in trouble too
18:14 cognominal I don't know but once Perl 6 will be a reality they will have to react. Maybe that the meaning of the Guido quote. He can't ignore Perl 6 anymore?
18:15 vendethiel cognominal: hard to judge without context.
18:15 vendethiel _sri: p5p ? perl5 in perl5 ?
18:16 btyler perl5 porters, vendethiel
18:16 vendethiel oh, alright
18:16 cognominal we will see if we get a link to his presentation.
18:17 vendethiel tbh, from an outsider point of view, perl is dead. I did a lot of web before coming here (~ 6 months ago), php, then mostly ruby and js, and nobody even considers perl (in its global state) a threat or anything. It just doesnt exist anymore
18:17 moritz S04-phasers/first.t aborted on rakudo-moar
18:17 geekosaur it also occurs to me that, considering that perl 5 is picking up stuff form perl 6, maybe he's responding to the fact that python 2.7 is backporting stuff from python3 in the same way
18:17 vendethiel I just came to know perl6 because a core coffeescript contributor is a really big perl fan, has a fork with many features, etc
18:18 vendethiel Well, I certainly don't believe p6 people are in their own little world, but it's really how it felt from outside
18:19 cognominal vendethiel, you mean, he is forking coffeescript to make it more Perl 6 like?
18:19 vendethiel cognominal: he forked it a long time ago and added perl-ish features to it. I consider him to know more about coffee/coffee codebase than the creator.
18:20 vendethiel and I got interested in perl 6 because he uses it as an exemple often enough.
18:20 cognominal what the name of the fork?
18:20 vendethiel cognominal: github.com/satyr/coco
18:22 * moritz has trouble taking coffeescript seriously; if you want to *improve* on a language, relying on implicit scoping (esepecially if there are closures) seems like sarcasm to me
18:23 vendethiel autovivification, trying to take * where it's possible (like for array indexing), do, and something that's even more perl-ish than perl 6 has (like `a('foo')b'key here'`)
18:23 vendethiel moritz: I agree people should try to stop wanting to "improve lexical scoping" :-)
18:23 vendethiel (this fork has a kinda-fixed scoping, though)
18:24 cognominal moritz, that's indeed my main critic against coffeescript.
18:25 vendethiel (and that's the main reason why I don't use coffee as well, although I'm a team member as well. In reality, it doesn't often bit you, but when it does ...)
18:25 vendethiel (mutability is bad anyway :D.)
18:25 btyler vendethiel: there's actually a lot of super awesome web stuff in perl5. mojo is like node.js done right
18:26 vendethiel btyler: I believe it ! But nobody knows about it ! that's my point :).
18:26 btyler fair enough
18:26 vendethiel perl has no "visibility" these days
18:27 vendethiel for most people, perl is a relic from ancient time; hard to understand and to work with, with few people still using it (*for web*). That's the way it felt to me, at least.
18:27 * Mouq only discovered mojo relatively recently, because of #perl6, and my father is a diehard perl5 user :(
18:27 * vendethiel discovered mojo the same ay
18:27 _sri significant whitespace is just not cool... you can pry my curly brackets from my cold, dead hands!
18:27 vendethiel way*
18:28 Mouq s/my/his/ is I suppose
18:28 cognominal I am ashamed to say I don't even know the differences between the various Perl web toolkits.
18:28 Mouq s/is//
18:28 vendethiel Mouq: who's father then ?
18:29 vendethiel cognominal: actually, for the tweet, maybe guido thinks they "failed" "in the same sense as perl 6"
18:30 _sri python3 changed too little, perl6 changed too much... ruby2 got it just right
18:33 * _sri doesn't get how pypy and rubinius have not surpassed cpython and mri yet though
18:34 dalek roast: 9906142 | moritz++ | S (4 files):
18:34 dalek roast: JVM unfudges
18:34 dalek roast: review: https://github.com/perl6/roast/commit/990614278f
18:34 cognominal Perl 6 regex question. what is the way to transform a grouping into a negated assertion?
18:34 moritz cognominal: example?
18:34 Mouq cognominal: Depends on what you're trying to do
18:35 moritz negated assertion is <!before ...>
18:35 Mouq <-[…]> might be what you're looking for though
18:36 Mouq (Although that's just "<!before <[…]> > ." I guess)
18:36 cognominal No, that's a negated character class.
18:36 Mouq cognominal: Ah, true
18:37 cognominal but, I think <!before ... > is what I really need. thx Mouq++
18:37 vendethiel _sri: the "breaking version" of ruby was 1.9 tho
18:37 FROGGS <!before [ foo | bar ]> or just <!before foo | bar >
18:38 Mouq (moritz++)
18:38 cognominal FROGGS++, indeed
18:40 Adriaaan joined #perl6
18:40 * _sri has high hopes for mojolicious on perl6 btw. (poor parallelism in perl5 is holding us back atm.)
18:40 dalek roast: 67a7d45 | moritz++ | S04-blocks-and-statements/let.t:
18:40 dalek roast: JVM-fudge a failing test (with ticket number)
18:40 dalek roast: review: https://github.com/perl6/roast/commit/67a7d45bf3
18:41 kivutar joined #perl6
18:42 vendethiel (would love to see mojo-perl6 with perl6-to-js :-).)
18:43 moritz m: (1,2,3,2,2,2,2).MixHash.kv.perl
18:43 camelia rakudo-moar 3e1f32: ( no output )
18:43 moritz m: say  (1,2,3,2,2,2,2).MixHash.kv.perl
18:43 camelia rakudo-moar 3e1f32: OUTPUT«((1, 1), (2, 5), (3, 1)).list␤»
18:43 timotimo watch out, though, !before will not consume any characters
18:43 timotimo <-[ … ]> on the other hand will
18:43 moritz that's the nature of assertions
18:44 timotimo aye
18:44 rurban joined #perl6
18:44 timotimo to be fair, it's kind of hard to express both non-matching and consuming characters
18:45 timotimo without going insane
18:45 moritz well, you can do stuff like   [ <!before ...> . ]*
18:46 moritz which is "match any characters up to ...
18:47 dalek roast: 2053bb2 | moritz++ | S02-types/mixhash.t:
18:47 dalek roast: make MixHash.kv test more robust
18:47 dalek roast: review: https://github.com/perl6/roast/commit/2053bb2fb1
18:47 Mouq moritz++
18:50 japhb What are the prereqs for ipython support?  ZeroMQ?
18:50 japhb Anything else?
18:51 timotimo basic threading
18:52 timotimo we can fortunately do without HMAC
18:52 timotimo there needs to be a heartbeat service
18:52 xenoterracide joined #perl6
18:53 japhb Do we need SSL?
18:53 timotimo no
18:53 timotimo and if we did, i think zmq would have an abstraction in place fo rus
18:53 colomon joined #perl6
18:53 timotimo maybe
18:55 japhb OK, fair enough.  So given that r-m and r-j both have basic threading, we just need a NativeCall ZeroMQ binding and then it's just a plain old module??
18:55 japhb s:1st/'?'//
18:56 timotimo it would appear to be the case, yeah
18:57 japhb Has anybody already looked at whether NativeCall on both r-m and r-j supports everything ZeroMQ needs at this point?
18:57 japhb timotimo: Oh, before I forget (again), thanks for making GH issues for perl6-bench.
18:57 timotimo yw :)
18:57 Mouq r: $_ = "a b c"; s:ss/[<.alpha> <.ws>?]+/d  e f/; .say
18:57 pmurias joined #perl6
18:57 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«d e f␤»
18:58 moritz in m-spectest run, t/spec/S04-phasers/first.t aborts with exit code 139 after test 1; it runs fine on its own
18:58 Mouq r: $_ = "a\n\nb\t\nc"; s:ss/[<.alpha> <.ws>?]+/d  e f/; .say
18:58 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«d␤␤e        ␤f␤»
18:58 jnthn moritz: Does it work out with MVM_SPESH_DISABLE=1 ?
18:58 moritz jnthn: lemmi try
18:58 pmurias re coffescript scoping wouldn't fixing that be a trivial (although backward incompatible) change?
18:59 jnthn moritz: A fix that just landed in oarvm head may deal with it
19:00 moritz jnthn: ok, I'll try with latest moar first
19:00 moritz jnthn: I suppose I don't need to recompile nqp and rakudo for it?
19:01 rindolf joined #perl6
19:02 jnthn moritz: nope
19:03 vendethiel pmurias: it'd :-). we're currently discussing improving it a bit
19:04 moritz "use strict";
19:04 vendethiel moritz: already something in JS land ;-)
19:04 moritz vendethiel: I know
19:05 moritz it's just ironic if language A is an attempt to fix some design flaws in language B, and now language A would benefit from the same hacks that langauge B has introduced years ago...
19:06 vendethiel (or has had since the beginning)
19:06 vendethiel "if it's not broken, don't fix it", right ?
19:07 jnthn detrain, dinner; bbl &
19:07 moritz "if you think it's not broken, maybe you are?" :-)
19:07 pmurias the coffescript scoping still seems much saner the javascript one
19:09 vendethiel really ? `lst = (a i for i in [1..10]); a = -> i = 0;` #what happens here ?
19:10 vendethiel imho, let > var > coffee's scoping
19:10 moritz oh, and make use-before-declaration (compare hoisting) a compile time error
19:11 vendethiel moritz: globals
19:11 vendethiel do you specify each of them ?
19:11 moritz vendethiel: which globals are you talking about?
19:11 moritz vendethiel: then ones I introduce myself? I sure hope I do
19:11 vendethiel moritz: `window` properties
19:12 vendethiel like, `$ ->` is "use-before-declaration", right ?
19:12 uppompey joined #perl6
19:12 moritz function () {  a(); function a() { } }; # use before declaration
19:12 vendethiel I thought you meant in coffee, which doesnt have that :)
19:13 moritz I actually don't know coffescript :-)
19:13 vendethiel but yeah, I agree. Lots of quirks. Another "weird hoisting" behavior :
19:13 moritz jnthn: MVM_SPESH_DISABLE=1 helped, updating to a new moar didn't
19:13 vendethiel `function foo(a) { var a; alert(a); }; foo(5);` actually alerts 5.
19:19 adu joined #perl6
19:20 Sqirrel joined #perl6
19:27 zakharyas joined #perl6
19:40 hummeleB1 joined #perl6
19:44 dwarring joined #perl6
19:46 rurban joined #perl6
19:53 vendethiel could you override the "add_method" to apply decorators to it ? I'm thinking of the ruby lib https://github.com/michael​fairley/method_decorators
19:54 xenoterracide joined #perl6
19:55 dalek roast: 6b23c08 | moritz++ | S29-os/system.t:
19:55 dalek roast: refude test for rakudo-m that depends on rakudo being installed
19:55 dalek roast:
19:55 dalek roast: better to get a passing TODO than to get test failures
19:55 dalek roast: review: https://github.com/perl6/roast/commit/6b23c0819d
20:01 xenoterracide joined #perl6
20:02 molaf joined #perl6
20:05 BenGoldberg joined #perl6
20:14 Alula_ joined #perl6
20:15 denis_boyun joined #perl6
20:16 adu joined #perl6
20:18 aindilis` joined #perl6
20:27 denis_boyun joined #perl6
20:34 pippo joined #perl6
20:35 zby_home_ joined #perl6
20:46 jnthn vendethiel: Yeah, I think I even wrote a demo of that once...
20:46 jnthn vendethiel: See slides of my meta-programming in Perl 6 talk
20:47 rurban joined #perl6
20:49 Mouq joined #perl6
20:54 lizmat Mouq: re "While you're adding things to Bag, would you consider a method that replicates the keys by their values? "
20:54 lizmat I'm not sure what you're getting at
20:55 lizmat doesn't .keys work ?
20:55 Mouq r: say (bag <a a a c b>).keys
20:55 camelia rakudo-jvm 3e1f32: OUTPUT«b a c␤»
20:55 camelia ..rakudo-parrot 3e1f32, rakudo-moar 3e1f32: OUTPUT«a c b␤»
20:55 Mouq r: say (bag <a a a c b>).pick(*).sort
20:55 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«a a a b c␤»
20:56 lizmat ah, you mean multiplied by their replication fcator
20:56 Mouq lizmat: Yeah
20:56 Mouq r: say (bag <a a a c b>).pairs.map: {.key xx .value}
20:56 camelia rakudo-jvm 3e1f32: OUTPUT«b a a a c␤»
20:56 camelia ..rakudo-parrot 3e1f32, rakudo-moar 3e1f32: OUTPUT«a a a c b␤»
20:56 Mouq Something like that
20:57 jnthn .keyses )
20:58 lizmat maybe we need an adverb on .keys ?
20:58 jnthn No, that feels a bit smelly
20:58 Mouq It only really makes sense on Bags, not so much Sets and really not Mixes
20:59 lizmat maybe .flat ?
21:00 virtualsue joined #perl6
21:00 lizmat or .list ?
21:00 Mouq r: say (bag <a a a c b>).list.perl
21:00 lizmat r: say (bag <a a a c b>).list # seems broken
21:00 camelia rakudo-jvm 3e1f32: OUTPUT«("b", "a", "c").list␤»
21:00 camelia ..rakudo-parrot 3e1f32, rakudo-moar 3e1f32: OUTPUT«("a", "c", "b").list␤»
21:00 camelia rakudo-jvm 3e1f32: OUTPUT«b a c␤»
21:00 camelia ..rakudo-parrot 3e1f32, rakudo-moar 3e1f32: OUTPUT«a c b␤»
21:01 Mouq I think .list should stay as it is, honestly, for consistency with Set and Mix
21:01 Mouq r: say (bag <a a a c b>).hash.list.perl
21:01 camelia rakudo-parrot 3e1f32, rakudo-moar 3e1f32: OUTPUT«("a" => 3, "c" => 1, "b" => 1).list␤»
21:01 camelia ..rakudo-jvm 3e1f32: OUTPUT«("b" => 1, "c" => 1, "a" => 3).list␤»
21:02 Mouq m: say (mix <a a a c b>).hash.list.perl
21:02 camelia rakudo-moar 3e1f32: OUTPUT«("a" => 3, "c" => 1, "b" => 1).list␤»
21:03 lizmat .spread ?
21:03 Mouq m: say (mix <a a a c b>).flat.perl
21:03 camelia rakudo-moar 3e1f32: OUTPUT«(("a"=>3,"c"=>1,"b"=>1).Mix,).list␤»
21:03 Mouq m: say (bag <a a a c b>).flat.perl
21:03 camelia rakudo-moar 3e1f32: OUTPUT«(("a"=>3,"c"=>1,"b"=>1).Bag,).list␤»
21:04 pippo2 joined #perl6
21:05 Mouq .k×v
21:06 pippo2 joined #perl6
21:06 jnthn .kxxv? :)
21:07 jnthn It's quite fun to try and say that one out loud.
21:08 jnthn And yet quite clear what it will do it you stare at it for a bit :)
21:11 vendethiel jnthn: not really the same, though :-)
21:11 vendethiel but yeah, kinda look-alike
21:12 vendethiel I guess I'll need macros
21:16 adu joined #perl6
21:16 lizmat .kxxv it will be (for now)
21:17 jnthn haha :D
21:18 timotimo i don't understand it :(
21:19 jnthn timotimo: .k xx .v
21:19 jnthn timotimo: Where the keys are the things in the bag and the values are the number of times they are in there
21:19 timotimo ah
21:19 jnthn timotimo: and xx is the list repetition operator
21:19 timotimo okay
21:23 pippo2 joined #perl6
21:25 dalek rakudo/nom: 91f41bd | (Elizabeth Mattijsen)++ | src/core/Baggy.pm:
21:25 dalek rakudo/nom: Add Bag.kxxv (preliminary name)
21:25 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/91f41bdcdd
21:25 lizmat $ perl6 -e '<a b b c c c>.Bag.kxxv.perl.say'
21:25 lizmat ("a", "b", "b", "c", "c", "c").list
21:25 lizmat Mouq++
21:25 vendethiel that'll be awkward to say out loud :-)
21:25 vendethiel lizmat++
21:27 brrt joined #perl6
21:28 Mouq lizmat++ :)
21:28 jnthn vendethiel: Yes, next time I'm in a Perl 6 talk I'm going to ask somebody if there's an opertor to do what it does, jus tto hear them try :)
21:30 vendethiel jnthn: wrt that ruby stuff, I think I actually need to macro `class A` to `reset_decorators(); "class A"` then I'd want to parse stuff like
21:30 Ben_Goldberg joined #perl6
21:31 vendethiel `+mydecorater method foo {}` (which can't parse right now), to just the method but storing the associated decorator, and decorating every method at the end of the class declaration. No idea how it'd look like
21:31 vendethiel (definitely feels forced)
21:31 jnthn yeah, that's ew
21:31 jnthn Also the call inserted before class A feels very bogus
21:31 vendethiel https://github.com/rakudo/rakudo​/pull/257#issuecomment-40320398, funny one :)
21:31 jnthn Since that's runtime
21:31 vendethiel yeah I mean at BEGIN time
21:32 jnthn Yeah
21:32 jnthn but the way to do that is to write a module exporting a different ClassHOW
21:32 jnthn And then method foo is decorated(...) { } or so
21:32 vendethiel I might not even need to do that, since I can just reset a "decorator table" every time I add a function
21:32 vendethiel is decorated looks much better ! if I'm able to chain them, definitely go with that !
21:33 dalek specs: 89cc32d | (Elizabeth Mattijsen)++ | S32-setting-library/Containers.pod:
21:33 dalek specs: Spec Bag.kxxv
21:33 dalek specs: review: https://github.com/perl6/specs/commit/89cc32d82d
21:33 vendethiel thanks jnthn, I'll try that tomorrow :-)
21:34 Vlavv joined #perl6
21:34 * jnthn chuckles at the confusion in the pr
21:36 lizmat if captures are to be by value, then:
21:36 lizmat r: my @a = (1,2,3); my @b = (1,2,3); say \@a === \@b  # should be True ?
21:36 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«False␤»
21:37 lizmat jnthn, moritz: ^^^
21:37 Mouq m: my \a = (1,2,3); my \b = (1,2,3); say \@a === \@b
21:37 camelia rakudo-moar 3e1f32: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/LVoOgy6DCmâ�¤Variable '@a' is not declaredâ�¤at /tmp/LVoOgy6DCm:1â�¤------> [32my \a = (1,2,3); my \b = (1,2,3); say \@a[33mâ��[31m === \@b[0mâ�¤    expecting any of:â�¤        postfixâ�¤Â»
21:37 Mouq m: my \a = (1,2,3); my \b = (1,2,3); say \a === \b
21:37 camelia rakudo-moar 3e1f32: OUTPUT«False␤»
21:37 Mouq :(
21:37 jnthn lizmat: No, though @a.Capture === @b.Capture probably should.
21:38 jnthn lizmat: \@a is, iirc, like \(@a), which is a capture with one positional arg @a, and arrays are not value types
21:40 lizmat but that would mean that when the .WHICH of the Capture is to be used as a key for caching
21:41 lizmat that (@a) and (@b) would give different results ?
21:41 jnthn Yes
21:41 lizmat as in: not use the same cache key ?
21:41 jnthn Right, which is what I'd expect givne array is a reference type.
21:41 lizmat that feels wrong to me
21:42 jnthn Why?
21:42 jnthn r: say [1,2] == [1,2]
21:42 jnthn uh
21:42 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«True␤»
21:42 jnthn r: say [1,2] === [1,2]
21:42 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«False␤»
21:43 jnthn Using a mutable thing as a cache key is always gonna be bad design.
21:44 lizmat we're talking about implementing "is cached"
21:44 lizmat where the .WHICH of the Capture is to be the key in the cache, right ?
21:44 jnthn Right.
21:44 lizmat and now you're saying that doing that would be a bad idea ?
21:45 * lizmat is confused
21:45 jnthn No, Capture is immutable.
21:45 jnthn I'm saying the WHICH of a Capture should be defined in terms of the WHICH of things inside of it.
21:45 jnthn And the WHICH of an Array is dependent on its identity, *not* its contents.
21:45 lizmat yes, that is what I'm doing
21:45 jnthn OK
21:46 lizmat then maybe the .WHICH of Array is wrong atm
21:46 jnthn So
21:46 lizmat $ perl6 -e 'my @a = (1,2,3); say (\@a).WHICH'
21:46 lizmat Capture|(Int|1)(Int|2)(Int|3)
21:46 jnthn Oh, hang on...
21:46 lizmat $ perl6 -e 'my @a = (1,2,[3,4,5]); say (\@a).WHICH'
21:46 lizmat Capture|(Int|1)(Int|2)(Array|4494462984)
21:47 lizmat voila, the problem
21:47 jnthn r: my @a = 1,2; my \c = \@a; say c.perl
21:47 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«Capture.new( list => (1, 2).list, hash => EnumMap.new())␤»
21:47 jnthn r: my @a = 1,2; my \c = \(@a); say c.perl
21:47 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«Capture.new( list => (1, 2).list, hash => EnumMap.new())␤»
21:47 lizmat I guess that should be fixed  :-)
21:47 jnthn those are differnt
21:48 rurban joined #perl6
21:48 jnthn lizmat: what should be fixed?
21:48 lizmat sorry, nothing, the EnumMap.new got me confused
21:48 jnthn Ah, ok
21:48 jnthn You agree @foo.WHICH, where @foo is Array, has a WHICH basd on its identity, not its contents?
21:49 lizmat so: you're saying they are different, but the .perl doesn't see any difference
21:49 brrt left #perl6
21:49 lizmat yes
21:49 jnthn No, .perl won't
21:49 jnthn But
21:50 rurban1 joined #perl6
21:50 jnthn r: class Person { has $.name }; say Person.new(name => 'Dave').perl; say Person.new(name => 'Dave').perl;
21:50 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«Person.new(name => "Dave")␤Person.new(name => "Dave")␤»
21:50 jnthn the .perl of those two is the same, but there's more than one Dave in the world. :)
21:50 lizmat yeah, got ya
21:51 lizmat so this basically means I can *not* use .WHICH as the key for "is cached"
21:51 Mouq jnthn: Should this be so, however:
21:51 Mouq m: say List.new.WHICH
21:51 camelia rakudo-moar 3e1f32: OUTPUT«List|140655207615040␤»
21:52 lizmat as any Capture with an array ref, would calculate things anew
21:52 Mouq Oh, Lists are mutable, nevermind...
21:52 lizmat r: my @a = (1,2,3); say @a.WHICH; @a.push(4); say @a.WHICH
21:52 camelia rakudo-parrot 3e1f32: OUTPUT«Array|-43627209465142315​30␤Array|-4362720946514231530␤»
21:52 camelia ..rakudo-jvm 3e1f32: OUTPUT«Array|632880711␤Array|632880711␤»
21:52 camelia ..rakudo-moar 3e1f32: OUTPUT«Array|1399651160368​08␤Array|139965116036808␤»
21:52 jnthn lizmat: No, if you pass in two different arrays *even if they have the same contents* I'd expect them to calculate things anew, because I passed in a different reference type.
21:53 Mouq m: my \a = List.new; say a.WHICH; a.push(5); say a.WHICH
21:53 camelia rakudo-moar 3e1f32: OUTPUT«List|139723787273464␤List|139723787273464␤»
21:53 jnthn lizmat: I don't think you can use "is cached" in ignorance of the incoming argument types.
21:53 lizmat even then, if I change the array from one invocation to the next, I would get the same result when I probably shouldn't
21:53 jnthn lizmat: Well, it depends what you want. :)
21:54 lizmat eh, no what the spec wants  :-)
21:54 jnthn Well, I'd hope the spec wants to keep value types and reference types straight.
21:54 lizmat S06:2122
21:54 synopsebot Link: http://perlcabal.org/syn/S06.html#line_2122
21:55 raiph joined #perl6
21:55 jnthn lizmat: Nothing in there seems to contradict what I'm saying.
21:56 lizmat well, your explanation doesn't match my expectation of memoization
21:56 jnthn lizmat: It doesn't make what I'm saying explicit either.
21:57 lizmat in my world, it's the input values that determine what the output value is going to be (for an "is cached" sub)
21:57 lizmat note: *values*
21:57 jnthn Yes, and the key word there is *value*
21:57 jnthn And array is an entity, *not* a value.
21:58 lizmat so foo(@a) and foo(@b) should give the same result, if @a == @b
21:58 adu joined #perl6
21:59 jnthn lizmat: http://perlcabal.org/syn/S02.html#Immutable_types http://perlcabal.org/syn/S02.html#Mutable_types
21:59 jnthn Of note, the first sentence in the second link.
22:00 adu jnthn!
22:00 yoleaux 17:56Z <Mouq> adu: FWIW I use osx 10.9 and am not having issues (just built [rakudo|nqp|moarvm]-HEAD). Usually if the build segfaults, it's because I needed to reconfigure something, so you may want to doublecheck that
22:00 jnthn o/ adu
22:01 adu Mouq: thanks
22:01 lizmat well, ok: but then maybe there's something wrong with \@a
22:02 jnthn Maybe
22:02 jnthn nore that \@ and \(@a) behave differently at the moment
22:02 lizmat as that gets a flattend @a in $!list, rather than a single Array in $!list
22:02 jnthn Of note, they behave like @a.Capture and (@a,).Capture respectively.
22:02 jnthn That may be too surprising.
22:03 jnthn Lemme see if I can find some spec language on it...
22:03 lizmat that's why:
22:03 lizmat $ perl6 -e 'my @a = (1,2,3); say (\@a).WHICH'
22:03 lizmat Capture|(Int|1)(Int|2)(Int|3)
22:03 lizmat and that's not saying "Capture|(Array:76278692)'
22:04 jnthn Yeah
22:04 jnthn I think that our \@a behavior may be wrong
22:04 jnthn In S02 is this:
22:04 jnthn You may retrieve parts from a Capture object with a prefix sigil operator:
22:04 jnthn $args = \3;     # same as "$args = \(3)"
22:04 timotimo huh?
22:06 jnthn S06 doesn't add much.
22:06 jnthn I can't find a single case of \@foo and \%foo in either S02 or S06 or S08
22:06 jnthn So yeah, I'm suspecting our \@a behavior is just wrong.
22:07 jnthn And it should be made consistent with \(@a)
22:07 Mouq my \a = (1,2,3); my \b = (1,2,3); say a === b; # shouldn't this be True, though?
22:08 Mouq m: my \a = (1,2,3); my \b = (1,2,3); say a.WHICH; say b.WHICH; say a === b; # shouldn't this be True, though?
22:08 camelia rakudo-moar 3e1f32: OUTPUT«Parcel|140040520206696␤​Parcel|140040520212936␤False␤»
22:08 jnthn Mouq: Yes, I think that one probably should
22:08 jnthn Givne it's under S02's Immutable Types section
22:09 Mouq Also
22:09 jnthn I'm a little bit surprised to see LoL under Immutable Types, however...
22:09 Mouq m: say LoL.^mro # should probably be more like (LoL) (Parcel) (Cool) (Any) (Mu)
22:09 jnthn Curious about Exception there too. :)
22:09 camelia rakudo-moar 3e1f32: OUTPUT«(LoL) (List) (Iterable) (Cool) (Any) (Mu)␤»
22:10 jnthn Mouq: tbh, LoL is not clearly enough defined in my mind to be sure where it falls :)
22:11 Mouq Oh, wait mebbe not
22:11 hoverboard joined #perl6
22:16 jnthn lizmat: On unrelated matters: I'm planning to make .cue on scheduler return a Cancellation object of some kind.
22:17 jnthn lizmat: Especially useful for timer based things; you can stop them. But will support it for the non-timer caes too
22:17 lizmat that feels good
22:17 jnthn lizmat: Sound OK?
22:17 lizmat yup
22:17 lizmat but don't you have something like that already with e.g. :app_lifetime ?
22:17 jnthn I'm pondering them a bit 'cus I'm gearing up to give Moar support for them, which means I'm looking at the nqp:: op API for such things.
22:17 jnthn No, app_lifetime is at the thread lvel
22:17 jnthn *level
22:17 jnthn Timers don't make a thread each.
22:17 lizmat ah, yes
22:18 jnthn Otherwise if you have thousands of them...ouch. :)
22:18 lizmat yup
22:18 lizmat we don't want that
22:18 jnthn Aye.
22:18 jnthn Well, the JVM thing we use manages them as a heap, and libuv also does now, iirc.
22:18 jnthn So both should be able to cope with thousands.
22:18 lizmat .oO( the new trend: thread bombs instead of fork bombs )
22:19 jnthn m: Thread.start({ }) while 1; # curious :)
22:19 camelia rakudo-moar 3e1f32: OUTPUT«Type check failed in binding &code; expected 'Callable' but got 'Hash'␤  in method start at src/gen/m-CORE.setting:17669␤  in block  at /tmp/Z3Rmg2Hw0Q:1␤␤»
22:19 jnthn ahaha
22:19 jnthn m: Thread.start(-> { }) while 1; # curious :)
22:19 camelia rakudo-moar 3e1f32: OUTPUT«(signal )»
22:19 BenGoldberg That was quick
22:19 jnthn Really
22:19 BenGoldberg m: Thread.start(-> { });
22:19 camelia rakudo-moar 3e1f32: ( no output )
22:19 BenGoldberg m: Thread.start(-> { }) for 1..5;
22:19 camelia rakudo-moar 3e1f32: ( no output )
22:19 BenGoldberg m: Thread.start(-> { }) for 1..99;
22:19 camelia rakudo-moar 3e1f32: ( no output )
22:20 BenGoldberg m: Thread.start(-> { }) for 1..9999;
22:20 camelia rakudo-moar 3e1f32: OUTPUT«(signal )»
22:20 BenGoldberg m: Thread.start(-> { }) for 1..999;
22:20 camelia rakudo-moar 3e1f32: OUTPUT«(signal )»
22:20 * BenGoldberg wonders if it's worthwhile to debug that, though
22:20 lizmat $ perl6 -e 'Thread.start(-> { }) for 1..999'
22:20 lizmat Segmentation fault: 11
22:20 jnthn Probably, yes. :)
22:20 jnthn m: Thread.start(-> { }).finish while 1; # wonder if this is OKer :)
22:20 camelia rakudo-moar 3e1f32: OUTPUT«(signal )»
22:21 BenGoldberg Now that, on the other hand...
22:21 jnthn Hmm...that one certainly wants debugging.
22:21 lizmat $ perl6 -e 'Thread.start(-> { }).finish while 1'
22:21 lizmat Segmentation fault: 11
22:21 jnthn I'm not gonna try it with j because I'll bring down the evalbot.
22:21 jnthn well, the r-j one anyway
22:21 BenGoldberg Poor bot ;)
22:22 jnthn oh, curious
22:22 jnthn On my (Windows) box the "Thread.start(-> { }).finish while 1" is not segv-ing at all
22:23 jnthn However, it is using plenty of memory :)
22:23 jnthn (not growing, mind)
22:24 xenoterracide joined #perl6
22:24 jnthn The non-.finish case also doesn't segv for me, it just keeps on trucking.
22:27 lizmat r: my $a = \3; my $b = \3; say $a === $b  # shouldn't this be True ?
22:27 camelia rakudo-parrot 3e1f32, rakudo-jvm 3e1f32, rakudo-moar 3e1f32: OUTPUT«False␤»
22:28 jnthn lizmat: Yes.
22:28 lizmat ok, then the test for that is wrong
22:28 jnthn Does your work on Capture.WHICH make it so?
22:29 lizmat that makes it return True
22:29 jnthn yeah, sounds right to me.
22:29 adu joined #perl6
22:29 lizmat $ perl6 -e 'my $a = \3; my $b = \3; say $a === $b'
22:29 lizmat True
22:29 jnthn \o/
22:29 lizmat spectest is expecting False
22:29 jnthn OK, then I think spectest is out of line with spec :)
22:30 lizmat so the test s wrong
22:30 jnthn ooh, it's going to be sunny here this week rather than soaking me on the walk to/from teaching :)
22:30 Mouq lizmat++
22:31 lizmat m: say \3 === \3
22:31 camelia rakudo-moar 91f41b: OUTPUT«False␤»
22:31 lizmat $ perl6 -e 'say \3 === \3'
22:31 lizmat True
22:31 xenoterracide joined #perl6
22:31 lizmat same thing, I think, fixing spectest
22:31 BenGoldberg n: say \3 === \3
22:31 camelia niecza v24-109-g48a8de3: OUTPUT«False␤»
22:35 rurban joined #perl6
22:37 colomon joined #perl6
22:37 jnthn Teaching tomorrow...guess I should sleep :)
22:37 jnthn 'night o/
22:38 Mouq night jnthn!
22:38 adu good night
22:39 dalek rakudo/nom: c855a0f | (Elizabeth Mattijsen)++ | src/core/ (2 files):
22:39 dalek rakudo/nom: Implement Capture.WHICH
22:39 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c855a0f439
22:39 dalek roast: 2cde4fb | (Elizabeth Mattijsen)++ | S03-operators/value_equivalence.t:
22:39 dalek roast: Unfudge TODO's passing / fudge test for \@a
22:39 dalek roast:
22:39 dalek roast: The value is probably wrong, because \@a gets flattened into Capture.$!list
22:39 dalek roast: rather than having a single Array object in Capture.$!list[0]
22:39 dalek roast: review: https://github.com/perl6/roast/commit/2cde4fbcfe
22:39 lizmat gnight jnthn!
22:46 Mouq r: .say for <j m p> Z=> (<29205 29573 29115> Z/ <31342 31567 31155>)
22:46 dalek rakudo/nom: 442cdf8 | (Elizabeth Mattijsen)++ | src/core/ (2 files):
22:46 dalek rakudo/nom: Naively implement "is cached" on Routines
22:46 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/442cdf8340
22:46 camelia rakudo-parrot 91f41b, rakudo-jvm 91f41b, rakudo-moar 91f41b: OUTPUT«"j" => <29205/31342>␤"m" => <29573/31567>␤"p" => <1941/2077>␤»
22:47 Mouq m: say ($_*100).Int for <j m p> Z=> (<29205 29573 29115> Z/ <31342 31567 31155>)
22:47 camelia rakudo-moar 91f41b: OUTPUT«Cannot call 'Numeric'; none of these signatures match:␤:(Mu:U \v: *%_)␤  in sub infix:<*> at src/gen/m-CORE.setting:4154␤  in block  at /tmp/nnoP4rsZ8s:1␤␤»
22:47 Mouq -_-
22:47 xenoterracide joined #perl6
22:47 Mouq Oh
22:48 Mouq m: .say for <j m p> Z=> ((<29205 29573 29115> Z/ <31342 31567 31155>) »*» 100)».Int
22:48 camelia rakudo-moar 91f41b: OUTPUT«"j" => 93␤"m" => 93␤"p" => 93␤»
22:48 Mouq m: .say for <j m p> Z=> ((<29205 29573 29115> Z/ <31342 31567 31155>) »*» 100)
22:48 camelia rakudo-moar 91f41b: OUTPUT«"j" => <1460250/15671>␤"m" => <2957300/31567>␤"p" => <194100/2077>␤»
22:48 Mouq m: .say for <j m p> Z=> ((<29205 29573 29115> Z/ <31342 31567 31155>) »*» 100).Num
22:48 camelia rakudo-moar 91f41b: OUTPUT«"j" => 3e0␤»
22:48 Mouq Hmm
22:49 Mouq m: .say for <j m p> Z=> ((<29205 29573 29115> Z/ <31342 31567 31155>) »*» 100)».Num
22:49 camelia rakudo-moar 91f41b: OUTPUT«"j" => 93.1816731542339e0␤"m" => 93.6832768397377e0␤"p" => 93.4520943668753e0␤»
22:51 dalek rakudo-star-daily: 1f3b2ea | coke++ | log/ (5 files):
22:51 dalek rakudo-star-daily: today (automated commit)
22:51 dalek rakudo-star-daily: review: https://github.com/coke/rakudo​-star-daily/commit/1f3b2eace9
22:51 dalek perl6-roast-data: 30f4207 | coke++ | / (6 files):
22:51 dalek perl6-roast-data: today (automated commit)
22:51 dalek perl6-roast-data: review: https://github.com/coke/perl6​-roast-data/commit/30f420759c
22:57 [Coke] (mojo6) i knew work made me forget something :)
22:57 dalek roast: 840d421 | (Elizabeth Mattijsen)++ | S02-names/is_cached.t:
22:57 dalek roast: Add tests for "is_cached"
22:57 dalek roast: review: https://github.com/perl6/roast/commit/840d421264
22:59 colomon joined #perl6
23:03 aindilis joined #perl6
23:06 robinsmidsrod joined #perl6
23:07 dalek rakudo/nom: 3aa101a | (Elizabeth Mattijsen)++ | t/spectest.data:
23:07 dalek rakudo/nom: Add "is_cached" tests to roast
23:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3aa101ac77
23:09 dalek rakudo/nom: 79167a1 | (Elizabeth Mattijsen)++ | docs/ChangeLog:
23:09 dalek rakudo/nom: Some more Changelog updates
23:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/79167a1615
23:09 lizmat and sleep&
23:11 cognominal lizmat, how come %cache is lexical _into_ the trait_mod sub? /me suspects he should go to sleep too
23:11 cognominal it should be outside to cache anything?
23:36 rurban joined #perl6
23:43 ponbiki joined #perl6
23:46 Alula_ joined #perl6
23:54 cognominal r: sub a(|a) {  say a.WHICH  }; a 1; a 1
23:54 camelia rakudo-parrot 3aa101, rakudo-jvm 3aa101, rakudo-moar 3aa101: OUTPUT«Capture|(Int|1)␤Capture|(Int|1)␤»
23:56 cognominal r: sub a(|a) {  say ~a.WHICH  }; a 1; a 1
23:56 camelia rakudo-parrot 3aa101, rakudo-jvm 3aa101, rakudo-moar 3aa101: OUTPUT«Capture|(Int|1)␤Capture|(Int|1)␤»

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

Perl 6 | Reference Documentation | Rakudo | Niecza | Specs