»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend!
Set by masak on 12 May 2015.
00:00 Psyche^_ joined, stmuk joined 00:01 zacts joined 00:03 kid51 joined 00:04 Psyche^ left
Hotkeys aw there was a lot of line ending commits 00:04
was hoping one would fix windows repl
MadcapJake what's the preferred panda module way of locating the path to a `so` file?
00:08 TrES2b left
psch .oO( party extraction and reporting language..? ) 00:08
Hotkeys: i have a suspicion that if you change src/core/IO/Handle.pm:24 to < :$nl-in is copy = ["\r\n", "\x0A"] > the windows repl might work 00:10
Hotkeys also psch I haven't tried linenoise
psch Hotkeys: i don't think that's a likely fix to arrive in the mainline though
Hotkeys because panda refuses to build
i.imgur.com/QJZjjRl.png 00:11
JSON gets angry
psch that's a bit spooky
might be related to the same order-mismatch for line endings though
Hotkeys maybe
psch i have no idea how much jnthn++ tests his win build against the ecosystem
Hotkeys it does build fine on old version 00:12
the one before the breakage
but not sure if it is the same problem
psch well
"can't parse objects starting at <\r\n> yet" somehow looks very similar :P
s/ yet/yet
Hotkeys oh 00:13
I didn't even think about that being a \r\n
psch ...and s/at/in/
Hotkeys I was wondering why the message looked so strange
00:16 Ven_ joined, Ven left
psch fwiw, i really don't feel like trying to set up a build env on windows 00:16
00:18 FROGGS joined
Hotkeys I had to install VS2010 00:19
after trying all of the later versions
it was quite a hassle
psch ...yeah :P 00:20
Hotkeys although rakudobrew makes everything after that :D 00:21
makes everything easy *
psch i am rather comfortable with building rakudo tyvm :P 00:22
00:22 retupmoca joined
Hotkeys lol 00:22
psch anyway, yeah, aside from trying to change that line in IO/Handle.pm i don't have any immediate ideas
Hotkeys but if I did that I would have to manually build
psch i'd have to dig into all the nl handling code, and i'm not sure i wanna do that in the near future
Hotkeys I guess I could do that
wait can rakudobrew build from a local thingy 00:23
psch as mentioned, the repl is kind of a low-ish impact feature currently, considering much of the language still needs fixes
hrm, well, maybe not "much", but "significant pieces", maybe
Hotkeys right 00:24
I just hope it
psch i think you can just cd into the local rakudobrew checkout and run the config.status that hangs around there..?
Hotkeys ll get accidently fixed
psch no clue how you run a text file as "this is a commandline" on win though :P
00:24 Ven_ left
psch if nothing else you should be able to copy the content out of it and enter it on the cli :P 00:25
00:25 khw joined
TEttinger psch: I do that all the time 00:25
newlines are new commands
00:25 lsm-desktop joined
AlexDaniel .u ∘ 00:26
yoleaux U+2218 RING OPERATOR [Sm] (∘)
psch TEttinger: i don't think i follow, you do what all the time?
dalek kudo/nom: 5ffd01f | TimToady++ | src/ (2 files):
allow traits to join the $*BORG
ast: 059757b | TimToady++ | S32-exceptions/misc.t:
fix over-specific borg error checker
00:27
Hotkeys I'll give changing the handle.pm thing a shot 00:28
MadcapJake how would I go about locating the filepath of a C library and passing that path to a bunch of `pm6` files? Will perl6 get upset if I have a circular dependency? 00:41
TimToady m: sub foo is export{}; foo();
camelia rakudo-moar 5ffd01: OUTPUT«5===SORRY!5===␤Trait 'is export' needs whitespace before block␤at /tmp/bG8cGwhgfP:1␤------> 3sub foo is export{}7⏏5; foo();␤Missing block (apparently claimed by 'is export')␤at /tmp/bG8cGwhgfP:1␤------> 3sub foo is export{};7⏏5 f…»
TimToady .tell Skarsnik I fixed your 'is export{}' LTA message. 00:43
yoleaux TimToady: I'll pass your message to Skarsnik.
MadcapJake I get the syntax, but what's the idiomatic perl6 way of organizing that? Do I put it in my toplevel module (wouldn't that be a circular dependency?) or I've seen some modules havea BUILD.pm file, how would I use that technique to load a path into some module files? 00:44
(Most Build.pm files are used to build C files, but I am just looking to access a C library)
00:46 Peter_R left
MadcapJake when I try and type `is native('libfluidsynth') for it says it can't locate it so I made a sub that would return the exact path to my `so` file on my machine. but I want to make it dynamically load for every user and each module file needs to have access to this sub. 00:46
00:48 FROGGS left 00:50 FROGGS joined
psch MadcapJake: can't you use Build.pm to write a package that exports the users path to libfluidsynth and import that package in your module? 00:50
psch doesn't really know much about Build.pm
MadcapJake How come some modules can just type `libssl` or `libSDL` into the native trait and it Just Works™? 00:52
Hotkeys "Receiving objects: 36% (19924/54131), 40.32 MiB | 89.00 KiB/s"
jeez
gonna be here all night
01:00 yqt left 01:01 cygx joined
cygx MadcapJake: it Just Works when the library has been installed somewhere the loader looks by default 01:02
on WIndows, that includes anything in PATH
01:06 sufrostico left
MadcapJake cygx: any idea where it looks on linux? 01:09
01:10 polettix left
TimToady cygx: by the by, there's already a 32x32 camelia at raw.githubusercontent.com/perl6/mu...elia32.ico 01:13
cygx TimToady: it was less about the icon and more about generating PNG from a text-based format 01:14
MadcapJake: LD_LIBRARY_PATH, /lib, /usr/lib and such 01:15
konobi lo 01:16
Hotkeys psch: I tried the fix you suggested but it didn't help 01:18
it was worth a shot though 01:19
psch Hotkeys: well, in that case it's probably beyond what i can figure out without building on win myself 01:20
and i really don't feel up to that
Hotkeys I might keep fiddling since building manually isn't as spooky as I thought
psch Hotkeys: it seems to be about nqp confusing the line endings, from a distance 01:21
Hotkeys: as in, if you can figure out how exactly the code that check whether we want \n or \r\n acts, you might able to figure it out 01:22
well, except if there's a hangup with grapheme composition of \r\n into \n somewhere, that might take a bit more work...
(that's all talking from a "i don't really know how this works" POV though...)
01:23 aborazmeh joined, aborazmeh left, aborazmeh joined
Hotkeys its okay I also have no idea how itworks 01:23
01:23 sprocket left
psch hm, nqp::getstdin simply gets the stdin_handle from the tc 01:25
maybe it just doesn't remember it has to check different line endings..?
oh
or it could be a bug in libuv
'cause apparently tc->instance->stdin_handle is a uv_stream_t
01:26 MacroniSalad joined
psch Hotkeys: well, i'm confident you can figure it out :P 01:26
Hotkeys: just keep bashing your head against the code base, it's what i usually do and it seems to work quite well ;)
zengargoyle MadcapJake: nativecall should *just* work with native('libfoo') if libfoo.(so|dll) is installed where the system expects it. 01:27
or with native('libfoo.so.2') for that matter, but that seems to only match that one thing and not do .dll like searching # as i grok it. 01:28
Hotkeys psch: i'm not so confident :p
zengargoyle the native(&library) thing when i first saw it was for things that built their own library and installed it along with the .pm6 file
Hotkeys I might wait til i get home to bash my head into the codebase 01:29
cause it's hard to think about problems while also absorbing lecutre info
zengargoyle and had the need to search for the actual path where it is finally installed to be able to load it.
psch Hotkeys: yeah, lecture probably should come first
Hotkeys I can do code monkey testing in lecture but actually thinking doesn't work as well 01:30
zengargoyle did this for Algorithm::Trie::libdatrie but hasn't released the version that builds its own library yet.
cygx 'night, #perl6 o/
01:30 abaugher left 01:31 nys left, cygx left, abaugher joined
zengargoyle and if you use LibraryMake, it has a couple of functions to help with that. so you end up with something like Find::Bundled.find("libfoo$so") and the $so is the .so / .dll depending on your system 01:33
and it can look in the place the module was installed and then on down the path to where the system usually installs things.
there's also LibraryCheck which helps a bit. 01:34
01:34 abaugher left
zengargoyle thinks there should eventually be a NativeCall tutorial of some sort. it took like a day of digging to figure all this out... 01:34
01:36 abaugher joined
zengargoyle for your case, i'd make a: module Module::Base { sub library() is export returns Str { code to find library } } 01:37
and then: use Module::Base; in your other modules and use is native(&library). 01:38
01:45 BenGoldberg joined
MadcapJake zengargoyle: thanks! That's a great tip! 01:52
MadcapJake goes off to implement Audio::Fluid::Base
01:53 tokuhiro_ joined
MadcapJake how do I keep all my classes in separate files while still allowing users to just type `use Audio::Fluid;` to get access to them all? 01:54
is that handled automatically or do I need to specify a `Fluid.pm6` file just for that?
psch MadcapJake: you need an 'Audio::Fluid', but that can just import and reexport stuff from lower in the same namespace 01:55
MadcapJake ok got it, thanks!
psch i feel like being explicit about it being fluidsynth is useful, tbh 01:56
'cause i at least expect the module name to be expressive, and i don't know what fluid audio would be :S 01:57
fluidsynth otoh i already know about
but that's just my perspective, take that as you will
MadcapJake ok I just didn't want to have `Audio::FluidSynth::Synth` but I guess it's better to have recognition
psch yeah, i'd go with Audio::FluidSynth as the package users usually use 01:58
MadcapJake ok will do!
psch "use" as in "use Audio::FluidSynth"
konobi who's in charge of the build/test infrastructure 01:59
skids of rakudo? 02:00
psch konobi: travis integration on github runs basic integration (i.e. "does it build")
konobi: [Coke]++ regularly upload summaries of roast against daily snapshot of rakudo
konobi psch: mkay... if I was able to get a couple of additional hosts to add to the testing matrix, who should I talk to? 02:01
psch konobi: you're talking about testers.perl6.org? 02:02
that's the module-level testing
konobi: afaik, we don't really have a dedicated daily roast run, which i think you're trying to help provide 02:03
i think [Coke] runs it semi-manually, but you'd have to ask them if you want to be sure 02:04
so, yeah, that's probably who you should talk to :)
konobi psch: mkay... well, I may hopefully have an illumos host or two available for longerterm use
flussence psch: parrot used to have a webapp thing for collecting spectest results, and I had a cronjob run it daily. Don't think anyone cared as much back then but I could put it back on if there were a new place to upload them to. 02:06
psch flussence: afaik, the spot to upload them to would be github.com/coke/perl6-roast-data nowadays 02:08
flussence: although we have testers.perl6.org, so something similarly fancy for spectest results might be decent dogfood target...
flussence: no idea if that still fits your scope though 02:09
flussence, konobi: for the latter afair FROGGS++ wrote testers
tbh, i'd kinda want a travis-y fail safe, 'cause i know it happens to me that i occassionally forget running spectest after pushing a change 02:10
and having something around that says "hey, this commit cause failures here" would be neat, although i'll admit i have no real clue about how much work is involved there 02:11
...i'm not sure how far to push this though
there was talk about backend-specific branches and auto-merging into the mainline after a successful (or maybe non-regressive) spectest 02:12
but we still have flappers in a few async tests, so maybe we're not quite yet at a spot where that's actually useful anyway
s/running spectest after/running spectest before/ # uhm... 02:13
konobi: i just saw illumos is OpenSolaris. i have no idea in how far that already works, although i'd expect "generally yes" 02:15
i don't know how different things are there, i'm pretty linux-centric.. 02:16
anyway, i need to get some rest o/
konobi psch: i've been working on moarvm build on illumos
psch: but it's basically Solaris... but with gnu tooling 02:17
02:18 advwp left
konobi (since sunstudio is closed) 02:18
02:19 isacloud_ joined 02:20 FROGGS left
flussence wonder if rakudo would build on this RPi 1 I've got sitting around... I could definitely leave that running a testing cronjob 02:20
02:20 Celelibi left, isacloud_ is now known as isacloud 02:21 Celelibi joined, Juerd_ joined, BenGoldberg left, Juerd_ is now known as Juerd 02:22 BenGoldberg joined, Actualeyes joined 02:23 flussence joined 02:25 xpen joined, SmokeMachine joined 02:28 mephinet left 02:29 mephinet joined, geraud left 02:30 Ben_Goldberg joined, BenGoldberg left 02:31 AlexDaniel left 02:32 pdcawley joined 02:36 moznion left, g4 left 02:37 xdbr left 02:38 psch joined 02:42 DrForr_ joined, petercom1and joined 02:43 ponbiki_ joined
dalek kudo/nom: bcebf8e | TimToady++ | src/core/ (5 files):
implement put sub/method

This is like 'say' insofar as it adds newline, but like 'print' insofar as it has .Str semantics instead of .gist.
02:43
02:44 moznion joined, g4 joined, silug joined, robinsmidsrod joined, hoelzro joined, rhr joined, ponbiki joined, krakan joined, bitmap joined, petercommand joined, Bucciarati joined, skaji joined, DrForr joined, xdbr joined, petercommand left, Bucciarati left, DrForr left, ponbiki left, xdbr left 02:45 xdbr joined, ilbot3 left, olinkl joined, petercom1and left, petercom1and joined 02:46 petercom1and is now known as petercommand, roguelazer joined 02:47 ilbot3 joined, Bucciarati joined 02:48 advwp joined 02:52 kid51 left
grondilu TimToady: have you considered 'disp' instead of 'put' for this semantics? 03:00
(or anything else) 03:01
TimToady put is the opposite of get, and disp means too many other things 03:05
03:06 raiph joined 03:07 BenGoldberg joined
[Coke] yawns 03:07
03:07 Ben_Goldberg left
[Coke] Have you considered making say do what put does, and making put do what say does? ;) 03:10
03:10 BenGoldberg left
flussence $*OUT.disp doesn't roll off the tongue... 03:10
03:11 BenGoldberg joined
TimToady [Coke]: yes, I did, in fact 03:11
but print and put both begin with 'p', and 'put' and 'say' are both 3 letters, so put is obviously the intersection of them :)
MadcapJake Is there a dynamic variable that can tell me if a user is on a 64 or 32 bit OS? 03:14
lizmat m: say $*KERNEL.bits 03:15
camelia rakudo-moar bcebf8: OUTPUT«64␤»
lizmat MadcapJake ^^^
llfourn sheds a tear at the beuty of that
beauty :\ 03:16
MadcapJake cool, thought maybe that was inside $*DISTRO or $*VM, couple useful ones inside $*KERNEL
m: say $*KERNEL.^methods
camelia rakudo-moar bcebf8: OUTPUT«(BUILD name version release hardware arch bits signals signal Str gist <anon> <anon> <anon>)␤»
lizmat m: say $*KERNEL.hardware # source of .bits: $!bits //= $.hardware ~~ m/_64|w|amd64/ ?? 64 !! 32; 03:17
camelia rakudo-moar bcebf8: OUTPUT«x86_64␤»
llfourn m: $*KERNEL.panic
camelia rakudo-moar bcebf8: OUTPUT«Method 'panic' not found for invocant of class 'Kernel'␤ in block <unit> at /tmp/6RKEPH6Cb4:1␤␤»
llfourn :( NYI?
MadcapJake whats the difference between .hardware and .arch? I get the same result on my machine ("x86_64") 03:19
lizmat it's all heuristics that's still in flux
flussence maybe for arm, where you can compile things a zillion different ways for one cpu type... 03:20
MadcapJake oi, that sounds lovely
lizmat is tired and goes to bed
zengargoyle not sure if it comes from the `uname` like source.
lizmat zengargoyle: look at src/core/Kernel.pm
good night, #perl6! 03:21
llfourn o/
flussence o/
zengargoyle kernel, machine, hardware, os, all of those things tend to differ on even Linux machines by distro, even moreso going to Solaris.
flussence I wonder if the values differ for running an i686 kernel on a 64-bit cpu.
(not sure if there's even a sane way to detect that...) 03:22
zengargoyle $WORK has a large-ish shell script that does many things to get a final description of uname like info.
yeah, uname 03:23
03:24 kaare_ joined
MadcapJake doesn't even know what any of the x86 variations mean 03:24
03:26 raiph left
flussence there's i386, some numbers between that and i686 (=anything with MMX) that few people use, some numbers *after* that one even less used, then it jumps straight to x86_64 and everyone seemingly gave up making up subarch names after that (thankfully) 03:26
zengargoyle and some use amd64 instead 03:27
and some i86pc
MadcapJake well i have a phenom II x6 which I thought would be amd64 but it's x86_64 apparently 03:28
zengargoyle they're the same.
MadcapJake oh, ok that's good xD 03:29
zengargoyle IIRC it's more about whether Intel or AMD got the first chip out. 03:30
ShimmerFairy AMD's version of 64-bit x86 won because it was backwards-compatible with the old x86, as I recall
Intel came up with a new and incompatible variant that is certainly in use, but I imagine the "can't run old 32-bit applications on it" thing kept it from "winning" :) 03:31
MadcapJake I'm just thankful I bought an AM3+ board a few years back, FX series AMD CPUs are still in production! That'll be quite the upgrade when I can pony up the cash. From my meager 2.8GHz 6 cores to 4.0 GHz 8 cores in the top-of-the-line FX CPU. I wonder if I'll have to reinstall linux, anyone ever upgraded a CPU without reinstalling their OS? Is it possible? 03:32
timotimo yeah, that's the ia64 thingie
flussence it can run them, they're just emulated at speeds rakudo-on-parrot could run rings around :)
timotimo ShimmerFairy: did you see i commented on a MoarVM github issue that you started?
ShimmerFairy oh, no, let me check :)
timotimo Hotkeys, psch, i'd very much accept a pull request to add explody tests to JSON::Fast about the newline stuff! 03:33
so if you can figure out what exact text gets passed to it there, that'll be a good start
probably just a comma followed with \r\n
ShimmerFairy timotimo: I haven't seen those memory issues lately either, so I'll get around to updating and running a new spectest at some point to make sure :)
flussence MadcapJake: it'll work fine, as long as you don't have anything compiled with -march=native or the like (because newer AMD chips got rid of 3dnow instructions entirely) 03:34
timotimo ShimmerFairy: i'd prefer not having an open bug for that unless it's somewhat reliably reproducible, so feel free to close the bug if you're not confident in its reproducibility 03:35
MadcapJake ok, then i'm good! if it does crash, it'll be a good excuse to jump from ubuntu to fedora though. xD 03:36
timotimo i'll head to bed now
ShimmerFairy timotimo: it looked like you closed it already
timotimo oh?
OK, so change that to: if you can reliably reproduce that bug, re-open the issue %)
anyway, ttyl!
ShimmerFairy will do :) 03:38
03:40 aborazmeh left 03:51 doublec_ joined 03:52 BenGoldberg left, doublec left, BenGoldberg joined
Hotkeys I still don't know exactly why the repl is breaking never mind json::fast 03:52
03:53 BenGoldberg left 03:54 BenGoldberg joined
ugexe if you're still talking about windows i thought its been said a few times its that newlines (and hence .lines etc) aren't properly handled yet 03:58
yoleaux 12 Nov 2015 21:33Z <mrf> ugexe: PR made with full passing tests and new RFC additions
ugexe do my $proc = run "git", "ls-files", :out; say $proc.out.lines; on windows and see what it outputs 03:59
its one long string with \n between everything
04:00 eternaleye left, eternaleye joined, sitaram joined, sitaram left 04:02 sitaram joined 04:05 colomon left
Hotkeys ugexe: I know that it's new lines I just don't know ehere it breaks 04:05
like in what file(s) and where in it/them 04:06
somewhere in nqp
ugexe i imagine the results from greping 'readline' on the nqp repo are a pretty good idea 04:07
theres not too many 04:08
04:08 kaare_ left
ugexe my guess would be github.com/perl6/nqp/blob/master/s...r.nqp#L397 04:15
04:15 doublec_ is now known as doublec
ugexe i think it should work if that is replaced with $?NL or whatever 04:17
er nqp wont have $?NL will it
04:18 BenGoldberg left 04:20 colomon joined 04:24 sprocket joined
MadcapJake what is the numbering scheme used by some people for their test files? It doesn't seem to be the number of tests. 04:26
ugexe they are supposed to get run in alphabetical order by file name unless otherwise specificed 04:27
so a lot of people do ##-some_name.t 04:28
MadcapJake oh, some people use a single number, some people use a leading zero number, others just name it however
ugexe right, or they leave some free numbers for extra tests that might need to be run towards the start/end
i.e. tests 10-start.t and 20-end.t 04:29
MadcapJake ohh, that makes sense, that's why there are missing numbers, xD
ugexe later i can add 19-almost_end.t
MadcapJake ugexe: thanks! that's been bugging me for a while :P
ugexe you can stop looking for goat #3 now heh 04:30
04:35 raiph joined 04:45 Oatmeal joined, Oatmeal left 04:50 dayangkun joined 05:15 raiph left 05:18 khw left 05:33 sprocket left
grondilu stumbled upon masak's "Javascript has already won" talk. Fascinating stuff. 05:47
(all the more reason to look forward to pmurias's work) 05:48
05:50 skids left
llfourn grondilu: thanks I hadn't seen this one... 05:55
06:37 domidumont joined 06:43 domidumont left
dalek kudo/nom: 06c0c53 | TimToady++ | src/core/ (6 files):
use --> True where appropriate
06:43
06:54 domidumont joined, domidumont left 06:59 jsimonet joined 07:01 polettix joined, polettix left 07:05 diana_olhovik_ joined
[Tux] good morning *6 07:19
07:22 adhoc left 07:28 adhoc joined
[Tux] test 50000 21.186 21.073 07:29
test-t 50000 17.626 17.513
Text::CSV = 17.6, CSV::Parser = 25.7 # tony-o tempted? 07:30
which means the currently Text::CSV is the fastest (and most versatile) CSV parser for perl6 :) :) 07:32
07:34 RabidGravy joined 07:35 MacroniSalad left 07:37 rindolf joined 07:44 quester joined 07:46 FROGGS joined 07:54 brrt joined, Averna joined, dayangkun left
moritz \o/ 07:59
07:59 Averna left 08:00 virtualsue joined 08:01 cosimo joined, darutoko joined
RabidGravy marnin 08:03
making test data on the sofa at 8 in the morning - living the dream 08:17
gfldex m: say Nil ~~ List; sub is-nil-a-list-or-not(--> List){Nil}; is-nil-a-list-or-not().WHAT.say; 08:18
camelia rakudo-moar 06c0c5: OUTPUT«False␤Nil␤»
moritz Nil and derived classes (like Failure) are an exception to return type checking 08:20
I guess that should be documented somewhere :-)
08:21 cbk left 08:22 cbk joined
gfldex m: sub foo([] --> ()){}; foo().WHAT.say; 08:26
camelia rakudo-moar 06c0c5: OUTPUT«5===SORRY!5=== Error while compiling /tmp/3jEQG4WjwS␤Malformed return value␤at /tmp/3jEQG4WjwS:1␤------> 3sub foo([] -->7⏏5 ()){}; foo().WHAT.say;␤»
gfldex can Perl 6 return the empty list from a --> definition for me?
moritz m: sub foo([]) --> []) { }; say foo([]).perl 08:29
camelia rakudo-moar 06c0c5: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0EPwQIro9h␤Missing block␤at /tmp/0EPwQIro9h:1␤------> 3sub foo([])7⏏5 --> []) { }; say foo([]).perl␤ expecting any of:␤ new name to be defined␤»
moritz m: sub foo([] --> []) { }; say foo([]).perl
camelia rakudo-moar 06c0c5: OUTPUT«5===SORRY!5=== Error while compiling /tmp/avySa8LffL␤Malformed return value␤at /tmp/avySa8LffL:1␤------> 3sub foo([] -->7⏏5 []) { }; say foo([]).perl␤»
gfldex m: sub foo([] --> List.new){}; foo().WHAT.say; # kinda LTA
moritz huh
camelia rakudo-moar 06c0c5: OUTPUT«5===SORRY!5=== Error while compiling /tmp/GT0SCbM3pn␤Type 'List' is not declared␤at /tmp/GT0SCbM3pn:1␤------> 3sub foo([] --> List7⏏5.new){}; foo().WHAT.say; # kinda LTA␤»
08:29 abraxxa joined
TimToady m: sub foo(--> Empty){}; foo().WHAT.say; 08:30
camelia rakudo-moar 06c0c5: OUTPUT«(Slip)␤»
08:31 abraxxa left, abraxxa joined
moritz m: constant EmptyList = (); sub foo( --> EmptyList ) { }; say foo().^name 08:32
camelia rakudo-moar 06c0c5: OUTPUT«List␤»
moritz m: constant EmptyList = (); sub foo( --> EmptyList ) { }; say foo().perl
camelia rakudo-moar 06c0c5: OUTPUT«()␤»
08:33 zakharyas joined 08:34 ely-se joined 08:53 pecastro joined
llfourn m: say Nil ~~ List; sub is-nil-a-list-or-not(--> List:D){Nil}; is-nil-a-list-or-not().WHAT.say; 08:57
camelia rakudo-moar 06c0c5: OUTPUT«False␤Nil␤»
08:57 zakharyas left
llfourn m: sub foo(--> Str:D) { Nil }; foo; 08:58
camelia ( no output )
llfourn I swear I have gotten the message for a return type "Expecting Str but got Nil".... 08:59
gfldex The Perl 6 Book will have a whole chapter trying to explain why Nil isn't the undefined value :-> 09:00
m: say Nil.Str; 09:01
camelia rakudo-moar 06c0c5: OUTPUT«Use of Nil in string context in block <unit> at /tmp/qGQIEV264e:1␤␤»
gfldex m: printf("%s", Nil); 09:02
camelia rakudo-moar 06c0c5: OUTPUT«Use of uninitialized value of type Any in string context␤Any of .^name, .perl, .gist, or .say can stringify undefined things, if needed.␤Use of uninitialized value of type Any in string context␤Any of .^name, .perl, .gist, or .say can stringify undef…»
Ulti I have to confess I have no idea what Nil is for given you have all the type objects?
llfourn It's to set a value to something so if that value is used it throws an exception. Or at least that's the way I think of it. 09:03
Ulti I use Any like undef
gfldex if you ask for the weather forcast it's a big difference if someone tells you, he doesn't know the weather forcast or simply doesn't give you any answer 09:04
llfourn mmm yeah it's not meant to be undef
Ulti llfourn then what's fail/failure for?
llfourn Util: when you want to attach a message to that exception
Ulti :S 09:05
ok
llfourn this is simply the way I understand it :P
Ulti I think Nil maybe suffers from being close to null from other languages
gfldex Nil means: this function was asked for a return value but didn't provide one 09:06
Failure.new is a value
llfourn I learned the other day that you can also use it in default values for :D attrs
m: class A { has Str:D $.a = Nil }; say A.new; 09:07
camelia rakudo-moar 06c0c5: OUTPUT«A.new(a => Str:D)␤»
gfldex m: say Failure ~~ Nil; say Failure.new ~~ Nil;
camelia rakudo-moar 06c0c5: OUTPUT«True␤True␤»
gfldex m: say Failure.new.defined; say Nil.new.defined; 09:11
camelia rakudo-moar 06c0c5: OUTPUT«False␤False␤»
09:34 kjs_ joined 09:36 polettix joined 09:38 pmurias joined 09:43 Skarsnik joined 09:44 kjs_ left 09:58 quester left 10:06 zakharyas joined
jnthn morning, #perl6 10:06
ooh, no messages :)
10:09 doublec_ joined
DrForr_ Must be ready for release :) 10:10
SHIP IT!
10:10 doublec left
pmurias jnthn: morning 10:11
RabidGravy the weather just went downhill rapidly 10:12
10:15 telex left 10:16 telex joined
jnthn RabidGravy: So...good news for coding? :) 10:21
RabidGravy At some point need to go to farm shop and buy vegetables 10:22
:-\
masak the vegetables will be juicier due to the precipitation 10:23
10:23 pecastro left 10:25 doublec joined 10:26 doublec_ left
masak alright, who wants to contact 0.30000000000000004.com/ to add Perl 6 to that list? :) 10:27
stmuk RabidGravy: I thought the only vegetables you liked were barley and hops! 10:28
masak .oO( graaaaaaains )
El_Che Does the default new for a class not catch "invalid" attributes? class foo { has $.bar }; Foo.new(bartypo => "foo") 10:30
jnthn No
masak this is something of a FAQ
jnthn Note that methods in general quietly discard unused named parameters, so it's consistent 10:31
El_Che mm
it will consistently lead to annoying bug
s
10:31 sprocket joined
masak El_Che: don't worry, the "it shold warn/error" school of thought has a sizeable following. :) 10:32
llfourn $.bar is required can help if it's appropriate
RabidGravy if it concerns you make multi variants with required named params
masak but I've never heard a cogent argument *against* S12's "Interface Consistency" 10:33
El_Che well, actually, it's worse than that
whay if I think I provide a optional attribute?
llfourn yes obviously that will be a problem :)
jnthn Method calls are *generally* more late-bound/sloppy. This is at the same level of "what if I typo the method name", and the answer is things like "we cope with this issue because we like the late binding overall" and "we write tests" 10:37
pmurias m: class Foo {has $!attr};Foo.new(attr=>23)
camelia ( no output )
10:37 doublec_ joined
RabidGravy m: 'sub foo(:$foo, *%bits where *.keys.elems == 0) { }; foo(foo => 1, bar => 1) 10:38
camelia rakudo-moar 06c0c5: OUTPUT«5===SORRY!5=== Error while compiling /tmp/gM6DHDBT7s␤Unable to parse expression in single quotes; couldn't find final "'" ␤at /tmp/gM6DHDBT7s:1␤------> 3elems == 0) { }; foo(foo => 1, bar => 1)7⏏5<EOL>␤ expecting any of:␤ sing…»
RabidGravy m: sub foo(:$foo, *%bits where *.keys.elems == 0) { }; foo(foo => 1, bar => 1); # even
camelia rakudo-moar 06c0c5: OUTPUT«Constraint type check failed for parameter '%bits'␤ in sub foo at /tmp/czlROiJ7x7:1␤ in block <unit> at /tmp/czlROiJ7x7:1␤␤»
RabidGravy there, problem solved
jnthn But subs check for you by default
:-)
10:38 doublec left
llfourn RabidGravy: that's cool! 10:38
jnthn But yes, you can do that. 10:39
(For methods)
RabidGravy for methods, yes, but I haven't cranked up the typing foo
Woodi hallo #perl6 :)
RabidGravy marnin 10:40
Woodi is node.js a new PHP ? 10:41
RabidGravy it would be cool to be able to alter the "Constraint type check failed for parameter ... " message
Woodi, no
eiro is it a spotted friday troll ? :)
hello everyone
Woodi o/ :)
masak Woodi: no.
eiro there is no "new php", there is php7 10:42
masak heiro \o
pmurias is glad he doesn't have to work on rakudo-php
El_Che jnthn: let agree in principle and disagree in practice :)
masak pmurias: :D
eiro masak, i miss you! tell me you'll be at fosdem ?
masak eiro: I wish I were. :/ 10:43
Woodi I don't mean: on lobal scale... so interned post-PHP will be more divided ?
RabidGravy even on a personal level, I dislike PHP intensely but have used node.js/javascript without wanting to break things
Woodi *global there...
masak eiro: deprioritizing fun confs right now, and prioritizing fun @family :)
10:43 TEttinger left
RabidGravy masak++ # damn right 10:44
llfourn whenever I had to dp PHP I always tried to turn everyhing into a client side problem so I could use JS
Woodi what Perl6 in web page means ? <script>v6-code</script> ?
eiro masak++ # damn damn right
masak Woodi: that does seem like the literal meaning, yes. 10:45
Woodi masak: do this require to download megabytes of js code ? :) or just once ? 10:47
masak Woodi: I suppose the runtime would be a big one-time overhead. probably clever things with caching can be done there to make it a one-time cost. 10:48
s/one-time//
El_Che Like MS office that preloads at boot time? :) 10:49
RabidGravy oooh bind_one_param is a bastarding big sub isn't it 10:51
jnthn Yes. 10:52
Thankfully we compile most signatures and so don't hit it 10:53
10:54 sprocket left 10:55 pecastro joined
Woodi so DBIish::Driver::Native::XxSql changed to DB::XxSql ? 10:57
pmurias masak: caching the runtime is one option, other is some sort of tree pruning like dart uses 11:00
masak pmurias: not-famous-for-its-performance basically-deprioritized-in-favor-of-js Dart?
11:02 polettix left
Skarsnik hm how do I pass the --prefix for Configure.PL with rakudowbrew? rakudobrew build moar --prefix=/opt/ does not work ~~ 11:03
yoleaux 00:43Z <TimToady> Skarsnik: I fixed your 'is export{}' LTA message.
11:03 cosimo left
Skarsnik and hello ^^ 11:03
.tell TimToady thx for fixing is export{ message 11:04
yoleaux Skarsnik: I'll pass your message to TimToady.
Woodi one nice side effect of XS-things in Perl5 was that DBI was central API. but with with more human oriented ffi's we can have usable raw, low-level XxSql APIs; nice for "special" databases features
11:04 luiz_lha joined 11:05 luiz_lha is now known as Guest36546, llfourn left
pmurias masak: Dart is both compiled to js and has it's own VM 11:07
masak pmurias: "tree shaking" seems to make a lot of sense, though.
in fact, I don't see why a codegen step of any kind shouldn't do that.
pmurias masak: the performance of dart-compiled-to-js is as far as I know awesome
masak it's just dead code elimination, no?
Woodi but it allows "I want my own DBI!"... in Perl5 it was "impossible" and all creativity was redirectet on top of DBI. so database interface was "clear"... 11:08
pmurias masak: I think so
Skarsnik Ok resolved my configure issue ^^ 11:09
pmurias masak: dart2js has near javascript performance on most benchmarks and they even beat idiomatically writen js on some of them
masak pmurias: that's nice. 11:11
pmurias: I think I would rather write Dart than ES5.
pmurias: but then again, I'd rather write TypeScript than Dart. 11:12
pmurias it's likely a reason they have up on the Dart VM as the dart2js performance was good enough
or is Google backing up out of Dart as whole too?
11:55 ilogger2 joined, ChanServ sets mode: +v ilogger2 12:13 ilogger2 joined, ChanServ sets mode: +v ilogger2 12:26 ilogger2 joined, ChanServ sets mode: +v ilogger2
masak RabidGravy: I find I use it quite a bit in MAIN sometimes. 12:27
timotimo Skarsnik: it's build-panda, not build panda 12:30
build panda would look for a branch or tag named "panda" inside rakudo
Skarsnik but I get the same error x)
timotimo huh.
maybe it's time for a rakudobrew nuke :D
tadzik no no
'build panda' is a special case
timotimo oh?
yay for special cases >_>
tadzik it's equivalent to build-panda
Skarsnik It's a fresh install, I just rakudobrew build moar-vm. but a quick look at the script. It does not seem it look at PATH to find perl6. I think it assume it's in the default path rakudobrew build-moar build 12:31
but I make it install in /opt/
12:37 ilogger2_ joined, kid51 joined
dalek kudo/nom: 1704b92 | jnthn++ | tools/build/NQP_REVISION:
Bump for multi cache with `is rw` support.
12:38
12:39 AlexDaniel joined
dalek kudo/nom: 4e3eab6 | peschwa++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Don't bypass multicache for rwness-aware multis.

This commit (and branch) depend on MoarVM pull request #291, and can be merged whenever that PR gets merged (or something equivalent implemented).
12:40
kudo/nom: f3e960e | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Merge branch 'for-mvm-pr291' into nom
ast: c9874ca | jnthn++ | S06-multi/by-trait.t:
Optimizer stress test for `is rw` on multis.
12:45
moritz 0.30000000000000004.com/ anybody want to submit a pull request explaining Perl 6's behavior?
timotimo i'm surprised php does it right
moritz I'm nearly sure it just truncates the digits, just like python and perl 5 do by default
tadzik . o O ( for any value of it )
moritz php5 -r 'echo .1 + .2 == .3;' 12:46
no output (which means false)
in comparison, php5 -r 'echo 1 + 2 == 3;' prints 1
timotimo then it should say something to that effect under the result 12:47
moritz $ php5 -r 'printf("%.17f\n", .1 + .2);' 12:48
0.30000000000000004
timotimo can't have php look better than perl5 on such a website, now can we :P 12:49
masak "look better" is a bit subjective here :)
timotimo hah
masak 0.3 is a short-sighted lie
0.30000000000000004 is an uncomfortable truth
12:58 kid51 left
moritz very much prefers Perl 6's comfortable truth 12:58
timotimo :)
masak I believe Perl 6 and the Scheme dialects on that pages can bask in that comfortable truth together.
lizmat good *, #perl6!
masak page*
12:58 sufrostico joined
timotimo "but omg performance dood" 12:58
masak good ⁂, lizmat!
timotimo: "I don't care about the answer, I just want it *fast*!"
lizmat masak o/
masak \✺
lizmat hates it being called at 4:30 am by a telemarketeer
masak minds less than he thought being woken up at 05:00 by a cheerful 10mo cherub next to him
jnthn hates being called by a telemarketer
jnthn mostly hates being called on the phone at all, though
masak hates phones
moritz masak: being woken by a cheerful child isn't all that bad; it's when they're screaming that the un-fun starts
masak moritz: agreed. screaming: not as fun.
jnthn Things I don't use my smartphone for much: phone calls :)
moritz especially since daughter no. 2 currently thinks that seeing her daddy makes her situation worse, not better
masak phone calls, also known as "unsolicited requests for instantaneous communication by analog audio"
moritz ... without a proper spam filter
masak moritz: oh? it's, like, a phase?
moritz masak: I hope so :-)
masak :) :/
$cherub always brightens up when daddy materializes. I kinda enjoy that.
lizmat All tests successful.
Files=1073, Tests=50172, 236 wallclock secs (13.14 usr 3.91 sys + 1438.40 cusr 136.73 csys = 1592.18 CPU) 12:59
of course, the telemarketeer thought it was 10:30 am, but still.... :-)
m: say True.pick # this is a bug, right ? 13:04
camelia rakudo-moar f3e960: OUTPUT«Cannot call pick(Bool: ); none of these signatures match:␤ (Bool:U $: *%_)␤ (Bool:U $: $n, *%_)␤ in block <unit> at /tmp/lUZCd0b9kD:1␤␤»
lizmat m: say False.pick # and this
camelia rakudo-moar f3e960: OUTPUT«Cannot call pick(Bool: ); none of these signatures match:␤ (Bool:U $: *%_)␤ (Bool:U $: $n, *%_)␤ in block <unit> at /tmp/M8tdyb_l5f:1␤␤»
ilmari m: say Boo.pick
camelia rakudo-moar f3e960: OUTPUT«5===SORRY!5=== Error while compiling /tmp/llODY5txtM␤Undeclared name:␤ Boo used at line 1␤␤»
ilmari m: say Bool.pick
camelia rakudo-moar f3e960: OUTPUT«False␤»
jnthn m: enum A <b c>; say A.pick
camelia rakudo-moar f3e960: OUTPUT«b␤»
lizmat yea, that works
jnthn m: enum A <b c>; say b.pick
camelia rakudo-moar f3e960: OUTPUT«(b)␤»
lizmat it only blows on True/False
jnthn Yeah, thing so, but I suspect it may go away once nine++'s "make bool more of an enum" work lands
*think
lizmat ah, didn't know he was doing that
can we do that, though?
I mean, Bool being something from BOOTSTRAP ?
jnthn Apparently, given his branch has got most of the way there ;)
Like most bootstrapping things, it's possible, but you'll probably bash your head against the problem for a while. :)
lizmat m: sub a(--> True) { 42 }; say a # this is not an error, or a bug, but a feature ? 13:07
camelia rakudo-moar f3e960: OUTPUT«True␤»
DrForr_ lizmat: Did you get out of FRA?
lizmat DrForr_: yes, on just about the *only* LH flight out of FRA
13:07 loren joined
timotimo it's a feature as far as i know, lizmat 13:07
lizmat is it a new feature? it's new to me :-)
loren evening, #perl6..
timotimo i think it's half a year old
lizmat ok, must have missed the memo. Cool!
timotimo :) 13:08
i think mister toady built it in
lizmat so this works on Bool / Nil only, right ?
masak lizmat: I'd say it's a bug that it doesn't fail at runtime. 13:09
lizmat m: sub a(--> True) { 0 }; say a #
camelia rakudo-moar f3e960: OUTPUT«True␤»
jnthn m: sub answer(--> 42) { }; say answer
camelia rakudo-moar f3e960: OUTPUT«42␤»
timotimo masak: i think annotating with a value overrides the "return last value of block" thing
lizmat m: sub a(--> Int) { 42 }; say a #
camelia rakudo-moar f3e960: OUTPUT«42␤» 13:10
lizmat doesn't look like it ?
jnthn masak: If you put a concrete value there, you're saying "use this as the return value"
timotimo that's not a value, that's a type :)
masak er.
is that in the spec?
jnthn masak: If you put a type there, you're saying "check it against this type"
Yes
masak ok, then.
jnthn Because there's tests for it. :)
masak heh :)
lizmat aha, it's the concreteness
jnthn Think TimToady++ implemented it.
masak my intuition goes against it, mostly because I think of the signature as more declarative than that. 13:11
but I'll accept it and see what happens ;)
jnthn You're declaring the return value :)
lizmat m: sub a(--> True) { fail }; say a #
camelia rakudo-moar f3e960: OUTPUT«Failed␤ in sub a at /tmp/MZX0gma02P:1␤ in block <unit> at /tmp/MZX0gma02P:1␤␤Actually thrown at:␤ in block <unit> at /tmp/MZX0gma02P:1␤␤»
lizmat m: sub a(--> True) { Failure.new }; say a #
camelia rakudo-moar f3e960: OUTPUT«Failed␤ in block <unit> at /tmp/u6vRAPTGik:1␤␤Actually thrown at:␤ in sub a at /tmp/u6vRAPTGik:1␤ in block <unit> at /tmp/u6vRAPTGik:1␤␤»
masak I think I half-remember the spec commit that went in for this... 13:18
and yes, it was part of the whole loops-at-the-end thing.
lizmat m: sub a(-->Nil) { Any }; say a # so Nil is considered a concrete value
camelia rakudo-moar f3e960: OUTPUT«Nil␤»
masak it's kind of both a concrete value and a type, I guess.
"singleton type"
13:18 kolikov joined
kolikov Hi Perl6 ! 13:18
masak hiya kolikov!
14:12 ilogger2 joined, ChanServ sets mode: +v ilogger2 14:20 pmurias_ joined
dalek kudo/nom: 0418755 | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Fix multi-dispatch failure over non-rw.

Failure to multi-dispatch should consistently report themselves as such.
14:25
14:50 tokuhiro_ joined 14:54 tokuhiro_ left
dalek kudo/nom: f6b74c4 | peschwa++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Micro-opt rwness check.

We don't really need an array there if we don't care what exactly failed, and we don't care what exactly failed because we aren't throwing Parameter::RW.
14:57
ast: e1b0e58 | peschwa++ | S06-multi/by-trait.t:
Include a native rw candidate in rwness-aware MMD.
ast: 93736e7 | peschwa++ | S0 (3 files):
Expect Multi::NoMatch instead of Parameter::RW on multis.

cf. Rakudo commit 0418755.
jnthn psch: Do the tests you added in e1b0e58 already pass? 14:58
14:59 RabidGravy joined
dalek ast: b0d0779 | peschwa++ | S06-multi/by-trait.t:
Correct test message.
14:59
RabidGravy rarr!
psch jnthn: yes
jnthn oddness
m: multi x(int $x is rw) { 1 }; multi x(Int $x) { 2 }; say x(1) 15:00
camelia rakudo-moar 041875: OUTPUT«1␤»
psch jnthn: yes, i saw that too
jnthn That doesn't work
Compiling a patch for that at the moment
psch jnthn: that's again the inlining magic isn't it?
as in, if we actually use the param it inlines differently or somesuch
m: multi x(int $x is rw) { $x; 1 }; multi x(Int $x) { $x; 2 }; say x(1)
camelia rakudo-moar 041875: OUTPUT«2␤»
jnthn Yeah but...wtf 15:01
15:02 loren joined
jnthn It just tried to say "ok, never compile-time multi dispatch if there's an is rw multi candidate" 15:02
And it still goes off and does it anyway :/
huh, and it does it with optimization off?!
oh, no, now I busted the other test :/ 15:04
psch jnthn: generated protos always pass a capture, which trial_bind always lets through 15:05
well, i'm sure about the latter part 15:06
not sure about generated protos, actually
15:07 polettix joined
AlexDaniel m: has $var 15:11
camelia rakudo-moar f6b74c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/2NKELZN3lE␤You cannot declare attribute '$var' here; maybe you'd like a class or a role?␤at /tmp/2NKELZN3lE:1␤------> 3has $var7⏏5<EOL>␤ expecting any of:␤ constraint␤»
AlexDaniel or maybe I want to use “my” instead? :)
psch right, Actions.autogenerate_proto adds a single capture proto 15:12
15:13 pippo joined
jdv79 how can a Seq have been iterated when i just created it ^H^H 15:13
jnthn psch: Yeah, I think the issue is that the multi-dispatch analysis is actually picking the wrong candidate.
jdv79 wonders ^H
psch jnthn: yes, analyze_dispatch can't check the containerness of the argument
AlexDaniel m: my Int Str $var;
camelia rakudo-moar f6b74c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/QtuQ02LKsB␤Multiple prefix constraints not yet implemented. Sorry. ␤at /tmp/QtuQ02LKsB:1␤------> 3my Int Str7⏏5 $var;␤»
psch jnthn: 'cause it doesn't get any flags for that
AlexDaniel wow! It is supposed to work!
El_Che I am kind of confused by private atributes as explained in doc.perl6.org/language/objects#Attributes. I fail to call them from a method in the same class:
m class Foo { has $.attr; method run(){ say $.attr } }; my $foo = Foo.new(attr=>'bar'); $foo.run()
dmanbar
damn
I mean: 15:14
m: class Foo { has $.attr; method run(){ say $.attr } }; my $foo = Foo.new(attr=>'bar'); $foo.run()
camelia rakudo-moar f6b74c: OUTPUT«bar␤»
El_Che so that ok, but this:
jnthn m: multi x(int $x is rw) { 1 }; multi x(Int $x) { 2 }; my int $i = 1; say x 1
camelia rakudo-moar f6b74c: OUTPUT«1␤»
El_Che m: class Foo2 { has $!attr; method run(){ say $!attr } }; my $foo = Foo2.new(attr=>'bar'); $foo.run()
camelia rakudo-moar f6b74c: OUTPUT«(Any)␤»
jnthn psch: I've got a patch making ^^ be 2 locally
psch: Without breaking type.t and by-trait.t in S06-multi 15:15
El_Che so a method in the same class can not use a private attribute? It looks like I do something wrong
kolikov Ok done comit for Lingua::EN::Conjugate ... Note: Perhaps it would bee good to add this link: github.com/perl6/ecosystem to doc.perl6.org/language/modules ?
psch jnthn: neat. i couldn't figure that out, mostly got stuck in Optimizer.analyze_args_for_ct_call
jnthn Took me a couple of goes...
Will have to spectest it
psch well, i'm curious to see it :) 15:16
jnthn Added it to S06-multi/by-trait.t too
RabidGravy El_Che, if you want the constructor to be able to set the private attributes then you need to provide a BUILD method. They are after all "private"
15:17 polettix left
El_Che so private does not mean class private 15:17
kolikov My wrong, link already there ... friday 13th is a bad day for me :(
15:17 loren left 15:18 rindolf joined
jnthn El_Che: You can't set privates using the default constructor 15:18
Ah, RabidGravy was faster
El_Che jnthn: thx 15:19
sorry for the silly question. Just going through the doc while rewriting some code to p6
RabidGravy El_Che :
m: class F { has $!foo; submethod BUILD(:$!foo) { }; method say-foo() { say $!foo } }; F.new(foo => "boom").say-foo
camelia rakudo-moar f6b74c: OUTPUT«boom␤»
15:19 polettix joined
jnthn El_Che: The design guide for $!foo attrs is that you should be able to rename any of them inside of the class, and not break anything. 15:20
El_Che it makes senseeeeeeee
oops
minus some e s
thx for the code, RabidGravy 15:21
15:21 sprocket joined
RabidGravy but my dumb way of looking at is that the new() is called on the type object and the setting of the attributes is done on a newly created object, so in the context of the constructor they are still private 15:22
the BUILD submethod is called on the newly created object so (being the same object) the method is "internal" so you can set the private attributes 15:24
El_Che Don't you declare something prive (e.g. in other languages), to *use* in the same class? The empty submethod feels like some extra plumbing
(looking at it from a user's point of view)
RabidGravy using the private attribute name in the signature is the special sauce there 15:25
moritz actually not special
it just falls out of signature binding
15:25 softmoth_ joined
zengargoyle the BUILD submethod keeps you from having to write a new and worrying about super classes and such. 15:26
jnthn El_Che: The problem isn't your using the private thing in the class, it's expecting the default constructor will let it be set from the outside. 15:27
pippo m: grammar G {rule TOP { ^^<one> <two> <three>$$}; rule one {one}; rule two {two}; rule three {three}}; say G.parse("one two three").values; 15:29
camelia rakudo-moar f6b74c: OUTPUT«(「two」 「three」 「one」)␤»
RabidGravy anyway on a completely different note, I had the first Shepherd & Neame Christmas Ale of the year just now, last couple of years they've made a rather wussy one in the "session beer" category, but this one is back to normal at a proper full-blooded 7% :)
pippo ^^ that was returning them in the order they were put in TOP rule. What has changed now? 15:30
psch pippo: the order should never have been reliable there 15:31
pippo: it's a hash, and those only accidentally are ordered sometimes
pippo psch: It was until recently. sigh!
psch m: grammar G {rule TOP { ^^<one> <two> <three>$$}; rule one {one}; rule two {two}; rule three {three}}; say G.parse("one two three").caps>>.value # gives them ordered by .from
camelia rakudo-moar f6b74c: OUTPUT«(「one」 「two」 「three」)␤»
RabidGravy If you want the order to be reliable you need to create an action class that has a means to stash them away in the order they are seen 15:32
timotimo hashes used to be implemented with some extra code to provide ordering in MoarVM, but that code was ripped out quite some time ago
psch we still have a few tests that only fail because of hash ordering :/
timotimo so they were ordered, but not because we wanted them to, just because that's what the implementation for hashes we used had
15:32 lichtkind joined
pippo psch: TY! I'll use caps as in your ex. 15:33
timotimo "we"?
RabidGravy checks
dalek osystem: f9e057a | kolikov++ | META.list:
Please Add Lingua::EN::Conjugate

See github.com/kolikov/perl6-Lingua-EN...jugate.git
RabidGravy nope nothing to do with me ;-)
dalek osystem: 701c89b | (Steve Mynott)++ | META.list:
Merge pull request #91 from kolikov/kolikov-add1

Please Add Lingua::EN::Conjugate
psch r: my @a; @a[0]:zip:zop # this, S32-array/adverbs.t 15:34
camelia rakudo-jvm f6b74c: OUTPUT«2 unexpected named arguments passed (zip, zop)␤ in block <unit> at /tmp/tmpfile:1␤␤»
..rakudo-moar f6b74c: OUTPUT«Unexpected named parameter 'zip' passed␤ in block <unit> at /tmp/tmpfile:1␤␤»
psch although moar here throws only one unexpected named...
dalek kudo/nom: c96dedd | jnthn++ | src/Perl6/ (2 files):
Fix rw handling in compile time dispatch.

We could accidentally let literals match an `is rw`.
jnthn psch: We tend to bail on first problem. 15:35
dalek ast: b738dd0 | jnthn++ | S06-multi/by-trait.t:
Test for a `is rw` dispatch bug.
15:37
psch m: my @a; @a[*]:kv:zip:zop # ah here 15:38
camelia rakudo-moar f6b74c: OUTPUT«2 unexpected adverbs (zip zop) and unsupported combination of adverbs (kv) passed to slice on @a␤ in block <unit> at /tmp/94tTRpNONO:1␤␤Actually thrown at:␤ in block <unit> at /tmp/94tTRpNONO:1␤␤»
psch ah, but we sort those now in X::Adverb
so yeah, the test got corrected that way and doesn't actually fail anymore 15:39
jnthn OK, I think we've got is rw in multi dispatch in good enough shape
jnthn had hoped that'd be "review patches, apply, close ticket" :)
psch ...i tried :P 15:40
dalek kudo/nom: f0c6a02 | lizmat++ | src/core/ (4 files):
Get some crazy optimizations, timotimo++

  irclog.perlgeek.de/moarvm/2015-11-13#i_11531889
15:41
zengargoyle bit again by the 'hit space and loose your place' feature of the docs.
jnthn psch: You got it much of the way :-) 15:42
RT resolved 15:43
psch jnthn: yeah, things like the opt you made of my moar patch i'm ok with not having known in advance...
jnthn psch++ # helping get another xmas RT nailed
psch similarly with the literal stuff
sprocket hello #perl6!
15:43 rurban joined
sprocket i’m wondering if there might be somewhere i could submit a nifty perl6 article to in the next couple weeks. i’m using p6 and a raspberry pi to run my greenhouse irrigation controller (ie. turning on/off water in different zones, turning on/off heating, monitoring water usage, detecting leaks/blockages) 15:45
psch sprocket: perl6advent would be nice i guess 15:46
jnthn sprocket: Wow, cool! :)
dalek osystem: 799f586 | (Zoffix Znet)++ | server/updatelist.pl:
Handle "https.git" case in URL normalization
jnthn Yes, that would make an excellent advent calendar post. 15:47
PerlJam indeed
sprocket just to give myself a deadline, when does the advent start up? :)
PerlJam sprocket: Advent is Dec 1 - Dec 24
colomon sprocket: Dec 1st, natch
sprocket great, ok
i’ll follow up closer to the date then :) 15:48
PerlJam sprocket: do you have a wordpress account?
colomon sprocket++
psch sprocket: pick a date between 2nd dec and 25th dec, that's your publishing date :P
PerlJam sprocket: if not, give me an email address I can send the invite to
dalek href="https://modules.perl6.org:">modules.perl6.org: 974451a | (Zoffix Znet)++ | web/lib/P6Project/Info.pm:
Handle "https.git" case in URL normalization
15:49
jdv79 sprocket: how long does it take to compile?
sprocket start up take a loooong time 15:50
(or are we talking compiling rakudo?)
15:50 Ven joined
PerlJam sprocket: (wordpress account for the Perl6 advent calendar that is) 15:51
RabidGravy sprocket, I was meaning to ask you - does your RPi module enable I2C over the gpio or would one need to make something over the top of it> 15:52
sprocket rabidgravy: that’s coming, i’d just got the bare bones going for what i’d needed
RabidGravy I'd like to make a P6 version of my Device::PiLite module but am aftaid of the yaks
cool, cause I gotta have my blinken lights 15:53
15:54 ZoffixW joined
[Coke] We should probably start soliciting advent posts in general. about that time. 15:54
ZoffixW zengargoyle, what do you mean 'hit space and loose your place'?
zengargoyle, where, on the docs.perl6.org?
RabidGravy actually it's not PiLite that uses the i2c that's serial it's the other thingy with the spiral arms of multi-coloured LEDs
jdv79 compiling rakudo. but now that you mention it what is the startup delay?
ZoffixW [Coke], I was only joking about DBD::CSV BTW :) And nice to see someone started Text::CSV. I don't think it was there just a few weeks ago.
RabidGravy Device::PiGlow 15:55
sprocket jdv79: in terms of compiling rakudo, i don’t recall - i just let it do its thing in the background and went to have dinner, or some other task :)
|Tux| ZoffixW, I started in October 2014
sprocket jdv79: let me fire up to test the start up delay
15:56 Calibellus joined
jdv79 i thought it was running your greebnhouse or something 15:56
[Coke] Use of Nil in numeric context in method new at /Users/williamcoleda/perl6/share/perl6/site/lib/HTTP/Response.pm6:27
ZoffixW |Tux|, 0.o hm... what I recall seeing is a mention that Text::CSV is needed and me thinking "man, that would be a large project, so not for me"... Maybe I'm thinking of some other language heh
sprocket jdv79: it is; i have another pi on my desk right here that i use or dev/testing 15:57
|Tux| define *large* :)
sprocket jdv79: 0m48.905s for start up 15:58
zengargoyle ZoffixW: it's that the Search box is selected by default. if you're scrolling through reading docs and then hit space for the next page, BAM you're back at the top of the page with a space in the Search box and a dropdown of all the entries with a space in them.
ZoffixW |Tux|, well, P5's Text::CSV_XS has tests that run for like 2 minutes and many of them are about all sorts of edge cases :) Not something I'd want to deal with :P
zengargoyle, aha! I can fix that :)
[Coke] mmm. I think my original request of "/" to focus on the search box is better, and used on many sites these days. :| The autofocus was a compromise on that. 15:59
zengargoyle i don't know if it's just me, or maybe everybody else expects/likes the Search activated...
psch doesn't like pages autofocusing textboxes
PerlJam Coke++ I'd rather "/" to focus as well.
ZoffixW [Coke], I'm gonna de-focus it if the user scrolls down a bit
zengargoyle brilliant 16:00
ZoffixW++
ZoffixW What sites use "/" to focus stuff? First time I hear of that.
psch i'd also dislike '/' for searchbox focus, 'cause i use that instead of F3 for searching on the page
zengargoyle well firefox automatically uses / to search in page. 16:01
hoelzro o/ #perl6 16:02
|Tux| CSV.pm has 1663 lines, the current test suite 2747 lines
RabidGravy someone who remembers Lotus 1-2-3 probably thought of that / thing 16:03
AlexDaniel Oh, by the way, is it possible to add search query #like_this? 16:05
16:05 zengargoyle joined
jnthn m: use Test; class A { multi method foo($a) { "general" }; multi submethod foo(Str $a) { "specific" } }; class B is A { }; is B.new.foo("OH HAI"), 'general', 'multi submethod ignored on call on subclass'; 16:05
camelia rakudo-moar f0c6a0: OUTPUT«not ok 1 - multi submethod ignored on call on subclass␤␤# Failed test 'multi submethod ignored on call on subclass'␤# at /tmp/EOJfqi2IHz line 1␤# expected: 'general'␤# got: 'specific'␤»
AlexDaniel so that you can link it this way: modules.perl6.org/#test
16:06 sufrostico joined
ZoffixW AlexDaniel, that's already implemented in the mojo-app branch 16:06
modules.perl6.org/q/test
AlexDaniel, I plan to have it ready sometime this weekend. 16:07
RabidGravy anchors would be cool though too
16:07 rurban left 16:08 Ven left, pmurias_ left, kjs_ joined
ZoffixW RabidGravy, what for? 16:08
kjs_ m: say .1 + .2 16:09
camelia rakudo-moar f0c6a0: OUTPUT«0.3␤»
RabidGravy for sharing the link without having to do a query or anything
kjs_ time to add an entry for Perl 6 to 0.30000000000000004.com/
RabidGravy it would be trivial to add an anchor to each row 16:10
16:10 skids joined
ZoffixW
.oO( PHP does it right? 0.o )
16:10
kjs_ ZoffixW: see the footnote ;-)
ZoffixW RabidGravy, yeah and about 6KB of markup :P
kjs_ PHP converts 0.30000000000000004 to a string and shortens it to "0.3".
ZoffixW RabidGravy, I rather use the "query thing" that will show a single module instead of linking to one that might not even end up at the top. 16:11
RabidGravy I actually have no strong opinion on the matter 16:12
16:12 Ven joined
AlexDaniel kjs_: are you going to do this? :) 16:13
kjs_ AlexDaniel: there’s already a pull request for the P6 version i see
AlexDaniel kjs_: it is not mergeable though 16:14
kjs_ 11 other pull requests - getting a lot of attention from redditers i think
AlexDaniel ah right, 27 minutes ago
kjs_ i’d say they’re on top of it
AlexDaniel attention from redditers? That's a really old website… 16:15
ZoffixW There are actually 2 PRs for P6 :) #11 and #44 They went through 33 Issues/PRs in 6 hours 0.o
kjs_ hadn’t seen it before
Skarsnik hm I was looking at adding write support on Config::INI. how about rewrite it to be like search.cpan.org/~rsavage/Config-Tin...ig/Tiny.pm ; basicly it give an object that act like a hash of hash where you can call .read and .write to read/write the file 16:18
dalek kudo/nom: bbad114 | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Multi submethods should not "inherit".

There were a few ways we could have implemented this. The solution in this patch is to require an exact type match on the invocant in the dispatcher. Since the cache does exact type matching, this works out fine in that case also.
16:19
ast: 1d7f6cb | jnthn++ | S12-methods/multi.t:
Unfudge test for RT #74646.
Ven jnthn++
16:19 khw joined
jnthn That was another xmas one 16:20
Nicely under 50 now
RabidGravy Skarsnik, sounds good, do it.
tadzik Skarsnik: well, Config::INI has write support 16:21
jdv79 whatsup wit self.?foo being ok while $.?foo throws with something about $. and .ins on a fh? 16:23
RabidGravy but Associative support would be cool, just easier to write ;-)
Skarsnik oh there is an Writer.pm I did not see
jdv79 self. and $. aren't equivalent?
dalek kudo/nom: 3bbc922 | lizmat++ | src/core/Any-iterable-methods.pm:
Make List.sort 30% faster

And also not lazy: the thing is that there is little point in laziness on the result of a sort: all data is in memory already, so making things lazy just adds overhead. The only case this is slower, is for the sink-all and count-only iterator cases. But if you doing a sort in sink context, or counting number of elements in a sort, you're doing it wrong anyway.
16:24
timotimo jdv79: that's because .? is a method call feature and $.foo isn't a method call
SmokeMachine excuse me, just a question: is there any plan (or is it already being done) to make perl6 runs on iOS devices?
moritz SmokeMachine: I know of no such plans
lizmat SmokeMachine: perhaps when we have a javascript backend
and then in a browser :-) 16:25
timotimo lizmat: sorry, you referred to crazy optimizations for ++$i vs $i++, but i was actually looking at the wrong numbers and there is exactly no speedup :(
zengargoyle jdv79: i think that's a case of trying to catch Perl5-isms
jdv79 what is $.foo then? i thought $!foo was the var.
16:25 g4 left
RabidGravy iOS doesn't support native applications at all? 16:25
jdv79 zengargoyle: the error message makes that much clear:)
lizmat timotimo: but will there be in the future ?
timotimo lizmat: probably not the near future :( 16:26
lizmat: if i can't make it work by myself, it'll have to wait until next year
SmokeMachine lizmat: no way to compile rakudo, or another compiler, for iOS? maybe moarVM on iOS...
jnthn In the long run, we'll probably spot when postfix ++ was used and prefix ++ was sufficient and end up with the same code
zengargoyle more specifically, sometimes the checking is overly eager.
lizmat jdv79: $.foo is just short for self.foo (and it interpolates :-) 16:27
zengargoyle there's probably not a case for 'method that starts with ?' in there so it hits the '$.' is perl 5 first.
lizmat SmokeMachine: not unless you jailbreak it, I would think, knowing Apple's guidelines for app development
ugexe ive had instance where $.foo fixes errors caused by self.foo in JVM
RabidGravy SmokeMachine, is there a way of compiling and installing native applications for iOS? If so it's try a cross-compile and see how it goes. 16:28
ugexe notable where .foo is a method on a class, and some role is reference foo via $.foo or self.foo
SmokeMachine RabidGravy: I am not a iOS developer, but you can use objective-c on iOS, objective-c is just a super-set of c... so, I think that could be possible, am i right?
lizmat timotimo jnthn : but ++nativeint should at one point in the future just become an INC machine op, no ?
jnthn lizmat: Yeah 16:29
SmokeMachine lizmat: I mean... there are a python interpreter for iOS... (pythonista)
lizmat SmokeMachine: from the app store ?
SmokeMachine yes!
RabidGravy SmokeMachine, haven't the faintest idea, maybe try compiling it with the cross compiler and see what happens
SmokeMachine lizmat: itunes.apple.com/en/app/pythonista...79881?mt=8 16:30
AlexDaniel how can I print the name of the current sub? I mean, the sub that I'm in? 16:31
RabidGravy I'm sure if someone cares enough at some point it might happen
$?ROUTINE.name or something?
psch m: sub f { &?ROUTINE.name.say }; f #
camelia rakudo-moar 3bbc92: OUTPUT«f␤»
psch RabidGravy: the sigil! 16:32
lizmat SmokeMachine: I'm pleasantly surprised
stmuk was there a META.info lint type program?
lizmat but alas, nobody yet working on such a beast afaik
RabidGravy THE SIGILS! THE SIGILS!
stmuk, I made Test::META for just this purpose
lizmat imagines a sequel to PIXELS 16:33
zengargoyle and sometimes &ROUTINE doesn't quite work (already rakudobug'd i believe)
stmuk I thought I saw something about it!
SmokeMachine lizmat: and it is used too on a great text editor: itunes.apple.com/us/app/editorial/...07758?mt=8 (from the same developer)
AlexDaniel hehe
RabidGravy it may need some features but it checks basic things like does it parse, does it have the required fields, does what it say in provides: actually exist 16:34
SmokeMachine I am watching lots of non programmers learning python only to automate iOS stuff with pythonista and editorial...
AlexDaniel I'm not sure if camelia is going to show this beauty…
m: sub test { BEGIN { say &?ROUTINE.name } } 16:35
camelia rakudo-moar 3bbc92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/xOLiW1xNqN␤An exception occurred while evaluating a BEGIN␤at /tmp/xOLiW1xNqN:1␤Exception details:␤ 5===SORRY!5=== Error while compiling ␤ Cannot call method 'name' on a null object␤ at :␤»
AlexDaniel nested SORRY!
RabidGravy which is cool and fun and all but hey ;-)
AlexDaniel I also like how it prints the line number 16:36
“at :”
SmokeMachine lizmat: so, do you think that it is possible to port perl6 to iOS? 16:37
lizmat technically, I don't have a doubt
Apple policy wise, I'm not so sure :-(
lizmat hopes to be wrong in that respect 16:38
SmokeMachine lizmat: but way would they accept python but perl6?
Skarsnik tadzik, should I write a new module to have a more oo thing or maybe rewrite your module?
RabidGravy and "anyone wanting it done enough to make it happen"-wise I have have a doubt
lizmat SmokeMachine: Apple's rulings are not known to be very consistent
SmokeMachine lizmat: don't you think that it would worth? 16:41
lizmat: don't you think that try it would worth?
lizmat yes, I think it's definitely worth a try!
SmokeMachine: so if you're up to it, I would say: go for it! 16:42
RabidGravy Skarsnik, I'd go with providing an alternative interface to the same module
SmokeMachine lizmat: how do you think that should wort? What should be ported? the VM should be ported? 16:43
grondilu m: my Array[Real] @a; @a[1] = pi # not sure if that's ok
camelia rakudo-moar 3bbc92: OUTPUT«Type check failed in assignment to @a; expected Array[Real] but got Num␤ in block <unit> at /tmp/_Q7ycL5pfU:1␤␤»
timotimo lizmat: could you revert the commit for ++$foo ?
lizmat timotimo: sure, but why ?
SmokeMachine *work 16:44
grondilu understands his mistake
RabidGravy I.E. rewrie the innards to use a single OO design, but retain the existing interface and provide a new OO type interface
16:44 hankache joined
Skarsnik RabidGravy, actually it's a module that export stuff, not a class. So there will be a long name or somthing for the OO class 16:44
RabidGravy sure
timotimo lizmat: because it's woefully slow 16:45
lizmat so I made it worse ?
timotimo i believe so. let me check
m: my int $i = 0; while ++$i < 10_000_000 { }; say now - INIT now
camelia rakudo-moar 3bbc92: OUTPUT«5.747536␤»
timotimo m: my int $i = 0; while ($i = $i + 1) < 10_000_000 { }; say now - INIT now 16:46
dalek kudo/nom: b627af6 | jnthn++ | src/ (2 files):
Implement nextcallee.

Allows you to grab one callee from the current dispatch iterator and call it many times (callsame moves you through the iterator in a destructive way).
camelia rakudo-moar 3bbc92: OUTPUT«0.0569592␤»
timotimo yeah, a factor of 100
PerlJam grondilu: I dunno ... looks like a bug to me. You're assigning to an individual element of the array (granted, you get the type wrong), but why would it complain that it's looking for Array[Real] rather than just Real?
dalek kudo/nom: 019a7ff | lizmat++ | src/core/ (4 files):
Revert "Get some crazy optimizations, timotimo++"
16:47
timotimo pff, i got a ++ for the revert, too. shameful!
16:47 jesper_ joined
lizmat timotimo: too bad :-) 16:47
PerlJam m: my Array of Num @a; @a[0] = pi;
camelia rakudo-moar 3bbc92: OUTPUT«Type check failed in assignment to @a; expected Array[Num] but got Num␤ in block <unit> at /tmp/W8j3eVLp4x:1␤␤»
16:48 telex joined
psch m: my @a of Num; @a[0] = pi 16:49
camelia ( no output )
dalek ast: d88edec | jnthn++ | S12-methods/defer-call.t:
Some tests for RT #125783.
16:50
16:50 pyrimidine joined
PerlJam oh, it's "doubling" the Array? once because of the @ and once because I said Array? 16:50
grondilu PerlJam: I think it's the @ sigil. my Foo @ is always an array of Foos. 16:51
16:51 Ven left
grondilu so my Array[Real] @ is an array of Array[Real] 16:51
timotimo that's right
16:51 Ven joined
grondilu but then I'm not sure how I create an Array[Real] 16:52
PerlJam aye. Looks like I made the same mistake you did :)
psch m: my Real @a; @a.WHAT.say; my @b of Real; @b.WHAT.say
camelia rakudo-moar 019a7f: OUTPUT«(Array[Real])␤(Array[Real])␤»
lizmat m: my Real @a; @a[0] = 1
camelia ( no output )
lizmat m: my Real @a; say @a[0].WHAT
camelia rakudo-moar 019a7f: OUTPUT«(Real)␤»
timotimo tony-o: should we throw JSON::Faster out of the ecosystem now that JSON::Fast has it? 16:53
tadzik Skarsnik: you may want to use Config::INI as a backend for your Config::INI::Object or so :)
timotimo tony-o: and perhaps make it easier (or just documented) to only grab to-json from JSON::Fast (so that you can get from-json from the more compliant JSON::Tiny)
grondilu thing is, what I wanted to do initially is : subset Vector of Array[Real]; but then I can't make it work in subroutines.
timotimo then you'll have to use "is" instead of "of" (is that implemented?) 16:54
PerlJam timotimo: I doubt it
grondilu m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; f my Array[Real] $
camelia ( no output )
grondilu m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f my Array[Real] $
camelia rakudo-moar 019a7f: OUTPUT«vector!␤»
PerlJam m: my @array is Array;
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/LtQmNoCVQX␤Variable trait 'is TypeObject' not yet implemented. Sorry. ␤at /tmp/LtQmNoCVQX:1␤------> 3my @array is Array7⏏5;␤ expecting any of:␤ constraint␤»
grondilu m: my Array[Real] $ = pi 16:55
camelia rakudo-moar 019a7f: OUTPUT«Type check failed in assignment; expected Array[Real] but got Num␤ in block <unit> at /tmp/i368cF5L1P:1␤␤»
grondilu m: my Array[Real] $ = [pi]
camelia rakudo-moar 019a7f: OUTPUT«Type check failed in assignment; expected Array[Real] but got Array␤ in block <unit> at /tmp/cjaXOFAgVK:1␤␤»
timotimo m: my Array[Real] $foo .= new(pi); say $foo.perl
camelia rakudo-moar 019a7f: OUTPUT«Array[Real].new(3.14159265358979e0)␤»
grondilu m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f my Array[Real] @ = pi 16:56
camelia rakudo-moar 019a7f: OUTPUT«Type check failed in assignment to @; expected Array[Real] but got Num␤ in block <unit> at /tmp/3EM4GjXyCJ:1␤␤»
grondilu m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f my Real @ = pi
camelia rakudo-moar 019a7f: OUTPUT«vector!␤»
grondilu oh that works
I'd swear I had tried that
16:56 diana_olhovik joined
timotimo :) 16:56
tony-o [Tux]: not really tempted, not sure why you think it's the most versatile, either. admittedly i haven't spent 80 weeks of my life on csv parsing, though, so it just might be.
Skarsnik tadzik, I can probably keep the existing API (that return %hash) and add an exported parse-ini (or from-ini) that return an object
tadzik Skarsnik: I think you should go ahead and create your own module, one that uses Config::INI under the hood to not duplicate the tricky parts 16:57
Skarsnik I am not fan of having two modules that do exactly the same thing. It lost the user 16:58
timotimo oh tony-o is here :)
tony-o i'm back :-)
PerlJam Skarsnik: You could call your module Config::INI and then it's almost as if there's only one module :) 17:00
RabidGravy Skarsnik, layers of interfaces are cool though - one module does a procedural interface and another that uses that module to provide an OO interface
jnthn .ask TimToady I've added nextcallee. One outstanding question I can't dig up a previous discussion on: what are the seamtnics of nextsame/nextwith and callsame/callwith if you've exhausted the iterator already? At the moment they all just do nothing and return Nil; that seems LTA for nextsame/nextwith, which probably at least want to return Nil, not continue onwards.
yoleaux jnthn: I'll pass your message to TimToady.
zengargoyle m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f Real @ = pi
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/WA_BqImrVh␤Two terms in a row␤at /tmp/WA_BqImrVh:1␤------> 3ub f(Vector $) { "vector!" }; say f Real7⏏5 @ = pi␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ …»
tony-o timotimo: what's up?
Skarsnik RabidGravy, well for now we don't have a nice SEE also section like on cpan x) 17:01
timotimo did you see what i highlighted you with about a screen page up?
zengargoyle m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f @[Real] = pi
camelia rakudo-moar 019a7f: OUTPUT«Type check failed in binding <anon>; expected Array[Real] but got Array␤ in sub f at /tmp/ACy0ItXQcJ:1␤ in block <unit> at /tmp/ACy0ItXQcJ:1␤␤»
mrf m: say "aaaa" ~~ /<?after a>+ a/;
zengargoyle m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f @ of Real = pi
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/TYy8LZQCJ5␤Confused␤at /tmp/TYy8LZQCJ5:1␤------> 3sub f(Vector $) { "vector!" }; say f @ o7⏏5f Real = pi␤»
rakudo-moar 019a7f: OUTPUT«(timeout)» 17:02
tony-o timotimo: i didn't until you mentioned it, but i'm agreeable to that. can we throw some props on that repo?
timotimo zengargoyle: that really needs the "my" there
er ... some props?
grondilu m: @ or Real
camelia ( no output )
zengargoyle meh, trying to remember something... didn't think it needs real as @ is automatic state variable
tony-o credits ^ :)
17:02 yqt joined
grondilu m: say @ or Real 17:02
camelia rakudo-moar 019a7f: OUTPUT«[]␤»
grondilu m: say @ or Real = pi
camelia rakudo-moar 019a7f: OUTPUT«[]␤»
timotimo oh, you mean JSON::Fast mentioning the work you did in JSON::Faster?
also putting you in the authors
grondilu m: @ of Real 17:03
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/9Etkpcy45P␤Bogus statement␤at /tmp/9Etkpcy45P:1␤------> 3@ o7⏏5f Real␤ expecting any of:␤ whitespace␤»
zengargoyle thought i saw TimToady do some fancy typed anonymous var things before
timotimo where do authors go in the meta6.json file? :S
tony-o yea, if you don't want to, i don't mind - i'm still agreeable to removing JSON::Faster
grondilu m: @[Real]
camelia ( no output )
grondilu m: @[Real] = pi
camelia ( no output )
grondilu m: say @[Real] = pi
camelia rakudo-moar 019a7f: OUTPUT«[3.14159265358979]␤»
tony-o i think it's just authors: []
grondilu m: say @[Real] = pi, 6
camelia rakudo-moar 019a7f: OUTPUT«[3.14159265358979 6]␤»
RabidGravy Skarsnik, I'm of the opinion that none of these modules are *finished* or the APIs settled until there 's a stable 6.0.0 release and people start using them
so it's all kind of moot 17:04
grondilu m: subset Vector of Array[Real]; sub f(Vector $) { "vector!" }; say f(@[Real] = pi)
camelia rakudo-moar 019a7f: OUTPUT«Type check failed in binding <anon>; expected Array[Real] but got Array␤ in sub f at /tmp/bISccKYBZF:1␤ in block <unit> at /tmp/bISccKYBZF:1␤␤»
timotimo tony-o: github.com/timo/json_fast/commit/3...c57bd8b522 - look good? 17:05
tony-o haha, extravagant. that works for me man, thank you
timotimo :3 17:06
so i'll kick faster out of the ecosystem
tony-o timotimo++
lizmat sightseeing&
17:06 lizmat left
dalek osystem: ff0327f | timo++ | META.list:
JSON::Faster has been swallowed by JSON::Fast

perhaps make things a bit less confusing for newcomers.
17:07
timotimo i've recently seen someone complain about "why do we have JSON::Tiny, JSON::Fast and JSON::Faster?!?" or something
that's where i got the idea to throw ::Faster out
Skarsnik maybe me x)
JimmyZ JSON::Slow JSON::Slower :P 17:08
timotimo BBIAB :) 17:09
tony-o *intentionally makes the interface callback hell like early node and random sleeps *
timotimo we don't have a streaming json parser yet
Skarsnik I should port my dumb Acme module in perl6 but... dealing with IRC color is not fun x)
PerlJam Having all those JSON modules isn't so bad unless it makes it onerus for the prospective users to choose
17:10 Ven left
AlexDaniel m: sub { 'Perhaps it should complain about sink context?' } 17:10
camelia ( no output )
Skarsnik people are afraid to choose. "What if it's the bad choice?" "What if I use something deprecated?"
timotimo AlexDaniel: an anonymous sub defined in sink context you mean?
tony-o choose now, refactor later
AlexDaniel timotimo: yes
PerlJam Skarsnik: what tony-o said
Skarsnik: change is inevitable, people need to get used to it :) 17:11
RabidGravy it's all immature, people are still wombling around trying to find what the mpst Perl 6-ish interfaces are
timotimo does anybody feel responsible for building that download page for perl6.org that leads people to a reasonable rakudo installation? 17:12
PerlJam RabidGravy: people are still doing that for Perl 5 modules too :)
RabidGravy make all the things and let the software gods sort it out
tony-o don't know how many times i've waited for AnyEvent to finish building and then remembered that there's AE and another one that are shinier.. 17:13
RabidGravy PerlJam, I think I am going to actually delete several of my Perl 5 modules in the near future
timotimo RabidGravy: yeah, force those perl5 people to upgrade to perl6! :P 17:14
PerlJam RabidGravy: delete them because ... ?
17:14 Ven joined
PerlJam RabidGravy: or ... why not put them up for adoption rather than delete them? 17:14
Skarsnik tony-o, hm I was wondering, maybe add a warning on h:p:x doc that it does not parse html5 well? (or follow the spec) The html5 spec specify how to handle syntax/tag error and such, it's a freaking huge work to write a proper html5 parser it seems
[Coke] (/ to search) facebook and gmail, for two.
17:16 diana_olhovik left
RabidGravy PerlJam, because I can't see the reason for e.g. Linux::Svgalib, CGI::XMLPost or CGI::Form2XML any more ;-) 17:16
PerlJam RabidGravy: btw, do *you* have an account for perl6advent.wordpress.com? An article on JSON::Infer might make a good advent post. 17:17
17:17 hankache left, ^elyse^ joined
RabidGravy the first is totally broken and I haven't had a bug -report ever for it, so I guess no-one uses it 17:17
jdv79 RabidGravy: (or anyone else that interested) I'd be interested in feedback on/about github.com/jdv/p6-uri2 17:18
my lame attempt at "mutable URI" primarily but also try to do it sa "p6ish" as possible 17:19
RabidGravy PerlJam, no, no account but I'd write an article
tony-o jdv79: not sure if you're doing that for learning or not but i believe ugexe has published some stuff with uri
PerlJam RabidGravy: give me an email address and I'll send you an invite. 17:20
17:20 perlwiz joined
jdv79 for learning and because i had a need for mutability and the current URI bugged me 17:21
perlwiz what is wrong with this code rakudo is printing error message
my $i=0 while $i<5{ print "Suman"; $i+=1; }
[Coke] m: say "Need to fix { 46 / 33 } bugs a day until XMAS";
camelia rakudo-moar 019a7f: OUTPUT«Need to fix 1.393939 bugs a day until XMAS␤»
PerlJam perlwiz: needs more space
jnthn [Coke]: Where does the 33 come from? :)
PerlJam perlwiz: and some punctuation
tony-o perlwiz: probably need a ';' after declaring $i
[Coke] because the december release is 12-17, not 12-25.
jnthn [Coke]: Also, why does your count always seem to be 1 less than mine? :)
AlexDaniel jnthn: although indeed I probably “expected wrong”, still it is very non-DWIM, so perhaps it could throw a warning if you try to use “callsame” multiple times? Is it possible? 17:22
jnthn counts 47 to go
jdv79 tony-o: iirc ugexe's was meant to be "simple". i mean for comprehennsive and well built
[Coke] jnthn: ah, because pbpaste | wc -l is missing a newline somewhere! 17:23
jnthn AlexDaniel: No, but I did ask if callsame on an exhausted iterator should die, in which case you'd have got an error.
PerlJam btw, anyone else willing to contribute to the Advent calendar?
[Coke] so yes, all my xmas counts have alwas been off by one. whoops.
m: say "Need to fix { 47 / 33 } bugs a day until XMAS";
camelia rakudo-moar 019a7f: OUTPUT«Need to fix 1.424242 bugs a day until XMAS␤»
PerlJam (anyone who may not already have a login)
jdv79: do you have a login for the advent calendar?
jnthn AlexDaniel: Will implement whatever TimToady++ decides on that :)
AlexDaniel jnthn: right. OK then :)
ZoffixW PerlJam, contribute how?
AlexDaniel jnthn: thanks!
perlwiz PerlJam My code is my $i=0;
[Coke] m: say "Need to fix { 47 / 41 } bugs a day until XMAS, if we release on xmas";
camelia rakudo-moar 019a7f: OUTPUT«Need to fix 1.146341 bugs a day until XMAS, if we release on xmas␤»
PerlJam ZoffixW: write content (though, if you want to update the look and feel, that would be tres awesome) 17:24
jnthn Enough for me for today :)
perlwiz while $i<5 {print "Suman"; $i+=1;}
AlexDaniel [Coke]: how many xmas blockers are created per day? Approximately?
perlwiz PerlJam I am getting this error
===SORRY!=== Error while compiling sum.p6 Whitespace required before < operator at sum.p6:6 ------> <BOL><HERE><EOL> expecting any of: postfix
ZoffixW PerlJam, I probably don't know enough Perl 6 to contribute meaningfully; about look-n-feel, what's the URL to the site / repo? 17:25
jnthn AlexDaniel: We've not been adding to the list, and likely won't add much more
17:25 diana_olhovik joined
[Coke] AlexDaniel: approximately zero. 17:25
there may be some one offs that get added, but it's unlikely. and there are still going to be monthly releases all year. 17:26
AlexDaniel sounds weird :)
jnthn perlwiz: Exactly what the error says
perlwiz: You have to put whitespace before the < operator
PerlJam ZoffixW: perl6advent.wordpress.com/ is the site. (that's something I threw together whatever year we first started doing this and it hasn't changed since)
jnthn Enough for me for today. Going to do dinner, relax, etc. :) o/ 17:27
[Coke] jnthn++
PerlJam ZoffixW: There's no repo, but if you're an admin you can configure things like the graphics, colors, layout, etc.
TimToady just pretend it's a Friday
yoleaux 11:04Z <Skarsnik> TimToady: thx for fixing is export{ message
17:00Z <jnthn> TimToady: I've added nextcallee. One outstanding question I can't dig up a previous discussion on: what are the seamtnics of nextsame/nextwith and callsame/callwith if you've exhausted the iterator already? At the moment they all just do nothing and return Nil; that seems LTA for nextsame/nextwith, which probably at least want to return Nil, not continue onwards.
ZoffixW PerlJam, MY EYES!!!!
PerlJam ZoffixW: gimme an email address so that I can invite you
ZoffixW PerlJam, just kidding :) It looks good to me as is TBH
PerlJam, [email@hidden.address]
PerlJam Well ... it's simple at least :)
tadzik Skarsnik: yeah, point taken. I have no objections (he he) to giving Config::INI some new (other?) API, if it gives a new possibilities to the user 17:29
ZoffixW TimToady, but it IS Friday! :D
You scared me for a second, making me think it wasn't :P
AlexDaniel m: my @a = 1, 2, 3 .. *; .say for @a[0..20]; # whoops! Should've used … 17:31
camelia rakudo-moar 019a7f: OUTPUT«1␤2␤3..Inf␤»
pippo o/ #perl6!
17:31 pippo left 17:32 diana_olhovik left
AlexDaniel m: my @a = 1, 25, 3 … * 17:32
camelia ( no output )
AlexDaniel m: my @a = 1, 25, 3 … *; .say for @a[0..20];
camelia rakudo-moar 019a7f: OUTPUT«Unable to deduce arithmetic or geometric sequence from 1,25,3 (or did you really mean '..'?)␤ in block <unit> at /tmp/zEEr4XO3ux:1␤␤»
AlexDaniel “did you really mean '..'”?
what does it mean? 17:33
aaah
ZoffixW AlexDaniel, the ... is magical :)
Oh wait
AlexDaniel m: my @a = 1, 25, 3 .. *; .say for @a[0..20];
camelia rakudo-moar 019a7f: OUTPUT«1␤25␤3..Inf␤»
perlwiz jnthn But why whitespace ? what's the difference between whitespace and no whitespace? Does that has special meaning?
AlexDaniel so it kinda tells me to do this?
ZoffixW AlexDaniel, it can't figure out what sequence you wanted
17:33 Ven left
ZoffixW Um. 17:33
Right. 17:34
AlexDaniel ZoffixW: Yea, I understand that
ZoffixW m: my @a = 1, 25, 125 … *; .say for @a[0..20];
camelia rakudo-moar 019a7f: OUTPUT«Unable to deduce arithmetic or geometric sequence from 1,25,125 (or did you really mean '..'?)␤ in block <unit> at /tmp/swDKLWrlUj:1␤␤»
ZoffixW m: my @a = 0, 25, 50 … *; .say for @a[0..20];
camelia rakudo-moar 019a7f: OUTPUT«0␤25␤50␤75␤100␤125␤150␤175␤200␤225␤250␤275␤300␤325␤350␤375␤400␤425␤450␤475␤500␤»
TimToady perlwiz: p6 requires whitespace before any infix that could be confused with a postfix, and we use angles as a postfix for literal hash subscripting 17:35
AlexDaniel I just don't find '..' suggestion useful at all. I am probably missing something important
perlwiz TimToady Yeah I gotch it :)
TimToady AlexDaniel: sometimes you want to put a range in the middle of an otherwise unrelated list
so this is a suggestion if you happened to put ... when you meant .. 17:36
that's why it's a question, because it's just a guess
AlexDaniel okay!
m: my @a = 1, 2 …… *; say 'hello'; 17:43
camelia ( no output )
AlexDaniel O_o
m: …; say 'hello';
camelia ( no output )
AlexDaniel ah right
timotimo "stub code executed"? 17:44
TimToady shouldn't be throwing that away
m: fail; say 'hello'
camelia ( no output )
TimToady or that
worth a rakudobug, if it's not there already 17:45
perlwiz Now time for Perl6Data conference guys just like PyData
TimToady bring it on! :)
perlwiz We need to focus more on scientific computing and data crunching 17:46
TimToady we've been anxiously awaiting the PDLers to show up and start hacking
jdv79 PerlJam: no
perlwiz doing data analysis in PDL is not that simple as in pandas(python) 17:47
AlexDaniel hmm, can't find anything
sivoais I've made the start of a Perl5 Pandas (called Data::Frame). It integrates with R.
arnsholt perlwiz: Sounds like a Perl 6-y version of the pandas API might be a good idea. Well volunteered! =) 17:48
sivoais by the way, I'm on the PDL Porter dev team. :-) I've let some know on the IRC channel before that we need to start thinking about Perl6.
timotimo so this is about the code around the main program not working with
17:48 kjs_ left
sivoais but I'm on a hiatus right now as I finish my thesis. :-) 17:48
timotimo hm, in this case probably &RETURN or the exhaust thingie or something 17:49
perlwiz arnsholt Yeah whatever we urgently require analytic and visualisation tools within perl6 I guess :) :)
arnsholt I actually have a semi-related project I'd like to get working on
dalek c: 29ee496 | (Zoffix Znet)++ | html/js/main.js:
Clarify what the code is for
arnsholt But like sivoais, it turns out this whole thesis stuff is so time-consuming. Odd that. =)
17:50 colomon joined
timotimo perhaps bridge the gap in the mean time with Python::Inline to connect the perl6 api we want with the python code that already exists to do stuff 17:50
sivoais I still promise to take the IPerl <-> IPython work I'm doing and turn that into an IPerl6 :-) 17:51
but tuits are hard to find over here these days
arnsholt sivoais: Is that your thesis work?
perlwiz sivoais eagerly waiting IPerl6!!
sivoais no, I'm doing image analysis mainly in C/C++ :-) IPerl was something to make quick experiments easier to work with. 17:52
arnsholt Ah, cool 17:53
I've looked a bit a the ipython docs, but I haven't been able to figure out how to actually implement a kernel
timotimo arnsholt: i have
ipython.org/ipython-doc/3/developm...rnels.html 17:54
17:55 tokuhiro_ joined
arnsholt timotimo: Yeah, the problem is the messaging part of it. I probably just haven't sat down and read it with the proper attention, to be honest 17:55
timotimo oh
the messaging part i can help you with 17:56
ipython.org/ipython-doc/3/developm...e-protocol - it's this
arnsholt Yeah, that's the tricky bit
timotimo hah, you think?
arnsholt Odd, that =) 17:57
17:57 kjs_ joined
sivoais there are a couple oddities when you get into the details, but the high-level view of Jupyter's/IPython's messaging spec isn't too bad. 17:58
timotimo arnsholt: well then. you'll implement the parts that connect the kernely bits with the messaging stuff, and i'll implement the messaging stuff
because the repl connecting things scare me
sivoais here's where I do all of that <github.com/EntropyOrg/p5-Devel-IPe...Kernel>
17:59 tokuhiro_ left
sivoais and the kernel-y bit <github.com/EntropyOrg/p5-Devel-IPe...nel.pm> 17:59
arnsholt timotimo: Oh, right. I was thinking about just making sense of the docs. Implementation wise there's sure to be a whole raft of stuff
timotimo hah
fair enough
another thing is that i don't really have a good idea of where we stopped with our ZMQ binding :(
arnsholt Yeah, I remember you wrestling with this back in the day
Yeah =( 18:00
So many projects, so few tuits
perlwiz sivoais Yeah I saw Data::Frame. Its Ok. For data manipulation we need to use concepts like in dplyr and data.table(R) in perl6 18:03
timotimo dplyr?
sivoais perlwiz: totally agree. It's on my list. I'm trying to create a Perl {5,6} for science project like ROpenSci or SciPy. Something with a good solid set of docs and nice API that learns from the existing tools. 18:05
timotimo: dplyr is a SQL / LINQ -like API for tabled data in R 18:06
dalek c: a1f5f53 | (Zoffix Znet)++ | html/js/main.js:
Unfocus search box when user scrolls a bit

  zengargoyle++ for spotting the issue
18:07
timotimo ah, neat
i'll be AFK for a bit
perlwiz sivoais Loads of thanks. I was wandering why despite perl being older than python it was lagging behind in scientific computing. Why the whole ecosystem of data analytics was lacking in perl? At least now I am relieved that someone's working in it. And even Ruby is picking up in this area(data analytics and visualisation). Why can't perl? 18:11
18:13 avalenn joined
sivoais This is where I'm starting a rough sketch of things <entropyorg.github.io/>. I'm defending very soon (so I need to get back to work :-P), so new things will start happening after that. 18:13
18:14 mr_ron joined 18:18 avalenn left, zengargoylew joined
perlwiz sivoais Again many many thanks. I appreciate your work. But for plotting I suggest to use matplotlib. I am never happy with plotting within perl. Bitter truth I should say perl is not better at plotting. 18:19
arnsholt There is no plotting but gnuplot, if you ask me 18:20
Especially for thesis-writing, with the epslatex terminal
AlexDaniel is waiting for p6lot 18:21
18:21 polettix left
hoelzro I like that name! 18:21
[Coke] tripping over a bug in ignoremark/ignorecase, having trouble golfing it.
perlwiz sivoais Can you show me documentation how to install IPer kernel? 18:22
sivoais perlwiz: what OS are you on? I need to write more docs for all the OSes 18:23
[Coke] gist.github.com/coke/751920fda50cd3196fbd
looks like the check is wandering off the edge of the string. doing a rebuild to see if this changed recently. 18:24
perlwiz sivoais I am on windows
win 10
win 10 64 bit 18:25
AlexDaniel IMO, gnuplot is very painfull to use. Matplotlib worked significantly better for me, but it is not perl-ish enough
sivoais perlwiz: eep, that's the system I was trying to install on last. You see, I needed to have ZeroMQ4 built on there as a static lib so that I could link the messaging up. That's a WIP.
AlexDaniel So yeah, please somebody create p6lot!
[Coke] m: say "Malmö" ~~ m:i:m/^ 'malmo' $/
camelia rakudo-moar 019a7f: OUTPUT«「Malmö」␤»
sivoais perlwiz: best bet right now is to spin up a Linux VM and work in there :-( 18:26
[Coke] m: my $a='Malmo'; say "Malmö" ~~ m:i:m/^ $a $/
camelia rakudo-moar 019a7f: OUTPUT«「Malmö」␤»
perlwiz AlexDaniel I agree matplotlib and ggplot2 are great in scientific plotting. You can check rbokeh also for interactive plotting.
[Tux] tony-o, it was not meant to scale down your version! 18:27
sivoais perlwiz: I would recommend something Debian-based since I have some short instructions in the README here <github.com/EntropyOrg/p5-Devel-IPerl>
AlexDaniel perlwiz: actually, I haven't tried ggplot2 yet! Thanks!
18:27 eliasr joined
sivoais oh yes, ggplot2 and bokeh are my current favourites. They have clean APIs. 18:28
AlexDaniel wow, bokeh looks great too! 18:29
18:29 ZoffixW left
sivoais perlwiz: if you have the tuits, finishing this for Windows might help <github.com/zmughal/p5-Alien-ZMQ4> progress IPerl on Windows. :-) 18:30
18:32 jesper_ left 18:39 yqt left
dalek c: 61a22a3 | (Ronald Schmidt)++ | doc/Language/subscripts.pod:
Update subscripts.pod

Fix broken link to Custom_type_example
18:40
ast: 528a22b | TimToady++ | S32-exceptions/misc.t:
argument now reported as Int rather than int
tony-o jdv79: the URI stuff ugexe ripped out of zef was from the RFC, not sure if he published it separately 18:43
timotimo hmm, there's gotta be some simple tool that checks a bunch of documents for broken links, right?
we could (should?) put that into the travis build for perl6/doc 18:44
tony-o xenu's link sleuth
timotimo .o( so that's what .xls stands for ) 18:45
18:45 kjs_ left 18:46 Begi11110 joined 18:48 kjs_ joined 18:49 espadrine joined
tony-o i've used xenu on corporate sites to great effect, not sure if you can cli it, though.. 18:50
it'd be an interesting tool to write in P6, i volunteer for that job.
hahainternet in a loop, is there a succinct way to say 'do this part only once'? 18:51
tony-o first { }
hahainternet thanks, hard to google for!
tony-o oops, first isn't the right one - there is a verb for it 18:52
hahainternet no worries, i figured it'd be something like once {} or similar
i don't actually need it now, but as usual i've come across the annoyance in python, so i'm comparing it to p6
tony-o FIRST
m: for ^5 { FIRST { 'sup'.say; }; .say; } 18:53
camelia rakudo-moar 019a7f: OUTPUT«sup␤0␤1␤2␤3␤4␤»
18:53 kjs_ left
tony-o can also use LAST and NEXT 18:53
m: for ^5 { NEXT { 'sup'.say; }; .say; }
camelia rakudo-moar 019a7f: OUTPUT«0␤sup␤1␤sup␤2␤sup␤3␤sup␤4␤sup␤»
tony-o m: for ^5 { NEXT { 'sup'.say; }; next; .say; } 18:54
camelia rakudo-moar 019a7f: OUTPUT«sup␤sup␤sup␤sup␤sup␤»
hahainternet yeah, phasers?
also, thanks :)
tony-o yea. np
perlwiz AlexDaniel sivoais ggvis is also great just like bokeh 19:02
tony-o ugexe is perl6 god 19:03
like hookah
19:03 ozykhan joined
masak thought hookah was just vaporware 19:04
tony-o nice pun masak++
zengargoylew is FIRST supposed to work in while loops? 19:06
sivoais is just here for the puns ;-)
AlexDaniel zengargoylew: why not?
tony-o m: while True { FIRST { "sup".say; next; }; break; } 19:07
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/8ZHKY2Hlmk␤Undeclared routine:␤ break used at line 1␤␤»
tony-o m: while True { FIRST { "sup".say; next; }; last; }
camelia ( no output )
zengargoylew well i've rakudobug'd it because it doesn't :P, but not *certain* it shuld
masak m: role R {}; say R.new # pun!
camelia rakudo-moar 019a7f: OUTPUT«R.new␤»
masak sivoais: you're welcome :) 19:08
AlexDaniel tony-o: I'm not sure if next/last are actually working in phasers 19:09
19:09 krunen left 19:10 ozykhan left
AlexDaniel m: for ^5 { NEXT { last }; .say } 19:10
camelia rakudo-moar 019a7f: OUTPUT«0␤1␤2␤3␤4␤»
AlexDaniel is it a bug?
oh, it actually works in FIRST 19:12
19:13 perlwiz left
timotimo arnsholt: you know, there's already a thing written in python that'll easily let you build your own kernel; why don't we go via Inline::Python for starts? 19:15
arnsholt timotimo: That's a horrendous hack. I like it! =) 19:16
But more seriously, that does sound like a very good idea
timotimo build it and you'll make a bunchton of people happy
like, SO MANY people
arnsholt Exactly. Link me the Python thingy? 19:17
timotimo gimme a sec
Skarsnik hm, how to handle $class<a><b>? (maping to hash of hash) I want to write $conf<a><b> = "piko"; but I end with {:a(${:b("piko")})}
timotimo ipython.org/ipython-doc/3/developm...rnels.html
Skarsnik: i'm not sure i understand what you mean? what's the problem here? 19:18
AlexDaniel Skarsnik: %conf<a><b> ?
timotimo m: say ${:a(1)}.perl
camelia rakudo-moar 019a7f: OUTPUT«{:a(1)}␤»
timotimo m: dd ${:a(1)}
camelia rakudo-moar 019a7f: OUTPUT«Hash $var = {:a(1)}␤»
Skarsnik $conf is an object from a class with AT-KEY defined 19:19
it has an internal %hash where I map data into it and display it. I am not to understand why I get a ${}? Should it display {a:((:b("piko"))} if it was a hash of hash? 19:21
arnsholt timotimo: Cheers! Looking at it now
Skarsnik oh it's the right thing. my bad 19:26
masak m: say "Malmø" ~~ m:i:m/^ 'malmo' $/
camelia rakudo-moar 019a7f: OUTPUT«「Malmø」␤»
19:26 nys joined
masak m: say "Mælmø" ~~ m:i:m/^ 'malmo' $/ 19:26
camelia rakudo-moar 019a7f: OUTPUT«「Mælmø」␤»
masak :P
flussence «Stage parse : 80.689» — another drop from 87ish, hopefully it'll stick this time 19:27
19:27 yqt joined
arnsholt masak: Mælmø, that's how the locals pronounce it, right? =) 19:28
flussence («Stage mast» dropped from 30ish to 28.1 too, looks like everything's a bit faster today for whatever reason) 19:29
pink_mist masak: lol .. no we don't :P 19:31
err arnsholt ^
moritz flussence: a fresh wave of Computrons has arrived at your CPU
masak arnsholt: totally.
pink_mist masak: >_<
masak arnsholt: actually, I've never understood what the locals are saying... :P
arnsholt: I understand people perfectly in Oslo, but here in Mælmø I just draw a blank. 19:32
pink_mist masak: I'm going to haveto go down to malmö and buy you a beer some day =) 19:33
masak pink_mist: I might hold you to that ;)
pink_mist: assuming you're in the vicinity?
pink_mist masak: helsingborg 19:34
masak ah; I was there today.
pink_mist ohh =)
masak $work main office is there.
(we're hiring) :P
arnsholt masak: Yeah, the dialect is odd. I get periodic reminders of that from Wallander and Broen =)
masak arnsholt: even the province flag is 50% Sweden and 50% Denmark! 19:35
arnsholt Oh, that's true! 19:36
For some reason I'd never connected those dots =D
masak arnsholt: there's this joke about a yearly tradition where some cessesionists go to the border to Blekinge to dig a (symbolic) ditch to break free of the rest of Sweden. 19:37
pink_mist lol, yeah I've heard about that one :P
masak arnsholt: the punchline is that the Blekinge people come from their side, and help digging.
TimToady also hates the autoselect of the Search box; could it be put where the 1st TAB will select it instead, or make it deselect itself and page down if you type space as the first thing? 19:39
masak +1 19:40
is the Search box for people who don't know about Ctrl+F ?
TimToady it's all very well to say "scoll first" deselects it, but those buttons Don't Work when the search box is selected in my browser
and I always scroll using space
19:41 zakharyas joined
arnsholt masak: Hee, hee. It's kind of like Bergen here (and Bavaria, I've been told). The Bergeners claim that Bergen is separate from Norway, and everyone else agrees 19:44
19:45 labster_ joined
TimToady then there's California 19:45
masak and Texas
and Catalonia
19:45 labster_ is now known as labster
masak and Scotland 19:45
moritz Scotland voted to stay in the UK 19:46
which I totally understand, and it still made me a bit sad 19:47
TimToady for some reason we're still a bit touchy on the subject of seccession over here in the U.S. of A. 19:48
RabidGravy but they asked to join the UK two hundred years ago when they pissed thir entire economy up the walll trying to start a colony in Venezuela
TimToady *secession 19:49
masak .oO( a "seccession" is an excession of secession ) :P
flussence TimToady: awkward question, I found out the other day enums halfway-work where a "unit module" statement does. I kinda like that behaviour, can I keep it? 19:53
RabidGravy flussence, had you considered applying a role to the enum, which does and I believe is always going to work? 19:54
flussence I know that works, but the part I'm not entirely sure about is putting an enum in a *.pm by itself, and being able to "use" that by name... 19:56
RabidGravy module Foo { our enum Bar <h g k> ... }; 19:59
arnsholt timotimo: I've got a prototype echo kernel with Inline::Python. But it turns out my Ubuntu IPython was *ancient*, so I'm upgrading to the most recent version so that it might have an actual chance at working
19:59 ZoffixW joined
ZoffixW Am I the only one who's bummed out that subtest takes the test's description AFTER the code block? 19:59
ZoffixW wonders what the chances are of that changing 20:00
RabidGravy yes
it's consistent with all the other things
flussence now that I poke at it some more, it seems I can name the enum anything I want and the «use» always succeeds. hmm...
moritz in "use Mumble;", the Mumble determines the file name 20:01
ZoffixW RabidGravy, I'd say readability trumps consistency
I have to skim all the way to the end of the block to find out what the subtest is all about.
The other functions don't take dozens of lines as the first argument, thus the test decription makes sense there
RabidGravy er 20:02
Skarsnik Hm, how do I can write attribute in a method that will construct the class?
moritz attributes are passive
so an attribute can'te vern construct anything
*can't ever
20:02 zakharyas left 20:04 espadrine left
Skarsnik I am not to understand what you are talking about x) I just want to write method read($filename) {$!something = "piko"; return self.bless} without writing self.bless(:something("piko")); 20:08
RabidGravy you mean like "static" methods? 20:10
20:12 rurban joined, rurban left
RabidGravy ie you do Foo.whatever() and still keep internal state 20:12
moritz Skarsnik: why don't you want to write self.bless(...)?
ZoffixW suspects some sort of .new-with(...)
Skarsnik, are you wanting to return a copy of the current object, except with $!something assigned to the new value? 20:13
Skarsnik I have a method read that can replace new. It read a file and should set some attribute according to it. but it does not let me write $!attribute = $value; It just feel dumb to have to pass them all at self.bless 20:15
20:17 FROGGS joined
ZoffixW Skarsnik, if it's a replacement for new, doing $!attribute is a bit meaningless. If you don't yet have an object, how would the compiler know what $!attribute is? 20:17
You want to change state, but you don't even have state without an object. 20:18
RabidGravy lots of existing patterns for that
TimToady ZoffixW: some additional carpage from me regarding the search box at irclog.perlgeek.de/perl6/2015-11-13#i_11534285
Skarsnik ZoffixW, but does that work in new itself? 20:19
RabidGravy even includinding doing callsame with a different invocant (see e.eg Staticish) 20:20
ZoffixW Skarsnik, why would it?
Skarsnik, $!attribute is an attribute of an object.
moritz Skarsnik: in a class (static) method, there is no instance yet, so you can't assign to an attribute yet 20:21
Skarsnik: so either you pass it to some form of constructor, of you create the object first, and then initialize it from the inside
Skarsnik well like in C++, in the constructor the attributes exist.
20:23 molaf joined
RabidGravy but new() isn't really the constructor here, bless() is the actual constructor (with I guess CREATE below that) 20:23
Skarsnik so after I call self.bless, the object exist or you are still in a class method (oposed to method of the instance)? 20:25
RabidGravy self.bless returns the new onject which you can call methods on 20:26
moritz Skarsnik: .bless returns the instance
flussence is :EXPORT on use NYI, or am I holding it wrong?
moritz flussence: NYI I think 20:27
timotimo arnsholt: i'm so glad you're going ahead with that
RabidGravy it has to match some "is export(:EXPORT)"
flussence RabidGravy: this is about the adverb (S11:206), not the thing inside the qw-list 20:29
arnsholt timotimo: Do you know if there's a list of formatting stuff I can use in the kernel.json file? 20:31
Skarsnik I will not have access to private attribute then? I mean like my $self = self.bless; $self.!privateattribute does not work
arnsholt There's {connection_file} from the example, but the path to the directory the kernel is installed to or something would be nice too
RabidGravy Skarsnik, no
it's a different object
flussence
.oO( is the synopsebot around? thought S11:206 would produce a link... )
20:32
Skarsnik RabidGravy, so you can't write different constructor that do stuff to private attribute? or giving them to .bless work? 20:34
RabidGravy you may be looking at BUILD that is called after the object is constructed on the new object with the same arguments 20:36
20:37 pippo joined
timotimo arnsholt: that's an excellent question! 20:37
arnsholt And I think the answer is: There isn't
Anyways, I don't care at this point
20:37 ^elyse^ left
arnsholt I just hardcoded the path to the Perl 6 script in the kernel file 20:37
So now I have something that echoes (via Perl 6)
Now for the hard part: Evaluating stuff 20:38
timotimo yeah, it seems like the very only thing is connection_file
pippo Question. in a for loop is i possible to get the next iteration's $_? i.e. for 1,2,3,4,5 { say $_; say what would be the next $_} and have then the for continues as if two iterations have been done? 20:41
moritz pippo: you can iterate two items at a time 20:42
20:42 abaugher left
moritz m: for <a b c d> -> $a, $b { say "after $a comes $b" } 20:43
camelia rakudo-moar 019a7f: OUTPUT«after a comes b␤after c comes d␤»
PerlJam pippo: do you only sometimes want to skip 2 ?
20:43 xfix joined, abaugher joined
PerlJam pippo: or ... why do you want to do this? :) 20:43
pippo PerlJam: Yes it is for some times unknown in th beginning. 20:44
dalek c: e132d9b | (Zoffix Znet)++ | html/js/main.js:
Un-focus search box and scroll when SPACE, DOWN, or PAGE DOWN are pressed
ZoffixW TimToady, ^ that should fix that
pippo PerlJam: moritz: I need it to parse a file. I know it is mad. Just wondering if it is possible. 20:45
timotimo pippo: there's a method called "rotor" that'll help you
i forget the exact way it's invoked 20:46
m: say (^10).rotor(2=>1).perl
camelia rakudo-moar 019a7f: OUTPUT«((0, 1), (3, 4), (6, 7)).Seq␤»
timotimo nope.
m: say (^10).rotor(2=>-11).perl
oops, very wrong
PerlJam you have to know ahead of time how you want rotor to function.
timotimo m: say (^10).rotor(2=>-1).perl
camelia rakudo-moar 019a7f: OUTPUT«((0, 1), (1, 2), (2, 3), (3, 4), (4, 5), (5, 6), (6, 7), (7, 8), (8, 9)).Seq␤»
rakudo-moar 019a7f: OUTPUT«(timeout)»
timotimo wait. which one is right now?
m: say (^10).rotor(2=>-1).perl
camelia rakudo-moar 019a7f: OUTPUT«((0, 1), (1, 2), (2, 3), (3, 4), (4, 5), (5, 6), (6, 7), (7, 8), (8, 9)).Seq␤»
timotimo yeah, that's the one
PerlJam It would be interesting if there was a looping construct like rotor where you could inject the take/skip elements information 20:47
timotimo take the next two, but take a step backwards before taking another two
moritz pippo: the next value isn't generally known, but knowing the previous value is trivial 20:48
pippo: so you can just re-formulate the problem from the perspective of the next value
20:49 ^elyse^ joined, mr_ron left
timotimo there's a homomorphism between the two 20:49
or something
pippo moritz: OK. I take it as not possible.
moritz pippo: well, we have presented you several options 20:50
zengargoylew m: my $i = [1,2,3,4]; for @$i -> $j { say $j; say $i.shift if $j == 2; }
camelia rakudo-moar 019a7f: OUTPUT«1␤2␤1␤4␤»
pippo moritz: I can of corse reformulate my problem and solve it in another way. But it would have been faster with that.
moritz pippo: all of them are possible; I just kept on, because it seems you weren't happy with any of them 20:51
timotimo pippo: just have a state variable that the for loop will next if $state-- > 0
zengargoylew would have expected 1,2,1,3,4
timotimo or something
zengargoylew or 1,2,3,4
not 1,2,1,4
moritz my \iter = lines().iterator; while IterationEnd !=:= (my $value = iter.pull-one) { say $value; my $next = iter.pull-one; say "Next: $next" } 20:52
m: my \iter = lines().iterator; while IterationEnd !=:= (my $value = iter.pull-one) { say $value; my $next = iter.pull-one; say "Next: $next" }
camelia rakudo-moar 019a7f: OUTPUT«Céad slán ag sléibhte maorga Chontae Dhún na nGall␤Next: Agus dhá chéad slán ag an Eireagal ard ina stua os cionn caor is coll;␤Nuair a ghluais mise thart le Loch Dhún Lúich’ go ciúin sa ghleann ina luí␤Next: I mo dhiaidh bhí gleanntái…»
20:52 zakharyas joined
moritz but that's really the same as iterating two at a time 20:53
20:53 ZoffixW left
timotimo damn, Weird Al is good. 20:55
PerlJam pippo: fwiw, were I you, I would use a variable as timotimo suggests.
RabidGravy buffalo girls go round the outside 20:56
20:56 krunen joined
skids m: my $a = Supply.new; my $b = Promise.in(1); my $n = now; react { whenever $b { 42.say; exit; }; sleep 2; 43.say } 20:56
camelia rakudo-moar 019a7f: OUTPUT«43␤42␤»
skids m: my $a = Supply.new; my $b = Promise.in(1); my $n = now; react { whenever $b { 42.say; exit; }; }
camelia rakudo-moar 019a7f: OUTPUT«42␤»
pippo PerlJam: you mean with the state var? 20:57
PerlJam pippo: it doesn't *have* to be a state var, but yes.
moritz also, you can interate over the indexes instead of the values
timotimo pippo: you could also have a gather/take in front that does nothing but do the +1/+2 thing
moritz then youc an easily advance by one
timotimo pippo: and then you can even communicate across the consumer and the producer... 20:58
pippo moritz: PerlJam: timotimo: Thank you. I'll try that.
20:59 spider-mario joined
zengargoylew can one take two at a time from an odd list with -> ($a,$b?) 20:59
timotimo yes, one can
moritz zengargoylew: yes
m: for 1, 2, 3 -> $a, $b? { say "$a: {$b // '-'}" } 21:00
camelia rakudo-moar 019a7f: OUTPUT«1: 2␤3: -␤»
moritz m: for 1, 2, 3 -> $a, $b = '-' { say "$a: $b" }
camelia rakudo-moar 019a7f: OUTPUT«1: 2␤3: -␤»
moritz idly wonders if Perl 6 signature binding is Turing complete 21:01
zengargoylew thinking more probably wouldn't work. in body take first and if needed use second, if not swap with first and redo body.
only works if the second item can't be an item that needs a second item tho. 21:02
arnsholt timotimo: IT'S ALIIIIIIVE! 21:06
arnsholt cackles madly 21:07
timotimo :-)
arnsholt Do you want me to put it in your iperl6kernel repo? 21:08
timotimo yes 21:09
jdv79 tony-o: they all are;) 21:13
PerlJam: I'm not sure i want to write anything but [email@hidden.address] 21:14
timotimo i don't leave my home without my pancreas~
21:16 tokuhiro_ joined
timotimo oh lord, iperl6kernel's last commit is 3 years old 21:17
21:17 eliasr left
arnsholt timotimo: Incidentally, do you know how to run the kernel as a separate process (so that I can debug it more easily) and connect to it in a separate step? 21:19
timotimo well, just intercept the connection file i suppose? 21:20
ipython qtconsole foobar.json
or something?
ah
--existing
is the right thing to do that
21:20 tokuhiro_ left 21:22 llfourn joined 21:25 raiph joined
Skarsnik hm why rakudo told me Config::Simple does not define new as defined in the role? Am I blind or something? x) gist.github.com/Skarsnik/2db25f0b9ab52dc0635b 21:26
raiph hi Skarsnik 21:29
arnsholt timotimo: Could you commitbit me on iperl6kernel?
21:33 zakharyas left
Skarsnik Oh multi is part of the signature? 21:35
timotimo haha 21:36
sure
i was f5-ing all the time for a little bit
21:37 pippo left
timotimo you're in 21:37
arnsholt Try now =)
21:37 rangerprice joined
rangerprice Hi 21:37
i need some help
21:38 raoulvdberge joined
rangerprice How i can found the number of characters in a file in perl ? 21:38
Skarsnik slurp($filename).chars ?
timotimo you're totally using Inline::Python wrong :P 21:39
arnsholt I can imagine!
Feel free to fix it =)
timotimo why did you write python code at all?
arnsholt Good question, I guess! =D
21:40 pippo joined
arnsholt I just got an idea for how to do it and whacked out the code 21:40
timotimo mhm
rangerprice Fille::Slurp is by default in perl ?
timotimo 5? 21:41
rangerprice yes
timotimo no idea
rangerprice File::Slurp *
tony-o Skarsnik: don't define new as a multi method 21:42
21:42 TEttinger joined
timotimo alternatively put a proto in there 21:43
21:43 rangerprice left
moritz m: say 'README'.IO.s 21:43
camelia rakudo-moar 019a7f: OUTPUT«Failed to find 'README' while trying to do '.s'␤ in block <unit> at /tmp/m4JNTsOtEo:1␤␤Actually thrown at:␤ in block <unit> at /tmp/m4JNTsOtEo:1␤␤»
Skarsnik m: role R { method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi foo($a) { say $a}}; my $a = A.new; $a.foo("hello"); 21:44
camelia rakudo-moar 019a7f: OUTPUT«===SORRY!===␤Method 'foo' must be implemented by A because it is required by a role␤»
moritz m: say '/etc/passwd'.IO.s
camelia rakudo-moar 019a7f: OUTPUT«1310␤»
Skarsnik m: role R { multi method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi foo($a) { say $a}}; my $a = A.new; $a.foo("hello");
camelia rakudo-moar 019a7f: OUTPUT«Cannot call foo(A: Str); none of these signatures match:␤ (A $: *%_)␤ (A $: *%_)␤ in block <unit> at /tmp/sn9yVNSBBn:1␤␤»
Skarsnik hm 21:45
moritz Skarsnik: did you intentionally create a multi sub and method each? 21:46
Skarsnik I forget a method
m: role R { multi method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi method foo($a) { say $a}}; my $a = A.new; $a.foo("hello");
camelia rakudo-moar 019a7f: OUTPUT«hello␤»
timotimo happens to the best of us 21:47
arnsholt: did you know you can derive perl6 classes from python classes with I::P?
Skarsnik but if I don't put a multi in the role I am not allowed to have another one (it make sense) but it's weird
21:47 molaf left
timotimo as i said, try putting a proto method in there 21:47
m: role R { method foo() {...}}; class A does R { proto method foo(|) {*}; multi method foo() {say "foo"}; multi foo($a) { say $a}}; my $a = A.new; $a.foo("hello"); 21:48
camelia rakudo-moar 019a7f: OUTPUT«Cannot call foo(A: Str); none of these signatures match:␤ (A $: *%_)␤ in block <unit> at /tmp/Upi0dk0HCz:1␤␤»
timotimo m: role R { method foo() {...}}; class A does R { proto method foo(|) {*}; multi method foo() {say "foo"}; multi method foo($a) { say $a}}; my $a = A.new; $a.foo("hello");
camelia rakudo-moar 019a7f: OUTPUT«hello␤»
llfourn Skarsnik: yeah multi foo { ... } doesn't really work as a contraint on the child class afaik
timotimo m: role R { method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi method foo($a) { say $a}}; my $a = A.new; $a.foo("hello");
camelia rakudo-moar 019a7f: OUTPUT«===SORRY!===␤Method 'foo' must be implemented by A because it is required by a role␤»
llfourn as timotimo++ showed you need proto :)
timotimo see?
llfourn unfortunetly we have not documented proto yet :\ 21:49
Skarsnik hm what proto does exactly? x)
arnsholt timotimo: Nope! Didn't think that far, TBH. The ipython docs had a Python example, so I just shoved the whole thing in there
But I agree; deriving a Perl 6 class and using that would be a lot cleaner
llfourn it essentially wraps a bunch of routines checking signature first and then re-dispatching 21:50
arnsholt timotimo: In my defence, the I::P docs are a bit sparse =) 21:51
timotimo the thing is, if you put a bunch of multi methods into something, you'll get a proto generated for you
arnsholt: right
but when there was already a method in the role you applied, things became a bit troublesome
perhaps this could be rakudobugged as an LTA error? because this case should probably be detectable 21:52
llfourn yes, I don't think what Skarsnik is trying to is actually possible atm...
to require at least one multi method to be implemented
timotimo i don't even know what Skarsnik's trying
oh, hm
that seems difficult, yeah
Skarsnik I put multi in the role and it work x) 21:53
but will I have trouble with another class that has only one foo ?
llfourn Skarsnik: give it a try, I think I remember triyng the exact same thing and it didn't work
timotimo does it properly require the method to be implemented?
Skarsnik ah good question 21:54
llfourn ie it didn't throw the not implemented error
21:54 grondilu joined
Skarsnik yep it did not throw, if I don't define the method 21:55
21:56 xfix left
timotimo right, in that case it's toothless :) 21:56
Skarsnik hm interesting... 21:57
llfourn yes I also just tried it and it doesn't work :\
Skarsnik when I try to call the method (with only one of them, but still with multi)
Ambiguous call to 'read'; these signatures all match:
:(Config::Simple $: $filename, *%_)
llfourn is that because you have a { ... } there as well? 21:58
do your signature constraints in your proto
it seems doing { ... } in a multi is useless atm
Skarsnik I did not try with proto yet
yes, I think that the issue 21:59
psch m: class C { multi method f { ... } }; C.new.f
camelia rakudo-moar 019a7f: OUTPUT«Stub code executed␤ in method f at /tmp/MdZTfJTUWn:1␤ in block <unit> at /tmp/MdZTfJTUWn:1␤␤Actually thrown at:␤ in block <unit> at /tmp/MdZTfJTUWn:1␤␤»
psch it just doesn't check for stubs when composing multi methods
for anyone who wants to try their hand at MOP-hacking, src/Perl6/Metamodel/RoleToClassApplier.nqp:104
Skarsnik m: role R { multi method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi method foo($a) { say $a}}; my $a = A.new; $a.foo("hello"); a.foo();
camelia rakudo-moar 019a7f: OUTPUT«5===SORRY!5=== Error while compiling /tmp/SAiOCefGlo␤Undeclared routine:␤ a used at line 1␤␤»
Skarsnik m: role R { multi method foo() {...}}; class A does R { multi method foo() {say "foo"}; multi method foo($a) { say $a}}; my $a = A.new; $a.foo("hello"); $a.foo(); 22:00
camelia rakudo-moar 019a7f: OUTPUT«hello␤Ambiguous call to 'foo'; these signatures all match:␤:(A $: *%_)␤:(A $: *%_)␤ in block <unit> at /tmp/c9ClPMbEQE:1␤␤»
22:00 lab joined
psch that's where we do the check for non-multi stubs 22:00
a few lines down it doesn't do a similar check for multi stubs
(which might be because we can't be completely sure, but i doubt it. if anything else we could check for a proto without candidates and throw the same error then)
s/anything/nothing/
llfourn psch: what do you think the correct behaviour is?
22:01 Zoffix joined
psch llfourn: uh, i'm not sure what's in roast, lemme check 22:01
llfourn m: role R { proto method foo {*} }; class A does R { }; 22:02
camelia ( no output )
llfourn m: role R { proto method foo {*}; multi method foo { ... } }; class A does R { };
camelia ( no output )
llfourn I'm guessing the second one is incorrect
but why shouldn't proto just require it by itself 22:03
psch well, i can't find anything that tests a role with a proto applied to a class
i think having a stub or onlystar proto in a role should require the class to implement at least one candidate
llfourn I mean if you have a type which has a proto but nothing implements a dispatchee isn't that a compile time error?
psch no, methods are late bound 22:04
22:04 lab left
psch m: class A { proto method foo {*} }; say "alive"; say A.new.foo 22:04
camelia rakudo-moar 019a7f: OUTPUT«alive␤Use of uninitialized value of type Any in string context␤Any of .^name, .perl, .gist, or .say can stringify undefined things, if needed. in block <unit> at /tmp/r55aknHnS7:1␤Cannot call foo(A); none of these signatures match:␤ in block <uni…»
psch i don't know if we can know that at compile time either 22:05
llfourn I see. so you don't know whether the multi has a candidate until runtime?
psch until dispatch, yes
m: class A { proto method foo($: ) {*} }; say "alive";
camelia rakudo-moar 019a7f: OUTPUT«alive␤»
psch if you never call a proto without candidates there's no problem... :) 22:06
Skarsnik maybe not allow multi method {...}? (or throw a warning if it's role?)
arnsholt timotimo: Looks like I need to define things in Python after all. I::P doesn't know how to marshal class objects as arguments to Python 22:07
22:07 ^elyse^ left
llfourn mm I guess it's just whether it's possible to make something inheriting from you implement a multi method at compose time.. 22:07
ugexe why would you disallow multi method in a role? it can be used properly and to great effect 22:08
llfourn role X requires you to implement at least one multi method..
ugexe: disallow a stub
ugexe ah 22:09
timotimo oh, damn :(
nine: do you hear that? something's wrong about passing classes across the perl6-python border?
Skarsnik well maybe you want a multi method foo() { ... } and multi method foo($a) { foo() } in your role. sound like legit code 22:10
arnsholt And I suspect named params are NYI as well
llfourn Skarsnik: hmm yes that's not a bad point. Maybe you do want to just have a stub mutli candidate... 22:11
22:11 Zoffix left 22:13 rangerprice joined
psch Skarsnik: the other way around maybe, yeah 22:13
as i said, i'm not convinced what we have is (1) fully designed (and tested) or (2) fully implemented 22:14
Skarsnik: "the other way around" means have a param-less candidate in the role that does some default stuff
Skarsnik: so yes, i agree with the notion
ugexe isnt that what proto method blah(|) { do-stuff(); {*}; do-after-stuff(); }; does? 22:15
psch m: role R { proto method f(|c) {*}; multi method f() { ... }; multi method f($) { self.f() } }; class C does R { multi f() { "doing C-things" } }; C.new.f(1) # resolution also seems a bit lacking
camelia rakudo-moar 019a7f: OUTPUT«Stub code executed␤ in method f at /tmp/bFMr_J72TA:1␤ in method f at /tmp/bFMr_J72TA:1␤ in block <unit> at /tmp/bFMr_J72TA:1␤␤Actually thrown at:␤ in block <unit> at /tmp/bFMr_J72TA:1␤␤»
Skarsnik what I am trying to btw is a Config::Simple module that offer a basic way to have a config file. but you can change the 'driver' by calling for example Config::Simple.new("ini"); that why I want 2 new or 2 read method in it; ~~
22:16 espadrine joined
MadcapJake Are there any other "type adverbs" like `:D` or is that the only one? 22:16
psch ah, no, braino...
m: role R { proto method f(|c) {*}; multi method f() { ... }; multi method f($) { self.f() } }; class C does R { multi method f() { "doing C-things" } }; C.new.f(1) # can't decide against the stub before we know it's a stub 22:17
camelia rakudo-moar 019a7f: OUTPUT«Ambiguous call to 'f'; these signatures all match:␤:(C $: *%_)␤:(C $: *%_)␤ in method f at /tmp/D7zG0w0nfk:1␤ in block <unit> at /tmp/D7zG0w0nfk:1␤␤»
llfourn ugexe: proto doesn't req the child to implement a method. Basically if you do method foo { ... } in a role it requires it but as soon as you put multi it doens't which is unexpected depending on your viewpoint.
psch that last example of mine could probably be solved in RoleToClassApplier.nqp
rangerprice mmm 22:18
llfourn MadcapJake: :U # :)
ugexe :_
MadcapJake llfourn: thanks! Is there a name for that? Can't seem to find details on those in the docs. 22:19
llfourn MadcapJake: docs.perl6.org/language/faq#What_ar...natures%3F 22:21
ugexe also doc.perl6.org/type/Signature#Constr...ned_Values
llfourn amusingly it's in the FAQ # hopefully it's somewhere else too!
llfourn hopes are satisfied 22:22
MadcapJake Woah this signature page is an eye opener! I think some of this stuff should be moved to the language category (somehow) 22:25
jdv79 is there a way to switch the profiler on/off at runtime? 22:26
22:29 rindolf left
masak m: class C { has $.id = $++ }; say C.new.id for ^5 22:33
camelia rakudo-moar 019a7f: OUTPUT«0␤1␤2␤3␤4␤»
masak another reason we don't need "class attributes" :)
llfourn what is $ I don't even... 22:34
Skarsnik how can you count the number of instance of a class? 22:35
ugexe its incrementing an anonymous state variable
jdv79 maintain a custom count?
llfourn m: class C { has $.id = $ ~= 'foo'}; say C.new.id for ^5; 22:37
camelia rakudo-moar 019a7f: OUTPUT«foo␤foofoo␤foofoofoo␤foofoofoofoo␤foofoofoofoofoo␤»
zengargoylew s/id/instance_count/ :P
22:37 Zoffix joined
llfourn ugexe: I see thanks :) 22:37
Zoffix Sheesh! twitter.com/unlocalblog/status/665...5899986944
A person can't have a beer and hack on some code in peace :P
Skarsnik well how you -- when you delete?
jdv79 why do you want an instance count? 22:38
zengargoylew method DESTROY { $!id-- } # eventuall decrement?
jdv79 no
zengargoylew no, guess ot
jdv79 DESTROY is not reliable
i don't know a real answer though. sorry. haven't gotten there yet. 22:39
zengargoylew eventual sorta meant when gc'd or if it ever managed to get called.
masak jdv79: I don't want an instance count. I want a unique ID for each new object I create.
zengargoylew but since id is copy of $ , wont'work
jdv79 isn't that $o.WHICH?
Begi11110 Horror in Paris...
zengargoylew need a $.destroyed = $++; and method foo { $.id - $.destroyed } :) 22:40
22:40 bbkr joined
zengargoylew doesn't think that would work either.. 22:40
Skarsnik Not really x) 22:41
zengargoylew would have to .new a sacrificial object and then not include it in the reconing. 22:42
stmuk Zoffix: I'm giving up on the twitter troll 22:43
finally :)
22:44 zengargoylew left
Zoffix stmuk, are you @steve_mynott? 22:45
stmuk yes! 22:48
22:48 rangerprice left
stmuk colinm.org/language_checklist.html :D 22:48
Zoffix stmuk, eh, I've seen many times the exact same nonsense arguments as that dude on Twitter.
"P6 will kill P5! It will take up all the market share!!" "No one cares about P6! Perl is not a strong brand name!" -_- 22:49
It's one or the other, dude. Either no one cares about Perl or Perl *is* a strong brand name :P
stmuk I couldn't believe he honestly thought Perl 5 was perfect 22:50
it's like he had never used it ;) 22:51
Zoffix :P
22:54 Begi11110 left
masak I guess the same could be said of most languages. frequent users of it are not likely to lean back and state, "nah, it's perfect like this" 22:54
except perhaps Lisp people.
stmuk most programmers have ideas of how to "improve" their language of choice 22:55
Zoffix is a "frequent" user of P5, with 97 active dists on CPAN and ~250 released dists in lifetime
On some level, I can see why the people like that guy feel like that. They see something new and unknown. The fear the boogieman. 22:56
I felt nervous about P5 before I took time to learn P6.
But I'm really annoyed that people like him—instead of advocating P5's strength—are trying to tear down P6. 22:57
Skarsnik P5 is fine, it just look ulgy sometime comparing to P6 (syntax wise) 22:58
stmuk does he dislike Moose etc I wonder since that changes Perl 5? 22:59
masak Zoffix: I'm less sad about people tearing down Perl 6 than I used to be. Perl 6 will survive that.
Zoffix: in the end, what's important and what I care about is people leaving constructive/positive impressions. like writing scripts/modules/frameworks. 23:00
...and applications.
Zoffix I think mst has put it most apt and succinctly: shadow.cat/blog/matt-s-trout/f_ck-perl-6/ 23:02
Maybe I should just starting linking to that post instead of arguing :P
masak is aware of that post :)
but yes, mst is basically making the same point in that post: it's contributions that matter, not communities grinding against each other. 23:04
Zoffix Yeah
timotimo vendethiel is in paris, isn't he? 23:06
jdv79: there's the ops that nqp and rakudo themselves use to start and stop profiling 23:07
jdv79: but i'm not sure if you can start, stop, start, stop and get correct results at the end 23:08
raiph Zoffix: could you turn your design skills on /r/perl6?
Zoffix: er, not could you, of course you could, but, *would you be willing to* :) 23:09
Zoffix raiph, not an active reddit user... what does that mean? :)
masak 'night, #perl6
Zoffix night
raiph gnite
timotimo Zoffix: we can supply our own css rules to make it prettier 23:11
raiph Zoffix: www.reddit.com/r/perl6/ and (this prolly won't work without the right privs: www.reddit.com/r/perl6/about/stylesheet/)
Zoffix Looks fine the way it is IMHO 23:12
MadcapJake So I've written an expanded perl 6 language grammar for Atom Editor that is a lot more colorful than the one included in the builtin language-perl. Check it out and let me know what needs tweaking! github.com/MadcapJake/language-perl6fe Also I plan to add linter support, autocomplete support and atom-build support. 23:13
raiph Zoffix: OK. Thanks. :)
hoelzro MadcapJake++
Zoffix w00t! 23:14
MadcapJake++ sweet. Gonna try it at $work on Monday :)
Zoffix can't run Atom on their home box because too lazy to upgrade to 64-bit box :(
23:16 Zoffix left 23:17 pink_mist joined
timotimo MadcapJake: could you post a screenshot or two? 23:18
23:29 pdcawley_ joined 23:30 bbkr_ joined 23:32 pdcawley left, bbkr left
jdv79 timotimo: ill try that then 23:43
timotimo could just be nqp::startprofiling and nqp::stopprofiling; you can find it in the HLL::Compiler in nqp and/or Perl6::Compiler or Perl6/HLL/Backend.nqp or so 23:44
23:46 sprocket left 23:51 raiph left
dalek rl6-roast-data: af7f7d3 | coke++ | / (9 files):
today (automated commit)
23:52
kudo-star-daily: 18e6880 | coke++ | log/ (3 files):
today (automated commit)
zengargoyle hrm, =finish is just supposed to mean no more Perl 6 code after here, not this is the end of POD documentation right?
23:53 kid51 joined
[Coke] masak: no, the search box is for searching the -site-, not the -page 23:53
jdv79 with the profiler i was able to obseeve the large diff tween using | and || in regeces though. 23:54
MadcapJake timotimo: yeah let me write up a readme and ill add a screenshot. The screenshot will have Fira Code as the font as I developed this highlighter to work well with ligatures! B) 23:57
zengargoyle =finish ... block is in all other respects identical to a C<=pod> block. 23:58
perl6 --doc Module.pm6 ignores stuff after =finish :(
jdv79 ShimmerFairy was or was going to work on pod afaik 23:59