»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
00:00 bisectable6 left, committable6 left, bisectable6 joined, ChanServ sets mode: +v bisectable6, committable6 joined 00:03 niceperl left 00:06 huf joined 00:07 Herby_ joined
Herby_ o/ 00:07
question. If I have two strings "12/31/2015 0400" and "12/31/2015 0700", how do I convert those to datetime objects to see if greater there is greater than 4 hour difference between the two? 00:08
I have a tenuous grasp on datetime in general, and I can't figure it out in the docs 00:09
00:12 konsolebox left
jnthn I don't think anything built-in will parse that format (it'll only do ISO 8601, and that sure ain't what you have) 00:12
00:13 konsolebox joined
Herby_ hmm. any recommended modules to use? 00:14
jnthn m: given "12/31/2015 0400" ~~ /(\d+)'/'(\d+)'/'(\d+) ' ' (\d\d)(\d\d)/ { dd DateTime.new(day => $0, month => $1, year => $2, hour => $3, minute => $4) }
camelia Month out of range. Is: 31, should be in 1..12
in block <unit> at <tmp> line 1
jnthn Middle endian be dammed!
Herby_ :) 00:15
jnthn m: given "12/31/2015 0400" ~~ /(\d+)'/'(\d+)'/'(\d+) ' ' (\d\d)(\d\d)/ { dd DateTime.new(month => $0, day => $1, year => $2, hour => $3, minute => $4) }
camelia DateTime.new(2015,12,31,4,0,0)
jnthn That's one way to parse it
Then I think you can just use - with the two to get an Instance
uh, Instant
Herby_ great, i'll give that a go. Thanks!
00:29 evalable6 left, evalable6 joined, ChanServ sets mode: +v evalable6, cdg_ joined 00:30 bisectable6 left, committable6 left, bisectable6 joined, ChanServ sets mode: +v bisectable6, committable6 joined, ChanServ sets mode: +v committable6
lookatme o/ 00:30
Herby_, o/ 00:31
Herby_ lookatme: \o/
lookatme morning here 00:32
00:32 cdg left
Herby_ australia? 00:33
00:33 mson joined
lookatme No, china 00:34
Here is 8:30 am
00:34 cdg_ left
Herby_ 5:30 PM in cold Colorado 00:34
lookatme yeah, It's winter now 00:35
so cold
AlexDaniel squashable6: next 00:37
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in 1 day and ≈9 hours (2017-12-02 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
jnthn Cold is fine, I can just wrap up warmer. Beats hot, when there's not much to do about it. :) 00:38
Herby_ ^
jnthn is still waiting for some snow
lookatme yeah, the summer is so hot, we have nothing to beat it 00:40
Is this page perl6.org/compilers/features still update ? 00:42
I am keep watch out the macro feature. 00:44
And the macro will be redesign ?
00:45 konsolebox left 00:46 konsolebox joined 00:48 aborazmeh joined, aborazmeh left, aborazmeh joined 00:51 cdg joined, jeromelanteri left, BenGoldberg joined 00:56 cdg left
jnthn lookatme: Yeah, masak is exploring/prototyping a bunch of that; it'll be a while yet, though, it's difficult and a lot of work to do well 00:57
lookatme oh thanks
jnthn github.com/masak/007/ may be interesting to you 00:58
00:59 evalable6 left, evalable6 joined
lookatme oh, great 00:59
jnthn Sleep time for me; 'night 01:00
lookatme night
01:00 bisectable6 left, committable6 left, bisectable6 joined, ChanServ sets mode: +v bisectable6, committable6 joined, ChanServ sets mode: +v committable6
Herby_ night! 01:01
01:09 vike left
SmokeMachine m: <abc xyz>.classify( *.contains: any 'a'..'f' ) 01:10
camelia ( no output )
SmokeMachine m: say <abc xyz>.classify( *.contains: any 'a'..'f' )
camelia {False => [abc xyz xyz xyz xyz xyz xyz], True => [abc]}
SmokeMachine can anyone explain me why?
01:13 committable6 left, committable6 joined, ChanServ sets mode: +v committable6
Herby_ Zoffix: I'm following along your Weatherapp tutorial. Did you ever write any code for part 4? 01:13
SmokeMachine the way I think, abc contains the letter (True) in 3 possibilities of 'a'..'f' (a, b and c) and doesn't contains in another 3 (False) (d, e and f)... so, in my mind, the answer should be: {False => [abc abc abc xyz xyz xyz xyz xyz xyz], True => [abc abc abc]}
could, please, someone explain me that? 01:14
01:14 raschipi joined, margeas left
SmokeMachine Os this really expected? 01:17
01:17 espadrine left 01:19 troys is now known as troys_ 01:21 vike joined
raschipi m: <abcz xyzj>.classify( *.contains: any 'a'..'f') 01:21
camelia ( no output )
lookatme Interesting output
raschipi m: say <abcz xyzj>.classify( *.contains: any 'a'..'f') 01:22
camelia {False => [abcz xyzj xyzj xyzj xyzj xyzj xyzj], True => [abcz]}
lookatme m: say <abc>.classify( *.contains: any 'a'..'f' )
camelia {False => [abc], True => [abc]}
lookatme m: say <xyz>.classify( *.contains: any 'a'..'f' )
camelia {False => [xyz]}
lookatme m: say <xyz abc>.classify( *.contains: any 'a'..'f' )
camelia {False => [xyz abc abc abc], True => [abc]}
raschipi m: say 'abc'.contains: any 'a'..'f'
camelia any(True, True, True, False, False, False)
01:23 astronavt joined
lookatme Hmm, seems like some problem about junction and classify 01:23
01:24 mcmillhj joined
SmokeMachine This code was gotten from a roast test... 01:25
raschipi what does the test say the result should be? 01:27
and are you sure the test isn't fudged for rakudo?
SmokeMachine github.com/perl6/roast/blob/ac5295...ify.t#L126
timotimo it occurs to me that .classify({ $_ }) is equivalent to .Bag 01:28
well, you might have to put an xx in there as well 01:29
raschipi RT #126032
synopsebot RT#126032 [resolved]: rt.perl.org/Ticket/Display.html?id=126032 The .classify method is calling the closure twice on the first element
raschipi Right, it's expected. Not supposed to be used in that form, it's just for the test. 01:30
m: say so <abc>.contains: any 'a'..'f' 01:31
camelia True
raschipi m: say so <xyz>.contains: any 'a'..'f'
camelia False
raschipi m: say so <abc>.contains: all 'a'..'f' 01:32
camelia False
raschipi m: say so <abc>.contains: all 'a'..'c'
camelia True
SmokeMachine But, shouldn’t it return {False => [abc abc abc xyz xyz xyz xyz xyz xyz], True => [abc abc abc]}? 01:33
I still don’t get it... 01:35
01:35 troys_ is now known as troys
Zoffix Herby_: no, I got bad response to those series and got discouraged from finishing them. There won't ever be Part 4 01:35
Herby_ Sorry to hear that. For what its worth, I really enjoy your blogs and postings 01:36
raschipi Me too, really like them.
01:37 Todd joined
SmokeMachine raschipi: what’s the value of a test that uses a form that shouldn’t be used? 01:38
Todd Hi All. I am about to write a Perl6 program for a customer on Windows 7, sp1, 32 bit (not 64)
01:39 xi- left
Todd Is this the best place to download Perl 6 for Windows 32 bit? rakudo.org/how-to-get-rakudo/ 01:39
01:40 BrianOn99 joined
Zoffix Todd: in a way; you'll notice the 32-bit version is nearly 2 years old 01:40
Todd nuts, any better download?
raschipi SmokeMachine: It's not that it shouldn't be used, it's just that it doesn't collapse a junction before using it and junctionsare more useful when they collapse.
Zoffix Todd: you could try building from source: github.com/zoffixznet/r#windows 01:41
Todd: note that JIT is not available on 32-bits, so your rakudo will be noticably slower 01:42
Todd: may want to run `git checkout 2017.11` before the `perl Configure.pl` step to get a much more well-tested the release commit, rather than bleeding edge
01:43 xi- joined
Todd If I build, it look like I will need Perl 5. Was hoping not to have to do that. Also, speed is not an issue. Works properly is. 01:43
Zoffix Todd: yeah, Configure.pl is a Perl 5 script; also you'll need a C compiler, which comes with Strawberry Perl 5
Todd rats. I was hoping for a lot easier 01:44
01:44 BrianOn99 left
Zoffix Sorry. No volunteer stepped up with the resources to build 32-bit Windows 01:44
Todd looking at the link, I do not see a switch for 32 bit. My Windows VM is 64 bit. I would like to compile it locally 01:45
Zoffix It figures it out automatically. No idea if there's a switch to force it into 32 bit 01:46
Todd poop
if I originally write it in Linux, do I need to be careful to use an editor that saves in cr/lf 01:48
?
Zoffix Todd: write what? 01:49
lookatme No, if you execute it with `perl6 xxx.p6`
Todd my perl6 program. get a head start on it in Linux (my base system). then remote into the customer's w7 machine and copy it over and finish it off 01:50
lookatme The newline only effect shebang, I think
Zoffix Todd: it'll work, but depending on what you open it with on Windows, it might end up all on one line (e.g. in notepad.exe). Just run `unix2dos foo.p6` before sending it
Todd forgot about that one. thank y for hte reminder 01:51
I think I will try to old versionof rakudo. If it doesn't work, then I will try compiling up a new one. Thank you guys! 01:52
Zoffix Any time
Todd bye bye 01:53
lookatme 88
01:53 Todd left 01:55 dj_goku left 02:02 xi- left 02:03 Cabanossi left
Geth mu: ef13dd7847 | (Zoffix Znet)++ (committed using GitHub Web editor) | misc/perl6advent-2017/schedule
Put "Perl 6: Sigils, Variables, and Containers" to 2nd

It's been scheduled now
02:03
02:03 xi- joined 02:04 Cabanossi joined 02:08 konsolebox left 02:14 konsolebox joined, llfourn joined 02:18 zakharyas joined 02:19 kerframil left 02:20 kerframil joined 02:22 Zoffix left 02:31 troys is now known as troys_ 02:46 ilbot3 left, pilne left 02:48 raschipi left 02:56 kitsunenokenja left 02:57 cdg joined 02:58 ilbot3 joined, ChanServ sets mode: +v ilbot3 03:01 konsolebox left 03:02 cdg left 03:03 ufobat___ joined 03:04 cdg joined 03:07 ufobat_ left, konsolebox joined 03:17 Herby__ joined, Cabanossi left 03:19 Cabanossi joined 03:21 konsolebox left 03:22 konsolebox joined 03:28 Khisanth left 03:30 mcmillhj left 03:48 konsolebox left 03:50 konsolebox joined, Khisanth joined 03:53 eliasr left 03:55 konsolebox left 03:58 konsolebox joined 04:06 jeromelanteri joined 04:14 lookatme left, lookatme joined 04:17 Cabanossi left, llfourn left 04:18 Cabanossi joined 04:23 wamba joined 04:33 mson left 04:38 dj_goku joined 04:50 wander joined 04:52 xtt joined 04:53 konsolebox left 04:55 konsolebox joined 04:58 astj joined 05:03 cdg left, cdg joined 05:08 cdg left 05:16 Cabanossi left 05:18 Cabanossi joined 05:19 mson joined
wander jnthn: 05:30
m: multi sub g(Int \a, Int \b) { say 0; nextsame };multi sub g(Any \a, Int \b) { say 1; nextsame };multi sub g(Int \a, Any \b) { say 2; nextsame };multi sub g(Any \a, Any \b) { say 3; nextsame };g(1, 2);
camelia 0
1
2
3
05:30 astronavt left
wander m: multi sub g(Any \a, Int \b) { say 1; nextsame };multi sub g(Int \a, Any \b) { say 2; nextsame };multi sub g(Any \a, Any \b) { say 3; nextsame };g(1, 2); 05:30
camelia Ambiguous call to 'g'; these signatures all match:
:(\a, Int \b)
:(Int \a, \b)
in block <unit> at <tmp> line 1
wander could i infer that 'Ambiguous' judge is only applied for the first dispatch? 05:31
05:32 Xliff left
wander m: multi sub g(Int \a, Int \b) { say 0; nextsame };multi sub g(Int \a, Any \b) { say 2; nextsame };multi sub g(Any \a, Int \b) { say 1; nextsame };multi sub g(Any \a, Any \b) { say 3; nextsame };g(1, 2); 05:32
camelia 0
2
1
3
05:34 wamba left
wander it's weird that textual ordering tie-breaker works in re-dispatch, where the signature doesn't have `where` clauses, named parameters or something. 05:35
05:36 Xliff joined
Xliff \o 05:36
Is there a blog post or tutorial on how to write basic networking apps in P6? 05:37
05:38 troys_ is now known as troys
Xliff There's a basic skeleton, here but is there something else with more details? 05:40
docs.perl6.org/type/IO::Socket::INET
05:43 Herby__ left 05:49 Herby_ left
lookatme Xliff, there are a lot of blog post in rakudo.party/post/Perl-6-Hands-On-...pp--Part-1 05:54
maybe help
05:54 aborazmeh left
Xliff Thanks 05:56
lookatme Xliff, And if you don't know Perl6 weekly, I recommend you check out this: p6weekly.wordpress.com/ 05:57
05:59 BenGoldberg left
Xliff Hah. Good start, but never got to Part 4 05:59
06:13 wander left 06:16 Cabanossi left 06:17 cpage_ left 06:18 Cabanossi joined 06:20 cdg joined 06:23 troys left 06:25 cdg left 06:28 darutoko joined 06:30 cdg joined 06:35 cdg left 06:40 astj left
tony-o Xliff: there's also IO::Socket::Async if you're into that sort of thing 06:40
06:45 Cabanossi left 06:48 Cabanossi joined 06:53 domidumont joined 06:55 khw left 06:58 domidumont left 06:59 domidumont joined 07:03 Guest72929 joined 07:08 Guest72929 left, geospeck joined 07:09 domidumont left 07:10 domidumont joined 07:11 someuser_ joined 07:17 rindolf joined 07:23 someuser_ left 07:24 someuser joined, lowbro joined, lowbro left, lowbro joined 07:26 MasterDuke left 07:34 anop joined
anop i have file of 100 lines ....... .race(batch => 32, degree => 4) how it work ..... 07:34
what is batch ?
what is degree ?
07:35 astj joined 07:39 astj left 07:56 abraxxa joined 07:59 mson left
AlexDaniel anop: hello :) What you wrote should work. Like “@smth.race(batch => 32, degree => 4).map({ your code here })” or “race for @smth.race(batch => 32, degree => 4) { your code here }” 07:59
anop: degree is basically the number of threads
anop: and batch is how meach each thread “takes” each time 08:00
perhaps my explanation is not clear enough :)
much* 08:01
08:01 kerframil left
AlexDaniel anop: with 100 lines perhaps a batch size of 5 will work ok 08:02
degree => 4 is probably reasonable for the average computer :) 08:03
08:09 geospeck left 08:25 wamba joined 08:27 wander joined 08:31 cpage_ joined 08:34 dakkar joined 08:47 xtt left 08:48 wamba left
Geth ecosystem: JJ++ created pull request #381:
Adds Wikidata::API
08:53
08:54 scimon joined 08:58 konsolebox left 08:59 wamba joined 09:00 konsolebox joined 09:05 wamba left
anop hello AlexDaniel 09:07
that means, at a time for four thread will run and every thread has 32 lines for processing 09:08
that means, at a time four thread will run and every thread has 32 lines for processing 09:09
lookatme Not sure, it's no document about it. Only batch is clear
AlexDaniel well, each thread will take 32 items, process them, then take the next 32 and so on
anop that means, at a time 128 lines will process 09:11
that means, at a time 128 lines will be process
09:11 wander left
lookatme I don't think degree is thread number 09:12
AlexDaniel why not
anop hello AlexDaniel, that means, at a time 128 lines will be process
is right ?
is it right ?
lookatme According the mean of `degree` :) 09:13
AlexDaniel anop: well. If you have 4 threads, then three of them will be processing 32 items, and the fourth thread will be processing just 4 items…
lookatme :) byebye
09:13 lookatme left
AlexDaniel so ideally you should set the batch size to 25 if you have 100 items exactly 09:14
but I'd go lower than that assuming that the processing may different time… 09:15
it really depends
09:18 Voldenet joined, Voldenet left, Voldenet joined 09:21 konsolebox left, wander joined 09:22 konsolebox joined
Geth ecosystem: cb3f2869a5 | (JJ Merelo)++ | META.list
Adds Wikidata::API
09:25
ecosystem: 3fd867a4f8 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | META.list
Merge pull request #381 from JJ/master

