»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
AlexDaniel zostay: right 00:00
star: my $a = 0..2; my $b = 0..2; for cross($a, $b) -> ($x, $y) { say ++$ } 00:01
camelia star-m 2015.09: OUTPUT«1␤2␤3␤4␤5␤6␤7␤8␤9␤»
AlexDaniel m: my $a = 0..2; my $b = 0..2; for cross($a, $b) -> ($x, $y) { say ++$ }
camelia rakudo-moar 3259ba: OUTPUT«1␤»
skids jvcakg: Hello
AlexDaniel zostay: you are right, that's how it was before GLR
00:01 cpage_ joined 00:02 scz joined
zostay even if i wasn't, my mental map got all messed up by that... eventually i will recover 00:02
RabidGravy heads up to anyone who cares, there may be a "slight" infelicity in doing a subsequent .grep on a Supply that is the result of a previous grep
zostay is @$a still safe if $a = 0 .. 10**15? i think it will lazily evaluate, but it will start filling up memory, won't it? 00:05
not important to me for what i'm working on now, but to help me rebuild my mental map... 00:06
vendethiel m: say (@(my $a = 15)).perl
camelia rakudo-moar 3259ba: OUTPUT«(15,)␤»
leont Why would that not be safe?
zostay i just meant it would create an array with 10**15 elements over time, right? 00:07
or not?
vendethiel no, it's only a one-element array
zostay i'm trying to understand
what? i missed something 00:08
leont List context doesn't do much 00:09
00:09 kjs_ left
leont And you probably mean ... not .. 00:10
jvcakg anyone here has a free time on making me a site? we can be partners, must be talented =)
leont .. is a range, ... a sequence
zostay okay, i'll RTFM again
masak 'night, #perl6
jvcakg I only know C++ =/ 00:11
ely-se why can't you pass environment variables to Proc::Async?
00:11 firstdayonthejob left
jvcakg hobbyist? 00:12
passionateist? is that a word
vendethiel jvcakg: no one knows C++ //cc El_Che 00:14
ely-se*. sorry El_Che :s
jvcakg =P
ely-se I'm going crazy
stupid deadlocks
jvcakg Yea I would take on Perl 00:15
but sooooo big
I reallly like the modules
00:15 rurban1 left
pmqs_ zip 00:15
jvcakg remember the zip drives? that went obsolete fast! 00:16
leont ely-se: good point!
00:19 RabidGravy left 00:20 protium left 00:28 zacts left 00:29 zacts joined
jvcakg Perl ftw 00:30
00:31 zacts left 00:33 zacts joined 00:39 ely-se left 00:59 TEttinger joined 01:03 newbie joined, newbie is now known as Guest27320 01:04 yqt left 01:14 _nadim left 01:21 colomon left
mspo why is doc.perl6.org/language/nativecall using { * } (whatever code, I think) in all of the examples? 01:21
instead of using ... or !!!
01:22 colomon joined
skids mspo: that syntax is an "onlystar" whereas { ... } is "stub code" 01:25
01:26 spider-mario left
skids One is a prototype, the other is a die-if-you-ever-fallback-to-this 01:26
01:27 SCHAAP137 left
Juerd m: sub foo { * }; foo() 01:27
camelia ( no output )
Juerd Dunno, having a stub might make debugging easier :) 01:28
m: sub foo { ... }; foo()
camelia rakudo-moar 3259ba: OUTPUT«Stub code executed␤ in sub foo at /tmp/ZjHWcpLeh5 line 1␤ in block <unit> at /tmp/ZjHWcpLeh5 line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/ZjHWcpLeh5 line 1␤␤»
skids m: ...; # The stub is generic, so it would have to be aalyzed out of the code by the compiler. 01:29
camelia rakudo-moar 3259ba: OUTPUT«Stub code executed␤ in block <unit> at /tmp/sycFqYvCMG line 1␤␤»
skids Also, there are NYI ways to treat onlystars with wrapping IIRC.
01:31 colomon left, colomon joined
mspo well in my case 01:32
* segv and ... works ;) 01:33
skids Huh, does { 1 } work?
01:34 leont left 01:43 colomon left
AlexDaniel { ‘it should’ } 01:45
skids I would think an "is nativecall" sub with actual code in the body should probably warn. 01:46
01:46 colomon joined
skids *is native 01:47
(Warn as NYI, that is, until we have the S06 wrapping stuff, and definitely not run the native code without the {*} somewhere in there) 01:48
01:50 pierre-vigier joined, vendethiel left
mspo I think { * } must be expanding to something 01:54
skids What it's supposed to expand to is in S06, but I don't think it's quite implemented that way yet. 01:55
mspo okay I think this is some other kind of bug 01:56
this is amazing 02:00
it's really just a sometimes kind of situation 02:04
gist.github.com/msporleder/2e59371765812a3c1cd6 02:06
just reordering the file is enough to make it segv vs not
skids heisenbugs--
mspo it's consistent 02:07
the ones that work always work :)
oh a bunch of cached stuff is landing in ~/.perl6 ? 02:09
02:09 vendethiel joined
gfldex do i understand github.com/rakudo/rakudo/blob/nom/...d.nqp#L636 right, that the tags are never handed over to the to be imported package? 02:09
02:10 colomon left 02:11 AlexDaniel left 02:12 scz left 02:16 colomon joined 02:17 scz joined 02:18 pierre-vigier left 02:19 lokien_ left
mspo skids: I added "use v6;" to all foo's and now they all work 02:20
02:26 bjz joined
dalek c: 03c2f46 | skids++ | doc/Language/traps.pod:
Add a caveat about tricky precedence on ranges
02:28
02:29 bjz_ left 02:32 vendethiel left 02:43 Spryttan joined 02:44 Spryttan left 02:45 vendethiel joined 02:46 protium joined
skids gfldex: I don't think any code in the to-be-imported package is called -- just the EXPORT hash is used. 02:48
gfldex the calling of EXPORT in the imported package is called here github.com/rakudo/rakudo/blob/nom/...d.nqp#L664 02:54
02:54 sortiz joined
gfldex my $result := &EXPORT(|@positional_imports, |@to_import); # or somesuch is on my v6.d wishlist 02:55
02:55 Util_ is now known as Util
skids Maybe the EXPORT hash could do some fancy AT-POS stuff :-) 02:57
gfldex i just need the tags as named parameters in &EXPORT 03:02
EXPORT as it is, is a nice flexible ways to react to the wishes of a modules user. As soon as you start to do that, tags become pretty much useless. You have to provide them in is export but you can't devide what symbols to return from &EXPORT based on those tags. 03:03
so you either hava tags or positionals for use 03:04
03:08 vendethiel left, scz left 03:17 scz joined 03:24 protium left 03:25 lichtkind left, scz left 03:31 scz joined 03:48 kid51 left 03:51 noganex joined 03:53 Guest27320 left, noganex_ left 03:56 pierre-vigier joined 03:57 scz left 04:00 scz joined 04:02 pierre-vigier left 04:05 pierre-vigier joined 04:21 pierre-vigier left 04:37 mohae left 04:38 mohae joined
autarch hmm, I just said this in #perl6-toolchain but there's more folks here so I'll repeat it ... 04:46
I think I have a more or less working Test::Stream 04:47
and by more I mean it has events, a Test.pm6-alike sub exporter, and it has a context system for making sure that test events appear to come from the place where you call ok() rather than inside the ok() sub or elsewhere
and by less I mean no built-in IPC support and it could probably use more tests
and it has no docs yet
github.com/autarch/perl6-Test-Stream
skids autarch++ though I don't know much about TAP etc. 04:53
autarch actually, the whole point of this system is that it's not tied to TAP at all
though the distro does include a TAP formatter
but it'd be very easy to output other test formats too
skids Have you taken a look at the specialized roast/packages/Test/ modules? -- some of them get a little deep in the weeds. 04:57
04:57 lostinfog left
autarch I don't really expect this to replace anything in the core 04:58
04:58 revhippie left
autarch We talked about making the Test.pm6 in core an internal-only thing and recommend this distro (probably renamed to Test) for the ecosystem to use 04:59
it's actually really important that everyone use an event based test system as soon as possible in order to make it easier to build testing tools (and to test the testing tools)
but I don't know that there's any desire to actually put the thing I wrote into core, and my understanding is that p6 is aiming for a lightweight core to avoid the p5 "why do we have this ancient piece of junk in core?!" problem 05:00
skids Certainly parallelizing tests is good. Is there any predictability built in, so that we only get spurious failures due to weird scheduling when we want to? 05:01
MadcapJake lol the github perl6 syntax highlighter catches my method «is-before» as two keywords seperated by a minus op :P 05:04
autarch skids: what I'm working on has very iittle to do with parallelization 05:05
05:05 parisba_ is now known as parisba 05:06 pierre-vigier joined
autarch it's just an abstraction of testing from "spit out some TAP to stdout" to "send an abstract event describing the thing (Plan, Test, Skip) to a bunch of listeners and let the listeners do what they want (and one of those listeners may be a TAP formatter that prints to stdout)" 05:06
what is possible under this system is to implement an IPC layer so events can be passed from one thread or process to a central monitoring process - so it provides a reasonable toolset for parallelization, and I'd like to add an actual IPC mechanism to the distro 05:07
05:13 pierre-vigier left 05:20 vendethiel joined 05:25 Psyche^_ joined 05:29 Psyche^ left 05:37 sammers joined 05:39 pierre-vigier joined 05:43 pierre-vigier left 05:44 vendethiel left 05:50 Cabanossi left 05:53 Cabanossi joined 05:58 abraxxa joined 05:59 kaare_ joined 06:00 raiph joined 06:01 raiph left 06:08 khw left 06:11 jme` left 06:45 protium joined 06:55 scz left 07:01 scz joined 07:02 CIAvash joined 07:14 BenGoldberg left 07:26 skids left, scz left 07:30 abraxxa left 07:31 scz joined 07:46 daotoad joined 07:50 sjoshi joined 08:09 psy left 08:10 psy_ joined 08:12 darutoko joined 08:13 skaji left 08:21 daotoad left, daotoad joined 08:27 pierre-vigier joined
gfldex m: gist.github.com/57bb505e41eb7649b1ba 08:32
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/GHw2wy1jJc␤Confused␤at /tmp/GHw2wy1jJc:1␤------> 3https:7⏏5//gist.github.com/57bb505e41eb7649b1ba␤ expecting any of:␤ colon pair␤»
gfldex what am i doing wrong? ^^^ 08:33
08:36 awwaiid left
moritz camelia doesn't seem to recognize the gist URL 08:37
08:39 sjoshi left 08:40 dustinm` left 08:43 dustinm` joined 08:54 _nadim joined 08:55 bpmedley joined, daotoad left 08:56 firstdayonthejob joined 08:59 perl6newbee joined 09:05 daotoad joined 09:11 lokien_ joined
gfldex ===SORRY!=== Error while compiling /home/dex/projekte/perl6/tmp/import/export.pod.p6 09:12
Error while importing from 'ParametrisedLib':
no EXPORT sub, but you provided positional argument in the 'use' statement
at /home/dex/projekte/perl6/tmp/import/export.pod.p6:57
------> arametrisedLib NewBaseClass, {:consumer}⏏;
that's the error that gist produces and leaves me confused
any ideas why it cant see the &EXPORT? 09:13
09:14 rindolf joined 09:16 daotoad left
sortiz gfldex, Try: import ParametrizedLib { NewBaseclass, :consumer}; # Just guessing 09:20
moritz gfldex: I think EXPORT must be outside the module
09:21 RabidGravy joined
gfldex sortiz: no luck 09:27
09:31 _nadim left, _nadim joined
RabidGravy m: my $supp-a = Supply.from-list(<foo bar baz>); $supp-a.tap( { say "original $_" }); my $supp-b = $supp-a.grep(/bar/ ).map({ $_.uc }); $supp-b.tap( { say "B: $_" }); $supp-b.grep({ /foo/ }).tap({ say "C: $_" }); 09:35
camelia rakudo-moar 3259ba: OUTPUT«original foo␤original bar␤original baz␤B: BAR␤C: FOO␤»
RabidGravy ^ I'm pretty damned sure that it's not supposed to do that 09:36
09:38 rurban joined
RabidGravy If someone thinks that it is expected behaviour and I'd be all ears as to why they think so 09:38
sortiz m: package Foo { our sub EXPORT(|a) { say |a; } }; import Foo Any, Int, <:flags &gol>;
camelia ( no output )
RabidGravy as it stands it's totally broken Net::AMQP as it uses that pattern all over the place 09:39
sortiz m: package Foo { our sub EXPORT(|a) { say |a; } }; Foo::EXPORT(Any, Int, <:flags &gol>); 09:40
camelia rakudo-moar 3259ba: OUTPUT«(Any)(Int)(:flags &gol)␤»
09:40 pmqs_ is now known as pmqs
sortiz Seems that import extra args is NYI 09:40
dalek ecs: 2168554 | (Sterling Hanenkamp)++ | S04-control.pod:
[S04] Add missing parenthesis in zip() example
09:41
ecs: 21525aa | niner++ | S04-control.pod:
Merge pull request #105 from zostay/zip-parens

  [S04] Add missing parenthesis in zip() example
gfldex sortiz: it does work when the modules are put into individual files
dalek osystem: 8767ce6 | pmqs++ | META.list:
Update META.list
osystem: 43517bd | niner++ | META.list:
Merge pull request #126 from pmqs/patch-3

Aded Archive-SimpleZip
sortiz Maybe that EXPORT handling is per compunit 09:44
nine sortiz: do you mean "import" specifically or EXPORT in general? 09:45
09:49 bpmedley left
RabidGravy wonders whether it is worth bisecting the above as there have been several opportunities to break it 09:51
sortiz Both, see:
m: module Foo { sub bar is export {} }; module Bar { sub foo is export {} }; UNIT::EXPORT::DEFAULT::.keys.say 09:52
camelia rakudo-moar 3259ba: OUTPUT«(&foo &bar)␤»
sortiz I.e. un the same compunit, both modules uses the same UNIT.
RabidGravy yes 09:53
sortiz s/un/in
09:54 [ptc] left, burnersk left
RabidGravy I don't suppose anyone knows the commit where the GLR branch got merged? 09:56
09:58 [ptc] joined
sortiz So, when use or import search for an EXPORT sub, they expect only one per UNIT. I'm just speculating. 09:58
RabidGravy yes that is currently the case 09:59
10:00 pierre-vigier left, burnersk joined, pierre-vigier joined
sortiz Make sense, that way we can have many packages (classes, emums, etc.) per compunit, all sharing the same import/export machinery. 10:02
nine RabidGravy: commit 9622594885a50a761887a7bb451102ad2adeb9c1 10:06
sortiz: yes, module management is all about comp units 10:07
RabidGravy I'm pretty certain that the offending commit for the Supply.grep badness is a8231f14 but I'll do the full bisect anyway 10:08
nine, cheers
moritz RabidGravy: 9622594885a50a761887a7bb451102ad2adeb9c1 seems to have been the GLR merge 10:09
RabidGravy cool
10:09 burnersk left, [ptc] left
RabidGravy that's the last time I know that Net::AMQP was tested 10:09
10:10 vendethiel joined
RabidGravy actually this an even more succinct example, with no map involved 10:12
m: Supply.from-list(<foo bar baz>).grep(/foo/).grep(/baz/).tap({say $_}
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/I8aBuHgh0K␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/I8aBuHgh0K:1␤------> 3z>).grep(/foo/).grep(/baz/).tap({say $_}7⏏5<EOL>␤ expecting any of:␤ post…»
RabidGravy m: Supply.from-list(<foo bar baz>).grep(/foo/).grep(/baz/).tap({say $_})
camelia rakudo-moar 3259ba: OUTPUT«baz␤»
10:13 [ptc] joined
RabidGravy that is, it appears that a subsequent grep on a supply derived by grep goes back to the original supply 10:13
and I really, really can't think of any plausible reason why that might be intentional 10:14
10:15 pierre-vigier left
moritz yes, bug 10:15
10:16 burnersk joined
sortiz m: use NativeCall; class Foo is repr('CStruct') { }; sub foo(Pointer[Foo]) is native('bar') { }; 10:16
camelia ( no output )
sortiz m: use NativeCall; class Foo is repr('CStruct') { sub foo(Pointer[Foo]) is native('bar') { }; } # Bug ? 10:17
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/EbcMCANe5k␤An exception occurred while parameterizing Pointer␤at /tmp/EbcMCANe5k:1␤Exception details:␤ Cannot call infix:<===>(Foo, Str); none of these signatures match:␤ ($?)␤ ($a, $b)…»
10:20 pierre-vigier joined 10:32 vendethiel left
masak good antenoon, #perl6 10:37
10:39 vendethiel joined
sortiz o/ masak 10:39
Hotkeys good early morning masak :p 10:41
RabidGravy good quarter to eleven GMT 10:44
10:45 TEttinger left
RabidGravy bisecting over four months of commits is really rather tedious 10:46
nearly every step requires a make distclean && rm -rf install 10:47
moritz RabidGravy: if you suspect one commit, you can simply build it and the previous commit; if the previous succeeds and the one fails, you've found the offending commit 10:48
RabidGravy I'm pretty sure I know which commit already to be honest (a8231f14) but it seems too obvious 10:50
10:51 erdic left
moritz RabidGravy: then it's easier to test that hypothesis than to find for that in the vast space of possible offenders 10:51
RabidGravy indeed, but not enough coffee yet 10:54
it is does throw something interesting up
that is that the parse stage varies wildly over time 10:55
10:59 pierre-vigier left
[Tux] UNDER 12! 11:00
csv-ip5xs 50000 18.119 12.488
test 50000 23.267 22.634
test-t 50000 12.603 11.717
csv-parser 50000 51.006 0.912
abaugher, leading v fixed. Try again 11:03
nine RabidGravy: do you use git bisect run?
RabidGravy no
does that help? 11:04
masak I'm curious, is someone actively using Tux++'s benchmarks to optimize Rakudo?
[Tux] Text::CSV requires Perl version 6.0.0. Cannot continue.
moritz it helps you to automate the bisects
[Tux] that is without the v. I need guidance I think
RabidGravy I think it's the 6.c or whatever
moritz [Tux]: use v6.c;
RabidGravy or just plain 6 will do 11:05
11:05 azawawi joined
azawawi hi 11:05
nine RabidGravy: well it makes git do all the tedious work, so you can do something else :) As long as you can automate the testing
moritz \o azawawi 11:06
masak RabidGravy: `git bisect run` takes a shell command as arguments, and considers exit code 0 to be "good" and other exit codes to be "bad"
nine [Tux]: there's no 6.0.0. It's always 6.c: use v6.c; and in the META6.json "perl": "6.c", # without the v
RabidGravy oh okay 11:07
11:07 hackworth joined, hackworth left
azawawi what's the best way to *depend* on a specific module under platform X in META.info? 11:07
RabidGravy I think it's time to flip Test::META to use always fail for a v
jdv79 hola * 11:08
yoleaux 11 Jan 2016 12:15Z <Zoffix> jdv79: How is work on the P6 variant of PAUSE/CPAN/MetaCPAN going? Maybe the repo should be moved under the perl6 GitHub organization, so it'd be easier for potential volunteers to finds and contribute to?
11 Jan 2016 12:18Z <Zoffix> jdv79: we also now have #perl6-toolchain you may be interested in joining.
masak azawawi: you mean you want the dependency to be different, depending on platform?
azawawi masak: yup 11:09
masak hola jdv79
azawawi: no idea. is that even possible?
11:09 virtualsue joined
azawawi masak: e.g. on windows, i want to depend on Alien::OpenCV::Windows to install the DLL . On unix, i need LibraryMake but not on windows 11:09
masak: otherwise OpenCV will be bloated given that the openv (static) DLL is like 3.24MB 11:10
masak: the zipped tarball from github that is
jdv79 anything extraordinarily interesting happen in the last few weeks?
masak azawawi: this might be something to ask about in #perl6-toolchain 11:11
jdv79: ...Christmas? :)
jdv79 i ducked out just after new years so i caught that part 11:12
[Tux] Hmm, it wasn't under 12. I looked at the wrong column :( sorry
azawawi masak: done 11:13
jdv79: github.com/azawawi/perl6-opencv/bl...drawing.p6 :) 11:14
11:16 Actualeyes joined 11:20 virtualsue left 11:25 pierre-vigier joined
jdv79 masak: i meant a couple weeks. my bad. thanks. 11:26
pierre-vigier p6: <121 200 333 392 605 684 707 944 909 320 1221 1296 1404 1414 1080>.map( * / ++$ ).map(*.chr).join.flip.say
camelia rakudo-moar 3259ba: OUTPUT«Hello everybody␤»
lucs m: unit class A; class B::C { }; say A::B::C.perl; 11:30
camelia rakudo-moar 3259ba: OUTPUT«A::B::C␤»
lucs m: unit class A; class Test::C { }; say A::Test::C.perl;
camelia rakudo-moar 3259ba: OUTPUT«A::Test::C␤»
lucs m: unit class A; class X::C { }; say A::X::C.perl;
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&C'␤ in block <unit> at /tmp/ZCdm_oTPlE line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/ZCdm_oTPlE line 1␤␤»
lucs Why does the last one fail?
pierre-vigier i might be totally wrong, however 11:32
say A.WHAT
p6: say A.WHAT
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tmpfile␤Undeclared name:␤ A used at line 1␤␤»
pierre-vigier A is unkonw in core 11:33
where X is not
say X.WHAT
p6: say X.WHAT
camelia rakudo-moar 3259ba: OUTPUT«(X)␤»
lucs Hmm...
p6: say Test.WHAT
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tmpfile␤Undeclared name:␤ Test used at line 1␤␤»
lucs Okay, makes sense I guess. 11:34
11:34 z8 joined
pierre-vigier X might be reserverd only for Exception 11:34
p6: unit class A; A::X.WHAT.say 11:35
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&X'␤ in block <unit> at /tmp/tmpfile line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/tmpfile line 1␤␤»
pierre-vigier but that is strange
lucs What's 'p6:' as opposed to 'm:'? 11:36
pierre-vigier i don't know if there is any
lucs Oh, right, according to the output, they do look the same.
pierre-vigier rakudo: "test".say 11:37
camelia rakudo-moar 3259ba: OUTPUT«test␤»
lucs That too :)
geekosaur I think they're currently the same becaase rakudo-moar's the only one that works right now. but notionally p6: runs in every working backend?
jdv79 .tell Zoffix absolutely nothing. i fell off the grid for two weeks. sure, i can move them over.
yoleaux jdv79: I'll pass your message to Zoffix.
11:41 pierre-vigier left 11:46 pmurias joined 11:48 sortiz left
RabidGravy .tell pierre-vigier yes X is implicitly at least created in the setting because that's where all the exceptions live 11:48
yoleaux RabidGravy: I'll pass your message to pierre-vigier.
lucs m: unit class A; class X::C { }; say X::C.perl; # This is why I'm confused. 11:49
camelia rakudo-moar 3259ba: OUTPUT«A::X::C␤»
lucs m: unit class A; class X::C { }; say A::X::C.perl;
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&C'␤ in block <unit> at /tmp/khvZqzkGHL line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/khvZqzkGHL line 1␤␤»
RabidGravy because you're still in A 11:50
m: class A { class X:::C { } }; say A::X::C.perl;
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tnh3fiXN29␤Cannot use adverb C on a type name (only 'ver' and 'auth' are understood)␤at /tmp/tnh3fiXN29:1␤------> 3class A { class X:::C7⏏5 { } }; say A::X::C.perl;␤ expecting any of:␤ …»
RabidGravy m: class A { class X::C { } }; say A::X::C.perl; 11:51
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&C'␤ in block <unit> at /tmp/Q0ULrbn43G line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/Q0ULrbn43G line 1␤␤»
RabidGravy eh?
11:51 rindolf left
lucs m: unit class A; class B::C { }; say A::B::C.perl; 11:52
camelia rakudo-moar 3259ba: OUTPUT«A::B::C␤»
RabidGravy I'm confused now as well 11:53
11:55 mort96 left
azawawi tadzik: ping 11:57
11:57 spider-mario joined
azawawi .tell tadzik Shell::Command is now failing to install on windows after the which command was added. Please consider using File::Which 11:58
yoleaux azawawi: I'll pass your message to tadzik.
RabidGravy I can only think that the 'X' is actually special cased somewhere
lucs Actually, it appears to fail in the same way for all built-in types (the one I've tried anyway). 12:00
m: unit class A; class Bag::C { }; say A::Bag::C.WHAT
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&C'␤ in block <unit> at /tmp/dFjuudGQvw line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/dFjuudGQvw line 1␤␤»
lucs m: unit class A; class Bag::C { }; say Bag::C.WHAT
camelia rakudo-moar 3259ba: OUTPUT«(C)␤»
lucs m: unit class A; class Bag::C { }; say Bag::C.perl
camelia rakudo-moar 3259ba: OUTPUT«A::Bag::C␤»
RabidGravy I cannot comment on whether it is intentional or not, but I can hypothesize a failure mode 12:01
azawawi zef/panda both fail at different things... zef works but you cant --force it :) panda will ignore your --force with the famous "Sorry.. already installed" ... :) 12:02
RabidGravy time for a new one
;-)
azawawi I declare opencv to be working on windows but not when installed through panda or zef.... :) 12:03
12:04 pierre-vigier joined
azawawi wonders where is rakudo star 2015.12 (rakudo.org/downloads/star) 12:06
RabidGravy azawawi++ coolio I can't think of a use I may have for it quite yet but cool nonetheless 12:07
azawawi RabidGravy: I want to make a demo script where camelia flies around and then eats a python :) 12:08
another pet project to start later for Arduino with Perl 6 .... Implementing github.com/firmata/protocol :) 12:09
RabidGravy Ooh, then you'll be wanting to do some serial port thingy :) I've been putting it off myself, but will need it to drive a PiLite 12:11
azawawi and then try to remote control an arduino board through firmata over a bluetooth connection in Perl 6
RabidGravy I think I've got a bluetooth shield around somewhere 12:12
azawawi i bought an HC-06 bluetooth chip 12:13
pretty cheap
RabidGravy I was going to have a play with the MQTT thing Arduino -> RabbitMQ -> Perl 6 at some point but seem to have got totally bogged down in fixing Net::AMQP 12:14
12:14 sena_kun joined
azawawi cool 12:15
also simplecv.org/ is now another project for OpenCV::Simple :) 12:16
azawawi windows reboot... brb & 12:17
12:17 azawawi left
lucs m: class A { class X::Meh { }; }; class B { class X::Meh { }; }; die X::Meh.new; 12:21
camelia rakudo-moar 3259ba: OUTPUT«B::X::Meh<140541024946368>␤ in block <unit> at /tmp/aenCLaASRp line 1␤␤»
lucs m: class A { class X::Meh { }; }; class B { class X::Meh { }; }; die B::X::Meh.new;
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&Meh'␤ in block <unit> at /tmp/SwAvDhVyFE line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/SwAvDhVyFE line 1␤␤»
12:21 kid51 joined
lucs How can I be sure to avoid name collisions in the X namespace? 12:22
Do you folks do something like this in your modules? class X::MyModule::Meh ? 12:23
RabidGravy yes, but I always only use them in the module
so it isn't a problem
12:24 azawawi joined
lucs Ah, I hit the problem when testing exceptions (from another file, eh). 12:24
RabidGravy m: class A { class X::Meh { }; method foo() { die X::Meh.new } }; class B { class X::Meh { }; method foo() { die X::Meh.new }}; A.foo 12:25
camelia rakudo-moar 3259ba: OUTPUT«A::X::Meh<140617387570104>␤ in method foo at /tmp/o27asXUoVa line 1␤ in block <unit> at /tmp/o27asXUoVa line 1␤␤»
RabidGravy m: class A { class X::Meh { }; method foo() { die X::Meh.new } }; class B { class X::Meh { }; method foo() { die X::Meh.new }}; B.foo
camelia rakudo-moar 3259ba: OUTPUT«B::X::Meh<139659739210712>␤ in method foo at /tmp/Eo708hzNdL line 1␤ in block <unit> at /tmp/Eo708hzNdL line 1␤␤»
lucs Well, that works, but I was trying to pass around the exceptions with throws-like(), and tripping all over myself with these failures. 12:28
RabidGravy throw-like will match the short name fine 12:29
lucs Hmm... I'll revise my code...
RabidGravy infact 12:30
12:31 pierre-vigier left
RabidGravy m: use Test; class A { class X::Meh { }; method foo() { die X::Meh.new } }; throws-like { A.foo }, X::Meh, "there"; 12:31
camelia rakudo-moar 3259ba: OUTPUT« 1..2␤ ok 1 - code dies␤ not ok 2 - right exception type (A::X::Meh)␤ ␤# Failed test 'right exception type (A::X::Meh)'␤# at /home/camelia/.perl6/2015.12-212-g3259ba3/precomp/6F03C0411DF045AC18E1EFD65118CA6D717A8AA5.1452723027.09182/3…»
RabidGravy m: use Test; class A { class X::Meh { }; method foo() { die X::Meh.new } }; throws-like { A.foo }, A:X::Meh, "there"; 12:32
camelia rakudo-moar 3259ba: OUTPUT«5===SORRY!5=== Error while compiling /tmp/ZxGhuoRVG0␤Invalid type smiley 'X' used in type name␤at /tmp/ZxGhuoRVG0:1␤------> 3:Meh.new } }; throws-like { A.foo }, A:X7⏏5::Meh, "there";␤ expecting any of:␤ pair value␤»
RabidGravy m: use Test; class A { class X::Meh { }; method foo() { die X::Meh.new } }; throws-like { A.foo }, A::X::Meh, "there";
camelia rakudo-moar 3259ba: OUTPUT«Could not find symbol '&Meh'␤ in block <unit> at /tmp/qJXa0wWa_G line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/qJXa0wWa_G line 1␤␤»
RabidGravy m: use Test; class A { class X::Meh { }; method foo() { die X::Meh.new } }; throws-like { A.foo }, X::Meh, "there";
camelia rakudo-moar 3259ba: OUTPUT« 1..2␤ ok 1 - code dies␤ not ok 2 - right exception type (A::X::Meh)␤ ␤# Failed test 'right exception type (A::X::Meh)'␤# at /home/camelia/.perl6/2015.12-212-g3259ba3/precomp/6F03C0411DF045AC18E1EFD65118CA6D717A8AA5.1452723027.09182/3…»
RabidGravy okay that'll be weird right there
I have tests that do exactly that
12:34 pmurias left
lucs Yeah, that looks like what I was trying. 12:34
RabidGravy: Are you saying that you have tests that don't work (anymore?) as expected? 12:38
RabidGravy no
m: use Test; module A { class X::Meh is Exception { }; class C { method foo() { X::Meh.new.throw } } }; throws-like { A::C.foo }, X::Meh, "there";
camelia rakudo-moar 3259ba: OUTPUT« 1..2␤ ok 1 - code dies␤ ok 2 - right exception type (A::X::Meh)␤ok 1 - there␤» 12:39
RabidGravy it was just a bad example
lucs Oh.
RabidGravy If the class isn't an Exception it will never work 12:40
lucs With throws-like()? It better not, eh. 12:41
I'll revise my code, see if I can fix it.
RabidGravy no, but the example I ran first it wasn't which confused me 12:42
(doing ten things at once)
12:43 azawawi left 12:46 rurban left 12:48 azawawi joined 12:50 pierre-vigier joined
pierre-vigier Is there any way to get the private methods added by a role? 12:55
yoleaux 11:48Z <RabidGravy> pierre-vigier: yes X is implicitly at least created in the setting because that's where all the exceptions live
pierre-vigier p6: role A { method A() {}; method !B() { } };say A.^methods; 12:56
camelia rakudo-moar 3259ba: OUTPUT«(A)␤»
pierre-vigier p6: role A { method A() {}; method !B() { } };say A.^private_methods;
camelia rakudo-moar 3259ba: OUTPUT«Method 'private_methods' not found for invocant of class 'Perl6::Metamodel::ParametricRoleGroupHOW'␤ in block <unit> at /tmp/tmpfile line 1␤␤»
pierre-vigier i found nothing in the doc
RabidGravy m: role A { method A() {}; method !B() { } };say A.^methods(:all) 12:57
camelia rakudo-moar 3259ba: OUTPUT«(A)␤»
RabidGravy oh I did an example yesterday but I forgot 12:58
12:59 SCHAAP137 joined
pierre-vigier i checked as well the rakudo source for ParametricRoleHOW and ParametricRoleGroupHOW 12:59
but did not found anything
moritz : role A { method A() {}; method !B() { } }; say A.^private_method_table().keys 13:04
m: role A { method A() {}; method !B() { } }; say A.^private_method_table().keys
camelia rakudo-moar 3259ba: OUTPUT«Method 'private_method_table' not found for invocant of class 'Perl6::Metamodel::ParametricRoleGroupHOW'␤ in block <unit> at /tmp/M1IGwJHW4z line 1␤␤»
RabidGravy ah yes, that was it
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates(0).private_method_table(A).keys 13:05
camelia rakudo-moar 3259ba: OUTPUT«Too many positionals passed; expected 2 arguments but got 3␤ in any candidates at gen/moar/m-Metamodel.nqp line 2653␤ in block <unit> at /tmp/M0rCSTafDD line 1␤␤»
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates(0).private_method_table().keys
camelia rakudo-moar 3259ba: OUTPUT«Too many positionals passed; expected 2 arguments but got 3␤ in any candidates at gen/moar/m-Metamodel.nqp line 2653␤ in block <unit> at /tmp/CB_scRG3gp line 1␤␤»
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates(0).perl
camelia rakudo-moar 3259ba: OUTPUT«Too many positionals passed; expected 2 arguments but got 3␤ in any candidates at gen/moar/m-Metamodel.nqp line 2653␤ in block <unit> at /tmp/xW1R_yOfeM line 1␤␤»
timotimo o/
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates[0].private_method_table().keys
camelia rakudo-moar 3259ba: OUTPUT«Method 'private_method_table' not found for invocant of class 'A'␤ in block <unit> at /tmp/nZrIOjOXtu line 1␤␤»
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates[0].private_methods() 13:06
camelia rakudo-moar 3259ba: OUTPUT«Method 'private_methods' not found for invocant of class 'A'␤ in block <unit> at /tmp/X3UocRFlCG line 1␤␤»
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates[0].^private_methods()
camelia rakudo-moar 3259ba: OUTPUT«Method 'private_methods' not found for invocant of class 'Perl6::Metamodel::ParametricRoleHOW'␤ in block <unit> at /tmp/kfy25A_Gro line 1␤␤»
moritz m: role A { method A() {}; method !B() { } }; say A.^candidates[0].^private_method_table().keys
camelia rakudo-moar 3259ba: OUTPUT«(B)␤»
moritz ok, that was a tough ride :-) 13:07
\o timotimo
pierre-vigier hum, i'm confused 13:08
moritz don't worry; for some of us, that's quite normal.
pierre-vigier in core, it seems that role is first applied to a strawman to check for collisions 13:09
and after, that "dummy" class is introspected
m: role A { method A() {}; method !B() { } }; say A.^candidates 13:11
camelia rakudo-moar 3259ba: OUTPUT«((A))␤»
pierre-vigier m: role A { method A() {}; method !B() { } }; say A.^candidates[0]
camelia rakudo-moar 3259ba: OUTPUT«(A)␤»
13:12 AndyDee left
RabidGravy .tell jnthn I don't believe you intended for rt.perl.org/Ticket/Display.html?id=127297 to happen :-\ 13:12
yoleaux RabidGravy: I'll pass your message to jnthn.
pierre-vigier m: role A { method A() {}; method !B() { } }; say A.^candidates[0].HOW 13:16
camelia rakudo-moar 3259ba: OUTPUT«Perl6::Metamodel::ParametricRoleHOW.new␤»
pierre-vigier m: role A { method A() {}; method !B() { } }; say A.HOW
camelia rakudo-moar 3259ba: OUTPUT«Perl6::Metamodel::ParametricRoleGroupHOW.new␤»
pierre-vigier that explains 13:17
m: role A { method A() {}; method !B() { } }; say A.new.^private_method_table 13:18
camelia rakudo-moar 3259ba: OUTPUT«B => B␤»
pierre-vigier m: role A { method A() {}; method !B() { } }; say A.new.^private_method_table.keys
camelia rakudo-moar 3259ba: OUTPUT«(B)␤»
13:19 bowtie left
pmqs Is DESTROY for a class always invoked? 13:20
m:class c { method DESTROY() { say "destroy"; } }; { my $x = c.new ; }
m: class c { method DESTROY() { say "destroy"; } }; { my $x = c.new ; }
camelia ( no output )
pmqs I see it invoked sometimes, but mostly not
Am I missing something obvious? 13:21
13:21 bowtie joined
RabidGravy it is called when the garbage collector gets to the object 13:21
so if the program is exiting anyway then it may not be
13:22 sena_kun left, xpen joined
pmqs any way to reliably tidy up on object destruction? 13:22
if DESTROY doesn't seem to get called all the time 13:23
nine pmqs: LEAVE or END phasers, depending on what you want to do during destruction
end _when_ you need it done obviously 13:24
13:24 Skarsnik joined
pmqs nine, really want it when the object goes out of scope 13:24
nine then LEAVE is what you need
pmqs nine, ta. Will have a play with that 13:25
nine { my $obj = Obj.new; LEAVE $obj.cleanup; }
arnsholt pmqs: In case you're wondering *why* destructors aren't called reliably, it's because guaranteeing reliable destructors (as well as the order they're called in) more or less forces you to do some kind of refcounting GC 13:26
Skarsnik Hello
hey pmqs, why no read support in your zip module? x) 13:27
dalek line-Perl5: d64121b | (Stefan Seifert)++ | META.info:
Fix warning about the leading "v" in Perl 6 version in META.info
line-Perl5: b71be5a | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
Replace "native" sub by standard "is native" traits

Now that the whole mechanism for finding the bundled native library is provided by NativeCall and Perl 6, we can use a plain constant for simplifying the code.
line-Perl5: 9bd89e4 | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
Replace baroque OpaquePointer by just Pointer

Now that we require Perl 6.c, we can be sure it supports the shorter "Pointer".
pmqs Skarsnik, there's already a module that does that File::Zip (I think) 13:29
arnsholt, aah yes. remember reading that
Skarsnik Yes, but I don't want to use 2 modules with different interface for the the "same" thing
13:29 xpen left
pmqs Skarsnik, I hear you :-) 13:30
13:34 rindolf joined 13:39 rurban1 joined
gfldex m: sub f(::T) { class :: is T {} }; f(class {}); 13:41
camelia rakudo-moar 3259ba: OUTPUT«Unhandled exception: Method 'item' not found for invocant of class 'T'␤ at <unknown>:1 (/home/camelia/rakudo-m-inst-1/share/perl6/runtime/CORE.setting.moarvm:print_exception:4294967295)␤ from gen/moar/m-CORE.setting:20403 (/home/camelia/rakudo-m-in…»
13:41 bpmedley joined
RabidGravy yeah, I saw that one the other day, can't remember what I was trying to do 13:42
13:42 bpmedley left
gfldex i got a complete (i think) list of things that do work with EXPORT and type captures 13:42
RabidGravy gfldex++ 13:43
13:44 bpmedley joined 13:45 bpmedley left 13:46 molaf joined
gfldex gist.github.com/gfldex/e0c398175941d094958a 13:46
if you happen to another one that works, please let me know
i want to propaganda this
s/to/to know/
jnthn RabidGravy: Certainly a bug; thanks for reporting 13:47
yoleaux 13:12Z <RabidGravy> jnthn: I don't believe you intended for rt.perl.org/Ticket/Display.html?id=127297 to happen :-\
RabidGravy had me tearing my (metaphorical) hair out, I was postulating all sorts of weird interactions with the target supply before I golfed it :) 13:48
13:49 z8 left 13:51 FROGGS_ joined
dalek kudo/nom: 770d109 | jnthn++ | src/core/Supply.pm:
Fix scoping bug in Supply.grep.
13:51
jnthn RabidGravy: ^^
And yes, please add a test to S17-supply/grep.t 13:52
RabidGravy will do, just re-testing 13:53
nine jnthn: so I _was_ on the right track there :) 13:54
13:55 FROGGS left
jnthn :) 13:58
My first Rakudo commit of 2016 \o/
RabidGravy and the first one by anyone since Wednesday apparently 14:00
jnthn++
nine .seen lizmat
yoleaux I saw lizmat 13 Jan 2016 21:26Z in #perl6: <lizmat> mspo: no pb
14:09 xdoctor joined, lokien_ left
pierre-vigier Thank to all the help i had here on Metamodel, Trait and Role, i finally have something "showable" for AttrX::PrivateAccessor 14:10
github.com/pierre-vigier/Perl6-Att...teAccessor
I love Perl6 :)
14:17 bpmedley joined
masak lol, I blogged! strangelyconsistent.org/blog/macros...q-are-they 14:17
14:18 bpmedley left, Actualeyes left 14:21 lucasb joined, bpmedley joined 14:22 bpmedley left
mspo masak: a lot of formatting issues 14:29
14:29 avs_ joined
masak oh :/ 14:30
masak looks
mspo the first few questions, anyway
they go to the next line
masak yes 14:31
will fix immediately
mspo markdown?
ditto Q: Ok, final question: is there something that you've omitted from the 14:32
masak fix'd
should be able to F5 now and see the fix'd version
apologies for the inconvenience
and yes, markdown
I do know that ATX headers can't break lines 14:33
but somehow I forgot and overeagerly formatted them in vim when converting from a gist :)
mspo markdown without live preview is hard :)
14:33 xdoctor left
mspo I haven't found a good drop-in js live-preview widget either 14:34
masak I've seen plenty of libraries for it 14:35
dunno about widgets
but you're right -- I would like something like that for editing my posts
mspo most of the libs I've seen are part of larger systems 14:37
14:37 Actualeyes joined
mspo so if your edit page isn't structured just so.. 14:37
14:39 pierre-vigier left 14:42 average joined
average blog.garage-coding.com/2016/01/17/a...teams.html 14:42
does anyone here understand this blogpost ?
dalek ast: 696d50a | RabidGravy++ | S17-supply/grep.t:
Check subsequent grep only gets the results of the first

Per rt.perl.org/Ticket/Display.html?id=127297
14:43
RabidGravy I'm wondering looking at that whether the Test::Tap merits being given a life in the ecosystem 14:54
14:55 jme_ joined 14:56 orbus joined 14:58 jme` joined
orbus good morning sixers 14:59
got another puzzle to figure out, if anyone's around
15:00 awwaiid joined
orbus so say I want to loop on polling a channel, and stop as soon as no more values are available 15:02
m: my $c=Channel.new; for 1..3 {$c.send($_)}; while $c.poll -> $x { put $x }
camelia rakudo-moar 770d10: OUTPUT«1␤2␤3␤»
orbus but while $c.poll -> $x actually apparently test the value of $x
m: my $c=Channel.new; for 0..3 {$c.send($_)}; while $c.poll -> $x { put $x } 15:03
camelia ( no output )
orbus if there's a 0 on the channel, the loop ends prematurely
poll returns Nil if it fails to get a value, but I can't figure out a good way to test for that
if I assign the result of poll to a variable and then test it, Nil evaporates on assignment 15:04
15:04 bpmedley joined, AlexDaniel joined 15:05 lokien_ joined
RabidGravy m: my $c=Channel.new; for 0..3 {$c.send($_)}; $c.close; for $c.list -> $x { put $x } 15:05
camelia rakudo-moar 770d10: OUTPUT«0␤1␤2␤3␤»
15:05 bpmedley left
orbus no, don't want to do that 15:06
15:06 Zero_Dogg left
orbus that will only work on one thread 15:06
RabidGravy well, you have to signal the end of the channel
orbus I don't think I want to do that either :p
15:07 Zero_Dogg joined, Zero_Dogg left, Zero_Dogg joined
orbus m: my $c=Channel.new; for 0..3 {$c.send($_)}; loop { my $x = $c.poll; if defined $x { put $x } else { last } } 15:07
camelia rakudo-moar 770d10: OUTPUT«0␤1␤2␤3␤»
orbus that seems to work
thought I tried that before
jnthn You generally don't want to loop on .poll
Because it's busy waiting.
orbus well, not really if I stop and go do something else as soon as I don't get a value back 15:08
jnthn Ah, OK. So there's a bit more to it than your example showed :)
orbus yes - it was a naive example
15:08 brrt joined
orbus also I'm trying to figure out how Nil works 15:08
jnthn If you didn't already know, you can use whenever with a Channel also.
orbus hmmm 15:09
haven't looked at whenever yet
jnthn Nil, when assigned to a Scalar, resets it to its default value
Which is Any for an untyped Scalar.
orbus yeah, I was trying to figure out how to reliably test for that
I guess defined 15:10
or ! defined
i.e. first I tried $x === Nil but that was no good
jnthn with $c.poll -> $x { put $x } # maybe neater
Right, after the assignment the Nil is gone.
orbus as I discovered :)
more generally, it seems like it would be nice if there were a "while defined" loop 15:12
that also allowed assignment
m: my $c=Channel.new; for 0..3 {$c.send($_)}; loop { with $c.poll -> $x { say $x } else { last }} 15:15
camelia rakudo-moar 770d10: OUTPUT«0␤1␤2␤3␤»
orbus yeah, that works and is slightly neater - thanks
I've just been messing around with concurrency stuff a lot over the last week or two 15:17
still haven't totally wrapped my head around all the things you can do with Supply
jnthn Me either :D 15:18
orbus haha
actually the other day I was trying to implement atomic compare and swap
didn't go so well
and then I tried to make a bounded channel that would block if you tried to put more than $limit elements into it until slots freed up 15:19
also didn't go so well
apparently I'm worse at concurrency than I believed
15:20 rurban1 left
funrep "my $conn = IO::Socket::INET.new(listen => $server, localport => $port);" this just crashes without any error message or anything, any ideas? 15:21
15:21 kid51 left
RabidGravy "crashes" ? 15:22
orbus $server and $port aren't declared...
try putting my on them
runs fine for me if I do that...
jnthn orbus: Yeah, I'm kinda pondering whether there'd be a market for a Perl 6 concurrency cookbook at some point :)
But want to work lots of polishing up the implementation first :) 15:23
*lots on
orbus definitely
pochi does 'listen' take server?
RabidGravy no it doesn't
orbus jnthn: actually I've been meaning to ask you if you've done a writeup anywhere on exactly what is and is not atomic 15:24
like
scalar assignment seems to be
usually
15:24 azawawi left
orbus unless you're assigning like an object constructor - object construction definitely seems not to be 15:24
jnthn orbus: No, that plus a "memory model" doc is really needed.
RabidGravy funrep, please examine the example in doc.perl6.org/type/IO::Socket::INET
moritz please use https:// URLs to doc.perl6.org :-) 15:25
orbus mostly just trying to figure out where the mines are so I don't step on them
jnthn: okay, that's kind of what I figured
jnthn Hm, looks like I'd better go for my afternoon stroll now if I want it before dark falls. :) 15:26
bbl :)
orbus enjoy
RabidGravy already nearly dark here
orbus it's morning here
time for breakfast actually 15:27
bbl
15:27 skaji joined
jvcakg what does bbl mean? 15:33
nine be back later 15:34
jvcakg ty
psyke =P
15:35 zakharyas joined
RabidGravy Well, it appears that Net::AMQP is nearly working again 15:45
15:52 jordman_ left
tadzik Computer, messages 15:55
yoleaux 11:58Z <azawawi> tadzik: Shell::Command is now failing to install on windows after the which command was added. Please consider using File::Which
tadzik ... There's a which command now?
lucasb
.oO( which command are you talking about? )
nine tadzik: do you know the feeling, when you wake up and don't know your software anymore? ;) 15:56
tadzik Yes! :)
But I wake up and don't know who writes my software :P 15:57
Skarsnik yay the first type I define my own operator in a perl 6 program x)
*time
15:58 khw joined
RabidGravy If anyone's bored you can take a poke at github.com/retupmoca/P6-Net-AMQP one thing left broken now 16:02
funrep RabidGravy: oh i never closed it, may that have to do with it? i forgot to say i have a loop { } after 16:10
lucs Can I make something like this work?: "Foo::Bar".new
That is, instantiate a class given its name in a string.
RabidGravy lucs, :("Foo::Bar").new
er ::() rather 16:11
lucs I wish I knew how to find that stuff in the docs :)
Thanks
RabidGravy funrep, no. listen is a Bool
DrForr The docs are still in flux :) 16:12
lucs That too :)
16:12 aenaxi left
funrep RabidGravy: im writing a client 16:12
RabidGravy right 16:13
funrep oh shit
hah, thanks!
okey, now i get this error "Socket is already bound or connected" 16:14
RabidGravy yeah, you just need to close it 16:15
but see doc.perl6.org/type/IO::Socket::INET
you don't use listen for a client
funrep yes doing that now 16:16
but how can i close a connection from a closed program? xd 16:17
pochi you have to wait till the kernel releases the socket I think 16:18
funrep okey
Skarsnik interesting I managed to have a sigseg on the compile x)
AlexDaniel Skarsnik: out of curiosity, which character did you pick and what is it for?
pochi or maybe you can turn on SO_REUSE or something
RabidGravy It doesn't matter with a client 16:19
Skarsnik I used the string 'type-eq' to compare C Type in gptrixie, to avoid writing stuff like $type ~~ PointerType and $type.ref-type ~~ FundamentalType and $type.ref-type.name eq 'char'; I write $type type-eq <Ptr char>; 16:20
16:20 average left
mspo for NativeCode should I just use int32 for uint32_t ? 16:21
RabidGravy uint32 16:22
mspo not mentioned doc.perl6.org/language/nativecall ? 16:23
Skarsnik uint32_t does not exist x)
mspo oh they have an example with it, but it's missing from the little table 16:24
Skarsnik: ?
Skarsnik nvm I read or instead of for 16:25
damn I get a sigseg that I can't gold 16:26
*golf
unsigned int type should probably be added in this table yes x) 16:32
16:32 sftf joined, brrt left
colomon does Proc.run actually work in current Rakudo? 16:35
my simple experiment hung in OS X and core dumped in Linux 16:36
nine colomon: if it didn't work, loading modules would crash as precompilation is "run" 16:37
autarch colomon: :merge causes a core dump, but it otherwise works, I think
colomon oh, well I used :merge
autarch there's a bug filed for that
colomon indeed, removing :merge fixes everything 16:38
16:40 bpmedley joined
Skarsnik Ok I am confused. I try to run a perl6 script and it sigsev before doing anything (it was not doing that some time ago and even putting a say in a BEGIN block do nothing); I tried a perl6 -e and use the stuff it included that does not sigsev 16:40
colomon autarch++ 16:41
16:41 bpmedley left, domidumont joined
Skarsnik whelp 16:42
root@testperl6:~/piko/gptrixie# perl6 --stagestats -I lib/ bin/gptrixie
Stage start : 0.000
Stage parse : Erreur de segmentation
colomon oooo, this is officially brilliant for my purposes. turns out including :out just makes it silly noisy anyway
16:44 domidumont left, domidumont joined
nine Skarsnik: I guess your installation is somehow screwed up 16:45
16:45 brrt joined
Skarsnik perl6 -e run stuff x) 16:45
nine First step of packing for vacation: my better half - evening dress, me - charging all battery powered devices 16:47
Zero_Dogg Can MAIN be made to handle "--key value" in addition to "--key=value" ? 16:50
16:50 mcmillhj joined
nine Zero_Dogg: it does already 16:50
Zero_Dogg nine: it does? How did I miss that
nine Zero_Dogg: you just have to give the parameter a non-Bool data type
sub MAIN(Str :$key) 16:51
Zero_Dogg nine: it doesn't here, it outputs the help message 16:52
perl6 -e 'sub MAIN(:$key!) { say "key=$key" }' --key test # doesn't work, --key=test works 16:53
RabidGravy nine. absolutely, I'm always left in charge of making sure we have all the chargers and adaptors and Mrs Gravy packs the clothes ;-) 16:54
Skarsnik x) 17:00
nine Zero_Dogg: indeed...it's missing from src/core/Main sub process-cmd-args 17:01
Skarsnik not in spec test? x) 17:02
17:03 BenGoldberg joined 17:04 rurban joined
Zero_Dogg nine: need me to file a bug? 17:04
17:07 jme_ left 17:09 lokien_ left 17:17 brrt left 17:19 erdic joined, zakharyas left
ugexe Zero_Dogg: rt.perl.org/Public/Bug/Display.html?id=124664 17:21
17:22 drrho left 17:23 drrho joined
MadcapJake Would you ever have a :: in a sub or method declaration? 17:25
Skarsnik ::? 17:27
17:28 espadrine joined
Zero_Dogg ugexe: thanks 17:29
17:30 ely-se joined
MadcapJake Skarsnik: like would you ever have «sub Foo::Bar($baz) { ... }» 17:31
mst MadcapJake: subs are basically lexical so that doesn't make a lot of sense to me 17:32
Skarsnik m: sub Foo::bar() {say "heelo"}; Foo::bar();
camelia rakudo-moar 770d10: OUTPUT«Could not find symbol '&bar'␤ in block <unit> at /tmp/Q4jcoRCVFS line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/Q4jcoRCVFS line 1␤␤»
MadcapJake ok I just needed to make sure that it could never be the case that a `::` would appear in a sub/method declaration 17:33
Skarsnik m: module Foo {sub Foo::bar() {say "heelo"} }; Foo::bar();
camelia rakudo-moar 770d10: OUTPUT«Could not find symbol '&bar'␤ in block <unit> at /tmp/N9LRJ_CD9D line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/N9LRJ_CD9D line 1␤␤»
MadcapJake m: module Foo {sub Foo::bar() {say "heelo"} }; Foo::Foo::bar();
camelia rakudo-moar 770d10: OUTPUT«Could not find symbol '&bar'␤ in block <unit> at /tmp/gy54DuwdcJ line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/gy54DuwdcJ line 1␤␤»
Skarsnik m: module Foo {our sub Foo::bar() {say "heelo"} }; Foo::bar(); 17:34
camelia rakudo-moar 770d10: OUTPUT«Could not find symbol '&bar'␤ in block <unit> at /tmp/F2clBsui0m line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/F2clBsui0m line 1␤␤»
17:34 rodi joined 17:35 rodi left
ugexe m: class Foo { method foo::bar () { say 665; }; }; Foo.new."foo::bar"(); 17:36
camelia rakudo-moar 770d10: OUTPUT«665␤»
MadcapJake ugexe: lol alrighty then! 17:37
ugexe: so is that because any character is acceptable for a name though you'll have to use quotes to access it? 17:38
RabidGravy okay if I have a slurpy positional how do I pass an empty hash as one positional?
m: sub foo(*@foo) { say @foo }; foo("a","b",{}); # doesn't 17:39
camelia rakudo-moar 770d10: OUTPUT«[a b]␤»
MadcapJake m: class Foo { method foo«bar () { say 665; }; }; Foo.new."foo«bar"();
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Dbfup3bjnG␤Missing block␤at /tmp/Dbfup3bjnG:1␤------> 3class Foo { method foo7⏏5«bar () { say 665; }; }; Foo.new."foo«ba␤»
MadcapJake m: class Foo { method foo*bar () { say 665; }; }; Foo.new."foo*bar"(); 17:40
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/hmRE4RBMsm␤Missing block␤at /tmp/hmRE4RBMsm:1␤------> 3class Foo { method foo7⏏5*bar () { say 665; }; }; Foo.new."foo*ba␤»
17:40 psy_ left
MadcapJake ok i guess just the `::` get special priviledges :P 17:40
funrep are there tuples in perl6? 17:41
MadcapJake is there even a good reason to use a `::` in a method/sub decl? I don't see how that would be anything other than confusing :P 17:42
funrep: do you mean like an immutable list? 17:43
funrep yeah kinda, maybe tuples are reduntant immutable lists :) 17:44
ugexe not ::, :. so foo:bar and foo:::bar also work 17:45
MadcapJake well containers are mutable, so `my @tuple = 1, 2, 3;` will allow you to mutate. But `my \tuple = (1, 2, 3) gives you an immutable list 17:46
ugexe: what's the point of being able to do that?
funrep: doc.perl6.org/language/list#Immutability 17:47
ugexe well, whats the point of not? 17:49
MadcapJake because it's confusing, it looks like package syntax but it isn't and you have to use quotes to access it.
17:51 rurban left, rurban joined
MadcapJake you can't even use it on bare names, it has to be nested in a module/class 17:51
ugexe should it not be allowed to be done at all because its confusing for normal use then? 17:54
lucasb IMO, method foo::bar should be a syntax error 17:56
MadcapJake I'm just reading S02 names, and the `::` is a package sigil. If it's used just as a regular character in a sub/method declaration, that is terribly confusing 17:57
not only would you instantly think, "oh that preceding bit is a package" (which it's not) but you'd then try to access it as such and find a strange error that *doesn't* say "to use this method you need to enclose it in quotes" 17:58
17:59 lokien_ joined
MadcapJake what actual purpose does it serve? No where in S02 names does it say "in method names you can use `::` and it doesn't have any syntactic meaning" 18:00
mspo sub mysql_affectied_rows( .. ) returns int32 is native(LIB) 18:02
sub mysql_affectied_rows( .. ) returns int32 is native(LIB) 18:03
does LIB mean something?
18:03 sftf left
Skarsnik Not reall, are you playing with gptrixie? x) 18:03
It's just 'common' to have a constant LIB = ('foo', v1) or other stuff; 18:07
RabidGravy KISS MY HAIRY GIBBON AMQP!
Skarsnik I don't even know what amqp is, but have fun x) 18:09
18:09 Actualeyes left
MadcapJake I've created an issue for colons in method names: github.com/perl6/specs/issues/106 18:10
mspo MadcapJake: there's the Foo::Bar.method() call? 18:12
Skarsnik There is some Core::.keys and weird stuff like that with :: 18:15
MadcapJake mspo: how does that work? 18:17
Skarsnik: ahh ok 18:18
funrep does perl6 have enum? cant find any in perl6intro or docs 18:19
mst Skarsnik: it's the protocol via which one hates things like RabbitMQ
lucasb funrep: the syntax is 'enum Foo <A B C>' 18:20
funrep awesome, thanks!
MadcapJake funrep: design.perl6.org/S12.html#Enumerations
funrep oh nice (y)
18:22 dwarring joined, lucasb left
RabidGravy right that's Net::AMQP working properly for the first time since September :) 18:27
18:32 orbus left 18:33 skids joined 18:34 leont joined
dalek ast: 4b689b3 | RabidGravy++ | S17-supply/grep.t:
Make the test more explicit

Slight modification to 696d50a932328d9e0e69185c0f900a0b2588f86b
18:36
18:38 Kristien joined 18:39 ely-se left 18:41 orbus joined
ugexe m: package foo { our sub bar is export { 1; }; }; sub foo::bar () { 2 }; say &foo::bar(); say ::<&foo::bar>() 18:41
camelia rakudo-moar 770d10: OUTPUT«1␤2␤»
ugexe i wont claim to know if thats good or bad 18:43
nine it's good 18:46
AlexDaniel m: sub foo::bar() { say ‘hello’ } # how can I call this?
camelia ( no output )
[Tux] is there a timeframe for utf8-c8 fixes? (just curious) 18:47
18:51 Kristien is now known as ely-se
AlexDaniel [Tux]: Hmm… somehow it feels like it depends on how soon you'll do it :) 18:51
[Tux] AlexDaniel, if that was within my reach I might have taken a stab, but I know it is waaaaaaaay beyond what I am capable of 18:52
AlexDaniel [Tux]: common misconception :)
[Tux]: I believe in you
[Tux] even if lizmat says it is beyong her knowledge? 18:53
beyond
nine [Tux]: seems like you could use a little more hubris :) 18:55
[Tux] <gulp /> 18:56
AlexDaniel [Tux]: well, the thing about contributing to free software projects is that it's not about being geniuses in all questions but about contributing your time and focus into some small specific issue that you care about. With enough effort anyone could do it
[Tux] :) I think I score rather well in that area 18:57
[Tux] goes watch the news
AlexDaniel :D 18:58
abaugher [Tux], thanks for making that META.info change for Text::CSV. panda still complains, so I think it must have it cached already or something, because I can see you changed it. But I commented out that line in panda, so the install proceeds successfully. 18:59
nine abaugher: takes a while for the ecosystem to pick up changes to META files. Then you still need to do panda update to get the changes from the ecosystem 19:00
abaugher nine, yeah, I figured it was something like that. It says "fetching Text::CSV", but clearly it's not fetching a fresh copy of everything from github. No big deal. 19:01
19:02 jvcakg left
abaugher 'panda update' does eliminate it, so I'll have to keep that in mind, that that updates META.info files. Makes sense, now that I think about it, since those contain info about sources. 19:04
19:04 _nadim left
DrForr Wow. Don't invoke Perl6 core rules from inside your role. 19:08
19:08 _nadim joined
masak no? 19:09
DrForr Practically locks up my VM.
ugexe m: sub foo::bar () { 2 }; say ::<&foo::bar>() # AlexDaniel 19:12
camelia rakudo-moar 770d10: OUTPUT«2␤»
AlexDaniel ugexe: in other words colons are also allowed in sub names? 19:15
geekosaur aren't they somewhat special, though? infix:, trait_mod:, etc.
19:15 Zero_Dogg left 19:16 Zero_Dogg joined, Zero_Dogg left, Zero_Dogg joined
AlexDaniel m: sub foo::bar { 2 }; say ::<&foo::bar>.name 19:16
camelia rakudo-moar 770d10: OUTPUT«foo::bar␤»
ely-se why is Promise.then not called map? 19:29
like Supply.map
moritz because it is only ever executed once
it's more like if/then or given/when than for/map 19:30
mst ely-se: because that would be a completely inaccurate name?
ely-se mst: no, it wouldn't 19:31
mst ely-se: map maps a list. a Promise is equivalent to a scalar.
19:32 perl6newbee left
mst it would be sensible to call .map(then => ...) on a stream of promises, or whatever 19:32
mst does that quite a lot in perl5, although Future is what ours are called
19:33 hankache joined
ely-se I don't see why the name map is only suitable for list-like structures 19:34
19:34 _nadim left
ely-se and not any structure-preserving operation (which includes Promise.then), like in Haskell 19:35
moritz ely-se: in Perl, we care about singular vs. plural
as we do in many human languages, English among them
also, Perl has the philosophy of using a name only for one operation 19:36
and .map is a synchronous operation
MadcapJake moritz: that explains why `.chars` and `.elems` aren't just called `.length`. I've been wondering that!
ely-se "length" on strings is too ambiguous 19:37
mst MadcapJake: after the number of times I've seen people call .length on the wrong sort of object in other languages and get really confused, I -so- like that decision
MadcapJake I definitely like that they are different, but it's one of those go-to methods in JS that you get really used to using 19:38
mst not being able to immediately tell whether you're getting number-of-chars-in-string or number-of-elements-in-array is just sadface making
MadcapJake for sure, but it definitely is a strong JS idiom nonetheless X) 19:41
19:42 marmay_ joined
MadcapJake Definitely something to add to the JS-to-P6 pod when that exists. 19:48
mst oh, I'm aware. also a strong python idiom. but we're still allowed to do better than them :)
masak I guess that decision in JS comes from Java originally
though in Java it's .length() for String and .length for Array 19:49
mst also java wasn't an influence on the JS design process really
MadcapJake masak: lovely xP
masak because brain damage, apparently
mst: oh, I think it was
mst: all the wrapper types were basically lifted directly from Java
mst wrapper types?
masak object types holding methods for native types 19:50
Java has int and Integer
JavaScript has native numbers and Number
MadcapJake JavaScript Origin Story: www.computer.org/csdl/mags/co/2012/...20007.html 19:52
mst ISTR it was primarily based on scheme and self
except m-expressions
MadcapJake Smalltalk, C[++], and LISP apparently 19:53
masak Scheme and Self were the "hidden" influences
Java was the explicit influence, syntax-wise and with some of the semantics
MadcapJake But he was under marketing orders to make it look like Java also 19:54
masak the infix:<+> operator doing both string concat and math -- that decision is from Java. doesn't make as much sense in a loosely typed language, though. :/
mst aha
mst stands corrected
masak Perl was an influence, too. regular expressions.
Modula/Python was another influence, but I forget what for. 19:55
er, Modula/Pascal...
leont regular expressions weren't in Javascript 1.0
masak that rings a bell, yes 19:56
MadcapJake «Eich built a simplified object model that combined structs from the C language, patterns from SmallTalk, and the symmetry between data and code offered by LISP. The Hypercard event model inspired the pattern for adding events to the HTML document. Object-oriented patterns were possible but via runtime semantics with prototypes (as in Self) instead of compiler-supported class syntax (as in Java and C++).» 19:57
19:57 _nadim joined
ugexe my $chain = @promises.reduce: {$^a.then($^b)} 20:03
20:07 hankache left 20:10 darutoko left 20:12 domidumont left 20:14 FROGGS_ left 20:17 ely-se left 20:18 espadrine left 20:19 ely-se joined
mspo okay mdb is a little too advanced for a fist try at nativecall ;) 20:25
RabidGravy mdb?
mspo MDB_env is a struct with like 50 members, most of which are other structs/unions
sorry- lmdb
symas.com/mdb/ 20:26
RabidGravy where's your spirit of adventure ;-)
mspo RabidGravy: indeed 20:27
bartolin .tell [Coke] looks like you have about 100 processes (some of them a few days old) running on hack. no real problem so far, just got some notifications (we're monitoring the number of procs on hack)
yoleaux bartolin: I'll pass your message to [Coke].
20:33 cognominal left 20:34 musiKk joined, avs__ joined, kid51 joined
Skarsnik mspo, gptrixie does not manage to get them? 20:35
mspo Skarsnik: didn't try it 20:36
dalek ecs/meta-v1: 73ff494 | (Anthony Parsons)++ | S22-package-format.pod:
META doesn't need an entire glossary to itself

There's a document-level one right above it. Merged the two.
mspo Skarsnik: let's try 20:37
Skarsnik: I saw you talking about it yesterday but thought you were talking to someone else :) 20:38
20:38 avs_ left
mspo wow panda actually installed something 20:44
musiKk hello! i have a small question: what does "Int(Cool)" mean in a signature? why would the extra "(Cool)" be necessary?
RabidGravy it constrains the coercion to those types that inherit from Cool 20:46
20:46 leat left, CIAvash left
RabidGravy so: 20:46
m: class F { method Int() { 1; }}; sub foo(Int(Cool) $a) { say $a }; foo(F.new); 20:47
camelia rakudo-moar 770d10: OUTPUT«Type check failed in binding $a; expected Cool but got F␤ in sub foo at /tmp/Ebn4d1XhUu line 1␤ in block <unit> at /tmp/Ebn4d1XhUu line 1␤␤»
RabidGravy m: class F { method Int() { 1; }}; sub foo(Int() $a) { say $a }; foo(F.new); #without the cool 20:48
camelia rakudo-moar 770d10: OUTPUT«1␤»
20:48 mohae left
RabidGravy or alternatively 20:49
b2gills 「sub example ( Int(Cool) $a ) {...}」 can be thought of as being short for two subs 「multi example ( Int $a ) {...}; multi example ( Cool $a ) { samewith $a.Int }」
RabidGravy m: class F is Cool { method Int() { 1; }}; sub foo(Int(Cool) $a) { say $a }; foo(F.new);
camelia rakudo-moar 770d10: OUTPUT«1␤»
RabidGravy b2gills++ nice explaining ;-) 20:50
20:50 mohae joined
musiKk very helpful, thanks. now i try to under stand why. 20:50
20:51 cpage_ left
musiKk for example IO::Socket's read() method does this. why would it care that the number of bytes given is Cool? isn't Int enough? 20:51
ugexe can Int contain Inf?
RabidGravy well it could be a string
20:51 leat joined
RabidGravy m: say "10".Int 20:51
camelia rakudo-moar 770d10: OUTPUT«10␤»
RabidGravy Cool guarantees an Int method that can be called for the coercion, it may blow up if the conversion isn't possible but it will always be there 20:52
AlexDaniel ugexe: not yet 20:53
ugexe: and possibly it will never be so
RabidGravy Cool basically defines an interface that all the builtin simple types share
ugexe yes, it was rhetorical
musiKk RabidGravy: so i only need to require it in a signature if i intend to call one of the many methods or subs defined by Cool? 20:56
don't know if that questions makes sense. i'm well versed in perl5 but super new to perl6. :) 20:58
RabidGravy yeah basically, a (Foo() $a) in a signature is a coercion, if the argument isn't already a Foo then it will try to call the Foo method on it, so specifying Int(Cool) there guaranteed there will be a an Int method on an object that inherits from Cool
so e.g
20:58 revhippie joined
RabidGravy m: class Foo {}; sub bar(Foo() $a) { say "foo" }; foo("bar"); 20:59
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/qHkGOa6LSr␤Undeclared routine:␤ foo used at line 1␤␤»
RabidGravy m: class Foo {}; sub bar(Foo() $a) { say "foo" }; bar("bar");
camelia rakudo-moar 770d10: OUTPUT«Method 'Foo' not found for invocant of class 'Str'␤ in sub bar at /tmp/3uWF3C9a0R line 1␤ in block <unit> at /tmp/3uWF3C9a0R line 1␤␤»
20:59 kaare_ left
RabidGravy specifying a constraint for the coercion prevents that sort of thing happening (though it may die for other reasons) 21:01
21:01 bpmedley joined
musiKk oh, i just noticed i did not know that "Foo()" is a coercion in the first place. i always thought it has something to do with lists. 21:01
RabidGravy ah
flussence signatures are a weird sub-language
21:02 raiph joined
musiKk i still don't get it completely but you sure helped a lot. 21:04
unfortunately i can't try stuff out right now b/c i did something and now rakudo does nothing but core dump due to "illegal instruction". lol
RabidGravy oops 21:05
masak oh, right. forgot about the Hypercard influence for the event model. MadcapJake++
musiKk psa: don't do "sub rec() { rec() } rec()" :(
lucs Else you will curse! And recurse! 21:06
musiKk it's super cool that rakudo has tail recursion but somehow this filled all my swap in two seconds and now the core dump thing does not go away.
masak musiKk: did you meant tail recursion *optimization*? and are you sure Rakudo has it? 21:07
marmay_ Is there a way to provide a named parameter to a sub just in case it accepts it? I try to pass a parameter $request to a sub that does not take any parameters and I get an error: "Unexpected named parameter 'request' passed in sub"
RabidGravy yes 21:08
21:08 avs_ joined
RabidGravy or for methods that just works 21:08
sjn \o
sjn wonders if there's a JSON formatted list of a the modules at modules.perl6.org somewhere 21:09
RabidGravy m: class F { method bar() { say %_ } }; Foo.new.bar(bumble => "goat");
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/iQSY6oyf5a␤Undeclared name:␤ Foo used at line 1␤␤»
RabidGravy m: class F { method bar() { say %_ } }; F.new.bar(bumble => "goat");
camelia rakudo-moar 770d10: OUTPUT«bumble => goat␤»
musiKk masak: now that you ask, i'm not positive anymore due to the problems i mentioned. i'll reboot and see if that fixes something. otherwise it's back to compiling rakudo. 21:10
RabidGravy sjn, yes, the project.json is at ecosystem-api.p6c.org/projects.json
21:10 jcallen left 21:11 jcallen joined, avs__ left 21:12 musiKk left
nine Rakudo doesn't have tail recursion optimization. 21:12
21:14 kid51 left
marmay_ RabidGravy: Ah, that's interesting. But is there a way to make subs behave more like methods in this case? 21:15
21:16 jcallen left
flussence m: sub foo(*%) { 'bar' }; say foo(:whatever(999)) 21:16
camelia rakudo-moar 770d10: OUTPUT«bar␤»
21:16 sortiz joined 21:17 bjz left
ely-se can I do exec without fork? 21:17
RabidGravy marmay_, but for subroutines it doesn't have a defaiult '*%_' in the signature so you would have to specify it explicitly 21:18
where '*%_' means any other named parameters that haven't been specified
21:18 [dpk] joined 21:19 dpk left
RabidGravy you can't make someone else's sub behave like it though 21:19
21:19 [dpk] is now known as dpk, jcallen joined, musiKk joined
flussence ely-se: that's called &runinstead in perl 6 21:19
marmay_ Ok, thank you.
21:19 lokien_ left
flussence (or at least, it was in the specs. doesn't look implemented) 21:20
ely-se flussence: aha! obscure :)
musiKk masak: it seems rakudo does not limit the stack or something. i cannot provoke a stack overflow. 21:21
ely-se runinstead is not implemented in rakudo though
21:22 lsm left 21:24 geraud joined 21:25 lsm-desktop joined, linuxuser9000 joined 21:26 rurban left, bowtie left
masak 'night, #perl6 21:26
21:28 sjohnson` joined, bowtie joined 21:29 bpmedley left, RabidGravy left, noganex left, uruwi left, balazs left, gfldex left, jevin left, sm0x left, sjohnson left, wtw left, avar left, literal left, jast left, raydiak left, jervo left, crux left, cbk__ left, musca left, jantore_ left, ranguard left, apejens left
ely-se goodbye masak 21:30
21:33 rurban joined 21:44 rindolf left 21:47 btyler left, Sgeo_ left 21:48 Sgeo joined
ely-se m: for (1, 2) Z ('a', 'b') -> $n, $a { } 21:48
camelia ( no output )
ely-se hmm
21:48 Sgeo left
ely-se m: for (1, 2) Z ('a', 'b') -> $n, $a { say "$n $a" } 21:48
camelia rakudo-moar 770d10: OUTPUT«1 a 2 b␤»
21:49 RabidGravy joined
RabidGravy ah there you all are 21:50
ely-se on my machine it says too few positionals are passed
geekosaur [17 21:29] * RabidGravy has quit (*.net *.split)
fwiw 21:51
moritz ely-se: -> ($n, $a) fixes it
RabidGravy yeah I saw but I was left with a version of the channel with 14 people
moritz m: for (1, 2) Z ('a', 'b') -> ($n, $a) { say "$n $a" }
camelia rakudo-moar 770d10: OUTPUT«1 a␤2 b␤»
ely-se moritz: why does it work for this example though?
moritz ely-se: which one?
21:51 marmay_ left
ely-se m: for (1, 2) Z ('a', 'b') -> $n, $a { say "$n $a" } 21:51
camelia rakudo-moar 770d10: OUTPUT«1 a 2 b␤»
ely-se hey there is only one newline 21:52
geekosaur yeh, that happens when the server is still up but its connection with the collective is lost. sometimes called "split brain" 21:53
RabidGravy yeah if you change it you'll see what is happening
m: for (1, 2) Z ("a", "b") -> $n, $a { say "$n -> $a" }'
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/1jwlCUoIDn␤Strange text after block (missing semicolon or comma?)␤at /tmp/1jwlCUoIDn:1␤------> 3 ("a", "b") -> $n, $a { say "$n -> $a" }7⏏5'␤»
RabidGravy m: for (1, 2) Z ("a", "b") -> $n, $a { say "$n -> $a" }
camelia rakudo-moar 770d10: OUTPUT«1 a -> 2 b␤»
moritz ely-se: it produces two elements which are sublists 21:54
ely-se: so it only "works"
ely-se ooh
I see
RabidGravy or you can do it one the other side with:
m: for ((1, 2) Z ("a", "b")).flat -> $n, $a { say "$n -> $a" }
camelia rakudo-moar 770d10: OUTPUT«1 -> a␤2 -> b␤»
21:55 TEttinger joined, lokien_ joined 22:05 apejens joined, ranguard joined, jast joined, jantore joined, gfldex joined 22:06 raydiak joined, sm0x joined, uruwi joined, cbk__ joined, balazs joined, jervo joined, musca joined 22:08 sjohnson` is now known as sjohnson, llfourn_ joined 22:10 avar joined, literal joined, avar left, avar joined, wtw joined, crux joined 22:11 llfourn left 22:13 ely-se left 22:15 mephinet- left 22:17 AndyDee joined 22:20 mephinet joined 22:27 yurivish_ joined, dpk left, nebuchadnezzar left 22:28 dpk joined, nebuchadnezzar joined, matt_ joined, eiro joined
yurivish_ hi everyone! quick question – is docs.parrot.org/parrot/latest/html/...s.pod.html an accurate description of how rakudo's current string implementation works, or is Parrot's approach different? 22:28
I'm interested specifically in the way unicode is handled. The Julia programming language is currently working out an improved approach towards string and character handling, and I pointed them towards Perl 6's approach to use as possible inspiration: github.com/JuliaLang/julia/pull/14383 22:29
22:30 yurivish_ left
flussence that sounds vaguely like how MoarVM implements it, yes 22:31
geekosaur I think that support was contributed to them back when rakudo-parrot development was active? 22:33
22:33 yurivish_ joined
geekosaur I vaguely recall some of it got rethought afterward though 22:33
whoops
helps to reply when they're in the channel >.>
yurivish_ (sorry, disconnected. caught up on the irc logs :)
diakopter pdd28 was always aspirational 22:34
yurivish_: your link to jnthn's talk is much more appropriate; good job 22:35
yurivish_ :)
diakopter simonbyrne's link should be removed
the one to the parrot doc 22:36
AlexDaniel m: sub infix:<\> { $^b / $^a }; say 5 \ 35
camelia rakudo-moar 770d10: OUTPUT«5===SORRY!5=== Error while compiling /tmp/jDjUMJEep5␤Unable to parse expression in quote words; couldn't find final '>'␤ ␤at /tmp/jDjUMJEep5:1␤------> 3sub infix:<\> { $^b / $^a }; say 5 \ 357⏏5<EOL>␤ expecting any of:␤ …»
22:36 rurban left
AlexDaniel m: sub infix:<\\> { $^b / $^a }; say 5 \\ 35 22:36
camelia rakudo-moar 770d10: OUTPUT«7␤»
yurivish_ diakopter: I can leave a comment to that effect, or you might be able to provide a bit more clarity than I can on the current situation
diakopter I commented 22:37
22:38 vendethiel left 22:41 linuxuser9000 left 22:47 bakedb_ left 22:48 llfourn joined, Cabanossi left, llfourn_ left 22:49 stux|RC left, nowan_ joined 22:50 nowan left, felher left, leont left 22:51 RabidGravy left 22:52 cognominal joined, Cabanossi joined, grassass left, tadzik left 22:53 balazs left, Praise left, mspo left, PotatoGim left, pnu left, Spot__ left, funrep left, Humbedooh left, krunen left, flussence left, AW3i left, avenj left, brabo left, solarbunny left, FatalNIX left, leont joined, tadzik joined, RabidGravy joined, grassass joined 22:54 PotatoGim joined 22:57 brabo joined, balazs joined, Praise joined, mspo joined, pnu joined, Spot__ joined, FatalNIX joined, funrep joined, Humbedooh joined, krunen joined, flussence joined, AW3i joined, avenj joined, solarbunny joined, FatalNIX left 22:58 pRiVi_ left 22:59 felher joined 23:00 FatalNIX joined, pRiVi joined, stux|RC-only joined 23:02 bakedb joined 23:12 TEttinger left 23:13 _nadim left 23:21 SCHAAP137 left 23:23 yurivish_ left, yurivish_ joined 23:29 RabidGravy left 23:30 musiKk left 23:32 vendethiel joined 23:33 azawawi joined
azawawi hi 23:33
Skarsnik Hello 23:34
azawawi just woke up :) 23:35
Skarsnik work on my pg array! 23:36
23:37 telex left 23:38 telex joined
azawawi :) 23:38
azawawi is reading doc.perl6.org/language/modules#EXPORT
23:40 Sgeo joined 23:44 bowtie left 23:48 bowtie joined, kid51 joined
azawawi so what's the advantage of versioning a module if panda/zef is not going to install the newer version? 23:49
Skarsnik it's look corporate? 23:50
ni idea
azawawi :) 23:51
orbus maybe it eventually will 23:52
or panda will be replaced with something that does handle versions - cpan6 or whatever 23:53
not sure what the plan is, but I assume versioning will be useful at some point 23:54
azawawi oh well, time will only tell :)
orbus is working on a module right now 23:55
suppose I'd better version it
actually 23:57
here's a question
Skarsnik I think the plan is to wait for a tool that handle version for you, aka fix a github release and upload on cpan x)
orbus yeah, I'm assuming there will be either cpan integration or cpan6 at some point
23:57 firstdayonthejob left
orbus so here's a question 23:58
I'm writing a class
that inherits from another class
the parent class has a method foo
and I'm adding a method in my class called bar
which I want to do some stuff and then call back to foo in the parent class 23:59
in java I guess that would just be like super.foo
so far the only way I see to do it in perl6 is with WALK
which works but is a bit cumbersome
wondering if there's any easier way