Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2017-03-21

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:11 BenGoldberg joined #perl6
00:33 Cabanossi joined #perl6
00:38 skids joined #perl6
00:53 gdonald joined #perl6
01:03 Cabanossi joined #perl6
01:19 drbaffico joined #perl6
01:20 drbaffico can anyone please tell me where to find a proper help file for referencing syntax for perl6?
01:20 drbaffico preferrablyon the internet
01:21 drbaffico something that is easy to print and format on double page duplexed print?
01:22 drbaffico all i can find is the garbage file layout on docs.perl6.org, it is inappropriate for printing and reference
01:22 drbaffico i need a file like the .chm file for python
01:22 drbaffico thank you for any who respond. :-) ---> dr. mw baffico
01:23 raiph joined #perl6
01:24 drbaffico ralph, are you aware of more appropriate perl6 documentation for advanced syntax sutiable for printing on the web?
01:32 * skids wonders if anyone has updated the "perl6 periodic table" poster?
01:33 skids https://www.ozonehouse.com/mark/periodic/  is probably too old to promulgate.
01:34 AlexDaniel skids: just redo it from scratch? If done in .svg, every operator can link to docs
01:36 skids Well, I meant for drbaffico's immediate need.
01:36 AlexDaniel “addenoid” :DD
01:37 raiph https://docs.perl6.org/perl6.xhtml shows an error
01:39 raiph drbaffico: ignoring the error, is the big page I just linked ^^ of any use to you?
01:39 drbaffico ii'll check it out right now, thanks
01:39 aborazmeh joined #perl6
01:39 aborazmeh joined #perl6
01:41 drbaffico ahh,thanks guys, found just what i was looking for.  i appreciate it very much!!!
01:41 lucs drbaffico: Is it that page that raiph showed, or something else?
01:42 mst [Coke]: basically, it isn't relocatable currently, and I worked around that
01:42 mst [Coke]: I owe the perl6 community a proper release of that stuff though, should try and do that soon
01:42 drbaffico it was the page that ralph showed, with a link i did not see before, my error, my apologies, it is just what i was looking for.  thanks again, guys
01:43 lucs Cool
01:43 drbaffico the 'perodic' table is interesting,ifa bit quaint, but interesting, i'll look at that as well in further detail,, thanks for that
01:50 drbaffico ok, thank you guys, i'm going to log off for a while and have some dinner.  will be back later to chat, and look forward to contributing to the community.  thanks for the -> help! ;-)  and i hope you all have a nice evening/day/etc...
02:17 raiph Do others get "rendering of the page up to the first error" when viewing the single doc page (link above)?
02:18 Cabanossi joined #perl6
02:21 AlexDaniel raiph: for me it does not render at all
02:22 MasterDuke XML Parsing Error: not well-formed Location: https://docs.perl6.org/perl6.xhtml Line Number 10323, Column 43:
02:24 MasterDuke i think it's pointing out the error as here `<p>Perl 6 makes considerable use of the &171; and &187; characters.</p>`, at the 1 of the 171
02:25 raiph I'm using Chrome (Version 47.0.2526.73); I've got "error on line 10323 at column 43: xmlParseEntityRef: no name"
02:28 mr-foobar joined #perl6
02:28 MasterDuke FF 52.0
02:30 dwarring shouldn't that be:  Perl 6 makes considerable use of the &#171; and &#187; characters
02:30 dwarring ?
02:31 dwarring Perl 6 makes considerable use of the « and » characters.
02:40 dwarring source https://github.com/perl6/doc/blob/​master/doc/Language/pod.pod6#L398
02:42 raiph dwarring: https://github.com/perl6/doc/blob/​master/doc/Language/pod.pod6#L385 etc. as well?
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 pytuger why is eval('say("hey");'); in perl5 just made all caps EVAL("say('hey');");
02:51 pytuger in perl6
02:53 pytuger A subjective question since not technically related, just seems confusing. I've learned of some things that were in all caps such as  " my $var = 10; $var.WHAT.say; " but haven't noticed a pattern, was wondering if there was one.
02:54 bwisti joined #perl6
02:55 MasterDuke i think it was meant to stand out a bit more, to make it obvious something dangerous/hacky/etc is going on
02:57 MasterDuke a bunch of the other all cap functions, e.g., WHAT, HOW, WHICH are mostly meant for internal use, and probably shouldn't be seen in user code
03:04 teichner joined #perl6
03:06 cpage_ joined #perl6
03:15 mcmillhj joined #perl6
03:22 xtreak joined #perl6
03:23 BenGoldberg m: say test p5=> 42;
03:23 camelia rakudo-moar 0c6281: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Undeclared routine:␤    test used at line 1␤␤»
03:23 travis-ci joined #perl6
03:23 travis-ci Doc build passed. David Warring 'Fix rendering problem
03:23 travis-ci https://travis-ci.org/perl6/doc/builds/213254619 https://github.com/perl6/doc/commit/431d94df46be
03:23 travis-ci left #perl6
03:24 mcmillhj joined #perl6
03:24 BenGoldberg It's a comic operator because it doesn't exist :P
03:31 noganex joined #perl6
03:33 Cabanossi joined #perl6
03:34 skids \o/ Finally, I have working (but still very ugly) code to fix diamond role composition.
03:42 mcmillhj joined #perl6
03:47 mcmillhj joined #perl6
04:03 Cabanossi joined #perl6
04:04 mcmillhj joined #perl6
04:14 raiph joined #perl6
04:21 mcmillhj joined #perl6
04:26 mcmillhj joined #perl6
04:37 xtreak joined #perl6
04:42 mcmillhj joined #perl6
04:47 Cabanossi joined #perl6
04:53 wamba joined #perl6
04:59 cpage_ joined #perl6
05:17 Cabanossi joined #perl6
05:48 curan joined #perl6
05:50 drrho joined #perl6
05:52 xtreak joined #perl6
05:55 cibs joined #perl6
06:00 kurahaupo__ joined #perl6
06:01 Sgeo joined #perl6
06:24 mcmillhj joined #perl6
06:28 rindolf joined #perl6
06:37 kaare_ lizmat: How come the p6 weekly isn't in the blog section of https://perl6.org/ anymore?
06:47 mcmillhj joined #perl6
06:52 RabidGravy joined #perl6
06:58 setty1 joined #perl6
06:58 domidumont joined #perl6
07:03 mcmillhj joined #perl6
07:06 domidumont joined #perl6
07:12 wamba joined #perl6
07:16 xtreak joined #perl6
07:31 mcmillhj joined #perl6
07:32 abraxxa1 joined #perl6
07:32 Cabanossi joined #perl6
07:40 sukrishn joined #perl6
07:45 darutoko joined #perl6
07:45 moritz probably some RSS feed messup
07:46 moritz they are also missing from http://pl6anet.org/ :(
07:46 rindolf joined #perl6
07:47 wdna joined #perl6
07:48 wdna good morning
07:51 moritz good morning wdna
07:52 mcmillhj joined #perl6
07:57 cpage_ joined #perl6
08:02 bjz joined #perl6
08:06 dct joined #perl6
08:07 nine lizmat-- # stealing half an hour of my time with the weekly
08:07 nine lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ lizmat++ # giving me 30 minutes of fun with the weekly
08:08 jast oh noes, karma spam
08:09 mcmillhj joined #perl6
08:28 grumble joined #perl6
08:29 * lizmat clickbaits https://p6weekly.wordpress.com/2017​/03/20/2017-12-how-to-race-a-hyper/  , to make things worse :-)
08:35 lizmat .tell stmuk_ is there a reason why the P6W is no longer syndicated to http://pl6anet.org ?
08:35 yoleaux lizmat: I'll pass your message to stmuk_.
08:35 mcmillhj joined #perl6
08:37 dakkar joined #perl6
08:44 zakharyas joined #perl6
08:45 zacts joined #perl6
08:47 Cabanossi joined #perl6
08:49 mcmillhj joined #perl6
09:05 mcmillhj joined #perl6
09:10 sukrishn joined #perl6
09:16 sukrishn joined #perl6
09:24 mcmillhj joined #perl6
09:27 xtreak joined #perl6
09:31 xiaomiao joined #perl6
09:38 wamba joined #perl6
09:39 mcmillhj joined #perl6
09:48 dakkar TIL: the invocant can be rw https://gist.github.com/dakkar/f​a26e2b816f92d494b79fb89e891fcd0
10:00 IOninja Yup. That's how Str.subst-mutate does it
10:03 mcmillhj joined #perl6
10:03 IOninja pytuger: eval is Perl 5 is frequent. In Perl 6 is rare. We have `try` replacing most of Perl 5's eval usage and. Leaving just the dangerous stuff for EVAL, and so it's in caps, to stand out.
10:06 IOninja .ask gfldex why does Podtobig page generate perl6.xhtml? We use HTML, not XML. The bogus extension is causing parse errors: https://irclog.perlgeek.de/​perl6/2017-03-21#i_14298152
10:06 yoleaux IOninja: I'll pass your message to gfldex.
10:18 astj joined #perl6
10:18 astj joined #perl6
10:23 IOninja .tell gfldex here's what it looks like in Firefox: http://i.imgur.com/0v67PIa.png The idiocy of using XHTML instead of HTML was common because people were too stupid to know how to kick IE6 out of quirksmode with a proper HTML doctype and it was never a right thing to use.
10:23 yoleaux IOninja: I'll pass your message to gfldex.
10:24 Geth ¦ doc: 5bd81fb834 | (Zoffix Znet)++ | doc/Language/pod.pod6
10:24 Geth ¦ doc: Work-around bug that incorrectly interprets E<> entities
10:24 Geth ¦ doc:
10:24 Geth ¦ doc: - Closes #1255
10:24 Geth ¦ doc: - Fixes rendering issue in perl6.xhtml (though it's still needs to be changed away from xhtml)
10:24 Geth ¦ doc: review: https://github.com/perl6/doc/commit/5bd81fb834
10:24 IOninja s/Work-around//;
10:24 IOninja No point in using an E<> there.
10:28 hobbs or, people used xhtml because it was nice actually being able to process HTML without having to have an utterly insane massive parser, at least if you knew its provenance :)
10:30 IOninja Nope, daily someone would come to #css with XHTML doctype and when asked why it was 'cause IE6
10:31 xtreak joined #perl6
10:31 hobbs So clearly I don't exist. Thanks.
10:33 mxco86 joined #perl6
10:34 masak I think I've heard the "being able to process" argument before. it's an interesting one.
10:34 masak but to me the "browser just choked" argument is fairly overriding -- YMMV
10:36 IOninja .ask gfldex does Pod::To::Big page do any processing? Pod::To::HTML outputs E<171> as &#171; but on perl6.xhtml it ended up as &171; (not the missing #).
10:36 yoleaux IOninja: I'll pass your message to gfldex.
10:40 xtreak joined #perl6
10:42 timotimo nine: which part of the weekly was the one that gave you so much fun?
10:44 moritz fwiw the IRC logs use content negotiation, and emit strict xml/xhtml when the browser wants it
10:45 moritz it has helped me find a few places where the (x)html escaping wasn't working
10:46 IOninja And HTML validator wouldn't helped?
10:47 masak does anyone know of a good *offline* HTML validator? all HTML validators I've found are some online service somewhere...
10:48 moritz masak: iirc you can download the one that w3.org uses
10:48 masak aye, I did find that one
10:48 masak it's written in Perl 5
10:57 tojo joined #perl6
10:59 Sgeo joined #perl6
11:07 sukrishn joined #perl6
11:12 nine masak: though if you need to validate HTML 5, you'll also need the one from validator.nu (written in Java). The w3c-validator will act as frontend then.
11:13 cpage__ joined #perl6
11:17 Cabanossi joined #perl6
11:44 masak nine: ah, and it's on Github: https://github.com/validator/validator
11:50 zakharyas joined #perl6
12:06 abraxxa joined #perl6
12:17 bjz_ joined #perl6
12:21 Geth ¦ modules.perl6.org: 025f677ec7 | (Zoffix Znet)++ | lib/ModulesPerl6/DbBuilder/Dist/Source.pm
12:21 Geth ¦ modules.perl6.org: Log a warning when `tags` META key isn't an array
12:21 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/025f677ec7
12:27 Geth ¦ modules.perl6.org: 9ecae4736c | (Zoffix Znet)++ | lib/ModulesPerl6/DbBuilder/Dist/Source.pm
12:27 Geth ¦ modules.perl6.org: Fix typo
12:27 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/9ecae4736c
12:29 raschipi joined #perl6
12:30 Geth ¦ modules.perl6.org: 4469e6a1e4 | (Zoffix Znet)++ | 2 files
12:30 Geth ¦ modules.perl6.org: [REBUILD] uniq tags of a dist
12:30 Geth ¦ modules.perl6.org:
12:30 Geth ¦ modules.perl6.org: Since the mangler may normalize multiple listed tags to the same tag.
12:30 Geth ¦ modules.perl6.org:
12:30 Geth ¦ modules.perl6.org: Fixes the last 7 UNIQUE constraint db errors.
12:30 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/4469e6a1e4
12:30 hord joined #perl6
12:32 Geth ¦ modules.perl6.org: bc576c5364 | (Zoffix Znet)++ | lib/ModulesPerl6/Controller/Root.pm
12:32 Geth ¦ modules.perl6.org: Fix undef uc warning in controller
12:32 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/bc576c5364
12:36 spebern joined #perl6
12:42 spebern left #perl6
12:43 IOninja "Since Perl 6 is a bit new, this LWP::Simple does both get and post requests." wat
12:43 IOninja That's LWP::Simple's readme
12:43 timotimo wants an "only"?
12:44 IOninja $ zef install LWP:Simple
12:44 IOninja Enabled fetching backends [git path wget curl] don't understand LWP:Simple
12:45 IOninja You may need to configure one of the following backends, or install its underlying software - [pswebrequest]
12:45 IOninja hm wtf... I do have wget git and curl :/
12:45 lizmat LWP::Simple ?
12:45 IOninja Yeah
12:45 lizmat not LWP:Simple
12:45 lizmat : vs :: ?
12:45 IOninja lizmat++
12:46 IOninja And I kept hitting "up" key and reusing the same typo even after upgrading zef :)
12:46 timotimo it could point out that LWP was being interpreted as a protocol name rather than part of the module name
12:46 lizmat yeah,. been there, done that :-)
12:46 timotimo like "can't grab module Simple with protocol LWP. only can handle http, https, git, ssh, ..."?
12:49 mcmillhj joined #perl6
12:49 cyphase joined #perl6
12:56 IOninja .tell gfldex Never mind. Found and fixed the issue in https://github.com/perl6/perl6-pod-to-bigpage/c​ommit/ed9c1a489640ce600b7901f1e1a878ca5ffcfee9 (P.S.: I didn't mean you were an idiot for using XHTML in my previous msg; but I'd still recommend using HTML5 doctype in Pod2BigPage)
12:56 yoleaux IOninja: I'll pass your message to gfldex.
13:02 ggoebel joined #perl6
13:06 * [Coke] yawns.
13:06 hord is there an easy way to see if a module is loaded?  like checking %INC in p5?
13:07 IOninja hord: you can use if ::('Module::Name') ~~ Failure { say "not loaded" } 90% of the time
13:07 IOninja hord: the place where it won't work is if someone did `require Module::Name` earlier. ^ that won't be a failure, even if the module failed to load
13:08 abraxxa joined #perl6
13:08 hord yeah, i'm doing require
13:08 IOninja hord: and I guess the proper-proper way would be to use the CompUnit API
13:08 IOninja hord: oh, you're just optionally loading something?
13:09 IOninja hord: here's info on how to optionally load stuff: http://rakudo.org/2017/03/18/​lexical-require-upgrade-info/
13:09 hord yes.  i need to optionally load a module and then check to see if it's loaded later when creating a closure.
13:09 IOninja try require ::('Foo');   …  if ::('Foo') !~~ Failure { say "module is loaded" }
13:10 IOninja note that that's lexically scoped.
13:10 eroux joined #perl6
13:10 kurahaupo__ joined #perl6
13:11 robertle joined #perl6
13:13 Sound joined #perl6
13:13 Sound_ joined #perl6
13:13 IOninja timotimo: jnthn the very last example in this doc looks like kinda iffy. Is it sane to use state/runtime require with subsets? https://docs.perl6.org/language/typesystem#subset
13:14 timotimo if it is, it's only in a non-multithreaded program
13:15 timotimo the state there is just to cache it so it won't have to do the lookup later i guess?
13:15 hord wow, i forgot i actually have booleans now
13:15 IOninja :)
13:16 hord this is working:  my $mob = %wurm<mob> // ::('Wvrm::mob') !~~ Failure;
13:16 IOninja uuhh
13:16 IOninja Well, it looks really weird :) Are you sure it's working?
13:17 IOninja $mob is just an indicator that the stuff got loaded?
13:17 hord not really
13:17 hord it's an indicator from the caller that a particular semantics are to be used
13:17 Sound_ joined #perl6
13:17 hord it assumes the module was loaded earlier and would actually be used to turn off default behavior
13:17 IOninja Ah
13:18 hord but now my closure isn't working so onward!
13:18 ugexe CUR has a .loaded method that lists what it has loaded
13:19 ugexe but youll have to iterate a list two or so levels deep
13:19 ugexe $*REPOs.repo-chain.map(*.loaded) or some such
13:30 Geth ¦ doc: 86b4228999 | (Zoffix Znet)++ | doc/Language/modules.pod6
13:30 Geth ¦ doc: Update `require` section
13:30 Geth ¦ doc:
13:30 Geth ¦ doc: - require is now lexical, so toss the routine-loaded module examples
13:30 Geth ¦ doc: - Make it clear require is lexical, including the symbol that's been required
13:30 Geth ¦ doc: - Include examples of correct checking for whether a module got loaded
13:30 Geth ¦ doc: review: https://github.com/perl6/doc/commit/86b4228999
13:32 Actualeyes joined #perl6
13:33 mcmillhj joined #perl6
13:34 itaipu joined #perl6
13:35 IOninja .ask jnthn would you check the very last example on this page? https://docs.perl6.org/language/typesystem#subset I vaguelly recall you saying subsets can be evaluated at compile time, so if relying on runtime stuff all bets are off: https://docs.perl6.org/language/typesystem#subset
13:35 yoleaux IOninja: I'll pass your message to jnthn.
13:35 SmokeMachine IOninja: do you think "Fix #131009\ntriangle reduce with listinfix wasn't working" is a good enough commit msg?
13:35 synopsebot6 Link:  https://rt.perl.org/rt3//Publ​ic/Bug/Display.html?id=131009
13:36 IOninja SmokeMachine: it's terrible
13:36 SmokeMachine :(
13:36 SmokeMachine Im not good at that...
13:38 IOninja SmokeMachine: here: https://perl6.fail/release/stats click on "Commits" tab. Imagine you're filling out the ChangeLog. You need to tell the users of Rakudo what changed. Then go through the list and write down the changes. You'll learn quick which commits suck :)
13:38 IOninja *commit messages
13:38 ugexe timotimo: zef doesn't know what protocols its fetching backends support - it just asks any backends you list in your config "do you understand this string?". Otherwise it was hard to support syntax like `zef -v install github:ugexe:zef:0.1.5` (the urn-like format, briefly mentioned in s22) and handle C:/
13:38 timotimo ah
13:38 ugexe re why it can't guess the error at protocol level
13:38 timotimo makes sense
13:39 timotimo each fetching backend needs to get levenshtein implemented for it :P
13:39 aborazmeh joined #perl6
13:39 aborazmeh joined #perl6
13:40 IOninja SmokeMachine: first, don't put the ticket in the title. Some stuff only shows the title (e.g. https://github.com/rakudo/rakudo/commits/nom ), so just the ticket number doesn't say what changed. As for the message itself, well, most of the stuff is fixing something that wasn't working. What does "wasn't working" mean?
13:41 IOninja SmokeMachine: I also like to write down what was broken and how I fixed it, so that 3 years from now people don't look at the commit wondering if some line change or changed behaviour was intentional or not.
13:42 eroux joined #perl6
13:45 SmokeMachine IOninja: "Fix triangle reduction with listinfix ops\nThe triangle reduction was appending the data inside of a array and applying the op on that. It was changed to push the data and apply the op on that array with each item deconted" better?
13:45 IOninja SmokeMachine: yeah, that's great. And mention the ticket number at the end
13:45 SmokeMachine IOninja: ok! thanks!
13:46 mcsnolte joined #perl6
13:47 Cabanossi joined #perl6
13:48 SmokeMachine IOninja: https://github.com/FCO/rakudo/commit/16​f950b30572e0fa584ddfab1e84e5ef0ca5dfc9
13:49 IOninja Great.
13:49 * IOninja &
13:49 hord How would I construct a class so that it acts like a class and a hash?
13:50 hord e.g. $foo<bar> ~ $foo.bar()
13:50 timotimo implement the Associative role i guess?
13:51 raschipi hord: It needs to implement the assossiative role
13:51 ugexe timotimo: searching meta data is centralized in another backend. but for levenshtein on the uri... doesnt perl6 have a built in exposed still? StrDistance or something...
13:52 timotimo that's something different
13:52 timotimo that's what we use to provide the integer return value to tr///
13:54 skids joined #perl6
13:55 hord unit class Wvrm::mob does Associative;  # do i need something more here?  i keep getting "Associative indexing implementation missing from type Wvrm::mob"
13:56 ilmari hord: you need to implement the methods required by Associative
13:56 hord where is this documented?  i come with nothing on google.
13:57 IOninja hord: https://docs.perl6.org/language/subscripts
13:57 IOninja timotimo: StrDistance was levenshtein distance last I looked :/
13:57 timotimo oh?
13:57 ilmari hord: specifically https://docs.perl6.org/language/subscripts#Met​hods_to_implement_for_associative_subscripting
13:57 IOninja timotimo: oh, looking at source now, maybe I just *assumed* it was
13:58 timotimo you're right
13:58 timotimo which one was the tr-related one :\
13:59 timotimo huh, it is both
13:59 [Coke] m: unit class Wvrm::mob does Associative; # works here
13:59 camelia rakudo-moar e5528d: ( no output )
13:59 IOninja timotimo: it does use StrDistance, looks like: https://github.com/rakudo/rakudo/bl​ob/nom/src/Perl6/Actions.nqp#L7866
14:00 hord would it be easier to add methods to a Hash?
14:00 timotimo it's very easy to apply a role to a hash object if you mean that
14:00 hord this looks like a nightmare to delegate to attributes
14:00 timotimo do you know about "handles"?
14:00 hord i want a hash object that acts like objects just like in perl 5
14:01 hord so i can use it as a hash or call methods on it
14:01 timotimo but you can already call methods on a hash
14:01 hord so do i need to sub-class Hash to make another object?
14:01 IOninja hord: you can give it a go.
14:01 timotimo do you want a method ".foo()" to grab the "foo" key out of the hash?
14:01 hord i have an API that can use either objects or hashes (perl 5)
14:01 hord i'm converting it to perl 6 so i need to retain that behavior
14:02 IOninja Heh
14:02 timotimo i'm not sure what "can use" means in this context
14:02 timotimo do you need an object that does both, or can you just differentiate on whether it's a hash or an object?
14:02 hord in perl 5 i just get a variable (scalar)
14:02 IOninja It's a differnt beast in perl 5, since objects use hash (or other type) as underlying structure :)
14:02 hord i don't want to have to differentiate
14:03 hord in one context i want to ALWAYS assume it is a hash
14:03 IOninja hord: don't you have to implement like 3 methods for it to work just fine with Associative role?
14:03 hord yes, but i have to delegate to the attributes which doesn't seem nice
14:03 IOninja hord: well, sounds like subclassing Hash or mixing in a role into it makes the most sense.
14:03 hord at least as how i understand it
14:04 * IOninja isn't sure what delegation there is to do
14:04 timotimo https://docs.perl6.org/language/typesy​stem#index-entry-handles_trait-handles
14:04 timotimo did we implement "handles Role" yet?
14:05 IOninja m: dd Hash ~~ Iterable
14:05 camelia rakudo-moar e5528d: OUTPUT: «Bool::True␤»
14:05 IOninja m: say class :: does Associative {} ~~ Iterable
14:05 camelia rakudo-moar e5528d: OUTPUT: «False␤»
14:05 IOninja You'd need more than just Associative to emulate a hash, so subclassing/mixinging roles makes sense
14:07 IOninja hord: IIRC we didn't yet sort out the whole subclassing business for userspace, so you may need to implement your own `new` if you're adding attributes
14:07 hord i think i'm thinking inside out
14:07 hord what i'm doing is weird because it's a direct port of perl 5
14:08 IOninja m: class BetterHash is Hash { has $.food = 'Tuna'; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b"; dd $h<a>; dd $h; dd $h.food
14:08 camelia rakudo-moar e5528d: OUTPUT: «Str <element> = "b"␤BetterHash $h = ${:a("b")}␤Any␤»
14:09 IOninja Yeah, didn't init it
14:09 IOninja m: class BetterHash is Hash { has $.food = 'Tuna'; method new { self.Mu::new: |%_ }; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b"; dd $h<a>; dd $h; dd $h.food
14:09 camelia rakudo-moar e5528d: OUTPUT: «Too many positionals passed; expected 1 argument but got 2␤  in method new at <tmp> line 1␤  in block <unit> at <tmp> line 1␤␤»
14:09 hord well now i get a different error.  progress?
14:10 IOninja eh, right
14:11 * skids yawns and tries to get some motivation up for $DAYJOB
14:11 cdg joined #perl6
14:11 skids https://gist.github.com/skids/1​8fa6fb1de776400abd43b6e82e9fcc2 # needs a lot of review.
14:12 IOninja m: class BetterHash is Hash { has $.food; submethod TWEAK (:$!food = 'Tuna'){}; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b"; dd $h<a>; dd $h; dd $h.food
14:12 camelia rakudo-moar e5528d: OUTPUT: «Str <element> = "b"␤BetterHash $h = ${:a("b")}␤Any␤»
14:12 IOninja crap right
14:12 bjz joined #perl6
14:15 itaipu joined #perl6
14:17 Cabanossi joined #perl6
14:17 IOninja m: class { method x (|) { |%_ } }.x
14:17 camelia rakudo-moar e5528d: OUTPUT: «Type check failed in binding to 'x'; expected Any but got Mu (Mu)␤  in method x at <tmp> line 1␤  in block <unit> at <tmp> line 1␤␤»
14:17 IOninja lol?
14:18 IOninja m: class BetterHash is Hash { has $.food; method new (|c) { self.bless(|%_).STORE(|c); }; submethod TWEAK (:$!food = 'Tuna'){}; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b"; dd $h<a>; dd $h; dd $h.food
14:18 camelia rakudo-moar e5528d: OUTPUT: «Cannot call method 'FLATTENABLE_LIST' on a null object␤  in method new at <tmp> line 1␤  in block <unit> at <tmp> line 1␤␤»
14:18 IOninja same cause, I believe
14:18 IOninja m: class { method x (*%_, |c) { |%_ } }.x
14:18 camelia rakudo-moar e5528d: ( no output )
14:19 IOninja m: class BetterHash is Hash { has $.food; method new (*%_, |c) { self.bless(|%_).STORE(|%_, |c); }; submethod TWEAK (:$!food = 'Tuna'){}; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b"; dd $h<a>; dd $h; dd $h.food
14:19 camelia rakudo-moar e5528d: OUTPUT: «Str <element> = "b"␤BetterHash $h = ${:a("b")}␤"Tuna"␤»
14:19 IOninja Yey \o/
14:20 IOninja m: class BetterHash is Hash { has $.food; method new (*%_, |c) { self.bless(|%_).STORE(|%_, |c); }; submethod TWEAK (:$!food = 'Tuna'){}; method meows { "Ketteh {"♥" x self.keys} $!food" } }; my $h = BetterHash.new: "a" => "b", food => 'Whitefish'; dd $h<a>; dd $h; dd $h.food
14:20 camelia rakudo-moar e5528d: OUTPUT: «Str <element> = "b"␤BetterHash $h = ${:a("b")}␤"Whitefish"␤»
14:20 IOninja hord: well, something like that perhaps will work. You don't need the `method new` stuff unless you need to set public attributes
14:22 hord let me try it.  i think i may need the new() stuff.  i can make objects but they are empty right now.
14:25 raschipi There's no lists of lists anymore
14:25 IOninja What are you talking about?
14:28 IOninja skids: man, I hate "face" even more than "interface". Reminds me of Sleeping Dogs game.
14:28 skids Yeah, well, bikeshedding welcome... it's more or less a s/// to change it.
14:29 IOninja m: role A { method x {say "B"} }; role B { method x {say "B"} }; class :: does A does B { }.x.say
14:29 camelia rakudo-moar e5528d: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Method 'x' must be resolved by class <anon|57747248> because it exists in multiple roles (B, A)␤at <tmp>:1␤»
14:29 IOninja skids: what's the ticket to Ovid's stuff? I only recall the one about multi candidates
14:29 cdg joined #perl6
14:29 skids Yeah I think he was laboring under some confusion about that part.  Hold on.
14:31 Khisanth joined #perl6
14:32 skids https://justrakudoit.wordpress.c​om/2015/03/07/role-inheritance/ is colomon's part and links back to IRC.
14:33 skids https://github.com/perl6/specs/issues/80 Ovid's issue.
14:34 IOninja "To my mind they are completely different things, and if someone re-orders role “inheritance” without considering the consequences, they deserve what they get."
14:34 * IOninja nods in agreement to that statemnt
14:35 skids Well, in this solution, they only "deserve what they get" if they do it despite seeing an "is face".
14:35 skids The root of the problem is the method overrides, not really the ordering.
14:37 IOninja Well, I know nothing about this stuff, so ignore my comments :)
14:37 skids Heh.  I'm grateful for any attention even from you :-)
14:39 obfusk joined #perl6
14:43 jnthn fwiw, I think we'd speculated a "claim" scope declarator rather than a trait in the past
14:43 yoleaux 13:35Z <IOninja> jnthn: would you check the very last example on this page? https://docs.perl6.org/language/typesystem#subset I vaguelly recall you saying subsets can be evaluated at compile time, so if relying on runtime stuff all bets are off: https://docs.perl6.org/language/typesystem#subset
14:43 jnthn I think I even had a branch where I played with that a bit, but if it still exists it'll be ancient by now
14:44 sena_kun joined #perl6
14:44 jnthn Yes, it's still here, as claim-prototype
14:46 IOninja `claim method foo` does sound much nicer than `method foo is face`
14:46 jnthn I think TimToady++ came up with the name :)
14:47 skids That was to be applied in a different place and with a different sense.  And it was pointed out that it only "kicked the can down the road"
14:47 skids This attribute is applied where someone might try to modify code and expect that modifcatio to promulgate, and is there when it won't necessarily promulgate, as a warning.
14:48 jnthn IOninja: I don't think we can just blindly go checking any subset at compile time; I suspect only those that we can infer as being pure would be candidates
14:48 skids (regardless of the name)
14:48 IOninja jnthn: thanks.
14:48 jnthn However, that use of state is dodgy there
14:48 jnthn If you try to use the subset type from multiple threads you could get surpious failures
14:49 itaipu joined #perl6
14:49 jnthn So it's risky and clouds the example with a premature optimization
14:49 jnthn So I'd get rid of that
14:49 jnthn just where ::('...')
14:49 hord $self.STORE(env  => $meal<env>);  # too few positionals?  expected 2 but got 1?
14:49 hord that doesn't even make any sense to me
14:49 Geth ¦ doc: 59f692564b | (Zoffix Znet)++ | doc/Language/typesystem.pod6
14:49 Geth ¦ doc: Toss risky `state`
14:49 Geth ¦ doc:
14:49 Geth ¦ doc: https://irclog.perlgeek.de/​perl6/2017-03-21#i_14300672
14:49 Geth ¦ doc: review: https://github.com/perl6/doc/commit/59f692564b
14:50 jnthn hord: The invocant ($self) is the first parameter
14:50 IOninja hord: that probably expects a Pair? Try $self.STORE("env"  => $meal<env>)
14:50 hord jnthn: then it should have received 3
14:51 IOninja hord: only in Perl 5.
14:51 IOninja hord: you're sending it a named argument `env`. So it complains it's missing a positional
14:51 hord so what does => do now?
14:51 IOninja Whereas if you quote the key, as "env"  => $meal<env>, you're sending it 1 positional argument: a Pair
14:51 hord since it apparently doesn't auto-quote
14:51 sukrishn joined #perl6
14:52 IOninja hord: it does, if you use it with Hashes or Maps. But in arguments list, an unquoted ones are passed as named arguments
14:53 IOninja hord: https://docs.perl6.org/lang​uage/traps#Named_Parameters
14:53 hord there's way too much to learn to do simple ports
14:54 IOninja buggable: eco Inline::Perl5
14:54 buggable IOninja, Inline::Perl5 'Use Perl 5 code in a Perl 6 program': https://github.com/niner/Inline-Perl5
14:54 IOninja hord: ^ there's always that
14:54 IOninja hord: my personal opinion is making a naive "port" will produce garbage. Because languages are so different.
14:55 hord a naive port of easy software also exposes a lot of weaknesses
14:55 IOninja You're basically porting a Hash with a few hacks to make it work like a class to a proper OOP system
14:56 IOninja hord: not really, you're just trying to use a different language under the paradigms of Perl 5. Hardly something I'd call a weakness.
14:56 IOninja m: say so "0"
14:56 camelia rakudo-moar e5528d: OUTPUT: «True␤»
14:56 IOninja ^ that statement is all I need to show just how different the languages are.
14:57 IOninja Thinking you can just tweak a few sigils and get working code is a bit delusional.
14:57 hord IOninja: that's not what i think
14:57 IOninja (and there are "converters" that try to do just that and they suck)
14:57 IOninja hord: OK :)
14:57 hord but perl 6 has become quite the stranger to perl 5 that it once was
14:57 IOninja hord: most definitely. It's closer to Ruby than to Perl 5
15:00 hord so i guess for this sub-class i have both attributes and keys... but i want them to be the same
15:00 hord that's what i don't get
15:01 skids jnthn: anyway, inverting the sense would not be hard and then "claim" would instead mean "I don't want this method overridden by my users" rather than "This is my eggo now." I don't know if "claim role A" works as well as the method variety, though.
15:02 IOninja hord: right, and in Perl 5 that class is just a blessed hash innit? And you can't have attributes that AREN'T keys (without some sort of clever hack), etc. In Perl 6 you can.
15:03 skids That would require less people to mod code, but more building awareness/expectations for role users that want purity, telling them they have to use "claim" to get purity warnings.
15:03 hord IOninja: perl 5 doesn't have "attributes" so you can do whatever you want
15:03 IOninja hord: so maybe it'd make sense for you to not have attributes, but to just use the keys as if they were attributes?
15:03 hord personally i'm tired of "attributes"
15:03 IOninja So don't use 'em :)
15:03 hord i just want data slots with some code around them
15:03 DrForr You can bless things that aren't hash references, at least in perl 5.
15:04 hord yeah, i think i just want methods
15:04 IOninja DrForr: I know that, but I'm talking specifically about hord's class
15:04 DrForr Ah.
15:04 hord wiring this stuff up just doesn't have the same feel to it
15:05 IOninja m: class BetterHash is Hash { method FALLBACK ($name, |) { self.{$name} }; method meows { "Ketteh {"♥" x self.keys} {self.food}" } }; my $h = BetterHash.new: "a" => "b", "food" => 'Whitefish'; dd $h<a>; dd $h; dd $h.food
15:05 camelia rakudo-moar e5528d: OUTPUT: «Str <element> = "b"␤BetterHash $h = ${:a("b"), :food("Whitefish")}␤"Whitefish"␤»
15:05 El_Che Looking at atom at work for perl 6: I see 3 perl6 packages. language-perl6 (by samcv iirc), language-perl6fe (by madcapjake) and atom-perl6-editor-tools (by azawawi). Do we know if one of those is obsolete of incompatible with the rest?
15:06 El_Che (with docs for new users in mind)
15:06 IOninja El_Che: language-perl6fe is
15:06 IOninja language-perl6 is its replacement
15:06 IOninja huggable: atom ide
15:06 huggable IOninja, https://github.com/perl6/Atom-as-a-Perl6-IDE
15:06 El_Che that's what I though
15:06 jnthn skids: Yeah, I need to read what you wrote more carefully and think about it some more, but I'm tied up with $other-job stuff today
15:06 El_Che is the fe version abandoned? and if so, can we remove it from atom
15:07 El_Che most people will install it because it has more installs (chicken-egg)
15:07 hord what is ($name, |) ?  the , | confuses.
15:07 skids jnthn: thanks, same here, really should be focusing on 'teh jawb'
15:07 IOninja El_Che: it is in my opinion. language-perl6 is a hostile fork of it, because author was unresponsive... language-perl6
15:07 lizmat it captures whatever extra parameters you sent
15:08 IOninja hord: a Capture
15:08 IOninja huggable: Capture
15:08 huggable IOninja, Argument list suitable for passing to a Signature: https://docs.perl6.org/type/Capture
15:08 IOninja hord: in this case, it's anonymous and makes the method ignore all the extra args.
15:08 lizmat what IOninja said  :-)
15:10 El_Che and looking at the doc, is https://atom.io/packages/atom-perl6-editor-tools the only prviding sytnax check
15:10 El_Che I'll enable language-perl and editor tools to see if they work together
15:10 IOninja El_Che: more detailed expl: https://github.com/github/linguist​/pull/3377#issuecomment-267050328
15:11 gdonald joined #perl6
15:11 El_Che IOninja: thx
15:11 hord is FALLBACK special?  it doesn't seem to be getting called.
15:12 hord wait... i'm dumb
15:12 IOninja hord: it's like Perl 5's AUTOLOAD (or whatever it was): https://docs.perl6.org/language/typesy​stem#index-entry-FALLBACK_%28method%29
15:12 hord it helps if you remove the attributes with the same names.  DUH.
15:12 IOninja heh
15:12 hord ok... this thing actually works now
15:13 hord but i'm still confused about bless()
15:13 wamba joined #perl6
15:13 hord method new(Hash $meal={}) { my $self = self.bless(); ... }
15:13 El_Che IOninja: you're a man of keeping details. Good summary of the events
15:13 IOninja hord: method new(Hash $meal={}) { my $self = self.bless(|$meal); ... }
15:13 hord how can i just pass $meal to bless() and have $self copy all the attributes or just bless the hash
15:14 hord |$meal explodes the hash container?
15:14 IOninja hord: I thought you didn't want any attributes?
15:14 IOninja hord: it slips the keys/values into bless; keys are names of attributes and values are their values
15:14 itaipu joined #perl6
15:14 cdg_ joined #perl6
15:14 hord not attributes... keys
15:14 hord see... i don't think about attributes.. they are just data buckets to me
15:15 hord probably too much javascript
15:15 IOninja hord: well, then you don't really need method new() at all, eh? The default Hash's one does just fine doesn't it?
15:15 hord honestly, that's what i want... javascript with perl 5 syntax
15:15 IOninja heh
15:15 hord IOninja: i'm actually adding a couple of things so having new is required.
15:16 IOninja hord: adding things like what?
15:16 hord a few more keys to the hash
15:16 IOninja You don't need new for that
15:16 IOninja 1 sec
15:16 IOninja m: class BH is Hash {}; dd BH.new: "a" => "b", :42c;
15:16 camelia rakudo-moar e5528d: OUTPUT: «{:a("b")}␤»
15:16 IOninja Well, maybe you do, if you don't want ^ that to happen.
15:17 SmokeMachine whats the op ^^?
15:17 hord here's what i'm doing... this is a plack framework.  i want requests to either be objects or hashes based on performance constraints.
15:18 IOninja m: class BH is Hash { method new (*@_, *%_) { nextwith |@_, |%_.pairs } }; dd BH.new: "a" => "b", :42c;
15:18 camelia rakudo-moar e5528d: OUTPUT: «{:a("b"), :c(42)}␤»
15:18 hord so if you decide you want objects, more classes are loaded and each request is wrapped in an object with even more objects embedded inside.
15:18 hord so that's why i want this hash/obj thing
15:18 IOninja m: class BH is Hash { method new (*@_, *%_) { nextwith |@_, |%_.pairs }; submethod TWEAK { self.<MEOWS!> = "♥" } }; dd BH.new: "a" => "b", :42c;
15:18 camelia rakudo-moar e5528d: OUTPUT: «{:a("b"), :c(42)}␤»
15:18 IOninja really?
15:18 IOninja Oh right the Hash.new messes with build bleh
15:19 IOninja m: class BH is Hash { method new (*@_, *%_) { my \self = callwith |@_, |%_.pairs; self.<MEOWS!> = "♥"; self } }; dd BH.new: "a" => "b", :42c;
15:19 camelia rakudo-moar e5528d: OUTPUT: «===SORRY!===␤Lexical 'self' already declared␤»
15:19 IOninja m: class BH is Hash { method new (*@_, *%_) { my \SELF = callwith |@_, |%_.pairs; SELF.<MEOWS!> = "♥"; SELF } }; dd BH.new: "a" => "b", :42c;
15:19 camelia rakudo-moar e5528d: OUTPUT: «{"MEOWS!" => "♥", :a("b"), :c(42)}␤»
15:19 IOninja hord: like that?
15:20 IOninja hord: normally you don't need your own method new to do some initializtion. There's submethod TWEAK you could use (like my first example above). But the reason it didn't work here is because Hash.new is a bit antisocial ATM and doesn't go through the full build sequence.
15:21 * IOninja &
15:21 jnthn hord: I'm not sure which you're assuming is cheaper: hashes or objects?
15:21 hord jnthn: in perl 5, hashes.
15:22 hord i don't actually care about perl 6, yet
15:22 jnthn OK. In Perl 6, objects.
15:22 hord this is a direct port to learn
15:22 hord then i will optimize to learn the perl 6 way
15:22 hord i know i am making this harder on myself.  that's the point.
15:22 hord if i wanted easy, i'd already be done :)
15:22 jnthn :-)
15:23 jnthn Yeah, Perl 6 just considers hashes and objects as very different things
15:23 hord yeah.  very, very different.
15:23 jnthn Both at a language level and an implementation level
15:23 hord i guess i should have expected that
15:29 MilkmanDan joined #perl6
15:29 st_elmo joined #perl6
15:29 alimon joined #perl6
15:38 SmokeMachine m: my &op = &infix:<X>; say [\&op](<1 2 3>, <10 11 12>)
15:38 camelia rakudo-moar e5528d: OUTPUT: «Potential difficulties:␤    To pass an array, hash or sub to a function in Perl 6, just pass it as is.␤    For other uses of Perl 5's ref operator consider binding with ::= instead.␤    Parenthesize as \(...) if you intended a capture of a single v…»
15:38 SmokeMachine m: my &op = &infix:<X>; say [\ &op](<1 2 3>, <10 11 12>)
15:38 camelia rakudo-moar e5528d: OUTPUT: «Invocant requires a type object of type List, but an object instance was passed.  Did you forget a 'multi'?␤  in block <unit> at <tmp> line 1␤␤»
15:39 SmokeMachine ???
15:39 SmokeMachine m: my &op = &infix:<X>; say [\\&op](<1 2 3>, <10 11 12>)
15:39 camelia rakudo-moar e5528d: OUTPUT: «Potential difficulties:␤    To pass an array, hash or sub to a function in Perl 6, just pass it as is.␤    For other uses of Perl 5's ref operator consider binding with ::= instead.␤    Parenthesize as \(...) if you intended a capture of a single v…»
15:39 jnthn I think it needs to be [\[&op]]
15:39 jnthn To be recognized as a reduce meta-op
15:40 SmokeMachine m: my &op = &infix:<X>; say [\[&op]](<1 2 3>, <10 11 12>)
15:40 camelia rakudo-moar e5528d: OUTPUT: «((1 2 3) ((1 10) (1 11) (1 12) (2 10) (2 11) (2 12) (3 10) (3 11) (3 12)))␤»
15:40 SmokeMachine jnthn: thanks!
15:43 lukaramu joined #perl6
15:45 captain-adequate joined #perl6
15:46 TheovdH joined #perl6
15:54 * IOninja eyes IO::CatPath/::CatHandle with skepticism
15:55 lizmat IOninja: conceptually, or implementationally ?
15:55 IOninja If it weren't for IO::ArgFiles, I'd definitely say module space... but then, if we're doing IO::ArgFiles thing, may as well generalize it?
15:55 IOninja lizmat: conceptually.
15:55 lizmat that was my idea, yes
15:56 lizmat because you don't really want people to be messing with @*ARGS just to get the functionality
15:56 IOninja OK. Makes sense.
15:57 TheovdH Hi, when debugging I get "Unhandled exception: ctxlexpad needs an MVMContext". Rak 2017.1 on Ubuntu. Suggestions?
15:57 IOninja I guess what turns me off is all these "not-here" methods and basically all write methods that we can't really do anything sane for: https://github.com/rakudo/rakudo/co​mmit/a28270f009e15baa04ce76e#diff-3​c4e4507ba92d2e8db72990d1d4aa83dL154
15:58 IOninja So it's not really `is IO::Handle` but different enough to not be.
15:58 lizmat unless we abstract stuff from IO::Handle into a role as well
15:58 IOninja Alright.
15:59 lizmat fwiw, IO::Handle.open is a major performance bottleneck for scripts handling many files
15:59 IOninja TheovdH: under normal circumstances you should never see an error like that, so you're hitting a bug or have some really weird code. Do you have some sample of code you could pastebin for us to test?
16:00 SmokeMachine m: say [\X]((1, 2, 3), (4, 5, 6), (7, 8, 9))
16:00 camelia rakudo-moar e5528d: OUTPUT: «(((1 2 3)) ((1 2 3 4 5 6)) ((1 2 3 4 5 6 7 8 9)))␤»
16:01 SmokeMachine m: say [\[&infix:<X>]]((1, 2, 3), (4, 5, 6), (7, 8, 9))
16:01 camelia rakudo-moar e5528d: OUTPUT: «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 block <unit> at <tmp> line 1␤␤»
16:01 SmokeMachine whats the difference?
16:01 SmokeMachine m: say [\X]((1, 2, 3), (4, 5, 6), (7, 8, 9)).map(*.cache).tail
16:01 camelia rakudo-moar e5528d: OUTPUT: «((1 2 3 4 5 6 7 8 9))␤»
16:01 SmokeMachine m: say [\X]((1, 2, 3), (4, 5, 6), (7, 8, 9)).map(*.cache).tail.perl
16:01 camelia rakudo-moar e5528d: OUTPUT: «((1, 2, 3, 4, 5, 6, 7, 8, 9),)␤»
16:02 SmokeMachine m: say [\X]((1, 2, 3), (4, 5, 6), (7, 8, 9)).tail.perl
16:02 camelia rakudo-moar e5528d: OUTPUT: «Seq.new-consumed()␤»
16:03 TheovdH IOninja. Its a lot of code. I do not see a simple way of slicing it up. I will look at pastebin.
16:03 SmokeMachine IOninja: i think Ill PR now and finish the tests later... is that ok?
16:03 IOninja SmokeMachine: I guess... but how do you know your thing is working if you ain't got tests? O:)
16:04 IOninja TheovdH: FWIW, you can run perl6 --ll-exception switch and it should output more info about where the error happens.
16:04 SmokeMachine IOninja: I have some tests, but the tests Id like...
16:04 IOninja (unless it *does* include the file/line number)
16:07 zakharyas joined #perl6
16:10 m44st4 Hi !
16:10 IOninja Ahoy, mst!
16:10 IOninja mst's uncle :)
16:10 m44st4 Quick question, to xor two buffers, should i use ~^ ?
16:11 IOninja Probably +^, since ~ is string xor, innit?
16:11 IOninja ~^
16:11 IOninja by "buffers" you mean Buf's ?
16:11 m44st4 yep
16:11 hord are sub{}s Callable?
16:11 IOninja hord: yes
16:12 IOninja m: say sub {} ~~ Callable
16:12 camelia rakudo-moar e5528d: OUTPUT: «True␤»
16:12 TheovdH IOninja: Thanks, now I get new info: Strange text after block (missing semicolon or comma?)
16:12 TheovdH at SETTING::src/core/Exception.pm:63  (/home/theo/rakudo-star-2017.01/install/sha​re/perl6/runtime/CORE.setting.moarvm:throw)
16:12 IOninja TheovdH: what's the full output? The lines after the last one you pasted
16:12 hord sub protos save so much typing
16:12 IOninja hord: so don't type them...
16:13 IOninja hord: oh, never mind; misrtead
16:13 hord no, i really like them.  perl 5 protos were garbage.
16:13 TheovdH IOninja: it goes on and on, but here are the following lines.
16:13 TheovdH from src/Perl6/World.nqp:4065  (/home/theo/rakudo-star-2017.01/install/​share/nqp/lib/Perl6/World.moarvm:throw)
16:13 TheovdH from src/Perl6/Grammar.nqp:247  (/home/theo/rakudo-star-2017.01/install/shar​e/nqp/lib/Perl6/Grammar.moarvm:typed_panic)
16:13 TheovdH from src/Perl6/Grammar.nqp:1279  (/home/theo/rakudo-star-2017.01/install/share​/nqp/lib/Perl6/Grammar.moarvm:eat_terminator)
16:13 TheovdH from src/Perl6/Grammar.nqp:1180  (/home/theo/rakudo-star-2017.01/install/share​/nqp/lib/Perl6/Grammar.moarvm:statementlist)
16:13 TheovdH from gen/moar/perl6-debug.nqp:392  (/home/theo/rakudo-star-2017.01/install/​share/perl6/runtime/perl6-debug.moarvm:)
16:13 TheovdH from gen/moar/perl6-debug.nqp:390  (/home/theo/rakudo-star-2017.01/install/share/p​erl6/runtime/perl6-debug.moarvm:statementlist)
16:13 TheovdH from src/Perl6/Grammar.nqp:1353  (/home/theo/rakudo-star-2017.01/install/sh​are/nqp/lib/Perl6/Grammar.moarvm:blockoid)
16:13 TheovdH from gen/moar/perl6-debug.nqp:413  (/home/theo/rakudo-star-2017.01/install/shar​e/perl6/runtime/perl6-debug.moarvm:blockoid)
16:13 TheovdH from src/Perl6/Grammar.nqp:1316  (/home/theo/rakudo-star-2017.01/install/s​hare/nqp/lib/Perl6/Grammar.moarvm:pblock)
16:13 TheovdH from src/Perl6/Grammar.nqp:1282  (/home/theo/rakudo-star-2017.01/install/s​hare/nqp/lib/Perl6/Grammar.moarvm:xblock)
16:13 TheovdH from <unknown>:1  (/home/theo/rakudo-star-2017.01/ins​tall/share/nqp/lib/Perl6/Grammar.mo​arvm:statement_control:sym<given>)
16:13 IOninja Shiet
16:13 lizmat TheovdH: you probably want to put that in a gist  :-)
16:14 hord multi methods mean i don't have to re-wrap scalars into hashes or arrays
16:14 IOninja TheovdH: in the future, please pastebin large amounts of stuff into a pastebin: https://gist.github.com/
16:14 TheovdH IOninja: lizmat: sorry about that.
16:15 IOninja TheovdH: so the `ctxlexpad needs an` error is gone? Or does it disappear only if you use --ll-exception?
16:15 m44st4 Ok so ~^ xoring is working
16:15 IOninja OK
16:16 m44st4 but +^ isn't
16:16 m44st4 good to know
16:16 IOninja m44st4: yeah, I was wrong.
16:16 IOninja Bufs are Stringy and have ~ bitwise ops: https://github.com/rakudo/rakudo/b​lob/nom/src/core/Buf.pm#L704-L787
16:17 TheovdH IOninja: I'm not sure what you mean. It is not my code that gives this message. It is only if I use perl6-debug-m.
16:17 IOninja TheovdH: how can I reproduce this on my computer?
16:17 Cabanossi joined #perl6
16:18 TheovdH IOninja: I will try and pastebin my stuff. It is a lot and I have to embed some modules. Need some time for that.
16:21 IOninja OK, maybe someone else can help you out; as I'm leaving in a sec. FWIW, these are the only ctxlexpads in Rakudo's source, so your issue is something about module loading: https://gist.github.com/zoffixznet​/7dfd75fde398928e4795fa8d19f3b6a4
16:21 IOninja And perl6-debug-m is busted on HEAD:  ./perl6-debug-m -e 'say "hi"'
16:21 IOninja Illegal option --nqp-lib
16:21 * IOninja &
16:22 mst IOninja: awaylog spammer!
16:24 tokomer joined #perl6
16:24 mcmillhj joined #perl6
16:24 tokomer
16:25 sufrostico joined #perl6
16:25 sufrosti1o joined #perl6
16:27 IOninja mst: Twitter-relay spammer: http://i.imgur.com/j98Ad6a.png
16:27 IOninja It's not my fault your uncle visited our channel :P
16:28 IOninja ^_^
16:29 TheovdH IOninja: https://gist.github.com/anonymous​/71b0928420a07efbe50602a3842957b7
16:30 sufrosti2o joined #perl6
16:34 IOninja TheovdH: well, it dies, but with "No such method 'name' for invocant of type 'Str'" for me
16:35 domidumont joined #perl6
16:36 mcmillhj joined #perl6
16:37 TheovdH IOninja: yes. I know. My problem is not with this code, but with debugging it. I want to see what happened before it got there.
16:37 IOninja Ah
16:38 IOninja hm, my perl6-debug-m is busted: "Cannot find method 'setlang' on object of type Perl6::HookGrammar"
16:38 * IOninja builds a 2017.01
16:39 IOninja Never used it, though. No idea what it does :)
16:39 TheovdH IOninja: I had that before. I was recommended to not install from rakudobrew :0)
16:39 IOninja heh
16:41 mcmillhj joined #perl6
16:44 cale2 joined #perl6
16:44 cale2 u: wave
16:44 unicodable6 cale2, U+219D RIGHTWARDS WAVE ARROW [So] (↝)
16:44 unicodable6 cale2, U+219C LEFTWARDS WAVE ARROW [So] (↜)
16:44 unicodable6 cale2, 36 characters in total: https://gist.github.com/ced1​3f8aa9980c79b11c7f7912ee2725
16:44 hord wow... i think most of my port is now done and it seems to actually work.
16:47 IOninja Hm.
16:48 rindolf joined #perl6
16:48 IOninja TheovdH: well, I've built 2017.01 rakudo and its perl6-debug-m is still busted with "Illegal option --nqp-lib" :/ wonder what Rakudo Star does to it that it actually works.
16:49 IOninja Oh fixed that, but now need Could not find Debugger::UI::CommandLine
16:49 IOninja So what does the debug do?
16:50 IOninja guess I can find out if I install that module eh :P
16:50 IOninja hord: what module are you porting?
16:50 lizmat grrr I hate it when stuff breaks when trying to move things to a role  :-(
16:50 hord IOninja: it's my own Plack web framework that i wrote the other day
16:50 lizmat Type check failed in binding; expected NQPMu but got IterationBuffer  # WTF ?
16:51 IOninja hord: ah
16:53 IOninja TheovdH: success. I managed to reproduce your issue on 2017.01 :)
16:53 * IOninja tries HEAD
16:53 TheovdH IOninja: great. this "Unhandled exception: ctxlexpad needs an MVMContext" has reared its ugly head before.
16:54 hord has $.foo; # this gives me $obj.foo, but $.foo is immutable?
16:54 IOninja And HEAD gives me "Cannot find method 'setlang' on object of type Perl6::HookGrammar" ehehe
16:55 IOninja hord: from outside, yeah, immutable. You can still mutate it inside with $!foo = "meows"
16:55 [Coke] m: class hord {has $.foo}; my $a = hord.new; $a.foo = 3; say $a.foo
16:55 camelia rakudo-moar e5528d: OUTPUT: «Cannot modify an immutable Any␤  in block <unit> at <tmp> line 1␤␤»
16:56 [Coke] That did not do what I meant. oops.
16:56 IOninja Note that it's just an immmutable container; it doesn't magically make the stuff it contains immutable
16:57 IOninja m: class hord {has $.foo = [<a b c>]}; my $a = hord.new; $a.foo[1] = 3; say $a.foo
16:57 camelia rakudo-moar e5528d: OUTPUT: «[a 3 c]␤»
16:57 IOninja Wow perl6-debug-m is cool!
16:58 IOninja I had no idea we had this
16:58 jnthn o.O :)
16:58 mcmillhj joined #perl6
16:58 jnthn The setlang thingy sounds like a regression during the slang work
16:58 IOninja Yeah, and the fix should be fairly simple.
16:59 hord hrm... that means i would have to mutate someone else's class...
16:59 jnthn hord: I don't think anybody pointed it out yet: `has $.foo is rw` creates an l-value accessor
16:59 hord Crust::Response isn't like Plack::Response in that respect, i guess
16:59 jnthn IOninja: ah, nice :)
17:00 hord jnthn: yeah, those aren't on the attributes and this is someone else's class
17:00 hord i will have to find another solution
17:00 IOninja Well, I only think it is :) I don't know what it is. I guess I can grep the logs and find out....
17:01 [Coke] hord: you shouldn't be mucking in the other classes internals.
17:01 jnthn Ah, OK
17:01 jnthn :)
17:02 hord [Coke]: it's probably something that I should send a patch for.  Crust::Response doesn't seem to be useful unless you can mutate it.
17:02 hord and for now it seems you can only set attributes at .new() time
17:02 IOninja TheovdH: FWIW, your issue points to this line: https://github.com/jnthn/rakudo-debugger/blo​b/master/lib/Debugger/UI/CommandLine.pm#L736
17:02 * IOninja debugs it some more
17:02 [Coke] hord: sounds good!
17:04 IOninja m: class Foo { has $.a = 42; has $.b = 72 }; dd Foo.new: |.Capture, :90b with Foo.new
17:04 camelia rakudo-moar e5528d: OUTPUT: «Foo.new(a => 42, b => 90)␤»
17:04 IOninja hord: FWIW something like ^ that can be done to create a new class while modifying its attributes; doesn't keep the state of private stuff tho
17:05 IOninja I mean... create a new object and fill it up with values of another object's public attreibutes
17:05 hord IOninja: i'll be honest, that's too confusing
17:05 hord i don't have a clue what |., Capture or :90b are supposed to mean
17:05 hord even if i can see what they do
17:06 IOninja m: class Foo { has $.a = 42; has $.b = 72 }; my $old = Foo.new; my $new = Foo.new: |$old.Capture, b => 90; dd $new
17:06 camelia rakudo-moar e5528d: OUTPUT: «Foo $new = Foo.new(a => 42, b => 90)␤»
17:06 IOninja How about now?
17:06 IOninja The | is just a Slip
17:06 IOninja huggable: Slip
17:06 huggable IOninja, A kind of List that automatically flattens into an outer container: https://docs.perl6.org/type/Slip
17:06 hord it's too much syntax to take in
17:06 IOninja OK :)
17:06 IOninja And :90b is just another way to write b => 90
17:06 IOninja huggable: colonpairs
17:06 huggable IOninja, All the shortcuts of colonpairs: https://twitter.com/zoffix​/status/839807414211854337
17:07 hord what i need is a perl 6 => perl 5 idiom sheet
17:07 hord when i can see equivalent p5 code, i just know what it does
17:07 IOninja Not aware of that...
17:07 perigrin the truely fun stuff doesn't have an equivalent in p5
17:07 perigrin afaict
17:07 IOninja hord: There's 4 5-to-6 tutorials, but they're not really about whole idioms: https://docs.perl6.org/language.html
17:08 hord the guides i've seen are either confusing or too light (this was a while ago)
17:08 hord that's why i felt like just writing a bunch of code was the way to go
17:08 IOninja It probably is :)
17:08 hord but i can only take so much syntax in a day... and perl 6 adds an absolute TON
17:09 TheovdH IOninja: thanks. Looking at the debugger code I still cannot guess how to move forward.
17:09 TheovdH IOninja: thanks. Looking at the debugger code I still cannot guess how to move forward.
17:10 IOninja hord: FWIW, there's a lot of consistency in syntax, so there's not SO much to take in. The biggest thing to grasp I think is the lack of automatic list flattening in Perl 6.
17:10 IOninja TheovdH: well, are you trying to find the problem in your code or to fix the debugger? :)
17:10 hord IOninja: it's more that I have 20+ years of perl 5 along with C, JavaScript and many other things
17:11 hord IOninja: the syntax is easy, but i have to put it into context with every other thing i've learned
17:11 hord i'm poly-paradigm, poly-glot
17:13 IOninja TheovdH: the reason I ask is... trying to debug the debugger on 2017.01 may be wasted effort. My plan for that would be to de-bitrot it on HEAD and keep the snippet you gave me to see if it's still has that issue and then debug that.
17:14 TheovdH IOninja: OK. I am fine with that.
17:14 koki1 joined #perl6
17:15 dwarring hord: there's an old advent post that covers some Perl 5 -> 6 idoms
17:15 dwarring https://perl6advent.wordpress.com/2​011/12/23/day-23-idiomatic-perl-6/
17:15 dwarring that's all I can think of
17:15 IOninja 2011... I wonder how much of that Perl 6 is no longer valid.
17:16 hord dwarring: i was thinking something more along the lines of new concepts/syntax in Perl 6 being re-vamped in other languages
17:16 dwarring yeah probably too old
17:16 hord from the top-down rather than the bottom up
17:16 hord show why things are different and how
17:17 Cabanossi joined #perl6
17:20 IOninja TheovdH: next best thing:   use trace;
17:21 IOninja TheovdH: prints out the lines as they're executed.
17:21 IOninja TheovdH: and I added the debugger's bug to my TODO list; unless I forget, should be fixed in 2017.04 Rakudo Star.
17:21 * IOninja &
17:22 * jnthn bbl
17:23 TheovdH IOninja: great and great. I was not aware of trace. It is going to help. Looking forward to 2017.04!
17:30 TheovdH IOninja: btw I will let you know if I find a simpler stretch of code that has the same effect on the debugger
17:30 jast joined #perl6
17:30 El_Che IOninja: you sneaky b*tard, releasing a new rakudo. Building pkgs now.
17:30 hord can i create a class that is private to another class?  e.g.  Foo::bar objects can only be created by Foo?
17:32 grondilu_ joined #perl6
17:32 [Coke] define the second class inside the first.
17:32 hord unit class Foo;  ...  class Foo::bar;  #?   that's what i'm trying.
17:33 [Coke] m: class A { class B {} ; method frob { return B.new } } ; A.frob.WHAT.say;
17:33 camelia rakudo-moar e5528d: OUTPUT: «(B)␤»
17:33 [Coke] m: class A { class B {} ; method frob { return B.new } } ; A.frob.WHAT.say; B.new.say
17:33 camelia rakudo-moar e5528d: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Undeclared name:␤    B used at line 1␤␤»
17:34 hord namespacing is going to kill me in p6, too
17:35 [Coke] (you could go so far as to define B inside the frob method there, if that's how restricted you needed it
17:35 El_Che I need a new laptop. Travis finished faster than my local build
17:36 hord [Coke]: yes... yes that might actually be what i need.
17:36 hord i mean it's kind of disgusting to have a type that is only defined in the scope of a single sub
17:36 hord but i like it.  i like it a lot.
17:37 [Coke] hord: we do it in core, even: https://github.com/rakudo/rakudo/b​lob/3fb04c34e58cdaaddfdb9832abad60​867c9d8b33/src/core/Routine.pm#L63
17:37 hord yep, that's basically what i need
17:38 hord this means you can now create actionable message types
17:38 hord i can pass you a data structure and you give me an empire built from it
17:38 hord disgusting
17:41 japhb joined #perl6
17:51 girafe joined #perl6
17:52 kurahaupo__ joined #perl6
17:53 sufrostico joined #perl6
17:53 sufrosti1o joined #perl6
17:53 sufrosti2o joined #perl6
17:58 lizmat :-)
17:58 * lizmat wonders what hord would think of class :: does Iterator { ... }.new(...)  :-)
18:04 TimToady or anon class Sekrit does Iterator { ... }.new(...)  :-)
18:08 lizmat m: class A { method a(--> self) {} }; dd A.a # sometimes I wish this would work
18:08 camelia rakudo-moar e5528d: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Type 'self' is not declared␤at <tmp>:1␤------> 3class A { method a(--> self7⏏5) {} }; dd A.a # sometimes I wish this w␤»
18:09 IOninja m: class A { method a(\z: --> z) {} };
18:09 camelia rakudo-moar e5528d: OUTPUT: «===SORRY!===␤No compile-time value for z␤»
18:10 IOninja booo
18:11 IOninja m: class A { method a(\z: --> ::?CLASS) {z} }.new.a.say
18:11 camelia rakudo-moar e5528d: OUTPUT: «A.new␤»
18:11 TimToady --> is in the category of --> $result
18:11 TimToady which is NYI
18:11 TimToady er, --> self is in...
18:12 IOninja El_Che: not sneaky. It's third Saturday of the month, every month.
18:12 IOninja El_Che: also:
18:12 IOninja NeuralAnomaly: status
18:12 NeuralAnomaly IOninja, [✘] Next release will be in 3 weeks and 3 days. Since last release, there are 5 new still-open tickets (5 unreviewed and 0 blockers) and 17 unreviewed commits. See http://perl6.fail/release/stats for details
18:16 TimToady is anyone else not seeing the latest P6W in their pl6anet feed?
18:16 IOninja TimToady: everyone. Something's broken with pl6anet
18:16 IOninja m: class { method x { anon class Sekrit { constant x = anon role AlsoSekrit { method z { Sekrit.new but AlsoSekrit } }; also does x } } {} } }.new.x.z
18:16 camelia rakudo-moar e5528d: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Undeclared names:␤    AlsoSekrit used at line 1␤    Sekrit used at line 1␤␤»
18:16 IOninja booo
18:17 IOninja m: class { method x { class Sekrit { constant x =  role AlsoSekrit { method z { Sekrit.new but AlsoSekrit } }; also does x } } }.new.x.z.say
18:17 camelia rakudo-moar e5528d: OUTPUT: «<anon|50635344>::Sekrit+{<anon|50​635344>::Sekrit::AlsoSekrit}.new␤»
18:18 IOninja \o/
18:19 TimToady 'also' is one of those things you almost never want, but when you want it, you want it very, very much :)
18:19 IOninja El_Che: also, release happens in full view of the public #perl6-dev :) https://irclog.perlgeek.de/pe​rl6-dev/2017-03-18#i_14286273
18:19 zakharyas joined #perl6
18:19 SmokeMachine I am sorry, but I have to comment: had anyone noticed the charles chaplin made by lobster's and sorear's avatars on the rakudo's organization's page? https://github.com/rakudo
18:20 ilmari SmokeMachine: neat
18:21 * IOninja doesn't see it
18:21 IOninja I don't even see no sorear
18:22 hobbs haha
18:22 hobbs IOninja: third column of light green geometric things
18:22 hobbs in the People box
18:22 TimToady my People box apparently has different geometry
18:23 timotimo it has 16 entries on my end, in a 5x3 + 1 lone picture arrangement
18:23 hobbs http://i.imgur.com/htNHxfk.png
18:23 IOninja http://i.imgur.com/dqyybwg.png
18:23 timotimo hey that's me in there \o/
18:23 IOninja Ah. I have special powers and see more people that's why
18:24 * TimToady wonders what Rorshasch would make of your identification...
18:24 hobbs oh, I wonder if it's different if you're in the organization
18:24 IOninja SmokeMachine++ indeed it does look like it :)
18:25 TimToady ohh, pl6anet fixed, stmuk_++
18:25 SmokeMachine :)
18:27 gdonald left #perl6
18:27 SmokeMachine lizmat: why do you think that should be 2 different Pos?
18:27 SmokeMachine *PRs
18:28 domidumont joined #perl6
18:32 FROGGS joined #perl6
18:35 eroux joined #perl6
18:37 ranguard joined #perl6
18:37 Geth ¦ ecosystem: 6137040c18 | (Zoffix Znet)++ | META.list
18:37 Geth ¦ ecosystem: s/META.info/META6.json/ for P6-Data-Dump-Tree
18:37 Geth ¦ ecosystem: review: https://github.com/perl6/e​cosystem/commit/6137040c18
18:43 Geth ¦ modules.perl6.org: e06d6ab8a5 | (Zoffix Znet)++ | lib/ModulesPerl6/DbBuilder/Dist/Source.pm
18:43 Geth ¦ modules.perl6.org: Fix incorrect warnings for tags
18:43 Geth ¦ modules.perl6.org:
18:43 Geth ¦ modules.perl6.org: Detects missing tags as "have but not an array" tags.
18:43 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/e06d6ab8a5
18:52 El_Che IOninja: I am #perl6 lurker, not a #perl6-dev l33t haxor
18:53 IOninja heh
18:55 raschipi m: say +$*THREAD
18:55 camelia rakudo-moar e5528d: OUTPUT: «1␤»
18:56 lizmat m: start { say $*THREAD }
18:56 camelia rakudo-moar e5528d: OUTPUT: «Thread #3␤»
18:56 Geth ¦ modules.perl6.org: b6e5c60be4 | (Zoffix Znet)++ | templates/root/index.html.ep
18:56 Geth ¦ modules.perl6.org: Remove superfluous text
18:56 Geth ¦ modules.perl6.org: review: https://github.com/perl6/modul​es.perl6.org/commit/b6e5c60be4
18:56 hord what keeps perl 6 from including '?' in identifiers?
18:57 kurahaupo__ joined #perl6
18:57 lizmat hord: there's actually a slang for that
18:57 hobbs just use "p" ;)
18:57 hord i've always liked ruby's .nil?  and things like that.
18:57 lizmat hord: https://github.com/FROGGS/p6-Slang-Piersing
18:58 hord lizmat: nice!
18:58 raschipi If that gets popular, does it make into core?
18:58 SmokeMachine IOninja: the problem is: got: $(Seq.new-consumed(), Seq.new-consumed(), Seq.new-consumed())
18:58 lizmat raschipi: don't think so
18:59 lizmat it lives fine in module space  :-)
18:59 IOninja Wonder if that module's been busted by the braid upgrade
19:00 IOninja SmokeMachine: kinda yeah, it's the problem with the output though; it can still test if they differ.
19:00 IOninja m: use Test; is-deeply [(1,).Seq], [(1,).Seq]
19:00 camelia rakudo-moar e5528d: OUTPUT: «ok 1 - ␤»
19:00 IOninja m: use Test; is-deeply [(1,).Seq], [(2,).Seq]
19:00 camelia rakudo-moar e5528d: OUTPUT: «not ok 1 - ␤␤# Failed test at <tmp> line 1␤# expected: $[2]␤#      got: $[1]␤»
19:00 IOninja m: use Test; is-deeply [(1,).Seq,], [(1,).Seq,]
19:00 camelia rakudo-moar e5528d: OUTPUT: «ok 1 - ␤»
19:01 IOninja m: use Test; is-deeply [(1,).Seq,], [(2,).Seq,]
19:01 camelia rakudo-moar e5528d: OUTPUT: «not ok 1 - ␤␤# Failed test at <tmp> line 1␤# expected: $[Seq.new-consumed(),]␤#      got: $[Seq.new-consumed(),]␤»
19:01 IOninja Right
19:01 SmokeMachine IOninja: ok, thanks!
19:01 IOninja SmokeMachine: ^ so if it's failing, that means the outputs don't match.
19:02 IOninja It just can't output them, because they've been consumed during comparison.
19:02 hord oh my.  oh my my my.
19:02 SmokeMachine IOninja: ok, thanks!
19:02 SmokeMachine (is there any way to tell travis: if is there a new version of rakudo, run my modules tests again?)
19:03 IOninja SmokeMachine: yes: https://docs.travis-ci.com/user/triggering-builds/
19:03 hord so... you can modify the parser's grammar at run-time?
19:03 IOninja hord: yes
19:03 SmokeMachine IOninja: great! ill do that to my modules!!!
19:04 SmokeMachine IOninja: thanks!
19:04 Tonik joined #perl6
19:04 IOninja m: sub infix:<♥> { $^a + $^b }; say 2 ♥ 2
19:04 camelia rakudo-moar e5528d: OUTPUT: «4␤»
19:04 IOninja hord: that's ^ one way. And slangs is another. Slangs currently don't have an "official" API
19:04 IOninja huggable: slang
19:04 huggable IOninja, https://mouq.github.io/slangs.html
19:05 IOninja hord: ^ docs for them; though that might be outdated a bit due to recent braids upgrade (it would be just a couple of lines though, see the recent changes in Slang::Tuxic for a fix)
19:06 IOninja buggable: eco Slang::Tuxic
19:06 buggable IOninja, Slang::Tuxic 'allows to call subs as: foo (args)': https://github.com/FROGGS/p6-Slang-Tuxic
19:06 hord that's just wild
19:06 hord i'm trying to imagine how you accomplish that... i'm guess a mutable grammar tree.
19:06 IOninja hord: even without any changes, parsing is done with a braid of three languages: Main, Quote, and Regex
19:07 hord i don't think i've ever built a parser that stored the semantics as a tree
19:07 hord or whatever
19:07 hord yeah, i seem to recall reading about the multi-language ability with regards to regex
19:07 IOninja m: say "Oh {"my"}"
19:07 camelia rakudo-moar e5528d: OUTPUT: «Oh my␤»
19:08 IOninja Note how the quotes don't interfere :)
19:08 IOninja (well, I guess you don't need braids for that, but still)
19:09 mr-foobar joined #perl6
19:12 El_Che New rakudo 2017.03 Linux pkgs: https://github.com/nxadm/rak​udo-pkg/releases/tag/2017.03
19:13 IOninja \o/
19:13 IOninja El_Che++
19:13 IOninja El_Che: do Centos .rpms work on all the other Linuxes that use .rpms?
19:13 hord i'm behind (2017.01)
19:13 SmokeMachine m: say [\X~](<a b c>) eqv ((("a",).Seq, ("ab",).Seq, ("abc",).Seq)).Seq # <- IOninja, is that good enough?
19:13 camelia rakudo-moar 1132b1: OUTPUT: «True␤»
19:13 El_Che I will try to squeeze a Debian release soon, because I saw some users here on the channel asking about it
19:14 El_Che IOninja: they are built on CentOS7. It should (because everything is self-contained), but ymmv
19:14 IOninja m: use Test; is-deeply [\X~](<a b c>), ((("a",).Seq, ("ab",).Seq, ("abc",).Seq)).Seq
19:14 camelia rakudo-moar 1132b1: OUTPUT: «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 sub _is_deeply at /home/camelia/rakudo-m-inst-2/shar​e/perl6/sources/C712FE6969F786C…»
19:14 El_Che thing will break e.g. if the OSes have incompalitble libc or something
19:14 IOninja m: use Test; is-deeply ([\X~](<a b c>)), ((("a",).Seq, ("ab",).Seq, ("abc",).Seq)).Seq
19:14 camelia rakudo-moar 1132b1: OUTPUT: «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 sub _is_deeply at /home/camelia/rakudo-m-inst-2/shar​e/perl6/sources/C712FE6969F786C…»
19:15 * IOninja wonders wtf
19:15 El_Che I could add a Fedora build to cover most bases
19:15 IOninja SmokeMachine: yeah
19:15 IOninja SmokeMachine: though I don't get why is-deeply isn't happy with them :/
19:15 El_Che The whole idea of the docker build is that it's trivial to add a 64-bit linux OS
19:15 raschipi Speaking of debian, 2017-02 is just available from the repos, I'm upgrading now.
19:16 IOninja 2017.02? ancient!
19:16 El_Che (and possible to add a 32 if there is a base 32 bit systemn like the one Ubuntu has for the cloud)
19:16 IOninja :)
19:16 mcmillhj joined #perl6
19:16 SmokeMachine is-deeply really didn't like that... :(
19:17 IOninja m: use Test; cmp-ok [\X~](<a b c>), 'eqv', ((("a",).Seq, ("ab",).Seq, ("abc",).Seq)).Seq
19:17 camelia rakudo-moar 1132b1: OUTPUT: «ok 1 - ␤»
19:17 IOninja SmokeMachine: you can use that
19:17 IOninja is-deeply is bustified with Seqs I guess.
19:17 SmokeMachine IOninja: great! thanks!
19:22 IOninja SmokeMachine: and commit directly (or merge your PR) when you're done. You have the commit bit.
19:23 SmokeMachine IOninja: ok... but if I did that the last time you wouldn't correct me...
19:23 espadrine joined #perl6
19:23 IOninja SmokeMachine: and if you ever decide to try to get a commit bit for rakudo, it's required that you sign a Contributor License Agreement and send it to The Perl Foundation first. It's here: http://www.perlfoundation.org/​contributor_license_agreement you can email it to them instead of shipping it by normal mail
19:26 SmokeMachine IOninja: should I send that to what email?
19:27 IOninja SmokeMachine: not really sure, maybe Jim Brandt? http://www.perlfoundation.org/contact_us  You can ask [Coke], he's a member
19:27 pytuger joined #perl6
19:27 pytuger joined #perl6
19:28 mr-foobar joined #perl6
19:32 SmokeMachine .tell [Coke] Hi there! Id like to sign the Contributor License Agreement, do you know what email should I send that? Should those blanks be hand written? Thank you very much.
19:32 yoleaux SmokeMachine: I'll pass your message to [Coke].
19:32 [Coke] print it out, sign it, scan it in.
19:32 yoleaux 19:32Z <SmokeMachine> [Coke]: Hi there! Id like to sign the Contributor License Agreement, do you know what email should I send that? Should those blanks be hand written? Thank you very much.
19:32 SmokeMachine [Coke]: and send it to what email?
19:33 [Coke] mail to trademark -at- perlfoundation.org
19:33 SmokeMachine [Coke]: thank you very much!
19:36 andrzejku joined #perl6
19:37 wamba joined #perl6
19:47 hankache joined #perl6
19:47 hankache hello #perl6
19:54 raschipi hey hankache!
19:56 mcmillhj joined #perl6
20:00 andrzejku joined #perl6
20:03 * timotimo has never had an aching hank
20:03 Cabanossi joined #perl6
20:06 setty1 joined #perl6
20:08 pyrimidine joined #perl6
20:11 SmokeMachine signed
20:12 SmokeMachine https://www.irccloud.com/pastebin/ls7lxwRV/
20:12 mcmillhj joined #perl6
20:13 SmokeMachine [Coke]: the email bounced... :(
20:14 * [Coke] wonders if DBIish supports oracle CLOBs
20:15 [Coke] SmokeMachine: ok. send it to me at will@coleda.com, I'll add it to my pile of TPF stuff to do.
20:15 SmokeMachine [Coke]: thanks!
20:16 SmokeMachine sent!
20:18 [Coke] SmokeMachine: recebido
20:18 SmokeMachine [Coke]: are you brazilian?
20:19 [Coke] no, although I think there are some Coledas down that way.
20:20 SmokeMachine tColedas?
20:20 SmokeMachine Coledas?
20:20 hord i don't see anything in the DBDish that lets you mess with CLOBs like the p5 driver does... good luck :)
20:21 hord Oracle is... fun.
20:21 SmokeMachine google translate told me that Coledas should means "cops"... (In brazil we call cops: policiais)
20:22 SmokeMachine *mean
20:22 avar joined #perl6
20:23 zakharyas joined #perl6
20:25 timotimo what are CLOBs?
20:26 timotimo do i even want to know ...
20:27 hobbs like a BLOB but without the first B
20:27 hobbs (character large object)
20:27 hankache joined #perl6
20:27 hord timotimo: all the horror of BLOBs with Unicode
20:28 timotimo so ... instead of bytes it has ascii characters? :P
20:28 timotimo oh yikes
20:28 timotimo that's somehow even worse
20:28 hord actually, Oracle's unicode handling is fine once you learn how to pick The One True Encoding
20:28 labster joined #perl6
20:28 hobbs I wrote an oracle stored-procedure wrapper for $WORK some years back, the LOB-fetcher was one of the more interesting parts of it
20:29 hobbs almost as hard to get right as the actual function introspector
20:29 hord yeah i had to deal with lobs for some web apps
20:29 [Coke] Whatever my name means, I'm pretty sure "police" ain't it. :)
20:30 hord i'm digging on MonoDB lately.  is there a p6 driver?  i haven't looked.
20:31 hord oh, there is..
20:31 timotimo is that mongodb but without the g?
20:31 hord i meant MongoDB
20:31 timotimo OK
20:31 domidumont joined #perl6
20:31 timotimo just make sure you either don't expose your mongodb to the public internet, or have a password set on it
20:33 hord what if i want to run a wiki-style database?
20:35 TEttinger joined #perl6
20:49 bjz joined #perl6
20:54 tinita joined #perl6
20:58 tinita joined #perl6
21:09 sufrostico joined #perl6
21:10 sufrosti1o joined #perl6
21:10 sufrosti2o joined #perl6
21:12 RabidGravy I ought to release Sofa soon
21:16 timotimo hord: why would you expose the database to the public internet in that case?
21:18 hord timotimo: for fun and profit
21:20 timotimo well, let's hope you have usernames and their passwords in a separate database in that case
21:21 timotimo and you don't mind someone dropping all your tables constantly
21:26 hord what if you made a database where the first record you create is your public key and only messages from you can mutate the database?
21:28 timotimo that would be fun
21:28 pyrimidine joined #perl6
21:30 hord i have a single-user version using symmetric keys.  the idea of using pki + multi-user hit me yesterday.
21:43 sufrostico joined #perl6
21:43 sufrosti1o joined #perl6
21:43 sufrosti2o joined #perl6
21:44 El_Che creating debian stable packages
21:44 El_Che so, far it hasn't exploded in my face :)
21:50 hankache joined #perl6
21:51 labster joined #perl6
21:53 El_Che https://github.com/nxadm/rak​udo-pkg/releases/tag/2017.03 <-- includes debian8 amd64 rakudo pkg
21:54 IOninja El_Che++
22:09 m44st4 Hi ! Do we have a good Crypto library with AES,Twofish,Serpent and Usual block-cipher modes,
22:09 m44st4 ?
22:12 samcv hi!
22:13 samcv m44st4, https://modules.perl6.org/#q=crypt
22:13 IOninja buggable: eco crypt
22:13 buggable IOninja, Found 8 results: Game::Crypt, Crypt::Bcrypt, Crypt::Libcrypt, Crypt::RC4, Crypt::TweetNacl. See https://modules.perl6.org/#q=crypt
22:14 mcmillhj joined #perl6
22:16 m44st4 Thanks !
22:19 ccakes joined #perl6
22:19 El_Che hi samcv
22:19 samcv hey
22:22 ccakes_ joined #perl6
22:22 pyrimidine joined #perl6
22:25 ccakes joined #perl6
22:25 * IOninja wonders how Slang::Piersing got its name....
22:25 timotimo somethign to do with a lisp?
22:26 timotimo lol
22:27 hobbs I was wondering that too, my guess to myself is that it's something that Piers Cawley was excited about at some point
22:27 timotimo https://duckduckgo.com/?q=Pier​s+Cawley+library&amp;ia=videos
22:30 mcmillhj joined #perl6
22:44 araujo joined #perl6
22:44 araujo joined #perl6
22:46 mcmillhj joined #perl6
22:47 Voldenet joined #perl6
22:47 Voldenet joined #perl6
22:47 Cabanossi joined #perl6
22:50 skids joined #perl6
23:07 SmokeMachine accordingly to this (https://rt.perl.org/SelfService/Dis​play.html?id=131008#ticket-history) should I remove lcm and gcd from Numeric.pm?
23:07 raiph joined #perl6
23:10 IOninja I wouldn't call that a bug TBH.
23:10 IOninja The docs clearly state the behaviour too: "Coerces both arguments to Int and returns the least common multiple, that is the smallest integer that is evenly divisible by both arguments."
23:11 * IOninja &
23:11 thowe_work joined #perl6
23:14 SmokeMachine ok, Ill leave that alone...
23:15 hord that's a balance between being strict math and fuzzy perl
23:16 hord if you are a math person, i think it'd be technically wrong to allow anything but integers for gcd/lcm
23:16 timotimo i thought so, too, hord
23:16 hord but most programmers aren't strictly math people
23:16 timotimo m: say 2.5.narrow
23:16 camelia rakudo-moar 28acf0: OUTPUT: «2.5␤»
23:31 cibs joined #perl6
23:35 IOninja hord: that's not my reasoning for it. My reasoning is non-Int numbers don't make sense with these ops, so forcing the user to constantly add .Int with them is antisocial.
23:36 IOninja 'cause 99.9% of the time people aren't writing "2.5 gcd 5" but "*some computation* … $stuff gcd $other-stuff"
23:41 raiph joined #perl6
23:43 SmokeMachine is the code inside {} inside a regex evaluated at runtime, right?
23:43 SmokeMachine so this dies at compile time:
23:43 SmokeMachine m: say "ooo" ~~ / "o" ** 1..0 /
23:43 camelia rakudo-moar 28acf0: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Empty range␤at <tmp>:1␤------> 3say "ooo" ~~ / "o" ** 1..07⏏5 /␤»
23:43 SmokeMachine and this doesn't:
23:43 SmokeMachine m: say "ooo" ~~ / "o" ** {1..0} /
23:43 camelia rakudo-moar 28acf0: OUTPUT: «「ooo」␤»
23:43 mcmillhj joined #perl6
23:43 El_Che This is Rakudo version 2017.03 built on MoarVM version 2017.03
23:43 El_Che implementing Perl 6.c.
23:43 El_Che f7d2a26e55ee9acbe34168c37761baf7100152a8  perl6-rakudo-moarvm-Fedora​25-20170300-01.x86_64.rpm
23:43 El_Che \o/
23:44 SmokeMachine but the second one shouldn't match, right?
23:47 Cabanossi joined #perl6
23:48 El_Che For whoever writes p6weekly this week: addition of Fedora and Debian packages to https://github.com/nxadm/rak​udo-pkg/releases/tag/2017.03
23:48 skaji_ joined #perl6
23:50 skaji_ joined #perl6
23:53 pyrimidine joined #perl6
23:54 raiph joined #perl6
23:56 khw joined #perl6

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

Perl 6 | Reference Documentation | Rakudo