Adds Wikidata::API
09:27 konsolebox left 09:28 konsolebox joined 09:32 konsolebox left 09:33 geospeck joined, konsolebox joined 09:35 poohman joined, poohman left
anop thank you so much AlexDaniel 09:36
09:36 poohman joined
DrForr Last year I had a problem with network connectivity and the Advent calendar - I can do one if I can write and post it before I leave, should I reserve the 16th for me? 09:36
09:36 poohman left 09:37 sena_kun joined, poohman joined, poohman left
AlexDaniel DrForr: sure 09:37
huggable: advent
huggable AlexDaniel, Sign up to write an Advent blog post: github.com/perl6/mu/blob/master/mi...7/schedule
09:37 ecocode_ joined, poohman joined 09:38 poohman left, sena_kun left, poohman joined
DrForr Excellent. I had to cancel at the last minute, ISTR Zoffix moving one of his up to cover. 09:38
09:38 poohman left, poohman joined, Juerd_ joined 09:39 poohman left, wictory[m] left, Juerd left, CIAvash[m] left, BinGOs left, zakharyas left, sftp left, Juerd_ is now known as Juerd, sftp joined 09:40 zakharyas joined, BinGOs joined, BooK joined, poohman joined, poohman left, sjn left, poohman joined, domidumont left, poohman left 09:41 sjn joined, poohman joined, poohman left, poohman joined, poohman left, john51 left, poohman joined, yoleaux left 09:42 poohman left, john51 joined, unicodable6 left, greppable6 left, poohman joined, poohman left, poohman joined, domidumont joined, poohman left, reportable6 left 09:43 poohman joined
Geth mu: e356e71cc2 | (Jeff Goff)++ (committed using GitHub Web editor) | misc/perl6advent-2017/schedule
Expanding and expounding on my latest blog post

