»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_log/perl6 | UTF-8 is our friend! 🦋
Set by Zoffix on 25 July 2018.
Geth doc: b14dfd6d21 | (Zoffix Znet)++ (committed using GitHub Web editor) | doc/Type/Proc/Async.pod6
Document .close-stdin's return value

Propspec: github.com/perl6/roast/commit/a61a9f0f9b
01:32
synopsebot Link: doc.perl6.org/type/Proc::Async
buggable New CPAN upload: AttrX-Mooish-v0.4.10.tar.gz by VRURG modules.perl6.org/dist/AttrX::Mooish:cpan:VRURG 03:04
rouking I have a basic application and it doesn't seem to even bind to the requested port (80 -- and yes, I am running with root access) 03:12
no errors, though :(
moritz rouking: if you want help, you'll need to show some code 06:31
lizmat weekly: ilya-sher.org/2018/09/10/what-i-di...om-perl-6/ 07:24
notable6 lizmat, Noted!
ZzZombo m: say new Int 07:43
camelia 5===SORRY!5=== Error while compiling <tmp>
Unsupported use of C++ constructor syntax; in Perl 6 please use method call syntax
at <tmp>:1
------> 3say new Int7⏏5<EOL>
ZzZombo So why is this a thing? 07:44
sena_kun m: sub new($type) { $type.new }; say new(Int); 07:47
camelia 0
sena_kun though parens are necessary, I guess. 07:48
lookatme_q m: sub new($type) { $type.new }; say new Int 08:49
camelia 5===SORRY!5=== Error while compiling <tmp>
Unsupported use of C++ constructor syntax; in Perl 6 please use method call syntax
at <tmp>:1
------> 3ub new($type) { $type.new }; say new Int7⏏5<EOL>
lizmat I guess we could lift that with a "no isms <C++>" 08:52
ZzZombo I wonder why is there no "Unsupported use of Object Pascal constructor: in P6 use Foo.new instead of Foo.Create". 08:55
Or for any other language.
lookatme_q There are some prevent you using some syntax such as -> 08:56
I don't know if it fixed 08:57
ZzZombo well, it's one thing to forbid unsupported (invalid) syntax, even tho I don't really agree with mentioning C++ or any other language for that matter. It's another going out of your way to forbid valid syntax just because some other language also uses it (?). 09:00
AlexDaniel it was meant to be helpful in case somebody writes that by mistake… A for effort I guess :) 09:03
lizmat I suggest we implement "no isms <C++>" 09:04
and then consider making "no isms" a default for 6.e
AlexDaniel .e? Doesn't have to be that far I think 09:05
well, as long as there's enough devpower to make that happen earlier 09:06
lizmat please make a ticket: if somebody doesn't beat me to it, I'll do that sometime tomorrow 09:09
HELLOPERL hi 09:19
AlexDaniel lookatme_q: ↑ 09:23
El_Che Perl 5 weekly as become useless even as RSS due the jobs ads 09:48
sigh
moritz El_Che: maybe give the editors that feedback? 09:52
Geth doc: 77e41134af | (JJ Merelo)++ | doc/Type/Mix.pod6
Avoid defined word in definition
10:48
doc: 40e5a15357 | (JJ Merelo)++ | doc/Type/Cool.pod6
Adds an example

And clarifies what happens if the second argument is not present. Addresses #2303. Not closing it until everyone is happy.
synopsebot Link: doc.perl6.org/type/Mix
synopsebot Link: doc.perl6.org/type/Cool
doc: 7268f126b6 | (JJ Merelo)++ | doc/Type/Iterator.pod6
Minor reformatting
10:50
synopsebot Link: doc.perl6.org/type/Iterator
lichtkind is there a way in POD do make headings into links? 11:04
Zoffix AlexDaniel: 6.e isn't "that far" really. We won't be waiting 3 years for it. Probably do it yearly, if it's worth it. 11:11
And probably do the work for it on an ongoing basis. Just so there isn't 3000 commits to review by the end. 11:12
And I imagine somewhere by [middle of] October there will be a changelog for 6.d released to users, and that would basically be a cutoff for all 6.d features. 11:13
Switching to "6.e" as our new go-to version for new features isn't a bad a idea :)
Geth doc: 1895af0cab | (JJ Merelo)++ | doc/Type/Str.pod6
Moving documentation for contains to Str

