Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2016-11-17

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:07 pierre_ joined #perl6
00:20 rpburkholder joined #perl6
00:31 timotimo bazzaar: i see your pull request came through to us
00:32 timotimo we should be able to upload renders from travis for pull requests so you could view the final render on doc.perl6.org somewhere
00:32 timotimo like doc-1012.perl6.org maybe?
00:33 bazzaar timotimo: oh, that's great ... been flying by the seat of my pants :), just now staring at the merge button, thinking am I supposed to push it?
00:33 timotimo well, if you're confident the pull request is good, sure
00:34 bazzaar timotimo: but am I supposed to wait for others to approve before doing so?
00:36 seatek is there any difference invoking perl6 as perl6 vs perl6-m ?
00:38 viki seatek: cat them both and see :) They're just wrapper scripts
00:38 timotimo usually you'd wait for others, yeah
00:38 seatek viki: i did notice they were the same size ;)
00:38 timotimo i see a colon with a space in front of it
00:38 timotimo was that in error?
00:39 bazzaar timotimo: ok, I'll wait
00:39 viki bazzaar: if it's just a small change you're confident with you can just commit directly. It's only for changes with large impact that folks tend to open a PR and wait for feedback.
00:40 geekosaur seatek, you could (although right now I would not) specify the default to be jvm instead of moar
00:40 geekosaur if you want to enforce moarvm, use the -m one. if you don't care which then omit the suffix
00:40 timotimo generally we operate on "it's easier to ask for forgiveness than for permission"
00:41 viki Yeah, the revert feature works :P
00:42 seatek geekosaur: gotcha! thanks :)
00:44 bazzaar viki: Thanks, I will bear that in mind :) this one is a rewrite of zip and roundrobin, and because it's my first PR maybe I should wait.
01:00 user10 joined #perl6
01:03 Actualeyes joined #perl6
01:05 BenGoldberg joined #perl6
01:06 sufrostico joined #perl6
01:11 aries_liuxueyang joined #perl6
01:16 labster joined #perl6
01:19 kyclark joined #perl6
01:30 nadim_ joined #perl6
01:32 sufrostico joined #perl6
01:58 flaviusb joined #perl6
02:00 Xliff \o/
02:01 Xliff Made it to the next stage of this freaking silly SSO process.
02:09 * Xliff does a silly dance.
02:27 kalkin- joined #perl6
02:27 kalkin- hi
02:28 kalkin- How can i list all the variables in the current scope? (I'm trying out in REPL)
02:28 kalkin- So when i declare my $foo = "Bar"; $::{'$foo'} should be the same var, according to docs
02:29 kalkin- so i should be able to do $::.kv
02:29 kalkin- to list the contents
02:29 kalkin- but REPL says $ is not declared
02:29 kalkin- https://docs.perl6.org/lang​uage/packages#Direct_lookup
02:33 MasterDuke m: my $foo = "Bar"; my \Bar = "baz"; say ::(q|$foo|); say ::($foo);
02:33 camelia rakudo-moar 58a482: OUTPUT«Bar␤baz␤»
02:35 kalkin-_ joined #perl6
02:36 MasterDuke well, it should be my $foo = "Bar"; $::{'foo'}
02:36 MasterDuke according to the doc
02:36 MasterDuke m: my $foo = "Bar"; say $::{'foo'}
02:36 camelia rakudo-moar 58a482: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$' is not declared␤at <tmp>:1␤------> 3my $foo = "Bar"; say 7⏏5$::{'foo'}␤»
02:36 MasterDuke bisectable6: my $foo = "Bar"; say $::{'foo'}
02:36 bisectable6 MasterDuke, On both starting points (old=2015.12 new=58a4826) the exit code is 1 and the output is identical as well
02:36 bisectable6 MasterDuke, Output on both points: ===SORRY!=== Error while compiling /tmp/TmRkwhWsrz␤Variable '$' is not declared␤at /tmp/TmRkwhWsrz:1␤------> my $foo = "Bar"; say <HERE>$::{'foo'}
02:38 MasterDuke m: my $foo = "Bar"; say ::{'$foo'}
02:38 camelia rakudo-moar 58a482: OUTPUT«Bar␤»
02:38 kalkin-_ thanks!
02:38 kalkin-_ but why does ::.kv not list the var?
02:39 MasterDuke but it looks like something is wrong about $::{'foo'}, either the docs or it's a bug
02:40 MasterDuke m: my $foo = "Bar"; .say for ::.kv
02:40 camelia rakudo-moar 58a482: OUTPUT«$=pod␤[]␤$foo␤Bar␤!UNIT_MARKER␤(!UNI​T_MARKER)␤EXPORT␤(EXPORT)␤$_␤(Any)␤$!␤Nil␤:​:?PACKAGE␤(GLOBAL)␤GLOBALish␤(GLOBAL)␤$¢␤Ni​l␤$=finish␤(Mu)␤$/␤Nil␤$?PACKAGE␤(GLOBAL)␤»
02:41 samcv trying to work on Perl6FE highlighting for atom right now, get it to recognize fancy quotes and more styles of #`{{ multiline comments
02:46 MasterDuke m: my $foo = "Bar"; for ::.kv -> $k, $v { say "$k => $v.perl()" }
02:46 camelia rakudo-moar 58a482: OUTPUT«$=pod => $[]␤$foo => "Bar"␤!UNIT_MARKER => !UNIT_MARKER␤EXPORT => EXPORT␤$_ => Any␤$! => Nil␤::?PACKAGE => GLOBAL␤GLOBALish => GLOBAL␤$¢ => Nil␤$=finish => Mu␤$/ => Nil␤$?PACKAGE => GLOBAL␤»
02:46 MasterDuke kalkin-_: ^^^ see it there?
02:46 kalkin-_ This doesn't work in repl
02:46 MasterDuke there are known problems with the repl
02:46 kalkin-_ ahh i see
02:46 kalkin-_ in repl is $foo missing
02:46 kalkin-_ it's only in it if i declare it on same line
02:47 ilbot3 joined #perl6
02: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!
02:51 richi235 joined #perl6
02:54 dj_goku anyone notice colabti.org searching is slow/broken/never returns?
02:57 kyclark joined #perl6
03:30 kyclark joined #perl6
03:39 noganex_ joined #perl6
03:48 kyclark joined #perl6
03:50 pierre_ joined #perl6
03:55 cibs joined #perl6
04:00 troys joined #perl6
04:02 Xliff m: my $a = do for ^4 { $_ * 2 }; say $al
04:02 camelia rakudo-moar 58a482: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$al' is not declared␤at <tmp>:1␤------> 3my $a = do for ^4 { $_ * 2 }; say 7⏏5$al␤»
04:02 Xliff m: my $a = do for ^4 { $_ * 2 }; say $a;
04:02 camelia rakudo-moar 58a482: OUTPUT«(0 2 4 6)␤»
04:20 aborazmeh joined #perl6
04:20 aborazmeh joined #perl6
04:21 Xliff m: my @a = ^6; for @a:kv -> $k, $v { say "$k $v" }
04:21 camelia rakudo-moar 58a482: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '@a:kv' is not declared␤at <tmp>:1␤------> 3my @a = ^6; for 7⏏5@a:kv -> $k, $v { say "$k $v" }␤»
04:21 gfldex seatek: zef problem already solved: https://github.com/ugexe/zef/commit/4a​97451d78407b6b09ab4355f8059f7e4039859c
04:21 Xliff m: my @a = ^6; for @a.hash:kv -> $k, $v { say "$k $v" }
04:21 camelia rakudo-moar 58a482: OUTPUT«4    5 0     1␤Too few positionals passed; expected 2 arguments but got 1␤  in block <unit> at <tmp> line 1␤␤»
04:21 Xliff Well crap. I thought you could get array index and value via :kv adverb from arrays.
04:22 Xliff m: my @a = ^6; for @a.kv -> $k, $v { say "$k $v" }
04:22 camelia rakudo-moar 58a482: OUTPUT«0 0␤1 1␤2 2␤3 3␤4 4␤5 5␤»
04:22 Xliff Oh. Not adverb. LOL!
04:24 kyclark joined #perl6
04:37 ggoebel joined #perl6
04:41 dj_goku what are valid block delimiters?
04:41 dj_goku a code block that is.
04:47 seatek gfldex: wow that was fast! i'm going to have to try zef eventually
04:49 rpburkholder joined #perl6
05:14 seatek core! hmm. double free or corruption? double free please!
05:21 Cabanossi joined #perl6
05:23 seatek anyone know of any known memory eating bug issues related to Callables?
05:26 seatek In Crust... a Callable is used and passed up to the connected server from the application.
05:26 seatek Multiple repeated calls can create some extra memory use at first, but it levels off
05:28 seatek If you use the Crust::Builder to create "middleware" -- it temporarily assigns this Callable to a new local Callable, passing to to some constructed classes, then returning. I'm wondering if those locally created Callables might linger
05:33 Actualeyes joined #perl6
05:37 seatek if you pass an Callable to a method, and return that callable time and again, memory use goes up (in Crust here).
05:38 seatek if you pass in a Callable to a method, then assign that Callable to a local $_app var, then return that local $_app var instead of the Callable passed in, memory usage noticably increases
05:39 seatek (and the rate at which it climbs)
05:39 gfldex seatek: are you trying to tell us that you want to golf that? :->
05:40 seatek i don't know what that means. i just want to stomp my foot and make everything better :)
05:40 seatek does that mean I should keep trying to isolate down what the cause is?
05:41 seatek or that i'm trying to get someone else to fix it?
05:41 seatek golfing it... putting it down further
05:41 gfldex a code golf is the shortest prossible program that can trigger a bug
05:41 seatek i need a memory profiling tool :)
05:41 seatek ah ok
05:41 seatek ugh
05:41 seatek it's hard extracting that out from something like Crust
05:42 seatek I don't even like Callables
05:43 seatek they're nothing but trouble anyway
05:43 gfldex You could file a ticket on your own module and come back to it later. Very well possible that the bug is already known.
05:44 seatek i'll go a little further into the chaos. or i'll forget what i did and didn't do
05:46 seatek i should file the bug in Crust::Builder cuz that's where it comes up, even using none of the middleware modules (like mine)
05:47 seatek but i'm betting it's a Callable in general memory issue relating to scopes of some kind... freeing stuff
05:47 seatek $20
05:57 seatek what the heck is the MONKEY-SEE-NO-EVAL - not in modules listing, not in --doc
05:58 seatek ah on the site
05:58 gfldex https://docs.perl6.org/language/pragmas
06:11 dj_goku anyone build the perl6/doc html on a mac and is on sierra?
06:12 gfldex dj_goku: doubt it will work. There are still a few things that are case sensitive
06:13 dj_goku gfldex: haha ok, well I guess I am done for the night.
06:13 dj_goku I was going to spin up a ubuntu system and try it thee.
06:13 dj_goku s/thee/there/
06:45 Xliff m: my $a = do for ((1, 'a'), (2, 'b'), (3, 'c')) -> $c { $_.flat }; dd $a;
06:45 camelia rakudo-moar 58a482: OUTPUT«List $a = $((Any,).Seq, (Any,).Seq, (Any,).Seq)␤»
06:45 Xliff m: my $a = do for ((1, 'a'), (2, 'b'), (3, 'c')) -> $c { $c.flat }; dd $a;
06:45 camelia rakudo-moar 58a482: OUTPUT«List $a = $((1, "a").Seq, (2, "b").Seq, (3, "c").Seq)␤»
06:45 Xliff m: my $a = { do for ((1, 'a'), (2, 'b'), (3, 'c')) -> $c { $c.flat } }; dd $a;
06:45 camelia rakudo-moar 58a482: OUTPUT«Block $a = -> ;; $_? is raw { #`(Block|65663120) ... }␤»
06:45 Xliff Damn.
06:45 seatek gfldex: where's a good place to paste code into for viewing here?
06:46 Xliff fpaste
06:46 gfldex https://gist.github.com/
06:46 Xliff fpaste.scsys.co.uk or gist.github.com
06:46 Xliff gfldex++ was faster on the gist.
06:47 Xliff m: my $a = { do for ( 1 => 'a', 2 => 'b', 3 => 'c') -> $c { $_ } }; dd $a;
06:47 camelia rakudo-moar 58a482: OUTPUT«Block $a = -> ;; $_? is raw { #`(Block|64771344) ... }␤»
06:47 gfldex there is gist-paste to paste and update directly from the shell, provided by https://packages.debian.org/jessie/gist
06:47 seatek https://gist.github.com/adaptiveoptics/3df583b​4a14486923b1a6e66a0d4eb1f#file-crusty-wrappers
06:47 Xliff m: my $a = { do for ( 1 => 'a', 2 => 'b', 3 => 'c') -> $c { $c } }; dd $a;
06:47 camelia rakudo-moar 58a482: OUTPUT«Block $a = -> ;; $_? is raw { #`(Block|78349744) ... }␤»
06:48 Xliff Hrrm....
06:48 seatek That's basically what Crust with middlewear (from Builder) is doing
06:49 seatek and it grows and grows in memory use. and i think it may be a bug in the way callables are being passed around more than callables themselves
06:50 seatek maybe not though - they're all self-contained
06:50 RabidGravy joined #perl6
06:53 seatek even when you put a $c=C.new in there to clear it out each time, memory grows and grows
06:53 gfldex seatek: if you remove line 8 and 9, does it still blow up?
06:54 seatek yup
06:54 seatek that was my first thought before too ;)
06:54 Woodi joined #perl6
06:55 gfldex could be RT#77644
06:55 synopsebot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=77644
06:56 seatek i'll try it without evals
06:57 seatek could i just substitue a code ref for that and it's still Callable?
06:59 neuraload joined #perl6
06:59 Xliff m: @a = ^4; @b = ^3; for @a, @b { .say }
06:59 camelia rakudo-moar 58a482: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '@a' is not declared␤at <tmp>:1␤------> 3<BOL>7⏏5@a = ^4; @b = ^3; for @a, @b { .say }␤»
06:59 Xliff m: my @a = ^4; my @b = ^3; for @a, @b { .say }
06:59 camelia rakudo-moar 58a482: OUTPUT«[0 1 2 3]␤[0 1 2]␤»
07:00 Xliff m: my @a = ^4; my @b = ^3; for |(@a, @b) { .say }
07:00 camelia rakudo-moar 58a482: OUTPUT«[0 1 2 3]␤[0 1 2]␤»
07:00 Xliff m: my @a = ^4; my @b = ^3; for |(@a, @b).flat { .say }
07:00 camelia rakudo-moar 58a482: OUTPUT«0␤1␤2␤3␤0␤1␤2␤»
07:01 seatek gfldex: yes that's exactly the problem -- the EVAL. dammit
07:01 seatek who fixes that?
07:01 seatek ha! Nobody is the owner :)
07:01 u-ou left #perl6
07:02 seatek clear back when Parrot was the thing
07:06 nadim_ joined #perl6
07:07 seatek wait -- i don't think it gets eval'ed each loop in Crust
07:07 seatek a flaw in my model
07:07 seatek curses
07:08 domidumont joined #perl6
07:08 gfldex perl6 -e 'loop { say ((slurp "/proc/$*PID/stat").lines[0].split: " ")[22]; EVAL q[]; }'
07:08 gfldex problem cleary still persists
07:10 darutoko joined #perl6
07:11 gfldex actually it stops growing after ~30sec
07:12 gfldex seatek: and that's why we golf :)
07:14 seatek i see :)
07:14 seatek yeah i noticed earlier that it tended to level off a bit
07:15 * masak .oO( when the bug hits your eye / like a big pizza pie / that's a-golf-e )
07:15 seatek so who fixes it? can you assign it to masak?
07:15 masak doubtful
07:15 seatek he'll fix it. he can fix anything :)
07:16 masak I think you might be thinking of some other masak
07:16 seatek hehe
07:16 wamba joined #perl6
07:18 seatek alright, if it can't be fixed I'll just have to hard-code my application into Crust.
07:18 brrt good morning #perl6
07:18 RabidGravy marning!
07:19 RabidGravy to be honest that's the way I use Crust anyway
07:21 seatek seriously? love it
07:21 go|dfish joined #perl6
07:22 RabidGravy infact I tend to implement the actions as "class Foo does Callable { method CALL-ME(%env) { } }" and put  the action in the CALL-ME
07:23 * seatek jots things down
07:24 RabidGravy I think there is an example of this kind of usage in Lumberjack::Application
07:24 RabidGravy anyway off to the grind-stone
07:27 gfldex seatek: it would not hurt if you would write your adventures down. We got the question, what web framework to use, quite often.
07:28 seatek I gave up on that question -- that's why I'm messing so deeply with Crust ;)
07:28 seatek I really don't like web frameworks. I spend more time learning them than I do making stuff work myself
07:29 seatek that's why i was so happy to see sessions with Crust
07:29 seatek just your basic stuff.
07:33 seatek i'm wanting to incorporate grammars into what i'm doing with this one. can't imagine anything better for an api
07:42 imcsk8 joined #perl6
07:45 labster joined #perl6
07:46 cgfbee joined #perl6
07:49 brillenfux joined #perl6
08:01 abraxxa joined #perl6
08:04 domidumont joined #perl6
08:08 domidumont joined #perl6
08:10 samcv i still need to lead grammars
08:11 abraxxa joined #perl6
08:12 samcv they look like they could be fun though
08:13 moritz they aren't really fun, but less painful than other approaches to parsing, IMHO
08:13 jferrero joined #perl6
08:13 samcv that's fun enough for me :)
08:13 samcv i guess fun is relative
08:15 ufobat joined #perl6
08:15 imcsk8 joined #perl6
08:15 domidumont joined #perl6
08:26 zakharyas joined #perl6
08:29 b2gills1 joined #perl6
08:30 Actualeyes joined #perl6
08:44 domidumont joined #perl6
08:53 domidumont joined #perl6
08:54 ocbtec joined #perl6
09:02 dakkar joined #perl6
09:09 Actualeyes left #perl6
09:14 g4 joined #perl6
09:14 g4 joined #perl6
09:36 maybekoo2 joined #perl6
09:36 domidumont joined #perl6
09:41 rindolf joined #perl6
09:55 khw joined #perl6
10:03 dextertzu joined #perl6
10:03 kurahaupo__ joined #perl6
10:04 xinming joined #perl6
10:09 xinming_ joined #perl6
10:35 Actualeyes joined #perl6
10:53 gregf_ joined #perl6
11:04 canopus joined #perl6
11:11 pmurias joined #perl6
11:20 pierre_ joined #perl6
11:21 itaipu joined #perl6
11:24 brillenfux_ joined #perl6
11:38 Actualeyes joined #perl6
11:45 Actualeyes joined #perl6
11:47 imcsk8 joined #perl6
11:57 geekosaur joined #perl6
12:09 Actualeyes left #perl6
12:15 AlexDaniel joined #perl6
12:22 timotimo hmm. do we want to redirect people from perl6.org to https://perl6.org?
12:23 moritz timotimo: if you want that, please grep the ecosystem for tests that try to fetch from HTTP URLs from perl6.org
12:23 timotimo oh, that's a very good point indeed
12:25 jonadab Redirecting onto https really only makes sense for sites that most users are going to log into with a username and password or the like, and even then really only if it's the kind of login where it _matters_ for something other than leaving blog comments.
12:25 jonadab IMO.
12:25 timotimo i just saw PoisonTap, which injects backdoors into pretty much everything the user's browser might ever request
12:28 moritz or hotstops that inject ads, and then some of these ads contain malware
12:29 AlexDaniel timotimo: generally, yes
12:29 jonadab timotimo: That explains why you are thinking about this now; but I don't see how it's really an argument in favor of redirecting all site traffic to https.
12:29 AlexDaniel jonadab: and you are wrong, sir
12:30 jonadab (It _might_, _arguably_, be an argument in favor of web browsers trying https first in preference to http when the user inputs a URL without a protocol.  Possibly.)
12:30 moritz jonadab: people then have the HTTPS URL in their browser history or bookmarks, and that's where they will go in a hostile environment
12:30 jonadab (Not that most users ever input URLs these days, except into search engine boxes.)
12:31 moritz well, and that's the next argument in favor
12:31 arnsholt If we want to move perl6.org to HTTPS, but also make it possible to download some things over HTTP for testing, maybe we could have a dedicated endpoint/virtual host that doesn't redirect to HTTPS and redirect everything else?
12:31 moritz if there's a redirect to HTTPS, that's where the search engines will send you
12:31 moritz arnsholt: we can make an insecure.perl6.org or so
12:31 moritz or nohttps.perl6.org
12:31 arnsholt Yeah
12:32 jonadab moritz: There are more direct ways to influence where the search engines send users.
12:32 jonadab (Granted, they aren't entirely foolproof.)
12:32 moritz jonadab: somehow the canoncial URL meta tags never really worked for me
12:33 AlexDani` joined #perl6
12:35 moritz https://www.reddit.com/r/IAmA/comm​ents/5c9ku9/lets_encrypt_team_a_no​nprofit_working_to_secure/d9ur4a2/ # the let's encrypt team's take on whethere you should use HTTPS everywhere
12:36 arnsholt Yeah, on the whole I think it's the right direction to move in
12:38 arnsholt It introduces an additional OpenSSL dependency (more or less de facto) on many things, which isn't great, and introduces a bootstrapping problem of getting HTTPS working when you don't already have working HTTPS
12:38 arnsholt But the gains are worth it I think
12:38 AlexDani` https://github.com/supernovus/perl6-h​ttp-client/blob/master/t/01-get.t#L8
12:38 AlexDani` https://github.com/supernovus/perl6-ht​tp-client/blob/master/t/02-post.t#L11
12:38 AlexDani` https://github.com/supernovus/perl6-http-cl​ient/blob/master/t/03-post-multipart.t#L11
12:39 AlexDani` these are the only tests you have to fix I think (I'm not sure if it works with https or not)
12:39 arnsholt I'd be surprised if it works over HTTPS
12:40 arnsholt AFAIK we don't have any bindings to an SSL library, much less a pure Perl 6 SSL suite
12:41 moritz the client that sergot++ worked on has openssl integration
12:42 AlexDaniel these are the only tests I see in our ecosystem that use perl6.org domain in this way
12:42 arnsholt moritz: Oh, neat!
12:44 dalek doc: f73aca6 | bazzaar++ | doc/Type/List.pod6:
12:44 dalek doc: Attempt to improve the documentation of routines zip, and roundrobin.
12:44 dalek doc: review: https://github.com/perl6/doc/commit/f73aca69d5
12:44 dalek doc: 3ca220b | (Zoffix Znet)++ | doc/Type/List.pod6:
12:44 dalek doc: Merge pull request #1012 from bazzaar/roundrobin-edits
12:44 synopsebot6 Link: http://doc.perl6.org/type/List
12:44 synopsebot6 Link: http://doc.perl6.org/type/List
12:44 dalek doc:
12:44 dalek doc: Improve the documentation of routines zip, and roundrobin.
12:44 dalek doc: review: https://github.com/perl6/doc/commit/3ca220b952
12:47 arnsholt Speaking of something completely different: Have any of you experimented with proportional fonts for code?
12:48 arnsholt In the SmallTalk environment at $dayjob, there's no highlighting and proportional fonts by default, and I'm finding it to be pretty nice actually
13:02 AlexDaniel arnsholt: um… that's some interesting point of view
13:03 AlexDaniel arnsholt: so what's nice about it?
13:03 timotimo maybe it's pleasant to the eye?
13:14 AlexDaniel but the question about fonts is a good one
13:14 arnsholt At least for reading normal text, I'm pretty sure proportional fonts score better on legibility than fixed-with
13:14 AlexDaniel are there any studies about this?
13:14 arnsholt I think so
13:14 arnsholt There're studies comparing serif and sans-serif at least
13:15 arnsholt But that's not my area of expertise
13:15 arnsholt Only annoying thing with no highlighting is that comments (especially with code inside) are a bit too prominent
13:16 timotimo "where the heck is the code"
13:18 domidumont joined #perl6
13:19 domidumont joined #perl6
13:32 pmurias arnsholt: aren't SmallTalk environments a hate it or love it kind of thing?
13:40 * timotimo stumbled over subresource integrity, but doesn't really think it applies for perl6.org or something in that space
13:47 kyclark joined #perl6
13:55 user9 joined #perl6
14:03 * nine just booked his flight for LPW2016
14:04 DrForr Yay! I'm coming in Friday morning, returning Monday morning.
14:05 tadzik I'm coming wednesday night, leaving sunday night
14:05 lizmat joined #perl6
14:05 nine Sooo...on to finding a hotel
14:09 nine 256 Euros for 2 nights? In London? With 4 stars? I don't trust this
14:09 timotimo they'll probably harvest one of your kidneys
14:10 kyclark joined #perl6
14:11 DrForr I gave up and found a place in Croydon; it's a little outside of London proper but all I could find in town was those damn GBP60/night walkups that are just above a hostel.
14:19 nine Bloomsbury Palace Hotel it is. It cannot be any worse than the last one I picked. That's physically impossible, so I may as well give it a try ;)
14:19 lizmat joined #perl6
14:20 tadzik nine: hmmm, not entirely unreasonable I think
14:20 tadzik I pay ~480 for 3 nights, 2 people
14:21 nine Now all I need to do is get really started working on my talk. Got swamped with work lately which kicked me really out of my Perl 6 habits.
14:22 domidumont1 joined #perl6
14:24 iH2O joined #perl6
14:33 itaipu joined #perl6
14:34 iH2O z...
14:36 viki ?
14:48 pmurias joined #perl6
14:54 cdg joined #perl6
14:55 xtt joined #perl6
15:00 titsuki joined #perl6
15:02 arnsholt pmurias: Yeah, I suspect ST is love it or hate it. But I'm digging it
15:02 arnsholt At work we're stuck with a pretty old commercial ST, but apart from that it's pretty neat
15:03 iH2O left #perl6
15:06 handle_ joined #perl6
15:06 handle_ left #perl6
15:15 pierre_ joined #perl6
15:45 titsuki bisect: my $a = "john.doe@perl6.org"; my $b = / <:L>+\.<:L>+\@<:L+:N>+\.<:L>+ /; say $/ if $a ~~ $b;
15:45 bisectable6 titsuki, On both starting points (old=2015.12 new=85c7072) the exit code is 0 and the output is identical as well
15:45 bisectable6 titsuki, Output on both points: 「john.doe@perl6.org」
15:46 FROGGS joined #perl6
15:47 titsuki bisect: old=2016.10 my $a = "john.doe@perl6.org"; my $b = / <:L>+\.<:L>+\@<:L+:N>+\.<:L>+ /; say $/ if $a ~~ $b;
15:47 bisectable6 titsuki, Bisecting by output (old=2016.10 new=85c7072) because on both starting points the exit code is 0
15:47 FROGGS o/
15:47 bisectable6 titsuki, bisect log: https://gist.github.com/18df​2dd79a0a2e1e8f7d136ca12fa7ab
15:47 bisectable6 titsuki, (2016-10-27) https://github.com/rakudo/rakudo/commit/​5ac593ee098f204ea69ef57edd9ae0925c544ea4
15:48 titsuki hi
15:50 AlexDaniel NeuralAnomaly: when?
15:50 AlexDaniel NeuralAnomaly: status
15:50 NeuralAnomaly AlexDaniel, [✘] Next release will be in 1 day and 13 hours. Since last release, there are 32 new still-open tickets (0 unreviewed and 0 blockers) and 12 unreviewed commits. See http://perl6.fail/release/stats for details
15:51 AlexDaniel titsuki: yeah, seems like it will be solved in the next release. Still an “oops” :)
15:52 AlexDaniel committable6: 6c my $a = "john.doe@perl6.org"; my $b = / <:L>+\.<:L>+\@<:L+:N>+\.<:L>+ /; say $/ if $a ~~ $b;
15:52 committable6 AlexDaniel, ¦«2015.12,2016.02,2016.03,2016.04,2016.05,​2016.06,2016.07.1,2016.08.1,2016.09,HEAD»: 「john.doe@perl6.org」␤¦«2016.10»: Nil
15:53 AlexDaniel there was no ticket for that?
15:53 AlexDaniel meaning that there are still no tests?
15:55 titsuki AlexDaniel: I'm not sure, but I can't find the test code for that bug.
15:55 AlexDaniel titsuki: perhaps you can contribute some?
15:57 pmurias joined #perl6
15:58 titsuki AlexDaniel: Should I RT this bug or write some test cases ?
15:59 viki Isn't it fixed already?
15:59 AlexDaniel titsuki: it is fixed already, so I don't think a ticket is required
16:00 viki committable6: 2016.10 my $a = "john.doe@perl6.org"; my $b = / <:L>+\.<:L>+\@<:L+:N>+\.<:L>+ /; say $/ if $a ~~ /<$b>/;
16:00 committable6 viki, ¦«2016.10»: 「john.doe@perl6.org」
16:00 viki I recall this bug and lizmat fixing it.
16:04 pmurias joined #perl6
16:05 committable6 joined #perl6
16:05 viki a glance through commits doesn't show tests
16:05 * viki adds
16:05 viki just in case
16:06 dalek doc: c40ccb5 | coke++ | doc/Type/List.pod6:
16:06 dalek doc: remove trailing whitespace
16:06 synopsebot6 Link: http://doc.perl6.org/type/List
16:06 dalek doc: review: https://github.com/perl6/doc/commit/c40ccb5553
16:07 viki s: &infix:<~~>, \($, $)
16:07 SourceBaby viki, Sauce is at https://github.com/rakudo/rakudo/​blob/85c7072/src/core/Mu.pm#L818
16:08 Actualeyes joined #perl6
16:08 titsuki Isn't it the test case for this bug ? https://github.com/perl6/roast/commit/4​0b8c3ebf1add22b9f982cba5c2b0324a1521566
16:09 viki Ah, OK. That gives me the commit that fixed it :) https://github.com/rakudo/rakudo/commit/5ac593e
16:10 viki titsuki: not really, basically the fix made it so you get truthy values instead of Bool
16:10 viki So the above (old) tests  needed an adjustment
16:11 viki The issue itself is regex stored in a variable used with a smartmatch and so the bug assumed that meant the ~~ was chained and so it returned just a Bool
16:15 kyclark joined #perl6
16:19 [Coke] jnthn: does your file finder module deal with this corner case: https://stackoverflow.com/questions/40649280​/ack-vim-with-ag-not-using-current-directory (last comment)
16:27 titsuki m: ("a" ~~ /a/ ~~ /abc/).say
16:27 camelia rakudo-moar 85c707: OUTPUT«Nil␤»
16:27 kyclark joined #perl6
16:28 titsuki viki: thanks for your explanation. I understand that.
16:29 pmurias joined #perl6
16:33 viki Tests for the bug have been added in https://github.com/perl6/roast/commit/839566cfd6
16:41 AlexDaniel viki++
16:51 skids joined #perl6
16:53 xtt joined #perl6
16:54 zakharyas1 joined #perl6
17:07 titsuki viki: thx. I could solve this issue: https://github.com/hankache/perl6intro/issues/118
17:07 viki sweet
17:14 lizmat joined #perl6
17:16 girafe joined #perl6
17:35 [Coke] google alert gave me: http://infogalactic.com/info/Perl_6 ... TIL someone is just copying wikipedia...
17:36 itaipu joined #perl6
17:38 viki Except they seem to be copying it as it were a year ago: "Stable release Rakudo Star / November 28, 2015"
17:41 geekosaur that's sadly common
17:42 geekosaur (copying old revs of wikipedia, that is. usually weaponized with adware or malware)
17:49 jnthn [Coke]: D'oh, I missed the negation case.
17:49 ufobat joined #perl6
17:50 jnthn [Coke]: Left myself a reminder at https://github.com/jnthn/p6-file-ignore/issues/1 :)
17:52 kyclark joined #perl6
17:54 domidumont joined #perl6
18:37 domidumont joined #perl6
18:44 viki What is the benefit in writing 2*$fract >= 1 rather than $fract >= .5 when deciding which way to round?
18:46 viki .oO( or is there any... )
18:46 mst possibly the 2* approach is cargo-cultish floating point bug avoidance?
18:46 viki hm. OK, I'll leave it in then
18:46 DrForr One's a shift and int comparison, the other is a floating-point comparison.
18:49 kyclark joined #perl6
18:50 dextertzu joined #perl6
18:53 El_Che why: $15,563 already? https://www.kickstarter.com/proj​ects/1422827986/learning-perl-6
18:53 El_Che 1 10k pledge
18:53 DrForr Liz & Wendy, I'm pretty sure.
18:54 nnunley joined #perl6
18:54 viki I was thinking the same :)
18:54 El_Che it sounds like them, indeed :)
18:54 viki lizmat++ wolfy++
18:54 El_Che don't guilt-shame them in case it's not them :)
18:55 El_Che I was having a look which pledge to take, but 10k is not happening :)
18:55 [Coke] oh, there was a 10K pledge? that explains how it jumped 10K between me leaving work and getting home yesterday! :)
18:57 El_Che well, the good thing about Trump ois that the dollar is cheaper now :)
18:58 DrForr And thanks to Brexit so's the pound :)
18:58 El_Che well, it will be handy when someone in the uk kickstarts a perl 6 book
18:59 viki So what you're saying the value of my monopoly Canukistan dollars goes us by as much as the rest of the world is getting trashed with bad decisions?
18:59 El_Che about that? is Timtowdy or someone else working on the Camel book succesor?
18:59 viki Sweet.
19:00 viki Damian promised a book "in a year" from last April.
19:00 viki ...but maybe he just got scared with the audience of 30 people starting at him, damanding a book :P
19:00 El_Che haha
19:00 El_Che just throw them some bones and run away
19:02 El_Che (the pledges are not cumulative, right? If you go for the t-shirt you won't get the ebook, I guess)
19:02 El_Che (I mean the early version pdf's)
19:02 DrForr El_Che: Read the comments.
19:02 El_Che ah cool
19:12 jdv79 joined #perl6
19:13 kalkin-_ Why in Perl6 if I'm using pipes i.e @array ==> sort() ==> unique() …, do i have to write ()?
19:13 kalkin-_ Why can't i just do @array ==> sort ==> unique …
19:14 kyclark joined #perl6
19:15 viki They're called feeds.
19:16 viki The … has very low precedence
19:16 viki (why? dunno)
19:16 kalkin-_ viki: ahh feeds, thanks
19:16 viki The Ancients who designed the language may know why it's so low.
19:16 kalkin-_ Viki … was just a replacement for etc, I'm asking about the reasoning behind the ()
19:17 kalkin-_ s/etc/ect/
19:17 viki Oh around sort() and unique() and stuff
19:17 lizmat El_Che: we're not guilt shamed that easily :-)
19:17 viki m: sort
19:17 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Calling sort() will never work with any of these multi signatures:␤    (@values) ␤    ($cmp, + is raw)␤at <tmp>:1␤------> 3<BOL>7⏏5sort␤»
19:17 viki kalkin-_: possibly to disambiguate whether you want the feed stuff to be used as an argument to the subs?
19:18 * viki knows nothing about feeds :(
19:19 kalkin-_ m: 3..1 ===> sort()
19:19 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Preceding context expects a term, but found infix > instead␤at <tmp>:1␤------> 3..1 ===>7⏏5 sort()␤»
19:19 kalkin-_ m: (3...1) ===> sort()
19:19 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Preceding context expects a term, but found infix > instead␤at <tmp>:1␤------> 3(3...1) ===>7⏏5 sort()␤»
19:19 viki m: 3..1 ==> sort()
19:19 camelia rakudo-moar 7f3224: ( no output )
19:19 viki m: say 3..1 ==> sort()
19:19 camelia rakudo-moar 7f3224: OUTPUT«3..1␤»
19:19 viki m: say 3..1 ==> sort
19:19 camelia rakudo-moar 7f3224: OUTPUT«3..1␤»
19:20 psch m: say (unique() <== sort() <== [1,1,3,2,5,2,1,6])
19:20 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3 5 6)␤»
19:20 kalkin-_ argle one = to many
19:21 kalkin-_ ahh i understand I didn't know that i can call a method like this: sort 1...3
19:21 kalkin-_ I always thought I need to use sort: 1...3
19:21 psch kalkin-_: that's because you can't.  that 'sort' isn't a method
19:21 psch m: say &sort eqv Any.^can('sort')
19:21 camelia rakudo-moar 7f3224: OUTPUT«False␤»
19:21 psch m: say &sort; say Any.^can('sort')
19:21 camelia rakudo-moar 7f3224: OUTPUT«sub sort (| is raw) { #`(Sub|69319472) ... }␤(Method+{<anon|73532432>}.new)␤»
19:22 kalkin-_ When do I want to  use ':' after a function?
19:22 viki kalkin-_: it's just a sub. Perl 6 is a multiparadigm language :)
19:22 kalkin-_ I.e what is the difference between sort 1..3 and sort_:_ 1...3?
19:23 psch anyway, the feed operators have the second lowest precedence, just above ; (i.e. statement end) and { } (i.e. block curlies)
19:23 viki One works and another doesn't?
19:23 viki m: say sort: 1...3
19:23 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5===␤Calling sort() will never work with any of these multi signatures:␤    (@values) ␤    ($cmp, + is raw)␤at <tmp>:1␤------> 3say 7⏏5sort: 1...3␤Variable '&infix:<:>' is not declared␤at <tmp>:1␤------> 3say sort7⏏…»
19:23 viki m: say sort 1..3:
19:23 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:23 viki ^ in that case it's a method call
19:23 psch uh wow, what about that &infix:<:> there..?
19:23 psch oh, right, colon in the wrong spot does that
19:24 kalkin-_ viki: ohh, hmm i think i misunderstood before
19:24 [Coke] m: <1 3 2> ==> sort() ==> say
19:24 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5===␤Argument to "say" seems to be malformed␤at <tmp>:1␤------> 3<1 3 2> ==> sort() ==> say7⏏5<EOL>␤Other potential difficulties:␤    Unsupported use of bare "say"; in Perl 6 please use .say if you meant $_, or use an explicit…»
19:24 kalkin-_ psch: thanks
19:24 [Coke] m: <1 3 2> ==> sort() ==> say()
19:24 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:24 [Coke] m: <1 3 2> ==> { sort } ==> { say }
19:24 viki kalkin-_: to be fair, you're not the first one I see write colons after a sub. Maybe it worked some time in the past?>
19:24 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Unsupported use of bare "say"; in Perl 6 please use .say if you meant $_, or use an explicit invocant or argument, or use &say to refer to the function as a noun␤at <tmp>:1␤------> 3<1 3 2> ==> { sort }…»
19:24 [Coke] m: <1 3 2> ==> { sort } ==> { .say }
19:24 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Sorry, do not know how to handle this case of a feed operator yet.␤at <tmp>:1␤------> 3<1 3 2> ==> { sort } ==> { .say }7⏏5<EOL>␤    expecting any of:␤        postfix␤»
19:25 psch m: <1 3 2> ==> &sort # is this supposed to work or is the error just an artifact?
19:25 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Sorry, do not know how to handle this case of a feed operator yet.␤at <tmp>:1␤------> 3o work or is the error just an artifact?7⏏5<EOL>␤»
19:25 kalkin-_ m: sort: 1...3
19:25 camelia rakudo-moar 7f3224: ( no output )
19:25 kalkin-_ m: say sort: 1...3
19:25 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5===␤Calling sort() will never work with any of these multi signatures:␤    (@values) ␤    ($cmp, + is raw)␤at <tmp>:1␤------> 3say 7⏏5sort: 1...3␤Variable '&infix:<:>' is not declared␤at <tmp>:1␤------> 3say sort7⏏…»
19:25 RabidGravy joined #perl6
19:26 kalkin-_ m: sort: 1...3 # this works in repl
19:26 camelia rakudo-moar 7f3224: ( no output )
19:26 viki m: dd (sort: 1...3)
19:26 camelia rakudo-moar 7f3224: OUTPUT«(1, 2, 3).Seq␤»
19:26 psch m: sort: 1..3; say sort.WHAT
19:26 camelia rakudo-moar 7f3224: OUTPUT«WARNINGS for <tmp>:␤Useless use of ".." in expression "1..3" in sink context (line 1)␤(Label)␤»
19:26 psch m: quietly sort: 1..3; say sort.WHAT # for clarity
19:26 camelia rakudo-moar 7f3224: OUTPUT«(Label)␤»
19:26 kalkin-_ m: sort 1...3; say sort.WHAT
19:26 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Calling sort() will never work with any of these multi signatures:␤    (@values) ␤    ($cmp, + is raw)␤at <tmp>:1␤------> 3sort 1...3; say 7⏏5sort.WHAT␤»
19:26 viki ahh
19:26 viki psch++
19:27 kalkin-_ m: sort: 1...3; say sort.WHAT
19:27 camelia rakudo-moar 7f3224: OUTPUT«(Label)␤»
19:27 psch m: sort: 1..3; redo sort unless $++
19:27 camelia rakudo-moar 7f3224: OUTPUT«WARNINGS for <tmp>:␤Useless use of ".." in expression "1..3" in sink context (line 1)␤labeled redo without loop construct␤  in block <unit> at <tmp> line 1␤␤»
19:27 psch :P
19:27 andrzejku joined #perl6
19:27 psch kalkin-_: try 'sort: 3,2,1' in the repl instead maybe? :)
19:27 kalkin-_ I have no idea where i picked up the colons form
19:28 FROGGS huh, someone broke Label.gist it seems
19:28 psch kalkin-_: probably misplaced intuition.  "sort: 1,2,3" seems more natural, but we demand the invocant marker *after* the invocant, not before
19:28 kalkin-_ psch: sort: 3,2,1 & sort 3...1 works in repl
19:28 psch kalkin-_: does it print 3,2,1? :)
19:28 kalkin-_ aehm
19:28 kalkin-_ the second one is sort_:_ 3...1
19:29 psch right, but it doesn't sort
19:29 psch is my point
19:29 psch i don't recall if your repl actually prints non-printy stuff though...
19:29 kalkin-_ ahh
19:29 viki m: sort: 1...3; say sort
19:29 camelia rakudo-moar 7f3224: OUTPUT«Cannot find method 'Stringy': no method cache and no .^find_method␤  in block <unit> at <tmp> line 1␤␤»
19:29 kalkin-_ I haven't noticed that it doesn't sort
19:29 viki m: sort: 1...3; say sort.gist
19:29 camelia rakudo-moar 7f3224: OUTPUT«Cannot find method 'Stringy': no method cache and no .^find_method␤  in block <unit> at <tmp> line 1␤␤»
19:29 dalek ecosystem: ebc1542 | (Paweł Szulc)++ | META.list:
19:29 dalek ecosystem: Added Statistics::LinearRegression
19:29 dalek ecosystem:
19:29 dalek ecosystem: See https://github.com/hipek8/p6​-Statistics-LinearRegression
19:29 dalek ecosystem: review: https://github.com/perl6/e​cosystem/commit/ebc1542774
19:29 dalek ecosystem: e31bda4 | RabidGravy++ | META.list:
19:29 dalek ecosystem: Merge pull request #266 from hipek8/master
19:29 dalek ecosystem:
19:29 dalek ecosystem: Added Statistics::LinearRegression
19:29 dalek ecosystem: review: https://github.com/perl6/e​cosystem/commit/e31bda45e5
19:29 psch point is, [ \w+ ':' .+ ] gets parsed as a Label followed by a statement
19:30 viki bisect: sort: 1...3; say sort.gist
19:30 bisectable6 viki, Bisecting by exit code (old=2015.12 new=7f32243). Old exit code: 0
19:30 psch err, plus anchors :S
19:30 FROGGS viki:     multi method gist(Label:D:) {
19:30 bisectable6 viki, bisect log: https://gist.github.com/f53d​92a6264535b1bd1db47f86bcf1c7
19:30 bisectable6 viki, (2016-07-19) https://github.com/rakudo/rakudo/commit/​34f7f36f65ef0d52932b3d1986afe6c39db42ab8
19:30 psch so [ ^ \w+ ':' .+ ;? $] # or something like that
19:30 AlexDaniel that being said:
19:30 AlexDaniel m: say sort 1..3:
19:30 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:30 FROGGS :S
19:31 psch m: say unique sort 3,1,1,5,2,5: :
19:31 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3 5)␤»
19:31 AlexDaniel which should not be that surprising
19:31 kalkin-_ thanks for the explanation. Any hints where i can read up on labels?
19:31 psch https://docs.perl6.org/type/Label probably?
19:31 AlexDaniel psch: although I am surprised that you can nest it like that…
19:32 psch AlexDaniel: it gets wonky though
19:32 psch m: say unique sort 3,1,1,5,2,5: : : #
19:32 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say unique sort 3,1,1,5,2,5: : :7⏏5 #␤    expecting any of:␤        colon pair␤»
19:32 psch AlexDaniel: although that's probably &say being somewhat special :)
19:32 AlexDaniel m: say 25 :
19:32 camelia rakudo-moar 7f3224: OUTPUT«25␤»
19:32 AlexDaniel not really?
19:32 AlexDaniel m: say 25,40 :
19:32 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say 25,40 :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:32 AlexDaniel m: say (25,40) :
19:32 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say (25,40) :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:33 FROGGS viki: let me try to fix it
19:33 AlexDaniel m: say sort (25,40) :
19:33 camelia rakudo-moar 7f3224: OUTPUT«(25 40)␤»
19:33 psch m: sort unique (2, 12, 1, 2): :
19:33 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3sort unique (2, 12, 1, 2): :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:33 psch hm, maybe just the outer most doesn't parse
19:33 psch although i can't imagine why
19:34 psch might be we commit to a sub call somewhere along the way..?  dunno, haven't looked at the grammar in a few weeks :/
19:34 psch bisect: sort unique (2, 12, 1, 2): :
19:34 bisectable6 psch, On both starting points (old=2015.12 new=7f32243) the exit code is 1 and the output is identical as well
19:34 bisectable6 psch, Output on both points: ===SORRY!=== Error while compiling /tmp/r2wO3Ni78N␤Confused␤at /tmp/r2wO3Ni78N:1␤------> sort unique (2, 12, 1, 2): :<HERE> ␤    expecting any of:␤        colon pair
19:34 psch well, apparently it's been like that for a while
19:34 AlexDaniel commit: all sort unique (2, 12, 1, 2): :
19:34 kalkin-_ left #perl6
19:35 kalkin-_ joined #perl6
19:35 psch m: $a = sort unique (2, 12, 1, 2): :
19:35 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$a' is not declared␤at <tmp>:1␤------> 3<BOL>7⏏5$a = sort unique (2, 12, 1, 2): :␤»
19:35 psch m: my $a = sort unique (2, 12, 1, 2): :
19:35 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3my $a = sort unique (2, 12, 1, 2): :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:35 committable6 AlexDaniel, https://gist.github.com/f110​e1039926477f4c3b2a59c4f694ae
19:35 psch aha, 2015.03 and earlier explicitly forbade it
19:35 psch then came the confusion
19:36 psch honestly, it seems weird to forbid it there
19:36 psch i don't see the difference between allowing nesting inside and argument list and allowing nesting up to the statement level
19:36 psch so either nested invocant markers should be all the way gone or they should be fine up to statement level
19:36 FROGGS $ perl6 -e 'say: say(say)'
19:36 FROGGS Label<say>(at -e:1, '⏏say: say(say)')
19:36 psch and considering a single invocant marker on statement level is fine, it should probably be fine?
19:36 psch FROGGS++
19:38 kalkin-_ Why can I do say 1…3 but not sort 1…3 ?
19:38 kalkin-_ has sort some kind of special precedence?
19:38 viki kalkin-_: you can do both
19:38 viki m: say sort 1…3
19:38 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:38 viki m: say sort 3…1
19:38 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:39 kalkin-_ m: sort 1…3
19:39 camelia rakudo-moar 7f3224: ( no output )
19:39 kalkin-_ Repl throws me an error on that
19:39 kalkin-_ Error while compliing: Two terms in a row
19:39 psch kalkin-_: is your sort maybe still a Label?
19:39 viki kalkin-_: what sort of error?
19:39 kalkin-_ psch: good point
19:39 psch m: sort: 1; sort 1..3
19:39 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Two terms in a row␤at <tmp>:1␤------> 3sort: 1; sort7⏏5 1..3␤    expecting any of:␤        infix␤        infix stopper␤        statement end␤        statement modifier␤        statement…»
19:39 kalkin-_ yes it was still a label, thank you psch
19:40 psch m: X: 1; X::AdHoc.new.throw: msg => "phooey" # /o\
19:40 camelia rakudo-moar 7f3224: OUTPUT«WARNINGS for <tmp>:␤Useless use of constant integer 1 in sink context (line 1)␤Could not find symbol '&AdHoc'␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
19:40 nicq20 joined #perl6
19:41 psch we probably still have a ticket about 'class X' sitting somewhere...
19:42 psch m: sub f(Int(Cool) $x) {$x}; Int: quietly 1; f 2.0
19:42 camelia rakudo-moar 7f3224: OUTPUT«===SORRY!===␤P6opaque: get_boxed_ref could not unbox for the representation '20' of type Label␤»
19:42 psch snrk
19:42 AlexDaniel m: say (sort (2, 12, 1, 2):):
19:42 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say (sort (2, 12, 1, 2):):7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:44 AlexDaniel ah wait
19:45 AlexDaniel m: say sort unique (2…3…1): :
19:45 camelia rakudo-moar 7f3224: OUTPUT«(1 2 3)␤»
19:46 AlexDaniel psch: it kinda works
19:46 AlexDaniel m: say sort unique [3, 5, 3, 1]: :
19:46 camelia rakudo-moar 7f3224: OUTPUT«(1 3 5)␤»
19:49 AlexDaniel ah, you mean without say…
19:49 AlexDaniel m: sort unique (2…3…1): :
19:49 camelia rakudo-moar 7f3224: ( no output )
19:49 AlexDaniel m: sort unique [3, 5, 3, 1]: :
19:49 camelia rakudo-moar 7f3224: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3sort unique [3, 5, 3, 1]: :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:49 AlexDaniel I have no idea
19:50 psch yeah, there's definitely some weird state in the parser making things... weird
19:50 dalek doc: 3fd8f9d | (Zoffix Znet)++ | doc/Type/Real.pod6:
19:50 dalek doc: Direct to parse-base as reverse of base
19:50 dalek doc:
19:50 dalek doc: Since the :16("") notation has some magiks in it and it can't parse negatives
19:50 dalek doc: review: https://github.com/perl6/doc/commit/3fd8f9d0f4
19:50 synopsebot6 Link: http://doc.perl6.org/type/Real
19:50 psch s:2nd/weird/inconsistent/ # probably
19:51 psch from what i remember it might just come down to the non-parens'd branch not expecting an invocant marker anymore for some reason
19:51 psch but yeah, been some time since i spend time with the grammar
19:53 mohae_ joined #perl6
19:54 dalek doc: 3dd93ed | (Zoffix Znet)++ | doc/Type/Real.pod6:
19:54 dalek doc: Document behaviour of Rational.base(Int:D, Whatever)
19:54 dalek doc: review: https://github.com/perl6/doc/commit/3dd93ed2ee
19:54 synopsebot6 Link: http://doc.perl6.org/type/Real
19:57 viki hm
19:57 psch r: say sort 1: :
19:57 camelia rakudo-moar 2432c4, rakudo-jvm 76b061: OUTPUT«(1)␤»
19:57 psch r: say sort 2,1: :
19:57 camelia rakudo-jvm 76b061: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say sort 2,1: :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:57 camelia ..rakudo-moar 2432c4: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say sort 2,1: :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:57 psch wicked
19:58 psch r: say (sort 2,1:) :
19:58 camelia rakudo-moar 2432c4: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say (sort 2,1:) :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:58 camelia ..rakudo-jvm 76b061: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say (sort 2,1:) :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:58 * psch blames the comma
19:58 viki r: say sort (2,1): :
19:58 camelia rakudo-moar 2432c4: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say sort (2,1): :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:58 camelia ..rakudo-jvm 76b061: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say sort (2,1): :7⏏5<EOL>␤    expecting any of:␤        colon pair␤»
19:59 psch r: say (sort 1:) :
19:59 camelia rakudo-moar 2432c4, rakudo-jvm 76b061: OUTPUT«(1)␤»
20:00 dextertzu joined #perl6
20:06 Tonik joined #perl6
20:10 viki What are the 10 extra second agbout?
20:10 viki *about
20:10 viki m: say Instant.from-posix: 100
20:10 camelia rakudo-moar 2432c4: OUTPUT«Instant:110␤»
20:10 psch j: say Instant.from-posix: 100
20:10 camelia rakudo-jvm 76b061: ( no output )
20:10 psch j: say Instant.from-posix: 100
20:10 camelia rakudo-jvm 76b061: OUTPUT«Instant:110␤»
20:11 psch leap seconds?
20:11 * viki doesn't follow how those fit in there
20:11 psch j: say Instant.from-posix: 100, :!prefer-leap-second
20:11 camelia rakudo-jvm 76b061: OUTPUT«Instant:110␤»
20:11 psch yeah, it was a completely blind guess
20:13 psch "Nil while ($i = $i + 1) < $elems && $p > nqp::atpos($posixes,$i);"
20:13 psch seems kind of not-that-self-documenting, that line
20:13 psch in Rakudo/Internals.pm:1546, .tai-from-posix
20:13 psch which is what's behind Instant.from-posix
20:14 viki Hm https://github.com/rakudo/rakudo/blob/7f​32243/src/core/Rakudo/Internals.pm#L1517
20:14 viki "# TAI - UTC at the Unix epoch (1970-01-01T00:00:00Z)."
20:14 psch ah, so it *is* leap seconds
20:14 psch and we had 10 leap seconds before epoch start
20:15 viki Oh, "TAI is exactly 36 seconds ahead of UTC. The 36 seconds results from the initial difference of 10 seconds at the start of 1972, plus 26 leap seconds in UTC since 1972."
20:15 psch j: say Instant.from-posix: 0, :!prefer-leap-second
20:15 camelia rakudo-jvm 76b061: OUTPUT«Instant:10␤»
20:15 psch m: say Instant.from-posix: 0, :prefer-leap-second
20:15 camelia rakudo-moar 2432c4: OUTPUT«Instant:10␤»
20:15 psch m: say Instant.from-posix: 0, :!prefer-leap-second
20:15 sufrostico joined #perl6
20:15 camelia rakudo-moar 2432c4: OUTPUT«Instant:10␤»
20:15 * psch is completely unclear about what that named does
20:16 psch oh wait
20:16 psch that's the named for tai-from-posix...
20:17 psch ah, but it's called the same in .from-posix
20:17 psch so, yeah, it might have been intended to allow "ignore leap seconds"..?
20:17 geekosaur but that might be buggy if you can't ignore the fixed initial difference
20:17 psch ohh
20:17 geekosaur which might well be a thinko somewhere
20:18 psch prefer-leap-second means "interpret this as a leap second"
20:18 Xliff *SNARL*
20:18 Xliff I went and upgraded libssl on my linux box.
20:18 viki # If $prefer-leap-second is true, 915148800 is interpreted to
20:18 viki # mean 1998-12-31T23:59:60Z rather than 1999-01-01T00:00:00Z
20:18 Xliff OpenSSL 1.1.0 changed the initialization and went and broke the OpenSSL module.
20:18 AlexDaniel I don't want to sound annoying, but…
20:18 psch m: say Instant.from-posix(78796800, $_) for True, False
20:18 AlexDaniel what about negative values?
20:18 camelia rakudo-moar 2432c4: OUTPUT«Instant:78796810␤Instant:78796811␤»
20:18 psch m: say Instant.from-posix(78796800, $_).Date for True, False
20:18 camelia rakudo-moar 2432c4: OUTPUT«1972-06-30␤1972-07-01␤»
20:18 psch there it is
20:19 Xliff So OpenSSL support for perl6 will BREAK if users upgrade to OpenSSL 1.0.2
20:19 psch well, assuming there's a positional candidate :P
20:19 Xliff Er...
20:19 psch m: say Instant.from-posix(78796800, prefer-leap-second => $_).Date for True, False
20:19 camelia rakudo-moar 2432c4: OUTPUT«1972-07-01␤1972-07-01␤»
20:19 psch m: say Instant.from-posix(78796800, prefer-leap-second => $_).DateTime for True, False
20:19 camelia rakudo-moar 2432c4: OUTPUT«1972-07-01T00:00:00Z␤1972-07-01T00:00:00Z␤»
20:19 Xliff Let's try that again. -- "So OpenSSL support for perl6 will BREAK if users upgrade to OpenSSL 1.1.0"
20:20 viki Isn't 1.1.0 the buggy one with the DoS bug?
20:21 RabidGravy Xliff, I'm sure your patch to mitigate that would be welcomed :)
20:21 AlexDaniel m: say Instant.from-posix: -9999999999999999999999999999999999999999999
20:21 camelia rakudo-moar 2432c4: OUTPUT«Instant:-999999999999999​9999999999999999999999999989␤»
20:22 Xliff RabidGravy: Already looked. It is non-trivial.
20:22 viki m: say Instant.from-posix: -10
20:22 camelia rakudo-moar 2432c4: OUTPUT«Instant:0␤»
20:23 viki AlexDaniel: to me it does sound like the 10 extra seconds do not apply prior to start of 1972
20:24 viki m: say Instant.from-posix(-10).DateTime
20:24 camelia rakudo-moar 2432c4: OUTPUT«1969-12-31T23:59:50Z␤»
20:24 viki hm
20:24 viki m: say Instant.from-posix(10).DateTime
20:24 camelia rakudo-moar 2432c4: OUTPUT«1970-01-01T00:00:10Z␤»
20:24 viki So we basically always sub them?
20:25 viki From what I'm reading at https://en.wikipedia.org/wik​i/International_Atomic_Time that sounds like a bug
20:25 geekosaur sounds like we're back to the old days of openssl
20:26 RabidGravy yeah
20:27 acrussell_ joined #perl6
20:28 Xliff GRRR.... and there is no graceful way to downgrade without breaking everything.
20:28 psch ahh, it's *not* named in .from-posix
20:28 psch so yeah, my first eval there was correct
20:28 Xliff Sooo...
20:28 psch m: say Instant.from-posix(78796800, $_).Date for True, False
20:28 camelia rakudo-moar 2432c4: OUTPUT«1972-06-30␤1972-07-01␤»
20:28 psch first is leap-second ignorant, second is *-aware
20:29 psch m: say Instant.from-posix(-10, $_).Date for True, False
20:29 camelia rakudo-moar 2432c4: OUTPUT«1969-12-31␤1969-12-31␤»
20:29 psch m: say Instant.from-posix(-0, $_).Date for True, False
20:29 Xliff Compile openssl 1.0.2 in /usr/local and have a wrapper for my script that forces its use.
20:29 camelia rakudo-moar 2432c4: OUTPUT«1970-01-01␤1970-01-01␤»
20:29 Xliff yay.
20:29 psch m: say Instant.from-posix(0, $_).Date for True, False
20:29 camelia rakudo-moar 2432c4: OUTPUT«1970-01-01␤1970-01-01␤»
20:29 psch m: say Instant.from-posix(0, $_).DateTime for True, False
20:29 camelia rakudo-moar 2432c4: OUTPUT«1970-01-01T00:00:00Z␤1970-01-01T00:00:00Z␤»
20:29 RabidGravy I've always tended to treat openssl specially in a build, it went through so long being totally bizarre in its changes
20:30 psch ...the first 10 seem to always be there though, viki++
20:31 sufrostico joined #perl6
20:32 viki AlexDaniel: FWIW, I didn't mean that you open too many tickets or anything here: https://irclog.perlgeek.de/​perl6/2016-11-15#i_13573265  it was just general frustration at dead-end tickets :)
20:32 AlexDaniel viki: I never thought about it this way, don't worry
20:32 * psch . o O( don't dead-end tickets just mean that people with notable insight don't write enough patches..? )
20:32 viki OK. Just making sure :)
20:33 AlexDaniel thanks :)
20:33 psch in any case, AlexDaniel++ for digging into things
20:34 AlexDaniel viki: that being said, will you open a ticket for 10 second issue?
20:34 AlexDaniel I don't understand it as much as you do
20:34 viki Yeah
20:34 AlexDaniel viki++
20:34 psch m: say Instant.from-posix(100, $_) for True, False
20:34 camelia rakudo-moar 2432c4: OUTPUT«Instant:110␤Instant:110␤»
20:34 psch one of those should say "100", probably the first one
20:35 psch so, yeah, +1 on the ticket and all
20:35 psch although, honestly, 'prefer-lead-second' sounds like False is the wrong default..?
20:36 psch ...leap
20:36 troys joined #perl6
20:37 RabidGravy Xliff, my reading of the openssl changes would indicate that you have a choice when it is compilled whether to be backward compatible or not
20:37 RabidGravy seems strange to package one that isn't
20:38 Xliff Backwards compatible (from what I've read) involves a macro in a header.
20:38 Xliff I'll download the 1.1 source in a few and see.
20:38 Xliff But every time I seem to get somewhere with this latest project, something always come back to bite me in the ass.
20:38 Xliff It's frustrating.
20:42 moritz https://github.com/supernovu​s/perl6-http-client/pull/13 preparation for the perl6.org HTTPS redirect. AlexDaniel++ for digging it up
20:44 dalek doc: 523f08a | (Zoffix Znet)++ | doc/Type/Real.pod6:
20:44 dalek doc: Document .base(Int:D, Whatever) for all Reals
20:44 synopsebot6 Link: http://doc.perl6.org/type/Real
20:44 dalek doc:
20:44 dalek doc: The Whatever was made acceptable by all Reals and not just the Rationals in
20:44 dalek doc: https://github.com/rakudo/rakudo/commit/​c1d2599234ecf29539e8940f96dc48c94acda6a6
20:44 dalek doc: review: https://github.com/perl6/doc/commit/523f08a702
20:45 mohae joined #perl6
20:46 TEttinger joined #perl6
20:48 Xliff \o/
20:48 Xliff Holy shinkies... I fixed it!
20:48 * Xliff looks at RabidGravy++
20:48 RabidGravy top man!
20:52 viki Instant.from-posix ticket: https://rt.perl.org/Ticket/Display.html?id=130123
20:52 * viki &
20:54 lizmat viki: from the WP article: "Since this system of correction was implemented in 1972, 26 leap seconds have been inserted"
20:56 lizmat viki: "By then, the UTC clock was already 10 seconds behind TAI"
20:56 geekosaur yes, viki quoted a different statement of that earlier
20:57 geekosaur [17 20:15:01] <viki> Oh, "TAI is exactly 36 seconds ahead of UTC. The 36 seconds results from the initial difference of 10 seconds at the start of 1972, plus 26 leap seconds in UTC since 1972."
20:57 lizmat so, anything before 1972 has 10
20:57 lizmat since this only goes back to 1970 anyway, the current behaviour feels correct to me
21:01 kyclark joined #perl6
21:01 geekosaur I think viki's intepretation is that it was ignored before 1972 so should be 0, with the 10 seconds abruptly appearing at 00:00:00 1 Jan 1972
21:02 geekosaur if nobody was actually keeping track officially before that point, the interpretation makes sense
21:05 psch so the 11th leap second was at 78796800, and nobody cared about them before?
21:05 lizmat https://en.wikipedia.org/wiki/Leap_second
21:05 lizmat "which had been synchronized with UT1 in 1958, "
21:06 cognominal joined #perl6
21:06 lizmat so, I one could argue that 10 seconds got added in 1958, and between then and 1972 the difference got corrected at 78796800
21:07 psch m: say Instant.from-posix(78796800).DateTime
21:07 camelia rakudo-moar 53d7b7: OUTPUT«1972-07-01T00:00:00Z␤»
21:07 cdg joined #perl6
21:08 psch ...this comes down to metrology doesn't it
21:09 psch i mean, it's about solar seconds vs SI seconds
21:09 psch the question is, are the precise instants for the 10 pre-1972 leap seconds
21:09 psch because if not we can just do whatever, where one possibility is "we already are doing the right thing"
21:10 psch *are there
21:11 ydhf joined #perl6
21:11 sufrostico joined #perl6
21:14 ydhf sometimes I ask myself what would have been Perl 6 if it would have fully embraced POSIX apis at the nativecall level throwing away multiplatform and fancy things like multithreading (a part for the huge amount of stuff POSIX already gives you) but keeping the syntax and features
21:16 lizmat feels like an ecosystem module to me :-)
21:17 ydhf an huge one
21:17 stmuk_ there is one
21:18 firstdayonthejob joined #perl6
21:18 moritz but it's tiny at the moment, no?
21:19 stmuk_ yes but its just case a case of adding nativecall
21:19 stmuk_ https://github.com/cspencer/perl6​-posix/blob/master/lib/POSIX.pm6
21:20 espadrine joined #perl6
21:20 psch dunno, integrating POSIX on a language level seems way more work than what POSIX.pm does currently
21:20 psch i mean, start {} would start posix thread, wouldn't it?
21:20 psch +a
21:20 lizmat psch: but "start" doesn't start a thread
21:21 lizmat start merely schedules code to be executed at a later time by another thread
21:21 ydhf pthread_create would be ok
21:21 ydhf $
21:21 ydhf would it work?
21:21 psch lizmat: that's kind of my point, start would have to schedule a pthread, instead of a vm thread
21:21 lizmat it does not necessarily start a tread
21:21 psch lizmat: sorry if i wasn't particularly clear in my wording
21:21 Vynce joined #perl6
21:22 moritz ydhf: try it and see!
21:23 psch m: use NativeCall; sub pthread_create($, $, &, $) is native('pthread') {*}
21:23 camelia rakudo-moar 53d7b7: OUTPUT«Potential difficulties:␤    In 'pthread_create' routine declaration - Not an accepted NativeCall type for parameter [1]  : Any␤     --> For Numerical type, use the appropriate int32/int64/num64...␤    at <tmp>:1␤    ------> 3ate($, $, &, $) is nat…»
21:23 psch well...
21:23 * psch isn't gonna dig up the corresponding defines...
21:23 psch m: use NativeCall; sub pthread_create(Pointer $, Pointer $, &, Pointer $) is native('pthread') {*}
21:23 camelia rakudo-moar 53d7b7: ( no output )
21:23 psch that probably almost works :P
21:26 stmuk_ isnt the whole point of perl6 that you dont have to do that?
21:26 RabidGravy quite
21:26 moritz you really don't have to
21:26 psch right, the hypothetical is "what if Perl 6 was a POSIX extension"
21:31 nadim_ joined #perl6
21:33 atweiden-air joined #perl6
21:35 atweiden-air in a regex, is it possible to specify that a general quantifier (**) is an even number?
21:36 itaipu joined #perl6
21:40 nicq20 left #perl6
21:40 firstdayonthejob joined #perl6
21:42 AlexDaniel atweiden-air: well kinda
21:42 geekosaur ** {0, {$_ + 2} ... *} # something like?
21:42 AlexDaniel 0, 2 ... * should work too
21:42 AlexDaniel m: .say for 0, 2 ... *
21:42 AlexDaniel oops
21:42 AlexDaniel m: say (for 0, 2 ... *)
21:42 camelia rakudo-moar 53d7b7: OUTPUT«(timeout)0␤2␤4␤6␤8␤10␤12␤14␤16␤18␤2​0␤22␤24␤26␤28␤30␤32␤34␤36␤38␤40␤42␤44␤46␤4​8␤50␤52␤54␤56␤58␤60␤62␤64␤66␤68␤70␤72␤74␤7​6␤78␤80␤82␤84␤86␤88␤90␤92␤94␤96␤98␤10…»
21:42 camelia rakudo-moar 53d7b7: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Missing block␤at <tmp>:1␤------> 3say (for 0, 2 ... *7⏏5)␤    expecting any of:␤        block or pointy block␤»
21:43 AlexDaniel the problem is that you probably want longest token matching
21:43 AlexDaniel but it seems to prefer shorter ones, if I'm not mistaken
21:44 atweiden-air m: say so 'ww' ~~ / w ** {0, 2 ... *}/
21:44 camelia rakudo-moar 53d7b7: OUTPUT«Cannot .elems a lazy list␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
21:45 AlexDaniel so just add a <?{}> check
21:45 AlexDaniel m: say ‘abcdef’ ~~ /(.*) <?{$0.chars %% 2}> /
21:45 camelia rakudo-moar 53d7b7: OUTPUT«「abcdef」␤ 0 => 「abcdef」␤»
21:45 AlexDaniel m: say ‘abcdefg’ ~~ /(.*) <?{$0.chars %% 2}> /
21:45 camelia rakudo-moar 53d7b7: OUTPUT«「abcdef」␤ 0 => 「abcdef」␤»
21:46 AlexDaniel m: say ‘abcdefg’ ~~ /^ (.*) <?{$0.chars %% 2}> $/
21:46 camelia rakudo-moar 53d7b7: OUTPUT«Nil␤»
21:46 AlexDaniel m: say ‘abcdef’ ~~ /^ (.*) <?{$0.chars %% 2}> $/
21:46 camelia rakudo-moar 53d7b7: OUTPUT«「abcdef」␤ 0 => 「abcdef」␤»
21:46 AlexDaniel atweiden-air: any reason why that ↑ is not good enough?
21:46 perlpilot That's probably closer to what's wanted anyway.  (using <?{}> like that)
21:46 atweiden-air thanks, will use that
21:47 AlexDaniel though you will have to rely on backtracking in this case…
21:50 perlpilot btw, I'm pretty sure any solution like 'ww' ~~ / w ** {0, 2 ... *} /  isn't going to do the right thing anyway.  For example ...
21:50 perlpilot m: "aaaa" ~~ / a ** {0,2,4,6} /;  #  works?
21:50 camelia rakudo-moar 53d7b7: ( no output )
21:50 perlpilot m: "aaaa" ~~ / a ** {0,2,4,6} /;  say $/; #  works?
21:50 camelia rakudo-moar 53d7b7: OUTPUT«「aaaa」␤»
21:50 perlpilot m: "aaa" ~~ / a ** {0,2,4,6} /;  say $/; #  nope
21:50 camelia rakudo-moar 53d7b7: OUTPUT«Nil␤»
21:50 AlexDaniel number of elems, yeah
21:51 AlexDaniel it does .elems on it
21:52 atweiden-air m: my token item { \h* <?{$0.chars %% 2}> w+ } ; say so 'w' ~~ &item
21:52 camelia rakudo-moar 53d7b7: OUTPUT«Use of Nil in string context␤  in block  at <tmp> line 1␤True␤»
21:52 perlpilot It should die with an NYI error IMHO as it could easily confuse someone
21:52 AlexDaniel m: say ‘abcdefgh’ ~~ /.**{2|5}/ # this is sad too
21:52 camelia rakudo-moar 53d7b7: OUTPUT«This type (Junction) does not support positional operations␤  in block <unit> at <tmp> line 1␤␤»
21:52 AlexDaniel atweiden-air: you didn't capture it with ()
21:53 atweiden-air right
21:53 AlexDaniel m: say ‘abcdefgh’ ~~ /.**{Inf}/ # this is sad too
21:53 camelia rakudo-moar 53d7b7: OUTPUT«This type (Failure) does not support positional operations␤  in block <unit> at <tmp> line 1␤␤»
21:53 AlexDaniel m: say ‘abcdefgh’ ~~ /.**{NaN}/ # this is sad too
21:53 camelia rakudo-moar 53d7b7: OUTPUT«This type cannot unbox to a native integer: P6opaque, Failure␤  in block <unit> at <tmp> line 1␤␤»
21:53 AlexDaniel m: say ‘abcdefgh’ ~~ /.**{3.4}/ # this is sad too
21:53 camelia rakudo-moar 53d7b7: OUTPUT«「abc」␤»
21:54 sufrostico joined #perl6
21:55 AlexDaniel m: say ‘abcdefgh’ ~~ /.** 3..5/
21:55 camelia rakudo-moar 53d7b7: OUTPUT«「abcde」␤»
21:55 AlexDaniel and this is also not a normal range syntax
21:55 AlexDaniel m: say ‘abcdefgh7’ ~~ /.** 3..5..8/
21:55 camelia rakudo-moar 53d7b7: OUTPUT«Nil␤»
21:55 AlexDaniel m: say ‘abcdefgh7’ ~~ /.** 3..5..✓/
21:55 camelia rakudo-moar 53d7b7: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Unrecognized regex metacharacter ✓ (must be quoted to match literally)␤at <tmp>:1␤------> 3say ‘abcdefgh7’ ~~ /.** 3..5..7⏏5✓/␤    expecting any of:␤        infix stopper␤»
21:55 AlexDaniel oops
21:55 AlexDaniel m: say ‘abcdefgh7’ ~~ /.** 3..5..7/
21:55 camelia rakudo-moar 53d7b7: OUTPUT«「bcdefgh7」␤»
22:00 AlexDaniel meh
22:00 AlexDaniel m: say ‘abcdefgh’ ~~ /.** {0..Inf}/
22:00 camelia rakudo-moar 53d7b7: OUTPUT«「abcdefgh」␤»
22:00 AlexDaniel m: say ‘abcdefgh’ ~~ /.** {0..-Inf}/
22:00 camelia rakudo-moar 53d7b7: OUTPUT«Range maximum in quantifier (**) cannot be -Inf␤  in block <unit> at <tmp> line 1␤␤»
22:00 AlexDaniel cool, somebody special-cased -Ing, right?
22:00 AlexDaniel m: say ‘abcdefgh’ ~~ /.** {0..NaN}/
22:00 camelia rakudo-moar 53d7b7: OUTPUT«This type cannot unbox to a native integer: P6opaque, Failure␤  in block <unit> at <tmp> line 1␤␤»
22:01 AlexDaniel but not NaN!
22:03 AlexDaniel m: say ‘abc’ ~~ /^(.** {-10..-5}) {say $0} <!>/
22:03 camelia rakudo-moar 53d7b7: OUTPUT«「abc」␤「ab」␤「a」␤「」␤Nil␤»
22:03 AlexDaniel and negative numbers are bugged
22:06 Dunearhp joined #perl6
22:17 AlexDaniel ah dammit
22:17 AlexDaniel m: say ‘abcefghij’ ~~ / .**{2..^3} /
22:17 camelia rakudo-moar 53d7b7: OUTPUT«「abc」␤»
22:17 AlexDaniel m: say (2^..^2).elems
22:17 camelia rakudo-moar 53d7b7: OUTPUT«0␤»
22:17 AlexDaniel m: say ‘abcefghij’ ~~ / .**{2..^2} /
22:17 camelia rakudo-moar 53d7b7: OUTPUT«「ab」␤»
22:17 AlexDaniel m: say ‘abcefghij’ ~~ / .**{2^..^2} /
22:17 camelia rakudo-moar 53d7b7: OUTPUT«「ab」␤»
22:22 wamba joined #perl6
22:26 RabidGravy heads up for anyone interested, there's something leaky around Capture literals - will track down and golf
22:26 RabidGravy anyone nighty night
22:27 AlexDaniel m: say ‘abcefghij’ ~~ / .**{2..1} /
22:27 camelia rakudo-moar 53d7b7: OUTPUT«Nil␤»
22:27 AlexDaniel so this doesn't match anything, makes sense?
22:27 AlexDaniel yeah
22:27 AlexDaniel m: say ‘abcefghij’ ~~ / .**{2..0} /
22:27 camelia rakudo-moar 53d7b7: OUTPUT«「abcefghij」␤»
22:27 AlexDaniel /o\
22:32 [Coke] viki: 3fd8f9d0f4a1 in perl6/doc breaks with: L«C<parse-base>/routine/parse-base» . getting a failure in 'make xtest'
22:33 [Coke] er, file is doc/Type/Real.pod6
22:33 [Coke] perl6 xt/aspell.t doc/Type/Real.pod6 shows the error.
22:33 [Coke] er, warning.
22:36 samcv is there a perl 6 module to find all url's in a text or should I make one?
22:37 El_Che samcv: make one, I use Perl5 URI::Find on some perl 5 scripts :)
22:37 samcv kk :)
22:38 kurahaupo__ joined #perl6
22:52 Vynce joined #perl6
23:06 canopus joined #perl6
23:06 dalek doc: 8b85121 | (Zoffix Znet)++ | doc/Type/Real.pod6:
23:06 dalek doc: Fix broken POD directive
23:06 synopsebot6 Link: http://doc.perl6.org/type/Real
23:06 dalek doc:
23:06 dalek doc: [Coke]++
23:06 dalek doc: review: https://github.com/perl6/doc/commit/8b85121015
23:09 seatek joined #perl6
23:13 cpage_ joined #perl6
23:17 atweiden-air is it possible to have more than one C<:my $such-and-such = 2> code block inside a grammar token?
23:20 timotimo should be possible, yeah
23:23 MasterDuke atweiden-air: https://github.com/rakudo/rakudo/b​lob/nom/src/Perl6/Grammar.nqp#L199
23:30 atweiden-air joined #perl6
23:36 atweiden-air m: https://gist.github.com/anonymous​/86f67673d67b03164956477ec6927efc
23:36 camelia rakudo-moar 53d7b7: OUTPUT«Use of Nil in string context␤  in regex abc at <tmp> line 8␤[DEBUG] $leading-whitespace: 0␤[DEBUG] real $leading-whitespace: 2␤False␤»
23:37 timotimo you may have to cause the captures to be reified with a {}
23:37 timotimo literally just {} after \h*
23:38 atweiden-air timotimo: what does reified mean in this instance?
23:40 timotimo ah, just "turned into a real thing"
23:48 lizmat joined #perl6

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

Perl 6 | Reference Documentation | Rakudo