Tips and tricks to help with writing Perl 6 tests
09:43
09:43 zakharyas left, poohman left
DrForr 7th reserved as... we can all see now. 09:43
09:43 notbenh left, poohman joined, poohman left 09:44 poohman joined, poohman left, poohman joined 09:45 poohman left, poohman joined, poohman left
anop what is diff between Promise.anyof and Promise.allof 09:45
09:45 notbenh joined
anop what is diff between Promise.anyof() and Promise.allof() 09:45
09:46 poohman joined, wictory[m] joined, CIAvash[m] joined
moritz anop: .anyof is fulfilled when at least one of the promise is fulfilled 09:46
09:47 poohman left
DrForr Blocking on all of the Promises completing vs. just one of the list... 09:47
moritz and alloff waits for all of them to be finished (kept or broken)
DrForr ("blocking" is probably the wrong term tere.)
*there
09:47 poohman joined, poohman left
anop thanks moritz, that means .anyof for at least one promise should kepp 09:48
thanks moritz, that means .anyof for at least one promise should keep
thanks moritz, that means .anyof for at least one promise should be keep
09:48 poohman joined, poohman left, poohman joined, poohman left 09:49 poohman joined, poohman left, poohman joined, poohman left
Geth mu: 994989602f | ven++ (committed using GitHub Web editor) | misc/perl6advent-2017/schedule
add myself on the 20th
09:50
09:50 poohman joined, poohman left 09:51 poohman joined, poohman left 09:52 poohman joined, poohman left, poohman joined, poohman left 09:53 poohman joined, poohman left, poohman joined, poohman left 09:54 poohman joined, poohman left 09:55 khisanth_ joined, poohman joined, TEttinger left, poohman left 09:56 domidumont left, poohman joined, poohman left, poohman joined 09:57 poohman left, poohman joined, domidumont joined, poohman left, poohman joined, poohman left 09:58 poohman joined, poohman left, poohman joined, Khisanth left, poohman left 09:59 poohman joined, poohman left, poohman joined, poohman left 10:00 konsolebox left 10:01 konsolebox joined, Cabanossi left 10:03 poohman joined, Cabanossi joined, poohman left, poohman joined, poohman left 10:04 poohman joined, poohman left, poohman joined, nightfro` joined 10:05 poohman left, poohman joined, poohman left, eythian_ joined, eythian_ left, eythian_ joined 10:06 poohman joined, poohman left, poohman joined, poohman left 10:07 poohman joined, poohman left 10:08 konsolebox left, poohman joined, poohman left, dakkar left 10:09 tyil[m]1 joined, poohman joined, poohman left, rgrau left, Geth left, SourceBaby left, synopsebot left, dalek left, jhill left, nightfrog left, pi2 left, cpage left, xui_nya[m] left, tyil[m] left 10:10 nightfro` is now known as nightfrog, poohman joined, poohman left, dakkar joined 10:11 poohman joined, lizmat left, jhill joined, poohman left 10:12 albongo joined, evalable6 left, mtj_ joined 10:13 poohman joined, poohman left 10:14 xui_nya[m] joined, poohman joined, poohman left, eythian_ is now known as eythian, poohman joined, poohman left 10:15 konsolebox joined, rgrau joined, Geth joined, SourceBaby joined, synopsebot joined, dalek joined, tolkien.freenode.net sets mode: +vvvv Geth SourceBaby synopsebot dalek, pi2 joined, cpage joined, salva joined, poohman joined, poohman left 10:16 poohman joined 10:17 poohman left, poohman joined, poohman left, poohman joined 10:18 poohman left 10:20 poohman joined, poohman left 10:23 poohman joined, poohman left 10:24 konsolebox left 10:25 poohman joined, poohman left, poohman joined, poohman left 10:26 poohman joined, konsolebox joined, poohman left 10:27 lowbro left, poohman joined, poohman left, poohman joined 10:28 poohman left 10:29 poohman joined, poohman left 10:30 poohman joined, poohman left, wamba joined 10:31 margeas joined
jnthn wander: The should always be an unambiguous first thing to dispatch to. Re-dispatch works by calculating all of the possible targets, then excluding the first one, and then iterating through those. 10:37
wander aha, that's it. 10:38
thank you.
El_Che hey jnthn, coming to next fosdem? 10:39
DrForr I would ask the same of you :)
(if I haven't already.)
El_Che hehe 10:40
jnthn wander: I mean, conceptually nextsame works by iterating a candidate list calculated at the point of the original dispatchy
wander: But if we implemented it like that then performance would be pretty terrible 10:41
So we cheat and hope to not get caught. ;)
I think the refusal to dispatch to an unambiguous first candidate makes that safe.
Since we know that calculating the list upon first use of nextsame using the original arguments, then dropping the first result, means that the result we drop matches the one we'd originally hit 10:42
wander then we have cached it? 10:46
DrForr Now I just have to remember to write the bloody Advent post... 10:47
jnthn wander: We use a cache to resolve initial dispatches, yes (of course, the first time we call them the cache has no entry)
10:48 konsolebox left 10:49 konsolebox joined
El_Che DrForr: that's the price you pay for fame 10:51
DrForr H*ll, I'm starting to get people cold-emailing me about doing presentations... 10:53
It's almost like they think I know what I'm doing. 10:54
El_Che DrForr: really? Nice to hear that
10:54 konsolebox left
DrForr Yeah. CloudFoundry was the latest. 10:55
10:55 konsolebox joined
DrForr Grabbing lunch, back in a bit. 10:55
El_Che Talk about what mostly? P6? p5? origami?
10:58 Ven`` left
jnthn El_Che: Most likely won't make fosdem this time around 10:59
11:00 konsolebox left
El_Che with all the improvements of the last few years, that was a good PR opportunity. 11:00
jnthn: I understand, though
11:01 konsolebox joined
El_Che DrForr: are you coming? 11:03
DrForr FOSDEM? If I can, definitely. 11:04
El_Che I asked because you moved recently and stuff 11:05
DrForr I'd end up totally rethinking my machine learning stuff, which is probably a good thing.
11:05 xui_nya[m] left, donaldh left
DrForr I'm now in a vastly more convenient place to be able to get in and out of. 11:05
(checking on Brussels flights, come to think of it.) 11:06
11:06 dakkar left, wamba[m] left, M-Illandan left, cdg joined
DrForr I took flybe ... holy f*ck, $67 roundtrip Prague-Brussels Friday-Monday of FOSDEM. 11:08
11:09 donaldh joined 11:10 itaipu joined
jnthn El_Che: Well, there'll be *even more* improvements by the year after ;) 11:10
11:11 cdg left 11:12 dakkar joined 11:13 AlexDaniel` left 11:14 Matthew[m] left, Garland_g[m] left, wictory[m] left, mack[m] left, mienaikage left, tadzik left, unclechu left, tyil[m]1 left, CIAvash[m] left, ilmari[m] left 11:16 DickClarke joined 11:17 cdg joined, ribasushi left 11:18 xinming_ joined, konsolebox left
Geth mu: 94e497bc85 | (Zoffix Znet)++ (committed using GitHub Web editor) | misc/perl6advent-2017/schedule
Emptify schedule
11:18
11:18 konsolebox joined 11:20 ribasushi joined 11:21 xinming left, cdg left 11:26 konsolebox left
perlawhirl Can I clone/copy a sequence so I can iterate over it again. ie, not cache all the values, but copy the Seq and re-generate it 11:27
m: my $x = (1...3); .say for gather for ^3 { for $x[] { .take } }
camelia 1
This Seq has already been iterated, and its values consumed
(you might solve this by adding .cache on usages of the Seq, or
by assigning the Seq into an array)
in code at <tmp> line 1
in block <unit> at <tmp> line 1

2
3
11:28 konsolebox joined 11:34 scimon left
Geth doc: 82bec53180 | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/tables.pod6
update to current state of table handling
11:36
synopsebot Link: doc.perl6.org/language/tables
11:41 yoleaux joined, ChanServ sets mode: +v yoleaux, astj joined
SmokeMachine m: use Test; sub roundtrip ( $name ) {|sprintf( "%s", $name ) eq $name, "'$name' round trips.”}; ok roundtrip “a” 11:42
camelia 5===SORRY!5=== Error while compiling <tmp>
Unable to parse expression in double quotes; couldn't find final '"' (corresponding starter was at line 1)
at <tmp>:1
------> 3'$name' round trips.”}; ok roundtrip “a”7⏏5<EOL>
expe…
SmokeMachine m: use Test; sub roundtrip ( $name ) {|sprintf( “%s”, $name ) eq $name, “'$name' round trips.”}; ok roundtrip “a” 11:43
camelia ok 1 -
11:44 gregf_ left
SmokeMachine m: use Test; sub roundtrip ( $name ) {slip sprintf( “%s”, $name ) eq $name, “'$name' round trips.”}; ok roundtrip “a” 11:44
camelia ok 1 -
SmokeMachine m: use Test; sub roundtrip ( $name ) {sprintf( “%s”, $name ) eq $name, “'$name' round trips.”}; ok |roundtrip “a”
camelia ok 1 - 'a' round trips.
DrForr That code looks suspiciously familiar :)
SmokeMachine :)
DrForr I was wondering if slip() would work. 11:45
11:45 astj left
SmokeMachine DrForr: yes... it didn’t... :( 11:45
11:45 lowbro joined, lowbro left, lowbro joined
DrForr Yeah, slip() just returns the list in this context which still returns as a List. I suspect there's a way to jigger around with the signature to get the effect I wanted, but I was already at nearly midnight. 11:47
And it's really gratifying to see that someone's actually reading this stuff :)
SmokeMachine m: use Test; sub roundtrip ( $name ) {|[sprintf( “%s”, $name ) eq $name, “'$name' round trips.”]}; ok roundtrip “a”
camelia ok 1 -
SmokeMachine :(
DrForr 453 reads in the last ~3 days... 11:48
SmokeMachine :) was that was a very good post!
DrForr Thanks. 11:49
Practically all of the views from the US, which should come as no surprise. Australia and Canada being almost even counts as a surprise though. 11:53
Next one will probably be my blogspot poster I'm writing. 11:54
12:02 yoleaux left, yoleaux joined, ChanServ sets mode: +v yoleaux 12:06 wander left 12:07 sena_kun joined 12:08 scimon joined 12:12 silug left
SmokeMachine You had at least 1 read from Brazil... :) 12:13
DrForr It's only showing the top 10... :/ 12:15
12:22 cdg joined 12:25 konsolebox left, mienaikage joined 12:26 konsolebox joined 12:27 cdg left 12:34 konsolebox left 12:35 konsolebox joined 12:43 rgrau left 12:44 dustinm` left, cdg joined 12:47 konsolebox left 12:49 konsolebox joined, cdg left 12:50 zakharyas joined 12:53 dustinm` joined 12:59 wamba left 13:02 lizmat joined, go|dfish joined, Cabanossi left 13:03 Cabanossi joined 13:04 pmurias joined
pmurias hmm, how can I emulate a signed to unsigned integer conversion in js? 13:05
for signed to smaller signed I do something like: value << 24 >> 24 (to emulate a 8 bit integer) 13:06
13:08 jeromelanteri left 13:11 tyil[m] joined, mack[m] joined, tadzik joined, unclechu joined, CIAvash[m] joined, AlexDaniel` joined, wictory[m] joined, wamba[m] joined, M-Illandan joined, ilmari[m] joined, xui_nya[m] joined, Matthew[m] joined, Garland_g[m] joined
DrForr Uh, what's with the [m] markers? 13:11
13:12 konsolebox left 13:13 lizmat left 13:14 lizmat joined, konsolebox joined 13:17 lizmat left 13:19 konsolebox left 13:21 konsolebox joined 13:26 HoboWithAShotgun joined 13:28 bdmatatu joined
HoboWithAShotgun ok, so i got my hands on this R500 thinkpad with win10 on it and thought it'd be fun to benchmarck the windows rakudo vs a linux subsystem rakudo 13:28
easy fun for an evening right? wrong. the thing has been off for a year and it is still updating. for like 16 hours now. 13:29
El_Che HoboWithAShotgun: :)
I bet it didn't ask you when to update?
HoboWithAShotgun well it has to. the linux subsystem is new and requires the creators update 13:30
*has to update
13:30 cdg joined
HoboWithAShotgun it`s a neat little thing that thinkpad. i think i gonna put an ssd in it 13:32
the 60gig ones now get sold as doorstoppers so i think i gonna pick one up 13:33
13:35 cdg left, konsolebox left 13:37 wander joined
wander jnthn: I still find it weird that we don't apply textual ordering in this case ↓ 13:37
13:37 wamba joined
timotimo HoboWithAShotgun: updating a windows machine is much faster when you use wsusofflineupdater 13:37
wander m: multi sub f(Int \a, Any \b) { } ;multi sub f(Any \a, Int \b) { } f(42, 42); 13:38
camelia 5===SORRY!5=== Error while compiling <tmp>
Strange text after block (missing semicolon or comma?)
at <tmp>:1
------> 3\b) { } ;multi sub f(Any \a, Int \b) { }7⏏5 f(42, 42);
expecting any of:
infix
infix stoppe…
wander m: multi sub f(Int \a, Any \b) { } ;multi sub f(Any \a, Int \b) { }; f(42, 42);
camelia Ambiguous call to 'f'; these signatures all match:
:(Int \a, \b)
:(\a, Int \b)
in block <unit> at <tmp> line 1
jnthn wander: That only applies to tie-breakers
wander and we really use it when re-dispatch
jnthn This is a type match
wander m: multi sub f(Int \a, Int \b) { say '0'; nextsame }; multi sub f(Int \a, Any \b) {say '1'; nextsame } ;multi sub f(Any \a, Int \b) {say '2'; nextsame }; f(42, 42); 13:39
camelia 0
1
2
jnthn I guess in that case we build the DAG in such a way that it happens to toposort (in this case at least) such that the nextsame visits the things in source order. 13:40
HoboWithAShotgun timotimo: interesting 13:41
jnthn But nextsame is about iterating all possible candidates
wander as to multi dispatch, we choose *one* candidate, so there is no DAG built? 13:42
jnthn There's always a DAG built
That's how we decide the order to consider candidates in the first place
13:42 konsolebox joined
jnthn Just saying that it's pure luck that you get 012 and not 021 13:42
wander there should be, all that confuse me is the inconsistent
jnthn Oh, actually...maybe not
I guess it has to preserve that order for tie-breaking where clauses 13:43
Well, I guess we could change it so nextsame and friends also blow up with ambiguity errors 13:44
But I'm not sure if that's helpful :)
13:44 mson joined
jnthn But overall, I'm not sure one should expect two different things to be consistent 13:48
When you want to call one thing, there must be an unambiguous result. When you are iterating things, as next* does, then it's not an issue if there's multiple things that could be visited.
13:50 philomath joined 13:52 cdg joined
wander even if in which order we iterate thing is unclear? it looks like we iterate these candidates by the order same as how we choose the first one. and now it tells me for some candidates, the order is random 13:53
we define some tie-breaker and then define textual ordering as tie-breaker's tie-breaker 13:54
why not textual ordering itself be a tie-breaker 13:55
HoboWithAShotgun an explicit call and one via nextsame may be different things, but i'd expect this to blow 13:58
jnthn Because ambiguous dispatches on type are very rarely what anyone intended
[Coke] japhb++
HoboWithAShotgun that's the point, it's rarely intended and ambigious and it should at least produce a warning 13:59
jnthn Then write a patch to make nextcall explode in that case, and we can see what the impact is. 14:00
HoboWithAShotgun i'll keep my feet onto the userland, you guys do the kernel shit tyvm :) 14:01
14:01 itaipu left
wander yes, it's rare 14:02
HoboWithAShotgun i mean it's not that i wouldn't do it. i'm just not qualified.
jnthn An alternative is to try and detect all of these cases at compile time
14:03 itaipu joined 14:04 sena_kun left, sena_kun joined
wander anyway, always i like perl6. these stuff become problem at the situation where i recommend perl6 to friends, when we talk about some details. 14:06
DrForr You don't have to tell them about *all* the gory details :) 14:13
14:14 drigglearray joined
drigglearray Hello 14:14
I'm having trouble getting concatenation inside loops to work
DrForr Put your code up in a gist and we can take a look :) 14:15
drigglearray Okay, one sec 14:16
:D
14:16 philomath left, philomath joined
drigglearray pastebin.com/mwmz3Hfu 14:17
DrForr You're declaring $espace_r each time through the loop. Try declaring it before the loop. 14:19
Alternatively you could use 'state $espace_r = 0;' and it'll get initialized once, then used every subsequent time. 14:20
And you're initializing it to a number, and concatenating a string.
14:23 philomath_ joined
wander as our tie-breakers of PEGs, textual ordering always works. it looks like we believe when users deal with PEGs, they know what happens(textual ordering matters). 14:23
then for the very case of multi dispatch, we assume when users define 'ambiguous' candidates, that is a mistake.
and when they use tie-breaker explicitly, we trust them again, saying they know textual ordering matters. 14:24
DrForr Also, you want ~= in order to concatenate *to* something, just using '~' will return the concatenated string, not store it.
14:24 philomath left
drigglearray Thanks DrForr, will try all your advice and report back with the results 14:24
DrForr for reverse(100..2) -> $m { state $espace_r; $espace_r ~= $m } 14:25
14:25 silug joined 14:31 zakharyas left
drigglearray Many thanks DrForr, it looks like the main issue was solved by using ~= instead of ~ 14:31
DrForr No worries. 14:33
14:44 philomath_ left, koto joined 14:46 sena_kun left 14:48 mcmillhj joined
[Coke] writes a few paragraphs for the advent article so that when he forgets about it for 3 weeks, he's doesn't have to start on an empty page. 14:53
s/he's/he/
14:53 drigglearray left 14:54 HoboWithAShotgun left 14:56 wander left, philomath joined 14:59 koto left
dpk how is the regexp :ignoremark semantic actually defined? 14:59
accent normalization was removed from Unicode
(actually it was never formally in, it was withdrawn while still at draft stage)
15:00 comborico1611 joined
dpk uh, and by 'accent normalization' i of course mean diacritic folding 15:00
NFK?[CD] are of course still there
does it just NFD the input string and ignore characters in the mark category (Mn etc)? 15:01
15:01 Cabanossi left 15:02 pmurias left 15:03 Cabanossi joined
timotimo it only compares against the base character of each nfg grapheme 15:04
jnthn Hm, I think if NFDs the grapheme and looks at the first decomposed codepoint
15:04 philomath_ joined
dpk how do you define the base character then? 15:04
jnthn Well, only has to NFD the first codepoint, of course
15:05 philomath left, philomath_ left
timotimo i believe that's based on append and prepend properties? 15:05
dpk base characters are obvious for characters like é but less obvious for Hangul
15:05 philomath_ joined
dpk (for Hangul you probably want ignoremark to do nothing …) 15:05
15:07 philomath_ is now known as philomah, philomah left 15:14 Slayerk joined
dpk okay, it does seem to dtrt for Hangul at least, based on messing around with Rakudo a bit 15:15
15:15 philomath joined
Slayerk Is there any way to turn integers into strings so they give a valid .elems value? 15:16
timotimo what is a valid .elems value for an integer that's turned into a string? 15:17
dpk Slayerk: (sprintf "%d", 123)
(probably a quite heterodox way to do it …) 15:18
timotimo i'd literally just 123.Str, but what would you expect from .elems rather than just 1? 15:19
dpk oh, that's how you do it
Slayerk Well, I'd want it to give me the length of the integer
timotimo oh
that's not elems, that's chars
Slayerk For instance, the .elems value of 123 would be 3?
timotimo m: say 12345.chars
camelia 5
timotimo no need to convert to string first, because it's one of the "Cool" methods that automatically coerce for you
Slayerk Nice! 15:20
comborico1611 That's pretty cool, for sure.
15:20 geospeck left 15:21 geospeck joined 15:23 xinming_ left 15:24 xinming joined 15:25 geospeck left
Slayerk Hmm, is there any way to loop through an integer? 15:29
masak m: for 5179 { .say }
camelia 5179
masak Slayerk: ^
jnthn Do you mean the digits of it? :)
masak .oO( From the department of Creative Misunderstandings )
jnthn m: for 5179.comb { .say }
camelia 5
1
7
9
Slayerk ^^^
masak jnthn++ # being less literal-minded :P 15:30
comborico1611 Well, i learned something.
masak Slayerk: keep in mind, though, that decimal digits are a societal construct, and not at all intrinsic to the number itself
masak is such a big help right now
Slayerk o_O
masak anytime! :D 15:31
timotimo here's the purest "iterate through digits of a number" you can get:
m: for 42 xx 1 { .say }
camelia 42
timotimo haha
masak m: for 5179.base(2) { .say }
timotimo wrong way around
camelia 1010000111011
timotimo m: for 42 Rxx 1 { .say }
camelia 1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
masak ah, unary 15:32
timotimo the *other* purest "iterate through digits of a number" you can get is:
comborico1611 Lol
timotimo m: for 1 { .say }
camelia 1
timotimo ^- correct answer for every number you can come up with
oh, maybe not for 0 though 15:33
15:33 mcmillhj left
El_Che is 0 a number? 15:33
masak El_Che: yes, but kind of an ostracized one
timotimo did you know that the number of zeros inside ℕ is not zero, but one? 15:34
though sometimes ℕ is interpreted as "1 and up" not "0 and up"
in which case, substitute ℤ
masak clearly only luddites think 0 ∉ ℕ
El_Che whatever excuse is needed to type utf8 on irc
timotimo ℕ₊ doesn't have 0 though, right? 15:35
masak El_Che: see /topic :)
timotimo: no, but there it is by choice; that's different
timotimo right, i was just wondering if i got the name right 15:36
masak: it may be worth pointing out that in for 5179.base(2) { .say } you're only doing a single iteration that gives the whole string 15:37
so you'd .base.comb to get the individual digits
masak indeed; good point
if you're knowingly doing only a single iteration, you might also want to consider the more idiomatic `given` construct 15:38
15:39 pmurias joined 15:40 konsolebox left 15:41 Zoffix joined, Zoffix left 15:44 wamba left
perlpilot I probably would have used ... 15:44
m: .say with 5179.base(2);
camelia 1010000111011
perlpilot (reads a little better than given to me)
15:46 konsolebox joined, mcmillhj joined 15:49 wamba joined 15:50 rgrau joined 15:54 mson left 15:55 mcmillhj left 15:57 f0x left, domidumont left 16:00 gregf_ joined 16:09 mcmillhj joined 16:16 HoboWithAShotgun joined
HoboWithAShotgun builds rakudo under win10/ubuntu 16:17
finally ^^ 16:18
Slayerk Is there any simple way to remove a particular character from a string? 16:19
perlpilot Slayerk: yes? 16:20
Slayerk :P plz tel
HoboWithAShotgun m: "abc".subst("b","").say
camelia ac
Slayerk Thanks, I'm new to Perl6/programming 16:21
perlpilot Slayerk: Is that what you meant by "particular" character? Because another option I can think of is that you meant "remove the 5th character" from the string
Slayerk Yeah, I'm trying to remove all spaces from a number 16:22
HoboWithAShotgun aaand the build fails, it's trying to mkdir /opt/rakudo-star-2017.10
perlpilot Slayerk: oh, then you want to add an :g to HoboWithAShotgun's solution
m: "foo bar baz".subst(" ","", :g).say 16:23
camelia foobarbaz
HoboWithAShotgun retries under sudo
Slayerk wow, and I was coming up with this super complex solution to remove spaces involving 3x nested loops and stuff :P
perlpilot Slayerk: or, if you really mean "whitespace" rather than "spaces", maybe you want to use a regular expression
16:24 philomath_ joined 16:25 philomath_ left, philomath_ joined, philomath left
perlpilot m: "foo\t bar baz".subst(" ","", :g).say; # tabs are whitespace but not spaces, so ... 16:25
camelia foo barbaz
perlpilot m: "foo\t bar baz".subst(/\s+/,"", :g).say; # get rid of all whitespace 16:26
camelia foobarbaz
perlpilot Slayerk: also ... why do your "numbers" have spaces in them? 16:27
16:28 troys joined
Slayerk Ah, I used .comb so I can for loop through them 16:28
But now I just want to remove the spaces
16:28 Phi_mb joined
HoboWithAShotgun progress. but now i get this: pasted.co/b5791eaa 16:29
any idea what could cause this?
16:29 wander joined
timotimo HoboWithAShotgun: yup! 16:30
huggable: execstack
huggable timotimo, nothing found
timotimo huggable: windows
huggable timotimo, nothing found
timotimo huggable: windows 10
huggable timotimo, nothing found
timotimo huggable: stack
huggable timotimo, nothing found
timotimo ...
github.com/MoarVM/MoarVM/issues/470 - this can help, but it'll make nativecall unavailable 16:31
HoboWithAShotgun huggable: love
huggable HoboWithAShotgun, nothing found
16:31 philomath_ left 16:32 Phi_mb left, Phi_mb joined
timotimo actually, maybe it's not a problem after all? 16:32
El_Che HoboWithAShotgun: github.com/nxadm/rakudo-pkg/blob/m..._windows10 16:33
Geth doc: 34c332873d | (Tom Browder)++ (committed using GitHub Web editor) | doc/Programs/README.md
update after pod table fixes
Slayerk perlpilot: I've noticed that the .subst command doesn't save the new values, and I can't declare a new variable that equals a something.subst(). Any ideas? 16:37
perlpilot er, what?
HoboWithAShotgun ty El_Che, i gonna try that right after dinner, there's fried fish'n chips waiting
perlpilot m: my $foo = "foo bar baz"; my $bar = $foo.subst(/\s+/, '', :g); say $bar; 16:38
camelia foobarbaz
perlpilot m: my $foo = "foo bar baz"; $foo ~~ s:g/\s+//; say $foo; # some syntactic sugar 16:39
camelia foobarbaz
perlpilot Slayerk: do those 2 bits of code help you?
Slayerk perlpilot: Thanks, I think I should be good to go 16:40
perlpilot m: my $foo = "foo bar baz"; $foo.=subst(/\s+/, '', :g); say $foo; # slightly less sugary
camelia foobarbaz
16:45 khw joined, Phi_mb left 16:46 Zoffix joined 16:48 wamba left
Zoffix Is there a way to… dynamically execute… a coercer. A user gives me a coercer and ideally, I want to attach it to a parameter on a block, but things I've tried failed. I know I can just see what the coercer coercers from and to and call the .$to() method myself, but that's a bit fragile, since the way our coercers work might change. 16:49
16:49 konsolebox left
Zoffix m: role Foo[::T] { method z { -> T $x { $x } } }; Foo[Int()].new.z.(42.2).say 16:49
camelia Type check failed in binding to parameter '$x'; expected Int(Any) but got Rat (42.2)
in block at <tmp> line 1
in block <unit> at <tmp> line 1
Zoffix ^ like here, I'd expect that to coercer Rat to Int 42
jnthn No. The coercer syntax came fairly late on, and replaced the as trait on parameters. 16:53
Zoffix OK. Thanks.
jnthn The only things it can handle are, pretty much, the exact same thing that the as trait's internals could 16:54
And since it was a trait, that meant we knew it at compile time
So in the case you're looking at there, we can't know at compile time to compile the signature differently to handle the coercion
16:54 konsolebox joined, aindilis left
jnthn And so it doesn't happen 16:55
timotimo i could imagine the CoercerHOW to grow a method that does the coercion for you as part of our API
just don't expect the method to be called when a coercion happens as part of a signature (if you override or wrap it) 16:56
Zoffix m: my $c := Int(Cool); sub coerce { $^v ~~ $c.^constraint_type or die; $^v."{$c.^target_type.^name}"() }; say coerce "4e3" 16:58
camelia 4000
Zoffix I'll just do this, for now.
17:02 astj joined
Slayerk perlpilot: After some experimentation, I've noticed a problem. After I remove the whitespace, I can't loop through the number anymore 17:04
my $a = "41 42";my $b = $a.subst(/\s+/, '', :g);loop (my $i = 0; $i < $b.chars; $i++){ say $b[$i];}
m: my $a = "41 42";my $b = $a.subst(/\s+/, '', :g);loop (my $i = 0; $i < $b.chars; $i++){ say $b[$i];}
camelia 4142
Index out of range. Is: 1, should be in 0..0
in block <unit> at <tmp> line 1
Zoffix m: my $a = "41 42";my $b = $a.subst(/\s+/, '', :g);loop (my $i = 0; $i < $b.chars; $i++){ say $b.comb[$i];}
camelia 4
1
4
2
Zoffix m: my $a = "41 42";my $b = $a.subst(/\s+/, '', :g); for $a.comb { .say } 17:05
camelia 4
1

4
2
Zoffix m: my $a = "41 42"; $a.comb(/\S/) { .say }
camelia 5===SORRY!5=== Error while compiling <tmp>
Unexpected block in infix position (missing statement control word before the expression?)
at <tmp>:1
------> 3my $a = "41 42"; $a.comb(/\S/)7⏏5 { .say }
expecting any of:
infi…
Zoffix m: my $a = "41 42"; for $a.comb(/\S/) { .say }
camelia 4
1
4
2
Zoffix Slayerk: your code doesn't work because you're trying to index into a string. It's a 1-element list (just the string itself), so only index 0 is valid. You need to break the string up into characters if you want to access them with `[]`; you could also use .substr 17:06
17:06 astj left
Zoffix m: my $a = "41 42";my $b = $a.subst(/\s+/, '', :g);loop (my $i = 0; $i < $b.chars; $i++){ say $b.substr: $i, 1;} 17:06
camelia 4
1
4
2
Zoffix m: my $a = "41 42";my $b = $a.subst(/\s+/, '', :g); for ^$b.chars { say $b.substr: $_, 1 } # the C-style loop is rarely needed in Perl 6 17:07
camelia 4
1
4
2
Zoffix m: .say for comb /\S/, "41 42" 17:08
camelia 4
1
4
2
Zoffix Thanks for the help. \o 17:09
17:09 Zoffix left
Slayerk Thanks Zoffix 17:09
TimToady m: say m: "foo\t bar baz".words.join 17:12
camelia 5===SORRY!5=== Error while compiling <tmp>
Colons may not be used to delimit quoting constructs
at <tmp>:1
------> 3say m:7⏏5 "foo\t bar baz".words.join
expecting any of:
colon pair (restricted)
TimToady m: say "foo\t bar baz".words.join
camelia foobarbaz
perlpilot Slayerk: why are you iterating over each character in the number? 17:17
Slayerk Well, I want to get the palindrome of the number 17:19
So the idea is to take individual numbers from a number and reassemble the number backwards
Then compare to the original number
jnthn m: say "1234".flip
camelia 4321
Slayerk ...
Really?
...
perlpilot Slayerk: yep.
Slayerk omg 17:20
I've just spent 5 hours on this
jnthn m: say 696.flip eq 696
camelia True
perlpilot Slayerk: you're doing *way* too much work :)
jnthn m: say 669.flip eq 669
camelia False
Slayerk ... plz no more
Xliff m: my $a = 1234; ($a ~ $a.flip).say 17:21
camelia 12344321
Xliff Sorry. Couldn't resist. /o\ 17:22
17:26 eroux joined 17:28 scimon left 17:32 mson joined 17:35 abraxxa left 17:40 setty1 joined 17:45 dakkar left
Slayerk Well, using .flip I managed to do in 20 minutes what I couldn't get working in 5 hours. RIP me. Thanks for the help guys. 17:46
Night.
17:47 Cabanossi left, Slayerk left 17:48 Cabanossi joined 17:58 mcmillhj left 18:11 domidumont joined, itaipu left 18:17 Cabanossi left 18:18 Cabanossi joined, llfourn joined 18:24 domidumont left 18:25 mcmillhj joined 18:29 darutoko left 18:30 mcmillhj left
AlexDaniel squashable6: next 18:31
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in ≈15 hours (2017-12-02 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
18:33 mcmillhj joined 18:38 mcmillhj left 18:40 wamba joined 18:43 ExtraCrispy joined 18:51 Ven joined 18:52 Ven is now known as Guest33619 18:56 mcmillhj joined
masak perlpilot: I have no idea why you think `with` reads better than `given` ;) 18:59
19:00 Cabanossi left
masak though I realize this might be my bias speaking. I still mostly fail to see the point of `with` 19:00
and I think it's extra confusing to use it in situations unrelated to definedness 19:01
AlexDaniel it's really useful 19:02
LEAVE .unlink with $tempfile;
and stuff like that 19:03
19:03 Cabanossi joined
AlexDaniel and of course, `without` :) 19:03
19:05 eroux left
perlpilot masak: perhaps. 19:05
19:06 cdg left
timotimo leave with your stuff 19:06
masak AlexDaniel: I hear you. maybe I'm just stubborn. ;)
19:07 wamba left, wamba joined
El_Che moritz: today I freed some time to read your book. I like it so far 19:08
AlexDaniel masak: but how else would you write that stuff? LEAVE $tempfile.unlink if defined $tempfile; ?
perlpilot stubbornness is an admirable trait when used in moderation. masak: Are you moderately stubborn? ;)
El_Che moritz: you really show off the languages without boasting
AlexDaniel
.oO( trait? sub foo() is stubborn { } )
masak perlpilot: I don't know, to be honest 19:10
AlexDaniel: maybe LEAVE .unlink if .defined given $tempfile 19:11
AlexDaniel masak: O_O
perlpilot looks like temporary insanity from here
(at least I hope it's temporary) 19:12
El_Che moritz: I was suspicious about the existence of a Perl 6 cabal and TimToady's nice words confirmed it :P
masak AlexDaniel, perlpilot: I hear you :) I will try to like `with`
19:13 ExtraCrispy left
perlpilot oddly, for me, it's `without` that bothers me. I'm all for symmetry when it makes sense, but I'm not sure `without` makes enough sense. 19:13
(maybe that's just my myopia or something though) 19:14
masak I agree about `without` being weird and odd -- it's just for me, the problem starts earlier :)
AlexDaniel without makes sense too 19:15
return ‘blah’ without $foo;
masak there's nothing conditional about either `with` or `without` 19:16
perlpilot yeah, they should be called "ifdef" and "ifndef" ;>
masak .oO( .beat with $dead-horse )
perlpilot: github.com/masak/007/issues/236 :) 19:17
moritz El_Che: thanks! :-)
AlexDaniel and it reads so nicely: github.com/perl6/whateverable/sear...=%E2%9C%93 19:18
El_Che moritz: the jury is out yet :). I am at the datetime chapter
19:18 benchable6 left
AlexDaniel (although most of the results are from the GPL header :D) 19:18
19:18 benchable6 joined
Geth mu: 13f470c7a7 | (Curt Tilmes)++ (committed using GitHub Web editor) | misc/perl6advent-2017/schedule
Sign up for day 5
19:19
HoboWithAShotgun ok, got it working, now make install is installing a bunch of modules 19:21
Xliff masak: with || without $you
Xliff flees
Of course, it works properly in plain english: with or without $you
Xliff goes back to grooving to U2. 19:22
masak Xliff: yes, but in no language does "with" mean "if defined, but topicalize on the thing whose definedness we're checking"
feel free to check me on this ;) 19:23
perlpilot AlexDaniel: in `return ‘blah’ without $foo;`, without feels more exclusionary than "if not defined"
Xliff masak: LOL
perlpilot AlexDaniel: as in, return $burger without $fries;
Xliff I wasn't even being serious. Anytime I can work in a U2 lyric into a coding conversation is an opportunity I am not missing! :>
masak I mean, it's admirable we're Finally Solved the semipredicate problem and all (*snrk*)
19:24 Actualeyes left
Xliff s/we're/we've/ 19:24
masak indeed, thanks
Xliff just realized that "without $you" is also a John B lyric. O_O 19:25
Good song, too.
www.youtube.com/watch?v=1DRcuAr_bR...talRecords 19:26
comborico1611 Man, I feel for Slayerk. He should have read a perl6 intro book. But at least he got good practice in.
Xliff comborico1611: We all learn more from our mistakes than our successes.
I speak from experience. :P
comborico1611 Wisdom.
moritz didn't even mention .flip in p6f 19:27
perlpilot no, wisdom is learning from *other* people's mistakes ;)
Xliff perlpilot: Actually Wisdom is learning from EVERYONE's mistakes. I think you are thinking of Good Wisdom 19:28
comborico1611 Haha. But sometimes, or often, people don't even learn from their mistakes.
Xliff Although the "Good" modifier might not be the right one.
19:28 cpage_ left
comborico1611 Experience is a hard teacher because she gives the test first, the lesson afterwards 19:28
perlpilot moritz: still, it would be nice to have a reference tome that mentions all the things. I'm not sure the docs quite do it for some people. (i.e. if you were looking for how to "flip a string", would you actually search for "reverse a string", and what would the docs tell you that would help?) 19:29
comborico1611 Marissa Tomé?
I hate the docs. 19:30
moritz docs.perl6.org/routine/reverse "Note that reverse always refers to reversing elements of a list; to reverse the characters in a string, use flip."
perlpilot: ^^
comborico1611 I mean, I'm glad they exist. But I find it very confusing. But I'm very inexperienced as a programmer, and as a P6er.
19:31 nadim joined
Xliff comborico1611: But you looove Marissa Tomé! 19:31
(no hate... I'm in the same boat)
perlpilot comborico1611: yeah, that's what I think tends to happen for some (many?) people
comborico1611 Haha.
moritz perlpilot: I considered applying to a grant to write some more introductory for the docs, so that the docs become a good "integrated" reference+learning source 19:32
perlpilot comborico1611: also, it would be sweet if we could get a "Learn Perl 6 from Marissa Tomé" video ;)
Xliff perlpilot++
comborico1611 I was just making fun of perlpilot's reference to tome.
Xliff perlpilot: You should get on that. :)
perlpilot moritz++ that would be awesome (if you have the time)
comborico1611 Haha!
moritz perlpilot: haha, that's the catch
there are two other projects I want to do first :/ 19:33
comborico1611 She seems like a nice woman. Someone can actually ask her she might do something.
If someone can*
19:35 releasable6 left, statisfiable6 left, greppable6 joined, ChanServ sets mode: +v greppable6, releasable6 joined, ChanServ sets mode: +v releasable6, statisfiable6 joined, ChanServ sets mode: +v statisfiable6, reportable6 joined 19:36 unicodable6 joined, ChanServ sets mode: +v unicodable6, bisectable6 left, committable6 left, bisectable6 joined, ChanServ sets mode: +v bisectable6, committable6 joined 19:37 statisfiable6 left, benchable6 left, quotable6 left, greppable6 left 19:38 DickClarke left, st_elmo joined 19:44 troys is now known as troys_, mson left
HoboWithAShotgun i added a line about the execstack issue to the website code: pasted.co/822dcc3e 19:46
any objections before i save this?
(the second list item is new)
19:47 epony left, Cabanossi left, epony joined 19:48 Cabanossi joined 19:50 reportable6 left, rgrau left 19:55 geospeck joined 19:59 TEttinger joined
HoboWithAShotgun that doesn't seem to be the case 20:00
20:01 Guest33619 is now known as Ven`` 20:02 troys_ is now known as troys 20:03 mcmillhj left, cdg joined
Geth perl6.org: 80178dfc64 | holli-holzer++ (committed using GitHub Web editor) | source/downloads/index.html
Mentioned the Win10/WSL execstack issue and how to get around it
20:03
buggable New CPAN upload: PDF-Font-0.1.0.tar.gz by WARRINGD cpan.metacpan.org/authors/id/W/WA/...1.0.tar.gz
20:05 lostinfog joined 20:07 cdg left 20:10 lostinfog left 20:12 Ven`` left 20:16 espadrine joined 20:21 Ven`` joined, mcmillhj joined 20:32 s0me0ne-unkn0wn joined 20:33 Ven`` left 20:35 as_ joined, s0me0n3-unkn0wn left 20:37 pentashift joined 20:39 astronavt joined 20:42 as_ left, HoboWithAShotgun left 20:44 astronavt left 20:52 geospeck left, geospeck joined
AlexDaniel heh! Finally, I looked at my Pascal's triangle solution for a second while I was in the middle of doing something else, and all of the sudden I realized how verbose it is 20:54
22 characters now!
(context: code-golf.io/ ) 20:55
20:57 geospeck left 20:58 bdmatatu left
geekosaur (apl lives!) 21:00
comborico1611 How did you learn networking? By battling one of the senior network engineers. He hurt his back lifting a 1000' box of Cat5e and I saw my opportunity to ascend. He was in pain, and I could smell his fear. I threw down an AUI cable at his feet, the customary challenge (of course), and the Rite of Ascension began. Our Director presented us with the ceremonial 19" rack shelves, honed to a razor's edge on one side. We battled, it wa 21:01
geekosaur channel? (or venue; this sounds vaguely SDM) 21:03
comborico1611 Stackoverflow
21:06 pecastro left 21:08 cdg joined 21:09 mcmillhj left 21:12 grumble joined 21:13 cdg_ joined, pecastro joined 21:16 cdg left, ivans joined 21:17 troys is now known as troys_ 21:18 Ven`` joined 21:19 wander left 21:20 someuser left 21:21 Ven`` left 21:22 mniip left 21:23 ryn1x_ joined 21:25 mniip joined, wamba left 21:26 Ven`` joined
ryn1x_ Any one know why I get the warning "Regex object coerced to string (please use .gist or .perl to do that)" when trying "if / \w+'_'\d+$ / ~~ $subdir {$subdirname = ~$/}"? It only happens in a source file and not in the REPL. 21:26
jnthn The regex belongs on the right of the ~~ 21:27
21:27 kitsunenokenja joined
ryn1x_ Oh shoot. Thanks jnthn. 21:28
AlexDaniel squashable6: next 21:30
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in ≈12 hours (2017-12-02 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
21:32 kerframil joined 21:34 ivans left 21:35 mcmillhj joined 21:36 pentashift left 21:40 ivans joined, astronavt joined, mcmillhj left 21:43 nadim left 21:45 astronavt left 21:46 mcmillhj joined 21:52 mcmillhj left
Geth doc: 5396cdf379 | (Jan-Olof Hendig)++ | doc/Type/Kernel.pod6
Fixed broken link and added some headers
21:52
synopsebot Link: doc.perl6.org/type/Kernel
21:59 mcmillhj joined 22:01 Cabanossi left, setty1 left 22:03 Cabanossi joined 22:04 mcmillhj left 22:18 mcmillhj joined 22:20 kerframil left
Geth doc: 239abcaccb | (Jan-Olof Hendig)++ | doc/Type/Kernel.pod6
Fixed copy paste error
22:20
synopsebot Link: doc.perl6.org/type/Kernel
22:26 ryn1x_ left 22:27 mcmillhj left 22:28 mcmillhj joined 22:41 astronavt joined 22:45 pilne joined 22:46 astronavt left 22:47 nadim joined 22:53 mcmillhj left
buggable New CPAN upload: Inline-Go-0.0.3.tar.gz by AZAWAWI cpan.metacpan.org/authors/id/A/AZ/...0.3.tar.gz 22:53
22:53 pecastro left
Geth doc: 8c929d9a1d | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/regexes.pod6
escape visual col sep chars used as cell data

Correct the table by escaping visual column separator characters used as cell data.
22:57
synopsebot Link: doc.perl6.org/language/regexes
22:57 pilne left, Slayerk joined
Slayerk Hello 22:58
masak \o
22:58 pilne joined
Slayerk If I do if $i %% $n[^20].all, does that check if the number is divisible by the all of the first 20 numbers in the sequence? 22:59
23:01 mcmillhj joined 23:02 kerframil joined
AlexDaniel Slayerk: yes, that's how it should work 23:03
you can also try it to see if that's the case :) 23:04
m: say 20 %% <1 2 5 10 15>[^4].all
camelia all(True, True, True, True)
AlexDaniel m: say 20 %% <1 2 5 10 15>[^5].all
camelia all(True, True, True, True, False)
AlexDaniel m: say so 20 %% <1 2 5 10 15>[^4].all
camelia True
AlexDaniel m: say so 20 %% <1 2 5 10 15>[^5].all
camelia False
23:09 mcmillhj left
Slayerk Thanks Alex 23:09
I'll carry out some testing and report back 23:10
23:11 pecastro joined 23:15 pmurias left 23:16 Zoffix joined
Zoffix m: sub runner (&foo) { my $*bar; foo }; runner { $*bar = 42 } 23:17
camelia ( no output )
Zoffix hm... my slightly more complex setup gives Dynamic variable $*PROXEE not found for that
Slayerk "slightly" more complex :P 23:19
Zoffix m: subset Palindrome of Cool where { $_ eq .flip }; say $_ ~~ Palindrome for 1331, "()()", "())(", 「\o//o\」 23:21
camelia True
False
True
True
Zoffix Slayerk: ^ another take on your palindrome thing. You can make a subset and typecheck against it :)
m: gist.github.com/zoffixznet/ba48a57...9039b164a7 23:23
camelia No contextual found with name '$*PROXEE'
in block <unit> at <tmp> line 36
23:24 Morfent joined
Zoffix m: sub runner (&foo) { my &meow := { $*bar }; my $*bar; foo; meow }; say runner { $*bar := 42 } 23:24
camelia 42
Zoffix stares 23:25
23:25 eliasr joined
jnthn It's not in dynamic scope there, is it? 23:25
my $*PROXEE is declared inside of new 23:26
new returns the Proxy
STORE is called on the assignment
Zoffix Ahh. Thanks doh
23:28 dayangkun joined 23:31 pentashift joined 23:32 rindolf left
Zoffix m: gist.github.com/zoffixznet/8255609...ab8770860c 23:35
camelia Value is Proxy.new
Zoffix would've thought the proxy would be read
23:35 Ven`` left
Zoffix fetched the value from I mean 23:35
Oh, I messed up 23:36
m: gist.github.com/zoffixznet/8255609...ab8770860c 23:37
camelia Value is $(1, 2, 3)
Zoffix hehe. That's not the way to get rid of cont on assignment I guess :P
I don't get where it gets conted tho 23:38
Ah, the proxy is the cont /o\ 23:40
My brilliant idea is falling apart!
23:42 astronavt joined 23:46 troys_ is now known as troys 23:47 astronavt left, Ven`` joined 23:54 Actualeyes joined 23:55 reportable6 joined, ChanServ sets mode: +v reportable6 23:56 reportable6 left, reportable6 joined
Geth doc: tbrowder++ created pull request #1694:
use non-breaking spaces
23:59