»ö« 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.
Herby_ o/ 00:07
\o 00:10
Herby_ Watching Jonathan's great talk at Perlcon on Concurrency 00:13
bhaskar Hi 02:42
discord6 <Aearnus> bhaskar: o/ 02:46
Geth doc/master: 4 commits pushed by (Stefan Fischer)++, (Will Coleda)++ 03:07
bhaskar Hi 03:08
I am trying get all the instances of classe
class*
adu docs.perl6.org/language/classtut#Introspection 03:44
Geth doc: f6039af952 | threadless-screw++ | doc/Language/traps.pod6
Rewrite of interpolation trap section
06:48
synopsebot Link: doc.perl6.org/language/traps
doc: ccf2245704 | (Juan Julián Merelo Guervós)++ (committed using GitHub Web editor) | doc/Language/traps.pod6
Merge pull request #2940 from perl6/traps

Improvement of regex-interpolation trap section
discord6 <Aearnus> what's the status on doing cgi with perl6? 06:53
<Aearnus> and/or preferably smth like sinatra
tadzik cro is probably what you're looking for 07:06
but that's not CGI: don't do CGI :)
cro.services/ 07:07
discord6 <Aearnus> yeah, cro's exactly what i'm looking for 07:12
<Aearnus> thanks
lichtkind how the bundle namespac works in p6 09:29
or how it supposed to work since i dont find any bundle mdule on the list yet 09:30
kawaii Good morning friends :) 09:58
antoniogamiz good morning :) 09:59
scimon Morning. 10:07
Nighty quick question regarding perl6-examples/blob/master/categories/cookbook/01strings/01-00introduction.p6 -- I notice some/most of the examples don't have the expected output. Is this something that can be done automagically, or does someone need to go through and add them? 10:08
antoniogamiz54 tyil: do your docker iamges have docker installed? 11:46
s/docker/zef
tyil yes
I've moved them to GitLab proper now, and auto-builds seem to work
if you have ideas for improvement, MRs are welcome :> 11:47
in general, the -dev variants should be optimized for ease-of-use, the regulars should be optimized for size
antoniogamiz54 good, thanks :) 11:48
tyil gitlab.com/tyil/docker-perl6 I'll write a README with some usage information probably on Saturday, when I have time to kill on the train
gitlab.com/tyil/docker-perl6/blob/...n/build.sh this is the build script that gets used 11:49
antoniogamiz54 mmm are the images in the hub? 11:57
it looks like they are not 11:59
tyil they are on the gitlab repo 12:07
antoniogamiz54: gitlab.com/tyil/docker-perl6/container_registry
antoniogamiz54 ty 12:08
kawaii Any status update on Star 2019.06.1? 13:17
07*, sorry :) 13:18
Ven`` not quite pottery, huh. 13:21
cono m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; nextwith(Date.new(2019, 1, 1), :&formatter) } }; A.new(2019, Int, 1).WHAT.say 14:13
camelia yay
Nil
cono a bit lost with this next/call/same/with. Does any1 able to explain why am I getting Nil ?
antoniogamiz cono: I think you need to use named parameters 14:15
timotimo m: Date.new(Date.new(2019, 1, 1), formatter => -> *@a { }).WHAT.say
camelia (Date)
timotimo m: Date.new(Date.new(2019, 1, 1), formatter => -> *@a { }).perl.say
camelia Date.new(2019,1,1)
cono timotimo: expcting this: (Date: Dateish $d, :&formatter, *%_ --> Date:D) 14:17
cono m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; nextwith(2019,1,1, :&formatter) } }; A.new(2019, Int, 1).WHAT.say 14:18
camelia yay
Nil
14:18
cono this one also gives me Nil :(
timotimo ah 14:18
nextwith operates on the list of candidates that was already filtered by the arguments passed 14:19
so the one that takes a Dateish as first argument won't be in the list of availables?
m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; callwith(Date.new($year, $month, $day, :&formatter) } }; A.new(2019, Int, 1).WHAT.say 14:20
camelia 5===SORRY!5=== Error while compiling <tmp>
Unable to parse expression in argument list; couldn't find final ')' (corresponding starter was at line 1)
at <tmp>:1
------> 3e.new($year, $month, $day, :&formatter) 7⏏5} }; A.new(2019, Int, 1…
timotimo m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; callwith(Date.new($year, $month, $day, :&formatter)) } }; A.new(2019, Int, 1).WHAT.say
camelia yay
Cannot resolve caller new(Date:U: Int:D, Int:U, Int:D, :formatter(Callable)); none of these signatures match:
(Date: Int:D(Any):D $year, Int:D(Any):D $month, Int:D(Any):D $day, :&formatter, *%_ --> Date:D)
(Date: Int:D(Any):D :$year!…
timotimo m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; callwith(Date.new($year, 11, $day, :&formatter)) } }; A.new(2019, Int, 1).WHAT.say 14:21
camelia yay
Nil
timotimo hmm
i'm not sure what your reason is to want to call the constructor that takes the Date as first argument
m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; callwith($year, 11, $day, :&formatter) } }; A.new(2019, Int, 1).WHAT.say 14:22
camelia yay
Nil
timotimo m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; my $result = callwith($year, 11, $day, :&formatter); say $result.perl; $result } }; A.new(2019, Int, 1).WHAT.say
camelia yay
Any
(Any)
cono well, not important, this one also doesn't work for me:
m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; callwith(2019,1,1, :&formatter) } }; A.new(2019, Int, 1).WHAT.say
camelia yay
Nil
timotimo m: class A is Date { multi method new(Int:D $year, Int:U $month, Int:D $day, :&formatter) { "yay".say; self.new(2019,1,1, :&formatter) } }; A.new(2019, Int, 1).WHAT.say 14:23
camelia yay
(A)
cono hm, for some reason in my real module (not minimized version), it returns instance of Date, instead of sub-class type 14:25
self.Date::new does the same, strange 14:26
timotimo: github.com/cono/p6-international-fixed-calendar 14:29
cono $d.WHAT.say; gives me (Date) 14:30
before I put muti in from of method new, all my tests worked fine 14:32
cono in front* 14:32
ab6tract o/ #perl6 14:41
kawaii hey! 14:42
ab6tract I'm hoping someone familiar with NativeCall might be able to help me figure out what the Perl 6 type would be for (float* outputBuffers[2])
where the output buffers are CArray[long] allocated to a pre-determined size 14:43
hey there kawaii, how's it going?
jnthn long? flaot would be num32?
ab6tract num32, yeah 14:44
jnthn but I think you'd just do CArray[CArray[num32]]
ab6tract with is rw, right?
jnthn Hm, but doesn't it expcet an array, which is a reference type? 14:45
ab6tract the function wants an array of pointers to the first floats in the array, right 14:46
at least, as far as my limited C pointer foo goes 14:47
i tried something like: $buf = CArray[num32].allocate($length); my $bufptr = nativecast(Pointer, $buf); .. but that didn't work 14:48
timotimo cdecl.org/?q=float*+outputBuffers%5B2%5D
ab6tract nice one timotimo :D 14:49
timotimo very useful tool
ab6tract however, those "pointers to float" are usually the kind of thing you get to handwave via the is rw trait 14:50
timotimo haha, yeah
is this for audio?
ab6tract timotimo: indeed 14:51
wrapping a proprietary library with a stupid NDA, unfortunately
otherwise I'd show the code
timotimo but yeah, that sounds like a CArray[CArray[num32]] where the outermost one has size 2 14:53
uzl o/ 15:02
uzl I'm proofreading some Type docs page and they usually reference other types. In some instances there are links to those types and others not. What's the convention? Should they be left alone? Link to them (L<>)? Tag them with C<>? 15:05
Examples: github.com/perl6/doc/blob/master/d...e.pod6#L14 and github.com/perl6/doc/blob/master/d...e.pod6#L75 15:06
antoniogamiz I think they should be linked 15:08
cono timotimo: so, any suggestions? Totally lost here, do not understand why it returns instance of Date, instead of IFC::Date 15:09
m: class A is Date { multi method new(Int:D $year, Int $month, Int:D $day, :&formatter) { "yay".say; self.Date::new(2019,1,1, :&formatter) } }; my $x = A.new(2019, Int, 1); $x.WHAT.say
camelia yay
(A)
15:10
cono minimized code returns proper sub-class type
timotimo having a hard time concentrating on anything
cono ah, no problem, sorry for bothering you :) 15:11
timotimo normally i'd be more than happy to help
uzl antoniogamiz: In what instances should C<> be used? I've seen they're usually used when referring to constructs from a code snippet but I don't know if that's always the case. 15:14
antoniogamiz docs.perl6.org/language/pod#Code 15:15
it's used to mark something as code
ab6tract timotimo: hm... it doesn't seem to be working, and really bizarrely i'm actually getting a float value back as the return value of the funciton.. but that should be an int32 and is declared such (returns int32) in the native sub declaration :O 15:16
timotimo i'd need to see more code or a golfed example to know what's up
ab6tract timotimo: ack, i'll work on it :) 15:17
uzl antoniogamiz: My bad. I meant in relation to L<>, what portion should be alloted to each one of them? Probably the first mention of a type should be linked to (L<>) and afterwards, one can use C<> for the type one linked? 15:18
antoniogamiz mmm that seems a good convention 15:19
tadzik welp, time to unsub from #81
antoniogamiz I have not found a convention here github.com/perl6/doc/tree/master/writing-docs
you can add it if you want
uzl antoniogamiz: Oh great, I'll check it out! 15:20
tadzik: Too many notifications? It's over 120 comments now ;-)!
tadzik uzl: they're no longer on topic :)
uzl That's what I thought. It's too derailed at this point and some people proposing outlandish things with too much speculation. I'm glad it's been overall civil though and many people brought up great points. 15:25
harmil tadzik it wasn't on-topic about 20 comments in... 15:30
El_Che NeuPerl is my favorite (aka WHAT???) :) 15:32
a6502 hi * 15:38
why does zef put installed modules in a weird path like .perl6/sources/CDC3F6E966AA850234F8781D1430D06B7332217E instead of something readable? 15:40
timotimo it's rakudo doing that, not zef 15:41
it's for supporting things like "filenames for modules that the operating system or filesystem does not allow"
and for "multiple versions of the same module at the same time
a6502 ok.. supporting multiple version of the same module is cool 15:42
timotimo also, you're not supposed to muck around in the sources file, the files are meant to be immutable 15:43
but of course filesystems don't really offer that functionality
a6502 some filesystems do.. but maybe not for mortal users 15:44
uzl El_Che: That was me when I first read it. Removing Perl (and version-like names) from the name is essentially the issue the community is trying to tackle. 15:45
If that'd be the end result (i.e., XPerl), I'd rather keep Perl 6. 15:46
antoniogamiz there's pretty and easy way to install perl6 with a single command?
a6502 in the perl5 world i've gotten used to looking at the sources of installed modules in the @INC locations 15:47
timotimo rakudup.github.io/ stmuk made this
timotimo a6502: i think you can "zef look" or "zef locate" for that 15:47
antoniogamiz timotimo: oh :o 15:48
a6502 timotimo: ah.. thx.. yet some more new things to remember ;) 15:50
El_Che uzl: yeah, it was extremely weird for me. Fix it or leave alone, not make it worse :)
antoniogamiz: what are you looking for? OS packages? local compile? docker? 15:51
antoniogamiz docker
I have seen tyil containers
but I also need a node environment
timotimo oh, docker is good
El_Che I had containers (and have locally), that just took a base OS and installed my OS packages
they were lots smaller than the rakudo-star ones
(rakudo star on docker escapes my understanding completely) 15:52
timotimo the good thing about docker containers is that you can just make one based on different containers and include extra stuff
steal tyil's setup from gitlab with the CI stuff and have it create the images automatically
El_Che timotimo: an alpine comtainer + rakudo-pkg is very small 15:53
sadly alpine sucks when you need to compile lots of stuff
antoniogamiz I was using tyil container as base but it took 2 hours to execute apt-get update 15:54
El_Che I have been seriously looking at releasing rakudo tar.gz now that's relocatable. Nothing out yet because of lack of time
El_Che antoniogamiz: you're doing something wrong then 15:55
Geth doc/raku: ca77a16a05 | Coke++ | CONTRIBUTING.md
another p6
antoniogamiz mmmm
I supposed that hehe
uzl El_Che: A weird kind of window dressing. We get a rename but unfortunately the community's back to square one. Hopefully, with this sensible rename the community won't have the infamous and cyclical naming issue. It'll be a thing of the past.
antoniogamiz I do not know why though
El_Che: I'm making tests here => cloud.docker.com/repository/regist...45c0aa0f6e
El_Che antoniogamiz: take a debian-slim base image, add this repo (github.com/nxadm/rakudo-pkg#debian...and-mint), apt-get install rakudo-pkg, and you're set 15:56
tyil antoniogamiz: thats a slow apt-get update 15:57
damn
a6502 ok.. next question: where do i put MyFirstModule? and how do i name the file? 15:58
antoniogamiz tyil: it's a problem with my dockerfile? 15:58
tyil I don't know, I can't really reproduce that
antoniogamiz El_Che: I will try it 15:58
El_Che antoniogamiz: you can always use other mirrors on tyil image by COPY'ing or mounting a /etc/apt/sources.list file 15:59
antoniogamiz mmm 16:02
harmil a6502 please see: docs.perl6.org/language/module-pac...es_on_disk 16:05
a6502 harmil: that does not explain that there apparantly are different types of include directories.. (because that might be rakudo-specific?) 16:34
jman hi 18:00
jman say "hi there im cool" ~~ / hey|hi|yo \s* there/ : only returns "hi". I want "hi there". what am I doing wrong? 18:03
antoniogamiz () 18:05
sena_kun m: say 'hi there im cool' ~~ / (hey|hi|yo) \s* there /
camelia 「hi there」
0 => 「hi」
sena_kun the issue is that whole "yo \s* there" is taken as a third branch of the alternation 18:06
so you need to group it
you can have either a capturing group, with `()`...
jman thank you:)
sena_kun m: my $match = 'hi there im cool' ~~ / (hey|hi|yo) \s* there /; say $match[0];
camelia 「hi」
sena_kun or without capturing...
m: my $match = 'hi there im cool' ~~ / [hey|hi|yo] \s* there /; say $match[0]; 18:07
camelia Nil
jman <3 18:08
ab6tract jnthn, timotimo: CArray[CArray[num32]] was indeed the right type. Thanks for your help in confirming this! The issue I was facing had to do with an edge case around mono files and null pointers 18:15
mst who was permission to lock the renaming thread? it's getting *dumb* now I think, and all the points have already been made 19:11
AlexDaniel`: 19:15
jnthn:
ab6tract mst++ 19:39
ciao all!
masak mst: haha :) 20:06
mst: actually, I'm glad bazzaar said that out loud
mst masak: you can tell how impressed I was by how polite my reply was
masak (not because it's in any way a good argument, but because it's a *thought* that's now been aired) 20:07
mst: I admire your restraint, yes
masak you know it's going to be substantial and well-supported when the comment starts "At the risk of being knocked down again," 20:08
that's how the Gettysburg address started, too 20:09
mst restraint? no, no, that was "I have gone through shouty and out the other side into the cool calm space where people get broken"
masak oh, I recognized the register, believe me
mst *GRINS* 20:10
masak in all seriousness, though, p5 and p6 _are_ competing
mst it's always nice to have one's art appreciated
masak the trick is to have that competition be benign
zero-sum is only interesting if you believe that people are wallets 20:11
mst ... you know, I'm pretty sure I wrote a blog post about "how bout we compete by being awesome" once upon a time ...
masak that _does_ ring a bell!
masak does a double take at mst
IT'S YOU!
antoniogamiz if I declare a dynamic variable inside a function can it be accesed outside of it?
masak antoniogamiz: lexically? sure. 20:12
antoniogamiz good :D
masak m: sub foo { my $*dyn = "OH HAI"; bar() }; sub bar { say $*dyn }; foo()
camelia OH HAI
masak look ma, outside the sub
mst no hands; 20:13
masak o <--- no hands, waving
cpan-p6 New module released to CPAN! Gnome::Gtk3 (0.18.1) by 03MARTIMM 20:38
Geth problem-solving/path-to-raku: 084ca0a0b3 | (Elizabeth Mattijsen)++ | solutions/language/PATH-TO-RAKU.md
Add section about books
21:27
pmurias masak: re competing, they do for some resources, but a super strong Perl 5 resurgence would be an excellent thing for Perl 6 21:36
antoniogamiz what's the situation with name change? 21:38
with the*
El_Che We're going for SexyMcPerlyBoatFace 21:41
antoniogamiz oh, I like that one :D
ecocode El_Che:hi 21:49
discord6 <Aearnus> o/ all 21:50
lizmat
.oO( I thought it was PerlyMcSexyBoatFace? )
22:01
timotimo what, has nobody suggested SexyScript yet 22:02
lizmat *sigh* :-) 22:04
sleep&
chloekek I like that Perl 6 has so many different tokens and they make the code so colorful when syntax highlighted. 22:06
At work I program in Python and Haskell and it just looks like a sea of identifiers and parentheses. 22:07
timotimo i agree, people say "words make the code much more readable" but i think too many words and not many symbols doesn't make things better at all
chloekek Sigils and operators 😍 22:10
timotimo sigils really allow for pretty much the nicest string interpolation 22:11
and allowing postcircumfixes is a great decision 22:13
discord6 <Aearnus> enterprise Haskell is really something to behold 22:13
<Aearnus> makes me realize how awful of an idea significant whitespace is 22:14
timotimo is that because haskell has significant whitespace (optionally) or the other way around?
discord6 <Aearnus> Haskell has significant whitespace
timotimo but it's optional, isn't it? 22:15
i haven't haskelled in years
chloekek You can use curly braces and then you don't need indentation. 22:16
discord6 <Aearnus> let, case, where, do, and currying functions onto new lines require a new level of indentation
<Aearnus> but yeah, curly braces 22:17
<Aearnus> here's a screenshot from the enterprise codebase i'm working on right now actually cdn.discordapp.com/attachments/484...nknown.png
<Aearnus> (censored, of course)
<Aearnus> but look at that indentation 😦
timotimo it's nothing until you start using fibonacci indentation 22:18
discord6 <Aearnus> ahaha 22:19
timotimo the good thing is that at the lower levels it actually saves space
discord6 <Aearnus> unironically, some sort of nonlinear indentation scheme would be nice
<Aearnus> i'd be an avid user of 4->2->2->1->1->... or something along those lines 22:20
chloekek 8->1->7->2->6->3->5->4 22:21
discord6 <Aearnus> dartboard indentation: 20, 1, 18, 4, 13,... 22:22
timotimo did you see that nickgravgaard.com/elastic-tabstops/ - this is a cool thing btw
discord6 <Aearnus> i really love that 22:23
<Aearnus> linked on that page, but i want to see some perl 6 raku written in this font input.fontbureau.com/info/ 22:24
timotimo did you know about elastic tabstops already? 22:27
discord6 <Aearnus> no, that's the first i've seen of them
discord6 <Aearnus> it's just concerning that the code will look awful to someone who didn't have an elastic tabstop enabled editor 22:27
timotimo aye 22:28
discord6 <Aearnus> but: hard tabs solve that problem themselves in that they're adjustable. i was already firmly in the camp of hard tabs anyway.
Geth ¦ doc: coke self-assigned Styling of types github.com/perl6/doc/issues/2954 22:39
timotimo media.discordapp.net/attachments/5...nknown.png 23:04
MasterDuke: here's the hilbert curve i briefly mentioned in #moarvm
MasterDuke cool 23:09
btw, it just struck me and i have no idea. is the explicit `my $t = $d` faster than `$d is copy` in the signature? 23:10
timotimo no clue :) 23:13
jnthn MasterDuke: I doubt it; iirc they code-gen into about the same thing. If anything, the code in `is copy` will be a bit tighter. 23:24
Though my first guess would be "about the same"