»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
00:00 Cabanossi joined 00:06 raschipi left 00:11 BenGoldberg left, BenGoldberg joined 00:12 BenGoldberg left, BenGoldberg joined
skids Hrm. I have an inexplicable situation. Essentially I have this in nqp: nqp::say("1"); try { thing }; nqp::say("2"); ...inside a few loops in some MetaModel core code. when run, It hangs printing a lot of "2"'s and no "1"s. 00:13
00:15 Actualeyes left
tbrowder hi #perl6 00:20
00:20 wamba left
skids o/ 00:20
00:21 BenGoldberg left 00:22 BenGoldberg joined
tbrowder i'm trying to install module SSH::LibSSH (with zef) and get a failure expecting MAST::Frame which can't be found and i don't find it in the ecosystem 00:23
skids It seems to be running the try over and over again... I can get a CATCH block to output interleaved with the "2"s.
tbrowder skids: hello! 00:25
skids nqp/MoarVM/lib/MAST/Nodes.nqp is where MAST::Frame comes from. 00:26
Maybe your nqp has come unsynced with your rakudo?
00:40 ramortegui joined 00:43 Cabanossi left 00:45 Cabanossi joined 00:46 pilne joined 00:47 Kyo91_ left 00:48 idiosyncrat joined
skids OK, so it seems what happened was a subsequent exception after the "try" thought it was in the "try" and control flow skipped back to the try block. 00:48
00:50 idiosyncrat left
MasterDuke skids: that's...interesting... 00:57
skids Kinda hard to golf the whole MetaModel though :-) 00:58
01:00 Kyo91_ joined 01:14 Cabanossi left 01:15 Cabanossi joined 01:28 cdg joined 01:33 cdg left 01:44 Cabanossi left, ilbot3 left 01:45 Cabanossi joined 01:51 ilbot3 joined, ChanServ sets mode: +v ilbot3, cdg joined 01:56 cdg left 02:00 greppable6 joined, ChanServ sets mode: +v greppable6
Geth doc/master: 4 commits pushed by (Will "Coke" Coleda)++ 02:01
02:01 piojo joined 02:02 u-ou- joined 02:06 Kyo91_ left
[Coke] m: $*ERR=Nil; note 3; 02:07
camelia No exception handler located for catch
at SETTING::src/core/Exception.pm:395 (/home/camelia/rakudo-m-inst-2/share/perl6/runtime/CORE.setting.moarvm:print_exception)
from SETTING::src/core/Exception.pm:452 (/home/camelia/rakudo-m-inst-2/share/pe…
skids eh... I know I didn't just fix all those TODOs... what's the roast branch to spectest on these days? 02:25
[Coke] in "multi sub", the "sub" is optional. Ditto "proto sub" ? 02:26
skids Yes and I think so.
MasterDuke skids: should be just master
02:27 AlexDaniel left
skids Oh... is 6.c.errata dead now? 02:27
src/core/List.pm:proto flat(|) {*} # Well, it's gotten away with here at least 02:28
MasterDuke no, but new tests are added to master
02:31 snarkyboojum left
[Coke] errata is for changes that differ from the original christmas release, but hopefully in ways that clarify or reduce other issues. 02:31
like, if a test incorrectly checked exception test or that something threw adhoc, instead of a specific exception, e.g. 02:32
02:34 noganex joined 02:36 noganex_ left 02:38 u-ou- left
Geth doc/coke/multi: 58dbd77e6b | (Will "Coke" Coleda)++ | xt/examples-compilation.t
add test to avoid multi sub
02:40
doc/coke/multi: 028f2bbcc9 | (Will "Coke" Coleda)++ | 34 files
avoid multi sub
02:43 Actualeyes joined 02:53 u-ou- joined
skids At long last, I have reworked my rolevolution patch: gist.github.com/skids/18fa6fb1de77...6e82e9fcc2 02:54
02:59 cdg joined 03:00 travis-ci joined
travis-ci Doc build failed. Will "Coke" Coleda 'avoid multi sub' 03:00
travis-ci.org/perl6/doc/builds/268586063 github.com/perl6/doc/compare/58dbd...8f2bbcc929
03:00 travis-ci left
buggable [travis build above] ☠ Did not recognize some failures. Check results manually. 03:00
03:04 u-ou- left, cdg left 03:06 u-ou- joined 03:12 Cabanossi left 03:15 Cabanossi joined 03:17 u-ou- left 03:21 piojo left 03:23 u-ou- joined 03:37 Ven`` joined 03:43 Ven`` left 03:48 u-ou- left 03:53 raschipi joined 03:57 Cabanossi left, todd joined 03:59 piojo joined, Cabanossi joined 04:02 raschipi left
todd Hi All, it is imperative that I get a program going to email me status reports on a RAID assembly (Fedora 26 Linux). Because of github.com/retupmoca/P6-Net-SMTP/issues/17 I can not eMail through Perl6's Net::SMTP. I do not want to call mailx and I really, really do not want more Perl 5 code to maintain. I was thinking my best route to eMail would be calling the system's Email::Sender::Transport::SMTP. Do you guys have an easier 04:02
04:08 cdg joined 04:13 cdg left
Juerd On a typical Unix-like system, the easiest and most reliable way to send email from scripts is to let the MTA handle it. Practically every system with an MTA will have a /usr/sbin/sendmail that will inject a message into the right spooler. 04:14
The MTA then handles SMTP to send it to a remote host. If the system does not have an MTA yet, and you're root, you could install ssmtp, which is a dummy MTA which will just send everything to a smarthost over SMTP. 04:15
skids Try an P5 module via Inline::Perl5 maybe?
todd I still look at ssmtp as this is an secure smtp problem with Net::SMTP. I have the WORST luck trying to use Inline::Perl5. 04:20
Juerd with run(:in, </usr/sbin/sendmail -t -oi>).in { .print: "To: [email@hidden.address] [email@hidden.address] example\n\nHello, world!"; .close } 04:23
Just be aware that newlines in headers create new headers (unless folded) so be careful with unknown strings in the headers :) 04:24
todd where does the message body go? 04:25
Juerd todd: Just to avoid confusion: with ssmtp I meant wiki.debian.org/sSMTP -- i.e. simple smtp, not secure smtp
simple smtp does support secure smtp though :)
afk # off to bed, 6:26 am here... 04:26
todd this thing needs to talk ssl on port 465
04:34 mr-foobar left 04:35 mr-foobar joined
skids Are you using ::Simple or ::Raw? 04:37
todd Net::SMTP 04:41
will look at what modules I import
use Net::SMTP; use Email::MIME;
skids Are you passing :raw to .new? 04:42
todd my $client = Net::SMTP.new(:server( $smtp ), :port( $port ), :ssl, :starttls, :debug( 1 ) )
don't think so.
skids Ok, maybe there's someting that can be done... looking. 04:43
todd github.com/retupmoca/P6-Net-SMTP/issues/17 crashes on port 465 with smtp.zoho.com
error:1408F119:SSL routines:SSL3_GET_RECORD:decryption failed or bad record mac 04:44
here is a three liner to simulate the crash
#!/usr/bin/env perl6 use Net::SMTP; my $client = Net::SMTP.new( :server( "smtp.zoho.com" ), :port( 465 ), :ssl, :starttls, :debug( 1 ) ); 04:45
skids Yeah it's because the protocol version is not being set, I think. OpenSSL:: has an option for that, IO::Socket::SSL not so much. But it could also be the libssl version on that system.
There are a few other similar bug reports on those packages. 04:46
todd believe it or not, mailx works.
04:55 wamba joined 04:56 kannan left 04:59 khw left
skids First IO::Socket::SSL needs to support passing extra options to OpenSSL::. Then Net::SNMP needs to support passing extra options to IO::Socket::SSL. Both of the latter could use a good dose of interface consistency and dependency injection. 05:01
todd Can I alter my code to support this? 05:02
05:03 mr-foobar left
skids Unfortunately it would be a lot of copy and paste, as the call to OpenSSL.new is hidden in a monolithic private method. 05:03
todd Is there a way to waeve that into the three liner I sent?
skids Hah, no :-) 05:04
todd okay. How do I can the system's Email::Sender::Transport::SMTP ?
05:07 mr-foobar joined
todd call not can 05:09
skids One of the github issue users says starttls worked for him... hmmm.
todd port 465? 05:10
my $client = Net::SMTP.new( :server( "smtp.zoho.com" ), :port( 465 ), :starttls, :debug( 1 ) ); 05:11
just hangs
skids No I guess I'm reading that wrong. It looks like you get that SSL3 message if you connect to a plain connection and try to do ssl: github.com/sergot/io-socket-ssl/issues/17 github.com/sergot/openssl/issues/22 (That is for XMMS but TLS is TLS no matter what you are running over it) 05:13
Oh I guess your error is a bit different. 05:14
todd How about a call to a C module (enter the "dark side")? 05:16
Tha time out finally came bac: 05:17
<== Start argument to substr out of range. Is: 3, should be in 0..0; use *-3 if you want to index relative to the end in method get-response at /home/tony/.perl6/sources/C7BFE131D057F94A1EC6C5CBF4DFC8C731D85400 (Net::SMTP::Raw) line 13 in method start at /home/tony/.perl6/sources/B0AFFC7E1CD3A465D71AF333700CF7086E4870E5 (Net::SMTP::Simple) line 59 in method new at /home/tony/.perl6/sources/AF0C4F60F05B28648456130019BA1D9C3B2FE938 (N
05:20 Guest69863 joined
skids github.com/sergot/openssl/issues/1 shows that SSL3 error, but supposedly OpenSSL:: had it fixed in issues 34 and 35. 05:21
05:22 pilne left
skids Yeah the rest of those errors are just garbage left over from not handling the original error. 05:24
todd is zef now support on Fedora 26's repo, or do I still have to github it? It does not show up on pbone or dnf 05:28
skids I dunno I do all my Perl6 stuff with git.
todd I try to stay with the repo's if I can 05:30
skids Have you tried openssl s_client -connect <mailhost>:465 to verify it is not some problem on the system? 05:31
todd will try. But I do communicate with this server over tls and Thunderbird 05:32
skids ah.
todd openssl s_client -connect mail.zoho.com:465
hangs
poop!
skids Should... until you EHLO.
todd still hangs 05:33
skids ^D? 05:34
05:34 mr-foobar left
todd what does ^D? mean? 05:35
preaction Ctrl+D
05:36 mr-foobar joined
skids control-d. Should close the connection. If it doesn't then you really are hung and not just spinning in a protocol. 05:36
todd I am ssh'ed into a fully updates Fedora 26 server. I am trying to zef in the pieces needed for my three line crash test 05:38
05:39 TreyHarris left 05:40 TreyHarris joined
todd zef is having fun insatlling Net::SMTP 05:41
Searching for missing dependencies: Email::Simple, MIME::Base64, Digest::HMAC, Digest, IO::Socket::SSL
skids Did s_client say anything at all? 05:42
todd no
05:43 Cabanossi left
todd over on the f26 server, my $client = Net::SMTP.new( :server( "smtp.zoho.com" ), :port( 465 ), :starttls, :debug( 1 ) ); 05:43
gives
Type check failed in binding to parameter '@seps'; expected Positional but got Str ("\r\n") in method get at /usr/lib64/perl6/site/sources/AF0C4F60F05B28648456130019BA1D9C3B2FE938 (Net::SMTP) line 24 in method get-response at /usr/lib64/perl6/site/sources/C7BFE131D057F94A1EC6C5CBF4DFC8C731D85400 (Net::SMTP::Raw) line 11 in method start at /usr/lib64/perl6/site/sources/B0AFFC7E1CD3A465D71AF333700CF7086E4870E5 (Net::SMTP::Simple) line 05:44
05:44 Cabanossi joined
skids Wasn't starttls on 587? 05:45
todd oops, uncomment the wrong line
my $client = Net::SMTP.new( :server( "smtp.zoho.com" ), :port( 465 ), :ssl, :debug( 1 ) ); 05:46
Cannot locate native library 'libssl.so': libssl.so: cannot open shared object file: No such file or directory in method setup at /usr/lib64/perl6/sources/24DD121B5B4774C04A7084827BFAD92199756E03 (NativeCall) line 316 in method CALL-ME at /usr/lib64/perl6/sources/24DD121B5B4774C04A7084827BFAD92199756E03 (NativeCall) line 328 in method new at /usr/lib64/perl6/site/sources/685BE85E0DDBD365D590D9B90C50E58E76D0AB36 (OpenSSL) line 36 in
skids Missing symlink or something would be my guess. 05:47
todd my $client = Net::SMTP.new( :server( "smtp.zoho.com" ), :port( 587 ), :starttls, :debug( 1 ) );
Type check failed in binding to parameter '@seps'; expected Positional but got Str ("\r\n") in method get at /usr/lib64/perl6/site/sources/AF0C4F60F05B28648456130019BA1D9C3B2FE938 (Net::SMTP) line 24 in method get-response at /usr/lib64/perl6/site/sources/C7BFE131D057F94A1EC6C5CBF4DFC8C731D85400 (Net::SMTP::Raw) line 11 in method start at /usr/lib64/perl6/site/sources/B0AFFC7E1CD3A465D71AF333700CF7086E4870E5 (Net::SMTP::Simple) line 05:48
symlink to where?
skids some filename libssl is hiding as, with a bunch of numbers after the libssl :-)
05:49 leont joined
skids Anyway I should have gone to bed 2 hours ago. Good luck. Sorry I can;t keep my eyes open at this point. 05:50
todd thank you for the help!
I have to go too
05:54 todd left 05:56 skids left 06:05 mr-foobar left 06:06 BenGoldberg left, mr-foobar joined 06:16 Guest69863 left 06:26 wamba left 06:35 mr-foobar left 06:40 mr-foobar joined 06:41 |oLa| left 06:42 Cabanossi left 06:44 Cabanossi joined, lizmat left 06:45 lizmat joined 06:50 lizmat left 07:05 |oLa| joined 07:06 |oLa|1 joined 07:07 leont left, |oLa| left 07:08 lizmat joined 07:13 Cabanossi left 07:14 Cabanossi joined 07:27 Skarsnik joined
Skarsnik hello 07:28
lizmat Skarsnik o/ 07:32
07:43 ufobat joined 08:03 espadrine joined 08:05 piojo left 08:18 ufobat left 08:20 nadim joined
Skarsnik hm travis-ci.org/perl6/DBIish/builds/268607217 is that a zef issue§ 08:21
08:24 |oLa|1 left, cdg joined 08:28 cdg left 08:36 araraloren joined 08:40 Exodist left 08:41 Exodist joined 08:44 TEttinger left 08:45 nadim left, Exodist left 08:47 lizmat left
timotimo yeah, that rakudo is too old 08:48
but the latest rakudo version has trouble, too 08:49
Skarsnik oh not the same error 08:50
timotimo yeah 08:51
Skarsnik damn everything fail
did it worked for the star release? 08:52
timotimo it should, no?
08:57 nadim joined, smls joined 08:58 Exodist joined, lizmat joined
smls Is perl6.fail down for everyone? 08:58
Skarsnik isup.me/ 08:59
but yes
smls Zoffix runs that page, right? Is it planned downtime? 09:00
(It's very helpful for browsing Rakudo tickets...) 09:01
Skarsnik i should have a vm/chroot set for dbiis 09:02
09:02 Kyo91_ joined
timotimo i believe zoffix stopped renewing the extra domains he got 09:04
09:05 mr-foobar left 09:07 Kyo91_ left
Skarsnik working with one hand is annoying x) 09:08
09:11 Exodist left, atroxaper joined 09:12 Exodist joined
atroxaper Hello! 09:13
I try Dancer2 with Inline::Perl5. It works well. Do somebody know how I can run "perl6 app.p6" as a daemon. I mean perl6's process closed when I close shell. 09:15
09:17 mr-foobar joined
smls timotimo: Is it available under a different domain? 09:19
atroxaper I found 'setsid'! :)) 09:27
Skarsnik timotimo, sry too tired to look at dbiish :( 09:35
timotimo smls: not entirely sure 09:43
trying to at the same time get something presentable for a lightning talk and pay attention to jnthn's talk 09:44
i think i'll close my laptop and watch attentively instead of struggling with my code :D
09:48 emo joined, cdg joined 09:49 lizmat left 09:51 lizmat joined 09:52 setty1 joined, lizmat left 09:53 cdg left 10:02 grondilu_ left 10:09 darutoko joined 10:13 Cabanossi left, lichtkind left 10:14 Cabanossi joined
nadim hi, weird error message: Type check failed in binding to parameter 'val2'; expected Any but got Mu (Mu). The line looks like: multi method get_elements (Stash $s) { $s.sort(*.key)>>.kv.map: -> ($k, $v) {$k, ' => ', $v} } I am a bit lost 10:16
passed test before I pulled the latest rakudo
10:18 emo left 10:22 rindolf joined 10:24 lichtkind joined 10:26 mr-foobar left
timotimo got a fix 10:28
but now it's lunch time and i have to go 10:29
gist.github.com/timo/805ace7f4fbd7...f4473adc2a test this please
bye
samcv hmm trying to see if this setup i did for travis so it will capture core dumps from a segfault and then have gdb print a backtrace afterward
but it's not triggering. so i guess i will have to just write something to force it to trigger 10:30
10:36 mr-foobar joined 10:41 mr-foobar left 10:44 espadrine left
samcv hmm anyone have any clue why *this* is happening travis-ci.org/samcv/MoarVM/jobs/268644978#L1073 10:46
hmm ah maybe i haven't pushed the tags to my branch
that's it :)
10:50 Exodist left 10:52 Exodist joined 10:56 Ven`` joined
smls m: say ((Mu) => 42).kv; 10:57
camelia Type check failed in binding to parameter 'val1'; expected Any but got Mu (Mu)
in block <unit> at <tmp> line 1
smls nadim: ^^ golfed
A bug in type `Pair`, it seems. 10:58
10:59 ramortegui left 11:02 margeas joined
smls bisectable6: say ((Mu) => Mu).kv; 11:03
bisectable6 smls, Bisecting by exit code (old=2015.12 new=6cec6b7). Old exit code: 0
smls, bisect log: gist.github.com/03a10377df0b3e0409...9330750868
smls, (2017-08-13) github.com/rakudo/rakudo/commit/30...1310e9fd0f
11:06 mr-foobar joined
smls nadim: I reported the bug as RT #131962 11:11
synopsebot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=131962
smls In the meantime, you can work around it by replacing `.kv` with `.&{.key, .value}`
Or by destructuting the `Pair`s inside the signature, like `-> (:key($k), :value($v))` or `-> (:$key, :$value)` 11:12
11:15 Exodist left
smls *destructuring 11:18
Ah, sorry, I didn't realize that ‎timotimo‎'s fix referred to this very issue. 11:21
nadim smis++ 11:22
And I didn't realize either, thought he was talking to you
How dow one clean the rakudo build artefacts? a make clean didn't do the trick, subsequend build did fail (when I was trying to find which version was buggy) 11:23
MasterDuke make realclean frequently is more aggresive 11:24
11:25 Exodist joined
Skarsnik add a test for this pair bug? :) 11:26
moritz git clean -xdf # fairly aggressive, works always 11:27
nadim moritz: that seems to be needed, reminds me how much make can suck sometimes 11:28
11:29 Exodist left
nadim What would be really nice is if the error message points at where the error is (Rakudo) rather than where the error originate (my code) is there a way to get that? 11:31
smls nadim: perl6 --ll-exception -e 'say ((Mu) => Mu).kv; 11:32
Which points to src/core/Rakudo/Iterator.pm:3064, which seems to be exactly the line that timotimo changed in that diff. 11:33
nadim I'm building the patched version, I'll keep that in mind next time I have so weird error. 11:34
11:35 Exodist joined 11:40 Exodist left, Exodist joined 11:43 lizmat joined
nadim Patch does not work, still the same error, or I did something wrong. 11:47
11:52 MasterDuke left
nadim but using .&{.key, .value} does 11:53
timotimo: ^^
11:58 Cabanossi left
moritz m: say ((Mu) => Mu).kv 11:58
camelia Type check failed in binding to parameter 'val1'; expected Any but got Mu (Mu)
in block <unit> at <tmp> line 1
11:59 Cabanossi joined
nine atroxaper: I usually just let systemd start my daemons 12:01
Very exciting: mi.cro.services/ 12:02
12:03 nattefrost joined
timotimo probably needs an exact same change a few lines below 12:09
12:16 Guest19820 is now known as masak
moritz nine: what, we have HTTP/2 in Perl 6? I never know 12:17
12:18 Aaronepower left
moritz *knew 12:20
no mention of a license or link to sources though :(
nine jnthn promised to upload today :) License is Artistic 2 12:23
moritz github.com/croservices/
12:23 Aaronepower joined
smls bisectable6: await do for ^20 { start dir("/").eager } 12:25
bisectable6 smls, Bisecting by exit code (old=2015.12 new=6cec6b7). Old exit code: 1
smls, bisect log: gist.github.com/97d96022fdfed416e6...df5b2b9353
smls, (2017-08-15) github.com/rakudo/rakudo/commit/23...50ec570b9d
smls \o/ 12:26
Looks like this commit by jnthn++ fixed RT #129845
synopsebot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=129845
smls Is there a way to write a spectest for something like this?
I mean the test-case pretty much always failed before, but was still probabilistic... 12:27
12:36 lizmat left 12:37 lizmat joined
moritz I guess dir('/') won't work on windows? 12:37
12:41 sena_kun joined 12:42 araraloren_ joined 12:43 Cabanossi left 12:44 araraloren left, Cabanossi joined
Geth ecosystem: 05dad74a71 | Altai-man++ (committed using GitHub Web editor) | META.list
Add cro to the ecosystem
12:45
12:51 woolfy joined 12:52 andrzejku_ joined
[Coke] moritz: need a test on win64? 12:53
smls moritz: The test only needs `dir()` to construct a bunch of IO::Paths, it doesn't need to be directory / 12:54
So the test could create a temporary directory with a bunch of files in it, and use that... 12:56
moritz smls: or simply run dir('.') 12:59
smls My question was more regarding the probabilistic nature of the bug. I.e. are flappy spectests allowed if the false positives are rare?
moritz flappy tests are mostly unwanted, and should be skipped 13:00
but once the bug is fixed, they shouldn't flap anymore
smls yes, now the test reliably passes
But if that part of Rakudo is ever broken again, the test could conceivably only fail 99% of the time instead of 100% of the time... 13:01
moritz that's fine 13:02
smls ok
moritz we'll notice a 0% -> 99% failing quote, I hope :-)
13:03 atroxaper left
smls moritz: What path will `dir(.)` be during a spectest run? 13:04
eh, `dir('.')`
13:13 ChoHag left 13:14 woolfy left 13:20 BenGoldberg joined, ChoHag joined
moritz smls: rakudo's source tree 13:21
smls ok
nine I'd rather people wouldn't make that assumption 13:27
A slightly better version would be "a source tree of a Perl 6 implementation", but not assuming anything at all would be much better still
13:29 nadim left 13:31 ChoHag left 13:38 sumdoc joined
sumdoc Is there any data structure in perl6 like set in python that doesn't contain repeted elements? 13:39
nine sumdoc: set ;)
sumdoc: or rather Set, but there's a set constructor
m: my $s = set 1, 1, 2, 3, 2; say $s 13:40
camelia set(1 2 3)
sumdoc nine OK lemme see
lizmat m: dd (1,2,3).Set 13:41
camelia set(1,3,2)
13:42 ChoHag joined
sumdoc lizmat what is dd 13:43
my $string = "Pokhara is is city beautiful city of Nepal";
my @aray= $string.split(" ").words; say @aray.Set;
13:44 setty1 left
sumdoc Is it alright? I just want unique elements of the sentence string in an array. nine lizmat 13:44
Ok now I have made set with unique elements. How to access individual element of the set? 13:45
lizmat m: my $s = "Pokhara is is city beautiful city of Nepal".words.Set; dd $s.keys 13:46
camelia ("beautiful", "city", "is", "Nepal", "of", "Pokhara").Seq
lizmat dd is the tiny data dumper, so small it lost the t 13:47
sumdoc lizmat :)
lizmat although if you just want to iterator over the unique words, you could use .unique
13:47 skids joined
lizmat m: dd "Pokhara is is city beautiful city of Nepal".words.unique 13:48
camelia ("Pokhara", "is", "city", "beautiful", "of", "Nepal").Seq
lizmat m: dd "Pokhara is is city beautiful city of Nepal".words.unique.sort(*.fc)
camelia ("beautiful", "city", "is", "Nepal", "of", "Pokhara").Seq
sumdoc lizmat Aye thats cool
But what if I want to access in this set "set(beautiful, city, is, Nepal, of, Pokhara)"
lizmat m: my $s = "Pokhara is is city beautiful city of Nepal".words.Set; dd $s<is> 13:49
camelia Bool::True
lizmat m: my $s = "Pokhara is is city beautiful city of Nepal".words.Set; dd $s<isnot>
camelia Bool::False
skids m: my $s = "Pokhara is is city beautiful city of Nepal".words.Set; dd $s<is city of town> 13:51
camelia (Bool::True, Bool::True, Bool::True, Bool::False)
13:52 lizmat_ joined 13:55 lizmat left
sumdoc lizmat Alright. Can I find the total number of elements in the above set. I thought it will work but not "my $string = "Pokhara is is city beautiful city of Nepal"; $string.words.Set.elems;" 13:55
nine ?? 13:56
lizmat_ sumdoc: unique words or just number of words? 13:57
sumdoc unique words. Yeah its working "Pokhara is is city beautiful city of Nepal"; $string.words.Set.elems;"
lizmat_ m: dd "Pokhara is is city beautiful city of Nepal".words.unique.elems
camelia 6
lizmat_ no need to make it a Set then
13:58 lizmat_ is now known as lizmat
sumdoc Is dd and say same. They r working like they are same.dd $string.words.Set.elems; and say $string.words.Set.elems; are working similarly izmat 13:59
skids dd will be more verbose much of the time.
.say/.gist is for casual human use, .print/.Str/.perl and dd is for programs and heavy debugging. 14:01
lizmat 'dd $a' is basically short for 'note $a.perl'
plus some extra features 14:02
skids m: my %a = a => { a => 2, b => [4,3,3] }; dd %a; dd %a 14:03
camelia Hash %a = {:a(${:a(2), :b($[4, 3, 3])})}
Hash %a = {:a(${:a(2), :b($[4, 3, 3])})}
skids oops.
m: my %a = a => { a => 2, b => [4,3,3] }; say %a;
camelia {a => {a => 2, b => [4 3 3]}}
lizmat s:n2d/dd/say/ :-)
*2nd rather :-)
smls lizmat_: According to the git log, last year you split off the multidim candidates of postcircumfix [ ] to `multidim_slice.pm` and gave them thorough NQP implementations. 14:04
lizmat_: But the multidim candidates of postcircumfix { } still remain in `hash_slice.pm`, in a seemingly half-finished state (much shorter and less NQP-y code, bug RT #130947, binding being NYI, etc.) 14:05
synopsebot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=130947
smls lizmat_: I'm looking into that bug, but I'm wondering how to proceed... Should those candidates be moved to `multidim_slice.pm` as well, and be reimplemented to mirror their [ ] equivalents?
lizmat smls: checking 14:07
14:07 epony left 14:11 sumdoc left, sumdoc joined 14:12 epony joined 14:20 epony left
sumdoc lizmat for the previous string I want to write more effiicent version of this "for $string.split(" ").words -> $pokh { say $pokh if $pokh.chars > 5; };" 14:21
my $string = "Pokhara is beautiful city of Nepal";
I want to return an array which returns the words with chars more than 5 14:22
lizmat m: dd "Pokhara is is city beautiful city of Nepal".words.grep(*.chars > 5) 14:23
camelia ("Pokhara", "beautiful").Seq
lizmat m: dd "Pokhara is is city beautiful city of Nepal".words.grep(*.chars > 5).unique 14:24
camelia ("Pokhara", "beautiful").Seq
14:24 hobbs left
smls sumdoc: `.split(" ").words` is redundant... '.split' returns a sequence of fields, and then the `.words` method concatenates it to a single string again and then splits that string into words all over again. 14:25
14:28 skids left 14:30 epony joined 14:31 hobbs joined, hobbs left, hobbs joined 14:32 nowan left
sumdoc smls I see. How to return an array which returns the words in a sentence string with chars more than 5? 14:32
Zoffix smls: oh yeah, the domain expired 'cause I'm pushing for rename... Lemme configure a subdomain on rakudo.party
sumdoc: $string.words.grep(*.chars > 5) 14:33
14:33 Guest69863 joined
Zoffix well I guess it's more 'cause the .party domains are expensive after first year and there's no point in having a whole domain just for that site. 14:34
sumdoc Zoffix Looks cool. Short and sweet
14:34 nowan joined
masak oh hai 14:35
smls o/ masak
14:36 lancew joined
masak today I had a bug because I didn't realize Bool ~~ Int ;) 14:36
sumdoc Zoffix why is this not valid list comprehension "($_ if $_.chars>5 for $string.words)
masak m: say Bool ~~ Int
camelia True
14:37 lucasb joined
lizmat m: dd Bool.enums # look at the values :-) 14:37
camelia {:False(0), :True(1)}
masak yes 14:38
agree
smls m: enum A <Foo Bar>; say Foo ~~ Int;
camelia True
masak but I still feel it's a has-a relationship rather than an is-a relationship
smls m: enum A (Foo => "a", Bar => "b"); say Foo ~~ Str;
camelia True
Zoffix sumdoc: it is valid.
m: my $string = "fooffff barffff"; say ($_ if $_.chars>5 for $string.words)
camelia (fooffff barffff)
Zoffix smls: back up: fail.rakudo.party/ 14:40
smls Zoffix: thank!
*thanks
14:40 nhywyll joined
sumdoc Zoffix I thought this would also be valid but throwing error "($lu if $lu.chars>5 for $string.words);" 14:40
14:41 Guest69863 left, buggable left
smls sumdoc: Where have you declared $lu ? 14:41
14:41 buggable joined, ChanServ sets mode: +v buggable
Zoffix sumdoc: $_ variable is a special topical variable that automatically gets the value being iterated over in that construct. You can't just change it to $lu 14:42
sumdoc smls Even after declaration my $lu, its throwing error
lizmat smls: can't look at it now, but I vaguely recall that the ones I added are optimized candidates, and the old ones just take all the cases that aren't handled by the optimized candidates 14:43
Zoffix &
smls lizmat: The {; } ones aren't just unoptimized though, they're incomplete and partially incorrect.
sumdoc Zoffix I thought that would work. This is valid in python [w for w in string if len(w) >5] 14:45
smls sumdoc: The `for w in` part gives the loop variable the name `w` in that Python code. Perl 6 does not support that for "list comprehensions". 14:46
Zoffix sumdoc: it's just a bit different in this language. You don't even have to declare variables at all in Pythong, right?
*Python
lizmat smls: very likely :-) I haven't touched them :-) 14:47
smls sumdoc: In Perl 6, using `for` and `if` as statement modifiers (a.k.a. "list comprehension") always uses the special variable `$_` (called the "topic") as the loop variable.
14:47 khw joined
smls sumdoc: Only the block forms of `for` and `if` allow choosing a custom name for the loop variable using the arrow notation, e.g. `for $string.words -> $w { ... }` 14:48
Zoffix m: my $string = "fooffff barffff"; say (for $string.words -> $lu { $lu if $lu.chars > 5 });
camelia (fooffff barffff)
Zoffix sumdoc: you could write it this way ^ to get the variable.
But... $string.words.grep(*.chars > 5) is probably how most Rakudo programmers would write it :)
Zoffix & for real now 14:49
smls lizmat: Should I try my hand at reimplementing the {; } candidates by copy&pasting the optimized [; ] ones and going from there?
lizmat smls: be my guest :-)
smls ok :) 14:50
14:51 Actualeyes left 14:55 xinming joined 14:57 Cabanossi left 14:59 Cabanossi joined 15:02 ufobat joined 15:08 Actualeyes joined 15:10 AlexDaniel joined, araralonre__ joined 15:12 araraloren_ left 15:15 espadrine joined
sumdoc smls ($lu if $lu.chars>5 for $string.words -> {$lu}); or ($lu if $lu.chars>5 for $string.words -> $lu); 15:17
smls sumdoc: Neither. As I said, Perl 6 does not support custom loop variable names for the "list comprehension" versions of `for` and `if`. 15:19
On for the block form: `for $string.words -> $lu { ... }`
That's because the -> is actually considered part of the block `-> $lu { ... }`. 15:20
sumdoc smls Oh I see
15:21 HoboWithAShotgun joined
HoboWithAShotgun So I came up with a beatiful proverb. it is full of wisdom and experience, insightful and enriching. 15:21
smls sumdoc: The block version of `for` is always of the form `for EXPRESSION BLOCK`.
HoboWithAShotgun And then I got stoned and forgot it.
lizmat hopes there weren't any stones involved 15:22
HoboWithAShotgun I can neither deny, nor confirm that. 15:23
sumdoc I have this string my $string = "Pocket is Is empty this is Is an example"; I want to find number of unique words in this string, but I want to treat Is and is same. 15:27
So what I did was convert all to lower case and count the items but it is showing 1 15:28
Here is the code "say "$string".words.lc.unique.elems;"
lizmat m: "Pocket is Is empty this is Is an example".words>>.lc.unique.elems
camelia ( no output )
lizmat m: say "Pocket is Is empty this is Is an example".words>>.lc.unique.elems
camelia 6
sena_kun m: say "Pocket is Is empty this is Is an example".lc.words.unique.elems
camelia 6
lizmat that works too :-) 15:29
sumdoc What could be the reason this is not working say "$string.words.lc.unique.elems;" 15:30
smls Is there a way to run only specific spectest files, but still get the "skipping fudged tests etc." magic that `make spectest` provides?
lizmat make t/spec/foo.t
smls ah, thanks
sumdoc lizmat What could be the reason this is not working say "$string.words.lc.unique.elems;" 15:31
Juerd sumdoc: .words returns a Seq, which is multiple items
sumdoc: But .lc works on a single item
sumdoc Juerd Aye I see
Juerd sumdoc: It should help to change the order: $string.lc.words.unique.elems 15:32
sumdoc Yeah changinf the order works :)
Juerd Or, to apply the .lc on the individual words: $string.words».lc.unique.elems
Oh, I now see that lizmat already said that :) 15:33
And sena_kun
15:34 lucasb left
sumdoc What is this ">>" Juerd? 15:34
lizmat sumdoc: docs.perl6.org/language/operators#..._Operators 15:36
15:41 _cronus joined 15:44 Khisanth left
_cronus hello, is it ok to paste code related a question here or should I use pastebin? 15:44
moritz _cronus: please use a pastebin 15:45
unless it's only one line :-)
_cronus moritz: thanks
unclechu hi guys, is there something for compiling perl6 code to javascript? 15:47
moritz unclechu: yes, pmurias is working on rakudo-js
unclechu i just found this repo github.com/rurban/rakudo-js
moritz: you're talking about different one? 15:48
moritz unclechu: I'm talking about rakudo/rakudo branch js
unclechu i think you're about this one? github.com/rakudo/rakudo/tree/js 15:49
moritz yes
unclechu moritz: thanks
_cronus I am trying to learn perl 6 regexes. I wrote a small script - paste.ubuntu.com/25397783/ - but cannot understand it's behavior - specifically why it does not remove .1 from the first line. What am I missing? 15:51
15:53 wamba joined
moritz compiles a rakudo to be able to test this 15:55
AlexDaniel lol, you have to login to “download as text” 15:56
moritz AlexDaniel: or you can just copy & paste
AlexDaniel committable6: please copy & paste it
committable6 AlexDaniel, ¦please: «Cannot find this revision (did you mean “releases”?)»
AlexDaniel c: HEAD gist.githubusercontent.com/AlexDan...tfile1.txt 15:57
committable6 AlexDaniel, Successfully fetched the code from the provided URL.
AlexDaniel, ¦HEAD(e8137b4): «AAAA.1 val.1␤BBBB val.2␤AAAA val.3␤BBBB val.4␤»
moritz _cronus: I found look-arounds to be quite tricky; it works as you expect if you change it to s:g / ^^ <-[.]>+ <( '.' \S* / /
_cronus: the <( limits the match
15:57 Khisanth joined
geekosaur isn't that <-[.]> a bad perl 5 regex hack translated? 15:58
moritz no
a negative char class is still a valid tool in Perl 6 regexes
geekosaur is still waking up... not very successfully
16:01 lancew left
moritz it seems to not work in the first line; if I insert another line before the AAAA.1 line, it does not work in the new first line, and works fine in the line with AAAA.1 16:01
16:02 MilkmanDan left
lizmat SPW over 16:03
until later&
16:03 lizmat left, lancew joined
moritz m: given "abc\ndef\nghi\n" { say S/ <?after ^^ > /x/ } 16:05
camelia abcx
def
ghi
moritz m: given "abc\ndef\nghi\n" { say S:g/ <?after ^^ > /x/ }
camelia abcx
defx
ghix
x
moritz I don't understand why that is, but it's at the heart of _cronus' problem 16:06
m: given "abc\ndef\nghi\n" { say S:g/ <?before ^^ > /x/ } 16:07
camelia xabc
xdef
xghi
_cronus moritz: thanks. Any idea why <?after does not match first line? using <?after AA does match it.
moritz _cronus: ah, you probably want <?before> instead of <?after>
16:08 mr-foobar left
moritz <?after x> means "what comes after the curerent position must match x" 16:08
16:09 mr-foobar joined
moritz or am I totally confused now? 16:09
I likely am
16:09 aindilis left
moritz m: given "abc\ndef\nghi\n" { say S:g/ ^^ /x/ } 16:09
camelia xabc
xdef
xghi
smls <?after x> means "The current position must not come after an x" 16:10
moritz s/not//
smls right
moritz m: given "abc\ndef\nghi\n" { say S:g/ <?after ^^> /x/ }
camelia abcx
defx
ghix
x
moritz is that wrong then? 16:11
isn't pos 0 after a start-of-line as well?
m: given "abc\ndef\nghi\n" { say S/ <?after ^^> /X/ } 16:12
camelia abcX
def
ghi
16:12 mniip left
moritz m: given "abc\ndef\nghi\n" { say S/ <?after ^> /X/ } 16:12
camelia abc
def
ghi
X
AlexDaniel o_o
smls yeah, seem broken
moritz that *is* wrong
_cronus++
m: given "abc\ndef\nghi\n" { say S/ <?after $> /X/ } 16:13
camelia Xabc
def
ghi
moritz muhaha
smls apparently <?after > doesn't like anchors, yet... :P
moritz iirc <?after> is implemented by reversing the string, or something
who wants to write the bug report? :-)
smls heh, and probably forgot to reverse the meaning of the anchors accordingly... :P
moritz ok, I'll write the bug report as a failing test case, I guess 16:15
smls m: say "abc".match(/ <?after ^ > /).from; 16:16
camelia 3
smls moritz: ^^ A test-case without S/// 16:17
japhb OK, so Cro is jnthn's reveal from SPW? 16:23
16:25 andrzejku_ left
sena_kun japhb, yeah. 16:25
japhb Ah, cool. Can't wait to see that slide deck / talk video
sena_kun me too. 16:26
16:26 andrzejku_ joined
japhb .tell Cro website typos: First HTTP flip page: 'SITINT', last HTTP flip page: 'requset', first Tooling flip page: 'delcaring'. 16:31
yoleaux japhb: I'll pass your message to Cro.
japhb .tell nthn website typos: First HTTP flip page: 'SITINT', last HTTP flip page: 'requset', first Tooling flip page: 'delcaring'.
yoleaux japhb: I'll pass your message to nthn.
japhb .tell jnthn website typos: First HTTP flip page: 'SITINT', last HTTP flip page: 'requset', first Tooling flip page: 'delcaring'.
yoleaux japhb: I'll pass your message to jnthn.
japhb *sigh*
There's a certain justice in typoing twice while reporting typos. 16:32
16:32 lancew left
sena_kun japhb, thanks for your reports, noted. As soon as easy deployment will be done, I'll be able to fix such issues right away. 16:33
japhb Who all is on the team? 16:34
sena_kun ? Can you rephrase, please?
japhb You said you would be able to fix such issues, which implies the Cro team includes you as well (not just jnthn). Who else is involved? 16:35
16:35 MilkmanDan joined
TimToady m: my $string = "fooffff barffff"; say (-> $lu { $lu if $lu.chars > 5 } for $string.words); 16:36
camelia (fooffff barffff)
sena_kun japhb, ah. just me and jnthn right now.
TimToady sumdoc: ^^^
16:36 Ven`` left
TimToady statement modifier form allows a lambda on the left 16:37
japhb sena_kun: Do you work for Edument Central Europe as well?
sumdoc TimToady Looks good :)
sena_kun japhb, well, yes.
TimToady but basically we don't care to allow postdeclarations of variables, which is what Python is doing 16:38
postdeclaration tends to violate the one-pass parsing principle 16:39
tony-o jnthn++
cro ^^
japhb sena_kun: Ah, I didn't realize he'd managed to build a staff (last I was paying attention, jnthn was moving and acting as founding member of the new office ... but it was never clear how many people he was planning to hire).
(including possibly zero) 16:40
sumdoc is there a way to make words in a string titlecase like my $string="hello sum Helo doc docile" to Hello Sum Helo Doc Docile 16:42
like .uc .lc methods??
japhb sumdoc: .words>>.tclc.join(' ') ?
b2gills m: say "Pocket is Is empty this is Is an example".words.unique(:as(*.fc)).elems 16:43
camelia 6
sumdoc japhb Yeah I found .wordcase method. Hope that works too
16:45 MilkmanDan left
japhb sumdoc: (... goes to look at Rakudo source ...) Yup, looks like that would work well (and by default uses .tclc as a transformer) 16:45
sumdoc But whats the difference between .tclc and .wordcase ? with examples. I couldn't make documentation.
geekosaur "complicated"
sumdoc I couldn't understand the documentation docs.perl6.org/type/Str#routine_wordcase 16:46
japhb m: my $string = 'this is a test'; say $string.wordcase; say $string.words.map(*.tclc).join(' ');
camelia This Is A Test
This Is A Test
16:47 MilkmanDan joined
japhb sumdoc: The docs are saying you can change the per-word transformation from its default of tclc, and also that you can select only some of the words to be affected. 16:47
16:47 nattefrost left
sumdoc japhb Still confused. Give me an example plz. 16:49
16:50 epony left
japhb m: say 'This is a test'.wordcase(:filter(&uc), :where(/:i 't'/)) 16:53
camelia THIS is a TEST
japhb sumdoc: ^^
(Uppercases words containing a 't' or 'T') 16:54
16:55 nadim joined 17:02 ChoHag left
sumdoc This gives the desired output, but is it syntactically correct? 17:04
my $string = "Pokhara is Is beautiful City city of Nepal"; my @exam=$string.split("is") ; say @exam.join("the tourist city");
17:05 MilkmanDan left
moritz how could it produce any output if it weren't syntactially correct? 17:05
sumdoc moritz I mean is the array @exam OK? 17:08
17:10 lancew joined 17:11 ufobat left 17:12 Cabanossi left 17:13 MilkmanDan joined 17:14 Cabanossi joined 17:16 lancew left 17:19 lancew joined 17:28 epony joined 17:39 nowan left 17:42 nowan joined 17:44 smls left, smls joined
sumdoc I have written a small tutorial. github.com/sumandoc/Getting-Starte..._perl_6.md 17:48
Hope to get feedback !!
17:54 smls left, smls joined
smls sumdoc: When printing lists/sequences (e.g. `say $string.split(" ");`), the output is easier to understand if each element is printed on a new line (e.g. `.say for $string.split(" ");`). 17:57
sumdoc smls OK 17:58
18:01 mniip joined
AlexDaniel sumdoc: The original course is using "" because in python there's no difference. IMO, in perl 6, using '' when no interpolation is needed makes the code easier to read 18:02
sumdoc AlexDaniel Aye 18:03
AlexDaniel sumdoc: I have a bunch of nitpicks, so don't take them too seriously, but… 18:05
sumdoc: “Split sentence on space” – using .words is probably more conventional there. If you want to show .split, maybe use some other delimiter
sumdoc: “$string.split(" ").words” is even weirder 18:07
sumdoc: “But if we are to ignorecase then, […] $string.lc” – use .fc for case-insensitive comparisons 18:09
sumdoc: “$string.split("\n")” – again, maybe .lines 18:11
smls Note that `.split(' ')` and `.words` aren't identical. One extracts the fields between single SPACE characters, the other extracts fields made up of consecutive runs of alphanumeric characters. Try the input string " Hello, world!! " to see the difference.
sumdoc AlexDaniel Yeah .lines 18:12
AlexDaniel sumdoc: “If the sentence contains the string […] $string.match("").Bool” – maybe .contains
18:12 Ben_Goldberg joined
smls s/alphanumeric characters/word characters (which also includes the underscore)/ 18:13
18:13 BenGoldberg left, Ben_Goldberg is now known as BenGoldberg
sumdoc AlexDaniel corrected 18:15
AlexDaniel smls: well, .split(“\n”) and .lines are not identical too, but which one should be preferred by a beginner to do The Right Thing™? 18:16
moritz would recommend .lines
AlexDaniel .split(“\n”) vs .lines is maybe more obvious than .split(‘ ’) vs .words. But yeah, it depends on what you need 18:17
18:17 smls left, smls joined
samcv m: my $a = " Hello world !!! "; say $a.split(' ', :skip-empty) cmp $a.words 18:19
camelia Same
samcv m: my $a = " Hello world\c[NBSP] !!! "; say $a.split(' ', :skip-empty) cmp $a.words 18:20
camelia More
samcv that's the difference between words and split(:skip-empty) afaik
smls m: my $a = " Hello world!!! "; say $a.split(' ', :skip-empty) cmp $a.words 18:21
camelia Same
smls Ohh, yes, it looks like I was wrong about what `.words` does. 18:22
Does that mean `.words` is equivalent to `.split(/\s+/, :skip-empty)` ? 18:23
sumdoc: In that case, maybe `.comb` would be a nice addition to your tutorial, for when you really do want words to mean "consecutive runs of word characters"... 18:27
sumdoc Perl 6 looks so vast. samcv Ehat does :skip-empty do?
smls I doesn't include empty fields in the output. 18:28
m: dd "Hello world!!! ".split(' ');
camelia ("Hello", "", "", "world!!!", "", "").Seq
smls m: dd "Hello world!!! ".split(' ', :skip-empty);
camelia ("Hello", "world!!!").Seq
smls Not entirely sure why it exists, when one can also do: 18:29
m: dd "Hello world!!! ".split(' ').grep(?*);
camelia ("Hello", "world!!!").Seq
smls m: dd "Hello world!!! ".comb; 18:30
camelia ("H", "e", "l", "l", "o", " ", " ", " ", "w", "o", "r", "l", "d", "!", "!", "!", " ", " ").Seq
smls m: dd "Hello world!!! ".comb(/ \w+ /);
camelia ("Hello", "world")
smls sumdoc: ^^ `.comb` examples
sumdoc smls Aye 18:32
thanks
smls What if I want only alphanum characters only and not spaces like in this example "dd "Hello world!!! ".comb;" 18:33
smls m: dd "Hello world!!! ".comb(/ \w /);
camelia ("H", "e", "l", "l", "o", "w", "o", "r", "l", "d")
sumdoc If I don't want redundant spaces when converting to characters
smls like this ^^
sumdoc smls Looks good
smls sumdoc: `.comb` is basically the opposite of `.split` - instead of specifying where the field delimiters are, you specify (using a regex) what the fields themselves are. 18:34
18:37 smls left, smls joined
sumdoc smls samcv Updated with .comb 18:41
18:44 sumdoc left
samcv smash, or specify just a number 18:50
19:08 AlexDaniel left 19:09 mando joined 19:11 AlexDaniel joined 19:22 emeric joined 19:24 |oLa| joined 19:31 TEttinger joined 19:34 ChoHag joined 19:38 kybr left 19:40 kybr joined 19:41 darutoko left 19:43 mando left 19:46 kst joined 19:48 konsolebox left 19:54 raschipi joined, |oLa| left, konsolebox joined 19:55 pmurias joined
pmurias is Cro meant to be a web framework? 19:55
AlexDaniel that's what I'm wondering too 19:56
Skarsnik huggable, eco cro 20:06
huggable Skarsnik, nothing found
Skarsnik huggable, cro
huggable Skarsnik, nothing found
20:13 Rawriful joined
AlexDaniel buggable: cro 20:15
buggable: eco cro 20:16
buggable AlexDaniel, cro 'Libraries for building reactive services in Perl 6.': github.com/croservices/cro 11 other matching results: modules.perl6.org/s/cro
ChoHag The urge to play with perl6 again has been increasing recently. What are the capabilities for which I'd choose it over another? 20:30
eg. if I've got to process tonnes of not-quite-sane text, perl5.
If I *really* like pressing the space bar, python.
It I want complete control over everything, C.
If I want $foo, perl6.
What is $foo? 20:31
Or $.foo, if you will.
20:33 lancew left
raschipi People that learn Perl6 say they feel like they are fighting the language when they are forced to use something else. Perl6 will adapt to your ideas, instead of having to adapt your ideas to a harness. 20:33
Perl6 also allows clean code that shows what the code is actually supposed to do, making understanding it later much easier. 20:34
20:35 kybr left
raschipi Other important feature is that Perl6 can make use of C and C++ libs, and Perl5, Python and Ruby modules very easily. 20:36
ChoHag Hmm I'd be careful on that second point.
You can write fortran in any language. I'm sure perl 6 is no exception.
(I picked fortran as a stand-in for "some old POS". I don't know it at all) 20:37
raschipi Yes, it's possible to write FORTRAN in Perl6.
20:37 kybr joined
ChoHag So perl 6 is even gluier than perl 5? 20:37
Or gluier at a lower level, perhaps? 20:38
raschipi Perl6 is the glue of glues, much better than anything else.
ChoHag Well there's your catch phrase.
raschipi But it also scales very well to big applications.
ChoHag Now you're just sounding like a salesman :P 20:39
*Every* language claims it scales well. 20:40
raschipi It's the only dynamic language with an actually good type system.
ChoHag Joke languages need not apply, although I'm sure someone's written something substantial in brainfuck.
Someone always does.
Now that's an interesting point. 20:41
I'm sure someone must have contended it though. Is there discussion around that (types) available for reading?
ilbelkyr brainfuck can't even do threads :) 20:42
ChoHag I'm quite familiar with perl 6's object hieirarchy. I used it quite a bit a year or so ago.
ilbelkyr I prefer threaded intercal for that (using multiple come froms pointed at the same line)
ChoHag ilbelkyr: So I guess you're that someone?
ilbelkyr nah, I just sort-of know the C-INTERCAL maintainer via IRC 20:43
that sort of thing rubs off on you :)
ChoHag Intercal has a maintainer? 20:44
ilbelkyr catb.org/esr/intercal/ mentions him as "co-maintainer" 20:45
raschipi We don't even see much behind INTERCAL because COBOL and FORTRAN are their own parody. 20:47
It's a blast for people used to them, though.
AlexDaniel m: for ^5 { KEEP { say ‘hello’ } } 20:54
camelia ( no output )
AlexDaniel so what is KEEP? 20:55
20:55 cpage_ left 20:56 mr-fooba_ joined
raschipi (KEEP { say ‘hello’ }).^name 20:56
m: (KEEP { say ‘hello’ }).^name.say
camelia Nil
ryu0 m: Nil.say
camelia Nil
ryu0 a nil sayer. 20:57
20:57 andrzejku_ left
AlexDaniel “Runs at every successful block exit, as part of the LEAVE queue” 20:57
what is considered “successful”?
20:57 mr-foobar left
smls AlexDaniel: design.perl6.org/S04.html#Definition_of_Success 21:00
raschipi m: my $a = do { KEEP { say "awooo" }; False }; my $b = do { KEEP { say "awooo" }; Nil }
camelia awooo
raschipi It runs if the block has a defined value. 21:01
AlexDaniel oh… okay
smls If it exits normally (i.e. not with an exception) and returns a defined value.
21:07 wamba left 21:11 emeric left 21:28 kybr left 21:30 kybr joined 21:31 nadim left 21:46 Rawriful left 21:53 cpage_ joined 21:58 cpage_ left 22:04 zakharyas joined 22:05 _cronus left, smls left 22:10 nhywyll left 22:18 raschipi left 22:33 Ven`` joined
b2gills m: say Failure ~~ Nil 22:45
camelia True
22:48 zakharyas left 22:50 lizmat joined 22:57 espadrine left 22:59 skids joined 23:16 MilkmanDan left 23:17 sena_kun left 23:18 margeas left 23:21 MilkmanDan joined
teatime what is _True__ 23:26
skids I don't grep that identifier anywhere in rakudo/nqp/MoarVM. 23:29
Oh, it's your IRC client, not displaying some codepoints. 23:46
23:48 quotable6 joined, ChanServ sets mode: +v quotable6, Kyo91_ joined
teatime o. my bad :) 23:48
I wonder if tmux ate it. 23:49
this may be a stupid question, but how come Failure ~~ Nil is true while Nil ~~ Failure is false 23:50
Skarsnik hm 23:51
good question
I thouht it was the other way around
Nil being a Failure
geekosaur I think of Failure as Nil with extra behavior (i.e. verbosity) 23:52
skids m: Failure.^mro.say 23:53
camelia ((Failure) Nil (Cool) (Any) (Mu))
Skarsnik hm how you list roles of a class already
skids m: Nil.^mro.say
camelia (Nil (Cool) (Any) (Mu))
skids Im: IO::Path.^roles.say
m: IO::Path.^roles.say 23:54
camelia ()
skids huh...
m: Num.^roles.say;
camelia ((Real) (Numeric))
Skarsnik m: say int32.^roles 23:55
camelia No such method 'roles' for invocant of type 'Perl6::Metamodel::NativeHOW'. Did you mean any of these?
does
roll

in block <unit> at <tmp> line 1
23:55 pmurias left
Skarsnik m: say int.^roles 23:56
camelia No such method 'roles' for invocant of type 'Perl6::Metamodel::NativeHOW'. Did you mean any of these?
does
roll

in block <unit> at <tmp> line 1
skids yeah natives have lots of rough edges still. 23:57
23:57 Kyo91_ left 23:59 rindolf left