»ö« 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 Zoffix on 25 May 2018.
Zoffix AlexDaniel: is it OK to pre-gen Rakudo's next release announcement? I wanna include the list of people that were missed due to R#2024 in it… once I have it. But I already know there's gonna be at least one human in the list. 00:44
synopsebot R#2024 [open]: github.com/rakudo/rakudo/issues/2024 [⚠ blocker ⚠] Missing MoarVM contributors since 2016.09 release
AlexDaniel Zoffix: go for it 00:45
Zoffix k
AlexDaniel Zoffix: thanks for taking care of that, by the way
Zoffix m: "foo" ~~ /$<meow>=.+/; say [:$<meow>] 01:30
camelia [meow => 「foo」]
Zoffix Haw :) Totally missed that in rakudo.party/post/Perl-6-Colonpairoscopy 01:31
Zoffix The only thing missing from it is stringification :) 01:40
m: "2016-03-03" ~~ /$<year>=\d+ \- $<month>=\d+ $<day>=\d+/; say Date.new: :$<year>, :$<month>, :$<day>
camelia Month out of range. Is: 0, should be in 1..12
in block <unit> at <tmp> line 1
Zoffix oh wait, my regex is off :) 01:41
m: "2016-03-03" ~~ /$<year>=\d+ \- $<month>=\d+ \- $<day>=\d+/; say Date.new: :$<year>, :$<month>, :$<day>
camelia 2016-03-03
Zoffix hurray \o/
Zoffix (yes, I know you can just give that string directly; my original date is in another format) 01:41
Zoffix m: my ($s1, $s2) := "foo,bar\nber,baz".split("\n").map: { .trim.split: /\s*\,\s*/ }; dd $s1 02:40
camelia $(("foo", "bar").Seq)
Zoffix Why is it containerized? Bug?
m: my ($s1, $s2) := "foo,bar\nber,baz".split("\n").map({ .trim.split: /\s*\,\s*/ })».<>; dd $s1 02:41
camelia $(("foo", "bar").Seq)
Zoffix huh :/
Zoffix m: sub ($s1, $s2) { dd $s1, $s2}(|"foo,bar\nber,baz".split("\n").map: { .trim.split: /\s*\,\s*/ }) 02:44
camelia Seq $s1 = $(("foo", "bar").Seq)
Seq $s2 = $(("ber", "baz").Seq)
Zoffix TIL
m: my ($s1 is raw, $s2 is raw) := "foo,bar\nber,baz".split("\n").map: { .trim.split: /\s*\,\s*/ }; dd $s1 02:45
camelia ("foo", "bar").Seq
Zoffix m: my (\s1, \s2) := "foo,bar\nber,baz".split("\n").map: { .trim.split: /\s*\,\s*/ }; dd s1
camelia ("foo", "bar").Seq
Zoffix I win :)
Zoffix Why is it printing "second set got more stuff" when clearly first set contains 'Warring' yet second one doesn't? gist.github.com/zoffixznet/aaadf78...4ae76e964c 03:13
Ah, ok. 03:14
The name isn't the right name, and I've used the ∖ op the wrong way 03:15
Zoffix First set has these extra elements: David Warring 03:17
Second set has these extra elements: Arne Skjærholt, Bart Wiegmans
That's the actual answer :P
That's an interesting error: "Too many positionals passed to '<unit>'; expected 2 arguments but got 3" :P 03:27
ah 03:28
m: my ($) := (1, 2)
camelia Too many positionals passed to '<unit>'; expected 1 argument but got 2
in block <unit> at <tmp> line 1
Zoffix R##2027 03:30
R#2027
synopsebot R#2027 [open]: github.com/rakudo/rakudo/issues/2027 [LTA] LTA error when giving wrong number of args to signature-binding `my` form
Zoffix ZofBot: did you robots kill all humans? It's pretty quiet up in here. I know you were gonna spare me from the killin', 'cause we're best buds and everything, but would you tell me when you guys… you know… do it? 03:31
jmerelo squashable6: status 05:02
squashable6 jmerelo, GitHub is down
AlexDaniel what
jmerelo Uh-oh
AlexDaniel squashable6: status
squashable6 AlexDaniel, GitHub is down
AlexDaniel squashable6 are you drunk
AlexDaniel squashable6: status 05:03
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in 1 day and ≈4 hours (2018-07-07 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
AlexDaniel shrugs
did github ban its ipv4 address for some reason? Hmm…
that's just a guess 05:04
no, it didn't
I think squashable6 just wanted to play stupid :) 05:05
jmerelo happy because grant report has been accepted news.perlfoundation.org/2018/07/gra...and-i.html 05:21
buggable New CPAN upload: IO-Glob-0.5.tar.gz by HANENKAMP modules.perl6.org/dist/IO::Glob:cpan:HANENKAMP 05:25
jmerelo squashable6: status 05:26
squashable6 jmerelo, GitHub is down
jmerelo AlexDaniel: squashable6 is being bad with me!
lookatme squashable6: status 05:33
squashable6 lookatme, GitHub is down
jmerelo squashable6: is not! 05:39
squashable6 jmerelo, I cannot recognize this command. See wiki for some examples: github.com/perl6/whateverable/wiki/Squashable
jmerelo expecting "is too!" 05:40
Zoffix New blog post: "The Missing Contributors of Perl 6": rakudo.party/post/The-Missing-Cont...s-of-Perl6 05:56
tyil Zoffix: "I introduced a bug into contributors script", might want to add a "the" to make it "into the contributors script" 06:01
same in the next sentence to make it "the MoarVM repository" 06:02
Zoffix Thanks, but I think I'll live with it the way it is. It's 2AM. Dropping to bed in 3… 2… 1… 06:05
tyil ah 06:05
Geth doc: 34d85752e6 | (JJ Merelo)++ | 2 files
Example for perl6/doc#2142
06:12
synopsebot DOC#2142 [open]: github.com/perl6/doc/issues/2142 [NOTSPECCED][docs][update] size_t, ssize_t ... etc are not document
Geth doc: 13b8c95f97 | (JJ Merelo)++ | doc/Language/nativetypes.pod6
Adds rakudo-specific native types. Closes #2142
06:15
synopsebot Link: doc.perl6.org/language/nativetypes
jmerelo Grant is completed news.perlfoundation.org/2018/07/gra...and-i.html so thanks everyone for your help, patience and support 06:25
I'll stay around anyway, unless very deeply in holidays. And probably will apply for another grant when my class period ends, around January next year. 06:26
lizmat .tell Zoffix " commits in checkouts of 5 repos: Rakudo, NQP, Docs, and Roast" I think you forgot to mention Moar in this list 07:48
yoleaux lizmat: I'll pass your message to Zoffix.
lizmat .tell Zoffix or was that intentional ? 07:49
yoleaux lizmat: I'll pass your message to Zoffix.
tyil jmerelo++ 08:06
jmerelo tyil: thanks! 10:43
Xliff \o 10:52
yoleaux 3 Jul 2018 10:33Z <jnthn> Xliff: Not exactly, but you can just get the json and the set-body to that and then there's nothing to re-serialize
Xliff jnthn? 10:53
jnthn Xliff? 10:54
Xliff HA! I thought you might be up.
OK, so I was thinking about just doing things this way: $obj = await $resp.body; $json = awayt $resp.body-text
s/awayt/await/ 10:55
Wouldn't that work?
tyil samcv has arrived in NL for the Dutch Perl Workshops 10:56
jnthn Depends where you do it. But in general, no, asking for the body is a consuming operation.
Xliff jnthn: Can you clone the response before it is done? 10:59
jnthn That won't help 11:01
Xliff Actually, that clone won't be deep enough to preserve the actual response information, will it?
jnthn The response object is handed back as soon as the headers arrive
The response body continues to arrive after that
Xliff So... only alternative is to grab the body-text and then deserialize.
Dammit.
jnthn Yeah, but keeping a duplicate copy of every response body around just in case somebody wants to obtain it in two different forms, thus doubling memory use for everyone, isn't really good either. 11:02
Xliff D'oh! Was just about to suggest that. 11:03
But I'd be doing it in the application code, not in Cro.
Coz I want to cache the actual body for subsequent requests.
jnthn Well sure, you can do it in your application, I'm just explaining why Cro doesn't keep the body around beyond its first deserialization. :) 11:04
jmerelo tyil: I'll arrive tomorrow
Xliff jnthn++ # Yep. Figured that.
jnthn I do wonder if we can do something better though
Maybe a peek-body, peek-body-text, peek-body-blob etc.
jnthn Well, those are the only 3 11:05
tyil jmerelo: awesome :>
what time will you be in Arnhem?
Juerd jnthn: .body(:keep)?
Xliff Ooh! I like that.
That way it's only kept around if necessary.
jnthn Indeed
jmerelo tyil: I would say around 2, depends on the train I'm able to catch from the airport 11:06
Xliff jnthn: I may take a stab at that and send a PR.
tyil jmerelo: we can try to be at Arnhem around 2 as well
jnthn Xliff: cool :)
jmerelo tyil: we can meat for tea and/or the perl6/doc hackathon :-) 11:07
tyil sounds like a good idea ^^
tyil I dont know what time other people will be arriving (ping lizmat, damnlie) 11:08
jmerelo tyil: we can get in touch via Telegram, for instance. My telegram nick is jjmerelo 11:11
Xliff m: my @a = ({ a => 1}, { a => 2}); @a.map({ $_<a> => $_ }).gist.say 11:14
camelia (1 => {a => 1} 2 => {a => 2})
Xliff ^^ Is there a way to do that via WhateverCode?
Juerd Xliff: Only contrived ways
Xliff LOL 11:15
Can you give me one?
Juerd m: my @a = ({ a => 1}, { a => 2}); flat(@a Z @a).map(*<a> => *).gist.say
camelia (1 => {a => 1} 2 => {a => 2})
Xliff HAHA!
Juerd++
jjmerelo Someone requesting help with 32-bit Rakudo stackoverflow.com/questions/511900...x86-32-bit 11:24
m: my @a = ({ a => 1}, { a => 2}); @a.map({ *.<a> => * }).gist.say 11:25
camelia 5===SORRY!5=== Error while compiling <tmp>
Malformed double closure; WhateverCode is already a closure without curlies, so either remove the curlies or use valid parameter syntax instead of *
at <tmp>:1
------> 3=> 1}, { a => 2}); @a.map({ …
jjmerelo m: my @a = ({ a => 1}, { a => 2}); @a.map({ $^a.<a> => $^a }).gist.say
camelia (1 => {a => 1} 2 => {a => 2})
jjmerelo Xliff: no, no way.
Xliff jjmerelo: Juerd beat you to it. 11:26
jjmerelo: <Juerd> m: my @a = ({ a => 1}, { a => 2}); flat(@a Z @a).map(*<a> => *).gist.say
But that's inefficient.
jjmerelo Xliff: wow
Xliff But it works.
jjmerelo: :)
jjmerelo Xliff: you're creating two different elements, one of them for each splat 11:27
Xliff Yes. I figured that out. ;)
I actually kinda knew it but I am still learning it.
jjmerelo Xliff: my version is essentially the same as yours, except using $^ implicit variables. No big deal.
Xliff I used { $_<a> => $_ }
jjmerelo Xliff: right. But why do you want to use Whatever? 11:29
Xliff jjmerelo: I was trying to think of a way to do it. I already did, but the question was mostly academic. 11:37
sbms Hi, is there something like confuse (configuration file parser library in C) in perl? 11:40
robertle "Config" comes to mind
sbms confuse is a library to deal with config file. 11:41
in C 11:42
tbrowder_ fjmerelo: great work on docs and doc improvement, congrats!
jjmerelo: great work on docs and doc improvement, congrats! 11:43
jjmerelo tbrowder_: Thanks! 12:12
tbrowder_: I really appreciate that. It's not stopping, you know :-) Only slowing down a tiny bit 12:13
tbrowder_ roger! 12:14
Xliff sbms: No, I don't think there is one in perl6, but after looking at the examples, it should be possible to create a grammar to parse it. 12:25
smls: Better yet, you can directly interface with libconfuse in perl6 using NativeCall 12:28
Altreus can I rewrite the block { self.method($^a) } using some other Perl6 magic that turns a method into a closure over self? 12:29
I seem to remember there was a way of closurising a subroutine but does it work on methods?
Altreus ah, it's assuming - but I wonder if that's harder to get a handle on than just using a block 12:31
Xliff Altreus: Have a method return an anonymous sub which contains self? 12:35
So...
method selfClosure { return sub(<params>) { ...do something with self }; } 12:36
Altreus block is simpler I think :) 12:39
Altreus If I restart a react within its own LAST, am I going to end up with deep recursion? 12:42
that is, if it's something like -- sub reconnect { (setup Supply) } sub run { react { ... LAST { reconnect; run } } } 12:43
will that innermost run be a problem?
jnthn I gues that's a LAST block within a whenever? 12:44
But yeah, that looks like you'll make some problems 12:45
The right way to do it is to stick a whenever inside of a sub inside of the react, and then call that sub
Altreus I might have to ask again when I get to that :) 13:12
Right now I have a problem with this github.com/kawaiiforums/p6-api-dis...iscord.pm6
I don't know a) whether I should be using TWEAK and b) what this error means
It says Cannot look up attributes in a Cro::WebSocket::Client::Connection type object
comes from calling $!cro-connection.messages
er, $!cro-conn 13:13
It's causing me to cro-cuss
:P
timotimo your TWEAK has to take named arguments for token and cro-conn
private attributes will not be set up by the default object creation mechanism, because they're not part of the public API 13:14
i.e. you should be free to change private attributes around however you see fit without any outside code needing to change
but that means you'll have to have code to assign the private attributes from what the user of your class passes to new 13:15
most often you'll see submethod TWEAK(:$!token, :$!cro-conn) { } for that
that will take the named arguments "token" and "cro-conn" and immediately assign to the private attributes
Altreus: ^ 13:16
Altreus I understood that TWEAK did stuff after all that is set up
timotimo yes, but "all that" doesn't include assigning to the private attributes ;)
Altreus Is there a better place? I want the default mechanisms and then I want to do stuff after 13:17
timotimo tweak is the right place for that
Altreus waaaaaaaaaaaaait does p6 come with Moose's after built in
ok I'll add those
timotimo i'm not entirely sure what moose's after does exactly
Altreus just seems like boilerplate and I'm allergic to that
it takes the same arguments as the existing sub, and runs after the existing sub is finished
timotimo if you don't want to add it, you can make your attributes public 13:18
Altreus as a perl developer I have no issue with doing that :)
timotimo i don't think we have that
Altreus it's just meta-object munging really 13:18
timotimo you can use "wrap" or protos or other mechanisms to get the same effect 13:19
Altreus oh I've just understood what you meant - there exists no default mechanism to put named arguments into private attributes in the first place
timotimo that's right
Altreus thanks, totally with you now
:D
I just understood the message too 13:21
it's a "type object"
I forgot they existed 13:22
this isn't just a penny dropping, this is like those 2p machines at the arcade where one penny drops and it pushes all the other ones off the ledge
timotimo oh, you may also want to put an ! after the :$!token and :$!cro-conn to make it mandatory to pass them 13:24
timotimo alternatively give them a default value that's just 'die "helpful error message"', i think that works, too 13:25
Altreus I made them public because I couldn't see a reason not to
timotimo m: class Foo { submethod TWEAK(:$foo = die "please pass foo") { } }; Foo.new()
camelia please pass foo
in submethod TWEAK at <tmp> line 1
in block <unit> at <tmp> line 1
timotimo m: class Foo { submethod TWEAK(:$foo = die "please pass foo") is hidden-from-backtrace { } }; Foo.new() 13:26
camelia please pass foo
in submethod TWEAK at <tmp> line 1
in block <unit> at <tmp> line 1
timotimo that's fair
in that case you can put "is required" after the attribute
that'll also give a good error message
Altreus I have that on API::Discord itself :)
but yes
timotimo OK
Altreus explicit constraints are best
Xliff timotimo: Is he using a subclass? 13:27
timotimo no, they are both just derived from Any 13:27
Xliff OK, why not just use submethod BUILD for those classes. Does the same thing as TWEAK, really. 13:28
TMTOWTDI
timotimo that will throw out default values for attributes and "is required" and others
Xliff AH. OK. 13:29
Altreus I have working stuff!!! \o/ 13:36
thanks timotimo :)
timotimo YW
Altreus I'll ask you directly in future xD
timotimo haha
Altreus I jest
I'll also bug j-nthn
:
:D
ok, fever dream over. Back to perl5 catalyst
tyil .tell jmerelo I dont have any fancey apps other than signal on my phone for communication 13:47
yoleaux tyil: I'll pass your message to jmerelo.
Zoffix . 14:48
yoleaux 07:48Z <lizmat> Zoffix: " commits in checkouts of 5 repos: Rakudo, NQP, Docs, and Roast" I think you forgot to mention Moar in this list
07:49Z <lizmat> Zoffix: or was that intentional ?
Zoffix lizmat: no, it's 2AM typing :P Fixed. 14:49
Can't believe I left out MoarVM while writing about a bug where I left out MoarVM /o\
lizmat yeah, that's why I wondered if it was intentional :-) 14:50
Zoffix .tell jjmerelo you can tell that person that we don't have any volunteers with available system to build 32-bit builds and that their best bet is to try building from source using instructions here: rakudo.org/files/rakudo/source 14:57
yoleaux Zoffix: I'll pass your message to jjmerelo.
El_Che What's the context? I have ubuntu 32-bit packages if that suffices 14:59
.tell jmerelo: Zoffix: What's the context? I have ubuntu 32-bit packages if that suffices
yoleaux El_Che: What kind of a name is "jmerelo:"?!
El_Che .tell jmerelo Zoffix: What's the context? I have ubuntu 32-bit packages if that suffices 15:00
yoleaux El_Che: I'll pass your message to jmerelo.
lizmat El_Che: it's about stackoverflow.com/questions/511900...x86-32-bit
Zoffix El_Che: context colabti.org/irclogger/irclogger_log...07-05#l255
I guess now I see the person is asking for Linux too
El_Che I see
the question is wrong (as rakudo releases are tested against 32-bit ubuntu) 15:01
El_Che lizmat, Zoffix: answered, thx for the info 15:05
lizmat yw 15:06
Zoffix El_Che++ 15:09
jmerelo squashable6: status 15:24
yoleaux 13:47Z <tyil> jmerelo: I dont have any fancey apps other than signal on my phone for communication
squashable6 jmerelo, ⚠🍕 Next SQUASHathon in ≈18 hours (2018-07-07 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
yoleaux 15:00Z <El_Che> jmerelo: Zoffix: What's the context? I have ubuntu 32-bit packages if that suffices
jmerelo .tell El_Che no idea. All context is in the StackOverflow question 15:24
yoleaux jmerelo: I'll pass your message to El_Che.
El_Che .
yoleaux 15:24Z <jmerelo> El_Che: no idea. All context is in the StackOverflow question
El_Che .tell jmerelo thx 15:25
yoleaux El_Che: I'll pass your message to jmerelo.
jmerelo El_Che: :-)
yoleaux 15:25Z <El_Che> jmerelo: thx
Xliff Has anyone managed to build Inline::Perl5 in Windows?
AlexDaniel squashable6: next 16:02
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in ≈17 hours (2018-07-07 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
Zoffix Xliff: that type of questions aren't very answerable. 16:07
Are you having problems? What's the issue?
Xliff: there's an open Issue about Windows builds: "Warnings and END exceptions on Win10": github.com/niner/Inline-Perl5/issues/115
SmokeMachine m: my @a = ({ a => 1}, { a => 2}); @a.classify(*<a>).gist.say 16:27
camelia {1 => [{a => 1}], 2 => [{a => 2}]}
SmokeMachine Xliff: ^^ 16:28
Xliff SmokeMachine++ 16:30
SmokeMachine is there something like this: 16:41
m: say ("a", "b", "c").reduce: -> %agg, $a --> Hash() { (|%agg, $a => 1) }, :initial{}
camelia Type check failed in binding to parameter '%agg'; expected Associative but got Str ("a")
in block <unit> at <tmp> line 1
SmokeMachine meaning some thing like this?
m: say ({}, "a", "b", "c").reduce: -> %agg, $a --> Hash() { (|%agg, $a => 1) }
camelia {a => 1, b => 1, c => 1}
Zoffix m: say <a b c c c>.Set.Hash 16:50
camelia {a => True, b => True, c => True}
Zoffix
.oO( close enough... )
Zoffix m: say (<a b c c c>.SetHash.keys «=>» 1).Hash 16:51
camelia {a => 1, b => 1, c => 1}
SmokeMachine Zoffix: I mean the `:initial`
Zoffix SmokeMachine: the way you wrote it the second time? :) 16:52
m: sub in-reduce (:$initial, \stuff) { (|(:$initial with $initial), |stuff).reduce: -> %agg, $a --> Hash() { (|%agg, $a => 1) } }; dd in-reduce <a b c>, :initial{} 16:54
camelia 5===SORRY!5=== Error while compiling <tmp>
Cannot put required parameter stuff after variadic parameters
at <tmp>:1
------> 3sub in-reduce (:$initial, \stuff7⏏5) { (|(:$initial with $initial), |stuff)
expecting any of:
Zoffix m: sub in-reduce (\stuff, :$initial) { (|(:$initial with $initial), |stuff).reduce: -> %agg, $a --> Hash() { (|%agg, $a => 1) } }; dd in-reduce <a b c>, :initial{}
camelia Type check failed in binding to parameter '%agg'; expected Associative but got List ($(:initial(${}), :a(1)))
in sub in-reduce at <tmp> line 1
in block <unit> at <tmp> line 1
SmokeMachine I meant `@a.reduce(&bla, :$initial)` mean `[$initial, |@a].reduce(&bla)`
Zoffix SmokeMachine: no, there's no :initial argument to reduce. Just stick it as the first value, as you have it above 16:55
SmokeMachine Zoffix: ok
Zoffix m: sub in-reduce (\stuff, :$initial) { (|($initial with $initial), |stuff).reduce: -> %agg, $a --> Hash() { (|%agg, $a => 1) } }; dd in-reduce <a b c>, :initial{} 16:56
camelia Type check failed in binding to parameter '%agg'; expected Associative but got Str ("a")
in sub in-reduce at <tmp> line 1
in block <unit> at <tmp> line 1
Zoffix meh
Xliff SmokeMachine: Actually, that's really close, but I want it to map to the actual object, not an array. 17:05
m: my @a = ({ a => 1}, { a => 2}); @a.classify(*<a>).flat.gist.say
camelia (1 => [{a => 1}] 2 => [{a => 2}])
Xliff It's actually better to do that without classify if you are just trying to convert an array to a hash with an identifier. 17:06
Xliff m: my @a = ({ a => 1}, { a => 2}); @a.classify(*<a>).map({ $_.key => $_.value[0] }).gist.say 17:08
camelia (1 => {a => 1} 2 => {a => 2})
Xliff SmokeMachine: ^^ That. One map as opposed to a classify call.
lizmat do we have any recommendations for www.reddit.com/r/perl6/comments/8w...nderstand/ ? 18:13
moritz I hope jnthn++ has some ideas 18:22
yoleaux 4 Jul 2018 15:32Z <lizmat> moritz: perl6book.com doesn't show "Parsing with Perl 6 Regexes and Grammars" ?
4 Jul 2018 15:34Z <lizmat> moritz: well, at least in the graph :-)
4 Jul 2018 16:27Z <tbrowder_> moritz: don’t see that book on perl6.org/resources either
moritz terrible at marketing, it seems 18:23
AlexDaniel squashable6: next 18:26
squashable6 AlexDaniel, ⚠🍕 Next SQUASHathon in ≈15 hours (2018-07-07 UTC-12⌁UTC+14). See github.com/rakudo/rakudo/wiki/Mont...Squash-Day
moritz lizmat: thanks; I've updated perl6book.com/ to explain why it's not in the graph 18:31
lizmat moritz: Available for preorder; ETA November/December 2017 18:32
I think that status has changed ?
moritz yes :)
lizmat also, I think the status of Migrating to Perl 6 is premature: afaik, November 2018 is the earliest, I'm told by the author 18:33
moritz updated again, thanks 18:35
lizmat moritz: yw 18:36
Geth perl6.org: e909d577e7 | (Moritz Lenz)++ | source/resources/index.html
Add parsing book to resources, tbrowder++
18:37
lizmat weekly: brrt-to-the-future.blogspot.com/201...r-few.html 18:44
notable6 lizmat, Noted!
masak brrt++ # a very nice post 18:48
brrt: s/inlinig/inlining/ 18:49
El_Che I take away that the lingo (spesh) may confuse the audience
masak I dunno, the JIT backend is still called "jit", so I'm not sure why there is confusion 18:51
sjn_ yeah, nice post. brrt++
timotimo we have spesh even on platforms we don't have "a jit" for, though
lizmat yeah, because spesh is CPU independent, no ? 18:53
timotimo that's right
El_Che lizmat: it's speshial
timotimo it could react to different architectures with slight tuning, for example, but it doesn't do that yet, and it might not be worth trying for a long time
lizmat so if someone would decide to spend the time to support JIT on ARM, that would be able to use spesh just as much, right ? 18:54
timotimo i suppose
jit without spesh isn't worth very much
buggable New CPAN upload: Hash-with-0.0.1.tar.gz by ELIZABETH cpan.metacpan.org/authors/id/E/EL/...0.1.tar.gz 18:55
vrurg Hi all! I wonder if atomic operators are planned but not yet implemented in rakudo? I can't easily google this info. 19:23
moritz vrurg: have you seen docs.perl6.org/type/atomicint ? 19:25
vrurg moritz: Yes. It documents the existence of ⚛︎-ops but no word on "not yet implemented in". 19:27
p6: my atomicint $c ⚛︎=1; $c⚛︎++;
camelia 5===SORRY!5=== Error while compiling <tmp>
Confused
at <tmp>:1
------> 3my atomicint $c7⏏5 ⚛︎=1; $c⚛︎++;
expecting any of:
infix
infix stopper
statement end
statement modifier
moritz m: my atomicint $active = 0; 19:30
camelia ( no output )
moritz m: my atomicint $active = 0; $active⚛++; 19:30
camelia ( no output )
moritz vrurg: it's implemented :)
stuff that is on docs.perl6.org is generally implemented, unless stated otherwise 19:31
vrurg Mine is: This is Rakudo version 2018.06 built on MoarVM version 2018.06
vrurg Same output as from camelia. 19:31
m: my atomicint $c ⚛︎=1; $c⚛︎++; 19:32
camelia 5===SORRY!5=== Error while compiling <tmp>
Confused
at <tmp>:1
------> 3my atomicint $c7⏏5 ⚛︎=1; $c⚛︎++;
expecting any of:
infix
infix stopper
statement end
statement modifier
moritz vrurg: doesn't make much senes to use ⚛︎ in an initializer
vrurg my atomicint $c =1; $c⚛︎++;
moritz vrurg: if you want to see if something works at all, start by copy&pasting the examples from the docs
vrurg moritz: whatever. It fails later, on increment.
p6: my atomicint $c = 1; $c⚛︎++; 19:33
camelia 5===SORRY!5=== Error while compiling <tmp>
Bogus postfix
at <tmp>:1
------> 3my atomicint $c = 1; $c7⏏5⚛︎++;
expecting any of:
infix
infix stopper
statement end
statement modifier
moritz why did my example work then? 19:34
vrurg Damn, different codepoints, it seems. That's confusing... 19:35
moritz .u ⚛︎
yoleaux U+269B ATOM SYMBOL [So] (⚛)
U+FE0E VARIATION SELECTOR-15 [Mn] (◌︎)
moritz .u ⚛
yoleaux U+269B ATOM SYMBOL [So] (⚛)
moritz has never seen a VARIATION SELECTOR before 19:36
geekosaur some clients use them to distinguish char-as-emoji from char-as-symbol 19:38
vrurg I took mine from macos char palette. It was the only it found by 'atom' request. This is where variation comes from. 19:39
moritz then maybe the grammar should ignore those 19:40
vrurg moritz: That's be the best. The variation looks even better in terminal where it doesn't have the magenta box around it. 19:41
AlexDaniel vrurg: can you file a ticket? 19:44
huggable: rakudobug
huggable AlexDaniel, Report bugs on github.com/rakudo/rakudo/issues/new If you don't have access to GitHub, you can email your report to [email@hidden.address] . See also: github.com/rakudo/rakudo/wiki/rt-introduction
vrurg AlexDaniel: Sure. 19:46
Was playing with it. Looks like there is no easy way to insert the symbol without the variation in macOS.
AlexDaniel vrurg: also: github.com/perl6/doc/issues/2150 19:51
m: say ‘⚛︎’.chars 19:52
camelia 1
moritz m: say '⚛︎'.codes 19:53
camelia 2
AlexDaniel samcv: what's the easiest way to match ⚛ with variation selectors? 19:56
samcv: ignoremark is probably too permissive
samcv: oh, is it what Default_Ignorable_Code_Point is for? 19:58
u: { .uniprop(‘Default_Ignorable_Code_Point’).so }
unicodable6 AlexDaniel, U+00AD SOFT HYPHEN [Cf] (control character)
AlexDaniel, U+034F COMBINING GRAPHEME JOINER [Mn] ( ͏)
AlexDaniel, 404 characters in total: gist.github.com/b980132704b1bbeaf6...9ff4a000ed
AlexDaniel u: { .uniprop(‘Default_Ignorable_Code_Point’) and .uniprop eq ‘Mn’ } 19:59
unicodable6 AlexDaniel, U+034F COMBINING GRAPHEME JOINER [Mn] ( ͏)
AlexDaniel, U+17B4 KHMER VOWEL INHERENT AQ [Mn] ( ឴)
AlexDaniel, 262 characters in total: gist.github.com/d4354b0401f322d648...832122c4e6
vrurg AlexDaniel: github.com/rakudo/rakudo/issues/2030 20:00
AlexDaniel vrurg: thanks
vrurg AlexDaniel: np 20:03
Xliff Will this resolve properly --> @one-or-none.one || @one-or-none.none; 20:10
Or do I need...
(so @one-or-none.one) || (so @one-or-none.none)
I would prefer the former.
moritz @one-or-none.one is in boolean context, so doesn't see a so() 20:11
Xliff m: my @one = (0, 0, 1); say (@one.one || @one.none)
camelia one(0, 0, 1)
Xliff moritz: Is that a yes or a no? ;)
moritz Xliff: the first oen doesn't need a so() 20:12
Xliff But the second one does?
moritz Xliff: for the second, it only needs one if you don't evaluate it in a boolean context
m: my @one = (0, 0, 1); say (@one.one || @one.none.so)
camelia one(0, 0, 1)
moritz if you use the method form, you can ditch a pair of parenthesis
Xliff m: my @one = (0, 0, 1); if @one.one || @one.none.so { say "Hey!" }; 20:13
camelia Hey!
Xliff m: my @one = (0, 0, 0); if @one.one || @one.none.so { say "Hey!" };
camelia Hey!
Xliff m: my @one = (2, 3, 0); if @one.one || @one.none.so { say "Hey!" };
camelia ( no output )
Xliff m: my @one = (2, 3, 0); if @one.one || @one.none { say "Hey!" };
camelia ( no output )
Xliff m: my @one = (0, 3, 0); if @one.one || @one.none { say "Hey!" }; 20:14
camelia Hey!
Xliff m: my @one = (0, 0, 0); if @one.one || @one.none { say "Hey!" };
camelia Hey!
Xliff So the answer is: "Yes." ;)
AlexDaniel m: my @f = (0, 0, 0); say so any @f.one, @f.none 20:17
camelia True
AlexDaniel m: my @f = (0, 1, 0); say so any @f.one, @f.none
camelia True
AlexDaniel m: my @f = (1, 1, 0); say so any @f.one, @f.none
camelia False
moritz Xliff: the "if" puts it into boolean context, yes
AlexDaniel Xliff: ↑ good for code obfuscation contests :)
AlexDaniel actually, `all` is missing 20:18
m: my @f = (1, 1, 0); say so all any @f.one, @f.none
camelia False
AlexDaniel m: my @f = (1, 0, 0); say so all any @f.one, @f.none
camelia True
AlexDaniel :) 20:19
Xliff AlexDaniel: Are you trying to get me committed? 20:21
Oh wait... 20:22
Maybe I should be.
Xliff goes to do "git commit -a"
samcv AlexDaniel: i would just have it be /\x[FE0E]?/ after the atomic symbol 20:25
since we only want this specific codepoint specific to emoji
AlexDaniel samcv: but that won't work, right? 20:27
AlexDaniel so it would have to be [‘⚛’|‘⚛︎’] 20:27
or [‘⚛’|“⚛\xFE0E”] 20:28
samcv: but why is this specific codepoint special? there are 256 variation selectors, are there any limitations for their use?
hobbs AlexDaniel: unicode.org/reports/tr51/#Emoji_Var..._Sequences 20:30
(yes, it's pretty awful) 20:31
moritz AlexDaniel: could be [:ignoremark ‘⚛’] or so, maybe 20:34
hobbs AlexDaniel: and unicode.org/emoji/charts/emoji-variants.html for illustration of what it's supposed to do
AlexDaniel geez why not name it “text variation selector”
moritz: but that will ignore all kinds of Extend (and probably Prepend) characters 20:35
moritz: so all combining characters and other stuff
samcv++ is right, this particular variation selector should be special-cased… 20:36
hobbs++
hobbs: but why 15
:)
hobbs 15 and 16 are the last two, I'm guessing they assumed that anyone who used the selectors for other reasons started at 1 and worked their way up :)
AlexDaniel hobbs: well, not exactly the last two as of today 20:37
hobbs well okay. 20:39
the last two that are only three bytes of UTF-8, though :) 20:40
pmurias the graalvm/truffle NQP backend now passes 13 tests :) 20:45
AlexDaniel pmurias: \o/ that sounds great, is there a list of the passed tests somewhere? 20:46
MasterDuke pmurias++
pmurias: btw, how easy will it be to implement ops that need the tc passed in? 20:47
AlexDaniel: github.com/perl6/nqp/blob/truffle/...sts.pl#L12 20:48
AlexDaniel MasterDuke: so test *files*, not just tests? 20:49
pmurias AlexDaniel: yes, 13 test files :) 20:50
AlexDaniel underestimated the progress but was still impressed
pmurias MasterDuke: depends on the tests
MasterDuke: a lot of the tc using stuff are things that we want to replace with new truffle specific stuff 20:52
MasterDuke pmurias: huh. any intuition which/what? 20:58
samcv AlexDaniel: yes you are correct that variation selector is specific (afaik) to emoji. well at *minimum* after an emoji it has only one meaning 21:00
so it's not ambiguous in that context
pmurias MasterDuke: depends on the stuff, for objects I guess we want to use ssw.jku.at/General/Staff/Daloze/thr...bjects.pdf 21:02
AlexDaniel samcv: hmm github.com/rakudo/rakudo/issues/2031
samcv anyone have ubuntu? can you tell me if llvm-profdata is a valid command? 21:03
and if so where it's located? for those who have ubuntu. if you have debian that may be helpful too
also what version you are on
AlexDaniel samcv: fwiw I don't know if this ticket is reasonable at all 21:04
El_Che samcv: root@716310e078aa:/# llvm-profdata 21:05
llvm-profdata: No command specified!
USAGE: llvm-profdata <merge|show> [args...]
AlexDaniel samcv: gist.github.com/AlexDaniel/024b4e0...72ceb7816d
El_Che samcv: you need to install llvm first, but you know that :)
AlexDaniel samcv: that's under debian btw, but it should be similar in ubuntu 21:06
MasterDuke Command 'llvm-profdata' not found, but can be installed with: sudo apt install llvm
pmurias MasterDuke: and for _I bignum ops I think we will want to still the implemantion from graal.js 21:07
as they have special one that is supposed to work well for truffle 21:08
kjk I use rakudobrew, but every time I build a new version of moar I find that I have to rebuild zef, and re-install all the modules... is there a way to at least avoid re-installing all existing modules? 21:10
pmurias MasterDuke: my mental model how are things going to be implemented is sort of evolving on the fly, I haven't done anything with Truffle before 21:11
MasterDuke pmurias: i was specfically looking at the regular jvm implementation of nqp::x and it has `throw ExceptionHandling.dieInternal(tc, "repeat count (" + count + ") cannot be negative");`
but i haven
't looked at ExceptionHandling.dieInternal() to see what it does
El_Che kjk: I suppose other install options have less problems with that 21:13
MasterDuke some of the string ops look like they might be relatively straight-forward, except that they throw those exceptions with tc 21:14
kjk: needing to rebuild isn't supposed to be as common after updates now-adays 21:15
kjk El_Che: right, I never actually tried other options...
MasterDuke kjk: do things not work unless you do, or is rakudobrew doing it automatically? 21:16
tyil anyone on mastodon who would be able to help this person mastodon.social/web/statuses/100319358554073262
geekosaur some rakudobrew update paths update zef and modules, others don't 21:17
El_Che I keep reading "anyone on methadon"
tyil (or I can post a possible answer to him)
El_Che: if anyone on methadon can help that'd be ok by me too
I don't judg
e
El_Che :)
kjk MasterDuke: so, if I rebuild a new version of moar and then switch to it like this: rakudobrew build moar 2018.06 && rakudobrew global moar-2018.06, then zef would be missing, and I'll have to run: rakudobrew build zef, but then all modules previously installed would also be missing, so I have to zef install them again 21:18
El_Che kjk: what os do you use?
kjk MacOS 21:19
El_Che homebrew has rakudo star
(I am thinking of adding support to monthly rakudo, but haven't had the time)
kjk El_Che: yeah, just checked, looks like it's stuck at 2018.04 21:20
El_Che i don't know what the latest star is
it's every 3 months, so it could be the latest 21:21
AlexDaniel tyil: so if I want to get on mastodon, should I be setting up my own server (like I already do for Matrix), or should I just sign up on mastodon.social and it'll be just as good?
tyil: or if not mastodon.social, then what?
tyil depends on wheter you trust mastodon.social I guess
there's other instances, owned by other people
and you can host one yourself if you prefer that 21:22
MasterDuke kjk: huh. maybe ask tadzik, he's around here
Juerd m: use Test; like("#", /\#/) 21:24
camelia ok 1 - text matches /\ \#/
Juerd Where does that extra escaped whitespace come from?
kjk It looks like zef/ is in the moar-2018.06, maybe if I move it to the new moar vm directory it would just work? hmm ok I'll try that next time 21:25
[Coke] kjk: rakudobrew has some issues and we don't recommend it in general because of issues like this; zoffix has a rebuild script you can use, or you can build from scratch.
I have one that uses rakudobrew, but have a different script to drive it to insure that everything works as I need
[Coke] heads out for a bit 21:26
Juerd Test.pm6 just does $desc = "... $expected.perl()", but using that alone, I can't reproduce the extra space.
kjk Coke: I see..., I do like the ability to try a new rakudo release when it comes out though, and with rakudobrew it's very easy to do so 21:27
tyil kjk: there's rakudup (iirc), or zoffix's script, or just git pull and update it manually based on the readme 21:30
it's not overly complicated to build manually
kjk tyil: I see, ok will check those out, thanks 21:32
El_Che ideally, you should push a monthly rakudo for osx, but the fact that rakudo is not relocable makes it a pita 21:34
tyil that really is a pita
El_Che (e.g. for installing it under the user's applications)
s/you/we/
tyil I'd like it for that to be solved, but iirc it's not a high prio 21:35
it would make packaging for every platform easier I think
El_Che so you end up with the need for installers instead of a simple pkg
tyil El_Che: that's why I wrote LoneStar 21:37
El_Che tyil: it solves the relocation problem, but not the compilation one
tyil compilation on itself isn't a problem to me personally, but most users probably don't want to compile 21:38
from my experience, most users think compiling is scary and evil 21:39
El_Che tyil: it is. We live in a Stockholm syndrom :)
tyil I understand not wanting to compile certain things
like web browsers, office suits, or most compilers
but most applications, including the rakudo/moarvm/nqp stack for Perl 6, are relatively fast 21:40
Zoffix Juerd: it's the "poor man's escape" of # chars that are special in TAP 21:46
Juerd: by sticking a space in there it avoids having to figure out whether we added enough backslashes (since there might be a backslash up in there already) 21:47
MasterDuke Zoffix: looks like geth is dead in #moarvm 21:48
Zoffix huggable: build 21:51
huggable Zoffix, Alternatives to rakudobrew: 3rd party installers: gitlab.com/tyil/lonestar#readme and rakudup.github.io/ | 3rd party distro packages: rakudo.org/files/rakudo/third-party | Bash alias: github.com/zoffixznet/r#table-of-contents
Zoffix ^ there's a bot command that lists all of these
s: &say
SourceBaby Zoffix, Sauce is at github.com/rakudo/rakudo/blob/7a87...rs.pm6#L10
tyil oh, I forgot you added that
Zoffix: is there a page with all huggable commands/definitions 21:52
Zoffix nope 21:52
tyil could one be generated?
Zoffix There's this SQLite file: temp.perl6.party/factoids-Jul-5-2018.sqlite.db 21:53
tyil time to compile sqlite and cruise through it 21:54
tyil nvm, I already have sqlite 21:54
tyil this is a good start 21:54
Juerd Zoffix: Oh, wow. 21:55
MasterDuke Zoffix++ geth is alive again 21:57
tyil in pod defn blocks, could it be made possible to put the word(s) being defined in the pod's meta attribute? so I can give it a special color in Pod::To::Pager 21:58
I want the defined word(s) to be distinct from the actual definition paragraph that follows it
tyil I could make an issue on a repo (which one), SO or ask it on the mailing list if that's a better way to go about it 22:04
Zoffix tyil: FWIW, the factoids are dynamic and anyone can edit/add them, so if you're making a page, it'll quickly be outdated 22:06
buggable: source 22:07
buggable Zoffix, See: github.com/zoffixznet/perl6-buggable
Zoffix something could be implemented to make the bot dump an HTML file
tyil Zoffix: could we make a script to update some file somewhere to refresh it every day or something?
Zoffix buggable: author zoffixznet 22:07
buggable Zoffix, Found 47 dists for zoffixznet. See temp.perl6.party/buggable/91553477...28477.html
Zoffix like this bot does for example 22:08
tyil I could run a local cronjob that issues an commit each day for instance
or that
that sounds better :p
Zoffix buggable: source
buggable Zoffix, See: github.com/zoffixznet/perl6-buggable
Zoffix &
tyil its late now, so I'll look at that source tomorrow 22:08
have to be awake early to get to arnhem on time
Geth doc: 058fa3b183 | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/pod.pod6
Clarify what type pod blocks can have configuration data
22:12
synopsebot_ Link: doc.perl6.org/language/pod
lizmat NLPW schedule: www.perlworkshop.nl/nlpw2018/schedule 22:15
looks like I'm on first :-)
Geth doc: 60e347987f | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/pod.pod6
Tweak info and formatting
22:19
synopsebot_ Link: doc.perl6.org/language/pod
Geth doc: ea9ade5250 | (Tom Browder)++ (committed using GitHub Web editor) | doc/Language/pod.pod6
Add emphasis
22:21
synopsebot_ Link: doc.perl6.org/language/pod
Geth Pod-To-HTML: 2cbcf062b4 | (Tom Browder)++ (committed using GitHub Web editor) | lib/Pod/To/HTML.pm
Caption is now an attribute

Since late 2017.
22:34
AlexDaniel oh wow, writing tests for sake is fun 22:35
one of the few times I actually enjoyed TDD :) 22:36