Which is actually what does the heavy lifting. Refs #2303 and grateful for @ToddAndMargo for drawing our attention to this issue.
11:14
synopsebot Link: doc.perl6.org/type/Str
Geth doc: 10ff0d6213 | (JJ Merelo)++ | doc/Type/Cool.pod6
Completes move fro Cool to Str

Leaving in Cool what it actually does, defer to Str. Closes #2303, if anyone has got any objection, please reopen and explain.
synopsebot Link: doc.perl6.org/type/Cool
Zoffix lichtkind: you'd just use a regular L<> tag, but it might be broken inside =head 11:27
lichtkind Zoffix, i will test 11:30
AlexDaniel Zoffix: ok true 12:04
El_Che moritz: I think it's their business model 12:14
moritz El_Che: still, feedback doesn't hurt 12:17
El_Che: there's a slippery slope where you add an ad, nobody complains, then you add a second ad
El_Che yes, maybe the jobs posting from the same headhunter were always there and the ad for the stickers website was just a trigger 12:18
Geth doc: 766353eb33 | (JJ Merelo)++ | doc/Language/5to6-nutshell.pod6
Reflow and eliminate index, refs #2304
13:22
doc: 1444d132e3 | (JJ Merelo)++ | 2 files
Indexes import where it's effectively explained

