»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
timotimo blog.frizk.net/2018/03/total-meltdown.html?m=1 m( 00:14
Bowlslaw does anyone know how to do the perl 6 equivalent of `my ($var1, $var2) = $sth->fetchrow_array` 00:35
that is, get values from a sql database one by one and assign them to $vars
timotimo i believe you want binding, i.e. the := operator 00:37
Bowlslaw hmm 00:49
timotimo m: sub returns-array() { [1, 2] }; my ($var1, $var2) := returns-array; say "var1 is $var1, and var2 is $var2"
camelia var1 is 1, and var2 is 2
lookatme m: sub returns-array() { [1, 2] }; my ($var1, $var2) = returns-array; say "var1 is $var1, and var2 is $var2" 00:50
camelia var1 is 1, and var2 is 2
lookatme m: sub returns-array() { $[1, 2] }; my ($var1, $var2) = returns-array; say "var1 is $var1, and var2 is $var2" 00:51
camelia var1 is 1, and var2 is 2
timotimo oh, that's fine, too
lookatme m: sub returns-array() { $[1, [2, 3],] }; my ($var1, $var2) = returns-array; say "var1 is $var1, and var2 is $var2" 00:52
camelia var1 is 1, and var2 is 2 3
BenGoldberg Can anybody here help me with rakudobrew? When I try to run it, I get the error message: Can't open perl script "C:\Users\Ben": No such file or directory 02:30
Bowlslaw All I know is that use of rakudobrew is discouraged now. 02:43
donpdonp my $header = BlkMev::Chain::($chain.name)::header; => Combination of indirect name lookup and call not supported 02:48
im not sure what thats trying to tell me. the modules are defined as: module BlkMeV::Chain::Bitcoin { our $header = Buf.new(0xf9, 0xbe, 0xb4, 0xd9); } 02:49
Bowlslaw hey guys i'm having a bit of trouble : after a variable 03:18
for example, if I have a class with a method
method my-method($me:) { say $me.^name(); }
the : allows me to use that variable to identify the class 03:19
but what is it called?
MasterDuke Bowlslaw: the invocant i think 03:29
Bowlslaw MasterDuke: thanks 04:04
donpdonp how can i set a timeout for docs.perl6.org/type/IO::Socket::As...od_connect 04:11
oh, use .in(seconds) on the promise. 04:13
hmm no, connect doesnt give the promise until connected apparently 04:14
AlexDaniel squashable6: next 07:49
squashable6 AlexDaniel, Next SQUASHathon in 9 days and ≈2 hours (2018-04-07 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
AlexDaniel .tell moritz not sure if you received my last message, so here it is again. Maybe fix issues with https on some domains: gist.github.com/Whateverable/8c42c...4d3aa6b529 08:09
yoleaux AlexDaniel: I'll pass your message to moritz.
AlexDaniel well, or anyone who has enough access and tuits ↑
AlexDaniel heh github.com/issues/assigned 08:39
AlexDaniel Useful link. I'm now down to three from a gazillion! 08:40
scimon Hmm.... I want to test that calling a method returns a Failure. Anyone got a handy pointer on how to do that? 08:44
AlexDaniel m: sub foo { my $x = +‘a’; $x }; if foo() ~~ Failure { say ‘oops’ } 08:45
camelia oops
AlexDaniel that's for testing that something returns a failure, it won't catch exceptions
scimon So in the case of a unit test just use and OK?
AlexDaniel is that what you wanted?
scimon ie ok test-call() ~~ Failure 08:46
(Which works) I thought is test-call(), Failure would work but it gave the wonderful error expected: (Failure) got: (Failure)
Cheers. 08:47
AlexDaniel I actually don't know if that's the best way, maybe someone else can comment 08:48
roast does exactly that in some cases
in other cases: 08:49
isa-ok 10 div 0 , Failure, "10 div 0 softfails";
scimon: ↑ alternative solution
scimon Hmmm (loosk) 08:56
looks even
Chhers.
scimon (Today is bad typing day apparently) 08:56
isa-ok seems to be a better match. 08:57
AlexDaniel “clip arser with grammar” hmmm… Ah! CLI parser! 09:20
( github.com/rakudo/rakudo/pull/324 )
AlexDaniel tyil: lonestar is under AGPLv3 but… why? I'm using APGLv3 myself for several things, but in this particular case I don't see the point… I'm really curious, why? 09:32
lizmat just typed "gut push" # bad typing day today indeed :-) 09:33
tyil AlexDaniel: its my go-to license these days, used to be GPLv3
AlexDaniel lizmat: I do that all the time when I'm not in Ctrl+R, and I get really mad that things don't autocorrect commands 09:34
tyil would there be any reason to not use AGPL?
AlexDaniel tyil: I'm not sure… 09:35
say I make a web application that has lonestar built into it to update itself, does it mean that I would have to release the source code? 09:39
I have no idea
tyil im not a lawyer, but from what I understand, yes 09:40
the AGPL intends to spread the libre even on webservices
AlexDaniel which is fine if you're making a webservice, but lonestar is not… 09:41
tyil I know 09:42
AlexDaniel so you're potentially “infecting” stuff by your little thingy that just installs rakudo, and I don't know if it's right or not. It's weird for sure :)
tyil but as I said, it's my default license I go to
how would it "infect" things if it just installs rakudo?
from what I've seen, most people who talk about the dangers of GPL infecting code are FUD 09:43
AlexDaniel well, I thought I gave an example a few messages ago? :)
tyil if you use lonestar to install rakudo, thats completely different from forking it and using that in your site's codebase 09:43
AlexDaniel don't get me wrong, I'm all for AGPLv3. The whole whateverable is under AGPLv3 for a good reason
but using AGPLv3 for an installer… hmmm… does not sound appropriate to me, but maybe it's ok
it was just a question anyway 09:44
tyil you're free to use (A)GPL code as a tool to setup any project
said project is not in any way required to follow the GPL
it is once you take part of the tool and incorporate it directly into your project that the license will start demanding things of your project
tyil but just bundling the entire tool and not modifying it is no problem 09:45
on a related note, did you try lonestar (and if you do, did any issues arise)? 09:46
AlexDaniel tyil: not yet, I'm hiding under the bed because the amount of installers we have nowadays is scaring me :)
tyil last time I referenced one in an article I got yelled at 09:47
and all other solutions proposed then were... lacklustre in my view
AlexDaniel tyil: fwiw the license question was not yelling in any way, I was just curious why one would use AGPL for a non-webservice project and how they see it 09:48
tyil oh, I didnt mean to imply you were part of the yelling 09:49
AlexDaniel just making sure :)
tyil the yelling was before I started on lonestar :p
AlexDaniel I've seen that, yeah
tyil I just use AGPL for new projects unless there's a solid reason not to go with AGPL
AlexDaniel we tend to yell sometimes on IRC. I guess we just need a bit more ♥
it was also reddit I think? 09:50
reddit is unfixable though :P
tyil tbh I could go for some ♥ but my gf isn't physically around :(
what was on reddit?
AlexDaniel discussion about rakudobrew
tyil oh
the time I was involved was in here 09:51
reddit is strangely kind to me unless I talk about perl in a positive light outside of the perl communities :p
AlexDaniel haha
donpdonp hehe 09:52
tyil inspired by JJ's need for analytics I set up that Matomo thing, but I dont like tracking people with js, so I'm now working on a small application to parse nginx logs into a db, and a frontend with cro and react to have decent insight of how many visitors I'm getting 09:53
once I get more positive feedback on lonestar I'll update my perl6 on a raspi guide to use that instead of rakudobrew 09:54
AlexDaniel cool 09:55
timotimo tyil: fwiw, matomo offers an opt-out button that you can include as an iframe 09:56
AlexDaniel what about an opt-in button? 09:57
timotimo perhaps you can change the default 09:57
stmuk what is lonestar?
timotimo anyway, matomo also lets you just feed it the server logs instead 09:58
AlexDaniel stmuk: github.com/Tyil/lonestar
timotimo lonestar is a rebel that tends to jam Dark Helmet's radar with raspberry jam 09:59
who*
stmuk I had a cow-orker who got so into bash he started using its unit test framework 10:00
donpdonp timotimo: only one man would dare give dark helmet the raspberry.
tyil stmuk: I intended it to make it posix sh
but posix sh had no export -f 10:01
stmuk I probably should port rakudup to posix sh TBH. stmuk 2002 would hate me
tyil I wonder how much effort it would be to get server side rendering with react and cro 10:06
stmuk when I saw the old school UNIX guys who produced go used bash I realised the battle was lost 10:07
Zoffix scimon: there's a fails-like test routine that got the same interface as throws-like you can steal: github.com/perl6/roast/blob/master...#L336-L353 10:32
scimon: isa-ok ..., Failure isn't good as it leaves the Failure unhandled and you'll get warned about it if it's GCed. 10:33
AlexDaniel: well, I have enough access and tuits, but what do I need to do? I already brought it up to moritz, but he said he doesn't see an issue: irclog.perlgeek.de/perl6/2018-03-18#i_15935550 10:36
Based on the domain name involved, I'd guess I messed up when seting up alerts.perl6.org 'cause I used the certbot command from repos or something. Basically, not the same certbot that was apparently already in use on the server 10:37
moritz faq.perl6.org/ does seem to have a problem 10:39
yoleaux 08:09Z <AlexDaniel> moritz: not sure if you received my last message, so here it is again. Maybe fix issues with https on some domains: gist.github.com/Whateverable/8c42c...4d3aa6b529
moritz testers too
rakudo.org doesn't yet point to our server, so nothing we can do
collabti.org is outside our control 10:40
Zoffix: I think certbot dosn't create certificates for pure redirect domains, because it needs a document root where it can store the challenge 10:41
Zoffix Is faq. using the wildcard cert instead of separate certbot cert?
moritz there is no wildcard cert 10:42
there is just one cert with several subject names
Zoffix At work I got half a dozen web apps with reverseproxy only setup and they work OK.
moritz which is used for everything on the www.p6c.org apache process
oh
iirc certbot/acme uses a fixed prefix for the challenge 10:43
maybe if you exclude these URL prefixes from the redirects, it starts working
Zoffix Imma run certbot with faq.perl6.org and see what it says.
I never had to worry about prefixes or challenges before :/
moritz it tries /.well-known/acme-challenge/$something 10:44
I might get around to it on the Easter weekend otherwise
Zoffix Attempting to parse the version 0.22.2 renewal configuration file found at /etc/letsencrypt/renewal/www.perl6.org.conf with version 0.19.0 of Certbot. This might not work.
Client with the currently selected authenticator does not support any combination of challenges that will satisfy the CA.
No idea what that means...
moritz it means we have to update certbot, i think 10:45
moritz tries that 10:46
community.letsencrypt.org/t/soluti...e-ca/49983
Zoffix just looked at $work's configs 10:49
Don't see any challenges. Just a bunch of SSL* directives 10:50
ZofBot: would you like a challenge? 10:51
ZofBot Zoffix, 27 megs, cool.
Zoffix You're not supposed to enjoy the challenge!
g2g. Ping me if you need me to try anything with fixing it. 10:54
Zoffix scimon: BTW, if you want to test *just* that you got a Failure and not what exception it contains, you can just use `is` routine: is $o.meth, Failure, "meth returns a Failure" 10:59
scimon Zoffix: That's what I tried first time (is method, Failure) 11:11
Zoffix scimon: it should work. Did you have trouble with it? 11:20
m: use Test; sub z { fail }; is z(), Failure 11:21
camelia not ok 1 -
# Failed test at <tmp> line 1
# expected: (Failure)
# got: (Failure)
Zoffix oops
That's a bug
moritz shouldn't you use isa-ok for that? 11:22
m: use Test; sub z { fail }; isa-ok z(), Failure 11:23
camelia ok 1 - The object is-a 'Failure'
Zoffix scimon: oh nevermind. I'm clearly nit awake. That only tests type objects in $got 11:24
Zoffix scimon: so yeah, use fails-like from that code I linked or isa-ok with manual defusion of failures with .so call on them 11:25
moritz: it doesn't mark them as handled
Zoffix would be +1 on adding fails-like to core Test.pm6 11:28
Lasse Is there a way to interface with SAP RFC? if so can someone point at an example? That would be much appreciated. 11:32
Zoffix m: use Test; sub z { fail }; isa-ok ($_ without z), Failure 11:33
camelia ok 1 - The object is-a 'Failure'
Zoffix eco: sap
buggable Zoffix, Nothing found
Zoffix Lasse: doesn't seem to be anything in ecosystem You could try searching metacpan.org and using what you find with Inline::Perl5 11:34
eco: Perl5
buggable Zoffix, Found 5 results: Inline::Perl5, Digest::MD5, Web::Scraper, Pod::Perl5, Inline::Perl5. See modules.perl6.org/s/Perl5
[Coke] bengoldberg's problem smelled like not handling spaces in paths. 11:58
(but I don't know if rakudobrew ever worked on windows)
scimon Cheers :) 12:23
AlexDaniel moritz: well yeah obviously I meant just the perl6.org ones 12:38
robertle AlexDaniel: if there is anything that I can do regarding R#1663 and similar ones, please let me know. I can do some debugging, but some of this is quite hard so I would need help. for example I don't understand where we create something that can be called from C for a sub reference that we pass to C code... 12:53
synopsebot R#1663 [open]: github.com/rakudo/rakudo/issues/1663 [severe][⚠ blocker ⚠] rakudo 2018.02 test failure on big endian systems in t/04-nativecall/21-callback-other-thread.t
AlexDaniel robertle: I don't know too, unfortunately. But I totally see why we should want to resolve these issues as soon as possible… 12:54
debian testing has no rakudo now. 💩 :(
that said, I'm a bit confused why it throws away the whole package if it doesn't build on some architectures 12:55
robertle debian distinguished between "release" architectures and those that are not, a package needs to work on all release architectures to be a candidate for testing 12:56
AlexDaniel OK makes sense 12:57
ilmari robertle: I thought it only needed to work on all release architectures it has worked on in the past
robertle the maintainer can furtehr restrict that set of architectrues, but the idea there is to use this for functional reasons, not quality. so e.g. a arm-specific bootloader would not be attempted on mips
AlexDaniel ilmari: rakudo did work in the past
on big endian and other stuff
robertle but apart from the technicalities of that process, I think it's a wise thing to do even if painful sometimes. if our nativecall implementation only works on some architectures, then that is clearly a quality problem 12:58
robertle and a quite intriguing one as well! 12:59
AlexDaniel robertle: by the way, if it did work in the past, maybe bisecting it is a reasonable idea? 13:00
who knows, maybe you'll get some clues from the commit it points to
robertle yeah, but from what I have glanced the point where it stoppedworking was when that test was added :) 13:02
AlexDaniel awesome
… maybe skipping the test for now is a reasonable idea?…
not nice, but the rest of rakudo works fine, right?… 13:03
does not resolve the quality issue though
robertle but we'll need working nativecall for lots of things that may not have enough test coverage on their own, e.g. database drivers
AlexDaniel right-right. Just thinking out loud… 13:04
AlexDaniel robertle: thank you for your help by the way 13:04
robertle I am wondering what ppc64 and s390x have in common that other arhcs do not have...
Geth doc/fails-like: 0c15591809 | (Zoffix Znet)++ | doc/Language/testing.pod6
Document fails-like test routine

