»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg camelia perl6: ... | irclog: irc.perl6.org | UTF-8 is our friend! Set by sorear on 25 June 2013. |
|||
00:02
rmgk_ joined,
rmgk_ is now known as rmgk
00:10
virtualsue left
00:23
noganex joined
00:27
KCL joined
00:30
Akagi201 joined
00:35
Akagi201 left
00:41
dj_goku joined
00:51
Ugator joined
00:53
robinsmidsrod joined
00:56
Ugator left
01:08
dayangkun joined
01:09
denis_boyun left
01:32
Akagi201 joined
|
|||
[Coke] | jnthn: sorry. no luck making things fail this evening. | 01:35 | |
01:38
jferrero joined
01:43
konsolebox joined
01:44
konsolebox left
|
|||
raydiak | \o * | 01:55 | |
colomon | o/ | 02:00 | |
02:02
konsolebox joined
02:03
konsolebox left
02:24
aborazmeh left
|
|||
raydiak | colomon: what have you been up to? | 02:32 | |
colomon | Trying to clean up Unicode filename handling in my C++ $work code. | 02:36 | |
raydiak | eh...idk specifically what that entail, but I'm sorry :) | ||
*entails | 02:37 | ||
colomon | It entails trying to deal with Microsoft's incompetence. | ||
raydiak | even more "eh"/ew...sorry :P | ||
colomon | basically, I've gone through my filename class and made sure it handles utf8 in char *s and utf16 or utf32 in wchar_t *s, depending on where the code is compiling. | 02:38 | |
raydiak learned perl 5 in his late teens and got spoiled too much to go very far w/things like C | 02:39 | ||
colomon | and it's only just now occurred to me to wonder if one (or more?) of the libraries I have to interface with may be using utf16 in 4-byte wchar_t class, because they are programming like they are on (broken) Windows even though their code is actually running on OS X / Linux. | 02:40 | |
And I've got no idea how I'm going to determine whether that is the case. | |||
raydiak | I have it in my memory for whatever reason that we have similar interests...do you have any interest in Math::Symbolic? | 02:43 | |
colomon | oh, yes. :) | ||
haven't really had time to look at it yet | 02:44 | ||
raydiak | it's a one-man band atm, but I'm totally down for more awesome people to swoop in and make it more serious at any time :) | ||
02:44
aborazmeh joined
|
|||
colomon is going through a life phase where he is pretty much perpetually wildly behind in everything he needs to do. | 02:44 | ||
raydiak | it needs a serious API, is where it's at atm...has some decent functionality, like solving for a variable in many cases, and compiling to perl 6, but justis plain "not done" | 02:45 | |
colomon | I did poke a bit recently at Math::ContinuousFractions, but I'm running into infinite loops where I think laziness should be working for me, and haven't had time to sort it out. | 02:46 | |
raydiak | it's close to being able to replace large parts of the primitive definitions in Pray w/the solving and precompiling abilities | 02:47 | |
colomon | Pray? | ||
raydiak | that raytracer I used to write about | 02:48 | |
cyberuniverses.com/pray/ | |||
written in P6 | |||
colomon | Oh! | 02:49 | |
raydiak | it's basically how I introduced myself to #perl6, over a year ago now | ||
colomon | I remember the raytracer, forgot the name. :) | ||
raydiak | yeah that thing :) | ||
the only thing stopping me atm, off the top of my head, is figuring out exactly how to deal with the ± resulting from solving a quadratic when calling .compile | 02:51 | ||
colomon | huh. I wouldn't think that would be that hard... | 02:52 | |
raydiak | it's not, I'm just indecisive | ||
colomon apologizes for phazing in and out of the conversation here, trying to juggle some $work and dishes at the same time. ;) | 02:53 | ||
raydiak | nah yer fine didn't even notice | ||
anyway, Math::Symbolic has serious implications beyond itself and myself, like auto-generating the math/logic for your games and simulations, so I'm just looking for people besides me who might be interested in contributing | 02:55 | ||
I used it to solve the leading problem in 3D as the intersection of a 4D line and a hypercone :) | 02:57 | ||
colomon | I absolutely am interested, but at the moment I cannot see myself having much in the way of tuits before 2015 | 02:58 | |
03:01
jimmy_ joined
|
|||
raydiak | awesome, good news to me...by then it'll likely be more stable anyway | 03:02 | |
(in terms of api...runtime seems stable already) | |||
jimmy_ | Does it run on MoarVM ? | ||
03:03
jimmy_ is now known as JimmyZ_
|
|||
raydiak | well ya :) | 03:03 | |
not sure if I've tested it on anything else yet... | |||
but cpandatesters has | |||
(though I can't seem to get those result sto load atm) | 03:07 | ||
03:10
Mso150_f_e joined
03:15
noganex_ joined
03:18
noganex left
03:19
aborazmeh left
03:21
atroxaper joined
03:23
Mouq joined
03:25
atroxaper left
03:33
dj_goku left
03:36
dj_goku joined
|
|||
colomon | raydiak: just went spulunking through the library code in question, and in fact they with malice aforethought return utf-16 in wchar_t values even if wchar_t is 4 or 8 bytes. (Who does 8 bytes?) :( | 03:41 | |
03:42
Mouq left
03:45
Akagi201 left,
dj_goku left,
Akagi201 joined
03:47
JimmyZ_ left
|
|||
BenGoldberg | Some strange 64 bit platform which can process strings which use 8 bytes per wchar_t faster than other sizes. | 03:47 | |
geekosaur would be tempted to suggest Alpha | |||
colomon | The good news is I think my code will handle utf32 in 8 byte characters in a pinch. | 03:48 | |
03:48
dj_goku joined,
Mso150_f_e left,
JimmyZ_ joined
|
|||
geekosaur | ok, not alpha, it was 4 byte | 03:52 | |
it does sound like some platform that used (long) for wchar_t and then ported to 64 bit | 03:53 | ||
colomon | the better news is there is not such thing as utf64 | 03:55 | |
BenGoldberg | That would verge on madness! | 04:03 | |
04:13
anaeem1_ joined
04:16
anaeem1_ left,
anaeem1 joined
04:35
dj_goku left,
kaleem joined
04:44
dj_goku joined
04:52
kaare_ joined
04:59
dayangkun left
05:12
kaleem left
|
|||
dalek | osystem: a2f27de | (Nick Patch)++ | META.list: add Geo::Region |
05:18 | |
05:26
Mouq joined
05:30
gfldex joined,
Mouq left
05:39
Woodi joined
05:52
BenGoldberg left
05:57
kaare_ left
06:14
adu joined
06:19
kaare_ joined
06:20
cibs joined
06:31
JimmyZ_ left
06:34
dayangkun joined,
dayangkun left
06:51
khisanth_ joined
06:56
atroxaper joined
07:02
djanatyn joined,
atroxaper left
07:06
hahainternet joined
07:12
gfldex left
07:13
kaleem joined
07:16
ggherdov joined
07:17
bjz joined
07:19
khisanth_ left
|
|||
raydiak | if I define a .list() method but my class doesn't do Positional, will it do anything other than let people say @$object? e.g. it won't get called in list context or stuff like that, right? | 07:20 | |
07:20
khisanth_ joined
07:22
FROGGS joined
07:28
vti joined
07:52
Ugator joined,
FloLo joined
|
|||
moritz | raydiak: stuff in a scalar container generally isn't automatically iterated over | 07:53 | |
m: say(42) for [1, 2, 3] | 07:54 | ||
camelia | rakudo-moar dfcf9f: OUTPUT«42» | ||
raydiak | true, and since it can't go in an @ either, I guess it's only an applicable question when the object is used as the return value from a routine without an intermediate container | 07:55 | |
moritz | iirc map/for use Iterable to decide whether to iterate over a non-itemized object | 07:56 | |
raydiak | ah, thanks, will read up on that | 07:57 | |
moritz | not sure much of it is documented | ||
m: say Positional ~~ Iterable | |||
camelia | rakudo-moar dfcf9f: OUTPUT«False» | ||
07:57
KCL left
|
|||
moritz | raydiak: also, Any has a 'list' method, so all your objects already have one | 07:58 | |
07:58
rurban joined
|
|||
raydiak | oh, well that answers that then :) | 07:58 | |
moritz++ | |||
FROGGS | morning | 07:59 | |
raydiak | \o FROGGS | ||
08:00
atroxaper joined
08:01
rindolf joined
08:05
atroxaper left
08:07
davido_ joined
08:13
krunen joined,
rindolf left
08:27
darutoko joined
|
|||
hahainternet | so nativecall has no union support it seems, that's a shame | 08:33 | |
i need to find some stuff to write in p6 | |||
08:33
jimmy_ joined
08:34
telex left
08:35
grondilu joined
|
|||
grondilu | rosettacode.org/wiki/Fast_Fourier_t...orm#Perl_6 is broken, apparently because it's not possible anymore to extract a finite list of values with an infinite list of indices. | 08:36 | |
perl6: my @a = 1 .. 10; say @a[0, 2 ... *]; | |||
08:36
telex joined
|
|||
grondilu is not sure what the spec has to say about that. | 08:36 | ||
08:37
blackbolt joined
|
|||
camelia | rakudo-{parrot,moar} dfcf9f: OUTPUT«(timeout)» | 08:37 | |
FROGGS | hahainternet: talk to timotimo, he was about to implement that | ||
hahainternet: so he has at least some insights | |||
hahainternet | FROGGS: rgr, i'm not sure what's blocking it but i've not written anything useful in p6 yet so | 08:38 | |
FROGGS | hahainternet: you might want to skim the advent posts, or skim the module list for inspiration | 08:39 | |
sergot | hey o/ | 08:40 | |
FROGGS | hi sergot | ||
hahainternet | FROGGS: i did but finding details even on 'repr' and its implementation is frustrating | ||
short terms, hard to google for, and i'm inexperienced | |||
grondilu | perl6: my @a = 1 .. 10; say @a[0, 2 ...^ * >= @a]; # kind of ugly, is there a better way to write this? | ||
camelia | rakudo-{parrot,moar} dfcf9f: OUTPUT«1 3 5 7 9» | ||
FROGGS | hahainternet: this should shed some lights: github.com/edumentab/rakudo-and-nq...als-course | 08:43 | |
hahainternet: here are pdf's: edumentab.github.io/rakudo-and-nqp-...ls-course/ | |||
hahainternet | yep already there :) | ||
thanks | |||
08:43
vti left
08:44
Mso150_f_e joined
08:48
xinming joined
08:53
adu left
09:02
atroxaper joined
|
|||
eiro | o/ #perl6 | 09:03 | |
09:07
atroxaper left
09:11
azawawi joined
|
|||
azawawi | hi | 09:11 | |
yoleaux | 30 Nov 2014 16:46Z <timotimo> azawawi: will you write a post on the advent calendar about farabi6? | ||
azawawi | timotimo: ping | 09:12 | |
azawawi takes a look at HTTP::Server::Async | 09:13 | ||
09:15
zakharyas joined
09:19
tinyblak joined
09:26
dakkar joined
09:33
Isp-sec joined
09:34
Ugator left,
FloLo left
09:35
Rounin left
|
|||
azawawi | .tell timotimo Please see github.com/azawawi/farabi6/issues/59 | 09:37 | |
yoleaux | azawawi: I'll pass your message to timotimo. | ||
09:40
vti joined
|
|||
dalek | volaj: 4d9eb73 | (Rob Hoelz)++ | t/08-callbacks.c: Remove strdup in Str callback example MoarVM no longer attempts to free strings coming in via callbacks; other implementations should follow soon |
09:40 | |
volaj: c2e7e3c | (Rob Hoelz)++ | README.markdown: Add callback example to README |
|||
volaj: 6bf4145 | jonathan++ | / (2 files): Merge pull request #52 from hoelzro/master Documentation for function arguments, and removal of strdup in Str callback test |
|||
azawawi | .tell timotimo im currently busy a bit @ $work. Hopefully workload will lighten up a bit after December. The HTTP::Server::Async idea is great. Is EventSource possible with it? | 09:48 | |
yoleaux | azawawi: I'll pass your message to timotimo. | ||
09:48
denis_boyun_ joined
09:49
ptc_p6 joined
|
|||
Ulti | how can I grab an account on the advent calendar ahead of time? | 09:52 | |
09:53
jimmy_ left,
denis_boyun_ left
|
|||
moritz | Ulti: /msg me your email address | 09:56 | |
Ulti | k k | 09:57 | |
masak | antenoon, #perl6 | 09:59 | |
moritz | \o masak | ||
jnthn | .tell hoelzro I'd suggesting giving make_where_block a third optional argument, which defaults to QAST::Var.new( :name('$_'), :scope('lexical') ), and then pass in the QAST tree to make it do $_.signature where you are calling it. | 10:01 | |
yoleaux | jnthn: I'll pass your message to hoelzro. | ||
10:08
ptc_p6 left
10:11
azawawi left
|
|||
Ulti | moritz can we get the pygments plugin via wordpress.com? | 10:17 | |
moritz | Ulti: I have no idea if we can | 10:18 | |
Ulti: I tend to use tools that generate HTML, and copy&paste the output into the HTML box | 10:19 | ||
Ulti | yeah I did that but you can't include any <style> tags | 10:21 | |
just checking if the appspot version of pygments has the perl6 support installed or not, not much point otherwise | |||
moritz | according to wordpress.com/products/custom-css/ you can put custom CSS somewhere, but I haven't managed to do that yet | 10:25 | |
10:26
Akagi201 left
10:46
robinsmidsrod left
10:47
Hor|zon joined,
robinsmidsrod joined
|
|||
blackbolt | Hi, someone install Steroids? i have problem : "Cannot locate native library './sdlwrapper.so" | 10:50 | |
10:51
Lasse_ joined
10:56
Mso150_f_e left
10:59
mvuets joined
|
|||
carlin | blackbolt: did you run `make -f Makefile.sdlwrapper` ? | 11:00 | |
11:01
robinsmidsrod left
11:02
robinsmidsrod joined
|
|||
blackbolt | carlin: yes, there was "sdl-config" -unknown command | 11:02 | |
carlin : sdl2-config * | 11:03 | ||
moritz | that would it explain it, I guess :-) | ||
blackbolt: you probably need to install the sdl2 development headers (+config program) | |||
11:05
denis_boyun_ joined
|
|||
blackbolt | mortiz : i will do that | 11:05 | |
11:08
tinyblak left,
tinyblak joined
11:14
robinsmidsrod left,
robins joined
11:15
robins left
11:18
robinsmidsrod joined
11:25
chenryn joined
11:28
robinsmidsrod left
11:30
robins joined
11:31
Isp-sec left
11:32
tinyblak_ joined
11:34
tinyblak left
11:35
TuxCM joined
11:38
kaleem left
11:40
robins left
11:41
rindolf joined
11:42
woolfy joined,
robinsmidsrod joined
|
|||
Ulti | moritz you'd need admin rights for that though | 11:44 | |
11:44
kurahaupo joined
|
|||
moritz | Ulti: I have admin rights | 11:46 | |
Ulti | moritz well here's a bunch of pygments classes ;P gist.github.com/asaaki/1007420 | 11:47 | |
11:47
robinsmidsrod left
11:48
robinsmidsrod joined
|
|||
Ulti | it's annoying GitHub stopped using pygments otherwise embedded Gist would have worked nicely | 11:49 | |
11:49
virtualsue joined
11:50
robinsmidsrod left,
robinsmidsrod joined
11:53
robinsmidsrod left,
robins joined
|
|||
colomon | huh. cleanest smoke test run in days, but I don't understand why. :\ | 11:55 | |
11:56
robins left,
robinsmidsrod joined
|
|||
carlin | colomon: LibraryMake was fixed yesterday, would have a fixed a few projects | 12:01 | |
colomon | ah | 12:02 | |
12:03
bcode joined
12:09
smls joined
|
|||
smls | o/ | 12:09 | |
12:10
atroxaper joined
12:16
rurban left
12:17
atroxaper left
|
|||
smls is enjoying mst's advent calendar ("mstpan") in which each day he provides an opinionated overview of available Perl 5 modules for a particular task: shadow.cat/blog/matt-s-trout/ | 12:19 | ||
^^ might also be of interest to Perl 6 module authors looking for inspiration / prior art / cautionary tales | |||
Ulti | so how do I get around "Circular module loading detected" when there is no actual circular dependencies other than two classes might want to produce each other | 12:35 | |
do they have to be in the same file? | |||
or is it just that I'm doing use rather than require or something | |||
dalek | ecs: a3cb57b | (Nick Patch)++ | S32-setting-library/Exception.pod: [S32::Exception] remove double-a typo |
12:38 | |
12:40
Ven joined,
erkan joined,
erkan left,
erkan joined
12:42
chenryn left
|
|||
FROGGS | Ulti: perhaps put it in the same file, then stub class A, then declare B and A | 12:44 | |
Ven | "valgrind is not just a leak checker" | 12:52 | |
maintainablecode.logdown.com/posts/...ak-checker | |||
12:53
kaleem joined
12:57
brrt joined
|
|||
brrt | \o | 12:57 | |
12:58
anaeem1 left
|
|||
Ulti | this feels like a bigger problem though if you have a bunch of classes that coerce to each other | 13:01 | |
FROGGS | you just need to stub the A's once | ||
and this should perhaps also work across files/CUs | 13:02 | ||
arnsholt | masak: Oooh, those were interesting posts. Thanks for mentioning it! | ||
13:04
BenGoldberg joined
|
|||
Ven needs to clog masak's links | 13:06 | ||
13:06
Ven left
|
|||
smls | moritz, Ulti (re. custom CSS on wordpress): I've read that's only possible if you either self-host your wordpress blog, or upgrade to a paid plan on wordpress.com | 13:08 | |
masak | arnsholt: I have completely lost context ;) no idea what posts those were, but glad they were interesting. | 13:10 | |
smls | although you can embed CSS in a <style></style> element in your post contents | ||
arnsholt | masak: mstpan =) | ||
Oh, except it was smls, not you | |||
Apparently I have still not had enough caffeine this morning >.< | 13:11 | ||
colomon | caffeine++ | ||
moritz | (not needing caffeine)++ | 13:12 | |
colomon | moritz: indeed :) | ||
13:14
BenGoldberg left
|
|||
smls | Ulti: Also, I've tried the pygments plugin on a local wordpress install, and it isn't very good. | 13:14 | |
For example, non-ASCII characters tripped it up badly. | 13:15 | ||
And it inserted a huge CSS block before every single syntax-highlighted code snippet, rather than just one per page. | |||
(which significantly affected page load time for a page with many code snippets) | 13:16 | ||
Ulti | lame | 13:21 | |
smls | Ulti: Note that you can manually pipe your code snippets through pygmentize though (which is installed with Pygments), using «pygmentize -f html -O nowrap -l perl6 -o output.htm input.p6» | 13:24 | |
Or write your file in HTML and make sure all code snippets are in <code></code> tags, and then use my convenience script on it: github.com/smls/undef/blob/master/...de-tags.p6 | |||
(although the script still has some rough edges) | 13:25 | ||
And then add something like this to the top of the HTML: gist.github.com/smls/a67af2e2c6466df32dc9 | |||
13:26
denis_boyun_ left
|
|||
moritz | or you could use Text::VimColor | 13:28 | |
13:31
atroxaper joined
|
|||
colomon wonders how hard it would be to make a p6 version of Text::VimColor... | 13:46 | ||
FROGGS | ++colomon | 13:47 | |
:D | |||
Ulti | yeah smls I was already doing that but the problem is <style> is stripped out by Wordpress | 13:58 | |
I think moritz can probably allow all HTML in posts though | |||
smls | really? | 13:59 | |
Ulti | yarly | ||
smls | it's not stripped out in my install | ||
Ulti | at least with the current security settings | ||
smls | maybe it's a *wordpress.com* thing, to promote their premium plan which includes custom CSS support? | ||
Ulti | smls well I literally just tried this | ||
moritz | Ulti: would it help you if I gave you admin privs? | 14:03 | |
Ulti | :S perhaps | 14:04 | |
moritz | Ulti: what's your wordpress user name? | 14:05 | |
14:05
telex left
|
|||
Ulti | though it's perhaps a better plan if I get some crappy wordpress.com blog to play in and work it out first | 14:05 | |
moritz matteoates | |||
moritz | Ulti: ok, you should be admin now | 14:06 | |
14:07
araujo joined,
araujo left,
araujo joined
14:19
kaare_ left,
Mouq joined
14:32
telex joined
14:33
Celelibi joined
|
|||
Ulti | uh oh | 14:38 | |
yeah I think its more this version of wordpress is some funky one specific to wordpress.com like all the stuff you might want to change and use ask you to pay £70 a year | 14:40 | ||
smls | :( | 14:41 | |
Does it at least allow inline style="" attributes? | 14:42 | ||
Ulti | not sure | ||
smls | Did you test if <style> elements are stripped even when posting as admin? | 14:43 | |
14:45
blackbolt left
|
|||
Ulti | yeah they are | 14:45 | |
15:03
spider-mario joined
15:06
anaeem1_ joined,
anaeem1_ left
15:07
anaeem1_ joined
15:10
atroxaper left
15:12
Mouq left
15:16
anaeem1_ left
15:22
anaeem1 joined
|
|||
masak | m: role A {}; role B does A {}; multi foo(A) { say "A" }; multi foo(B) { say "B" }; foo(B.new) | 15:22 | |
camelia | rakudo-moar dfcf9f: OUTPUT«B» | ||
masak | m: role A {}; role B is A {}; multi foo(A) { say "A" }; multi foo(B) { say "B" }; foo(B.new) | ||
camelia | rakudo-moar dfcf9f: OUTPUT«Ambiguous call to 'foo'; these signatures all match::(A):(B) in sub foo at /tmp/wV8QRUJXF6:1 in block <unit> at /tmp/wV8QRUJXF6:1» | ||
masak | oh, maybe that makes sense. | 15:23 | |
"is" on a role means something like "compose at the last minute". | |||
15:26
FROGGS left
|
|||
tadzik | I just noticed that Supply.act is pretty much what Steroid's event system is doing | 15:26 | |
yoleaux | 7 Dec 2014 01:37Z <raydiak> tadzik: sent you a PR for panda, s:g/path/IO/ | ||
tadzik | raydiak: oh, thanks :) Will look at it later today | ||
15:26
psch joined
15:27
muraiki left
|
|||
psch | hi #perl6 \o | 15:28 | |
yakudza | \o | 15:29 | |
hoelzro | jnthn: sounds good, thanks! | 15:30 | |
yoleaux | 10:01Z <jnthn> hoelzro: I'd suggesting giving make_where_block a third optional argument, which defaults to QAST::Var.new( :name('$_'), :scope('lexical') ), and then pass in the QAST tree to make it do $_.signature where you are calling it. | ||
15:32
muraiki joined,
KCL_ joined,
kaare_ joined
15:36
perltricks joined
|
|||
perltricks | hey y'all is there a way to capture stderr from qx//? | 15:41 | |
lizmat | good *, #perl6! | 15:46 | |
did pl6anet.org fall out of DNS ? | |||
moritz | I get connection resets from the DNS servers | 15:49 | |
pyrimidine | Anyone else seeing NativeCall test fails on OS X? | 15:54 | |
gist.github.com/cjfields/bd7682e80c679eb1a49c | |||
lizmat sees many tests flapping on OS X, period :-( | 15:55 | ||
15:58
ptc_p6 joined,
treehug88 joined
|
|||
pyrimidine | lizmat: :( indeed | 15:59 | |
16:02
FROGGS joined
16:04
skarn joined
16:06
Lasse_ left,
ptc_p6 left
16:07
ptc_p6 joined
16:09
denis_boyun joined
|
|||
El_Che spend the day configuring a nice perl5 soft that really could use p6 threading :). The soft is single threaded on a single cpu. Making it scale takes some work. Happy it works :) | 16:09 | ||
brrt is still looking for a way to run a recent darwin on virtualbxo | |||
16:09
NotJAck joined
|
|||
brrt | virtualbox | 16:09 | |
16:10
NotJAck is now known as NotJack
|
|||
psch | is there a different name for the colonpair on a used module's name without a space in contrast to with? | 16:11 | |
i.e. "use Foo :<Bar>;" vs "use Foo:from<java>;" | |||
i'd happily call the left one an adverb, but not the right one | |||
Ulti | pyrimidine: yes | 16:12 | |
psch | ah, S11 calls it an adverb as well | 16:13 | |
Ulti | the same error here on OSX 10.9.5 | ||
16:13
rurban joined
|
|||
psch | that does seem somehow lacking to me, but i guess it's the space or lack of space which changes whether we're changing what's used vs how we use | 16:13 | |
pyrimidine | Ulti: was planning on an initial run at NativeCall implementation of htslib/samtools when I have time. Kinda puts a kink in that :P | 16:14 | |
Ulti | :[ | ||
16:15
ptc_p6 left
|
|||
Ulti | yeah I was going to try and get SQUID bindings as a demo, but I think your plan is more useful | 16:15 | |
pyrimidine | squid would be nice and probably simpler | 16:16 | |
Ulti | erk it fails even more on Linux for me | 16:17 | |
this is with Rakudo-m from today | |||
might be a better plan to use an actual release I guess | 16:18 | ||
brrt hasn't seen great linux-related failures yet | |||
but i haven't checked today either | |||
nickpatch | howdy all! | 16:20 | |
i made a new p6 module Geo::Region: github.com/patch/geo-region-pm6 | |||
masak | nickpatch! \o/ | ||
nickpatch: add it to the ecosystem? | |||
nickpatch | masak: already done! | ||
ported it from p5, so i would love any feedback on the code or api in regards to p6ishness | 16:21 | ||
16:24
kaleem left
|
|||
lizmat | nickpatch: the only thing that seemed a bit non-optimal, are the "contains" and "is_within methods | 16:25 | |
(also is-within maybe?) | |||
seems like an awful lot of work to be done to get a boolean | |||
16:25
digitalw00t joined
|
|||
digitalw00t | ? | 16:25 | |
lizmat | otoh, it's only done once, right? | ||
digitalw00t | Morning | ||
lizmat | digitalw00t /o | ||
Ulti | nickpatch the long list of constants could maybe be an enum | 16:28 | |
colomon | nickpatch: I've been fighting with Unicode (for $work rather than p6) since Thursday. And as long as you're here: utf16 in wchar_t on Linux: Wrong or Very Very Wrong? | 16:29 | |
Ulti | nickpatch: perlcabal.org/syn/S12.html#Composit...from_Pairs | ||
16:29
KCL_ left
|
|||
TimToady | STD calls foo:bar<baz> a longname | 16:30 | |
Ulti | that way you have typeness and you dont pollute the namespace of someone using the module and you get helper methods like .invert | ||
dalek | kudo/newio: 6b53d38 | (Tobias Leich)++ | src/core/CompUnitRepo/Local/Installation.pm: fix last .IO.path.basename leftover |
16:31 | |
kudo/newio: 4a9ebae | (Tobias Leich)++ | src/core/CompUnitRepo.pm: fix CompUnitRepo.files When asking for an installed file (i.e. a script) then we basically ask for a filename, and optionally for distname/auth/version. In contrast to asking for packages where we tend to ask for packagename, and optionally for a filename/auth/version. |
|||
kudo/newio: 8a9791d | moritz++ | Configure.pl: Configure: warning on missing --prefix option requested for star in rakudo/star#40, and added here for consistency |
|||
kudo/newio: dfcf9fc | moritz++ | src/core/Exception.pm: Preserve warning message "0" |
|||
kudo/newio: bef54c7 | (Elizabeth Mattijsen)++ | / (4 files): Merge branch 'nom' into newio |
|||
16:32
atroxaper joined
|
|||
psch | TimToady: i'll call the parameter to use a "longname consisting of the module name and a colonpair" then, thanks | 16:32 | |
16:34
brrt left
16:35
mr-foobar joined
|
|||
colomon | nickpatch++ # making patches to Geo::Region as I'm reading the source. :) | 16:35 | |
nickpatch | lizmat: is_within is now is-within | ||
colomon: yay! :D | 16:36 | ||
lizmat: and what do you think in non-optimal? suggestions otherwise? | 16:37 | ||
16:38
atroxaper left
|
|||
nickpatch | Ulti: i'll look into p6 enums. ty | 16:38 | |
raydiak | gmorn #perl6 | 16:40 | |
masak | good antipodal morning, raydiak :) | ||
16:41
anaeem1 left,
Exodist joined
|
|||
nickpatch | colomon: i'm such not a C programmer that i won't be much help with wchar_t | 16:42 | |
raydiak | heh good diametric evening, masak \o | ||
NotJack | is there a deeper writeup somewhere on what "native shaped arrays" are? | 16:44 | |
for mortals, I mean | |||
PerlJam | NotJack: Ever used PDL in P5? | 16:45 | |
NotJack | nope | ||
colomon | nickpatch: ok. I will continue to consider it Wrong but not actually flame the programmers responsible. ;) | ||
16:46
khisanth_ is now known as Khisanth
|
|||
TimToady | S09 is the best we have on native shaped arrays, so far | 16:46 | |
NotJack | thanks, I'll go refresh on that | 16:47 | |
TimToady | but since they're not implemented yet, most everything there is subject to change | ||
NotJack | TimToady: Yeah, the reason I ask is because they're called out specifically as one of the last TODOs for a p6 launch | ||
TimToady | though the design does seem largely implementable | ||
NotJack | also, because I'm interested in anything novel p6 has to offer in the way of arrays and collection processing | 16:48 | |
TimToady | jnthn is working on the underpinnings of that | ||
16:53
zakharyas left
|
|||
NotJack | is prefix<||> a thing yet? | 16:54 | |
that looks neat | |||
p6: say 'hi'; | 16:55 | ||
camelia | rakudo-{parrot,moar} dfcf9f: OUTPUT«hi» | ||
NotJack | p6: @shape = 4, 2; say ||@shape; | ||
camelia | rakudo-{parrot,moar} dfcf9f: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileVariable '@shape' is not declaredat /tmp/tmpfile:1------> @shape⏏ = 4, 2; say ||@shape; expecting any of: postfix» | ||
16:55
spider-mario left
16:56
mvuets left
|
|||
NotJack | p6: my @ints[4;2]; my @shape = 4,2; say @ints[||@shape]; | 16:56 | |
camelia | rakudo-{parrot,moar} dfcf9f: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfileShaped variable declarations not yet implemented. Sorry. at /tmp/tmpfile:1------> my @ints[4;2]⏏; my @shape = 4,2; say @ints[||@shape];» | ||
NotJack | wait, wait, "shaped arrays" means "arrays of a fixed size"? | ||
ah, that clears it up then | |||
PerlJam | well, "shaped" also means "smooth or bumpy" to me. | 16:57 | |
(sparse arrays, arrays that are indexed on non-integer things, etc.) | 16:58 | ||
NotJack | Ok, I get it now. | ||
17:01
vti left
17:11
rurban1 joined
17:12
skarn left
|
|||
NotJack | Do non-fixed-sized multidim arrays exist? | 17:17 | |
NotJack should go back and read the perl6 book | |||
moritz | NotJack: yes, but rakudo's support for them is very thin | 17:20 | |
TimToady | basically, only multidimensional subscripts are supported currently, but they only work on arrays of arrays and such | 17:22 | |
17:25
tinyblak_ left,
pmurias joined
|
|||
pmurias | one hard problem I have in nqp-js, is how to compile subs that can be called before their surrounding scope come into existance. | 17:27 | |
example: XYZ::foo(); module XYZ { my $x; our sub foo() {...} } | 17:28 | ||
TimToady | make a stub that says "I don't exist yet!" ? | 17:29 | |
kurahaupo | isn't the real problem the initialization of $z in pmurias' example? | 17:30 | |
$x I mean | 17:31 | ||
17:31
anaeem1_ joined
|
|||
pmurias | with ... being for example '$x := 123' | 17:31 | |
TimToady | the call doesn't and shouldn't know what foo cares about later | ||
17:31
digitalw00t left
|
|||
TimToady | it just needs to fail gracefully until there really is a foo | 17:31 | |
moritz | pmurias: compile to a lookup by name(s) | 17:32 | |
TimToady | that also works, but might run slower | ||
kurahaupo | the same problem exists in p5 of course. it'd be nice to solve it | ||
17:34
virtualsue left
|
|||
TimToady | m: XYZ::foo(); module XYZ { my $x = 21; our sub foo() { say $x * 2 } } | 17:34 | |
camelia | rakudo-moar dfcf9f: OUTPUT«use of uninitialized value of type Any in numeric context in sub foo at /tmp/kBr9FfxGLt:10» | ||
TimToady | ah, module isnt' initialized yet | ||
m: XYZ::foo(); module XYZ { our $x = 21; our sub foo() { say $x * 2 } } | 17:36 | ||
camelia | rakudo-moar dfcf9f: OUTPUT«use of uninitialized value of type Any in numeric context in sub foo at /tmp/HpOyvbwrzs:10» | ||
TimToady | now that one's incorrect, since it should initialize $x at INIT time | ||
probably a known rakudo bug | |||
m: XYZ::foo(); module XYZ { constant $x = 21; our sub foo() { say $x * 2 } } | |||
camelia | rakudo-moar dfcf9f: OUTPUT«42» | ||
TimToady | yes, our is initializing too late | ||
if someone wants to doublecheck that we're testing for that, that'd be LHF | 17:38 | ||
17:38
denis_boyun left
|
|||
TimToady | to check, not to fix :) | 17:38 | |
moritz | what exactly is initialized at INIT time? all our-scoped vars? | 17:40 | |
17:41
Mouq joined
17:42
immortal joined,
immortal left,
immortal joined
|
|||
kurahaupo | so ... initializations won't be able to call yet-to-be-defined subs? | 17:43 | |
17:44
erkan left
|
|||
mathw | Sorry to barge in, but how do I read a single character from the console? | 17:44 | |
or rather, from stdin | |||
kurahaupo | oh, wait | ||
INIT, not BEGIN | 17:45 | ||
moritz | mathw: $*IN.getc | ||
17:45
skarn joined
|
|||
pmurias | TimToady: re fail gracefully, so is it safe for subs that depend on variable from scope that don't exist yet to fail gracefully? | 17:45 | |
17:45
adu joined
|
|||
kurahaupo makes note to self: actually *drink* wakeup coffee before chatting on irc | 17:46 | ||
mathw | moritz: thanks! | ||
pmurias | TimToady: for example stuff like XYZ::foo(); for @foo -> $x { my $z = $x+1; module XYZ { our sub foo {$z = 7;say $z;}} | 17:47 | |
m: XYZ::foo(); for 1,2 -> $x { my $z = $x+1; module XYZ { our sub foo {$z = 7;say $z;}}} | 17:48 | ||
camelia | rakudo-moar dfcf9f: OUTPUT«7» | ||
17:51
gfldex joined
|
|||
pmurias | moritz: if I need to support things like that, the best solution I have found (and used in the previous nqp-js) is to compile the subs twice | 17:51 | |
17:53
xinming left
17:54
xinming joined
17:55
pmurias left
17:58
denis_boyun_ joined
|
|||
nickpatch | Ulti: how does this look? github.com/patch/geo-region-pm6/compare/enum | 18:01 | |
not sure if i did the organization and naming the most p6ish or not | 18:02 | ||
18:02
telex left,
dakkar left
18:03
anaeem1_ left,
vendethiel joined
|
|||
TimToady | if Region is exported, you shouldn't need to qualify with Region:: after the enum is imported | 18:06 | |
(unless there's an enum collision somewhere) | |||
nickpatch | TimToady: i would like that but it didn't work | 18:07 | |
TimToady | mebbe it's a bug | 18:08 | |
m: module Foo { enum Bar is export <a b c> }; import Foo; say b | 18:09 | ||
camelia | rakudo-moar dfcf9f: OUTPUT«===SORRY!=== Error while compiling /tmp/8rz6t_Q8YoUndeclared routine: b used at line 1» | ||
TimToady | yeah, bug | ||
m: module Foo { enum Bar is export <a b c> }; import Foo; say Foo::b | |||
camelia | rakudo-moar dfcf9f: OUTPUT«b» | ||
mathw | "Slurpy positionals with type constraints are not supported." aaaw :( | ||
TimToady | it's impossible to guarantee the type of a lazy list at bind time unless we have manifest list types on the list being passed, which we don't currently | 18:12 | |
we are not Haskell :) | |||
(currently :) | |||
mathw | well, can't have everything | 18:13 | |
I was getting a little carried away perhaps | |||
TimToady | we still have some difficulty implementing time travel, for some reason :) | ||
we could conceivably wrap the list iterator with a lazy type check, but that'll generally be redundant with something in your routine anyway, and just slow things down | 18:15 | ||
and only blow up just before the routine would anyway | |||
18:15
telex joined
|
|||
TimToady | so when we do enable slurpy types, it will probably be to require arguments that can be known at compile time to be of that type | 18:17 | |
mathw | yes probably best to let the existing run-time type failure code catch it rahter than adding more | ||
18:17
Mso150 joined
|
|||
TimToady | but that means inferring types through .list calls, likely | 18:17 | |
and type inference is probably post-6.0, if we ever decide to do it | 18:18 | ||
18:19
kaare_ left
|
|||
TimToady | the basic problem with type inference is that it tends to require your user to be as smart as your compiler | 18:19 | |
18:19
Hor|zon left
|
|||
TimToady | especially if your compiler is stupid about error messages, and just says "That can't possibly work." without saying why | 18:20 | |
mathw | my problem with languages that do have type inference (other than stupid error messages) is when people then say "isn't this cool! We never need to mention types at all!" without realising apparently that from time to time it is good if your code does actually say what type things are expected to be | 18:21 | |
TimToady | or if does explain it, but the explanation requires a graduate degree in mathematics | ||
18:21
kaare_ joined
|
|||
TimToady | yes, there's that failure mode as well | 18:22 | |
so I'm guess we'd enable it technically, but try not to overdo it culturally | |||
*guessing | |||
18:23
anaeem1 joined
|
|||
TimToady | sort of like with extensibility, we provide all the tools, then given them a language they mostly won't want to extend :) | 18:23 | |
*give | 18:24 | ||
mathw | well these library authors always want to extend things... | ||
TimToady | can't type toady... | ||
don't they just | |||
mathw | extensibility is great, it's an admission also that you don't know everything today | ||
so you give people tools to help add some of the things they know they need next week | |||
a lack of extensibility being a major failing of many languages | 18:25 | ||
IMO anyway |