Closes #2304
Also some reflow, linking and reformatting.
synopsebot Link: doc.perl6.org/language/5to6-nutshell
lucasb is wondering if it would be too unethical to ask for a borrowed PDF copy of this new published book :) 13:49
El_Che lucasb: www.safaribooksonline.com/register/ 13:51
you can have a look in your 10 day free trial
lucasb thanks, I can try that. 13:52
lichtkind i cant install Pod::To::HTML 14:07
Extracting with plugin Zef::Service::Shell::git+{<anon|1>} aborted.
zoffix, it seems to work
El_Che "Learning Perl 6" and "Learning Perl, 6 the ed." is somewhat confusing on O'Reilly Safari 14:18
louisono hi, I'm trying to learn perl6 can anybody help me? 14:52
timotimo hello louisono
we have many different ways to learn perl6, depending on how you like to learn 14:53
louisono actually I'm reading a book
timotimo oh, cool, so you've already got something in front of you
louisono Perl6 Fundamentals
timotimo i think i have that in my bookshelf as well 14:53
do you have a particular question? 14:54
louisono yes. At some point in the book's code there a double semi-colon ';;' at the end of a line
I was wondering what it meant?
timotimo if i'm not forgetting something, double semicolons are only ever relevant inside of parenthesis when you're declaring a sub 14:55
so it's probably just a typo
louisono at first i thought it was a typo but then when changing the code the double semicolon happens again at an equivalent place in the code 14:56
timotimo if you remember the page number i can take a closer look
louisono thanks! it is at the end the chapter about testing page 35 14:57
timotimo yes, that looks just like a typo 14:58
it's not a mistake, it's just meaningless there
louisono ok, thanks for your help :)
timotimo moritz: ^ in case that's not already in your bugtracker or what you have 14:59
feel free to stay around or come back for when you have more questions :)
louisono thank you for welcoming newcomers such as me so nicely! 15:00
timotimo \o/ 15:01
moritz indeed, a (harmless) typo that none of my proof-readers has caught
happened twice in chapter 4 (git grep ftw)
El_Che "Welcome to the first edition of Learning Perl 6, a book title that sounds similar to others you may have read and I may have written. This one, however, is my first book about the language called “Perl 6.” I know the name is a bit confusing; I’m not in charge of that part. I’m just the book writer." <-- the first paragraph of Learning Perl 6 :) 15:16
APic 15:17
ccc_ Checked the Glossary and it's not there. What is an item; what does it mean to itemize? 15:53
p6: say [1,2,3].perl, [1,2,3].item.perl 15:54
camelia [1, 2, 3]$[1, 2, 3]
ccc_ What's the difference between these?
Does it perhaps have something to do with containers? 15:56
lucasb m: .say for [1,2,3] 16:02
camelia 1
2
3
lucasb m: .say for [1,2,3].item
camelia [1 2 3]
lucasb ^^ ccc_
one place where it makes difference
ccc_ m: .say for (1,2,3) 16:03
camelia 1
2
3
ccc_ m: .say for [1,2,3]
camelia 1
2
3
ccc_ m: .say for (1,2,3).item
camelia (1 2 3) 16:04
ccc_ m: .say for [1,2,3].item
camelia [1 2 3]
ccc_ okay, needs to be added to Glossary
m: .say (1,2,3) eqv [1,2,3] 16:05
camelia 5===SORRY!5=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> 3.say7⏏5 (1,2,3) eqv [1,2,3]
expecting any of:
infix
infix stopper
statement end
statement modifier
ccc_ m: .say {(1,2,3) eqv [1,2,3]} 16:06
camelia 5===SORRY!5=== Error while compiling <tmp>
Unexpected block in infix position (missing statement control word before the expression?)
at <tmp>:1
------> 3.say7⏏5 {(1,2,3) eqv [1,2,3]}
expecting any of:
infix
i…
ccc_ m: say (1,2,3) eqv [1,2,3] 16:07
camelia False
ccc_ thanks lucasb 16:10
Zoffix ccc_: the `(1,2,3) eqv [1,2,3]` is false, because one is an immutable List, while the other is a mutable Array. The item thing places things that are collections of many items (like lists) into a Scalar container, so that the entire collection gets treated like a single entity in things like looping or list flattening. There's an article on containers: perl6advent.wordpress.com/2017/12/02/ 16:19
Geth doc: ec83ae2cef | (Will "Coke" Coleda)++ | doc/Language/5to6-nutshell.pod6
whitespace
16:19
synopsebot Link: doc.perl6.org/language/5to6-nutshell
lucasb m: .say for \(1,2,3).item # except in some places :) 16:23
camelia 1
2
3
lucasb (places which could get some design attention before 6.d :)
lucasb I guess the indentation style used in that book has already been discussed here? 16:56
well, nevermind, just a small unfortunate detail 17:00
Zoffix lucasb: thanks for reminding about that misfeature. It was missing the 6.d label on the Issue and yeah, I think it will get an itemizing .item if there's no roast blockage or unforeseen LTAness 17:04
lucasb: yes, that indent style has been discussed and brought up to the author 2 years ago 17:05
lichtkind_ Zoffix: lichtkind@vav ~/code/perl/six/modules/Perl6-Math-Matrix $ zef install Pod::To::HTML
===> Searching for: Pod::To::HTML
Extracting with plugin Zef::Service::Shell::git+{<anon|1>} aborted.
Extracting with plugin Zef::Service::FetchPath+{<anon|1>} aborted.
No such method 'IO' for invocant of type 'Any'
Zoffix lichtkind_: what's `zef info zef` and what's `zef --debug install Pod::To::HTML` ? 17:06
lichtkind_ Zoffix, in a minute and btw at least converted it works very well as you see in github.com/pierre-vigier/Perl6-Math-Matrix 17:07
- Info for: zef 17:08
- Identity: zef:ver<0.5.3>:auth<github:ugexe>:api<0>
- Recommended By: Zef::Repository::Ecosystems<p6c>
- Installed: Yes, as zef:ver<0.5.2>:auth<github:ugexe>:api<0>
Description: A Perl 6 module manager
License: Artistic-2.0
Provides: 37 modules
Support:
# source:github.com/ugexe/zef.git
# bugtracker:github.com/ugexe/zef/issues
Depends: 2 items
Zoffix Doesn't seem to work well. All inner headers link to the parent section. Or is that the plan?
lichtkind_ yes 17:12
because its ease to click twice and you on top
lichtkind@vav ~/code/perl/six/modules/Perl6-Math-Matrix $ zef --debug install Pod::To::HTML
===> Searching for: Pod::To::HTML
===> Found: Pod::To::HTML:ver<0.3.22> [via Zef::Repository::Ecosystems<p6c>]
===> Dependencies: URI
===> Fetching: Pod::To::HTML
Fetching with plugin: Zef::Service::Shell::git+{<anon|1>}
===> Fetching [OK]: Pod::To::HTML:ver<0.3.22> to /home/lichtkind/.zef/tmp/1536599327.15460.7873/Pod-To-HTML.git
===> Extracting: Pod::To::HTML
Extracting with plugin: Zef::Service::Shell::git+{<anon|1>}
Extracting with plugin Zef::Service::Shell::git+{<anon|1>} aborted.
Extracting with plugin: Zef::Service::FetchPath+{<anon|1>}
Extracting with plugin Zef::Service::FetchPath+{<anon|1>} aborted.
No such method 'IO' for invocant of type 'Any'
Zoffix lichtkind_: what OS is that on? 17:14
And do you have git installed?
lichtkind_ zoffix: mint (debian derivate) on mate
git version 2.7.4 17:15
Zoffix lichtkind_: and your perl6 version?
lichtkind_ This is Rakudo version 2018.08-30-g5b34f69 built on MoarVM version 2018.08-21-gccc315f 17:16
implementing Perl 6.c.
Zoffix works fine for me on 2018.06-146-g1b3dd35 17:17
(haven't tried on anything recenter) 17:18
lichtkind_: what about: zef --debug install github.com/perl6/Pod-To-HTML
lichtkind_: if there are errors, pastebin them
lichtkind_: what about: zef --debug install github.com/perl6/Pod-To-HTML.git
I think it's the latter command
lichtkind_ lichtkind@vav ~/code/perl/six/modules/Perl6-Math-Matrix $ zef --debug install github.com/perl6/Pod-To-HTML.git 17:19
===> Fetching: github.com/perl6/Pod-To-HTML.git
Fetching with plugin: Zef::Service::Shell::git+{<anon|1>}
===> Fetching [OK]: github.com/perl6/Pod-To-HTML.git to /home/lichtkind/.zef/tmp/1536599937.15736.6838/Pod-To-HTML.git
===> Extracting: github.com/perl6/Pod-To-HTML.git
Extracting with plugin: Zef::Service::Shell::git+{<anon|1>}
Extracting with plugin Zef::Service::Shell::git+{<anon|1>} aborted.
Extracting with plugin: Zef::Service::FetchPath+{<anon|1>}
Extracting with plugin Zef::Service::FetchPath+{<anon|1>} aborted.
No such method 'IO' for invocant of type 'Any'
Zoffix Dude, don't flood the channel with output. Use a pastebin.
Zoffix I don't get the extra "extracting with" lines. It seems to work after the first one: gist.github.com/zoffixznet/f818312...9beec7ad81 17:20
lichtkind_ pastebin.com/nGfXjCjd 17:21
Zoffix No idea what it could be. There's a small chance the dev commit you're using got a bug on it, you could try using a release.
Zoffix g2g
lichtkind Tyil, hai i think i found the source of the bug its not you its Pod::To::HTML 18:13
rindolf lichtkind: hi 18:18
lucasb if ! $number %% 2 { put 'The number is odd' } 18:30
oreilly page is the place to submit errata for the book? 18:32
lichtkind rindolf, cheers 18:35
tyil lichtkind: heh, what's pulling that in when you try to install App::Assixt? 18:50
xinming m: multi t ($ where any(<a b>)) { "multi".say; }; multi t ($) { "def".say; }; t "b" 18:53
camelia multi
xinming is it possible to even shorten the multi t ($ where any(<a b>)) part? 18:54
xinming I tried something like this: 18:55
m: multi t ("a"|"b") { "multi".say; }; multi t ($) { "def".say; }; t "b"
camelia 5===SORRY!5=== Error while compiling <tmp>
Malformed parameter
at <tmp>:1
------> 3multi t ("a"|7⏏5"b") { "multi".say; }; multi t ($) { "de
expecting any of:
constraint
TimToady xinming: no, because junctional infixes | and & are also valid signature characters due to lack of TTIAR policy there 19:05
TimToady you can, however, use a subset type there 19:06
when you use a subset type in a signature it automatically splits out the 'where' bits for you
lichtkind tyil strangest thing it just installed 19:22
tyil lichtkind: eh, I guess it's resolved then? :p 19:35
lichtkind im still amazed even pod3html which gave me error msg still odesnt install 19:36
tyil still a similar error?
lichtkind yes
tyil once i have M::MM 0.3.0 out the door i will play with assixt
tyil :D 19:37
let me know if you need any help at any part
also, on your installation issues, I'd recommend making an issue on the zef repo
lichtkind tyil thank you but looks like i should get along, Matrix.gist is just currently broken badly so i have to fix that first, the blocker of 0.3.0 19:39
tyil alright, good luck with fixing it then :> 19:42
lichtkind tyil :) thanks 19:49
Zoffix .tell lucasb but there's no error in that code (other than overobundance of characters). The `a %% b` operator is equivalent to `a % b == 0`, so the code does indeed check for odd numbers: `m: my $number = 3; if ! $number %% 2 { put 'The number is odd' }` 20:57
yoleaux Zoffix: I'll pass your message to lucasb.
thundergnat Sigh... shitpost.plover.com/t/today-i-learned-7.html 21:29
timotimo does that blog actually have a basis in UUCP or is that just Looks/Aesthetic? 21:33
pyrimidine Someone needs to make a p6 version mjd's Higher Order Perl 21:34
tadzik that'd be sick
pyrimidine Might be 10% the volume of the original 21:35
lucasb . 22:00
yoleaux 20:57Z <Zoffix> lucasb: but there's no error in that code (other than overobundance of characters). The `a %% b` operator is equivalent to `a % b == 0`, so the code does indeed check for odd numbers: `m: my $number = 3; if ! $number %% 2 { put 'The number is odd' }`
lucasb m: my $that = 2; if ! $that %% 2 { say "Hmm... that's odd" }
camelia Hmm... that's odd
lucasb I'll report the errata once I get an accurate page number for that section 22:02
lucasb I think the correct is either 'if !($n %% 2)' or 'if not $n %% 2' 22:05
japhb lucasb: or just 'if $n % 2' of course. :-) 22:34
TimToady we thought about naming the other operator !% in fact 22:41
but that's kind of a double negative :) 22:42
AlexDaniel m: my $that = 3; if $that !% 2 { say ‘even’ } 22:50
camelia 5===SORRY!5=== Error while compiling <tmp>
Cannot negate % because multiplicative operators are not iffy enough
at <tmp>:1
------> 3my $that = 3; if $that !7⏏5% 2 { say ‘even’ }
expecting any of:
infix
inf…
lucasb ^^ that would be a very orthogonal feature to have! :) 22:55
since booleans are treated as numeric 0 and 1, why not have metaoperator ! and allow numerics to be treated as booleans 22:56
Zoffix lucasb: ah right. I guess my complaint about wordiness was more than just about typing. It had a precedence bug in it too :) 23:04
m: say "Hmm... that's odd" unless 2 %% 2
camelia ( no output )
Zoffix m: say "Hmm... that's odd" unless 3 %% 2
camelia Hmm... that's odd
Zoffix m: 3 %% 2 or say "Hmm... that's odd" 23:05
camelia Hmm... that's odd
Zoffix lucasb: also, there *is* a ! metaoperator
lucasb yes, but don't work on "iffy" operators 23:05
Zoffix m: sub infix:<♥> { $^a == $^b }; say 2 ♥ 5; say 2 !♥ 5 23:06
camelia 5===SORRY!5=== Error while compiling <tmp>
Cannot negate ♥ because additive operators are not iffy enough
at <tmp>:1
------> 3x:<♥> { $^a == $^b }; say 2 ♥ 5; say 2 !7⏏5♥ 5
expecting any of:
infix
infi…
Zoffix m: sub infix:<♥> is eqv(&[==]) { $^a == $^b }; say 2 ♥ 5; say 2 !♥ 5
camelia 5===SORRY!5=== Error while compiling <tmp>
Can't use unknown trait 'is eqv' in a sub declaration.
at <tmp>:1
expecting any of:
rw raw hidden-from-backtrace hidden-from-USAGE pure default
DEPRECATED inlinable nodal pre…
lizmat PSA: due to extended travel time, the Perl 6 Weekly will be published in about 12 hours
Zoffix m: sub infix:<♥> is equiv(&[==]) { $^a == $^b }; say 2 ♥ 5; say 2 !♥ 5 23:07
camelia False
True
Zoffix lucasb: the opposite. It works on iffy stuff, but % is not iffy enough, I guess :)
lucasb ah, right :) 23:08
TimToady we just decided that making the ! metaop coerce to boolean was one step too far 23:15
if we made ! coerce, we'd also have to make ? coerce, and that's just, well...two steps too far 23:16
Herby_ \o 23:47
timotimo o/ 23:48
perlBird hello! could somebody potentially help a fellow out with a simple thing ? 23:49
timotimo we can certainly try!
perlBird brilliant! I'm trying to send a post request with a json payload 23:50
using the WWW module
timotimo OK
perlBird and I keep running into an error that looks like so: 23:51
perlBird gist.github.com/cryptobird/4d93135...c0e7a1b95f 23:51
timotimo ah, looks like you're passing the headers as a literal hash, but the subs expect to get it slipped in 23:52
i.e. a bunch of named arguments, or alternatively |%the-header-hash
perlBird that seemed to do the trick!
I was way overthinking it lol 23:53
timotimo hum, but the synopsis looks different
ah i was looking at the wrong one
perlBird now I'm just getting a 400 error, but i expect I just don't understand how WWW wants the JSON to come 23:55
timotimo are you familiar with network sniffers like wireshark? or you can just use strace which is much simpler to get running, but a bit noisier to look at 23:56
perlBird never really used anything of the like 23:57
timotimo do you have control over the webserver you're connecting to? 23:58
perlBird nah, it's just like a ctf thing for an online job posting lol 23:59