Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2016-06-06

Perl 6 | Reference Documentation | Rakudo

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

All times shown according to UTC.

Time Nick Message
00:00 kalkin-_ ohh nevermind
00:00 skids kalkin-_: maybe you are just looking for a dynamically scoped variable?
00:01 kalkin-_ skids: you mean $*FOO?
00:01 skids right.  Does not have to be uppercase.  uppercase is usually for builtin stuff.
00:05 pierre_ joined #perl6
00:12 dalek joined #perl6
00:17 kurahaupo joined #perl6
00:22 kid51 joined #perl6
00:30 labster joined #perl6
00:34 raiph joined #perl6
00:37 mr-foobar joined #perl6
00:37 retupmoca joined #perl6
00:38 Herby__ joined #perl6
00:38 Herby__ Evening, everyone!
00:39 emdashcomma Hi__
00:39 Herby__ o/
00:41 kurahaupo joined #perl6
00:42 bisectable joined #perl6
00:44 Zoffix joined #perl6
00:44 AlexDaniel .tell Zoffix try your .wut snippet again. I thought that only I would throw in a code that produces non-zero exit code on a good commit, but since you've done it too I decided to cover it as well
00:44 yoleaux AlexDaniel: I'll pass your message to Zoffix.
00:45 Zoffix Any idea why this program works with `echo` but not with `perl`, even though if I start the perl script alone it produces output? https://gist.github.com/zoffixznet/0ec1c2ffc0986554b881a2a7804d4103
00:45 yoleaux 00:44Z <AlexDaniel> Zoffix: try your .wut snippet again. I thought that only I would throw in a code that produces non-zero exit code on a good commit, but since you've done it too I decided to cover it as well
00:45 AlexDaniel mmm…
00:45 AlexDaniel yoleaux: great job!
00:45 Zoffix AlexDaniel, no idea what .wut snippet you're talking about
00:45 AlexDaniel bisect: class A { has $.wut = [] }; my $a = A.new; $a.wut = [1,2,3]; $a.wut.say
00:45 bisectable AlexDaniel: exit code on a “good” revision is 1 (which is bad), bisecting with inverted logic
00:45 bisectable AlexDaniel: (2016-03-02) https://github.com/rakudo/rakudo/commit/fdd37a9
00:46 Zoffix It wasn't mine. Don't care about :/
00:46 retupmoca .botsnack
00:46 synopsebot6 om nom nom
00:46 yoleaux :D
00:46 Zoffix Pissed off that I'm constantly fighting with things that aren't primary code writing. Like this proc stuff
00:46 AlexDaniel bisect: for ‘q b c d’.words -> $a, $b { }
00:46 bisectable AlexDaniel: exit code on a “good” revision is 1 (which is bad), bisecting with inverted logic
00:46 bisectable AlexDaniel: (2016-03-01) https://github.com/rakudo/rakudo/commit/1b6c901
00:47 AlexDaniel but look how great it is now!
00:47 Zoffix The docs don't say how the .tap'ed stdout is chunked. Is it by new lines? Does it buffer and waits? *sigh*
00:49 AlexDaniel Zoffix: it may be the buffering in 01-basic.pl itself
00:50 Zoffix It prints fine when I run it from command line.
00:50 Zoffix I tried now with a small perl script that prints a few lines and sleeps and I'm getting nothing from the tap
00:50 AlexDaniel Zoffix: what if you run it piped to | cat ?
00:50 geekosaur remember that programs buffer output not to terminals, usually in 4k or 8k chunks
00:51 geekosaur on linux you can use stdbuf to defeat this
00:51 AlexDaniel or just turn on autoflush
00:51 AlexDaniel in 01-basic.pl
00:52 geekosaur oh, yeh, probably doesn't defeat perl's since it's doing its own buffering (p5 via the perlio stuff, rakudo via libuv)
00:52 geekosaur whereas stdbuf uses a backchannel into glibc's buffering code
00:53 AlexDaniel somehow all buffering problems I experienced were associated with perl5… hmm…
00:53 AlexDaniel sometimes it feels like it is overdoing it
00:54 Zoffix AlexDaniel++ thanks, adding $|++ fixed it
00:54 Zoffix Perl5--
00:58 AlexDaniel a bunch of code is not commited… :P gonna get some sleep
01:11 aborazmeh joined #perl6
01:11 aborazmeh joined #perl6
01:13 BenGoldberg m: say &x
01:13 camelia rakudo-moar 85682a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/hwvFiF6jOt␤Undeclared routine:␤    x used at line 1␤␤»
01:14 * BenGoldberg supposes that the x operator is a syntactically wossname, not a subroutine.
01:14 BenGoldberg m: (say 2) xx 1;
01:15 camelia rakudo-moar 85682a: OUTPUT«2␤»
01:15 BenGoldberg m: (say 2) xx 0;
01:15 camelia rakudo-moar 85682a: ( no output )
01:15 geekosaur m: say &infix:<xx>
01:15 camelia rakudo-moar 85682a: OUTPUT«sub infix:<xx> (Mu $, $, *%) { #`(Sub+{Precedence}|43087568) ... }␤»
01:15 finanalyst joined #perl6
01:17 BenGoldberg m: sub postfix:<twice> (Mu $lhs) { lhs xx 2 }; (say 'a') twice;
01:17 camelia rakudo-moar 85682a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/IpmyXCbgE8␤Two terms in a row␤at /tmp/IpmyXCbgE8:1␤------> 3twice> (Mu $lhs) { lhs xx 2 }; (say 'a')7⏏5 twice;␤    expecting any of:␤        infix␤        infix stopper␤        statement end…»
01:17 BenGoldberg m: sub postfix:<twice> (Mu $lhs) { $lhs xx 2 }; (say 'a') twice;
01:17 camelia rakudo-moar 85682a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/4fVDA6M5WM␤Two terms in a row␤at /tmp/4fVDA6M5WM:1␤------> 3wice> (Mu $lhs) { $lhs xx 2 }; (say 'a')7⏏5 twice;␤    expecting any of:␤        infix␤        infix stopper␤        statement end…»
01:17 geekosaur m: sub postfix:<twice> (Mu $lhs) { $lhs xx 2 }; (say 'a')twice;
01:17 camelia rakudo-moar 85682a: OUTPUT«a␤»
01:17 geekosaur m: sub postfix:<twice> (Mu $lhs) { $lhs xx 2 }; (say 'a')\ twice;
01:17 camelia rakudo-moar 85682a: OUTPUT«a␤»
01:18 geekosaur it's a bit peculiar that way
01:18 Zoffix You're not using the result of of `say`
01:18 BenGoldberg Ok, but now how do I make it actually run it's argument twice, the way xx does?
01:19 Zoffix It doesn't
01:19 timotimo not possible without a slang (or macros) at the moment, as far as i know
01:19 Zoffix m: (say 42) xx 1;
01:19 camelia rakudo-moar 85682a: OUTPUT«42␤»
01:19 Zoffix m: (say 42) xx 2;
01:19 camelia rakudo-moar 85682a: OUTPUT«42␤42␤»
01:19 Zoffix never miknd
01:20 geekosaur xx likely gets to cheat. user subs don't get to do that, they always receive something already evaluated
01:20 BenGoldberg m: macro postfix:<twice> (Mu $lhs) { quasi { {{{ $lhs }}} x 2 } }; (say 'a')twice;
01:20 camelia rakudo-moar 85682a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/sVLyzPmmGU␤Use of macros is experimental; please 'use experimental :macros'␤at /tmp/sVLyzPmmGU:1␤------> 3macro7⏏5 postfix:<twice> (Mu $lhs) { quasi { {{{␤»
01:21 gfldex is infix:<xx> meant to be eager?
01:21 BenGoldberg m: use experimental :macros; macro postfix:<twice> (Mu $lhs) { quasi { {{{ $lhs }}} x 2 } }; (say 'a')twice;
01:21 camelia rakudo-moar 85682a: OUTPUT«Weird node visited: QAST::BVal␤a␤»
01:21 BenGoldberg m: use experimental :macros; macro postfix:<twice> (Mu $lhs) { quasi { {{{ $lhs }}} xx 2 } }; (say 'a')twice;
01:21 camelia rakudo-moar 85682a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/mtWb0FEkTA␤Unknown QAST node type QAST::Unquote␤at /tmp/mtWb0FEkTA:1␤»
01:21 gfldex m: my @a := (say 42) xx 2; dd @a;
01:21 camelia rakudo-moar 85682a: OUTPUT«42␤42␤(Bool::True, Bool::True)␤»
01:22 gfldex m: my @a := (say 42) xx 2; say 'ello'; dd @a;
01:22 camelia rakudo-moar 85682a: OUTPUT«42␤42␤ello␤(Bool::True, Bool::True)␤»
01:22 araujo__ joined #perl6
01:22 kalkin- joined #perl6
01:25 * BenGoldberg does not yet sufficiently grok macros.
01:25 gfldex neither does Rakudo :)
01:30 araujo_ joined #perl6
01:35 timotimo that.s right
01:36 araujo__ joined #perl6
01:37 molaf joined #perl6
01:45 Actualeyes joined #perl6
01:47 ilbot3 joined #perl6
01:47 Topic for #perl6 is now »ö« Welcome to Perl 6! | https://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:,  or /msg camelia p6: ... | irclog: http://irc.perl6.org or http://colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
01:47 colomon joined #perl6
01:53 FROGGS_ joined #perl6
02:16 Zoffix Well, I'm gonna disappear for a week+. Burning out....  I do remember that I'm meant to release Rakudo on 18th and I will. So, don't worry, I remember :)
02:16 Zoffix \o
02:23 colomon joined #perl6
02:25 mr-foobar joined #perl6
02:30 user9 joined #perl6
02:34 pierre_ joined #perl6
02:37 Zoffix joined #perl6
02:38 colomon joined #perl6
02:38 noganex joined #perl6
02:38 Zoffix This will sound weird, but... My brain just won't shut up that my .seen message would be the wave and not the actual last message, so...
02:38 Zoffix Well, I'm gonna disappear for a week+. Burning out....  I do remember that I'm meant to release Rakudo on 18th and I will. So, don't worry, I remember :)
02:42 gorgonzola joined #perl6
02:42 colomon joined #perl6
03:37 TEttinger joined #perl6
03:39 khw joined #perl6
03:47 finanalyst joined #perl6
04:07 ssotka joined #perl6
04:14 xinming joined #perl6
04:25 Cabanossi joined #perl6
04:48 pierre_ joined #perl6
04:52 pierre_ joined #perl6
05:01 sno joined #perl6
05:10 _nadim joined #perl6
05:18 user9 joined #perl6
06:18 girafe joined #perl6
06:23 MadcapJake left #perl6
06:24 jrusso joined #perl6
06:24 firstdayonthejob joined #perl6
06:26 pierre_ joined #perl6
06:28 pierre_ joined #perl6
06:37 mtj_ joined #perl6
06:41 pierre_ joined #perl6
06:50 aries_liuxueyang joined #perl6
06:54 huggable joined #perl6
06:55 sno joined #perl6
06:58 RabidGravy joined #perl6
07:01 darutoko joined #perl6
07:08 RabidGravy BOOM!
07:22 rurban joined #perl6
07:24 zakharyas joined #perl6
07:41 bjz joined #perl6
07:49 g4 joined #perl6
07:50 rindolf joined #perl6
07:51 Humdai joined #perl6
07:53 RabidGravy I just have to say that among all the cool and fabulous things in Perl 6, the combination multi of dispatch and the richness of signature declaration is racing ahead as my favourite thing
07:53 RabidGravy s/multi of/of multi/
07:54 moritz that is indeed a very powerful combination
07:54 moritz and it nudges you in the direction of writing small routines
07:55 bjz joined #perl6
07:59 RabidGravy yeah, for a long while now I have aspired to making routines with the minimum possible complexity and removing all the logic surrounding determining what the arguments are and branching accordingly to a langiage feature leaps forward into that
08:01 ocbtec joined #perl6
08:01 user9 joined #perl6
08:08 dakkar joined #perl6
08:10 azawawi joined #perl6
08:10 azawawi hi
08:10 azawawi RabidGravy: https://github.com/azawawi/gtk-simple/blob/master/examples/09-toolbar.pl6#L32  # Feedback please :)
08:11 azawawi RabidGravy: https://github.com/azawawi/gtk-simple/blob/master/lib/GTK/Simple/Box.pm6#L13
08:12 azawawi http://pasteboard.co/1tyObr6M.png  # Screenshot of the above example after GTK::Simple::Box.new change
08:14 RabidGravy looks good matey
08:15 RabidGravy if it passes the tests and the rest of the examples continue to work as before then it's good to go :)
08:16 cosimo joined #perl6
08:24 wamba joined #perl6
08:25 sdsdfsd joined #perl6
08:25 * azawawi installs homebrew on macbook pro :)
08:29 DrForr RabidGravy: I might have a working wiki to show @ YAPC, I did most of the heavy lifting last night.
08:31 RabidGravy cool, WordPress replacement next ;-)
08:31 RabidGravy DrForr++ # making stuff
08:31 DrForr Oh, I've got *other* plans as well, they might earn a LT mention if I can get the REPL module to behave the way I want it.
08:32 RabidGravy I've been sidetracked for days trying to make something that does what SQL::Abstract does
08:33 araujo joined #perl6
08:34 DrForr I almost let myself get distracted by factoring out a MediaWiki grammar before realizing what a headache that actually was.
08:37 gregf_ morning Perl6!
08:37 DrForr Mornin'.
08:38 zakharyas joined #perl6
08:39 RabidGravy MARNIN
08:40 RabidGravy right, I'm going to use this window of fine weather opportunity to do some stuff in the garden
08:44 literal m: time
08:44 camelia rakudo-moar 85682a: ( no output )
08:44 araujo_ joined #perl6
08:44 literal m: say time
08:44 camelia rakudo-moar 85682a: OUTPUT«1465202659␤»
08:44 literal how do I get the epoch time in milliseconds?
08:45 moritz m: say now
08:45 camelia rakudo-moar 85682a: OUTPUT«Instant:1465202791.008717␤»
08:46 moritz m: say now.tai
08:46 camelia rakudo-moar 85682a: OUTPUT«1465202818.009479␤»
08:47 ufobat joined #perl6
08:51 literal I see
08:54 Woodi Zoffix: gl with resting! don't worry, be truly yourself :)
08:54 ufobat morning :)
08:56 Woodi hallo :)
09:12 arnsholt DrForr: IIRC, MediaWiki's language is implemented as a cascade of regex search-replace routines, which results a context-*sensitive* language
09:13 arnsholt So implementing a grammar for it is likely quite hard
09:13 arnsholt Besides, you want MarkDown ;)
09:13 iH2O joined #perl6
09:14 xinming joined #perl6
09:16 dogbert17 o/ #perl6
09:16 iH2O hi Dagobert
09:16 dogbert17 ashello iH20
09:16 dogbert17 s/ashello/hello/
09:17 iH2O is the final / really needed?
09:17 dogbert17 iH20, I always put it there for some reason :)
09:18 jast in perl? yes. in sed? yes. in IRC? depends on who is parsing your expression ;)
09:18 dogbert17 :)
09:20 dogbert17 does anyone have a minute to review my attempt to document List.categorize at https://gist.github.com/dogbert17/c0b286f90bed38f83397f8f431f22d30  ?
09:20 arnsholt It's optional in vi, as long as you don't need any modifiers =)
09:21 bjz_ joined #perl6
09:30 jast dogbert17: I found the first paragraph a little hard to follow, here's my attempt to simplify: https://gist.github.com/jast/45e6533056692a81d35e56a0e83b62df
09:31 jast might be a matter of taste, I don't know
09:31 dogbert17 jast: I like it an will change :)
09:31 dogbert17 *and
09:32 dogbert17 running it through htmlify.p6 atm
09:45 dalek doc: 0937200 | (Jan-Olof Hendig)++ | doc/Type/List.pod:
09:45 dalek doc: Added docs for List.categorize. jast++ for making the text easier to understand
09:45 dalek doc: review: https://github.com/perl6/doc/commit/09372005d9
09:46 rindolf joined #perl6
09:48 iH2O left #perl6
10:11 Hor|zon joined #perl6
10:23 kaare_ joined #perl6
10:27 jack_rabbit joined #perl6
10:27 kid51 joined #perl6
10:45 mr-foobar joined #perl6
10:46 DHAD05 joined #perl6
10:46 DHAD05 left #perl6
10:50 araujo joined #perl6
10:54 huggable joined #perl6
11:11 literal m: say "abc".split("", :skip-empty)
11:11 camelia rakudo-moar c4b3fa: OUTPUT«(a b c)␤»
11:11 literal is there a shorter way of splitting a string into characters?
11:12 lizmat m: dd "abc".comb
11:12 camelia rakudo-moar c4b3fa: OUTPUT«("a", "b", "c").Seq␤»
11:13 literal ah, nice
11:13 lizmat literal: in Perl 6, you usually want to use comb instead of split
11:14 literal alright
11:22 rurban1 joined #perl6
11:31 jast I used comb in one of my very first Perl 6 programs: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map({chr(ord($_)+^1)}).rotor(5)).reverse>>.join.join
11:31 rurban joined #perl6
11:32 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map({chr(ord($_)+^1)}).rotor(5)).reverse>>.join.join
11:32 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:33 moritz starting with an obfu, you fit right in here :-)
11:33 jast I wanted to play with the fancy operators as soon as possible :}
11:33 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map({chr(ord($_)+^1)}).rotor(5)).reverse>>.join.join
11:33 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:33 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map({chr(.ord+^1)}).rotor(5)).reverse>>.join.join
11:33 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:34 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map((*.ord+^1).chr).rotor(5)).reverse>>.join.join
11:34 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:34 jast dang :)
11:34 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.comb.map((*.ord+^1).chr).rotor(5)).reverse.flat.join
11:34 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:35 moritz m: say [Z](Q%`sd`Kbmsotj7!nrd!Quusidi!%.ords.map((*+^1).chr).rotor(5)).reverse.flat.join
11:35 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:35 jast no fair, I didn't know about that function ;)
11:35 moritz jast: it's not meant as competition, just as playing (and potentially education)
11:36 jast (btw I used Q% instead of ' because it looks stranger, even though it's slightly longer)
11:36 jast yeah, sure, it's all good, clean fun :)
11:37 moritz m: say [Z](<`sd`Kbmsotj7!nrd!Quusidi!>.ords.map((*+^1).chr).rotor(5)).reverse.flat.join
11:37 camelia rakudo-moar a64607: OUTPUT«Just another Perl6 hacker␤»
11:37 moritz 'nother option
11:37 jast right. I still prefer Q%...% because fewer people would think of it as matching pairs
11:38 jast obfuscation is applied psychology, right? :)
11:40 moritz aye
11:40 moritz I've never been good at that :-)
11:48 dontaki joined #perl6
11:53 samb1 joined #perl6
11:54 rurban1 joined #perl6
11:54 cessna joined #perl6
12:01 rurban1 left #perl6
12:11 gregf_ m: ("!".ord-1).chr
12:11 camelia rakudo-moar a64607: ( no output )
12:12 gregf_ m: ("`".ord-1).chr
12:12 camelia rakudo-moar a64607: ( no output )
12:12 gregf_ m: say ("`".ord-1).chr
12:12 camelia rakudo-moar a64607: OUTPUT«_␤»
12:13 dogbert17 m: my $i = 1; say ($i %% 2 ?? "even" !! "odd", "prime" if  $i.is-prime) # stupid question, why doesn't this return a one element list?
12:13 camelia rakudo-moar a64607: OUTPUT«()␤»
12:17 gregf_ that post if messes things up i guess
12:17 gregf_ or rather, gets the parser confused :|
12:19 gregf_ m: my $i = 1; say $i.is-prime *smiles*
12:19 camelia rakudo-moar a64607: OUTPUT«5===SORRY!5=== Error while compiling /tmp/3MLiAeGcOW␤Missing required term after infix␤at /tmp/3MLiAeGcOW:1␤------> 3my $i = 1; say $i.is-prime *smiles*7⏏5<EOL>␤    expecting any of:␤        prefix␤        term␤»
12:19 gregf_ m: my $i = 1; say $i.is-prime #*smiles*
12:19 camelia rakudo-moar a64607: OUTPUT«False␤»
12:19 psch m: my $i = 1; say ($i %% 2 ?? "even" !! "odd", ("prime" if $i.is-prime)) #
12:19 camelia rakudo-moar a64607: OUTPUT«(odd)␤»
12:19 psch m: my $i = 3; say ($i %% 2 ?? "even" !! "odd", ("prime" if $i.is-prime)) #
12:19 camelia rakudo-moar a64607: OUTPUT«(odd prime)␤»
12:20 gregf_ m: (^10).map(*.is-prime.say)
12:20 camelia rakudo-moar a64607: OUTPUT«False␤False␤True␤True␤False␤True␤False␤True␤False␤False␤»
12:20 dogbert17 psch: and why does that work?
12:20 psch dogbert17: parenthesis change precedence
12:20 psch dogbert17: statement_mod if modifies the whole statement
12:20 dogbert17 so gregf_ was right the post if messes things up
12:20 psch dogbert17: infix:<,> is part of that statement
12:20 psch dogbert17: it doesn't "mess anything up", it does exactly what it's suppose to do :)
12:21 gregf_ dogbert17: no, prime says 1 is not a prime. my $i = 3; say ($i %% 2 ?? "even" !! "odd", "prime" if  $i.is-prime) # run this
12:22 dogbert17 psch: ah, thanks for the explanation, it sure messed with my brain :)
12:23 psch m: my $i = 1; say (do if $i.is-prime { $i %% 2 ?? "even" !! "odd", "prime" }) # without parens, it's equivalent to this
12:23 camelia rakudo-moar a64607: OUTPUT«()␤»
12:23 psch m: my $i = 1; say ($i %% 2 ?? "even" !! "odd", do if $i.is-prime { "prime" }) # with parens, it's equivalent to this
12:23 camelia rakudo-moar a64607: OUTPUT«(odd)␤»
12:24 dogbert17 psch: that definitely makes things clearer
12:24 dogbert17 gregf_: indeed this 'odd' problem showed itself when is-prime returned false
12:25 perlpilot joined #perl6
12:25 dogbert17 psch: do you remember discussing an async bug a few days ago, an example running 'hexdump'?
12:26 dogbert17 pscg: and a missing error message
12:26 psch dogbert17: i remember talking about it, yeah.  not sure what - if any - came of it though
12:26 dogbert17 psch: nothing came of it, should we report it, perhaps it interests jnthn?
12:27 psch ...i thought that was already ticketed?
12:27 dogbert17 psch: not by me, but perhaps it had been reported earlier
12:28 psch in any case, yes, if there is no ticket there definitely should be
12:28 dogbert17 psch: how would I search for it in RT
12:29 psch dogbert17: i usually use google, with "site:rt.perl.org" and well, keywords i hope that match :)
12:30 psch the rt search isn't bad, but a bit unwieldy
12:30 dogbert17 psch: thx, I should have figured that out myself :(
12:33 dogbert17 can't find anything on RT so either it isn't there or my keyword(s) were bad
12:35 Possum joined #perl6
12:39 dogbert17 ok, I'll try to rakudobug it then
12:47 sufrostico joined #perl6
12:54 brrt joined #perl6
12:56 zakharyas joined #perl6
13:09 Emeric joined #perl6
13:10 yqt joined #perl6
13:16 rurban2 joined #perl6
13:16 azawawi joined #perl6
13:16 azawawi hi
13:18 masak \o
13:18 brrt good hi masak azawawi
13:19 masak hìíìí
13:19 azawawi https://github.com/perl6/gtk-simple/pull/46
13:20 azawawi مرحبا   # hi in Arabic  :)
13:23 masak irssi shows it all backward :)
13:23 * masak .oO( íìíìh )
13:24 azawawi m: say "مرحبا".reverse;
13:24 camelia rakudo-moar a64607: OUTPUT«(مرحبا)␤»
13:24 psch looks the same in irssi as on the clog for me
13:24 psch ...and reverse *still* looks the same
13:27 masak m: say "مرحبا".flip
13:27 camelia rakudo-moar a64607: OUTPUT«ابحرم␤»
13:27 azawawi i was searching for that .flip :)
13:27 masak :)
13:28 psch i find it really hard to tell where one letter begins and another ends
13:28 * masak .oO( always useful to be flippant on channel )
13:28 psch but i suppose that'd be the same for cursive for anyone who never learned the latin alphabet
13:28 masak psch: that's how you know you're not seeing it reversed ;)
13:29 psch masak: well, it's both - flipped and non-flipped - that look very... connected, for lack of a better word :)
13:30 azawawi if you need to specify unconnected arabic letters, you can use https://en.wikipedia.org/wiki/Arabic_Presentation_Forms-B btw
13:30 cdg joined #perl6
13:30 azawawi connected = line on the left/right
13:31 azawawi https://en.wikipedia.org/wiki/Arabic_script_in_Unicode  # to be exact all blocks
13:31 skids joined #perl6
13:36 stevieb joined #perl6
13:42 azawawi http://pasteboard.co/1tUpg8C8.png  # GTK::Scintilla Editor Demo :)
13:42 * azawawi starts wrapping https://developer.gnome.org/gtk3/stable/GtkFileChooserButton.html
13:45 brrt joined #perl6
13:55 dalek ecosystem: f923b67 | titsuki++ | META.list:
13:55 dalek ecosystem: Add Algorithm::NaiveBayes to ecosystem
13:55 dalek ecosystem:
13:55 dalek ecosystem: See https://github.com/titsuki/p6-Algorithm-NaiveBayes
13:55 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/f923b67270
13:55 dalek ecosystem: 03ddc2c | titsuki++ | META.list:
13:55 dalek ecosystem: Merge pull request #216 from titsuki/add-naive
13:55 dalek ecosystem:
13:55 dalek ecosystem: Add Algorithm::NaiveBayes to ecosystem
13:55 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/03ddc2c979
13:59 girafe joined #perl6
14:01 azawawi any feedback on https://github.com/perl6/gtk-simple/pull/46 ?
14:06 timotimo doesn't look bad at first glance
14:10 azawawi going to merge it then since it provides the ability to do this http://pasteboard.co/1tUpg8C8.png :)
14:12 dalek gtk-simple: 611a180 | azawawi++ | lib/GTK/Simple/Box.pm6:
14:12 dalek gtk-simple: Introduce the idea of an array of hashes or objects to Box.new(@packees)
14:12 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/611a1809b1
14:12 dalek gtk-simple: f9cc80a | azawawi++ | / (2 files):
14:12 dalek gtk-simple: Use the new Box expand attribute
14:12 timotimo yeah
14:12 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/f9cc80a61b
14:12 dalek gtk-simple: e17ffa9 | azawawi++ | / (2 files):
14:12 dalek gtk-simple: More typing
14:12 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/e17ffa91bb
14:12 dalek gtk-simple: ea78db1 | azawawi++ | / (2 files):
14:12 dalek gtk-simple: Merge pull request #46 from azawawi/master
14:12 dalek gtk-simple:
14:12 dalek gtk-simple: Expose more Box API to fine tune layout
14:12 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/ea78db175c
14:17 khw joined #perl6
14:26 pullphinger joined #perl6
14:28 rindolf joined #perl6
14:46 azawawi https://github.com/perl6/gtk-simple/pull/47 # File Chooser Button :)
14:46 masak m: my ($x1, $x2) = 5, 3; $x1 = .min, $x2 = .max given minmax $x1, $x2; say ($x1, $x2).perl
14:46 camelia rakudo-moar bf099b: OUTPUT«(3, 5)␤»
14:46 azawawi http://pasteboard.co/1tYxawu0.png # screenshot
14:46 masak is there a nicer way to do the above?
14:46 AlexDaniel joined #perl6
14:47 sherwool joined #perl6
14:47 timotimo masak: yes!
14:47 timotimo m: my ($x1, $x2) = 5, 3; ($x1, $x2) .= sort
14:47 camelia rakudo-moar bf099b: ( no output )
14:47 arnsholt .=sort perhaps?
14:47 timotimo m: my ($x1, $x2) = 5, 3; ($x1, $x2) .= sort; say ($x1, $x2)
14:47 camelia rakudo-moar bf099b: OUTPUT«(3 5)␤»
14:48 arnsholt Yeah, that =)
14:48 * timotimo o/⁵o arnsholt
14:48 brrt oh, wow, that is nothing if not awesome
14:48 brrt and evil
14:48 masak ooh, .sort
14:49 Juerd .= on a list of lvalues... oh my.
14:49 brrt indeed
14:49 masak yeah, that's magical
14:49 masak Perl 6 is fairly alone in doing that kind of thing
14:50 gregf_ m;say 5,4,100 .=min
14:50 gregf_ m: say 5,4,100 .=min
14:50 camelia rakudo-moar bf099b: OUTPUT«Cannot modify an immutable Int␤  in block <unit> at /tmp/dZoFm_Ca7o line 1␤␤»
14:50 jnthn First class l-values are both awesome and such a PITA as an implementer I'm not sure I'd ever include them in a language I designed :P
14:50 yoleaux 5 Jun 2016 21:44Z <AlexDaniel> jnthn: Here is the ticket: https://rt.perl.org/Ticket/Display.html?id=128325 (gnull++)
14:50 brrt i suppose an array doesn't do that
14:50 masak gregf_: need to store it in variables first
14:50 gregf_ hmm, lists are immutable
14:50 AlexDaniel .
14:50 masak jnthn: I wonder if the same effect could be had through just-sweet-enough syntactic sugar
14:50 arnsholt I hadn't thought of doing it that way, actually
14:50 jnthn masak: Not sure :)
14:50 Juerd m: my $foo = "foo"; my $bar = "bar"; ($foo.substr-rw(1), $bar) .= sort; say $foo; say $bar
14:50 camelia rakudo-moar bf099b: OUTPUT«fbar␤oo␤»
14:51 timotimo haha
14:51 masak m: my ($a, $b, $c) = 4, 100, 5; ($a, $b, $c) .= sort; say ($a, $b, $c).perl
14:51 camelia rakudo-moar bf099b: OUTPUT«(4, 5, 100)␤»
14:51 brrt m: my ($x1, $x2) = 5,3; [$x1,$x2] .= sort; say $x1, $x2;
14:51 camelia rakudo-moar bf099b: OUTPUT«53␤»
14:51 brrt thought as much
14:51 masak brrt: no, because the array has already de-<mumble>d the lvalues
14:52 masak docont'd
14:52 masak decont'd*
14:52 Juerd Are there any more interesting lvalue methods like substr-rw?
14:52 timotimo yeah, array is a list of scalar containers. unless you bind the originals, you'll end up with new ones
14:52 timotimo Juerd: just grep the core setting for Proxy.new :)
14:53 literal m: class Foo { has $.val handles <AT-POS EXISTS-POS elems end iterator>; }; my $f = Foo.new(val => [5,6]); say $f[1], $f[*-1]
14:53 camelia rakudo-moar bf099b: OUTPUT«65␤»
14:54 literal am I missing some method in 'handles', since it's getting the wrong size of the array for '*' ?
14:54 arnsholt No, it's just that *-1 is the last but one element
14:54 brrt m: my @a = (1,2,3); @a .= sort; say @a;
14:54 camelia rakudo-moar bf099b: OUTPUT«[1 2 3]␤»
14:54 brrt eh...
14:54 literal m: my $f = [1,2]; say $f[1], $f[*-1]
14:54 camelia rakudo-moar bf099b: OUTPUT«22␤»
14:54 literal arnsholt: see --^
14:54 brrt m: my @a = (3,2,1); @a .= sort; say @a;
14:54 camelia rakudo-moar bf099b: OUTPUT«[1 2 3]␤»
14:54 huggable joined #perl6
14:55 brrt m: my @a = (3,2,1); say @a.WHAT;
14:55 camelia rakudo-moar bf099b: OUTPUT«(Array)␤»
14:55 arnsholt Or wait, am I confused again? Could be
14:55 arnsholt I thought @arr[*] was the last element
14:55 brrt m: my @a := (3,2,1); say @a.WHAT;
14:55 camelia rakudo-moar bf099b: OUTPUT«(List)␤»
14:56 timotimo no, @arr[*] is the last-plus-one element
14:56 arnsholt Right, I was confused
14:56 arnsholt In that case it's a weird thing
14:57 perlpilot sounds like everyone is confused to me.
14:57 perlpilot m:  my @foo = 1,2,3; say @foo[*];
14:57 camelia rakudo-moar bf099b: OUTPUT«(1 2 3)␤»
14:57 arnsholt m: class Foo { has $.val handles *; }; my $f = Foo.new(val => [5,6]); say $f[1], $f[*-1] # I wonder
14:57 camelia rakudo-moar bf099b: OUTPUT«Index out of range. Is: 1, should be in 0..0␤  in block <unit> at /tmp/Qycq4lTWvE line 1␤␤Actually thrown at:␤  in block <unit> at /tmp/Qycq4lTWvE line 1␤␤»
14:58 arnsholt Oh, no that won't work
14:58 arnsholt That'll eat .new too
14:59 timotimo hehehe
14:59 moritz and .val, for that matter
14:59 psch m: class A { has $.val handles * }; say A.new(:2val).perl
14:59 camelia rakudo-moar bf099b: OUTPUT«A.new(val => 2)␤»
15:00 timotimo hm, interesting.
15:00 psch afaik it doesn't do anything currently
15:00 psch m: say *()
15:00 camelia rakudo-moar bf099b: OUTPUT«No such method 'CALL-ME' for invocant of type 'Whatever'␤  in block <unit> at /tmp/V6oqL2AqBL line 1␤␤»
15:00 psch $target.set_handles($thunk()); # $thunk is Whatever, in this case
15:01 get_drunk joined #perl6
15:01 literal https://doc.perl6.org/language/subscripts ==> "In other words, @alphabet[*-1] becomes @alphabet[@alphabet.elems - 1]."
15:01 get_drunk good morning smart people
15:01 perlpilot get_drunk: don't start asking too many random questions here  :)
15:01 literal since "elems" is in "handles", why doesn't it work?
15:01 get_drunk that is a premature assumption
15:02 psch so i'd think that the handles call just gets Whatever-curried and not actually applied..?
15:03 literal but it is applied. $f.elems returns the correct value
15:03 psch m: class A { has $.val handles * }; say A.new(:2val).^attributes[0].handles
15:03 camelia rakudo-moar bf099b: OUTPUT«*␤»
15:03 literal psch: I wasn't using "handles *", that's just something arnsholt mentioned
15:05 psch m: class A { has $.val handles * }; say A.new(:2val).succ
15:05 camelia rakudo-moar bf099b: OUTPUT«3␤»
15:05 literal m: class Foo { has $.val handles <AT-POS EXISTS-POS elems end iterator>; }; my $f = Foo.new(val => [5,6]); say "elems: {$f.elems}, second: $f[1], last: $f[*-1]"
15:05 camelia rakudo-moar bf099b: OUTPUT«elems: 2, second: 6, last: 5␤»
15:05 ssotka joined #perl6
15:05 literal second and last should be the same there
15:07 llfourn I think it's because it's [*-1] is calling     SELF[^SELF.cache.elems];
15:07 llfourn not .elems
15:07 llfourn see array_slice.pm
15:08 psch m: class Foo { has $.val handles <cache AT-POS EXISTS-POS elems end iterator>; }; my $f = Foo.new(val => [5,6]); say "elems: {$f.elems}, second: $f[1], last: $f[*-1]"
15:08 camelia rakudo-moar bf099b: OUTPUT«elems: 2, second: 6, last: 6␤»
15:08 llfourn or is that only for slices?
15:08 psch well, anyway, 'handles *' (and 'handles **') does a lot currently actually
15:09 llfourn nvm that's just for slicing with *, but it might be the same problem
15:09 psch i'll blame my statements about that yesterday on being too tired to read the source properly then vOv
15:09 psch same for my statement just now, which was informed by my insufficient reading yesterday :S
15:11 llfourn m: class Foo { has $.val handles <cache AT-POS EXISTS-POS elems end iterator>; }; my $f = Foo.new(val => [5,6]); say $f[1], $f[*-1] # yup it's because it calls .cache.elems internally
15:11 camelia rakudo-moar bf099b: OUTPUT«66␤»
15:11 llfourn kinda annoying
15:15 psch it probably would be nice to have something convenient hanging around that makes delegating all Positional (or Associative, for that matter) methods to an Attribute
15:15 llfourn I agree.
15:15 psch not sure i have a sane way to do that though - someone did something with .^methods and grep a few days back, but i don't recall the specifics
15:15 llfourn then we could have spectests to make sure that at least works
15:16 llfourn that was me I think
15:16 llfourn but it wouldn't have worked I rkn
15:17 llfourn m: say ?Array.^methods.first(*.name eq "cache")
15:17 camelia rakudo-moar bf099b: OUTPUT«False␤»
15:17 llfourn m: say ?Array.^methods(:all).first(*.name eq "cache")
15:17 camelia rakudo-moar bf099b: OUTPUT«True␤»
15:17 llfourn maybe if you did that :S
15:17 llfourn but you are starting to get into evil territory with that
15:18 psch m: say Array.^methods(:all).grep(* !(elem) Mu.^methods)>>.name # not quite it...
15:18 camelia rakudo-moar bf099b: OUTPUT«(iterator from-iterator new is-lazy STORE reification-target shape pop shift splice name of default dynamic flat List AT-POS ASSIGN-POS BIND-POS DELETE-POS push append unshift prepend perl gist WHICH iterator STORE pick Slip perl fmt unshift item EXISTS-PO…»
15:18 llfourn I'm going to RT this because it would probably be easy to implement and would be a great feature.
15:18 b2gills perlpilot: Your last comment could easily be taken the wrong way by people new to #perl6. ( In fact it seems as if it was )
15:19 psch well, the easiest thing i could think of is just something like Rakudo::Internals::ListOfPositionalMethods
15:19 psch although it'd probably be in the wrong spot in Rakudo::Internals
15:20 llfourn there should simply be a role which is a coathanger for all positionaly methods
15:20 * perlpilot looks to see what his last comment was ...
15:20 llfourn then you can do handles ThatRole;
15:20 psch llfourn: i don't think that's particularly sensible, because then you'd have to stuff Iterator in there too
15:20 psch llfourn: or you don't get cache
15:20 psch wait, Iterable i think actually?
15:21 perlpilot b2gills: oh, I was just giving get_drunk a hard time because he was asking questions about P6 in #perl before he came here.
15:21 llfourn I think the implementors will have to worry about that :)
15:21 llfourn what about $.a handles @;
15:21 get_drunk it was a joke b2gills
15:21 get_drunk about chat in another channel
15:21 get_drunk so it sorta seems bad but it is not in the context that it was meant in
15:22 llfourn but that probably won't be ok because handles is just a trait hmmm
15:22 psch llfourn: as an (on and off...) implementor, i don't think compromising internal interface sanity for a feature is a good idea :)
15:22 psch FSVO "internal" - Iterator and Iterable can be implemented outside of CORE...
15:22 psch oh, but maybe i'm thinking bad again
15:23 * psch steps away from hard programming thoughts
15:23 perlpilot get_drunk: though ... you were strangely silent here after all that activity in #perl  ...
15:23 psch it's definitely too warm for that o/
15:23 llfourn the role would be purely superficial just there a way of tagging methods that make postcircumfixes work as intended
15:23 get_drunk i am observing
15:23 llfourn I don't know how it could make things more complex interanally?
15:24 perlpilot get_drunk: you didn't even re-try your "wildly successful" question, which might have gotten some different answers here (though I doubt it :)
15:24 get_drunk this is my wildly cautious side
15:24 get_drunk i feel like I should learn both though
15:25 llfourn anyway I'll RT the general problem and this convo can be continued there if need be :)
15:26 mst whyyyyy do we have a quiet for lambdabot2
15:27 mst when there's not been one in here for ... aaages
15:27 mst I'm going to assume that wasn't helping anything
15:27 perlpilot mst: because no one has been keeping up with channel maintenance in that regard?
15:27 mst (also that first -q was buharin; apparently I did remember)
15:27 dalek gtk-simple: 66bf155 | azawawi++ | / (4 files):
15:27 dalek gtk-simple: Add File Chooser Button
15:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/66bf155580
15:27 dalek gtk-simple: 063388c | azawawi++ | / (4 files):
15:27 dalek gtk-simple: Merge pull request #47 from azawawi/master
15:27 dalek gtk-simple:
15:27 dalek gtk-simple: Add File Chooser Button
15:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/063388cf94
15:28 mst perlpilot: I was just looking while I was there
15:29 mst argh, and all our bans are timed by netsplat
15:32 b2gills perlpilot get_drunk: Fair enough. Just trying to keep this an inclusive community, I see that it was a false positive ( or is that false negative, whatever )
15:33 get_drunk ok
15:33 mst b2gills: he did ask a metric fucktonne of random questions in #perl which I think triggered the comment
15:34 b2gills At least it wasn't an Imperial fuckton
15:35 get_drunk i only ever asked two questions
15:37 gregf_ m: 2 == 'metric ****tonne'
15:37 camelia rakudo-moar bf099b: OUTPUT«WARNINGS for /tmp/oGbr3bcjD1:␤Useless use of "==" in expression "2 == 'metric ****tonne'" in sink context (line 1)␤Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5metric ****tonne' (indicated by ⏏)␤  …»
15:41 gregf_ get_drunk: what were your questions *if i may ask* that did cause an uproar? *sorry, dont want to flood this channel*
15:41 get_drunk they were dumb
15:41 gregf_ you'll proly get 2 to-the-point answers on here ;)
15:42 gregf_ or more.. lol
15:44 mst there wasn't an uproar, they were just random
15:44 mst wtf is it with everybody assuming everything was more drama than it aactually was
15:45 literal m: my $f = Q{b\ar}; $f .= trans(Q{\} => Q{\\}); say $f
15:45 camelia rakudo-moar bf099b: OUTPUT«b\ar␤»
15:45 mst b2gills, gregf, please calm down and stop imagining drama where none exists so we can get back to our regularly scheduled scaring newbies with awesome language features
15:45 gregf_ quotemeta?
15:45 jast mst: but drama is so much fun :(((
15:45 get_drunk agreed
15:45 literal m: my $f = Q{b\ar}; $f .= trans(Q{\} => Q{_}); say $f
15:45 camelia rakudo-moar bf099b: OUTPUT«b_ar␤»
15:46 literal how come \\ doesn't work as a replacement?
15:46 mst jast: go join a local theatre group then, they're usually awesome :D
15:46 get_drunk blegh
15:46 jast that's the boring kind of drama
15:46 get_drunk actually
15:46 get_drunk if it was a bunch of perl hackers I'd do it
15:46 jast ideally nobody actually enjoys it. there's a residual risk of enjoyment in theatre
15:46 mst jast: you've clearly never been backstage during a performance of wyrd sisters that was going wrong
15:46 get_drunk interdisciplinary perling could be a thing
15:46 jast you've got me there
15:47 literal or is trans() only for single-char replacements?
15:48 jast literal: AFAICT, yes. just like most transliterate features in various languages.
15:48 get_drunk depends on their gender
15:48 jast but I'm wrong \o/
15:48 get_drunk same
15:48 jast based on skimming the docs, maybe try this: ... .trans([Q{\}] => [Q{\\}])
15:49 jast (I always forget about the bot and so don't try it myself :))
15:50 sufrostico /clear
15:52 jast now I want to know
15:52 jast m: my $f = Q{b\ar}; say $f.trans([Q{\}] => [Q{\\}])
15:52 camelia rakudo-moar bf099b: OUTPUT«b\\ar␤»
15:52 Humdai joined #perl6
16:01 _nadim joined #perl6
16:08 Emeric joined #perl6
16:10 llfourn psch: RT #128330
16:10 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=128330
16:12 setty1 joined #perl6
16:14 nadim joined #perl6
16:19 vike joined #perl6
16:27 kurahaupo joined #perl6
16:29 notbenh joined #perl6
16:34 silug joined #perl6
16:55 dha joined #perl6
17:06 TreyHarris joined #perl6
17:06 telex joined #perl6
17:13 firstdayonthejob joined #perl6
17:22 zakharyas joined #perl6
17:22 grondilu joined #perl6
17:25 domidumont joined #perl6
17:44 rurban2 left #perl6
18:10 masak m: class A::B {}; class C { has A::B $.ab = A::B.new }; say "alive"
18:10 camelia rakudo-moar 3156a9: OUTPUT«alive␤»
18:10 masak m: class A::B {}; class C { has A::B $.ab .= new }
18:10 camelia rakudo-moar 3156a9: OUTPUT«===SORRY!===␤Could not locate compile-time value for symbol A::B␤»
18:11 perlpilot that one seems familiar.  I bet there's already a ticket for it.
18:18 masak yes, that's from RT #126975
18:18 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=126975
18:18 spider-mario joined #perl6
18:18 masak just found it in some 007 code, and wanted to check if it's still alive and kicking :)
18:19 dha James Bond does Perl?
18:20 masak oh, he's at the cutting edge of Perl
18:20 perlpilot oh
18:20 masak dha: it's the Q department, providing Mr Bond with all the latest futuristic tech
18:20 masak finest secret Britain can produce
18:21 dha Rule Brittania!
18:21 dha Wait, is it the *real* Q giving him this stuff or that new 12 year old?
18:21 masak that's... a surprisingly apt slogan for the Bond movie franchise
18:21 TimToady why do you think MI-6 and such are illegal identifiers?
18:21 masak dha: it's the real Q
18:21 dha whew.
18:21 dha TimToady++
18:22 masak yeah, just becase Perl 6 is a 15-year-old doesn't mean it'd trust a 12-year-old to produce its stuff
18:22 * arnsholt once read a spy thriller where MI6 had been mangled into M16
18:22 TimToady no, we want the 7-year-olds, not the 12-year-olds
18:22 arnsholt Not sure if it was copy-editing or the translator's fault
18:22 TimToady by 12 they start to develop a conscience
18:23 rurban joined #perl6
18:24 * TimToady realizes his recent utterances could be taken the wrong way, and shuts up...
18:24 timotimo what, monkeys?
18:24 masak TimToady: haha
18:24 timotimo .o( it's not even called cont, it's called context! )
18:24 masak TimToady: it's already too late -- that one is already in *someone's* quote file :P
18:25 * TimToady blames camelia
18:25 sno joined #perl6
18:25 literal is there a shorthand to perform all substitutions according to some %hash?
18:25 literal on a string
18:26 TimToady with which semantics?
18:26 literal build up an alternation (LTM I suppose) of all the keys, do a global subst on the string with the values as replacements
18:27 TimToady with or without overlap after substitution?
18:27 TimToady probably without, most people would expect
18:27 literal without
18:27 literal basically the equivalent of this in Ruby: string.gsub!(Regexp.union(myhash.keys), myhash)
18:27 TimToady if trans were up to original spec, it would work for this
18:28 TimToady since trans was specced to to LTM on left-sides longer than a character
18:28 AlexDaniel m: ‘a123b123c’.trans(‘23’ => ‘’, :delete);
18:28 camelia rakudo-moar 3156a9: ( no output )
18:28 AlexDaniel m: say ‘a123b123c’.trans(‘23’ => ‘’, :delete);
18:28 camelia rakudo-moar 3156a9: OUTPUT«a1b1c␤»
18:28 TimToady oohie
18:28 TimToady maybe it'll work
18:29 * perlpilot doubts
18:29 literal I tried trans but it wouldn't insert replacements that were longer than 1 character
18:29 AlexDaniel m: say "a123b123c".trans(‘23’ => ‘X’, ‘a’ => ‘Z’, :delete);
18:29 camelia rakudo-moar 3156a9: OUTPUT«Z1Xb1Xc␤»
18:29 AlexDaniel m: say "a123b123c".trans(‘23’ => ‘LONGER’, ‘a’ => ‘Z’, :delete);
18:29 camelia rakudo-moar 3156a9: OUTPUT«Z1LOb1LOc␤»
18:29 AlexDaniel WTF?
18:29 TimToady bug, I say
18:29 perlpilot trans needs some love looks like
18:30 TimToady literal: so yeah, trans does that, it just doesn't do it right :)
18:30 yqt joined #perl6
18:30 literal alright
18:31 FROGGS joined #perl6
18:31 AlexDaniel m: say "abCDEe".trans(‘CDE’ => ‘LONGER’);
18:31 camelia rakudo-moar f0f1d4: OUTPUT«abLONe␤»
18:32 AlexDaniel :DD
18:32 AlexDaniel okay
18:33 literal I guess it just replaces the character positions it matched and no more
18:33 FROGGS o/
18:33 girafe joined #perl6
18:34 AlexDaniel oh
18:34 AlexDaniel look
18:34 AlexDaniel m: say "abCDEe".trans(/CDE/ => ‘LONGER’);
18:34 camelia rakudo-moar f0f1d4: OUTPUT«abLONGERe␤»
18:34 literal huh
18:34 FROGGS O.o
18:34 AlexDaniel wait…
18:34 AlexDaniel m: say "DabCDEe".trans(/CDE/ => ‘LONGER’);
18:34 camelia rakudo-moar f0f1d4: OUTPUT«DabLONGERe␤»
18:34 AlexDaniel m: say "DabCDEe".trans(‘CDE’ => ‘LONGER’);
18:34 camelia rakudo-moar f0f1d4: OUTPUT«OabLONe␤»
18:34 masak why am I getting this error: ?
18:34 masak Missing or wrong version of dependency '/home/masak/ours/007/lib/_007/Parser/Syntax.pm (_007::Parser::Syntax)' (from '/home/masak/ours/007/lib/_007/Parser/Actions.pm (_007::Parser::Actions)')
18:34 FROGGS one of these must be wron, no?
18:35 masak (I just changed Syntax.pm)
18:35 FROGGS masak: whipe /home/masak/ours/007/lib/.precomp
18:35 AlexDaniel FROGGS: uh, not really… I'm not sure
18:35 masak FROGGS: just did, reflexively
18:35 masak FROGGS: but I don't think the error message should ever happen
18:36 AlexDaniel ‘CDE’ => ‘LONGER’ means ‘C’ => ‘L’, ‘D’ => ‘O’ and so on
18:36 FROGGS masak: something uses X which uses Syntax.pm, and that isnt handled right it seems
18:36 FROGGS masak: aye
18:36 FROGGS masak: from my weekend experience it does not seem to happen if you only have one level of dependency
18:37 AlexDaniel m: say "CabCDEe".trans( ‘CDE’.comb => [‘LONGER’, ‘heh’, ‘test’]);
18:37 camelia rakudo-moar f0f1d4: OUTPUT«LONGERabLONGERhehteste␤»
18:37 AlexDaniel so it does work
18:38 AlexDaniel it's just that it anti-dwim a little bit
18:38 AlexDaniel is*
18:38 masak FROGGS: not sure how to count my levels of dependency, but 007 is a pretty multi-layered project
18:38 AlexDaniel literal: I believe that you can use it today
18:39 FROGGS I guess this is not enough: rakudo/src/core/CompUnit/PrecompilationRepository.pm:121:                return False if $modified > $since;
18:41 AlexDaniel so there's no bug :)
18:41 literal AlexDaniel: yeah
18:41 labster joined #perl6
18:41 AlexDaniel I find the current behavior a little bit weird but… it does the job if you play by its rules
18:43 AlexDaniel m: say ‘abc’.trans(‘b’ => ‘hello’)
18:43 camelia rakudo-moar f0f1d4: OUTPUT«ahc␤»
18:44 AlexDaniel ok, so, why no warning?
18:44 AlexDaniel m: say ‘abc’.trans(‘bc’ => ‘h’)
18:44 camelia rakudo-moar f0f1d4: OUTPUT«ahh␤»
18:44 masak g'ah, had to blow lib/.precomp again... :(
18:44 AlexDaniel ok, that I can understand
18:44 FROGGS masak: every time :/
18:45 FROGGS masak: let me try to actually golf it
18:45 masak FROGGS: much appreciated
18:45 zakharyas joined #perl6
18:53 dalek ecosystem/MARTIMM-patch-1: f712c39 | (Marcel Timmerman)++ | META.list:
18:53 dalek ecosystem/MARTIMM-patch-1: Add Config::DataLang::Refine to ecosystem
18:53 dalek ecosystem/MARTIMM-patch-1:
18:53 dalek ecosystem/MARTIMM-patch-1: See https://github.com/MARTIMM/config-datalang-refine but pod file is better
18:53 dalek ecosystem/MARTIMM-patch-1: review: https://github.com/perl6/ecosystem/commit/f712c393cf
18:57 _nadim joined #perl6
18:59 dalek ecosystem: f712c39 | (Marcel Timmerman)++ | META.list:
18:59 dalek ecosystem: Add Config::DataLang::Refine to ecosystem
18:59 dalek ecosystem:
18:59 dalek ecosystem: See https://github.com/MARTIMM/config-datalang-refine but pod file is better
18:59 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/f712c393cf
18:59 dalek ecosystem: d9aebe1 | (Zoffix Znet)++ | META.list:
18:59 dalek ecosystem: Merge pull request #217 from perl6/MARTIMM-patch-1
18:59 dalek ecosystem:
18:59 dalek ecosystem: Add Config::DataLang::Refine to ecosystem
18:59 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/d9aebe14bc
18:59 dalek ecosystem/MARTIMM-patch-1: 9cd1e6f | (Zoffix Znet)++ | META.list:
18:59 dalek ecosystem/MARTIMM-patch-1: Remove unwanted empty line
18:59 dalek ecosystem/MARTIMM-patch-1: review: https://github.com/perl6/ecosystem/commit/9cd1e6f334
19:01 nadim joined #perl6
19:06 revdiablo joined #perl6
19:08 andreoss joined #perl6
19:15 tbrowder joined #perl6
19:15 tbrowder m: say 'hi'
19:15 camelia rakudo-moar f0f1d4: OUTPUT«hi␤»
19:15 yoleaux 30 May 2016 10:50Z <Zoffix> tbrowder: any word on merging this? I recall you received positive feedback on adding a new tab: https://github.com/perl6/doc/compare/master...tbrowder:perl6-docs
19:15 FROGGS masak: it is not just a A-uses-B-uses-C problem
19:15 masak FROGGS: ok...
19:17 tbrowder Zoffix: I'm still working on it, but advice helpful; issues for me before any merge: (1) be able to sort input pod docs by file name, not internal title
19:18 tbrowder (2) figure out a way to work around the "table row with leading hyphen issue (#128221)
19:18 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=128221
19:19 FROGGS huh
19:20 FROGGS when C was changed, it tries to precompile A and fails, then B and fails, then C, continues, and then fails that D has an outdated dependency on C
19:20 FROGGS so it is more about a diamond dependency relationship
19:20 tbrowder in the meantime, I may have found another bug:  by my reading of the docs, this should be a valid scalar: "$issue-1234-fixed" but I'll try it:
19:20 tbrowder m: my $issue-1234-fixed = False;
19:20 camelia rakudo-moar f0f1d4: OUTPUT«5===SORRY!5=== Error while compiling /tmp/DXfR9HBMMD␤Preceding context expects a term, but found infix = instead␤at /tmp/DXfR9HBMMD:1␤------> 3my $issue-1234-fixed =7⏏5 False;␤»
19:21 araujo_ joined #perl6
19:21 tbrowder m: my $issue-N1234-fixed = False;
19:21 camelia rakudo-moar f0f1d4: ( no output )
19:21 tbrowder note adding a letter in front of the numbers quells the problem
19:21 tbrowder m: my $issue-_1234-fixed = False;
19:21 camelia rakudo-moar f0f1d4: ( no output )
19:21 perlpilot tbrowder: pretty that's how it's supposed to be.
19:22 tbrowder m: my $issue-1234_fixed = False;
19:22 camelia rakudo-moar f0f1d4: OUTPUT«5===SORRY!5=== Error while compiling /tmp/aZXEhWC44D␤Confused␤at /tmp/aZXEhWC44D:1␤------> 3my $issue-12347⏏5_fixed = False;␤»
19:22 perlpilot i.e.  the thing immediately after a - must match <.alpha>
19:22 [Coke] tbrowder: where in the docs? (I can't even find "identifier" in the index)
19:23 tbrowder Coke: that's another doc bug; the def is found here: <https://doc.perl6.org/language/syntax#Identifiers>
19:23 AlexDaniel m: sub test { 42 }; my $hello = 69; say $hello-10-test
19:23 camelia rakudo-moar f0f1d4: OUTPUT«17␤»
19:24 AlexDaniel tbrowder: ↑ I think that this is why it is not valid
19:24 perlpilot yep
19:24 perlpilot (at least that seems right to me)
19:25 tbrowder well the def in the docs doesn't agree (but I haven't checked the synopses)
19:27 AlexDaniel I see no tests at all: https://github.com/perl6/roast/blob/ab74762da156fa6fda5dd39281f7ffcc361d5a88/S15-literals/identifiers.t
19:27 AlexDaniel ah no, that's S15
19:27 dalek gtk-simple: baec00c | azawawi++ | examples/12-frame.pl6:
19:27 dalek gtk-simple: Add a seperate frame demo
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/baec00ca45
19:27 dalek gtk-simple: 99cc705 | azawawi++ | /:
19:27 dalek gtk-simple: Merge remote-tracking branch 'upstream/master'
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/99cc705608
19:27 dalek gtk-simple: 81d43c7 | azawawi++ | / (5 files):
19:27 dalek gtk-simple: Add initial Places sidebar example
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/81d43c7f7e
19:27 dalek gtk-simple: 46499b1 | azawawi++ | / (3 files):
19:27 dalek gtk-simple: More documentation and name fixes
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/46499b1b9b
19:27 dalek gtk-simple: 27e0315 | azawawi++ | / (3 files):
19:27 dalek gtk-simple: More fixes
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/27e0315c98
19:27 dalek gtk-simple: 7522fd8 | RabidGravy++ | / (6 files):
19:27 dalek gtk-simple: Merge pull request #48 from azawawi/master
19:27 dalek gtk-simple:
19:27 dalek gtk-simple: Separate Frame widget example + Places Sidebar + Documentation fixes
19:27 dalek gtk-simple: review: https://github.com/perl6/gtk-simple/commit/7522fd8628
19:28 AlexDaniel here https://github.com/perl6/roast/blob/ab74762da156fa6fda5dd39281f7ffcc361d5a88/S02-names/identifier.t
19:28 dha Actually, the description of identifiers says that that should be valid, but I think the examples don't necessarily agree. the first example of  a NON-valid identifier is "with-numbers1234-5" which seems to agree with the description.
19:28 sno joined #perl6
19:28 telex joined #perl6
19:28 avalenn_ the def and the examples in the doc don't agree with each other
19:29 avalenn_ https://design.perl6.org/S02.html#Names_and_Variables
19:29 avalenn_ An identifier is composed of an alphabetic character followed by any sequence of alphanumeric characters. The definitions of alphabetic and numeric include appropriate Unicode characters. Underscore is always considered alphabetic. An identifier may also contain isolated apostrophes or hyphens provided the next character is alphabetic.
19:29 dha Well, the design docs are pretty much considered historical at this point.
19:29 perlpilot avalenn_++
19:30 grondilu m: say my $apostroph'attempt
19:30 camelia rakudo-moar f0f1d4: OUTPUT«(Any)␤»
19:30 grondilu TIL
19:30 perlpilot m: my $foo't-gun;
19:30 camelia rakudo-moar f0f1d4: ( no output )
19:30 dha Ah, so the design document  has that right, and the user docs have it wrong.
19:30 dha (apparently)
19:30 avalenn_ examples in the language documentation agree with design doc
19:30 AlexDaniel dha: what's right about it?
19:31 AlexDaniel ah
19:31 AlexDaniel didn't read the last few words…
19:31 dha the last bit about what follows the hyphen or quote needing to be alphabetic.
19:32 tbrowder But the S02 definition clarifies that each portion delimited with a leading hyphen or comma must start with a alphabetic character--that's what's missing in the docs
19:32 AlexDaniel but also note that there's no test for that
19:32 dha If we're agreed that that's the problem, I'm happy to add that.
19:32 dha oop. Then there should be a test for that. :-)
19:32 tbrowder dha: and change the docs
19:32 AlexDaniel dha: didn't you just say that you'd be happy to add a test?
19:33 perlpilot AlexDaniel: I think he was talking about the docs
19:33 AlexDaniel perlpilot: shhh
19:33 dha Nope. I'd be happy to add docs. :-) But I'm willing to take a whack at the test as well.
19:33 [Coke] assuming that's the desired behavior, aye. A pull request on the docs requesting someone verify that's the desired behavior (and/or on the spec test suite) appreciated.
19:33 dha If someone would just tell me where said test should be put, I'll see what I can do.
19:34 AlexDaniel [Coke]: well, keep in mind that the only thing that is out of sync is the docs
19:34 [Coke] so we don't run afoul of pmichaud's concerns about the defacto implementation becoming spec.
19:34 AlexDaniel [Coke]: both the speculations and the implementation does it “right”
19:34 [Coke] AlexDaniel: no, if there's no tests, then there's no spec.
19:34 AlexDaniel [Coke]: ok, indeed
19:34 [Coke] the speculations help drive it, but post-christmas, we shouldn't assume they are right.
19:34 AlexDaniel dha: S02-names/identifier.t
19:35 perlpilot [Coke]++ for keeping things in perspective.
19:35 [Coke] that said, I think they are, and pre-emptively vote +1 on this. :)
19:35 dha ok. Will take a shot at it.
19:35 AlexDaniel ah wait
19:35 AlexDaniel “foob-4 is not a valid identifier (not alphabetic after hyphen)";”
19:35 AlexDaniel how did I miss that
19:35 dha Where's that?
19:35 AlexDaniel https://github.com/perl6/roast/blob/ab74762da156fa6fda5dd39281f7ffcc361d5a88/S02-names/identifier.t#L25
19:36 AlexDaniel so yeah, *everything* is right except the docs
19:36 perlpilot so there *are* tests
19:36 perlpilot one less thing for dha to do :)
19:36 AlexDaniel I'm probably blind, not sure how I missed it
19:36 dha perlpilot -  but not for the hyphen.
19:36 AlexDaniel dha: https://github.com/perl6/roast/blob/ab74762da156fa6fda5dd39281f7ffcc361d5a88/S02-names/identifier.t#L28
19:37 dha oh. how did I miss that.
19:37 dha bleah.
19:37 dha ok, so the doc just needs to change
19:37 AlexDaniel yep
19:37 AlexDaniel as simple as that
19:37 AlexDaniel OH COME ON. Who is “as”??
19:38 lizmat m: my $foo = 666; say $foo-42  # we probably don't want to lose this functionality
19:38 camelia rakudo-moar 055ca1: OUTPUT«624␤»
19:38 dha Ok. I'll add the aphabetic thing.
19:39 dha lizmat -  being able to subtract? Yeah, I'm sure *someone* needs that.
19:39 dha :-)
19:39 lizmat subtract without whitespace, was my point  :-)
19:39 tbrowder of course (slaps forehead hard)!
19:40 dha Yes.
19:40 perlpilot yeah, there are lots of examples I think that do that.
19:40 lizmat I think that's the only reason...  if we would force whitespace for an infix:<->, then we could have $foo-42
19:40 tbrowder I've just been enjoying kebab case too much...
19:40 lizmat but I think that's too alienating for people coming from p5
19:41 tbrowder but us non-typists love it, even coming from p5!
19:41 tbrowder (no shift key!!)
19:43 perlpilot just make sure you don't have variables named $A, $A-B and a constant named B that you want to subtract  ;)
19:43 dha How's this for wording: You can also embed dashes C<-> or single quotes C<'> in the middle, but not two in a row, and only if followed by an alphabetic character.
19:44 perlpilot dha: maybe add the word "immediately" for emphasis
19:44 dha ok.
19:44 lizmat m: my $a = 42; my \b = 666; say $a-b   #  perlpilot: I think LTM will take care of that
19:44 dha Anything else before I submit?
19:44 camelia rakudo-moar 055ca1: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0xaTKAlml2␤Variable '$a-b' is not declared␤at /tmp/0xaTKAlml2:1␤------> 3my $a = 42; my \b = 666; say 7⏏5$a-b   #  perlpilot: I think LTM will ta␤»
19:46 _nadim joined #perl6
19:49 _nadim joined #perl6
19:52 perlpilot m: my $a-b = 42; my $a = 39; my \b = 7; say $a-b;   # oops, I wanted 32
19:52 camelia rakudo-moar 055ca1: OUTPUT«42␤»
19:52 dha Grr... I really need to figure out how to create a pull request for JUST one commit instead of EVERY commit I've done since I last made a pull request.
19:53 perlpilot lizmat: what I was saying is that (under those contrived circumstances), you wanted to subtract, but the compiler thought otherwise.   You've just made a new footgun for yourself.
19:53 perlpilot dha: you can do that by making a branch for just the one commit.
19:53 lizmat true, hence perhaps we should emphasize longest token match at this place in the documentation ?
19:54 FROGGS masak: do you ex-/import tags in the packages the packages that fails with "Missing or wrong version of dependency"?
19:54 dha perlpilot -  that sounds like a HORRIBLE solution... :-/
19:54 FROGGS masak: do you have*
19:54 perlpilot dha: eh, branches are cheap.  I make them all the time.
19:55 perlpilot lizmat: I haven't the words, but certainly a word or two of caution could be put in the docs there.
19:56 * lizmat is currently busy with words for the P6W
19:56 dha Ok, I can't remember the last time I did a branch. Will probably have to look that up now...
19:56 Zero_Dogg joined #perl6
20:02 TEttinger joined #perl6
20:08 sufrostico joined #perl6
20:09 geekosaur branches are very cheap in git, and they're how it keeps track of this stuff
20:09 geekosaur it's not like svn or cvs where a branch is effectively a repo copy
20:10 mst dha: ideally, you'd use a branch for each unit you'll later PR
20:11 dha It's times like this I wish I were an actual developer. :-|
20:12 mst because sungo and I are so more happy go lucky, yeah :P
20:13 dha Well, it's not like I'm so happy go lucky to begin with, and were I a developer, I'd probably actually understand git better. So, result.
20:13 rurban joined #perl6
20:14 _mg_ joined #perl6
20:15 RabidGravy nobody understands git,they just use it
20:15 rurban_ joined #perl6
20:16 dogbert17 git happens ...
20:16 RabidGravy :)
20:17 mst dha: most important thing I ever learned about git
20:17 mst (cd ..; cp -a MyRepo MyRepo.bak73)
20:17 mst before I do anything clever
20:17 RabidGravy I've lost count of the version control systems I've used, but they all do the same thing
20:17 [particle] joined #perl6
20:18 dha I... wouldn't have thought that trying to do a pull request on a single commit would be considered "clever"
20:19 dha Hm. Looks like I need to figure out cherry-pick to make this work.
20:20 b2gills Considering you can force push a branch to change a PR, how would doing a PR on a single commit work?
20:22 dha Uh... I'm sure that means something, but apparently I'm too dim to know what that is. :-(
20:23 dha The great irony here is that I'm just adding a few words, and I actually have commit rights on the actual doc repository, so I *could* do it directly. But experience tells me that that way lies unpleasantness...
20:23 [Coke] dha: once you great the branch and are on it, "git cherry-pick sha-of-one-commit-you-care-about"
20:24 [Coke] s/great/create/ # huh
20:24 dha :-)
20:25 dha yeah, I'm seeing that's what I should do. I'm just not clear on what cherry-pick actually *does*. but that doesn't mean it wouldn't work, even if I have no idea what's going on.
20:26 lizmat PSA: does anybody have something in the Perl 6 world that "defined" the past week ?
20:27 stmuk_ lizmat: I think there are new videos at https://www.youtube.com/channel/UCMDEevWdptuwCJId-bPyReg since the last P6W
20:27 dha eek. I cherry-pick'ed and now it's... saying things.
20:27 stevieb dha: here's how I create PRs with an individual commit (or numerous commits related to one thing): https://gist.github.com/stevieb9/8b40e992ec05ca0ae00f730e9a387735
20:28 TEttinger lizmat: something something jon snow
20:28 TEttinger I don't watch game of thrones, but apparently it's popular recently
20:28 * TEttinger is unhelpful
20:28 dha m: say 'hodor'
20:28 camelia rakudo-moar 055ca1: OUTPUT«hodor␤»
20:29 stmuk_ actually maybe those videos did go in the last p6w (just)
20:29 lizmat stmuk_: yeah, they did  :-)
20:29 lizmat I think
20:30 stmuk_ the last day's video aren't out yet
20:32 FROGGS masak: I filed it as RT #128332
20:32 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=128332
20:33 AlexDaniel lizmat: bisectable bot is now more user-friendly
20:33 AlexDaniel bisect: class A { has $.wut = [] }; my $a = A.new; $a.wut = [1,2,3]; $a.wut.say
20:33 bisectable AlexDaniel: exit code on a “good” revision is 1 (which is bad), bisecting with inverted logic
20:33 bisectable AlexDaniel: (2016-03-02) https://github.com/rakudo/rakudo/commit/fdd37a9
20:34 AlexDaniel bisect: good=2016.03 bad 2016.02 say (^∞).grep({ last })[5]
20:34 bisectable AlexDaniel: exit code is 0 on both starting points, bisecting by using the output
20:34 bisectable AlexDaniel: “bisect run” failure
20:34 AlexDaniel bisect: say (^∞).grep({ last })[5]
20:34 bisectable AlexDaniel: exit code is 0 on both starting points, bisecting by using the output
20:34 bisectable AlexDaniel: (2016-03-18) https://github.com/rakudo/rakudo/commit/6d120ca
20:34 AlexDaniel and so on
20:35 FROGGS gnight
20:35 lizmat gnight freeze
20:35 lizmat grrr
20:35 AlexDaniel yeah, most importantly this:
20:35 AlexDaniel bisect: exit 42
20:35 bisectable AlexDaniel: on both starting points the exit code is 42 and the output is identical as well
20:38 jonadab joined #perl6
20:44 dha Ok, cherry-pick'ing did *not* remove the unwanted commits from my pull request. I think I need to murder github.
20:44 jnthn bisect: say $*VM.version
20:44 bisectable jnthn: exit code is 0 on both starting points, bisecting by using the output
20:44 bisectable jnthn: “bisect run” failure
20:44 jnthn o.o :)
20:46 AlexDaniel that's very interesting…
20:46 jnthn I didn't expect it to do anything sensible, fwiw. I was mostly curious what it would do (and hoping "nothing too bad" :))
20:47 [Coke] dha: you need to make sure you have a clean place to branch from; branch; cherry-pick; push; then PR that branch.
20:47 AlexDaniel jnthn: it shouldn't've failed
20:48 dalek bisectbot: 72d52f5 | (Aleks-Daniel Jakimenko-Aleksejev)++ | / (3 files):
20:48 dalek bisectbot: Garbage in, rainbows out
20:48 dalek bisectbot:
20:48 dalek bisectbot: This commit includes a lot of changes to how problematic cases are handled.
20:48 dalek bisectbot: The basic idea is that first the code snippet is tested on good and bad
20:48 dalek bisectbot: revisions (git is not doing that by default), and further behavior is adapted
20:48 dalek bisectbot: according to that.
20:48 dalek bisectbot:
20:48 dalek bisectbot: Also, 2015.12 is now used instead of v6.c.
20:48 dalek bisectbot: review: https://github.com/perl6/bisectbot/commit/72d52f5ad5
20:50 inokenty joined #perl6
20:51 lizmat and another Perl 6 Weekly hits the net: https://p6weekly.wordpress.com/2016/06/06/2016-23-friendlier-bisecting/
20:51 patrickz joined #perl6
20:51 jnthn AlexDaniel: btw, bisectbot is a really great idea :)
20:52 AlexDaniel jnthn: yea, thanks :)
20:52 vendethiel lizmat++ :D
20:53 [Coke] AlexDaniel++ for sure
20:54 dha joined #perl6
20:56 masak FROGGS++ # https://rt.perl.org/Public/Bug/Display.html?id=128332
20:56 AlexDaniel jnthn: https://gist.github.com/AlexDaniel/0f90c29aff43e29333f5b91b4b13435f
20:56 _28_ria joined #perl6
20:56 dha [Coke] -  define "clean place to branch from"
20:56 AlexDaniel jnthn: seems like you was just a bit unlucky
20:57 dha Also, unless I've done something wrong, git cherry-pick seems to have actually worsened the issue at hand.
20:57 mst yes, for pulling a single commit
20:57 AlexDaniel jnthn: there are like 15 revisions where the build process fails, so there's no perl6 executable. Such commits are skipped
20:57 mst once it gets merged you'll want to rebase your stack o' commits branch onto master
20:57 mst and it should just re-order itself
21:00 dha Well, the branch and the master didn't actually differ in the first place, although cherry-picking probably has changed that.
21:01 cpage_ joined #perl6
21:01 mst dha: right, I said *once it gets merged*
21:01 mst i.e. after the PR is accepted into master
21:02 [Coke] dha: are you working in a fork?
21:02 dha ah. But in the meantime, the problem I was trying to solve by making a branch (i. e. only have one commit be used in the pull request) persists.
21:02 dha [Coke] -  yes.
21:02 [Coke] if so, then rebase your master so it include's the upstream's master commits.
21:03 [Coke] then branch off your clean master that doesn't have any of your other commits.
21:03 [Coke] *includes
21:03 AlexDaniel what's the idea behind MONKEY-WRENCH and MONKEY-BARS ?
21:03 mst [Coke]: I think you've omitted about the first six steps from dha's point of view there
21:04 mst dha: so, if you keep a stack of commits in a wip branch atop master
21:04 [Coke] dha, mst: yes, well, not knowing how off-kilter his fork is, hard to tell. And feel free to jump in with any missing steps.
21:04 mst dha: you can PR one via 'git checkout master; git checkout -b some_name; git cherry-pick <the commit from wip>; git push origin some_name'
21:04 mst and then PR some_name
21:05 mst if currently your local master *is* your wip
21:05 mst then 'git checkout master; git checkout -b wip; git checkout master; git reset --hard origin/master'
21:05 dha define "wip"
21:05 dha work in progress?
21:05 mst (remember that I said about 'cp -a' first before being clever though)
21:05 mst yeah. I mean, if you're more comfortable generating a pile of commits in a single branch
21:05 mst then teasing them out one at a time to PR
21:05 mst you can use a wip branch like that
21:05 mst if they're completely independent commits, I'd give 'em a branch each up front
21:06 mst git branches are basically a symlink to a commit, they're dirt cheap
21:06 * mst resists urge to try and write Yet Another Git Tutorial
21:06 dha To be clear, what's going on on this end is: I forked the perl6/doc repo some time back. As of the beginning of this whole mess, it was up to date with the upstream repo.
21:07 mst ... wait, I think I might have a really easy way to get you a chance to 'redo from start' without losing any work
21:08 [Coke] note that if you have commit bits on the original repo, you can skip the fork entirely and put your branches to be merged in the original repo and PR from those branches.
21:08 dha But, there have been merges along the way from the upstream repo, so as to keep my fork in sync. Those commits are *all* showing up when I make a PR.
21:08 [Coke] (to cut this knot going forward)
21:08 [Coke] dha: you shouldn't be working in master in your fork if you're doing PRs
21:08 mst so, 'git format-patch origin/master' will turn each of your local commits into its own .patch file
21:08 dha Ah. That's probably what I missed.
21:08 [Coke] which doesn't help you clean up what you have today.
21:09 mst at which point, I would expect you can start again with a completely fresh fork
21:09 dha No. no it doesn't. I think at this point I should just shoot myself and avoid the christmas rush.
21:09 mst dha: yeah, GH workflow is fork, clone, 'git checkout -b mything', add comits, submit mything branch as PR, git checkout master, repeat
21:09 [Coke] how many commits are we talking about? if you made one huge PR and someone reviewed it...
21:09 geraud joined #perl6
21:09 dha Yep. I missed the branching part of that.
21:10 mst yes but (1) that would be a waste of a perfectly good bullet (2) we need your doc patches
21:10 mst (3) after bothering to try and explain it to you, clearly you owe me finishing the job, because the 10 minutes I spent totally give me the right to control your volunteer efforts, honest
21:10 dha [Coke] -  I imagine that, if I put the pull request through, someone could certainly weed out the crap. But I was going to *try* to avoid that.
21:10 perlpilot lizmat++
21:11 stmuk_ https://github.com/perl6/doc/compare/master...dha:master ?
21:11 mst dha: the other key problem is that you merged rather than rebasing, which makes for some untangling
21:11 mst though not that much
21:11 mst honestly, cherry picking each of your real commits into its own branch
21:11 mst then blowing away your current master
21:11 dha mst - please. I've been dealing with comic book fans lately. your claims to privilege over me pales in comparison. :-)
21:11 mst seems like it'd work fine to me
21:11 RabidGravy well "the crap" just makes it difficult to review, it won't mess up the target
21:11 dha stmuk_ -  yes, that would be my fork
21:12 mst dha: bah. I'll try and up my game next time.
21:13 * dha goes to read up on rebasing
21:14 TeTpaAka joined #perl6
21:14 stmuk_ what is the actual problem?
21:14 [Coke] dha: https://stackoverflow.com/questions/7244321/how-do-i-update-a-github-forked-repository
21:14 mst stmuk_: basically he wants to take his single master with assorted patches
21:14 mst and turn it into one PR per patch
21:14 mst without the mess
21:14 mst I think
21:14 mst dha: correct?
21:15 [Coke] top answer on how to do the rebase from upstream. (you might need a clean master to do that.)
21:15 dha Well, most of the commits I don't want to PR at all, but, basically, yes.
21:15 dha [Coke] -  thanks. Do they also have a "how do I clean my master" entry? :-)
21:15 [Coke] you could probably programmatically find the commits you have that upstream doesn't have and do a per-branch commit for each one with a shell script.
21:16 [Coke] if it's 100 commits, that might be worth it. If it's 10... eh.
21:16 [Coke] heading out. g'luck.
21:16 dha thanks
21:17 cpage_ joined #perl6
21:17 dha I'm actually trying to PR *one* commit. I just can't figure out how to not PR all the other crap.
21:18 cpage_ joined #perl6
21:18 stmuk_ just delete the branch and change the few lines again?
21:19 stmuk_ and in future "git pull --rebase" if you care (and most people don't bother but then most would only git pull once before committing)
21:19 mst dha: I thought you managed that with cherry-pick
21:19 mst hm. do you have a remote for upstream?
21:20 dha Nope. cherry-pick just added the relevant commit *again*
21:20 dha I believe so.
21:20 mst dha: er, yes, you need to do the cherry pick on a fresh branch that contains only the perl6 repo's master
21:21 mst dha: do you have a remote for upstream?
21:21 dha I believe so. Yes. Alternately, I am totally misunderstanding you.
21:21 mst ok, what's it called?
21:22 mst (origin is presumably your fork, not the perl6/doc repo itself)
21:23 dha yes.
21:23 mst so, what's the remote for perl6/doc called?
21:23 dha git tells me I have origin, perl6 and upstream
21:23 mst AHA
21:23 dha aha?
21:23 mst except that now I dunno whether perl6 or upstream is the real one
21:23 mst which one have you been merging from?
21:24 mst perl6/master or upstream/master ?
21:25 mst dha: ?
21:25 dha I should note that the urls for perl6 and upstream are the same.
21:25 mst ok
21:25 mst so it probably doesn't matter
21:25 mst RIGHT, let's see if this works then
21:25 dha Oh, I'm at the point where *nothing* matters anymore...
21:25 mst git checkout perl6/master; git checkout -b this_is_msts_fault; git cherry-pick <commit goes here>; git push origin this_is_msts_fault;
21:26 mst and then see if the PR button on origin looks like it's going to PR the commit you wanted it to
21:26 dha it doesn't like "git checkout perl6/master"
21:27 masak 'night, #perl6
21:27 dha night masak
21:27 mst dha: "doesn't like" ?
21:27 dha error: pathspec 'perl6/master' did not match any file(s) known to git.
21:27 mst it'll do some complaining about 'detached head'
21:27 mst ok. try 'upstream/master'
21:27 mst there must be one somewhere in here
21:27 dha oh. wait. i did something wrong.
21:28 mst the idea was that appart from <commit goes here>
21:28 mst you could actually copy-paste what I said into IRC
21:28 mst thereby reducing ti to 'mst did something wrong'
21:28 dha ok, now I'm getting the detached head thing.
21:29 mst that's fine
21:29 mst git checkout -b this_is_msts_fault
21:29 dha sorry about that. I tried to checkout in the wrong window before.
21:29 mst # now you're in a new branch from that
21:29 mst git cherry-pick <commit> # cherry pick it
21:29 stevieb9 joined #perl6
21:29 mst git push origin this_is_msts_fault # push just this new branch to origin
21:29 dha ok.... let me  cherry-pick...
21:30 RabidGravy I'm your ch-ch-ch-cherry bomb!
21:31 literal is there a way to do an exact type check against a typename, analogous to «$foo.^name eq 'Hash'»? comparing against .WHAT seems to cause warnings, and smartmatching is too lax
21:31 dha ok, picking of cherry achieved.
21:31 * dha pushes
21:32 dha Now which branch am I trying to do the PR from?
21:32 mst this_is_msts_fault
21:32 stevieb9 the one you just pushed
21:32 mst to perl6/doc/master
21:33 dha \o/
21:33 dha It's now just the one commit.
21:33 dha mst++
21:34 stevieb9 after you've submitted the PR, don't forget to switch back to master, or you'll add more commits to the branch (and the PR)
21:34 mst right, at this point you can do 'git checkout master' to get back to your own master-with-stuff
21:34 mst then do 'git checkout -b this_went_horribly_wrong' to make a copy of it
21:35 mst then 'git checkout master' to go back to your master
21:35 mst then 'git reset --hard perl6/master' to force it to look like the upstream master
21:35 mst and then you can start from fresh
21:35 mst and cherry pick out anything else you want from this_went_horribly_wrong later
21:36 mst dha: oh, and before you do any of this, do a 'cp -a' in case it goes even more horribly wrong - I did those all the time while learning git
21:37 dha ok, done.
21:37 dha Thanks!
21:38 mst when it goes well, git is amazing. once you get into a mess, it's about as fun to escape as "I'm not sure what shape my undo tree in vim is but I am sure I can't find the state I wanted anymore"
21:38 mst hence the 'cp -a' every so often while you learn
21:38 dha *nod*
21:38 dha mst++
21:39 * mst grins
21:40 dha is there any point to putting this_went_horribly_wrong up to github?
21:40 stevieb9 when we switched over to git from svn at work last year, there wasn't enough training, and those new to git caused all sorts of mayhem. Not fun
21:41 mst dha: backup, and being able to link it to other people later, and being able to clone it on another machine to steal more bits later
21:41 mst and if anybody judges you negatively on the contents of a branch with *that* name, I think they can safely be ignored
21:41 dha ok. :-)
21:41 AlexDaniel literal: what do you mean by smartmatching is too lax?
21:41 dha now I just have to remember how to do that.
21:41 stmuk_ there is actually one commit anyway .. github PR would have worked
21:41 mst dha: wait
21:41 * dha waits
21:42 mst stmuk_: no, we spent a long time unfucking to get to having only one commit.
21:42 mst stmuk_: that was the entire conversation
21:42 mst dha: to get this_went up to GH:
21:42 stmuk_ the rest are just merges
21:42 mst dha: git checkout this_went_horribly_wrong; git push origin this_went_horribly_wrong;
21:42 mst dha: then to get your rest master back up to GH
21:42 mst dha: 'git checkout master; git push --force origin master'
21:42 stmuk_ so there is no point in saving anything
21:43 dha ok.
21:43 mst oh, the only commit with any contents at all is the one already PRed now?
21:43 dha pretty much.
21:43 mst then, yeah, who cares
21:44 mst git branch -D this_went_horribly_wrong; # and don't bother pushing it to origin
21:44 * mst was doing belt-and-braces lets-not-lose-anything
21:44 dha eh. already pushed
21:44 mst without ever actually looking at the repo, because I was trying to achieve 'dha at least can pretend he knows what's going on' as well as things being sorted
21:44 stevieb9 having issues installing Inline::Python today. Started on FreeBSD, so when I got home I tried Ubuntu in hopes it was my box. Travis is not enabled, so I can't see if this is a global problem. Can someone please have a look to see if I'm missing something? https://gist.github.com/stevieb9/6e8afa08c10409f921b5335d4bfac03b
21:44 mst dha: I mean, I can't magically teach you to understand all of git
21:45 mst dha: but, like, a delusional sense of warm fuzziness? that's a doabla goal :D
21:45 stevieb9 I'm installing the module per the CONTRIBUTING doc
21:45 stevieb9 for perl6/doc
21:45 stmuk_ this is clear from the url I gave at 2111 above
21:45 dha Hm. I checked out master and it's telling me I'm behind by 382 commits, and it can be fast-forwarded. It also says I can use git pull to update my local branch.
21:46 dha Should I do that, or is there something else I should do that will not screw up everything again?
21:46 dha Also, I'm happy to be deluded in a fuzzy manner.
21:47 mst dha: yeah, if it says 'it can be fast-forwarded' then a pull shouldn't break anything
21:48 dha ok. things have been pulled. I assume I should now push?
21:48 mst I tend to always specify a branch to push
21:48 mst so 'git push origin master'
21:48 dha ah. ok.
21:48 mst (this means that, have I screwed up another branch, I don't accidentally propagate that without noticing)
21:49 stevieb9 very good habit to get into for sure...
21:49 mst "if git was a physical tool, it would have black and yellow stripes"
21:49 dha Apparently everything is up to date.
21:49 dha ...so it would be a bumblebee?
21:49 mst I don't know, it's rjbs' excuse for dzil having sharp edges
21:50 stmuk_ you should have made the whitespace changes in another commit really :)
21:50 dha Oh. sorry.
21:50 dalek doc: f97fc88 | (David H. Adler)++ | doc/Language/syntax.pod:
21:50 dalek doc: Added alphabetic-after-hyphen-or-quote restriction to Identifier
21:50 dalek doc: description.
21:50 dalek doc: review: https://github.com/perl6/doc/commit/f97fc88bb7
21:50 dalek doc: 7bb0eff | (Steve Mynott)++ | doc/Language/syntax.pod:
21:50 dalek doc: Merge pull request #563 from dha/this_is_msts_fault
21:50 dalek doc:
21:50 dalek doc: Added alphabetic-after-hyphen-or-quote restriction to Identifier
21:50 dalek doc: review: https://github.com/perl6/doc/commit/7bb0eff1b1
21:51 mst dha: later, we can talk about "how to hate yourself while turning one commit into two"
21:51 mst but right now it's 22:51 UK time
21:51 mst and i'm thinking it's time to start drinking
21:51 dha I don't actually need lessons on how to hate myself.
21:51 dha ooh. drinking.
21:51 dha I don't think I'm doing that until wednesday.
21:52 mst dha: no, but doing it *and* getting two working commits afterwards takes a little extra knowledge
21:53 mst you provide the generalised self hatred, i'll provide the git specific self hatred
21:53 mst SYNERGY!
21:53 dha deal.
21:55 stmuk_ | https://gist.github.com/stevieb9/6e8afa08c10409f921b5335d4bfac03b
21:55 stmuk_ oops
21:55 AlexDaniel mst: just nuke this commit, and then add -p ?
21:56 AlexDaniel mst: assuming that it's the last commit
21:56 stmuk_ stevieb9: are you using python from ports/pkg? if so you need to recompile your own with -fPIC
21:57 mst AlexDaniel: read through the past hour of backlog, then tell me again that you think dha's at a level where 'just' is a word that's even remotely sensible to use for explaining that
21:57 AlexDaniel I think that dha was doing great :)
21:57 dha Aw... thanks.
21:57 mst yes. but I wouldn't describe unwinding and re-assemblin a commit as 'just' for ... oh never mind
21:58 RabidGravy just drink beer and it will be fine
21:58 dha FWIW, I think I understand what you're suggesting, but not certain I would be able to actually implement it.
21:58 dha RabidGravy -  that's your answer to everything.
21:58 mst dha: which is precisely why I was offering to talk you through it rather than the offhand 'just'
21:59 mst that's because it's a GOOD answer
21:59 dha And I thank you for it.
22:01 stmuk_ stevieb9: BTW Inline::Python is optimal for perl6/doc (athough building HTML is a lot slower under pygments)
22:02 stmuk_ s/optimal/optional
22:02 stmuk_ optimal as well
22:02 cpage_ joined #perl6
22:03 stevieb9 stmuk_: I did compile with --enable-shared, but I'm doing a new build now as perhaps the new python wasn't being used.
22:05 lizmat good night, #perl6!
22:06 dha night lizmat
22:07 stmuk_ stevieb9: its probable noone has tried this under clang either
22:09 stevieb9 stmuk_: I'll rebuild on my fbsd box tomorrow if this works here on my ubuntu laptop now. If it still won't work on fbsd, I'll open a ticket
22:09 stmuk_ stevieb9: some stuff assumes gmake too
22:10 stmuk_ maybe not perl6/doc I forget
22:10 kurahaupo joined #perl6
22:11 cpage_ joined #perl6
22:12 tbrowder joined #perl6
22:14 kid51 joined #perl6
22:27 sftp joined #perl6
22:27 skids joined #perl6
22:29 tomboy64 joined #perl6
22:30 Sgeo_ joined #perl6
22:41 sufrostico joined #perl6
22:47 mr-foobar joined #perl6
22:47 _28_ria joined #perl6
22:53 bjz joined #perl6
22:54 huggable joined #perl6
22:55 dha joined #perl6
22:59 firstdayonthejob joined #perl6
23:03 mohae_ joined #perl6
23:11 labster joined #perl6
23:11 kurahaupo joined #perl6
23:13 kurahaupo_ joined #perl6
23:16 captain-adequate joined #perl6
23:25 jack_rabbit joined #perl6
23:27 Hotkeys_ is there a way to bind to a class attribute
23:27 Hotkeys_ say I have some class Foo { has $.attr } and I want to bind some $bar = "bar"
23:28 Hotkeys_ to some $foo.attr
23:28 Hotkeys_ but I want $foo.attr to change if I change $bar
23:28 Hotkeys_ how would I do that?
23:29 Juerd I don't know how, or if it's even possible.
23:29 Juerd Why do you want this?
23:29 Hotkeys_ I'm just curious really
23:29 Hotkeys_ since you can bind to regular variables
23:35 awwaiid m: class Foo { has $.attr; method bindit($v is rw) { $!attr := $v } } ; my $x = 5; my $f = Foo.new; $f.bindit($x); say $f.attr; $x = 42; say $f.attr
23:35 camelia rakudo-moar f80cc7: OUTPUT«5␤42␤»
23:35 yoleaux 5 Jun 2016 20:35Z <DrForr> awwaiid: It seems that lrepl only lets you invoke one middleware layer at a time, is this by design?
23:35 raydiak w
23:36 raydiak wrong terminal
23:37 raydiak though while I'm here...hi #perl6 \o
23:37 awwaiid DrForr: The intent, iirc, is for middleware to work very much like PSGI (rack, ring, wsgi,...) middleware -- each layer calls filters the data and invokes the next, and then can filter again on the way back out
23:38 Hotkeys_ oh
23:38 Hotkeys_ thanks awwaiid
23:38 Hotkeys_ idk why i didn't think of that
23:38 awwaiid Hotkeys_: ya. It told me the left-hand-side couldn't be bound, so I figured wrapping it into a method so that the left-hand-side was more boring would work
23:39 wamba joined #perl6
23:45 awwaiid I don't know WHY you'd want to do that though :)
23:49 Juerd Binding at a distance sounds like a bad idea.
23:53 _28_ria joined #perl6

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

Perl 6 | Reference Documentation | Rakudo