»ö« 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: Kaiepi++ created pull request #2299:
Write networking API section for JS nutshell
01:06
Kaiepi <Kaiepi> net::icmp's far from trivial to implement so i'm going to get started on net::nntp instead for now 01:17
oodani hi! i'm experimenting with the hyper operators in rakudo star 2018.06 and i'm wondering why these two expressions behave diferently? 02:07
p6: say ("the".ords.permutations>>.chrs); 02:08
camelia ((t h e) (t e h) (h t e) (h e t) (e t h) (e h t))
oodani p6: say ("the".ords.permutations.map: *.chrs);
camelia (the teh hte het eth eht)
oodani is the >>. hyper method call operator not equivalent to a .map? from the docs, it sounds like it should be
i'm aware that >>. doesn't necessarily run the method on each element in order, but there's no side-effects here so that shouldn't be a problem 02:10
Zoffix oodani: no, it's not equivalent to a map. Along with being a hint to the compiler that it can parallelize the call, the behaviour is also affected by nodality of the method, depending on which either nodemap or deepmap is used. That difference is documented in Traps ( docs.perl6.org/language/traps#Usin...changeably ) if the docs you read don't make it clear that hyper is not the same 03:36
yoleaux 2 Sep 2018 14:13Z <AlexDaniel> Zoffix: what's your predicted date for v6.d release? I wanna synchronize it a bit with my plans for future squashathons
2 Sep 2018 14:13Z <AlexDaniel> Zoffix: I mean, synchronize squashathons with whatever you reply :)
Zoffix as map, then they should be amended.
oodani aha! docs.perl6.org/language/operators#...ix_%3E%3E. is what i was reading, so it probably needs clarifying? 03:38
Zoffix .tell AlexDaniel I want to release 6.d roast on Diwali (~Nov. 6) and for the next rakudo release after that to have 6.d enabled by default.
yoleaux Zoffix: I'll pass your message to AlexDaniel.
oodani your irc client may or may not actually linkify that entire link :p 03:39
anyway thanks, the link to the traps page helped a lot! :)
Geth doc: 3663c35b6a | (Zoffix Znet)++ (committed using GitHub Web editor) | doc/Language/operators.pod6
Expand hyper methcall info

Document the whole nodality business.
  (really wordy paragraph; could use improvement)