Impl PR: github.com/rakudo/rakudo/pull/1664 Propspec PR: github.com/perl6/roast/pull/408
13:17
doc: zoffixznet++ created pull request #1876:
Document fails-like test routine
Lasse Zoffix: thanks but I would like to write my program in Perl6. I have never written anything in Perl5, can I use Perl5 modules in Perl6? 13:21
Zoffix Lasse: yeah, that's why I mentioned Inline::Perl5. It lets you use Perl 5 modules in Perl 6, though if you never coded in Perl 5, it might be tough to figure out how to use those modules (and install them too) 13:23
Lasse: I guess you could trailblaze and write a Perl 6 implementation of that stuff :)
sjn Lasse: No need to use Perl5 modules in a Perl6 program, especially when you're learning :) 13:24
Zoffix sjn: is there Perl 6 SAP RFC then? 13:25
.oO( what a terrible name choice to call it "RFC" )
13:26
sjn Zoffix: I'd be surprised. I was just speaking from the KISS perspective :) 13:27
sjn but sure, if the goal is to talk with SAP and learning stuff is secondary, then why not 13:28
Zoffix Looking at guts of metacpan.org/pod/release/PIERS/sap...apnwrfc.pm seems a pretty big task to write an implementation of it 13:32
scimon So if we're converting a Perl5 module to Perl6 do we stick to snake case? Or update methods to kebab case? Thoughts? 13:33
travis-ci Doc build failed. Zoffix Znet 'Document fails-like test routine 13:35
travis-ci.org/perl6/doc/builds/359363683 github.com/perl6/doc/commit/0c1559180933
buggable [travis build above] ☠ Did not recognize some failures. Check results manually. 13:35
timotimo scimon: let's build a metaprogramming module that can switch names around at import time 13:36
Zoffix .tell tbrowder_ docs build have a bunch of warnings about RAKUDO_POD_TABLE_DEBUG stuff. IIRC you implemented that. Perhaps you'll be able to convert the tables in the docs to proper format? travis-ci.org/perl6/doc/builds/359363683#L1375 13:37
yoleaux Zoffix: I'll pass your message to tbrowder_.
scimon That's a plan... 13:40
pmurias tyil: what's lonestar? 13:47
tyil from the first line of the readme: A small Bash application to install the Rakudo Star Perl 6 distribution. 13:48
Zoffix pmurias: github.com/Tyil/lonestar 13:49
tyil I'm at work rn, so I cant answer all questions properly, but if you have any questions, feel free to hl me or make an issue 13:49
pmurias tyil: thanks, it's straighforward enought that looking through the source answered my questions 13:51
tyil :>
glad to hear that 13:52
tbrowder_ Zoffix: noted
yoleaux 13:37Z <Zoffix> tbrowder_: docs build have a bunch of warnings about RAKUDO_POD_TABLE_DEBUG stuff. IIRC you implemented that. Perhaps you'll be able to convert the tables in the docs to proper format? travis-ci.org/perl6/doc/builds/359363683#L1375
Zoffix looks like above travis failure was due to the same bug that makes precomp spectests flop. Similar warnings in output and it works fine after I restarted it 13:55
travis-ci Doc build passed. Zoffix Znet 'Document fails-like test routine 13:58
travis-ci.org/perl6/doc/builds/359363683 github.com/perl6/doc/commit/0c1559180933
buggable New CPAN upload: LibGit2-0.2.tar.gz by CTILMES cpan.metacpan.org/authors/id/C/CT/...0.2.tar.gz 14:11
Lasse Soffix: tx again. I look into it to if it is worth the effort. Perl6 is worth the effort of learning though:) 14:12
abraxxa can the link buggable posts be changed to the metacpan documentation page? 14:34
moritz abraxxa: do you have an example where it should point to?
abraxxa or to modules.perl6.org because it seems metacpan can't display perl 6 module docs
mr_ron m: class C {has $.a = 5}; class C1 is C { method a { return 2 * $!a } }; say C1.new.a 14:37
camelia 5===SORRY!5=== Error while compiling <tmp>
Attribute $!a not declared in class C1
at <tmp>:1
------> 3 C1 is C { method a { return 2 * $!a } }7⏏5; say C1.new.a
expecting any of:
horizontal whitespace
postfix…
mr_ron m: class C {has $.a = 5}; class C1 is C { method a { return 2 * $.a } }; say C1.new.a # how to override default accessor?
camelia MoarVM panic: Memory allocation failed; could not allocate 306928 bytes
moritz mr_ron: return 2 * $!a 14:38
timotimo mr_ron: you have overridden the default accessor there
that's why it infinitely recurses
moritz a refers to the method you are declaring, the default acccessor doesn't exist anymore
mr_ron I'm confused. The first attempt had a syntax error and the second one hangs. 14:39
timotimo yeah, private attributes are private, derived classes can't access them 14:40
but you can call self.C::a
m: class C {has $.a = 5}; class C1 is C { method a { return 2 * self.C::a } }; say C1.new.a
camelia 10
timotimo m: class C {has $.a = 5}; class C1 is C { method a { return 2 * callsame } }; say C1.new.a
camelia 10
timotimo that's another way to reach the original a method
i didn't immediately see you had two classes there, sorry 14:41
mr_ron Thanks. Just curious - any way with ^parents? 14:42
timotimo if you want
m: class C {has $.a = 5}; class C1 is C { method a { my $parent = self.^parents[0]; my $meth = $parent.^find_method("a"); return 2 * self.$meth() } }; say C1.new.a
camelia 10
mr_ron thanks - working on a related doc issue ... 14:43
timotimo btw, it'd be better to get the .^mro
because that's how methods are normally resolved. it's literally the method resolution order 14:44
tyil if anyone around here is using Hash::Merge, I'm going to break it later tonight or tomorrow morning probably (UTC+2)
lizmat tyil: before you do that
could you release a version with an :api in the meta
and then break it, with a different :api in the meta ? 14:45
tyil lizmat: can do
I was gonna add :api<1> and release a 1.0.0 with it
lizmat that would give us an opportunity to test zef for :api specification :-)
tyil but I can do an api<0.1> first
for testing purposes :>
lizmat fwiw, it doesn't have to be a number
afaik
tyil from what I understood its a Version
lizmat ah? it is? 14:46
tyil github.com/ugexe/zef/issues/233#is...-374010261
seems like it differs 14:47
there's no consensus yet :p
lizmat :-( 14:48
Geth doc: 0c15591809 | (Zoffix Znet)++ | doc/Language/testing.pod6
Document fails-like test routine

Impl PR: github.com/rakudo/rakudo/pull/1664 Propspec PR: github.com/perl6/roast/pull/408
14:50
synopsebot Link: doc.perl6.org/language/testing
doc: 86293271f6 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | doc/Language/testing.pod6
Merge pull request #1876 from perl6/fails-like

Document fails-like test routine Thanks! Although it depends on a couple of other PRs, they both look OK.
scimon github.com/Scimon/p6-Proc-InvokeEditor : Almost ready for the 0.1 release. (Needs docs). 15:21
cfa morning all 15:34
github.com/perl6/doc/blob/HEAD/doc....pod6#L664
missing comma?
pmurias re :api isn't it supposed to be for a major rework of the interface rather than just regular breaking changes? 15:34
AlexDaniel` Regular breaking changes xD 15:38
pmurias AlexDaniel`: I might be exposed to npm too much ;) 15:39
pmurias AlexDaniel`: by rework I mean things like Dancer vs Dancer2 or Angular vs Angular2 where the old version is expect to linger around 15:41
Zoffix BTW, since topic of packaging/install was recently discussed, just spotted this thing while downloading Brave browser: snapcraft.io/ 15:42
"Snaps are quick to install, easy to create, safe to run, and they update automatically and transactionally so your app is always fresh and never broken."
Geth doc: 76d90fa4f8 | (Zoffix Znet)++ (committed using GitHub Web editor) | doc/Language/testing.pod6
Fix broken code example; cfa++
15:43
synopsebot Link: doc.perl6.org/language/testing
cfa Zoffix: thanks 15:43
note that the example currently fails to compile as &fails-like is undefined 15:44
might be worth skipping in the interim
(seems like this was merged ahead of time; might just be worth leaving the failure until the next rakudo release) 15:45
Zoffix I think docs are built using latest and greatest rakudo
cfa ah okay 15:47
cfa so it's just my local tests failing (i'm on .03); 15:47
Zoffix It's also a bit weird the docs PR was merged before the impl/spec got merged.
ZofBot: the humans are doing it wrong. Help! 15:48
ZofBot Zoffix, Mother had not died
Zoffix cfa: yeah, it went in just like 2 hours ago
m: use Test; fails-like { sub { fail }() }, Exception 15:49
camelia 1..2
ok 1 - code returned a Failure
1..2
ok 1 - code dies
ok 2 - right exception type (Exception)
ok 2 - Failure threw when sunk
ok 1 - did we fails-like Exception?
cfa nods 15:50
El_Che Zoffix: there is snap, flatpacks, nix, appimage, and 10 others. None has a complete install base 16:00
El_Che Zoffix: atm, snap is more of a deb alternative for Ubuntu than a common Linux installer 16:01
El_Che Zoffix: I am a little reluctant in investing time on snaps as they feel very closed garden-like 16:01
buggable New CPAN upload: Proc-InvokeEditor-0.0.2.tar.gz by SCIMON cpan.metacpan.org/authors/id/S/SC/...0.2.tar.gz
scimon (So I may have had not a huge amount to do today) 16:03
tyil lizmat: I uploaded Hash::Merge 0.2.1, which contains an api key 17:43
(and doesnt break usage for other people yet) 17:45
buggable New CPAN upload: Hash-Merge-0.2.1.tar.gz by TYIL cpan.metacpan.org/authors/id/T/TY/...2.1.tar.gz 17:51
buggable New CPAN upload: PDF-Class-0.1.1.tar.gz by WARRINGD cpan.metacpan.org/authors/id/W/WA/...1.1.tar.gz 18:21
mspo <guyfromanotherchat> ISTM we should have better programming notation for "append string/list" than `+` in 2018. 18:24
<guyfromanotherchat> seems like there should be a suitable Unicode character.
mspo <mspo> omg use perl6 18:25
Bowlslaw ewww 18:32
um
what is "better" than that?
it's one universal simple character
keep your complexity creep away from meee
mspo I prefer push(), append(), unshift()
El_Che << 18:33
is also nice
(ruby)
mspo + is too overloaded :)
El_Che the append function in golang is awful
Bowlslaw golang is aweful
hash tag autist language wars
Bowlslaw runs
El_Che arraySlice = append(arraySlice, "foo")
I like go 18:34
in a lot of ways the opposite of perl6
mspo I thought slices were immutable
El_Che I don't like middle ground langs :)
mspo: you assign a new one
with the same name
mspo El_Che: L1 ++ L2 18:35
masak mspo: in 007 we vacillated between a lot of options for the array concat operator. ++ was the main contender, but it doesn't quite fly in 007 because infixes share a namespace with postfixes, because 007 doesn't do Perl 6's whitespace sensitivity thing. 18:36
mspo: in the end, we just went with array.append(array2) instead 18:37
er, array.concat(array2)
like JavaScript does
mspo masak: ++ like that is erlang syntax
El_Che I don't see the evil in overloading + for lists
masak yeah. I like how it looks, but postfix:<++> has first dibs on that spelling
masak El_Che: it's a matter of taste, I think. 18:38
El_Che: Perl wants to keep its operators for "one" thing.
moritz it's a matter of philsophy
mspo I'm not a big fan of overloaded in general
it's kind of okay in perl because sigils give you the type most of the time
moritz you can only do coercion of arguments if you stick to one semantics for an operation
mspo at least list vs scalar 18:39
moritz the python model also works where "+" means "mush two things together", so it's sum for numbers, concat for arrays and strings etc., but then you can't do coercion and have it dwim
masak it's been a real eye-opener to be a language designer for a few years, even of a toy language like 007. the tradeoffs really box you in sometimes. 18:40
moritz: which is fine, because Python doesn't do a lot of coercion/dwim anyway
El_Che moritz: good point about the sigils 18:42
masak that was mspo :) 18:43
also, in Perl 6, the sigils give you more of an interface/API than the actual type
mspo @list1 + @list2 is pretty clear thanks to @, is what I meant. l1 + l2 could be freaking anything
masak like % means it's something Associative, possibly backed by a Hash, or maybe something else 18:44
El_Che mspo: well, it's ok if the lang is typed, though
mspo El_Che: sure
masak I've been half-wanting to make `l1 + l2` mean `l1.add(l2)` in 007 -- rather than Perl 6's `infix:<+>(l1, l2)` -- because that'd make it easier for custom types to provide their own operations 18:45
but I'm not sure. I don't feel strongly that that'd be a better way forwards than just having multis 18:46
El_Che masak: what was the itch for 007?
masak provide a test-bed for macros, a code base for quick experimentation and iteration
El_Che a feedback loop for general perl6? 18:47
masak yes
the above musings are part of the eternal tension of wanting to implement things in a simple/consistent way, but also wanting to stick close to Perl 6, so that lessons are transferable
El_Che a thin line 18:48
Bowlslaw hey guys I have a question about perl 6 and how it interacts with database, and also OOP design 19:00
stackoverflow.com/questions/495224...2#49530712
the person says, 'You might want to change the insert method to a submethod that instantiates the item and inserts it into the database.'
what does he mean by submethod and how would I instantiate the item and insert it? 19:01
also aren't submethods non-inheritable? so i would have to write an insert method for each of my classes
buggable New CPAN upload: Hash-Merge-1.0.0.tar.gz by TYIL cpan.metacpan.org/authors/id/T/TY/...0.0.tar.gz 21:11
buggable New CPAN upload: Config-1.3.5.tar.gz by TYIL cpan.metacpan.org/authors/id/T/TY/...3.5.tar.gz 21:41
Herby_ o/ 21:52
buggable New CPAN upload: App-Assixt-0.2.4.tar.gz by TYIL cpan.metacpan.org/authors/id/T/TY/...2.4.tar.gz 22:11
tyil Herby_: hi 22:12
glad to hear assixt finally installed for you
in an hour or so you can install v0.2.4, which is a couple of orders of magnitude faster 22:13
parse time went down from 13s to sub 0.5s 22:14
0.145 on my laptop
Herby_ awesome, I'll give it a whirl 22:15
tyil time to sleep tho 22:16
gn
Herby_ o/