»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend! Set by moritz on 22 December 2015. |
|||
RabidGravy | well don't do that then | 00:00 | |
00:01
kurahaupo left
|
|||
timotimo | you can't really write every algorithm to be branchless :) | 00:01 | |
not without pain, at the very least :D | |||
00:02
obfusk left
|
|||
RabidGravy | no but you have an asymetric architecure and clever compilers | 00:02 | |
00:03
obfusk joined
|
|||
RabidGravy | anyhow I'm whacked | 00:03 | |
toodles | |||
timotimo | toodles, mister gravy | ||
00:04
Skarsnik left
00:08
RabidGravy left
00:20
kid511 joined
00:22
kid51 left
00:24
itcharlie joined
00:30
huggable left,
huggable joined
00:43
pierre_ joined
00:46
tbrowder left
00:48
hotel joined,
BenGoldberg joined,
pRiVi left,
cpage_ joined
00:49
SquireOfGothos left,
avar left,
kurahaupo joined,
hotel|lethargy left
00:50
avar joined,
avar left,
avar joined,
literal joined
00:52
pRiVi joined
01:01
hotel_california joined
01:02
hotel left
01:05
cdg left,
hotel_california is now known as hotel,
cdg joined
|
|||
ZoffixWin | stmuk, what needs to happen to have my blog posts that show up on pl6anet.org/ to be from perl6.party and not from blogs.perl.org? [Eventually] the .party posts will look better and they also offer in-browser modifiable and runnable code examples, so I rather have that as default. | 01:07 | |
hotel | how do you use panda on windows again? | 01:09 | |
I have to make some batch file right? | |||
01:10
cdg left
|
|||
ZoffixWin | hotel, does panda command not work|? | 01:12 | |
hotel | no, it hangs | ||
and apparently this has been the case since 2013 perl6maven.com/getting-started-with...on-windows | |||
ZoffixWin | :/ | 01:13 | |
hotel, what Perl are you on? Did you use R* installation? 2016.04? | |||
hotel | yeah | ||
ZoffixWin | And what exact command does it hang on? (What Windows are you on, BTW)? | ||
hotel | I think it's because windows tries to call the shell script and doesn't know what to do | ||
running panda update, or any panda command | |||
>windows X | 01:14 | ||
ZoffixWin | X? | ||
Oh 10 | |||
ZoffixWin only has 7 | |||
hotel | hm | 01:15 | |
timotimo | there are 7 windows in my apartment, too | ||
hotel | weird, the fix on that link worked on my other computer | 01:16 | |
ZoffixWin | fwiw, `panda` "works" on Win7, but fails to fetch HTTP::Tinyish for some reason :S i.imgur.com/Dsfzffp.png | 01:18 | |
Oh... do I need some sort of git thing on Windows? | 01:19 | ||
hotel | git-scm.org | ||
ZoffixWin | That doesn't answer my question :D | 01:20 | |
ZoffixWin doesn't use Windows for anything other than gaming | |||
01:21
mr-foobar left
|
|||
ZoffixWin | I'm just saying we have no mention of needing git things on Download page. If it's a requirement, it should be mentioned | 01:21 | |
ugexe | zef does not require git on windows, but will use it if available fwiw | ||
hotel | huh? puu.sh/oHMQy/a054f301d3.png | ||
01:22
Ben_Goldberg joined
|
|||
itcharlie | zef bro | 01:22 | |
01:22
BenGoldberg left
|
|||
itcharlie | thats what you need | 01:22 | |
01:22
Ben_Goldberg is now known as BenGoldberg
|
|||
hotel | teach me the ways | 01:22 | |
ZoffixWin | ugexe, how to get zef without panda or rakudobrew? | ||
01:22
BenGoldberg left
|
|||
ZoffixWin | or git things :P | 01:22 | |
ugexe | ZoffixWin: download the .zip from github | ||
ZoffixWin | Right. Makes sense. ugexe++ | 01:23 | |
hotel | ZoffixWin, I guess they assume that if someone is using perl6 on windows they already have some sorta git thing? ¯\_(ツ)_/¯ | ||
ugexe | zef can also install .zip archive links from github | ||
ZoffixWin | hotel, well... try zef: github.com/ugexe/zef | ||
hotel | yeah I'm there :) | ||
01:24
Ben_Goldberg joined
|
|||
hotel | man, windows really hates files without extensions | 01:26 | |
gfldex | i just got `Failed to open file /usr/local/src/rakudo/install/share/perl6/site/precomp/.lock: permission denied` after rebuilding Rakudo | ||
here the stacktrace: gist.github.com/gfldex/ec7a4acd1a2...230d4a27a4 | 01:27 | ||
ugexe | i suppose there is still a flaw though: if the source-url of a module is a git link (and all of them are that are not on cpan) it won't try to guess its archive url. this means you would have to `zef install github.com/xxx/yyy/master.zip` for each module (or manually s/// the urls in the package list) | 01:28 | |
hotel | ugexe, I don't even anymore: puu.sh/oHNck/af950d0f43.png | ||
01:28
Ben_Goldberg left
01:30
Ben_Goldberg joined
|
|||
hotel | wow puu.sh/oHNhB/6f0c2c66e5.png | 01:30 | |
also Im dumb | |||
ugexe | heh | ||
stupid unzipper putting it in a stupid folder of the same name as the child folder | |||
hotel | yeah | 01:31 | |
01:32
hotel is now known as hotel|chagrin
01:34
sno left,
sno joined
01:35
Actualeyes joined
|
|||
hotel|chagrin | interestingly, in order to get cmd to recognise that zef is on the path, I have to call it zef.pl6.bat | 01:38 | |
ugexe | that is from rakudo itself i believe | 01:42 | |
hotel|chagrin | putting zef.bat (which calls the other bat) in rakudo/bin works though... | ||
ugexe | here is a modified $HOME/.zef/store/p6c/packages.json that has all the git urls turned into their .zip gist.github.com/ugexe/c408d997fcf5...f0889a9bd3 | ||
hotel|chagrin | but anyway, zef works so thanks :) | 01:43 | |
01:43
hotel|chagrin is now known as hotel
|
|||
ZoffixWin | \o/ | 01:43 | |
ugexe | strange about the .bat though, i'm able to invoke it with just `zef` | 01:44 | |
01:44
ilbot3 left
|
|||
hotel | yeah dunno | 01:44 | |
now I have to make this stop puu.sh/oHNZh/1fac35871e.png | |||
ugexe | the js backend? wth | 01:45 | |
hotel | atom perl6 plugin thing idk | ||
ugexe | oh | ||
hotel | m: say comb "aesthetics"; | 01:46 | |
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/DpRaj37jSgCalling comb(Str) will never work with proto signature ($,, $?)at /tmp/DpRaj37jSg:1------> 3say 7⏏5comb "aesthetics";» | ||
01:47
ilbot3 joined
|
|||
ugexe | m: say comb //, "aesthetics" | 01:48 | |
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/qVZXxTgZTpNull regex not allowedat /tmp/qVZXxTgZTp:1------> 3say comb //7⏏5, "aesthetics"» | ||
hotel | it works if you use your own sub | ||
ZoffixWin | m: say comb /./, "aesthetics"; | ||
camelia | rakudo-moar 780f07: OUTPUT«(a e s t h e t i c s)» | ||
hotel | m: sub foo($t) { return $t.comb; } say foo "hello"; | ||
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/FEm7QYd0tdStrange text after block (missing semicolon or comma?)at /tmp/FEm7QYd0td:1------> 3sub foo($t) { return $t.comb; }7⏏5 say foo "hello"; expecting any of: infix …» | ||
hotel | m: sub foo($t) { return $t.comb }; say foo "hello"; | ||
camelia | rakudo-moar 780f07: OUTPUT«(h e l l o)» | ||
ZoffixWin | : | 01:49 | |
:\ | |||
hotel, that's nonsense. | |||
hotel | how so? | ||
ugexe | looks like method comb and sub comb are missing that relation | 01:50 | |
ZoffixWin | hotel, comb sub always needs a matcher. Method form breaks up into characters without a matcher. | ||
hotel, so instead of actually giving it a matcher, you're creating a whole 'nother sub just to call it with a default matcher that breaks up into characters | |||
ugexe | no matcher method comb has been touted for splitting a string into individual letters though | ||
hotel | ^ | 01:51 | |
ZoffixWin | It uses substr, yes: github.com/rakudo/rakudo/blob/nom/...tr.pm#L121 | ||
ugexe | creating a new sub for it though is indeed pointless | ||
m: say "hello".comb | |||
camelia | rakudo-moar 780f07: OUTPUT«(h e l l o)» | ||
hotel | hey I'm learning don't bite my head off | ||
ZoffixWin | ¯\_(ツ)_/¯ | 01:52 | |
ZoffixWin is just talking | |||
ugexe | i dont think anyone knows all of perl6, dont sweat it | ||
hotel | haha | ||
ZoffixWin | FWIW: perl6.party/post/20160425-Perl6-Comb-It | ||
surprisingly, I never bother to mention any usecase of the sub form of .comb :/ | 01:53 | ||
hotel | I mean, of course I wouldn't make a sub to call comb normally, I was just making sure stuff worked :P | ||
01:54
colomon left
|
|||
ZoffixWin | hotel, IMO, you should rakudobug this. I see no reason why sub comb(Str) should not break up into chars: github.com/rakudo/rakudo/blob/c403...ol.pm#L338 | 01:54 | |
01:54
Ben_Goldberg left
|
|||
ZoffixWin | For consistency with the method form, it should | 01:54 | |
hotel | what do you mean? | ||
like it shouldn't require a match? | 01:55 | ||
grondilu | tadzik: panda question: do I still have to run ./bootstrap.pl everytime I recompile rakudo | ||
? | |||
01:55
Ben_Goldberg joined
|
|||
ZoffixWin | hotel, right. comb "blah"; should behave the same as "blah".comb; And it's possible, but simply not implemented. Report it: github.com/rakudo/rakudo/#reporting-bugs | 01:55 | |
hotel | alright, wilco | ||
ZoffixWin | hotel++ | 01:56 | |
ugexe | or overengineer a solution with &comb.wrap or MONKEY-TYPING | ||
ZoffixWin | :) | ||
01:57
Ben_Goldberg left
|
|||
grondilu | nevermind I had a syntax error in my META.info | 01:58 | |
01:58
Ben_Goldberg joined
|
|||
ugexe | you can probably get a PR in with `multi sub comb(Cool $input, $limit = *) { $input.comb($limit) }` at github.com/rakudo/rakudo/blob/c403...ol.pm#L342 (untested) | 02:00 | |
that proto ($, $, $?) might not like that though | 02:01 | ||
02:01
BenGoldberg_ joined,
Ben_Goldberg left,
BenGoldberg_ is now known as Ben_Goldberg
02:02
Ben_Goldberg is now known as BenGoldberg,
cpage_ left
|
|||
hotel | protos are default signatures? | 02:03 | |
ZoffixWin | That creates ambiguity between comb Int, $input. No $limit should be there. As in method form: github.com/rakudo/rakudo/blob/c403...ol.pm#L246 | ||
02:04
BenGoldberg left
|
|||
ZoffixWin still has no idea wtf protos are :P | 02:04 | ||
hotel | oh | ||
02:05
BenGoldberg joined
|
|||
hotel sets out to build an http server out of pieces of scrap metal and rusty tools | 02:05 | ||
ZoffixWin | heh... hotel++ # nice rt signature :PO | ||
ugexe | ($, $, $?) means 2 required positionals and an optional 3rd positional (like perl5) | ||
ZoffixWin | ugexe, what it means is clear, but why is it needed? What does it do? | 02:06 | |
ZoffixWin submits a PR to fix the comb() stuff along with the tests in roast | |||
ugexe | proto itself is for handling dispatching, so it would affect nextsame/callsame etc type stuff | ||
hotel | I didn't think it was clear | ||
ZoffixWin | hotel, it's good enough | 02:07 | |
ugexe | it also gives you a single item to `is export` and whatnot | ||
hotel | no I mean what the protos mean | ||
ZoffixWin | Ah | ||
ugexe | or do stuff like `proto foo { {*}.say }; multi method foo { "42" }` | 02:08 | |
ZoffixWin | Yeah, I still have no clue. Even with ugexe's explanation. Wouldn't dispatching handle the same with multies and what not? | ||
ZoffixWin leaves this for "another day" | |||
ugexe | if you have multis from multiple roles/classes then i believe it helps act as the authority | ||
hotel | like a template or something? | ||
ugexe | thats how I use them | 02:09 | |
02:09
BenGoldberg left
|
|||
hotel | cool | 02:10 | |
02:10
BenGoldberg joined
|
|||
hotel forgot how to import modules | 02:10 | ||
ZoffixWin | use blah; | ||
ugexe | `proto foo { {*}.say }; multi method foo(Int $a) { "42" }; multi method foo(Str $a) { "fourty two" }` -> xxx.foo(1) (says 42) xxx.foo("x") (says fourty two) | 02:11 | |
grondilu | also the lexical scope must be defined on the proto | ||
ugexe | so you can also put some top level shared code in them | ||
grondilu | you can't do 'our multi' | ||
hotel | oh it's imperative not gerund | ||
ZoffixWin++ | |||
ugexe | s/.say/.IO/ and it will always return an IO::Path | 02:12 | |
02:14
cpage_ joined
|
|||
hotel | m: my constant H = 10; say H; | 02:16 | |
camelia | rakudo-moar 780f07: OUTPUT«10» | ||
02:16
noganex_ joined
|
|||
hotel | so constants don't need sigils? | 02:16 | |
ZoffixWin | nope | 02:17 | |
m: my \Δ = 10; say Δ; | |||
camelia | rakudo-moar 780f07: OUTPUT«10» | ||
hotel | is \ shorthand for constant? | 02:19 | |
ZoffixWin | I wouldn't say shorthand. I think it's something to do with having containerless variables or something | ||
02:19
noganex left
|
|||
ZoffixWin is too drunk to give good advice :P | 02:19 | ||
hotel | again? lol | 02:20 | |
ZoffixWin | I'm quitting tomorrow! I promise! | ||
:P | |||
02:22
pierre_ left
|
|||
hotel | tomorrow's friday though | 02:23 | |
can't expect you to :P | |||
ZoffixWin | For me, today is Friday :P I booked tomorrow off. | 02:24 | |
hotel | what are the colon things in method calls again? | ||
oh gg | |||
ZoffixWin | Like foo.bar: 'blah'? They let you omit using parentheses | ||
hotel | my $listen = IO::Socket::INET.new(:listen, :localport(3333)); | ||
ZoffixWin | Oh, those are just pairs | ||
my $listen = IO::Socket::INET.new(listen => True, localport => 3333); | 02:25 | ||
hotel | interesting | ||
ZoffixWin | named args | ||
m: sub foo (:$name, :$num) { say "\$name is $name and \$num is $num" }; foo :name<Foo> :num<42> | 02:26 | ||
camelia | rakudo-moar 780f07: OUTPUT«$name is Foo and $num is 42» | ||
ZoffixWin | m: sub foo (:$name, :$num) { say "\$name is $name and \$num is $num" }; foo :name<Foo> :42num | ||
camelia | rakudo-moar 780f07: OUTPUT«$name is Foo and $num is 42» | ||
ZoffixWin | (you don't need commas if all you got are named args) | 02:27 | |
ugexe | m: sub foo(:a(:b(:$c))) { say $c; }; foo( a => 42 ) # also can do aliases | ||
camelia | rakudo-moar 780f07: OUTPUT«42» | ||
ZoffixWin | :o | ||
That's awesome ugexe++ | 02:28 | ||
02:28
kid511 left
|
|||
ugexe | handy for writing short versions of MAIN args | 02:28 | |
02:29
cpage_ left
|
|||
ugexe | perl6 -e 'sub MAIN(:o(:$out)!) { say $out }' # Usage: -e '...' -o|--out=<Any> | 02:30 | |
02:32
nowan_ left
02:33
nowan joined
|
|||
ZoffixWin | this is annoying... spectest in a VM eats so much CPU it interrupts my music in Windows host :/ Windows-- | 02:41 | |
ZoffixWin spins up 20-core 98GB-RAM Linode box just because he can o/ | 02:42 | ||
ugexe | building jvm rakudo on windows would freeze my entire machine for a few seconds ever 10 seconds or so | ||
also spins the fan up faster than any game i've put it through :x | 02:43 | ||
hotel | some spectests don't work on windows iirc | 02:45 | |
02:48
pierre_ joined
|
|||
hotel | is there a standard for using single quotes vs double quotes? I know double quotes do some extra fancy stuff, so is there really a reason to use single quotes? | 02:50 | |
ZoffixWin uses single quotes when he doesn't expect to have "extra fancy stuff" to happen | 02:51 | ||
hotel | is there a benefit to doing that though? | 02:52 | |
ZoffixWin | Lack of bugs due to accidental interpolation | ||
hotel | ah | ||
ZoffixWin | Lack of bugs due to accidental interpolation | 02:53 | |
m: say "Email me at [email@hidden.address] | |||
camelia | rakudo-moar 780f07: OUTPUT«Email me at [email@hidden.address] | ||
ZoffixWin | :/ | ||
Well, at least that was my reasoning back when using Perl 5 :P | |||
ugexe | m: say "C:\t\foo" | 02:54 | |
camelia | rakudo-moar 780f07: OUTPUT«C: oo» | ||
02:54
Ben_Goldberg joined,
BenGoldberg left
|
|||
ugexe | email addresses always get me in perl5 too | 02:54 | |
02:54
Ben_Goldberg is now known as BenGoldberg
|
|||
ZoffixWin | Ah, right, in P6 you need to have [] after arrays when interpolating | 02:54 | |
ugexe | we get this one instead tho | 02:55 | |
m: say "{" | |||
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/h8d2QyyEn0Unable to parse expression in double quotes; couldn't find final '"' at /tmp/h8d2QyyEn0:1------> 3say "{"7⏏5<EOL> expecting any of: double quotes term» | ||
hotel | what are the rules for doing the thing where $foo.bar "baz"; works? | ||
ZoffixWin | Yup. Any time you try to put CSS in a interpolating heredoc :P | ||
m: class F { method bar ($x) {"Foo $x"}}; my $meow = F.new; sasy "$meow.bar("42")" | 02:57 | ||
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/m0WoB2HqNqUndeclared routine: sasy used at line 1. Did you mean 'say'?» | ||
ZoffixWin | ..... "sasy"? 0.o | ||
Ohhh | |||
m: class F { method bar ($x) {"Foo $x"}}; my $meow = F.new; say "$meow.bar("42")" | |||
camelia | rakudo-moar 780f07: OUTPUT«Foo 42» | ||
ZoffixWin | use just () for method calls with no args | 02:58 | |
hotel | rip in peace puu.sh/oHREW/24b14fb92e.png | ||
apparently the HTTP::Headers module doesn't add in the HTTP/1.1 part | |||
ugexe | m: class Foo { method bar { 42 }; }; say Foo.new."bar"() # ? | ||
camelia | rakudo-moar 780f07: OUTPUT«42» | ||
ugexe | ah | 02:59 | |
03:00
cpage_ joined
|
|||
ZoffixWin | For a 20-core 98GB-RAM box, Perl 5 is sure taking its sweet ass time installing and testing itself :/ | 03:00 | |
hotel | are you on a server? 0.0 | 03:01 | |
03:02
milwaukee joined
|
|||
hotel | also downloadmoreram.com because it sounds like you don't have enough | 03:02 | |
ZoffixWin | yeah. I'm on Linode.com | ||
pfft... what do you mean!? I have 98GB of it! :D | |||
Default perlbrew perl5 tests are just stupid | 03:03 | ||
ZoffixWin blames mst for all of this | |||
Why? Just 'cause I can! :P | |||
hotel | just download some more ram ^^ | ||
ugexe | to be fair, HTTP/1.1 isnt a header line. then again neither is the status line but that is there (200 OK) | 03:05 | |
03:05
BenGoldberg left
|
|||
hotel | oh good point | 03:06 | |
ugexe | well, unless it in `Status: 200` or whatever format | ||
03:06
milwaukee left
|
|||
hotel is dumb again | 03:07 | ||
03:07
hotel is now known as hotel|chagrin,
BenGoldberg joined
|
|||
ugexe | i imagine his intention though is to have the http api separate so you can use 1.0 *or* 1.1. but its doubtful to work with 2.0 | 03:07 | |
03:07
milwaukee joined
|
|||
hotel|chagrin | pshah who uses 2.0 anyway | 03:09 | |
03:09
BenGoldberg left
|
|||
hotel|chagrin | also, for some reason, writing "HTTP/1.1 200 OK" to the client's connection makes it so that nothing else is written | 03:10 | |
ugexe | need more streams to get those ads to you faster | ||
03:10
BenGoldberg joined
|
|||
ugexe | maybe its only feeding a \n instead of \r\n? | 03:11 | |
if thats supposed to be the entire thing, it needs to be \r\n\r\n | 03:12 | ||
03:12
cpage_ left
|
|||
hotel|chagrin | gist.github.com/HotelCalifornia/54...9c27530eca | 03:13 | |
ugexe | ah, yep | 03:14 | |
headers are separated from body by a double \r\n (\r\n\r\n) | |||
hotel|chagrin | oh | ||
cool | 03:15 | ||
ugexe | you are sending a single \n | ||
03:15
yqt left
|
|||
hotel|chagrin | did not know that | 03:15 | |
ugexe | many servers accept \n in place of \r\n i think though, so \n\n may work | ||
github.com/ugexe/Perl6-Grammar--HT...-grammar.t | |||
there are some valid example requests | |||
hotel|chagrin | I'm reading a tutorial and translating from python | 03:16 | |
the guy used a docstring for his response so I missed the second newline | |||
ugexe | you can also use that grammar via `say Grammar::HTTP.parse($http-request)` to see if its a valid request | 03:17 | |
and if its not, put a `use Grammar::Tracer;` above it and it'll show you exactly how it gets parsed and where the match failed | 03:18 | ||
hotel|chagrin | oh that's what that does | ||
03:18
hotel|chagrin is now known as hotel
03:24
cpage_ joined
03:26
grondilu left
03:27
cdg joined
03:28
BenGoldberg left
03:29
cognominal left,
BenGoldberg joined
|
|||
ZoffixWin | time TEST_JOBS=1000 make spectest | 03:31 | |
real 3m51.235s | |||
hotel | well, guess it's time for bed | 03:32 | |
03:32
hotel is now known as hotel|netteiru
|
|||
hotel|netteiru | night | 03:32 | |
ZoffixWin | Failures: gist.github.com/zoffixznet/8b630dc...adfe65565e | ||
night | |||
time TEST_JOBS=100 make spectest | 03:33 | ||
1m53.111s | |||
Failures: gist.github.com/zoffixznet/5ee59ff...dca01e6f75 | |||
03:33
dwarring left,
BenGoldberg left
03:35
BenGoldberg joined
03:39
huggable left
|
|||
ZoffixWin | :o | 03:39 | |
Fuck me.... Deleted the wrong Linode by mistake lol | 03:40 | ||
alcohol-- | |||
Oh well... free upgrade! | 03:41 | ||
03:41
cdg left
03:42
sno left,
sno joined
03:44
sno left,
sno joined
03:48
astj joined
03:49
ZoffixWin left
03:53
khw left
03:56
Actualeyes left,
BenGoldberg left
04:01
AlexDaniel left
04:07
aries_liuxueyang left
04:08
aries_liuxueyang joined
04:09
cdg joined
04:26
pierre_ left
04:32
jack_rabbit joined
04:47
cdg left
04:53
buharin joined
04:57
Cabanossi left
05:00
Cabanossi joined,
astj_ joined
05:02
cgfbee left
05:03
astj left,
zacts left
05:05
macsnowball left,
zacts joined
05:06
Actualeyes joined
05:13
astj joined
05:14
ufobat joined
05:17
astj_ left
|
|||
ufobat | morning :) | 05:18 | |
05:23
buharin left
|
|||
sortiz | \o ufobat | 05:23 | |
05:24
aries_liuxueyang left,
aries_liuxueyang joined
05:26
rurban joined,
pierre_ joined
|
|||
MadcapJake | trying to understand channels more and I am getting "Tried to read() on a socket from outside its originating thread" gist.github.com/MadcapJake/c29b76d...orkers-pl6 | 05:29 | |
05:29
nwc10 joined,
Actualeyes left
|
|||
nwc10 | they're going to need a bigger hanger. | 05:30 | |
05:31
pierre_ left
05:33
itcharlie left
05:36
buharin joined
05:45
buharin left
05:47
Actualeyes joined
06:01
rurban left
06:02
pierre_ joined
|
|||
nwc10 | twitter.com/elonmusk/status/728459808270000128 :-) | 06:02 | |
06:11
Ven joined
06:20
firstdayonthejob joined
06:25
CIAvash joined
06:32
wamba joined
|
|||
Ven | > Invalid GC status observed; aborting | 06:39 | |
06:39
firstdayonthejob left
|
|||
Ven | ^ anyone used GTK::Simple in the past 6 months observed something akin to that? | 06:40 | |
who* | |||
06:51
sjoshi joined,
jack_rabbit left
06:57
pierre_ left
07:00
sjoshi left
|
|||
masak | mornz, #perl6 | 07:00 | |
07:00
pierre_ joined
|
|||
masak | Ven: I got some segfaults recently when running on top of HTTP::Server::Tiny. but nothing GC-related | 07:01 | |
07:01
domidumont joined
07:04
abraxxa joined
07:05
domidumont left
07:06
domidumont joined
07:10
[particle] left
07:11
jack_rabbit joined,
[particle] joined
07:12
sjoshi joined
07:15
xxpor joined
07:17
domidumont left
07:18
maybekoo2 joined,
Relsak joined
07:21
jack_rabbit left
07:23
pierre_ left
07:31
pierre_ joined
07:47
rindolf joined,
g4 joined
07:55
domidumont joined
07:56
chansen__ joined
07:58
chansen__ is now known as chansen_
07:59
sno left
08:00
darutoko joined
08:01
sno joined
08:02
RabidGravy joined
08:04
jnap__ joined
08:06
tharkun left,
jnap__ is now known as jnap_
|
|||
tadzik | grondilu: I don't think it's necessary anymore; what happens if you don't? :) | 08:08 | |
08:11
Ven left
08:19
kurahaupo left
08:24
vendethiel left
|
|||
stmuk | ZoffixWin: submit a PR for github.com/stmuk/pl6anet.org/blob/...perlanetrc | 08:33 | |
08:34
tharkun joined
|
|||
stmuk | BTW your use of a comma rather than colon meant irssi didn't alert me there! | 08:34 | |
08:41
Emeric joined
|
|||
nadim | Morning all | 08:42 | |
moritz | \o | 08:47 | |
RabidGravy | ero | 08:51 | |
08:53
pierre_ left
|
|||
psch | o/ | 08:53 | |
m: role R { multi method foo(::?CLASS:U: ) { "foo" } }; class C does R { multi method foo(::?CLASS:D: ) { "bar" } }; say C.^can('foo').perl; say C.new.^can('foo').perl; | |||
camelia | rakudo-moar 780f07: OUTPUT«(method foo (::T $: | is raw) { #`(Method|75023040) ... },)(method foo (::T $: | is raw) { #`(Method|75023040) ... },)» | ||
psch | i kind of wish there were two elems in that method list | 08:54 | |
m: role R { multi method foo(::?CLASS:U: ) { "foo" } }; class C does R { multi method foo(::?CLASS:D: ) { "bar" } }; say C.foo; say C.new.foo | 08:55 | ||
camelia | rakudo-moar 780f07: OUTPUT«foobar» | ||
psch | it works, but i need do know if i already added the :D candidate, 'cause i'm doing that during BUILD and only want to add when it's not around yet | ||
s/do/to/ | |||
m: role R { multi method foo(::?CLASS:U: ) { "foo" } }; class C does R { submethod BUILD { self.^add_multi_method('foo', my method (::?CLASS:D: ) { "bar" }) } }; say C.foo; say C.new.foo # ah, this is what i'm actually doing | 08:57 | ||
camelia | rakudo-moar 780f07: OUTPUT«fooCannot call foo(C: ); none of these signatures match: (C:U $: *%_) in block <unit> at /tmp/OD8LWVDckN line 1» | ||
psch | ...well, minus "the role is also applied during BUILD" :) | ||
09:01
Ven joined
09:05
pierre_ joined
|
|||
jnthn | psch: Wouldn't that add a multi method to the class (static) on every instantiation (dynmaic)? | 09:06 | |
psch | jnthn: well, yes. that's why i want to know how many candidates i already have, so i don't do that if it's been done with this specific Class + Role combination already | ||
jnthn | Also add_multi_method doesn't actually add it right away, it stores it up until compose time, to see if we end up with a proto | 09:07 | |
And doing such things at runtime will make the code need "no precompilation" | 09:08 | ||
To work out reliabily, at least. | |||
psch | hm, so i probably just stick with different names for the methods | ||
jnthn | If you want to find out about what candidates a given proto controls, though, there's .candidates | 09:09 | |
09:09
nwc10 left
|
|||
psch | ...i though i tried that and didn't get anything | 09:09 | |
maybe did it on the List from find_method i guess | |||
jnthn | find_method doesn't return a List...that's can | ||
psch | ...i'll finish my coffee :) | 09:10 | |
jnthn | ;-) | ||
Not through my first today yet :) | |||
09:11
john51 left
|
|||
psch | well, the scenario is that i have a class C, that during BUILD mixes in one of multiple roles. some of these roles supply methods that return C with a different role mixed in | 09:11 | |
09:12
john51 joined
|
|||
psch | well, actually BUILD adds the method, the role just knows which different role it has to be | 09:12 | |
and i had though "hey, maybe you can just reuse the method name for :U and :D so :U returns the role that have to be mixed in and :D returns the list of methods that return a C+{$thatrole}" | 09:13 | ||
'cause that'd be nice from a naming perspective :) | |||
09:13
wamba left
|
|||
psch | but yeah, i guess i'll just pull that into {$methodname}-roles and {$methodname}-methods | 09:14 | |
09:18
sno left
09:21
wamba joined
|
|||
RabidGravy | I'm having unhealthy thoughts about implementing something with POSIX message queues | 09:23 | |
09:28
pierre_ left,
pierre_ joined
|
|||
RabidGravy | actually I'm not sure it would work due to mq_notify requiring a struct one of who's members is a callback | 09:30 | |
09:31
CIAvash left
09:32
pierre_ left
09:35
cognominal joined
09:39
pierre_ joined
|
|||
sortiz | RabidGravy, Umm, I think that the SIGEV_SIGNAL case maybe work. The SIGEV_THREAD case requires MoarVM special support, thought. | 09:47 | |
09:53
domidumont left
09:54
wamba left
10:01
Actualeyes left
10:12
kaare_ joined
10:14
pierre_ left
10:19
Actualeyes joined
10:29
maybekoo2 left
|
|||
psch | m: my $async = -> @a { say @a; sleep 1; say @a }; my @b = ^5; start { $async(@b) }; sleep 0.5; @b = 5..10; sleep 2 # how do i get ^5 both times..? | 10:29 | |
camelia | rakudo-moar 780f07: OUTPUT«[0 1 2 3 4][5 6 7 8 9 10]» | 10:30 | |
psch | pointies don't default to 'is copy'? | ||
moritz | no | ||
psch | m: my $async = sub (@a) { say @a; sleep 1; say @a }; my @b = ^5; start { $async(@b) }; sleep 0.5; @b = 5..10; sleep 2 | ||
camelia | rakudo-moar 780f07: OUTPUT«[0 1 2 3 4][5 6 7 8 9 10]» | 10:31 | |
psch | m: my $async = sub (@a is copy) { say @a; sleep 1; say @a }; my @b = ^5; start { $async(@b) }; sleep 0.5; @b = 5..10; sleep 2 | ||
camelia | rakudo-moar 780f07: OUTPUT«[0 1 2 3 4][0 1 2 3 4]» | ||
psch | ...and @-s don't either, apparently | ||
10:32
boegel left
10:34
boegel joined
10:35
colomon joined
10:36
TEttinger left
10:46
wamba joined
10:49
sno joined
11:01
espadrine_ joined,
espadrine_ is now known as espadrine
|
|||
masak | psch: a thing *is* copied in the above code. it's just not the thing you expect. | 11:08 | |
m: sub foo(@a) { say(@a); bar(); say(@a) }; my @x = 1, 2, 3; sub bar { @x = 4, 5 }; foo() | 11:09 | ||
camelia | rakudo-moar 780f07: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Qh_U7BspgFCalling foo() will never work with declared signature (@a)at /tmp/Qh_U7BspgF:1------> 3my @x = 1, 2, 3; sub bar { @x = 4, 5 }; 7⏏5foo()» | ||
masak | m: sub foo(@a) { say(@a); bar(); say(@a) }; my @x = 1, 2, 3; sub bar { @x = 4, 5 }; foo(@x) | ||
camelia | rakudo-moar 780f07: OUTPUT«[1 2 3][4 5]» | ||
psch | moritz: well, yes. the array is copied, which copies "which container does @a[0] point to" | ||
masak | ^ simpler example, without threads | ||
psch: I'm over here | |||
psch | masak: whoops, sorry :/ | ||
masak | no, the array *reference* is copied | ||
which isn't intuitive, but it's consistent | |||
psch purposefully avoided the word "reference" | |||
instance probably? | |||
masak | you don't get two arrays, you get two references to the same array | ||
psch | anyway, yeah, i get it :) | 11:10 | |
masak | I wouldn't avoid the word "reference" here, since it's key to understanding what's going on :P | ||
11:10
wamba left
|
|||
psch | masak: well, i don't like using it 'cause it's pragmatically overloaded from Perl 5 | 11:11 | |
masak | fairy nuff | ||
psch | as in, "list of arrayrefs" for ([1,2], [3,4]) | ||
masak | that's the same meaning in Perl 6 in my mind, fwiw | ||
11:12
nchambers is now known as sillytime
|
|||
psch | then i probably have my own, weird, pragmatic for "arrayref" which means something more Perl 5-specific | 11:12 | |
masak | you should look into that :P | 11:13 | |
psch | m: sub f($x, @a is copy) { say $x; say @a }; my @c = ^5; my &g = &f.assuming(*, @c); g(1); @c = 5..^10; g(1) | ||
camelia | rakudo-moar e3ded7: OUTPUT«1[0 1 2 3 4]1[5 6 7 8 9]» | ||
psch | that's closer to my actual problem, fwiw. taking the thready bits with me was not necessary... | 11:14 | |
not sure i can close over @c there | |||
m: sub f($x, @a is copy) { say $x; say @a }; my @c = ^5; my &g = &f.assuming(*, my @ = @c); g(1); @c = 5..^10; g(1) | |||
camelia | rakudo-moar e3ded7: OUTPUT«1[0 1 2 3 4]1[0 1 2 3 4]» | ||
psch | actually yeah nvm | ||
11:14
wamba joined
|
|||
psch | hm, curiously that doesn't actually work in my actual code :/ | 11:16 | |
masak | I've come to the reluctant conclusion that the only actual solution to reference/aliasing/ownership problems (besides going 100% immutable) is what Rust is doing | ||
moritz | how well does it work in Rust? | 11:17 | |
from what I've heard, it seems to place a very heavy burden on the type system | |||
masak | it does force you to think about borrowing/ownership in about the same way as any strict type system forces you to think about return types and parameter types | 11:18 | |
11:18
boegel left
|
|||
masak | beyond that, I'm not sure. ENEEDMORERUSTEXPERIENCE | 11:18 | |
awwaiid | How about selective-immutable, OCaml style? | ||
masak | awwaiid: where can I read more about that? | 11:19 | |
11:19
boegel joined
|
|||
masak | awwaiid: all I know is that in Perl 6, we don't do a good enough job of tracking immutability. | 11:19 | |
moritz: probably github.com/servo/servo is a great showcase of a "real-world" project using borrowing in actual situations | 11:20 | ||
awwaiid | I might have made it sound more like a thing than it is -- basically in OCaml things are immutable by default and you go out of your way to use refs. So it is common to use Okaski's purely functional data structure (www.amazon.com/Purely-Functional-St...521663504) | ||
masak: OCaml itself is written in OCaml, might be interesting to do a read through their code | 11:21 | ||
masak | aha. | ||
well, I'd file that under "going 100% immutable", in a way | |||
and refs are basically a mechanism for you to opt out of the immutability | |||
I would say such a solution is not an option for Perl 6, because it'd change the core nature of the language too much | 11:22 | ||
psch | gist.github.com/peschwa/f60774251b...7ffd7265f7 # the first call to .riff inside the start in L19 has the original @chords, the second has the new one | ||
awwaiid | hm. yeah -- even their built-in hash is immutable | ||
11:23
kid51 joined
|
|||
awwaiid | psch: what does "@inner-chords[$++ % *]" mean? | 11:23 | |
masak | awwaiid: "modulo length of array" | 11:24 | |
awwaiid | I mean ... my guess is it is modding an incrementing thing | ||
masak | yes, an incrementing anon state variable | ||
moritz | $ is an anonymous state var | ||
so it's just giving an incrementing sequence | |||
psch | awwaiid: yeah, it's incrementing a state variable and modulos it the array length to not go out of bounds | ||
awwaiid | ah. so $++ is incrementing the anon state. gotchya | ||
thanks | |||
masak | m: my @things = <a b c>; for ^10 { @things[$++ % *] = $++ }; say @things | 11:25 | |
camelia | rakudo-moar e3ded7: OUTPUT«[9 7 8]» | ||
11:25
grondilu joined
|
|||
moritz | : my @things = <a b c>; say @things[$++ % *] for ^10 | 11:26 | |
m: my @things = <a b c>; say @things[$++ % *] for ^10 | |||
camelia | rakudo-moar e3ded7: OUTPUT«abcabcabca» | ||
masak | m: my @things = <a b c>; say @things[$++ % *] and @things[$++ % *] = "bacon" for ^10 | 11:27 | |
camelia | rakudo-moar e3ded7: OUTPUT«abcbaconbaconbaconbaconbaconbaconbacon» | ||
awwaiid | yeah. Makes sense. Kinda dense, but now that I'm looking at it I guess the line above it is for debugging/watching, so this would maybe normally be a one-liner | 11:31 | |
11:33
Ven left
11:34
Ven joined
11:38
finanalyst joined
11:49
vendethiel joined
11:50
kurahaupo joined
11:53
kid51 left
|
|||
psch | oh, i see my error in the gist, actually | 11:54 | |
the .assuming is ran repeatedly | |||
jdv79 | assumptions are dangerous | 11:58 | |
11:59
sillytime is now known as nchambers
12:00
[Sno] joined
12:03
sno left
12:05
finanalyst left
12:06
rindolf left
12:07
wamba left,
[Sno] left
12:10
sno joined
12:15
abraxxa left,
ZoffixWin joined,
ZoffixWin left,
ZoffixWin joined
12:16
rindolf joined
|
|||
sortiz wondering why people use @foo almost only for Array and %foo only for Hash. Fear of immutability? Perl5 habit? | 12:17 | ||
ZoffixWin | Oh man. Waking up, reading logs and seeing this: irclog.perlgeek.de/perl6/2016-05-06#i_12441561 | ||
ZoffixWin feels sorry for AlexDaniel spending time teaching huggable all the tricks | |||
sortiz, what else do you use them for? | 12:18 | ||
moritz | m: say Match ~~ Associative | ||
camelia | rakudo-moar d9803a: OUTPUT«False» | ||
moritz | I guess you could use them for Set as well | 12:19 | |
and @ for Blob/Buf | |||
sortiz | ZoffixWin, my @foo is Array by default, but any Positional can be used, and the same for my %foo, where the default is Hash, but any Associative is valid. | 12:20 | |
moritz | doc.perl6.org/type/Positional the type graph shows some arrows twice | ||
like NFKC => Uni | |||
oh, probably because they appear twice in type-graph.txt | 12:21 | ||
ZoffixWin | sortiz, oh. I guess Perl 5 habit then :P I didn't know they could do that | ||
dalek | osystem: 5ed988f | titsuki++ | META.list: Add App::AizuOnlineJudge to ecosystem See github.com/titsuki/p6-App-AizuOnlineJudge |
||
osystem: 68a991f | titsuki++ | META.list: Merge pull request #203 from titsuki/add-aoj Add App::AizuOnlineJudge to ecosystem |
|||
c: 413a693 | moritz++ | type-graph.txt: Remove double defintion of Uni and related types |
|||
12:21
domidumont joined,
cdg joined
|
|||
grondilu | I'm trying to use panda on windows and it fails installing a package. Error seems to point at a lack of "prove" on my system. I thought it was shipped in since it must have used it to install whatever aleaday is install, musn't it? | 12:22 | |
already is installed | 12:23 | ||
moritz | grondilu: how did you install panda? | ||
grondilu | I got it from rakudo* | ||
(I suppose) | |||
moritz | grondilu: from the MSI? | ||
grondilu | yes | ||
moritz | grondilu: then it might not even have run prove on installation | ||
grondilu | though I did try to install rakudo (not star) previously | 12:24 | |
so maybe there are remnants or something | |||
moritz | do you have p5's prove installed? | ||
stmuk | grondilu: the windows panda doesn't work without --notest see www.perl6.org/downloads/ errata | ||
grondilu | ok | ||
confirmed. Works with --notests | 12:26 | ||
sortiz | m: my @l is List.new: |<a b c d e>; my @b is Buf; @b.push(|(1..10)); dd @l,@b; # For example ZoffixWin | 12:27 | |
camelia | rakudo-moar d9803a: OUTPUT«()Buf.new(1,2,3,4,5,6,7,8,9,10)» | ||
stmuk | panda doesn't call prove correctly on Windows even when prove is installed .. zef is recommended | ||
grondilu never used zef | 12:28 | ||
stmuk | also see blogs.perl.org/users/itcharlie/2016...e-zef.html | 12:29 | |
ZoffixWin | sortiz, but what's the point of using @ in there? | ||
moritz, do you have easy access to this channel's IRC logs that you could zip up everything from November to today and give it to me? If I grep them for commands to huggable and then replay those to the new instances, I should be able to restore its database. | 12:31 | ||
sortiz | Mark them as Positional or Associative. Ie capables of subscripting. | ||
ufobat | ZoffixWin, i'd try to look into this this afternoon. | 12:32 | |
moritz | ZoffixWin: I can try come up with something | 12:33 | |
ufobat | ZoffixWin, have you tried something like "say $app.renderer.perl"? | ||
ZoffixWin | ufobat, no rush. I accidentally destroyed my server last night so I'll be a bit busy :P | ||
ufobat | oh sh... :( | ||
sortiz | ZoffixWin, Otherwise, why use different sigils in the first place? | ||
ZoffixWin | m: my $l = List.new: |<a b c d e>; say $l[2..3] | 12:34 | |
camelia | rakudo-moar d9803a: OUTPUT«(c d)» | ||
ZoffixWin | sortiz, to get the default hash/array stuff. To me, sigils feel a bit misdesigned in Perl 6. Maybe I don't get what their purpose is | ||
sortiz, the $l above has subscribting capabilities, so I'm unsure what benefit there is in using a @l | 12:35 | ||
sortiz | m: my @l := <a b c>; .say for @l; my $l = <f g h>; .say for $l; | 12:36 | |
camelia | rakudo-moar d9803a: OUTPUT«abc(f g h)» | ||
psch | m: sub f(+@a) { say @a.perl }; my @a = <a b c d e>; my $l = List.new: |<a b c d e>; f @a; say f $l | 12:37 | |
camelia | rakudo-moar d9803a: OUTPUT«["a", "b", "c", "d", "e"][("a", "b", "c", "d", "e"),]True» | ||
psch | -spurious say | ||
that's what's underlying sortiz++ example | |||
moritz | ZoffixWin: select ilbot_lines.line FROM ilbot_lines JOIN ilbot_day ON ilbot_day.channel = 38 WHERE ilbot_day.day >= '2015-11-01' AND ilbot_lines.line LIKE '%huggable' ORDER BY ilbot_lines.timestamp; | ||
ZoffixWin: does that look workable to you? or do you need more info? | |||
like, nickname, timestamp, whatever? | |||
ZoffixWin | moritz, looks good. | 12:38 | |
sortiz, why did you use := instead of normal =? | |||
12:38
MilkmanDan joined,
andreoss joined
|
|||
andreoss | m: "".ord.chr.say | 12:39 | |
camelia | rakudo-moar d9803a: OUTPUT«» | ||
moritz | ZoffixWin: moritz.faui2k3.org/tmp/huggable.txt.gz I hope that helps | 12:40 | |
sortiz | m: my @a = <a b c>; my @l := <a b c>; say @a.WHAT,@l.WHAT; | ||
camelia | rakudo-moar d9803a: OUTPUT«(Array)(List)» | ||
lizmat | m: "".ord.say | ||
camelia | rakudo-moar d9803a: OUTPUT«Nil» | ||
andreoss | for me it gives warning `Use of nil in a numeric context` | ||
should it? | |||
sortiz | ZoffixWin, ^^^ | ||
lizmat | m: Nli.chr | ||
camelia | rakudo-moar d9803a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/JXsA3HLtxrUndeclared name: Nli used at line 1. Did you mean 'Nil'?» | ||
moritz | .uni Q | 12:41 | |
lizmat | m: Nil.chr | ||
camelia | rakudo-moar d9803a: OUTPUT«Use of Nil in numeric context in block <unit> at /tmp/rs7mKswII4 line 1» | ||
12:41
Skarsnik joined
|
|||
ZoffixWin | moritz, that looks weird :P | 12:41 | |
moritz | ZoffixWin: agreed | ||
lizmat | andreoss: I think the warning is correct | ||
andreoss | m: "".ord.chr.say | ||
camelia | rakudo-moar d9803a: OUTPUT«» | ||
ZoffixWin | moritz, should that be LIKE '%huggable%' ? | ||
lizmat | "".ord returns Nil, Nil.chr attempts to use Nil as a number | ||
moritz | ZoffixWin: ah, yes | ||
andreoss | lizmat: what happens with ^Q inside the quotes? | 12:42 | |
ZoffixWin | sortiz, thanks | ||
lizmat | andreoss: ^Q ? | ||
moritz | ZoffixWin: will re-hug :-) | ||
my mysql instance is just super slow :/ | 12:43 | ||
andreoss | m: "".chars.say | ||
camelia | rakudo-moar d9803a: OUTPUT«5» | ||
ZoffixWin | m: "".uninames.say | 12:44 | |
camelia | rakudo-moar d9803a: OUTPUT«(DEVICE CONTROL ONE DEVICE CONTROL ONE DEVICE CONTROL ONE DEVICE CONTROL ONE DEVICE CONTROL ONE)» | ||
moritz | oh, forgot a JOIN condition | ||
ZoffixWin: please re-download from the same URL | 12:45 | ||
andreoss | m: say elems qw[ ] | ||
camelia | rakudo-moar d9803a: OUTPUT«3» | ||
ZoffixWin | moritz++ got it. Thanks a lot! | 12:46 | |
andreoss | m: say (qw[ ])».ord.chr.say | ||
camelia | rakudo-moar d9803a: OUTPUT«True» | ||
andreoss | m: say (qw[ ])».ord.chr.join.say | ||
camelia | rakudo-moar d9803a: OUTPUT«True» | ||
andreoss | m: say (qw[ ])».ord | 12:47 | |
camelia | rakudo-moar d9803a: OUTPUT«(17 17 17)» | ||
andreoss | m: say (qw[ ])».ord».chr.join | ||
camelia | rakudo-moar d9803a: OUTPUT«» | ||
andreoss | some warnings are suppressed for camelia? | 12:50 | |
jnthn | m: say (qw[Q Q Q]).ords».chr.join | ||
camelia | rakudo-moar d9803a: OUTPUT«Q Q Q» | ||
jnthn | Ah, qw | 12:51 | |
But on a string I suggest .ords rather than .comb>>.ord | |||
moritz | andreoss: no, camelia doesn't suppress anything | 12:52 | |
12:54
[Coke] left,
rindolf left
12:55
[Coke] joined,
wamba joined
12:58
Sgeo left
13:02
itaipu joined
|
|||
andreoss | seems that Linenoise ignores literal symbols | 13:03 | |
i.e and so on | 13:04 | ||
sortiz | Yep, Linenoise have serious problems with Unicode | ||
13:05
rindolf joined
|
|||
andreoss | is control symbol from ASCII | 13:05 | |
moritz | ASCII is a subset of Unicode :-) | 13:06 | |
andreoss | of UTF-8 rather | ||
moritz | ASCII is both an encoding and a character repertoire | 13:07 | |
13:07
itaipu left
|
|||
moritz | in the latter role, it's a subset of Unicode | 13:07 | |
in the former role, of UTF-8 | |||
13:08
itaipu joined
13:16
cdg left
13:17
cdg joined
13:18
hotel joined
|
|||
masak | moritz: wow, I had never thought of that. | 13:18 | |
so ASCII numbers are *both* characters and codepoints, sort of? | |||
moritz | masak: aye | 13:19 | |
13:20
sufrostico joined
|
|||
masak | life was simpler back then | 13:21 | |
perlpilot | but then we had to grow up | ||
masak | speak for yerself | ||
:P | |||
hotel | Hey ZoffixWin, they're tearing apart the bug i reported :( | ||
tadzik | I'm still mildly amused when people treat me as a responsible grownup | 13:22 | |
perlpilot | masak: that's almost the defining characteristic of growing up: things aren't as simple as they once were. | ||
13:24
itaipu left
|
|||
masak | perlpilot: I'm inclined to agree, provided I'm also allowed to point out that I really enjoy staying in touch with my inner child | 13:24 | |
ZoffixWin | hotel, what's the URL again? | 13:25 | |
hotel | rt.perl.org/Ticket/Display.html?id=128077 | 13:26 | |
I'm not smart enough to argue, lol | |||
ZoffixWin | hotel, I had tests and fixes for it last night, but I got too wasted before I committed anything | ||
hotel | Haha | ||
Well, time for school. Bbl | |||
13:27
hotel left,
grondilu left
13:28
itaipu joined
13:31
kaare__ joined,
kaare_ left
13:33
itaipu left,
wamba left
|
|||
perlpilot | masak: sure! Inner children are awesome! Let them out as often as you can. :) | 13:33 | |
13:33
kaare_ joined
|
|||
timotimo | but if you let them out, are they still "inner"? | 13:33 | |
13:33
domidumont left
13:34
perlawhirl joined
|
|||
masak | Children/InsideOut.pm | 13:36 | |
13:37
kaare__ left
13:39
itaipu joined,
g4 left
13:40
AlexDaniel joined
13:41
wamba joined
13:43
kaare_ left,
kaare__ joined
13:47
pierre_ joined
13:48
zakharyas joined
13:51
prammer joined
|
|||
dalek | href="https://modules.perl6.org:">modules.perl6.org: 861d999 | (Richard Hainsworth)++ | templates/root/index.html.ep: Update index.html.ep Add href to Citations Index page. |
13:51 | |
href="https://modules.perl6.org:">modules.perl6.org: 6714309 | (Zoffix Znet)++ | templates/root/index.html.ep: Merge pull request #59 from finanalyst/master Add link in Modules page template to Citations Index page. |
|||
ZoffixWin | Any word on the merging of github.com/rakudo/rakudo/pull/743 ? | 13:53 | |
I stupidly made it on `nom` branch and now it's kinda annoying to when I try to clone the repo again. | 13:54 | ||
I guess it's learning time to figure how to work around that \o/ | 13:55 | ||
It depends on this merge to roast: github.com/perl6/roast/pull/113 | 13:56 | ||
13:58
perlpilot left,
perlpilot_ left
14:00
perlpilot joined,
smls joined
|
|||
Ulti | lizmat I notice you are replacing a lot of if/else with conditionals under the commit "streamline" is this actually a performance improvement? | 14:06 | |
masak | conditionals -- as in ?? !!, yes? | ||
Ulti | yup | ||
ternary operators | 14:07 | ||
:P | |||
timotimo | yes, it is. it's a guaranteed "doesn't have curlies" | ||
Ulti | is that not something spesh can capture that there is a conditional with only assignment and optimize away the difference? | 14:08 | |
14:08
kaare__ is now known as kaare_
|
|||
timotimo | it's something the static optimizer should do, but it doesn't always do it yet | 14:08 | |
Ulti | by curlies is that producing a closure every time even for control flow? | 14:09 | |
timotimo | not necessarily | ||
14:09
finanalyst joined
|
|||
timotimo | it can definitely cause lexical variables to stay lexical rather than be lowered to locals | 14:10 | |
masak | I definitely like that we're reaping these short-term performance wins in the setting | ||
timotimo | if you're interested, you can look at the exact code we generate from those things with the spesh log | ||
masak | but sometimes I feel like we should keep a list of "code-degrading optimizations" we're making, so that in the future we can roll them back as the optimizer gets better at handling them | 14:11 | |
at least if we care about long-term setting niceness | |||
timotimo | anyway, ifs and curlies give us bigger code, which can push our simpler methods above the static inlining threshold | ||
that won't trigger too often, but when it does, it's quite good | 14:12 | ||
ugexe | MadcapJake: data from a handle in one thread cant be used in another thread | 14:14 | |
it might appear to work sometimes, but thats because its really using the same thread (even if you put start { } around it) | 14:15 | ||
Ulti | thanks for the explanation | ||
I'll remember that if I have some tight loops with that form of assignment | 14:16 | ||
ugexe | MadcapJake: github.com/MoarVM/MoarVM/issues/165 | ||
14:17
sjoshi left
|
|||
timotimo | alternatively, feel free to hack on the static optimizer :) | 14:17 | |
perlawhirl | Ulti: you did the perl6 commit for GlotIO, yeah? | ||
Ulti | yup | 14:18 | |
perlawhirl | can the container export RAKUDO_ERROR_COLOR=0, so that compiler errors disaply nicely | ||
right now they look like this: m===mSORRY!m===m | 14:19 | ||
Ulti | not sure but I can take a look | ||
a better plan is not default terminal errors :P | |||
all the graphical editors with erorr highlighting get that issue too | |||
perlawhirl | Well, for most terminal users it's a bonus, and doesn't cause issues if they don't use colours | ||
timotimo | why does the thing provide a tty if it can't do ansi colors? :P | ||
Ulti | could check for a tty and not use colours also | ||
perlawhirl | bet yeah, on by default seems an odd choice | ||
Ulti | but guess thats not portable | 14:20 | |
timotimo | it already does, doesn't it? | ||
Ulti | dont think so | ||
14:20
mr-foobar joined
|
|||
ZoffixWin | +1 on fixing GlotIO output to not include trash characters (whatever method used :P) | 14:21 | |
perlawhirl | i think default-off colours is the most sane way | ||
14:21
astj left
|
|||
literal | how do I succintly flatten the return values of zip()? basically I wanted to do something like for @foo Z @bar -> $k, $v { ... } | 14:21 | |
timotimo | huh, you are right | ||
teatime | lots of things check for tty to decide whether to do colors | ||
timotimo | but we do have "isatty" now, i think | ||
teatime | perlawhirl: so I'd have to alias perl6="perl6 --color=auto" ? | 14:22 | |
ah well, I already have like a dozen of those, so another won't hurt :) | |||
geekosaur | m: *IN.t.so.say | ||
camelia | rakudo-moar 7db7b4: OUTPUT«5===SORRY!5=== Error while compiling /tmp/rAd6s9RaLATwo terms in a rowat /tmp/rAd6s9RaLA:1------> 3*7⏏5IN.t.so.say expecting any of: infix infix stopper statement end statement modifier …» | ||
ZoffixWin | literal, isn't -> ($k, $v) { do the trick? | ||
geekosaur | whoops | ||
m: $*IN.t.so.say | |||
camelia | rakudo-moar 7db7b4: OUTPUT«False» | ||
literal | ZoffixWin: ooh, indeed, that works. Thanks | ||
perlawhirl | Ulti: not it's an ENV var... so i think somehow the contanier literally needs to 'export RAKUDO_ERROR_COLOR=0' when it's created | 14:24 | |
my words aren't working, but i think that made sense | |||
ahh, and i was responding to teatime, not Ulti | 14:26 | ||
14:26
pierre_ left
|
|||
teatime | oh wut | 14:27 | |
perlawhirl | not sure how you'd fix it in something like Atom... maybe if you export the env var it just werks? | 14:28 | |
ugexe | m: say Rakudo::Internals.NUMERIC-ENV-KEY("RAKUDO_ERROR_COLOR") | ||
camelia | rakudo-moar 7db7b4: OUTPUT«Nil» | ||
14:29
khw joined
|
|||
perlawhirl | if I may seque to another question, it seems NCurses does not like ANSI colors. is it known, or am i doing something wrong | 14:30 | |
teatime | umm, I don't understand the question | ||
perlawhirl | i was just trying to use Term::ANSIColor'd strings with NCurses, and it spat out junk | ||
teatime | oh. | ||
geekosaur | yes | 14:31 | |
perlawhirl | yes...? it has problems? | ||
geekosaur | ncurses has its own color management. it does not parse ANSI sequences, it *creates& them | ||
perlawhirl | oh... ok | ||
geekosaur | this is expected, it is not a bug, and trying to modify it so that it can un-ANSI just so it can re-ANSI would be frustrating and a source of bugs and unexpected behavior | ||
if you want ANSI color with ncurses, use the ncurses color mechanisms | 14:32 | ||
teatime | what is the default flavor of cream soda? the red one. | ||
perlawhirl | alright.. i'll check the source / ncurses docs | ||
geekosaur | teatime, primary flavor is vanilla, red *may* have cherry added but not as primary flavor | 14:33 | |
teatime | no, it's not cherry... I was thinking vanilla was probably the answer... vanilla isn't usually red, though, then? | 14:34 | |
geekosaur | naturally? it's dark brown | ||
but that's in fairly concentrated form; depending on the source, the more diluted form could well be reddish | 14:35 | ||
teatime | not actual vanilla. vanilla cream soda :) | ||
geekosaur | heh | ||
cream soda may be clear, brownish, or red/reddish | |||
Ulti | given things /win 2 | 14:37 | |
wah | 14:38 | ||
geekosaur | with "real" cream sodas this reflects amount of vanilla and possibly other flavorings, and the source of the vanilla. these days its all artificial x.x | ||
*it's | |||
Ulti | perlawhirl: yeah I get what it needs, Docker most config is done through the environment its the preferred way to do things | ||
perlawhirl | cool beans | 14:39 | |
geekosaur | oh, I should note that the curses color stuff looks overengineered. sadly, at the time when it was added, that was not actually overengineered; it reflected the actual limitations of terminals | 14:41 | |
14:41
grondilu joined
|
|||
geekosaur | things got a LOT simpler when terminals standardized on ANSI X3.64 | 14:41 | |
teatime | are you referring to 256-color mode and pallette setting | 14:42 | |
geekosaur | but that only happened when real physical terminals mostly went away | ||
teatime | rather than the 24-bit color escape codes | ||
geekosaur | COLOR_PAIR and such | ||
teatime | 'cause the 24-bit escapes aren't widely supproted | ||
geekosaur | you are not talking about the (n)curses level | 14:43 | |
which is what perlawhirl was asking about | |||
teatime | no, I am | ||
I am asking if you are referring to ncurses not using the 24-bit escapes | |||
geekosaur | I am referring to the curses API | 14:44 | |
teatime | nevermind. | ||
geekosaur | whether it knows about and can use the escapes depends on whether the terminal description (terminfo) describes them in a way that (n)curses can understand | ||
perlawhirl | hrm, i might just use Term::Screen via Inline | ||
geekosaur | ...and since that too dates from the days of physical terminals, its ability to express such things is limited (it's possible but a lot of work) | 14:45 | |
teatime | terminfo evolves, and is actually part of ncurses. | 14:46 | |
geekosaur | yes, I am aware of that | ||
Ulti | perlawhirl: github.com/prasmussen/glot-containers/pull/7 | 14:48 | |
that should do it I think | |||
unfortunately I can't test it since the deployment of glot.io is fairly epic | 14:49 | ||
14:49
itaipu left
|
|||
Ulti | since the Docker image needs to get rebuilt we might force a 2016.04 update too :) | 14:49 | |
perlawhirl | 5 repo's combine to make it... kinda like Ultron | ||
Ulti | yup | 14:50 | |
perlawhirl | 2016.04 bump is a good idea | ||
Ulti | had to go through three of them just to find the Dockerfile :'( | ||
14:50
Relsak left
|
|||
Ulti | another plan is to actually implement the colour codes being converted to coloured <span> tags :3 | 14:51 | |
14:51
molaf joined
|
|||
perlawhirl | pfft, they should made html understand ansi escape sequences in the first place :P | 14:54 | |
timotimo | yes | 14:55 | |
smls | Hm, the REPL fails to start up for me | ||
It prints "To exit type 'exit' or '^D'" and then hangs | |||
timotimo | are you inside a "panda look"? | 14:56 | |
smls | what's that? | ||
timotimo | it grabs a module for you and drops you in the module folder in a shell | 14:57 | |
smls | No, I'm in my home folder | ||
timotimo | it sadly doesn't unlock the repo, so if you start a perl repl it'll usually hang waiting for the repo to become unlocked | ||
awwaiid | you should be able to see that if you do `strace perl6` -- you'll see it blocking on a .lock file | 15:00 | |
if that is the case, that is | |||
So I see that "Bug #127190 for perl6: Perl 6 has 0 elements ( .hyper.grep )" is already filed -- is there any sort of work-around? | 15:02 | ||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=127190 | ||
awwaiid | m: say ^10 .race.grep: *.is-prime | 15:03 | |
camelia | rakudo-moar 7db7b4: OUTPUT«()» | ||
smls | m: .say for ^10 .race.map({ next if .is-prime; $_ }) | 15:05 | |
camelia | rakudo-moar 7db7b4: OUTPUT«014689» | ||
psch | m: ^10 .race.grep( *.say ); | ||
camelia | ( no output ) | ||
awwaiid | I'm working on a talk submission and was going to use that as an example :) | 15:06 | |
psch | whatever .grep does with whatever .race produces seems somewhat wrong... :) | ||
hoelzro wishes ack supported P6 regexes | |||
timotimo | awwaiid: no way at the moment, sorry :( | ||
awwaiid | ok cool | ||
timotimo | except if somebody goes in and fixes it, of course | ||
geekosaur | psch, I think that;s a known bug in race? | ||
psch | geekosaur: yeah, the tickets been linked a bit ago | 15:07 | |
awwaiid | there are a ridiculous number of other features that I can pick to highlight | ||
psch | geekosaur: i was just curious, which is why i put the *.say into the grep, to see what arrives there anyway | ||
timotimo | yeah, though of course parallelism features are extra juicy | ||
geekosaur | ob "you have a problem and you decide to use threads. nonw owy ou yoauv e hatwvo e ptrowbo plerombsle imns teinrtleearlveeda.ed." | 15:08 | |
ugexe | heh | 15:09 | |
timotimo | :) | ||
awwaiid | oh wait, if I put in a grpe it works | 15:10 | |
m: (^10).race.map(* + 0).grep(*.is-prime) | |||
camelia | ( no output ) | ||
awwaiid | m: (^10).race.map(* + 0).grep(*.is-prime).list.say | ||
camelia | rakudo-moar 7db7b4: OUTPUT«(2 3 5 7)» | ||
teatime | heh, how much code do you think will break when, at some point in the future, » etc. begin actually multi-threading :) | 15:11 | |
ugexe | something about map itemizing differently than grep such that hypers worked slightly different on each | ||
timotimo | teatime: for the longest time we've made the execution order of >> things randomized | ||
it no longer is randomized, if i recall correctly | |||
teatime | I was gonna say, ».say works for me when I do it | ||
timotimo | but since hyper still gives you the result order you wanted, it won't be that bad | 15:12 | |
only side-effects will be scrambled | |||
hoelzro | m: 'f3cd5fa' ~~ /<-:Letter - digit>/ | 15:15 | |
camelia | ( no output ) | ||
hoelzro | m: 'f3cd5fa' ~~ /<-:Letter - Digit>/ | ||
camelia | rakudo-moar 7db7b4: OUTPUT«Method 'Digit' not found for invocant of class 'Cursor' in block <unit> at /tmp/RW10TqzI9S line 1» | ||
hoelzro | why is titlecase ok for Letter, but not for Digit? | ||
timotimo | wouldn't you need to :Digit? | ||
because digit is also a method on Cursor? | |||
hoelzro | ahhh | ||
timotimo | whereas :Letter is a unicode property thing | ||
hoelzro | m: say '.' ~~ /<-:Letter - :Digit>/ | 15:16 | |
camelia | rakudo-moar 7db7b4: OUTPUT«Nil» | ||
teatime | dunno if relevant but <digit> also already pre-exists | ||
hoelzro | that *should* match, right? | ||
I'm trying to match any character that's neither a letter nor a digit | |||
teatime | no, . isn't in :Letter | ||
oh nm | |||
hoelzro | unless the leading - is complementing (:Letter - :Digit) | ||
...in which case it would still match, right? | 15:17 | ||
smls | timotimo: After nuking rakudobrew and rebuilding, my REPL works again. | 15:20 | |
timotimo | interesting. good to know, i guess | ||
awwaiid | hm | 15:22 | |
ZoffixWin | m: say '.' ~~ /<-[\w]+[_]>/ | 15:23 | |
camelia | rakudo-moar 7db7b4: OUTPUT«「.」» | ||
hoelzro | awwaiid: did you see my comment on your PR? | 15:24 | |
awwaiid | hoelzro: yes! But I haven't gotten a chance to fix it up yet. I missed .05 yet? | ||
hoelzro: think it would be ok to print out "Entering fallback REPL" if it does the fallback? I'm want us to know/debug any times it falls back | 15:25 | ||
15:25
tomboy65 joined
15:26
dolmen joined,
yqt joined
|
|||
hoelzro | awwaiid: .05 is a way's away =) | 15:27 | |
I think that's a good idea | |||
15:27
ufobat left
|
|||
hoelzro | something like "failed to load REPL.pm: $ERROR\nEntering fallback REPL" | 15:27 | |
15:27
tomboy64 left
|
|||
timotimo | hoelzro: well, very big changes should go in loooong before the release, to be fair | 15:28 | |
hoelzro | timotimo: agreed | ||
I'm thinking of even waiting until .05 is out to merge, to maximize our window | 15:29 | ||
awwaiid | ok cool. I'll get the fallback back in there over the weekend. | 15:33 | |
15:33
skids joined
15:36
Ven left
15:41
finanalyst left
15:46
Relsak joined
|
|||
awwaiid | Request for review/edits/suggestions on my Strange Loop talk submission -- gist.github.com/awwaiid/6d9c996557...943fde504c | 15:49 | |
15:50
domidumont joined
|
|||
perlpilot | awwaiid++ | 15:51 | |
awwaiid: experimention -> experimentation | 15:52 | ||
15:54
ZoffixWin left
|
|||
awwaiid | oh right, spelling | 15:54 | |
perlpilot: updated | 15:55 | ||
perlpilot | awwaiid: How long is the talk? This is a session or a workshop? | 15:56 | |
hoelzro | awwaiid: sounds good (both the weekend work and SL talk idea) | ||
smls | awwaiid: Aren't the concurrency primitives taken from (or heavily inspired by) C#/.NET, as opposed to complete innovations? | 15:57 | |
awwaiid | perlpilot: I'm putting in for a 40 minute talk. I could do a workshop, but felt like this is more likely to get accepted. | ||
perlpilot | awwaiid: So, is it going to be more of a survey of neat Perl 6 things or are you just going to focus on a few and mention that there are other neat things available? | 15:58 | |
awwaiid | smls: don't know! I think the innovation is more about how they are integrated in. start {} I think is c#, but .race.map looks more like clojure core.async (standard libs that have the same rough api but work on an async/concurrent datatype) | ||
perlpilot: I'm leaving it open for myself, but I think the best use of time would be to do a deeper-dive into like 2 nonstandard features and a survey/bief-mention of some others. | 15:59 | ||
15:59
dolmen left
|
|||
perlpilot | awwaiid: Sounds excellent! | 15:59 | |
awwaiid | I think I'll make that clear on the thing | 16:00 | |
perlpilot | awwaiid++ | ||
I also like how you say "the production-ready Rakudo implementation of Perl 6". The more we talk about the production-readiness, the better | 16:02 | ||
awwaiid | Yeah. That also let me talk about the back-ends | 16:03 | |
gist updated with a note about deep-dive into 2 advanced/nonstandard topics | |||
smls | [Coke], masak, other RT veterans: It looks like we have a large number of open tickets that were automatically submitted for roast test failures, about a year ago. Are they still needed? | 16:06 | |
(e.g. #124685) | |||
synopsebot6 | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=124685 | ||
RabidGravy | iirc it wasn't just failures but all the fudges | 16:16 | |
smls | What was the idea behint RT'ing them all? | 16:21 | |
Isn't it more useful for implementors to run roast themselves and check the *current* failures/fudges? | 16:22 | ||
RabidGravy | yeah, you'd have thought so | ||
psch | smls: that's not always really feasible. r-j spectest can take well over two hours, depending on machine and load | 16:23 | |
RabidGravy | if there is a big list of those tickets it might be worth grepping the roast for the numbers and just closing the ones that ain't there any more | ||
because I think the plan was that the tickets should be in the source | 16:24 | ||
16:24
samb1 joined
|
|||
smls | psch: But is anyone keeping the list up-to-date (i.e. closing no longer applicable ones)? | 16:24 | |
16:24
pnu_ left
16:26
pnu_ joined,
milwauke` joined,
prammer left
|
|||
awwaiid | "Your talk proposal was successfully submitted" . I'll let y'all know if it gets accepted and then everyone can come over :) | 16:26 | |
16:26
prammer joined
|
|||
psch | smls: well, i do usually comment on a ticket when i it, and usually our bug admins are attentive enough to react to that (when i don't forget to cc the mailing list...) | 16:27 | |
16:27
avalenn left
|
|||
psch | +fix | 16:27 | |
jnthn | smls: Certainly I closed a bunch of them when I dealt with the tests they were about in some way | ||
smls | ok | ||
16:28
avalenn joined,
apejens joined,
tharkun left
16:29
llfourn left
16:30
zakharyas left,
llfourn joined,
milwaukee left
16:31
Amnez777 left
16:32
kmwallio left
|
|||
smls | RabidGravy: It looks like it's 244 in total, that are still open | 16:32 | |
(search link here: gist.github.com/smls/eed26639e60f1...14856f41c) | 16:33 | ||
16:33
kmwallio joined
16:35
Amnez777 joined,
Emeric left,
tharkun joined
16:39
sufrostico left
16:43
gtodd1 left
16:44
cpage_ left
16:45
sufrostico joined
16:46
newbie1 joined
16:47
ZoffixWin joined
|
|||
ZoffixWin | How can I just pop up a bunch of supplies and tell my program to sit and chill (and just repond to those supplies whenever they happen)? I tried by just sticking this loop {} but I now see my app is using 100% of CPU: github.com/zoffixznet/perl6-Bailad...ilador#L16 | 16:47 | |
16:48
takadonet joined
|
|||
timotimo | you need "react" | 16:49 | |
16:50
yqt left
|
|||
ZoffixWin | I don't know how. The program exits right away | 16:50 | |
mst | isn't this what forever/whenever are for? | ||
timotimo | mst: whenever goes into a "supply" or "react" block to listen to other supplies doing stuff | 16:51 | |
ZoffixWin | hm. lemme try | ||
timotimo | yeah, you'd want to whenever your supplies inside the react block | 16:52 | |
jnthn | ZoffixWin: Something like this: gist.github.com/jnthn/b29e1628f21e...58c79a62af | ||
perlpilot isn't aware of a "forever" block, but that would be a nice self-documenting alternative to loop {} | 16:53 | ||
ZoffixWin | Thanks. jnthn++ timotimo++ mst++ | ||
16:56
itaipu joined
|
|||
mst | ah, right, so you use 'react' to say 'within this, we're setting up reactive stuff' then 'whenever' inside that uses the taps to do things, and the reason zoffix' stuff was exiting was he hadn't added any listeners? | 16:59 | |
timotimo | that sounds like the thing, yeah | ||
an empty react block would immediately shut down, i expect | |||
m: react { }; say "done" | |||
camelia | rakudo-moar ac36d2: OUTPUT«done» | ||
mst | oh damnation, I just helped somebody implement one of those horrible auto restarter things | 17:00 | |
mst feels dirty now | |||
timotimo | hah | ||
ZoffixWin | hahahahaaa | ||
mst, why is it horrible? | |||
Manually restarting is horrible | |||
mst | Ctrl-C, up, enter doesn't bother me | 17:01 | |
ZoffixWin | On EVERY change? | ||
mst | having my console log full of errors that are all complete lies so it obscures the real ones does bother me | ||
tadzik | haha, oh yes | ||
"why doesn't it work? Oh,because this time it failed to recompile so nothing changed" | 17:02 | ||
mst | more "what's wrong now? oh, my app server screen is fully of errors, is that a real problem or just a failed recompile from three minutes ago when I saved the first file out of three I needed to change for this to compile again?" | ||
I usually end up turning it off before I get as far as hitting tadzik's failure mode, but 'cold start the app please' is one of the standard ways I've found for letting junior devs discover they just wasted an hour | 17:03 | ||
17:03
perlawhirl left
17:04
firstdayonthejob joined
|
|||
mst | of course, newbies *still* think it's a good idea and it makes them happy so I'd much prefer the feature existed so long as nobody mind me turning it off as hard as possible the first time I run into it :D | 17:04 | |
ZoffixWin | No, I always know if it's a real problem because on each restart my restarter issues a message so all I need to follow is from end to the first restart message. | 17:05 | |
17:05
itaipu left
|
|||
ZoffixWin | And the error really should be chucked into the browser... | 17:05 | |
17:06
espadrine left,
tharkun left,
tharkun joined,
itaipu joined
|
|||
tadzik | ahaha | 17:07 | |
smls | m: say "abbbbb" ~~ /a b+/ | ||
camelia | rakudo-moar ac36d2: OUTPUT«Potential difficulties: Space is not significant here; please use quotes or :s (:sigspace) modifier (or, to suppress this warning, omit the space, or otherwise change the spacing) at /tmp/pdoXjL8i5l:1 ------> 3say "abbbbb" ~~ /a7⏏5 b…» | ||
smls | ^^ Isn't that warning a little overzealous? | 17:08 | |
ZoffixWin | Probably here: github.com/ufobat/Bailador/blob/ma...pp.pm#L115 Just pop the exception into the the message | ||
timotimo | smls: it can really help in real life circumstances | ||
i've been saved by it at least twice so far | |||
ZoffixWin | smls, IMO yes, but I'm of the minority opinion :) It doesn't *always* happen. There's only some sequence of tokens that trigger it. | 17:09 | |
smls | I'd consider putting a space there, good practive/style | ||
a little weird to have the compiler advise me to do the opposite... :P | |||
ZoffixWin | smls, right, but the way to write that is / 'a' 'b'+ / | ||
smls | That's *too* verbose for my taste... | 17:10 | |
ZoffixWin | m: say "abbbbb" ~~ m:Perl5:x/a b+/ | 17:11 | |
camelia | rakudo-moar ac36d2: OUTPUT«(「abbbbb」)» | ||
timotimo | m: say "abbbbb" ~~ m:/a 'b'+/ | ||
camelia | rakudo-moar ac36d2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/YhoQq6rq8dColons may not be used to delimit quoting constructsat /tmp/YhoQq6rq8d:1------> 3say "abbbbb" ~~ m:7⏏5/a 'b'+/ expecting any of: colon pair (restricted)» | ||
timotimo | m: say "abbbbb" ~~ m/a 'b'+/ | ||
camelia | rakudo-moar ac36d2: OUTPUT«「abbbbb」» | ||
ugexe | use all the modifiers | 17:12 | |
timotimo | m: say "abbbbb" ~~ m/'a' b+/ | ||
camelia | rakudo-moar ac36d2: OUTPUT«「abbbbb」» | ||
perlpilot wonders when that :Perl5 regex modifier will become problematic (similar to how PCRE on #perl is problematic) | |||
ZoffixWin | it doesn't support character classes. That's one problem I encountered | 17:13 | |
*named character classes [[:punct:]] and stuff like that | |||
timotimo | yeah, we didn't build it too far yet | ||
perlpilot | "best" might be to just use Inline::Perl5 for it now | 17:14 | |
timotimo | yah | ||
smls | timotimo: Isn't the version without space *more* likely to trip up people? i.e. a newbie looking at /foo+/ might think it repeats the whole word. | 17:16 | |
17:16
itaipu left
|
|||
timotimo | huh. not sure | 17:16 | |
mst | perlpilot: eh, you can always bounce people over to us :) | ||
17:17
itaipu joined,
cdg left
|
|||
AlexDaniel | m: say ‘abbbbb’ ~~ /‘a’ b+/ | 17:17 | |
camelia | rakudo-moar ac36d2: OUTPUT«「abbbbb」» | ||
geekosaur | the real fun will be when people confuse m:p5 with pcre >.> | 17:18 | |
AlexDaniel | say ‘abbbbb’ ~~ m+‘a’ b\++ | ||
m: say ‘abbbbb’ ~~ m+‘a’ b\++ | |||
camelia | rakudo-moar ac36d2: OUTPUT«False» | ||
ZoffixWin | m: say ‘abbbbb’ ~~ m+‘a’ b++ | 17:19 | |
camelia | rakudo-moar ac36d2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/VpQJqR_SQFMissing required term after infixat /tmp/VpQJqR_SQF:1------> 3say ‘abbbbb’ ~~ m+‘a’ b++7⏏5<EOL> expecting any of: prefix term» | ||
timotimo | oh btw, it wouldn't be terribly hard to implement a m:PCRE :) | 17:20 | |
AlexDaniel | m: say ‘abbbbb’ ~~ m+‘a’ b++ | ||
camelia | rakudo-moar ac36d2: OUTPUT«「abbbbb」» | ||
mst | timotimo: SET THE CONFUSATRON TO ELEVEN | ||
ZoffixWin | m: say ‘abbbbb’ ~~ /a b+/; | ||
camelia | rakudo-moar ac36d2: OUTPUT«5===SORRY!5===Unrecognized regex metacharacter (must be quoted to match literally)at /tmp/7R3zM6shSZ:1------> 3say ‘abbbbb’ ~~ /a7⏏5 b+/;Unable to parse regex; couldn't find final '/'at /tmp/7R3zM6shSZ:1------> 3say …» | ||
ZoffixWin | awwww | ||
timotimo | :) :) | ||
perlpilot | mst: Except currently you'll just be educating them on the fact that m:Perl5// is a bit of a lie. | 17:21 | |
(Or ... I'll be doing that :) | |||
17:21
ZoffixWin left
17:22
itaipu left
|
|||
MadcapJake | ugexe: thanks for the explanation and link! But I'm not really sure where I am accessing something outside of the thread. The only thing I could think of would be @collected (which I could actually put inside the last start block) | 17:24 | |
17:24
lichtkind_ left,
andreoss left,
cpage_ joined
|
|||
ugexe | MadcapJake: link? i didnt look at any code | 17:24 | |
17:24
newbie1 left
|
|||
MadcapJake | Otherwise maybe it's the channels I am passing as references to the workers, but without being able to do that, I am struggling to see the usefulness of channels | 17:24 | |
gist.github.com/MadcapJake/c29b76d...orkers-pl6 | |||
in debug, L16 (the $!chunks.poll call) is what sends the first "unable to read" error) | 17:26 | ||
Though it doesn't always fail there, for some odd reason. | 17:27 | ||
ugexe | if $!chunks contains anything from another thread, then thats where its finally read | ||
its not always failing there because sometimes it will happen in the same thread it originated in | |||
AlexDaniel | m: my $x = ‘’; for ^100000 { $x .= chop }; say ‘hello’ ~ $x ~ ‘world’ # awww, it works | 17:28 | |
camelia | rakudo-moar ac36d2: OUTPUT«helloworld» | ||
MadcapJake | Well $!chunks is created inside the class but not inside the start block (inside of submethod BUILD) | ||
17:29
itaipu joined,
sufrostico left
|
|||
ugexe | right, but what about anything $!chunks contains? if any of its elements were created in a different $*THREAD.id then that error happens | 17:29 | |
MadcapJake | yeah that's gotta be it then. so you can't communicate across channels? that seems really limiting | ||
what's send/receive/poll for if you can't do that? | 17:30 | ||
ugexe | yea its a pita, and a bug | ||
well you can communicate across channels, just not with data that originated from handles i believe | |||
17:30
wamba left
|
|||
MadcapJake | yeah it's pulled from a text file | 17:31 | |
AlexDaniel | m: ‘hello’.starts-with(‘’).say | ||
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
AlexDaniel | m: ‘hello’.ends-with(‘’).say | 17:32 | |
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
17:32
squirrel_ joined
17:33
squirrel_ left,
sufrostico joined
|
|||
ugexe | you pretty much have to roll your own ipc... socket client/server is one way | 17:34 | |
jnthn | It's the *handles* that can't be read on another thread | 17:35 | |
mst | moarvm needs to expose something approximately like p3rl.org/IO::Pipely I think | ||
or whatever the underlying libuv abstraction is | |||
jnthn | A Str or Buf can happily travel between threads. | ||
AlexDaniel wonders why Str.indent exists | |||
MadcapJake | jnthn: then what's going on because that's all I'm passing is strings | ||
mst | AlexDaniel: anti-leftpad insurance | ||
mst really wants access to libuv's unix domain socket / win32 named pipe abstraction | 17:36 | ||
ugexe | i dunno, i've never been able to get a buf from a socket on thread A to read on thread B | ||
AlexDaniel | mst: oh, well… OK, it makes sense. I guess | ||
MadcapJake | L38 calls lines on the handle and sends each line to a provider who rotates it between a series of workers | 17:37 | |
AlexDaniel | that's actually pretty smart | ||
mst | xkcd.com/1676/ # ARBITRARY LENGTH NON BREAKING SNAKE | 17:38 | |
timotimo | yes | 17:39 | |
mst | ISAGN | ||
17:39
hjst joined
|
|||
MadcapJake | timotimo: did you see the latest version of my shakespeare character counter? | 17:40 | |
AlexDaniel | m: ‘🐍🐍🐍🐍hello’.indent(-4) # snakes not supported | 17:41 | |
camelia | rakudo-moar ac36d2: OUTPUT«Asked to remove 4 spaces, but the shortest indent is 0 spaces in block <unit> at /tmp/IanqvZxiAO line 1» | ||
timotimo | MadcapJake: i have not. though i might write my own version later today, if you give me your source data :) | ||
MadcapJake | ocw.mit.edu/ans7870/6/6.006/s08/lec...speare.txt (5.3MB file) | 17:42 | |
timotimo | thanks | 17:43 | |
MadcapJake | I deleted the header and footer text too | ||
timotimo: my latest version was an attempt to follow your advice of rotating between workers, so I'd be interested to know if I implemented it how you envisioned (though it doesn't work due to some weird thread problem that I don't understand) | 17:44 | ||
[Coke] | smls: yes, because any todo or fudged test in roast needs a ticket. | ||
timotimo | oh | ||
[Coke] | (or to be removed) | ||
timotimo | oh, is that workers.pl? | 17:45 | |
MadcapJake | yeah | ||
[Coke] | (that said, the person who opened all those tickets did so on their own with only a little guidance. they've been greatly cleaned up since they were opened.) | 17:46 | |
timotimo | i don't know why you have a central start block that divides data from $provider into all the workers' chunks | ||
17:46
cpage joined
|
|||
timotimo | rather than having all workers .receive on the $provider | 17:47 | |
MadcapJake | timotimo: I know why I did that: cus I don't know how to do this :P | ||
timotimo | :D | ||
MadcapJake | I thought that I needed to send to each worker separately, I didn't know I could have them all listen to one channel and it would divy up the work automatically | 17:50 | |
[Coke] | (RT) if folks are looking to help work on the queue, I have a gist somewhere that would help. | 17:51 | |
17:51
zostay left,
cpage_ left
|
|||
[Coke] | gist.github.com/coke/ac078396e8f216b83e9a ... needs some work, I'll polish that slightly. | 17:52 | |
smls | [Coke]: I was just casually looking through old tickets... :P | 17:55 | |
17:55
zakharyas joined
|
|||
smls | For those that have been fixed, is leaving a comment and marking them "testneeded" still the best course of action? | 17:55 | |
[Coke] | yes. | 17:56 | |
smls | If it's just an LTA error, is it ok to mark it 'resolved' directly? (I did that today.) | ||
[Coke] | I mean, writing the test and closing out the ticket is best, but at least that, yes. | ||
I think that still needs a test, no. | 17:57 | ||
smls | ok | ||
[Coke] | we have to verify that the warning is, in fact, NLTA. | ||
thanks for going through tickets. | |||
Here's another thing: if there's no [TAG] in the subject, update the subject with one if there's an obvious existing one it should be. | |||
17:58
zostay joined
|
|||
[Coke] | gist.github.com/coke/9acb95ea87fab...3a2a6953ac | 17:59 | |
(there's all the current ones) | |||
18:01
dj_goku left,
dj_goku joined
|
|||
AlexDaniel | m: say ‘⋛’.uniname | 18:11 | |
camelia | rakudo-moar ac36d2: OUTPUT«GREATER-THAN EQUAL TO OR LESS-THAN» | ||
MadcapJake | lol why is there a symbol for that | 18:12 | |
AlexDaniel | MadcapJake: there's another one | ||
m: say ‘⋚’.uniname | |||
camelia | rakudo-moar ac36d2: OUTPUT«LESS-THAN EQUAL TO OR GREATER-THAN» | ||
timotimo | that just means "those two things are orderable somehow" | ||
perlpilot | and depending on which one you use ... shows your bias | 18:14 | |
18:18
takadonet left,
Joe_Perl joined
|
|||
Joe_Perl | Hello | 18:18 | |
timotimo | hey there | 18:19 | |
Joe_Perl | So i pretty much love perl6 but... | ||
AlexDaniel | m: .say for (0..0x1FFFF ==> grep { .uniname ~~ /MONKEY/ } ==> map {.chr.uniname}) | 18:20 | |
camelia | rakudo-moar ac36d2: OUTPUT«MONKEYMONKEY FACESEE-NO-EVIL MONKEYHEAR-NO-EVIL MONKEYSPEAK-NO-EVIL MONKEY» | ||
AlexDaniel | why so many monkeys? | ||
timotimo | Joe_Perl: uh-oh, here it comes :) | ||
Joe_Perl | Perl6 would be my first programming language i seriosly learn and i want to make sure that if i put my time into then for some reason decide i want to learn a new language I wont be totally messed up by Perl6. | 18:21 | |
Im just a hobiest but might transition into the IT field | 18:22 | ||
MadcapJake | the only thing Perl 6 will do is make you realize other languages aren't very powerful :) | ||
18:22
lostinfog joined
|
|||
timotimo | all languages are equally powerful as long as they can do what brainfuck can :P | 18:23 | |
Joe_Perl | I love Grammers they seem like a good compromise on Regex. | ||
AlexDaniel | compromise :o | 18:24 | |
MadcapJake | timotimo: powerful in terms of the programmer not the computer | ||
timotimo | heh heh | 18:25 | |
MadcapJake | Joe_Perl: Perl 6 grammars aren't a compromise on regex they are a tool that makes using regexes easier in some circumstances (where you need to parse things larger than one line) | 18:26 | |
AlexDaniel | m: say ‘abbbbb’ ~~ m/‘a’ b+/ # you can still do your regexy stuff | 18:27 | |
camelia | rakudo-moar ac36d2: OUTPUT«「abbbbb」» | ||
MadcapJake | grammars are to regexes what a general is to soldiers | ||
mst | wow, that's the worst metaphor I've seen in weeks | 18:28 | |
18:28
maybekoo2 joined
|
|||
MadcapJake | lol worst really? how is that so bad? let's see you come up with one :P | 18:29 | |
18:30
itaipu left
|
|||
MadcapJake | grammars organize regexes like a general organizes their soldiers, regexes capture text just like soldiers capture enemy combatants :) | 18:30 | |
perlpilot | MadcapJake: What are the lieutenants and sergeants in this metaphor? they're the one who actually talk to soldiers. :-) | 18:31 | |
18:31
itaipu joined
|
|||
MadcapJake | perlpilot: those are your tokens and rules! the actual regex literals are the soldiers :P | 18:31 | |
ugexe | but what about actions | ||
MadcapJake | orders | ||
perlpilot | ugexe: obviously they are the intelligence community | ||
18:31
cdg joined
|
|||
MadcapJake | hahaha | 18:31 | |
perlpilot | MadcapJake: Work at this a bit and it could become a really good lightning talk :) | 18:32 | |
18:32
zakharyas left
18:33
cdg left,
cdg joined
|
|||
perlpilot | "Text as the enemy" works fairly well in any case | 18:33 | |
18:34
ufobat joined
|
|||
MadcapJake | yeah it does! I think it's a pretty good metaphor! | 18:34 | |
AlexDaniel | well, if only it was part of military training | ||
perlpilot | speaking of training ... where's bootcamp in this metaphor? | ||
MadcapJake | Grammar::Debugger is bootcamp :) | 18:35 | |
perlpilot | and what branch of the service are these soldiers in? Air Force? Marines? Navy? Army? | ||
mst | nah, bootcamp is for infantry | ||
perlpilot | Coast Guard? | ||
18:35
itaipu left
|
|||
mst | bootcamp is an interactive grep tutorial | 18:35 | |
Joe_Perl | At what scale (page traffic, database size etc.) would you need to worry about any speed deficits in perl6? | ||
MadcapJake | lol yes! | ||
mst | Grammar::Debugger is either officer training school, or more likely 'high command's post mortem team' | ||
MadcapJake | lol | ||
perlpilot | Joe_Perl: The question is a tad vague. | 18:36 | |
MadcapJake | I'd say this is either Army or Coast Guard (two branches most likely to be capturing rather than just pummeling :) | ||
perlpilot | Then what are the Army Rangers? | 18:37 | |
MadcapJake | unicode properties :) | 18:38 | |
perlpilot | MadcapJake: you're certainly starting to live up to your nick ;) | ||
MadcapJake | hahaha it actually was a nickname I had at work a few years back :) | 18:39 | |
18:42
itaipu joined
|
|||
Joe_Perl | I suppose what i have in my head is the story that " Twitter had to switch to scala because Ruby was too slow at scale" Im not saying im going to have a company that big its just a theoretical question. | 18:42 | |
mst | Joe_Perl: yeah, and twitter would never have got that far if they hadn't used ruby first for fast prototyping | 18:43 | |
ugexe | that same story holds true for how many companies? | ||
mst | Joe_Perl: you're learning exactly the opposite lesson to the truth here | ||
Joe_Perl | Im willing to learn | ||
mst | I just explained the point. what wasn't clear? | ||
Joe_Perl | So perl6 would not hold up at " twitter scale"? | 18:44 | |
ugexe | if you get big enough then chances are you can afford to handle those consequences. if you don't then you didn't waste a bunch of time/effort on what essentially is premature optimization | ||
Joe_Perl | ugexe: good point | 18:45 | |
mst | Joe_Perl: if you think that question matters, you didn't listen to me. | ||
Joe_Perl: right, ugexe is making the same point I already did | |||
twitter switched *when it got big enough to matter* | |||
until then, worrying about twitter scale is masturbation, not programming | |||
RabidGravy | :-O | 18:46 | |
ugexe | are we web scale enough? | ||
mst | and as with other forms of masturbation, best done privately and not in the office | ||
timotimo | we're not scale enough | ||
RabidGravy | it's a clear sign you're a team player | ||
;-) | |||
18:46
itaipu left,
Joe_Perl left
18:47
pmurias joined
|
|||
AlexDaniel | .oO( web scale masturbation ) |
18:47 | |
ugexe | perl6 is great for prototyping at the very least | ||
pmurias | AlexDaniel: a large part of the internet is devoted to that ;) | ||
mst | AlexDaniel: funnily enough, a large part of youporn's early rise was because they had more efficient CDN usage than the competitition because of the tools they got via catalyst | 18:48 | |
timotimo | perl catalyst, eh? | ||
perigrin | yes. | 18:49 | |
timotimo | that's a neat story | ||
why doesn't perl brag about porn sites all the time? :P | |||
tadzik | it is! | ||
AlexDaniel | huggable: dunno | ||
perigrin | because it was later re-written in PHP | ||
AlexDaniel | :( | ||
tadzik | (because they switched to php) | ||
perigrin | but with a much more sound architecture | ||
tadzik: strangely they didn't, the company they sold the IP to did. | |||
tadzik | ah | 18:50 | |
mst | well, because it was bought out by another porn company with an existing PHP codebase and an existing PHP team | ||
at which point the port was totally reasonable | |||
mst remembers dropping into HN comments and telling people to stop complaining, I don't like PHP but they were still absolutely in the right business wise | |||
18:51
grondilu left
|
|||
perigrin | I think they green-fielded the re-write ... but yeah | 18:51 | |
RabidGravy | back in the last century if you had perl on your CV you were going to get a call from a recruiter about working on some "adult" web site at least once a week | ||
ugexe | the first time i was yelled at by mst was for not pasting my entire error logs, which i had edited out because i was developing a catalyst app for a porn company lol | ||
RabidGravy | :) | ||
mst | perigrin: yes, but *existing team* | 18:52 | |
perigrin | mst: yeah, no the re-write was entirely justified. | 18:53 | |
mst | if they'd listened to me the catalyst rewrite would've finished but *shrug* | ||
they paid their bills while not listening | |||
timotimo | fantastic | ||
RabidGravy | I have a love/hate relationship with clients like that | 18:54 | |
tadzik | heh, sex.pl was run by perl for a while too | ||
but it was just a perl script generating a static html | |||
mst | ugexe: heh, I can see your reasoning but I hope in hindsight it's obvious why my brain was going "I doooon't caaaare I just want to fiinnd your buuuuggg" :D | 18:55 | |
18:56
Amnez777 left,
edenc joined
|
|||
timotimo | tadzik: of course sex.pl would be run by perl :P | 18:56 | |
AlexDaniel | or prolog… | ||
timotimo | or that | ||
18:58
Amnez777 joined
|
|||
RabidGravy | or pl/1 | 19:00 | |
19:00
domidumont left
19:01
prammer left,
ZoffixWin joined
|
|||
ZoffixWin | AlexDaniel, no huggable for a while. I accidentally nuked my entire server last night :) irclog.perlgeek.de/perl6/2016-05-06#i_12441561 | 19:02 | |
Luckily, moritz++ gave me all #perl6 logs mentioning addressing her, so I can reconstruct her database by re-issuing those commands. | |||
I hope you didn't add a ton of factoids in /msg :P | 19:03 | ||
ufobat | ZoffixWin, i just tried your OO example. and it works for me :-( | ||
AlexDaniel | ZoffixWin: where are your backups? | ||
19:03
edenc left,
edenc joined
|
|||
ZoffixWin | heh, good question :P | 19:04 | |
Technically, I didn't lose any data tho :P | |||
sortiz | m: my @a := List.from-iterator((loop { }).iterator); Mu; # Reify delayed, good. | 19:05 | |
camelia | rakudo-moar ac36d2: OUTPUT«WARNINGS for /tmp/1ZGRZkg8yw:Useless use of constant value Mu in sink context (line 1)» | ||
sortiz | my @a := Array.from-iterator((loop { }).iterator); Mu; # Why try to reify? | ||
m: my @a := Array.from-iterator((loop { }).iterator); Mu; # Why try to reify? | |||
camelia | rakudo-moar ac36d2: OUTPUT«(timeout)WARNINGS for /tmp/19TRs_9jEO:Useless use of constant value Mu in sink context (line 1)» | 19:06 | |
rindolf | ZoffixWin: hi ,sup? | 19:07 | |
ZoffixWin | \o | ||
19:09
azawawi joined
|
|||
azawawi | hi | 19:09 | |
yoleaux | 5 May 2016 21:50Z <arnsholt> azawawi: It's maintained in the sense that I'll accept patches and such, and help out to the extent that I have time. But I'm super-duper busy ATM, sadly, so I'm not actively hacking on it ATM | ||
sortiz | Any good reason why Array try to reify its iterator at creation? | ||
rindolf | azawawi: hi, sup? | ||
ZoffixWin | ufobat, are you sure you tried the class version? I've just tried it again of a clean perl6/Bailador install and I get the template error, because it's using wrong template renderer | 19:10 | |
azawawi | rindolf: done | ||
ufobat | ZoffixWin, i updated the issue | ||
with my example | |||
azawawi | just finished reading zmq ffi perl5 code | ||
ZoffixWin | ufobat, oh, well, it does start, but try going to localhost:3000/ | 19:11 | |
ufobat | it prints the renderer and its the ::Extended | ||
ZoffixWin | k, lemme try running your version | 19:12 | |
ufobat | ZoffixWin, i added a say self.renderer.perl; in my / route and it printed the ::Extended as well | 19:13 | |
ZoffixWin | I'll take a closer look once I'm done eating :) | 19:15 | |
ufobat | enjoy the dinner :) | ||
i've got a question regarding this issue. github.com/ufobat/Bailador/issues/79 . I assume that this erorr happends when you declare a class twice? | 19:17 | ||
19:18
jjido joined
19:22
Relsak left
|
|||
arnsholt | azawawi: Speaking of ZMQ, maybe I should just give you a commit bit? | 19:22 | |
sortiz | For anyone curious I'm asking what is the case of github.com/rakudo/rakudo/blob/1ee2...ray.pm#L53 | ||
azawawi | arnsholt: cool :) | ||
arnsholt | You azawawi on GitHub as well? | 19:23 | |
azawawi | yup | ||
github.com/azawawi/ | |||
moritz | ufobat: yes, it happens when two files have an our-scoped symbol Store | ||
arnsholt | azawawi: There you go. Have fun! =) | ||
azawawi | arnsholt: thanks :) | 19:24 | |
arnsholt: going to finish the book and then start hacking at it soon | |||
ufobat | moritz, could that happen if you install a module and have it in the lib directory at perl6 -Ilib .... for example? | ||
moritz | ufobat: well, a "use Store" should only load one version, either the installed *or* the local oen | 19:25 | |
azawawi | arnsholt: been looking at what we need to support namely api.zeromq.org/4-1:_start and api.zeromq.org/3-2:_start | ||
ufobat | allright, thanks :) | 19:27 | |
19:28
grondilu joined
|
|||
azawawi | hmmm... I dont understand one thing. why does Debian skip versions packages.debian.org/sid/libzmq5 (libzmq5, libzmq3, no libzmq4) | 19:30 | |
moritz | TIL that webkit uses WTF as an internal namespace: webkit.org/blog/6161/locking-in-webkit/ | ||
AlexDaniel | azawawi: libzmq3 version is 4.0.5 | 19:31 | |
azawawi: maybe it is 4? | 19:32 | ||
moritz | "WTF stands for Web Template Framework" | ||
AlexDaniel | libzmq5 version is 4.1.4… hmm… | ||
azawawi | AlexDaniel: no i understand that... but why did they skip using libzmq2 and libzmq4? is that normal? | ||
AlexDaniel | azawawi: well the only reason to have different versions of the same program is if both are needed at the same time. E.g. python2 and python3 | 19:34 | |
19:34
itaipu joined
|
|||
AlexDaniel | azawawi: I don't know why that happened in this particular case though | 19:34 | |
but it could be anything | |||
azawawi | AlexDaniel: it seems the maintainer likes odd version numbers :) | 19:35 | |
rindolf | moritz: heh, heh. | 19:42 | |
19:42
pmurias left
19:44
pmurias joined
19:51
azawawi left
|
|||
ugexe | ZoffixWin: i think thats a rakudo/CUR bug. i replied with more details | 20:00 | |
20:03
jjido left,
uruwi left
20:04
grondilu left
|
|||
ufobat | good night | 20:06 | |
20:06
ufobat left
|
|||
ugexe | it mostly boils down to CUR wants to handle all things precomp, so if something needs to be re-precompiled its CURs job to do it. total reinstallation (the only way a package manager can re-precompile in this situation) involves things other than precompiling that don't need to happen | 20:08 | |
mst | part of me continues to wonder if that was a good plan, but OTOH trying to maintin precomp out of step with rakudo would be its own set of nightmares | 20:09 | |
ugexe | if a workaround is implemented (such as reinstalling all reverse depends) it puts less pressure to fix what is clearly a problem | ||
mst | right, if CUR is going to own precomp, there should be a re-precomp method, which will re-precomp revdeps, I guess | 20:10 | |
or do you mean that re-precomp should've triggered during installation of something and didn't? | |||
ugexe | i would think it should have already happened; that the precomps get invalidated and thus re-precompiled | 20:11 | |
mst | right | ||
but we should probably expose a way to force it | |||
because tish and tyops hapne | |||
ugexe | yeah. an api to precomp would be nice, especially for doing bad things like parallel precompilation | 20:12 | |
to quote latarian milton: its fun to do bad things | 20:14 | ||
timotimo | "shiny; let's be bad guys" | 20:15 | |
20:16
|2701 joined
|
|||
lizmat | masak: re irclog.perlgeek.de/perl6/2016-05-06#i_12443272 : I'll gladly convert these optimizations back to "proper" Perl 6 code :-) | 20:17 | |
once we're sure the optimizer can handle them | 20:18 | ||
like I've just done with (almost) all i = i + 1 -> ++i changes I did yesterday | |||
20:19
maddingue left,
maddingu1 joined
|
|||
AlexDaniel | lizmat: I was so happy to see that :) | 20:20 | |
20:21
Amnez777 left
20:22
Amnez777 joined
20:23
kaare_ left
20:25
infina left
20:27
infina joined,
infina left,
infina joined
20:30
darutoko left,
itaipu left
|
|||
[Coke] | timotimo++ serenity reference. | 20:30 | |
masak | lizmat: cool. that's what I was hoping :) | 20:34 | |
in a perfect world, all the "natural" ways to write things will also be fast, and then we should be using them in the setting ;) | 20:35 | ||
lizmat | yup, agree :-) | 20:36 | |
masak | 'night, #perl6 | ||
lizmat | night masak | 20:37 | |
sortiz | night masak | ||
20:39
itaipu joined
20:45
sufrostico left
20:48
bazzaar joined
|
|||
bazzaar | \o | 20:49 | |
.oO wonders if any good soul is enthused by the potential of using a perl6 grammar to parse a schema-only DB_dump file ? | 20:52 | ||
mst | interesting idea, you might want to look at the recdescent etc. parsers in the perl5 SQL::Translator module for bits to steal | 20:55 | |
timotimo | yeah, especially stealing tests is worth a lot i bet | ||
bazzaar | thanks for the pointers, I'll take a look. | 20:56 | |
20:57
hotel|netteiru is now known as hotel
|
|||
ZoffixWin | Found my issue for why Bailador's class-y interface was failing me last night. I still had `use Bailador` in the file and it was setting up a default app and not my own or whatever. | 20:59 | |
hotel | How do I give something optional arguments? or should I just use a multi? | ||
bazzaar | I've written and debugged such a grammar, ... only tested it against my own db schema though so probably not exhaustive | ||
ZoffixWin | hotel, named args are optional by default, positional args, just add '?' after them | ||
hotel | named argsare the ones with colons right? | ||
actually I'm probably better off using a multi | 21:00 | ||
ZoffixWin | m: sub foo ($a, $b?, :$yes) { say quietly "$a $b $yes" }; foo 42; foo 42, 45; foo 42, 45, :72yes; | ||
camelia | rakudo-moar ac36d2: OUTPUT«42 42 45 42 45 72» | ||
ZoffixWin | hotel, oh, or add a default value: | 21:01 | |
hotel | yeah I know all about those, I come from python | ||
ZoffixWin | m: sub foo ($a, $c = 2, $b?, :$yes) { say quietly "$a $c $b $yes" }; foo 42; foo 42, 45; foo 42, 45, 555; foo 42, 45, :72yes; | ||
camelia | rakudo-moar ac36d2: OUTPUT«42 2 42 45 42 45 555 42 45 72» | ||
21:02
TEttinger joined
|
|||
ZoffixWin | I think I'm gonna repeat my Perl 5 mistake and make my own Perl 6 web framework.... | 21:04 | |
Bailador just doesn't fit into my brain. | 21:05 | ||
moritz | port Mojolicious to p6? | ||
21:05
jjido joined
|
|||
mst | have a look at my Web::Simple stuff for ideas as well simply because it's probably the most flexible perl5 dispatcher in existence | 21:05 | |
and is already kinda slang-like in its own way | |||
bazzaar | Wondering if anyone has a PG schema of their own, that they could run past my perl6 grammar, to flush out additional bugs | ||
moritz | bazzaar: what's a PG schema? | 21:06 | |
geekosaur | postgresql | ||
hotel | so does this make sense? gist.github.com/HotelCalifornia/de...c4755aa421 | ||
ZoffixWin | mst, will do | ||
mst | ZoffixWin: I suspect the controller lifecycle stuff from mojo will be worth grabbing, plus look at how catalyst uses role composition etc. to be more DRY for large scale apps, plus Web::Simple for my ideas of "a better dispatcher" (Mojo's dispatcher is a much easier API to an about-as-powerful-as-catalyst dispatcher, which is a different achievement) | 21:07 | |
moritz | bazzaar: github.com/moritz/quelology/blob/m...schema.sql old and nothing fancy in there | ||
also github.com/moritz/ilbot/blob/maste...postgresql | 21:08 | ||
21:08
Skarsnik left
|
|||
moritz | this one contains a function at least :-) | 21:08 | |
bazzaar | moritz: wow, that was quick :-) .... will definitely use those, I see some things not in my schema | 21:10 | |
hotel | anyone? 0w0 | 21:12 | |
ZoffixWin | hotel, not really. On lines 2 and 3 you're declaring class variables, you know that? | 21:15 | |
bazzaar | sql [in the db_dump] to build the db relations is relatively simple to parse, and I'm guessing would be quite alike between diff db_servers, and no database access necessary to be able to do all sorts of fun stuff with the db relations in perl6 | ||
hotel | yeah? | ||
ugexe | hotel: it looks ok. you could also use `submethod BUILD` instead of new: submethod BUILD(Str :$!server-addr!, Int :$!server-port = 8080) { $!socket = ... } | 21:16 | |
hotel | what's the difference between BUILD and new? | ||
timotimo | very big difference | 21:17 | |
for one, every class in the chain of derivation has their BUILD called | |||
but only a single method new will be called | |||
geekosaur | new means you have to implement and orchestrate all the superclass building and such. BUILD is invoked byt he default new when it's time to initialize your class, with the superclasses already done | ||
timotimo | (the difference for submethods is that they don't get derived to subclasses) | 21:18 | |
hotel | hm | ||
timotimo | BUILD is actually invoked via "self.bless", which your own method new will most likely call, too | ||
21:18
ZoffixWin left
|
|||
hotel | But if I don't have a hierarchy... | 21:19 | |
ugexe | the short answer is you need to use `new` when you want to pass positional arguments, not all named | ||
hotel | ah | ||
timotimo | you can't get "no" hierarchy. you have to derive at least from Mu, but if you don't give any target to derive from, you'll derive from Any | ||
Xliff_ | In P6 BUILD is the better equivalent of an OO constructor, rather than new(). | 21:20 | |
timotimo | but Any doesn't do much in its construction, so it's n big deal | ||
Xliff_ | BUILD == assign values to attributes. new == perform actions required for the construction of a class instance. | ||
At lest that's how I've begun to see it. | |||
ugexe | someone contrive a reason to sneak a BUILDALL in | 21:21 | |
Xliff_ | ugexe, and BUILDALL does...? | ||
ugexe | call in the opposite order of BUILD, after its been initialized | 21:22 | |
21:22
hotel_california joined
|
|||
hotel_california | so then the body is the same in this case? | 21:22 | |
ugexe | you dont need to `bless` in BUILD | ||
21:22
hotel left,
hotel_california is now known as hotel
|
|||
hotel has a garbage connection | 21:22 | ||
ah okay | |||
Xliff_ | Am I correct in assuming that bless is called by new, implicitly? | 21:23 | |
s/bless/self.bless/ | |||
ugexe | BUILD is easier to subclass, so unless you really want positionals in your new you probably want to use BUILD | ||
21:24
pmurias left
|
|||
ugexe | if you declare your own `new` method you have to call self.bless(|%_) yourself | 21:24 | |
mst | hotel: short version: you should be using BUILD | 21:25 | |
hotel | thanks all | ||
mst | hotel: if you think you can't use BUILD, you're probably wrong, ask here | ||
hotel: then if we can't find a way to fix it without writing new(), then we can discuss doing it the hard way | 21:26 | ||
hotel didn't know about it before 5 minutes ago | |||
21:32
Sgeo joined
21:34
itaipu left
21:35
sortiz left,
jjido left
21:38
jjido joined
21:42
yqt joined
|
|||
hotel fried his brain, will try again later | 21:45 | ||
ugexe | i posted a comment to your gist with an untested example | 21:46 | |
21:46
bazzaar left
|
|||
hotel | nah, I got that part, just trying to translate from python to p6 while following a spec | 21:46 | |
but thanks | 21:47 | ||
cxreg | the more I learn Go the more I wish it was Perl 6 | 21:49 | |
21:52
jjido left
21:56
kaare_ joined
21:58
mr-foobar left
21:59
mr-foobar joined
22:04
kaare_ left
|
|||
AlexDaniel | .oO( the more you learn GO the more you wish it wasn't Go? ) |
22:04 | |
Go* | |||
cxreg | there are nice parts but those equivalent parts are also nice in p6 | 22:11 | |
and the icky parts are better in p6 :p | |||
AlexDaniel | .oO( use perl 6 then? ) |
||
cxreg | don't you live in a nice bubble :p heh | 22:12 | |
RabidGravy | I do :) apart from some tiny bits of C, Perl 5 and Javascript I've done nothing else but Perl 6 for a year | 22:17 | |
(I probably should get a proper job at some point ;) | 22:18 | ||
22:20
rindolf left
|
|||
cxreg | I've been binging on "recent stuff that people are hiring people to do" | 22:24 | |
there are precisely zero jobs asking for perl 6 experience | |||
maybe one day | |||
hotel | what is the point of keeping a Supplier around? can I just say my $supply = Supplier.new.Supply;? | 22:26 | |
smls | m: say "a" eqv "a" | ||
camelia | rakudo-moar ac36d2: OUTPUT«1» | ||
smls | ^^ Why is this returning 1 instead of True? | 22:27 | |
hotel | why not use eq? | ||
smls | It's a golfed-down example :P | 22:28 | |
hotel: Re. Supplier, you need it because you cannot call .emit on a Supply directly. | |||
geekosaur | isn't there a ticket for that? some kind of nqp shenanigans iirc | ||
22:29
protium joined
|
|||
hotel | ooh, I get it now | 22:29 | |
smls++ | |||
cxreg | m: say "a" eq "a" | 22:32 | |
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
hotel | "The server MUST provide a sane Supply that emits Blob objects..." but only suppliers can emit? | 22:33 | |
cxreg | m: say ("a" eqv "a") === True | 22:34 | |
camelia | rakudo-moar ac36d2: OUTPUT«False» | ||
cxreg | m: say ("a" eq "a") === True | ||
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
cxreg | o_O | ||
hotel | lol | ||
smls | hotel: When you call the .emit method on the Supplier, it becomes available to all subscribers of the Supply. | 22:35 | |
cxreg | i think that's a regression, i have an old build that returns True | ||
hotel | so basically I'm just supposed to have both | ||
or I guess I have to anyway | |||
just wondering why it says the supply should emit stuff | 22:36 | ||
smls | it is intended to mean the same thing | ||
just doesn't use the language very precisely | 22:37 | ||
hotel | gotcha | ||
smls | You hand the Supply to the down/up-stream code, and keep the Supplier locally in your lexical scope where you want to emit stuff on the Supply. | ||
ugexe | cxreg: maybe related to this? github.com/rakudo/rakudo/commit/fe...c2e23c3a40 | 22:39 | |
22:40
wamba joined
|
|||
cxreg | the issue isn't with ===, but with what eqv returns | 22:40 | |
ugexe | er, sorry its the commit *after* that | 22:41 | |
github.com/rakudo/rakudo/commit/46...99ae02c2b9 | 22:42 | ||
cxreg | yes | 22:46 | |
at least it looks like a likely culprit | |||
ugexe | i got True for 2014.04 fwiw | 22:47 | |
hotel | =:= ? | ||
cxreg | i had True in 2015.12 | ||
hotel | m: say 10 =:= 11 | ||
camelia | rakudo-moar ac36d2: OUTPUT«False» | ||
hotel | m: say 10 =:= 10 | 22:48 | |
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
cxreg | hotel: compares aliased containers | ||
ugexe | er 2016.04 heh | ||
cxreg | oh heh | ||
ugexe | i.e. it had to have happened in the last few weeks | ||
hotel | what are these so-called "containers" people keep talking about? | 22:49 | |
geekosaur | m: my $a; say $a.VAR.^name | 22:50 | |
camelia | rakudo-moar ac36d2: OUTPUT«Scalar» | ||
hotel | m: my $a; say $a.VAR | 22:52 | |
camelia | rakudo-moar ac36d2: OUTPUT«Any» | ||
cxreg | m: say "a" =:= "a" | 22:53 | |
camelia | rakudo-moar ac36d2: OUTPUT«True» | ||
hotel | bork I can't think anymore | 22:54 | |
22:54
hotel is now known as hotel|out
|
|||
geekosaur | before you run away too far, consider | 22:57 | |
m: my $a; say $a.^name | |||
camelia | rakudo-moar ac36d2: OUTPUT«Any» | ||
hotel|out | so it helps with introspection? | ||
geekosaur | a variable like $a normally gives you its value. but it's actually bound to a container --- that is how it can be mutable | 22:58 | |
cxreg | say my name say my name | ||
smls | hotel: Basic value types like strings (Str) and integers (Int) are immutable in Perl 6. Item containers (also called "scalars") are what makes it possible to use Perl 6 for imperative programming nonetheless. | ||
E.g. when you write «my $i = 42;», it stores an Int object representing the number 42, in the item container represented by the variable $i. | |||
And then when you call «$i++», it does not modify the Int object (which is immutable), but replaces it with another Int object representing the number 43. | |||
Every normal $ variable, and every slot of a @ variable, represents such a container. | 22:59 | ||
22:59
firstdayonthejob left
|
|||
hotel|out | so /that's/ why you can't access the characters in a Str | 23:00 | |
interesting nonetheless | |||
AlexDaniel | m: my $s = ‘abc’; $s.substr-rw(1, 1) = ‘z’; say $s | 23:08 | |
camelia | rakudo-moar ac36d2: OUTPUT«azc» | ||
AlexDaniel | smls: how would you explain this? :) | ||
23:08
kid51 joined
23:09
BenGoldberg joined
|
|||
geekosaur | don;t see how that proves smls wrong. substr's result doesn't know where it came from; substr-rw's is a proxy that knows and can make alterations to the container thereby | 23:11 | |
AlexDaniel | geekosaur: no-no, it doesn't. I just thought that after a great explanation he can also give another great explanation for this :) | 23:12 | |
ugexe | m: use MONKEY-TYPING; role StrList { method AT-POS($a) { return self.substr($a, 1) }; }; augment class Str { also does StrList; }; my $str = "abcd"; say $str[2] | 23:13 | |
camelia | rakudo-moar ac36d2: OUTPUT«c» | ||
23:19
smls left
23:21
zakharyas joined
23:22
sufrostico joined
23:23
jjido joined
|
|||
hotel|out | my phone's doing this weird thing where it drops or downloads corrupted audio packets when streaming but playback continues with long gaps of silence anyway | 23:27 | |
if only android was built on perl6, this kind of thing wouldn't happen | 23:28 | ||
23:28
jjido left
23:31
ZoffixWin joined,
ZoffixWin left,
ZoffixWin joined
|
|||
literal | m: class Foo is Str {}; my $foo = Foo("dsfsdf"); say $foo | 23:32 | |
camelia | rakudo-moar ac36d2: OUTPUT«Cannot find method 'Foo' in block <unit> at /tmp/gTydPtmEfn line 1» | ||
literal | how should I be doing this? | ||
ZoffixWin | I need to generate a date in HTTP Last Modified header format. I don't see any convenient methods in Dateish/DateTime... are there any subs that could make it easier than this: | 23:33 | |
my $mod = DateTime.new("main.css".IO.modified); say $mod; printf "%s, %02d %s\n", <Mon Tue Wed Thu Fri Sat Sun>[.day-of-week-1], .day, <Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec>[.month-1] given $mod; | |||
literal, Foo.new | |||
literal | ZoffixWin: is there no way to get a short-hand constructer like Str()? | 23:34 | |
ugexe | method CALL-SAME($a) { self.new($a) } | 23:35 | |
er CALL-ME | |||
ZoffixWin | m: class _Foo is Str {}; sub Foo { _Foo.new: $^a }; my $foo = Foo("dsfsdf"); say $foo | 23:36 | |
camelia | rakudo-moar ac36d2: OUTPUT«Default constructor for '_Foo' only takes named arguments in block <unit> at /tmp/c_4MS2cjqk line 1» | ||
ZoffixWin wonders what that throws that error | |||
literal | I see. new() requires a named argument, what is it for Str? docs don't mention it | ||
ugexe | m: class Foo { has $.str; method CALL-ME($str) { self.new(str => $str); }; }; my $foo = Foo("asdf"); say $foo | ||
camelia | rakudo-moar ac36d2: OUTPUT«Foo.new(str => "asdf")» | ||
ZoffixWin | neat | 23:37 | |
23:37
wamba left
23:38
grondilu joined
|
|||
literal | doesn't stringify like Str though | 23:39 | |
or .gistify | |||
23:39
cdg left
|
|||
ugexe | $.str handles /*/, its all in what you make it | 23:40 | |
maybe you really want to do role Stringy instead of inherit from Str | |||
23:40
cdg joined
|
|||
literal | I see didn't know about Stringy | 23:42 | |
hotel|out | roles are like interfaces right? | 23:45 | |
23:45
hotel|out is now known as hotel
|
|||
ZoffixWin | <ZoffixWin> perlbot, eval: strftime '%a, %d %b %Y %T GMT', localtime | 23:45 | |
<perlbot> ZoffixWin: Fri, 06 May 2016 23:45:15 GMT | |||
Is there similar simplicity in Perl 6? | |||
There just gotta be. I refuse to believe the person who decided we needed .weekday-of-month didn't think to add an easy way to format datetimes :/ | 23:47 | ||
hotel | m: strftime "%a, %d %b %Y %T GMT", localtime | 23:48 | |
camelia | rakudo-moar ac36d2: OUTPUT«5===SORRY!5=== Error while compiling /tmp/sG8tFMlJePUndeclared routines: localtime used at line 1 strftime used at line 1» | ||
hotel shrugs | |||
ZoffixWin | Hmmmm | ||
23:49
cdg left
|
|||
hotel | doc.perl6.org/type/Dateish#method_formatter ? | 23:49 | |
if I'm reading that right you can set it to your own function? | 23:50 | ||
:S | |||
ZoffixWin | hotel, yes, but that function would have to be huge like this: github.com/rakudo/rakudo/blob/nom/...ime.pm#L10 | ||
Which is what I'm trying to avoid :P | |||
It probably should belong in POSIX module: modules.perl6.org/dist/POSIX | 23:51 | ||
The strftime thing that is | |||
hotel | wow | ||
can't you use nativecall then? | 23:54 | ||
or do you need it to be really cross-platform? :P | |||
ZoffixWin | Why, is it not cross-platform in C? | 23:55 | |
ugexe | i think he just wants all the date-style directives for %Y etc for sprintf | ||
hotel | idk | 23:56 | |
guess it is then | |||
so can't you do a native call to strftime? | |||
ZoffixWin tries to hack something up and will submit a PR to POSIX | |||
hotel | lol | ||
23:57
hotel is now known as hotel|out
|
|||
ZoffixWin | hotel, well, I don't know C... So that will involve "learning things" :) | 23:57 | |
hotel|out | man7.org/linux/man-pages/man3/strftime.3.html | ||
BenGoldberg | Technically, you don't need to learn C. You just need to learn the types used by C. | 23:58 | |
ZoffixWin | Sure :) | ||
BenGoldberg | Some of it is a bit hard, I mean, 'char' is a type whose purpose is to hold a chararacter. Mind blowing! | 23:59 |