03:47
synopsebot Link: doc.perl6.org/language/operators
Zoffix oodani: thanks. Added nodality info to that page.
oodani looks good :) 03:48
oodani hmm, the rakudo repl seems to get "confused" by special unicode characters? for instance, if i write a string between the guillemets «», the repl thinks that my command is two columns wider than it actually is, and attempting to go back and edit the command behaves strangely since the actual position of the cursor differs from where the repl expects it to be 06:01
is there a workaround? it sounds like the linenoise library doesn't do utf-8, since that's one of the main features of linenoise ng :/ 06:02
El_Che oodani: check Readline? 06:03
remove Linenoise first
oodani hmm, 'zef install Readline' is having trouble finding the actual library. probably because this is a mac and everything's a mess 06:07
jmerelo oodani: that shouldn't have anything to do with mac stuff.
oodani Cannot locate native library 'libreadline.7.dylib': dlopen(libreadline.7.dylib, 1): image not found 06:09
hmm
jmerelo oodani: ah, OK. You might need to install that library independently first. 06:10
Or use Linenoise. That should work well.
El_Che no, the problem is linenoise 06:11
:)
oodani that's the thing, readline is installed. it's a weird homebrew thing where it's not in the usual library directories though. tried doing LDFLAGS="-L/usr/local/opt/readline/lib" CPPFLAGS="-I/usr/local/opt/readline/include" zef install Readline and got the same result so. hmm
jmerelo It shouldn't be that... 06:12
Hum, I have the same problem in Linux.
Only I use the terminal in Emacs, which solves that problem.
oodani: I think it's NativeCall who's erroring... It's also a dynamic library, LDFLAGS is for static... 06:13
El_Che LD_LIBRARY_PATH=/usr/local/opt/readline/lib perl6 06:15
does that work?
(ah it fails at install time)
jmerelo El_Che: NativeCall should use that env variable anyway
oodani "LD_LIBRARY_PATH=/usr/local/opt/readline/lib zef install Readline" followed by "LD_LIBRARY_PATH=/usr/local/opt/readline/lib perl6" worked, and the unicode char problem doesn't exist under readline 06:18
it's kind of a hassle though 06:19
jmerelo oodani: right. Please create an issue in the repo so that they are aware of that problem... Or better, a PR
El_Che oodani: it's part of the mac setup. You need to figure out how to make the setup global
(or make it global for the user) 06:20
jmerelo I guess export will work in the Mac if you use bash or zsh
oodani i don't think i can. the reason homebrew doesn't make its readline installation global is that macos provides bsd libedit under the same name, and stuff breaks if you shadow it
El_Che echo "export LD_LIBRARY_PATH=/usr/local/opt/readline/lib" > ~/.bashrc
or better:
alias perl6="LD_LIBRARY_PATH=/usr/local/opt/readline/lib perl6" 06:21
something like that
oodani yeah, an alias like that should work. i don't think i'll be needing a repl from noninteractive invocations of perl6 so. all good 06:22
El_Che until you have an other lib installed in a weird place 06:23
oodani yeah, until then
El_Che :)
haven't use a mac much for dev (I use Linux for that and general stuff). The mac machien I have (from work) is a glorified typewriter I use in the train :) 06:24
oodani libraries in weird places is gonna keep happening, since that's how homebrew avoids collisions between libraries it installs and the ones apple installed
maybe i just need to give up on apple tbh
jmerelo El_Che: glorified _and_ expensive
El_Che jmerelo: well, it's an air so not very expensive 06:25
(although it is if you consider the age of the components sold as new)
a good machine though 06:27
(the last with a normal keyboard it seems) 06:28
jmerelo :-)
pmurias m: my int $num = 2**64-1; 08:02
camelia Cannot unbox 64 bit wide bigint into native integer
in block <unit> at <tmp> line 1
pmurias ^^ are we using a right bigint width here? 08:03
moritz could be. int goes from -2**63 to 2**63-1 08:03
m: my int $num = 2**63-1; 08:04
camelia ( no output )
masak curious why 63, not 64. are we doing something with that last bit?
pmurias masak: you mean storing the sign?
masak ponders this 08:05
yes, that makes sense ;)
it would be from 0 upto 2**64-1 if 'twere unsigned 08:06
pmurias the part in the message I'm concerned about is that we are using the unsigned bit size in the error messages that's thrown when storing to a signed integer 08:06
pmurias so you can get a 'cannot unbox a 64 bit wid bigint' when unboxing it into a 64 bit int 08:08
moritz we should add 1 to that error message 08:15
moritz because the sign is represented in the bigint as well, even for positive numbers 08:16
pmurias I'm not sure what that size is supposed to be 08:18
is that the actuall stored size, the size the bigint would take after unboxing or the size when stored as an unsigned number (current) 08:19
pmurias not super important but when printing out some extra info it would be good not to mislead people 08:20
Altreus Anyone made a URL encode module yet?
wait this is going to be built in isn't it
masak .oO( the bigint is a lie! ) 08:21
Altreus gosh, it's URI::Encode not URL 08:21
silly me
donaldh Something odd in docs.perl6.org/routine/%C2%AB%20%C...%AB_%C2%BB 08:38
The 'interpolating quote-words operator' link is back to the same page
AlexDaniel` So colabti should be working again 08:59
yoleaux 5 Sep 2018 13:40Z <El_Che> AlexDaniel`: That needs some work. Travis is x64 only, so will have to run a qemu image to run the acutal image. It can be done, but not easily
AlexDaniel El_Che: ok I see 09:00
yoleaux 03:38Z <Zoffix> AlexDaniel: I want to release 6.d roast on Diwali (~Nov. 6) and for the next rakudo release after that to have 6.d enabled by default.
AlexDaniel Zoffix: OK, thank you! 09:00
jmerelo donaldh: hum. Will check it out. Can you please create an issue? 09:48
buggable New CPAN upload: Hash-with-0.0.2.tar.gz by ELIZABETH cpan.metacpan.org/authors/id/E/EL/...0.2.tar.gz 09:53
Geth doc: 3bffd8282e | (JJ Merelo)++ | doc/Language/operators.pod6
Fixes link found by donaldh

It didn't exist, so it pointed to the same place. Fixed now, I guess.
09:54
synopsebot Link: doc.perl6.org/language/operators
jmerelo donaldh: ^^^ fixed 09:55
pmurias how are binary string ops supposed to work? 11:50
the docs don't tell me what they really do docs.perl6.org/routine/~%7C
scimon So zef reads a couple of json files to work out potential install candidates. Looking at it's it's a list made up of META6.json objects. Is there a way to specify a 3rd list? (For internal modules). I'm hoping there's a config option or file ? 11:51
pmurias with something like ~& how are synthetic graphemes supposed to be treated? 11:59
scimon pmurias: I'm not best to ask as I avoid bit twiddling unless I need to but from the description it turns the strings into bufs zero pads the smaller one and then does a bitwise comparison on them then coerces the result BACK into a string.
And here's where I go and hide under the sofa.
timotimo imagine the surprise and joy when after months you reach between the cushions of your sofa and pull out a scimon or two! 12:13
scimon We do tend to breed down here :) 12:21
moritz if some of the offspring also contributes to Perl 6, I'm all for it :-) 12:23
scimon Meanwhile I'm hoping I'm going to be able to say "We have Perl6 in Production" soon... 12:24
timotimo not long until perl 6 is in produce, too
scimon Mmmm Tasty. 12:26
pmurias scimon: how it turns the string into a buf is the omitted part 12:26
timotimo at what point does it become "produce", btw? like, when a head of lettuce gets harvested and packaged or something? 12:27
pmurias timotimo: I would guess once it's harvested, based on the wikipedia definition it's not processed 12:34
lichtkind i can overwrite @ $m but how to overwrite @$m ? 12:35
i tried sigil namespace but got error 12:36
moritz lichtkind: can you pleae rephrase that question? I didn't understand it 12:51
lichtkind moritz, the infix op "@" and "%" of the type $m has only catch the the cases: @ $m and % $m but not @$m %$m which returns something different 12:53
moritz lichtkind: did you write some code? If yes, where is it? 12:54
also, @$m is just $m.list, so you need something that deals with a Positional or an Iterable on the RHS
lichtkind moritz, in a minute i recheck 12:55
scimon (So... answering my zef question earlier. If I want to DARKPan my repos I need to update the "Repository" section in config.json :) 12:59
lichtkind moritz, i got kicked/traffic issues , not sure what you could read but that @$m gets redirected to .list i got so war i jsut dont know what practically do about that 13:22
tyil lichtkind: o/ 13:25
lichtkind tyil: chers
tyil not sure if you read my direct message on twitter
pmurias timotimo: I can imagine Perl 6 being used to create a GMO, I don't imagine Perl 6 code running on a eddible biological organism 13:25
tyil but the issue you reported seems to be zef related
El_Che www.youtube.com/watch?v=3x7O5cy0TGU <-- jnthn speaking live 13:26
lichtkind tyil i got it and responded
tyil ah
then I'm just outdated, sorry
timotimo ooh, that is *now*!
tyil samcv tried to repro as well, and she could not get it to fail
pmurias timotimo: technically Perl 6 programers (who I guess could manually execute Perl 6 code) are *edible* but I hope they don't end up as produce 13:27
timotimo 6lent green
tyil lichtkind: twitter doesnt show any new messages
fwiw, I kept track of it in this issue gitlab.com/tyil/perl6-app-assixt/issues/18, and will have to assume it's a zef error now 13:28
since we cant repro it in 4 different environments
also, I think we're having a sprint review at $work, so I'll have to afk 13:30
you can leave me .tell messages on irc if anything important comes up :>
timotimo there's so much swishing noises in the stream :( 13:32
also, jonathan's shirt is giving fantastic moiree patterns on the stream! \o/ 13:33
.o( how many aquatic lifeforms are using cro ) 13:35
pmurias the way I implemented ~|, ~&, ~^ on js is that I convert the string into NFC form do the operations on codes and then convert back into a string 13:38
lichtkind tyil all good im glad you want to solve the issue 13:39
colomon zostay: ping? 13:59
pmurias m: say(("@" ~& " ").perl) 14:02
camelia "\0"
leont "P6opaque: no such attribute '$!pos' on type Match in a Int when trying to get a value" is confusing me a little 14:07
timotimo there's at least two ways to get this:
having a "method" be called on one type when it was lexically defined in another, and using a $!foo in that method
or using nqp::getattr on an object of an incompatible type 14:08
leont I'm matching a string against a regex
timotimo then you've found a nice internal bug :)
can you run perl6 with --ll-exception and give us the backtrace?
also maybe the code you're using
oh, and also the perl6 --version
leont paste.scsys.co.uk/581690 14:14
timotimo oh 14:15
i have an idea
m: grammar Foo { method TOP { <item> } } 14:16
camelia ( no output )
timotimo m: grammar Foo { method TOP { <item> } }; Foo.parse("99")
camelia No such method 'MATCH' for invocant of type 'Str'
in block <unit> at <tmp> line 1
timotimo not quite the right one 14:16
but anyway, it could be the grammar is accidentally calling what it thinks is a regex, but is actually a method inherited from Any
or, alternatively, a regex in the grammar is causing an action method to be called that doesn't expect it 14:18
leont I'm reusing a token in a regex, could that be it? 14:19
github.com/Leont/getopt-long6/blob...ong.pm#L19
timotimo m: say "foo".sign 14:21
camelia Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5foo' (indicated by ⏏)
in block <unit> at <tmp> line 1
timotimo maybe it has to be "my token" and <&sign>
try renaming it to something that isn't also an existing method
leont Yeah, that seems to solve it 14:23
Altreus does Perl6 have the concept of a "global" variable in the same way Perl5 does? In that, as long as I fully-qualify the variable name, it will resolve to the most recent runtime-set value, irrespective of where it is or whether I've seen that variable declared? 14:37
so I can set like $API::Discord::DEBUG = 1 and start outputting debug traces? 14:38
leont Rewrote the thing to a grammar anyway. Slightly more verbose but feels more robust 14:42
tadzik Altreus: I think a dynamic variable my be more to your liking 14:46
those are the ones with a star: $*DEBUG or so 14:47
then you can set it lexically, not globally
as in: { my $*DEBUG = 1; $api.i-will-get-debugged() }; $api.but-i-will-not()
Altreus hm 14:48
tadzik and I'm pretty sure you can use the same name no matter how many packages you cross, so no need to fully qualify it 14:49
Altreus and it won't complain that it's never heard of it? 🤔
tadzik m: package Disco { my $*DEBUG = 1; sub rd { say "Debug is: $*DEBUG } }; { my $*DEBUG = 1; Disco::rd; }; Disco::rd; 14:50
camelia 5===SORRY!5=== Error while compiling <tmp>
Unable to parse expression in double quotes; couldn't find final '"' (corresponding starter was at line 1)
at <tmp>:1
------> 3my $*DEBUG = 1; Disco::rd; }; Disco::rd;7⏏5<EOL>
expecting …
tadzik oops
m: package Disco { my $*DEBUG = 1; sub rd { say "Debug is: $*DEBUG" } }; { my $*DEBUG = 1; Disco::rd; }; Disco::rd;
camelia Could not find symbol '&rd'
in block <unit> at <tmp> line 1
14:51
tadzik m: package Disco { my $*DEBUG = 1; our sub rd { say "Debug is: $*DEBUG" } }; { my $*DEBUG = 1; Disco::rd; }; Disco::rd;
camelia Debug is: 1
Dynamic variable $*DEBUG not found
in sub rd at <tmp> line 1
in block <unit> at <tmp> line 1
tadzik oof
forget I said anything
but I'm a bit puzzled as to why it doesn't see the package-scoped one now
buggable New CPAN upload: Sparrowdo-VSTS-YAML-Update-Azure-SSL-0.0.1.tar.gz by MELEZHIK cpan.metacpan.org/authors/id/M/ME/...0.1.tar.gz 15:13
leont What I have done in such situations is «$*DYNAMIC // "default value"» 15:19
Or at least I recollect that working, it's a while ago
TimToady it's probably more efficient to put an overarching 'my $*DYNAMIC;' in the outermost scope if you have access to it, since caching the absence of a variable is problematic 15:57
TimToady (with our current cache) 15:58
colomon is there really no equivalent to the truncate sub in p6?
TimToady doesn't look like it, but you can always Nativecall into the C library 16:00
iirc, libuv didn't support it when the issue last came up 16:01
colomon TimToady: any hints on getting the C filehandle out of the IO::Handle?
TimToady .native-descriptor I believe 16:02
TimToady m: say $*ERR.native-descriptor 16:03
camelia 2
TimToady yup
colomon TimToady++
TimToady I don't know whether you might need to explicitly call ftruncate64 offhand 16:09
if someone has written a POSIX module, I don't know about it yet (or anymore, in the senile way of things) 16:11
colomon TimToady: just plain ftruncate seems to be working for me. 16:17
TimToady try it on a file larger than 4 gigs?
of course, if you files never get that big, doesn't matter :) 16:18
colomon I think it’s supposed to automatically promote to ftrunate64 internally, if I understood correctly.
but yeah, my files are never going to get anywhere near that long.
(translating some perl 5 $workhorse scripts to perl 6 because I’m having difficulty getting needed p5 modules working on my Mac.) 16:20
lizmat . 16:33
El_Che lizmat: how is the SPW? 16:35
watched some of jnthn's talk online
lizmat very good... :-)
the only thing not good is the fact that the WiFi blocks IRC 16:36
:-(
so yeah, that worked :-
)
diakopter well there's webchat.freenode.net/ 16:37
El_Che lizmat: use a ssh socks proxy? 16:39
lizmat yeah... too much trouble :-) 16:40
the easiest fix would have been to get out my phone and tether
El_Che "ssh -D 8080 $host" <-- ow, so much typing, I feel your pain :)
lizmat socializing& 16:41
tadzik tbh I'd sooner put up a proper wifi from phone than look up the syntax for ssh proxy :P 16:42
El_Che lol
tadzik assuming that wifi allows ssh :P
El_Che tadzik: I always run a vpn instance on port 443 and 80 16:43
not very likely to be closed
tadzik ah, I have both of those already used on my server :)
there is some hack to run both an httpd and openvpn on the same port, but eh, I usually just not use the wifi if it's this crappy
El_Che tadzik: there hacks for that
a splitter like daemon 16:44
but I wouldn't bother :)
tadzik I was recently at a hotel that said "no VPN clients allowed" on the landing page :P
just in case you wanted to do work on their 512kbps, 100MB limited crap
I made sure to let them know what influenced my review scores 16:45
El_Che lol
no VPN allowed, wtf
https will be punished with cold showers
timotimo "we do not route packets that have the evil bit set" 16:46
El_Che we reserve the right to serve you add and sotre ypur password!
Geth doc: 6988308c88 | (Ben Davies)++ (committed by Patrick Spek) | doc/Language/js-nutshell.pod6
Write networking API section for JS nutshell (#2299)
16:47
synopsebot Link: doc.perl6.org/language/js-nutshell
clemclem hello all 17:19
tyil hi clemclem 17:20
clemclem 10 years ago I used to be a perl programmer 17:23
I also published a cpan module
metacpan.org/author/CBIONDO
tyil are you looking to get back into it with Perl 6? :D 17:24
clemclem yep I was thinking if thee is some way I can help the perl 6 community 17:25
I am italian
tyil always
clemclem I work as a software architect
tyil if you use it for your personal projects you could help promote it, if you want to go a bit deeper there's plenty of issues on the github repos to look into
there are issues with tags indicating they're good for beginners to pick up 17:26
clemclem linkedin.com/in/clemente-biondo
there is the need for an italian version of the documentation? This way I can also start relearning the language
tyil I don't think we have alternate translations of docs.perl6.org yet, I know perl6intro.com has been translated multiple times,but Italian is already done there 17:29
clemclem nod
tyil it would be nice to have the docs.perl6.org in multiple languages, but I don't think there's support for internationalisation on the current version of it
perl6intro.com/it/ for the Italian version of the Perl 6 intro, btw 17:30
clemclem thanks faor your time
will take a look :-)
for
tyil if you need help, don't be afraid to ask :>
clemclem thank you very much!
vrurg I desperately need help with this: stackoverflow.com/questions/522274...d-closures 17:56
timotimo i read "roles and closures" and immediately want to say "roles and classes don't close over their surroundings" 17:58
but maybe i should read the actual question instead of just the title
vrurg timotimo: compile time, trait... Too much to fit into one subject. 17:59
timotimo the horizontal scrolling is making it kind of hard to see everything 18:02
diakopter vrurg: skimmed it; initial thought: bug
(primarily from the "Now, to another trick. I remove does BarRole from FooRole and make it applied directly on Foo" thing)
timotimo m: class Test { }; class Bloop { }; sub do-the-add($class, $foo) { my $outer = $foo ~ "closured" ~ $++; $class.^add_method("bleh", method { "it does the thing for $outer" }) }; do-the-add(Test, 1); do-the-add(Bloop, 2); Test.^compose; Bloop.^compose; Test.bleh; Bloop.bleh; 18:05
camelia ( no output )
timotimo m: class Test { }; class Bloop { }; sub do-the-add($class, $foo) { my $outer = $foo ~ "closured" ~ $++; $class.^add_method("bleh", method { "it does the thing for $outer" }) }; do-the-add(Test, 1); do-the-add(Bloop, 2); Test.^compose; Bloop.^compose; say Test.bleh; say Bloop.bleh;
camelia it does the thing for 1closured0
it does the thing for 2closured1
vrurg I'm sorry, have to go for a couple of hour. If its not too much trouble, I'd like to ask to leave comments on SO. 18:10
diakopter: I suspect a bug too. Would it be something intended removal of 'does BarRole' wouldn't affect the result. But it does. 18:11
vrurg is away...
pukku Hi! Quick question: can I make the following code any better? 18:22
for %perf<ringers>.keys.sort(&infix:'<=>') -> $n { $rdata<ringers>.push: { num => $n, ringer => %perf<ringers>{$n} }; } 18:23
Basically, I want to take a hash of data, and turn into an array of hashes, sorted by the key.
pyrimidine Ulti: around?
lichtkind moritz confirmed me that @$m is redirected to $m.list, how can i change that?
pukku (also, that parameter for sort is actually passed as "&infix:«<=>»" 18:24
)
pyrimidine is wondering whether there should be some benchmarks akin to Tux's CSV, but for us bioinfo types ...
AlexDaniel pyrimidine: what about github.com/japhb/perl6-bench ? 18:27
moritz lichtkind: you can try to overload prefix:<@> 18:31
pyrimidine AlexDaniel: that looks quite useful! Are there other benchmarks that are public and up-to-date, apart from the CSV ones that Tux posts on #perl6-dev? 18:59
lichtkind moritz you said somethign about Iterable, i guess you mean the role 19:09
japhb pyrimidine: There have been lots of benchmarks over the years; I had intended to merge the popular ones back to perl6-bench, but I ran out of free time. The structure should be there should you want to do so yourself, and I'm happy to take PRs. :-) 19:10
pyrimidine Thanks japhb! Re: lack of free time: yep, happens to us all :) 19:11
Altreus m: class P { sub foo ($cats) { say $cats } } class C is P { sub foo () { say "meow" } } my C $c .= new; $c.foo('baa'); $c.foo; 19:34
camelia 5===SORRY!5=== Error while compiling <tmp>
Strange text after block (missing semicolon or comma?)
at <tmp>:1
------> 3lass P { sub foo ($cats) { say $cats } }7⏏5 class C is P { sub foo () { say "meow"
expecting any of:
Altreus oh
m: class P { sub foo ($cats) { say $cats } }; class C is P { sub foo () { say "meow" } }; my C $c .= new; $c.foo('baa'); $c.foo; 19:35
camelia No such method 'foo' for invocant of type 'C'
in block <unit> at <tmp> line 1
Altreus oh
m: class P { method foo ($cats) { say $cats } }; class C is P { method foo () { say "meow" } }; my C $c .= new; $c.foo('baa'); $c.foo;
camelia Too many positionals passed; expected 1 argument but got 2
in method foo at <tmp> line 1
in block <unit> at <tmp> line 1
Altreus m: class P { method foo ($cats) { say $cats } }; class C is P { multi method foo () { say "meow" } }; my C $c .= new; $c.foo('baa'); $c.foo;
camelia Cannot resolve caller foo(C: Str); none of these signatures match:
(C: *%_)
in block <unit> at <tmp> line 1
Altreus hmm 19:36
is what I'm doing possible without the base class already making it multi?
timotimo you can add a candidate that defers to the base class, for example 19:41
Altreus would you do that just by providing multi method foo ($cats) { nextsame }? 19:50
or proto shenanigans?
timotimo no, that wouldn't work i don't think 19:51
you'd self.BaseClass::foo
Altreus you are correct as usual :) 19:54
This feels like a thing that could have more DWIM
Altreus hmm 19:58
I have a situation I don't understand :)
I'm going to push a branch 19:59
Altreus github.com/shuppet/p6-api-discord/...01c71cbe8a 20:02
This role
So the other role, HTTPResource, has the CRUD methods but they require a rest object. github.com/shuppet/p6-api-discord/...e.pm6#L106 20:03
well the commit diff probably speaks for itself 20:04
but then when I run it it says Cannot have a multi candidate for 'create' when an only method is also in the package 'API::Discord::Channel'
is it because the HTTPResource role adds an only method even though the Object role overrides it? 20:05
Kaiepi how can i get a list of bits from a Blob[uint8] and be able to convert it back? 20:07
Geth doc: 0b11f85fe9 | (JJ Merelo)++ | doc/Type/List.pod6
Adds examples on multicriteria sort

Which I understand is what's behind #1297. There was already an example, but these new ones maybe clarify it, thus closes #1297
synopsebot Link: doc.perl6.org/type/List
Ulti pyrimidine: [6~[6~[6~Im about now just back logging 20:19
Ulti pyrimidine: github.com/japhb/perl6-bench/pull/23 yeah didnt finish this off back in 2015 :/ 20:20
pyrimidine Ah, ok; those make sense. I was thinking a FASTA parsing one as well, primarily to compare 5 vs 6 and grammars vs line-by-line parsing 20:22
masak hm, what are the options for forward-referencing a type again? 20:23
Ulti pyrimidine: you've seen the blog article from timotimo ?
masak m: class A { has B $.b }; class B {}
camelia 5===SORRY!5===
Type 'B' is not declared
at <tmp>:1
------> 3class A { has B7⏏5 $.b }; class B {}
Malformed has
at <tmp>:1
------> 3class A { has7⏏5 B $.b }; class B {}
pyrimidine Ulti: Yep
Ulti k k
masak m: class B { ... }; class A { has B $.b }; class B {}
camelia ( no output )
masak right, that's one of the options.
m: class A { has ::{"B"} $.b }; class B {} 20:24
camelia 5===SORRY!5=== Error while compiling <tmp>
Autovivifying object closures not yet implemented. Sorry.
at <tmp>:1
------> 3class A { has ::{"B"}7⏏5 $.b }; class B {}
Ulti pyrimidine: for what its worth I've been doing a bit of this manually for a while with fasta parsing and 6frame translation perl6advent.wordpress.com/2017/12/...%9F%8E%B6/ 20:25
not really a proper benchmark though more just general tracking improvement 20:26
pyrimidine I'm really wondering whether the best initial thing would be to set up the basic libraries that use things like htslib
via NativeCall 20:27
then work on the 'pure perl6' parsing alongside it.
With perl6 I've seen some interesting variation re: speed of chunking by record delimiter ("\n>") vs using a grammar. Seems to be highly dependent on the length of the sequence itself. Not sure why 20:28
Ulti yeah htslib is on my wish list, I keep trying to convince the author of the more recent perl 5 bindings to give it a go ;) 20:28
yeah my original fasta implementation had a concept of rec separator to split a file separate from the grammar already for that reason 20:29
really I should update it to make that a supply and run the grammar in parallel 20:30
pyrimidine I have a small FASTA file of ~12k protein seqs of ~200aa each, which using chunking is 1.7s on my older Macbook Air, but using a grammar is about 1s. 20:31
But I also have a long-read file of 10k sequences up to 10000bp or more, and the grammar is much slower (chunking is 2s, grammar is ~7s). 20:32
Agreed re: using a supply, makes sense
masak .oO( "supplies!" ) 20:36
lizmat . 20:41
leont With grammars it's easier to accidentally go O(bad) I guess 20:59
moritz though tokens (no backtracking) reduce that risk again 21:01
masak not sure I've seen that notion expressed outside of the Perl 6 world, that grammars should strive towards ratcheting semantics, not backtracking 21:11
geekosaur haskell's parsec/megaparsec do so by making you explicitly request backtracking. and it is a generally recognized consideration from what I've seen. hidden because msot folks use token-based parser generators 21:13
or use regex based stuff and wonder why it performs so bad :p
leont My experience in YAMLish was similar, while I needed some backtracking it is the exception not the rule 21:19
masak geekosaur: tokenization (as a separate step) is another fun one where I feel Perl 6 has "warped" me 21:21
masak geekosaur: nothing wrong at all with a separate tokenization/lexer step. in fact, in most applications it's a nice way to "chunk" the input from individual characters to tokens 21:22
...but, it won't work in a language with slangs, like Perl 6 or 007.
geekosaur wasn't saying ti was wrong, just that it "hides" the backtracking aspectto some extent as you said
masak nodnod
though tokenization tends to be fairly non-backtracking 21:23
geekosaur I... am wonderin if I'mmaking sense. I mean, that was the point
masak it'd be nice if it turns out we're talking past each other, but agreeing all the while 21:27
geekosaur strongly suspects that's the case 21:29
ToddAndMargo I am trying to configure pigion for this chat. What is the protocol? ICQ, IRC? 22:44
next question. how do I do a case insensitive "contains"? 22:45
Kaiepi irc 22:49
ToddAndMargo Thak you! 22:50
Kaiepi for contains you could use the i flag with a regex 22:50
ToddAndMargo p6 'if "2018 Jul 7".contains( "jul", 3 ) {say "Yes";}' 22:51
I don't understand. I am trying to avoid a regex
Kaiepi oh, didn't realize there's a contains method
vrurg m: say "aAbB".fc.contains("ab".fc) 22:53
camelia True
Geth doc: 0141d3fc73 | (Curt Tilmes)++ | doc/Type/Cool.pod6
clarify that Cool/contains $start param is characters into the string
synopsebot Link: doc.perl6.org/type/Cool
vrurg ToddAndMargo: is it what you're lookng for?
ToddAndMargo testing 22:53
Yup! That works! Thank you! 22:54
Pegion is a pain in the neck to try and figure out!
vrurg yw 22:56
ToddAndMargo I will ask the fedora group how to operate it.
ToddAndMargo How about "contains" and starts with? 23:12