Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2015-04-16

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:12 eternaleye joined #perl6
00:24 japhb Yeah, faster JSON parsing would be a huge win for me as well.
00:25 japhb There are places I'd love to use it as a least common denominator interchange format, but the current parsing is just too slow for any reasonable amount of data.
00:34 baest joined #perl6
00:34 kst` joined #perl6
00:35 davido_ joined #perl6
00:37 sftp joined #perl6
00:46 alini joined #perl6
00:46 laouji joined #perl6
00:54 adu joined #perl6
00:55 vendethiel joined #perl6
00:58 nbdsp Greetings! I read the section "fancy method calls" in docs, but can't figure out how to access a private variable with its text name. E.g.
00:58 nbdsp class C { has $!field = "10"; method meth( $var ) { say self!<$var>; } }; my $c = C.new; $c.meth( "field" );
00:59 nbdsp m: class C { has $!field = "10"; method meth( $var ) { say self!<$var>; } }; my $c = C.new; $c.meth( "field" );
00:59 camelia rakudo-moar 239d74: OUTPUT«5===SORRY!5=== Error while compiling /tmp/oC6VvYJTyB␤Missing required term after infix␤at /tmp/oC6VvYJTyB:1␤------> 3"; method meth( $var ) { say self!<$var>7⏏5; } }; my $c = C.new; $c.meth( "field" )␤    expecting any of:␤        prefi…»
01:00 aborazmeh joined #perl6
01:00 aborazmeh joined #perl6
01:14 japhb nbdsp: Private attributes and private methods are separate (unlike the unification of public attributes and public methods), but both can be reached using the MOP.
01:14 japhb (Essentially you're digging into things the object doesn't *want* you to reach easily, so you have to go through the class's meta-object to pull it out.
01:14 japhb )
01:15 Akagi201 joined #perl6
01:16 japhb If you want to see the deepest, ugliest guts, you can look at the code that makes DUMP work in Rakudo -- but note that it's got a lot of extra logic to handle the case that a VM-level object has escaped into Perl 6 space, but we still want to display it sanely.  (DUMP is a low-level debugging tool, after all, designed for figuring such things out.)
01:17 nbdsp Oh. Though it's not quite clear why private methods are easier to access than private fields. But thanks for pointing to MOP!
01:20 japhb nbdsp: Private methods and private attributes are visible within the class, certainly.  Outside the class, what is the easier access that you are thinking of that favors one over the other?
01:30 nbdsp japhb: In the docs http://design.perl6.org/S12.html#Fancy_method_calls there are plenty of ways to access private methods through string variables. But not private fields.
01:35 DarthGandalf joined #perl6
01:36 nbdsp m: class C { has $!field = "10"; method meth( $var ) { say $!<$var>; } }; my $c = C.new; $c.meth( "field" );
01:36 camelia rakudo-moar 239d74: OUTPUT«Nil␤»
01:45 raydiak I suppose because, if I understand correctly, private attributes have no accessor at all, not even a private one; just a lexical alias to the attribute, more like a my var than an accessor method
01:47 ilbot3 joined #perl6
01:47 Topic for #perl6 is now »ö« Welcome to Perl 6! | http://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: http://irc.perl6.org | UTF-8 is our friend! | feather will shut down permanently on 2015-03-31
01:53 aborazmeh joined #perl6
01:53 aborazmeh joined #perl6
02:04 japhb nodnod
02:05 japhb m: class C { method !priv() { say "Hi!" } }; C.new!priv();
02:05 camelia rakudo-moar 239d74: OUTPUT«5===SORRY!5=== Error while compiling /tmp/rflpvixbu7␤Private method call to priv must be fully qualified with the package containing the method␤at /tmp/rflpvixbu7:1␤------> 3od !priv() { say "Hi!" } }; C.new!priv()7⏏5;␤»
02:05 nbdsp But how to access attributes via metaobject? When I try self.^attributes[0] = "1"; there is an error "Cannot modify immutable attribute"
02:05 japhb nbdsp: See the above as well, access to private methods isn't as simple as it appears in that section of S12
02:06 japhb nbdsp: You need to make it 'is rw' in order to have a container for it.
02:06 japhb (or have it be a native attribute)
02:06 KCL_ joined #perl6
02:07 nbdsp Will the private attribute remain private if it is set as 'rw'?
02:07 japhb I have to ask though, what is your actual use case?  Why are you trying so hard to work around privacy, rather than just make the relevant attributes/methods public?
02:09 nbdsp Is accessing an attribute via string variable instead of string literal has something in relation to privacy?
02:09 japhb m: class C { has $!foo is rw = 12; method !priv() { say $!foo } }; my $c = C.new; $c!priv(); $c.^attributes[0] = 5; $c!priv();
02:09 camelia rakudo-moar 239d74: OUTPUT«useless use of 'is rw' on $!foo  in any  at src/Perl6/World.nqp:2052␤␤5===SORRY!5=== Error while compiling /tmp/eKoLxB7rbM␤Private method call to priv must be fully qualified with the package containing the method␤at /tmp/eKoLxB7rbM:1␤------>…»
02:10 japhb Hmmm, won't let you make a container without making it public, it seems.  Interesting
02:10 japhb m: class C { has $!foo is rw = 12; method !priv() { say $!foo } }; my $c = C.new; $c!C::priv(); $c.^attributes[0] = 5; $c!C::priv();
02:10 camelia rakudo-moar 239d74: OUTPUT«useless use of 'is rw' on $!foo  in any  at src/Perl6/World.nqp:2052␤␤5===SORRY!5=== Error while compiling /tmp/CYheS5Osob␤Cannot call private method 'priv' on package C because it does not trust GLOBAL␤at /tmp/CYheS5Osob:1␤------> 3y $!foo …»
02:10 noganex_ joined #perl6
02:10 japhb Yeah, that's the next problem. ^^  You have to be trusted to use that syntax.  Only the MOP gets around that.
02:11 japhb nbdsp: No, I'm asking why you're trying to look at a private attribute from outside the class.  It's private, after all -- an implementation detail that outside code should never care about.
02:12 japhb (The MOP gets a pass here because if you're doing meta-programming it's assumed you know what you're doing and accept the risks in order to create magic.)
02:12 colomon joined #perl6
02:15 nbdsp I don't try to look at private attribute outside the class. I'd like to access the provate attribute from within the class but with name contained in a string.
02:25 Akagi201 joined #perl6
02:27 nbdsp m: class C { has $!field = "10"; method meth( ) { self.^attributes[0] = 1; } }; my $c = C.new; $c.meth( );
02:27 camelia rakudo-moar 239d74: OUTPUT«Cannot modify an immutable Attribute␤  in method ASSIGN-POS at src/gen/m-CORE.setting:9266␤  in sub postcircumfix:<[ ]> at src/gen/m-CORE.setting:3428␤  in method meth at /tmp/zGyA_rFCE1:1␤  in block <unit> at /tmp/zGyA_rFCE1:1␤␤»
02:28 nbdsp m: class C { has $!field = "10"; method meth( ) { say self.^attributes; } }; my $c = C.new; $c.meth( );
02:28 camelia rakudo-moar 239d74: OUTPUT«Mu $!field␤»
02:28 Akagi201 joined #perl6
02:31 vendethiel joined #perl6
02:43 Akagi201 joined #perl6
02:44 btyler joined #perl6
02:48 anocelot joined #perl6
02:55 Akagi201 joined #perl6
02:57 nbdsp m: class C { has $!field = "10"; method meth( ) { self.^attributes[0].set_value(1); } }; my $c = C.new; $c.meth( );
02:57 camelia rakudo-moar 239d74: OUTPUT«Too few positionals passed; expected 3 arguments but got 2␤  in method set_value at src/gen/m-CORE.setting:4058␤  in method meth at /tmp/UeY3ckQ7dH:1␤  in block <unit> at /tmp/UeY3ckQ7dH:1␤␤»
03:00 nbdsp m: class C { has $!field = "10"; method meth( ) { self.^attributes[0].set_value(self, 1); } }; my $c = C.new; $c.meth( );
03:00 camelia rakudo-moar 239d74: ( no output )
03:06 btyler joined #perl6
03:11 uvb joined #perl6
03:14 Akagi201 joined #perl6
03:17 dalek doc: d37c260 | skids++ | lib/Language/objects.pod:
03:17 dalek doc: Document object cloning.
03:17 dalek doc: review: https://github.com/perl6/doc/commit/d37c260c1e
03:20 El_Che joined #perl6
03:42 Akagi201 joined #perl6
03:46 baest_ joined #perl6
03:50 anocelot joined #perl6
03:51 adu joined #perl6
03:58 Akagi201 joined #perl6
03:59 raiph joined #perl6
04:02 Akagi201 joined #perl6
04:03 tinyblak_ joined #perl6
04:05 spider-mario joined #perl6
04:23 dalek rakudo-star-daily: 4688aea | coke++ | log/ (2 files):
04:23 dalek rakudo-star-daily: today (automated commit)
04:23 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/4688aea674
04:23 dalek perl6-roast-data: c900a45 | coke++ | / (9 files):
04:23 dalek perl6-roast-data: today (automated commit)
04:23 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/c900a45b26
04:29 btyler joined #perl6
04:30 [Coke] I think If I needed to do lookup by name of something, I'd probably stick it in a hash instead. Not sure if that helps.
04:30 anaeem1_ joined #perl6
04:31 anaeem1 joined #perl6
04:32 araujo joined #perl6
04:38 sterfry joined #perl6
04:38 sterfry really?
04:39 sterfry left #perl6
04:39 Zoffix heh
04:40 Zoffix Drive-by incredulity.
05:00 Alina-malina joined #perl6
05:04 lolisa joined #perl6
05:10 dolmen joined #perl6
05:13 alini joined #perl6
05:23 KCL joined #perl6
05:30 LordVorp left #perl6
05:32 silug joined #perl6
05:33 Perl6_newbee joined #perl6
05:41 laouji joined #perl6
05:45 Psyche^ joined #perl6
05:50 kaare__ joined #perl6
06:09 laouji_ joined #perl6
06:20 sqirrel joined #perl6
06:24 pyrimidine joined #perl6
06:26 baest joined #perl6
06:43 rindolf joined #perl6
06:43 jnthn morning, #perl6
06:44 pyrimidi_ joined #perl6
06:49 _mg_ joined #perl6
06:54 brrt joined #perl6
06:58 Ven joined #perl6
06:59 raydiak mornin jnthn
07:00 masak mornin', #perl6
07:01 raydiak \o masak
07:02 Ven \o, masak
07:02 masak japhb: it's not so much that "public attributes and public methods are unified", it's more like "public attribute = private attribute + (autogenerated) public accessor method"...
07:03 jnthn In answer to the backlog question of "can I get 'self' through CALLER", I can confirm the answer is "no" 'cus it's not marked dynamic; moreover we actually *do* optimize the self lexical out in some cases. :)
07:04 RabidGravy joined #perl6
07:04 lizmat joined #perl6
07:05 masak good :)
07:05 lizmat good morning from the 2015 QA Hackathon in Berlin
07:05 moritz \o lizmasakjnthndiakven
07:06 masak lizmat++ # assuring quality, together with dozens others
07:06 Ven \o lizmat++
07:08 tadzik g'morning
07:09 sjn \o
07:09 * jnthn waves to all at the QA Hackathon :)
07:10 * QAHackathon waves back
07:10 [TuxCM] joined #perl6
07:10 * Ven waves at tadzikathon
07:10 araujo joined #perl6
07:11 Ven So, I was thinking of writing a quickcheck library for perl6, but then I realized -- do we get anything from encoding it there instead of in subsets/PRE/POST?
07:12 nine Should I be worried that I get random test failures in Inline::Perl5? Like 8 out of 20 test files die and never the same ones.
07:12 yoleaux 15 Apr 2015 22:24Z <lizmat> nine: S22:235 specifies depends as "A list of run-time dependencies, specified as C<use> strings."
07:12 synbot6 Link: http://design.perl6.org/S22.html#line_235
07:12 yoleaux 15 Apr 2015 22:24Z <lizmat> nine: so you can depend on a specific version / auth of a module
07:12 jnthn nine: Yes, that sounds like memory corruption-ish problems
07:17 nine jnthn: oh, the answer is much simpler than that: I have -j6 in my .proverc and apparently running those tests in parallel does not work. I guess it's got something to do with t/precomp.t
07:20 dalek nqp: d4b4bcc | jnthn++ | src/QRegex/P6Regex/Grammar.nqp:
07:20 dalek nqp: Better error on solitary backtrack control.
07:20 dalek nqp:
07:20 dalek nqp: Provide a way for Perl6::Grammar to override this to use a typed
07:20 dalek nqp: exception too.
07:20 dalek nqp: review: https://github.com/perl6/nqp/commit/d4b4bcc8f3
07:20 jnthn nine: phew :)
07:23 dolmen joined #perl6
07:23 dalek rakudo/nom: b55263a | jnthn++ | / (3 files):
07:23 dalek rakudo/nom: Give a good error for solitary backtrack control.
07:23 dalek rakudo/nom:
07:23 dalek rakudo/nom: Resolves RT #77786, which complained about a poor error for / : /.
07:23 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b55263afb0
07:23 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=77786
07:25 dalek roast: 13567f2 | jnthn++ | S05-metasyntax/repeat.t:
07:25 dalek roast: Test for RT #77786.
07:25 dalek roast: review: https://github.com/perl6/roast/commit/13567f21b5
07:25 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=77786
07:28 Ven would it be interesting to be able to disable PRE/POST in "release mode", or should the JIT take care of optimizing these out?
07:29 Rounin joined #perl6
07:30 cschwenz joined #perl6
07:32 leont joined #perl6
07:36 dalek rakudo/nom: e1e71d3 | lizmat++ | src/core/Any.pm:
07:36 dalek rakudo/nom: Simplify dd(), make it work for expressions
07:36 dalek rakudo/nom:
07:36 dalek rakudo/nom: $ 6 'dd my $a = 42, 43'
07:36 dalek rakudo/nom: $a = 42
07:37 dalek joined #perl6
07:41 Ven Can I inspect a constructor? (to see what kind of arguments it needs).
07:45 zakharyas joined #perl6
07:50 Amurita joined #perl6
07:52 Ven the problem I'm thinking of is: I want to create instances on-the-fly, but it seems hard to know which types the arguments need. I probably need to inspect the constructor, check the argument names, and if they don't have types associated, try to find a member field and check its type...
07:53 jnthn Ven: Default constructors take named arguments and have them bound to the attributes with accessors, so you can .^attributes.grep(*.has-accessor) or so
07:53 moritz Ven: what problem are you trying to solve?
07:54 Ven m: class A{has $.a = 5; submethod BUILD{}}; say A.new(:a(10)).a; A .^attributes.grep(*.has-accessor)
07:54 camelia rakudo-moar e1e71d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/a_jHoZe6Da␤Two terms in a row␤at /tmp/a_jHoZe6Da:1␤------> 3bmethod BUILD{}}; say A.new(:a(10)).a; A7⏏5 .^attributes.grep(*.has-accessor)␤    expecting any of:␤        infix␤        infix stop…»
07:54 Ven m: class A{has $.a = 5; submethod BUILD{}}; say A.new(:a(10)).a; say A.^attributes.grep(*.has-accessor)
07:54 camelia rakudo-moar e1e71d: OUTPUT«5␤Mu $!a␤»
07:54 Ven jnthn: ^ what about this? I need to check for an user-defined constructor basically?
07:54 moritz Ven: 'cause if there's only a limited set of possible keys, you can just pass them all to .new
07:54 moritz Ven: that way (introspecting the objects) lies madness
07:55 DrForr Incidentally there's now a Perl6 FB group, if anyone's at all interested.
07:55 Ven moritz: I wanted to write a quickcheck-like (the "like" is important) library for perl6, and I'm thinking on how I can create instances "for you"
07:55 nine JSON::Tiny failes with: # Failed test 'Hash of Stuff'
07:55 nine # at t/04-roundtrip.t line 39
07:55 nine # expected: {:!keyfive, :keyfour(4), :keyone(["an", "array"]), :keyseven(3.2), :keysix, :keythree({:another("hash")}), :keytwo("A string")}
07:55 nine #      got: {:!keyfive, :keyfour(4), :keyone(["an", "array"]), :keyseven(3.2), :keysix, :keythree({:another("hash")}), :keytwo("A string")}
07:56 moritz Ven: ok, then you'll have to make do with approximations
07:57 Ven moritz: that's what I don't want to do :P
07:58 tinyblak joined #perl6
07:58 moritz Ven: then have fun solving the Halting problem
07:58 nine It's about time someone solved that
07:58 Ven moritz: what needs solving the halting problem?
07:58 Ven and why do everyone throws the halting problem around all the time? :P
07:58 moritz Ven: you can't really know what the new, BUILD and BUILDALL methods do if one or more of them is overridden
07:59 Ven moritz: I don't need to
07:59 Ven I need to call them with the correctly-typed arguments, that's all
07:59 moritz Ven: if you don't want to make do with approximations, you have to
07:59 Ven I'll probably add a "register_type(Mu:U, Callable)".
07:59 abraxxa joined #perl6
08:01 Ven m: say :{}.WHAT.perl
08:01 camelia rakudo-moar e1e71d: OUTPUT«Hash[Mu,Any]␤»
08:02 Ven m: say :{Int, 5}{Int}; say :{x => 2, Int, 5}{Int}
08:02 camelia rakudo-moar e1e71d: OUTPUT«postcircumfix:<{ }> not defined for type Block␤  in sub postcircumfix:<{ }> at src/gen/m-CORE.setting:3671␤  in block <unit> at /tmp/b71nAj4lnj:1␤␤»
08:04 Ven EMOREPARENTHESES
08:12 darutoko joined #perl6
08:14 nine Is there a way to declare a multi candidate with a fixed value for a named argument? multi foo(Str :$foo) { ... }
08:15 nine multi foo(Str :$foo where { $foo eq 'foo' }) { ... } like this but without having to use a where block?
08:16 jnthn Not afaik, but you can write that as "where 'foo'"
08:20 telex joined #perl6
08:20 tinyblak joined #perl6
08:21 nine jnthn: thanks! This also fixed my JSON::Tiny failures?!
08:25 moritz nine: note that named params play a secondary role in multi dispatch
08:26 moritz nine: so dispatching mostly one a named param is usually a bad idea
08:27 nine moritz: I guess I don't have much choice. My candidate is multi sub EVAL(Cool $code, :$lang where { $lang // '' eq 'perl5' }, PseudoStash :$context)
08:28 FROGGS joined #perl6
08:29 donaldh joined #perl6
08:30 moritz nine: ok
08:31 Ven can I inspect a subset's where?
08:32 andreoss` joined #perl6
08:32 laouji joined #perl6
08:32 jnthn m: $subset-type.^refinement
08:32 camelia rakudo-moar e1e71d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/uqYomkocz6␤Variable '$subset-type' is not declared␤at /tmp/uqYomkocz6:1␤------> 3$subset-type.^refinement7⏏5<EOL>␤    expecting any of:␤        method arguments␤»
08:32 jnthn oops
08:33 jnthn didn't mean to m: it :)
08:33 * Ven mumbles something about said halting problem... :)
08:34 Ven m: subset Foo of Int where 10..50; say Foo.WHAT; say Foo.^refinement;
08:34 camelia rakudo-moar e1e71d: OUTPUT«(Foo)␤-> ($_) { #`(Block|65247216) ... }␤»
08:34 Ven it's always translated to a block, sadly. means I can't use that to generate anything
08:38 FROGGS o/
08:38 jnthn o/ FROGGS
08:41 Ven mmh, I need to "ok" inside of my quickchecker, but then how to prettify stacktraces...
08:41 Ven o/ FROGGS !
08:42 dalek specs: d702a9e | (Cédric VINCENT)++ | S17-concurrency.pod:
08:42 dalek specs: Fix .cue parameter names.
08:42 dalek specs: review: https://github.com/perl6/specs/commit/d702a9ed5a
08:44 psch m: multi f("a") { say "a!" }; multi f(Str $a) { say "$a?!" }; f "ab"; f "a"
08:44 camelia rakudo-moar e1e71d: OUTPUT«ab?!␤a!␤»
08:45 dakkar joined #perl6
08:45 psch nine: literal as positional parameter just works, from the looks of it
08:46 psch iohh
08:46 psch yeah
08:46 psch that's why it was asked for named
08:46 * psch goes to get more coffee
08:47 Ven should a quickcheck use "ok" for its invariant checking, and should it print the generated value in the "ok"'s "description"?
08:48 dalek Heuristic branch merge: pushed 299 commits to rakudo/tab-completion by FROGGS
08:48 leont joined #perl6
08:48 nwc10 good *, leont
08:50 Ven should Perl6 come bundled with types such as NegativeInt, PositiveInt? I thought about "RangedInt", but we can't have compile-time "parameters" to subset (I'm thinking of template<int from, int to> using range = from..to or something)
08:52 lizmat .oO( PInt :-)
08:53 Ven m: my %h = :{(Int) => { round rand * 1000 }, DEFAULT => 5} # mmh? Pretty please?
08:53 camelia rakudo-moar e1e71d: OUTPUT«use of uninitialized value of type Int in string context  in block <unit> at /tmp/M5rbDfbi8r:1␤␤Saw 1 call to deprecated code during execution.␤================================================================================␤%h = itemized hash call…»
08:54 leont Oh hai
08:54 jnthn Ven: You'd want := there
08:54 Ven m: my %h := :{(Int) => { round rand * 1000 }, DEFAULT => 5} # mmh? Pretty please?
08:54 camelia rakudo-moar e1e71d: ( no output )
08:55 Ven jnthn: or should I use a scalar instead?
08:55 Ven (because I can't use := for an attribute)
08:57 jnthn Ven: could do
09:00 flaf_ joined #perl6
09:02 Ven joined #perl6
09:04 pippo joined #perl6
09:05 pippo m: my $a = 42; dd $a;
09:05 camelia rakudo-moar e1e71d: OUTPUT«$a = 42␤»
09:06 pippo On the REPL I also have "cannot stringify this". Is it OK?
09:06 dalek rakudo/nom: d8ec4d1 | jnthn++ | src/Perl6/Grammar.nqp:
09:06 dalek rakudo/nom: Toss unused dynamic.
09:06 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d8ec4d1b2f
09:06 dalek rakudo/nom: 753dae8 | jnthn++ | src/Perl6/Grammar.nqp:
09:06 dalek rakudo/nom: Add %*PRAGMAS as a first step to lexical pragmas.
09:06 dalek rakudo/nom:
09:06 dalek rakudo/nom: For now this will just let us get things like MONKEY-TYPING and soft
09:06 dalek rakudo/nom: to behave lexically; the key driver is to support upcoming refactor
09:06 dalek rakudo/nom: of how "use fatal;" works, however.
09:06 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/753dae8b06
09:07 tinyblak joined #perl6
09:07 tadzik pippo: same here, looks like the REPL is trying to stringify the return value of dd
09:07 tadzik and what that is, I have no idea
09:07 tadzik before you asked I didn't know dd existed :)
09:08 pippo :-)
09:08 espadrine joined #perl6
09:10 pippo That means that I hove no local pb. Thank you tadzik.
09:10 dalek rakudo/nom: b3292f6 | jnthn++ | src/Perl6/Grammar.nqp:
09:10 dalek rakudo/nom: Make 'use MONKEY-TYPING' lexical.
09:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b3292f647a
09:10 dalek rakudo/nom: b220d9a | jnthn++ | src/Perl6/ (2 files):
09:10 dalek rakudo/nom: Make 'use soft' lexical.
09:10 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b220d9af56
09:10 pippo o/
09:10 pippo left #perl6
09:10 Ven mmh, can I split my test plans?
09:11 Ven The basic idea -- I want Sixcheck.check to run :$iterations tests, but each call to Sixcheck.check must have its own plan...
09:12 dalek Heuristic branch merge: pushed 120 commits to nqp/no-readlineint by FROGGS
09:12 dalek Inline-Perl5: e939cf1 | (Stefan Seifert)++ | / (2 files):
09:12 dalek Inline-Perl5: Fix passing arrays to P5 callables
09:12 dalek Inline-Perl5:
09:12 dalek Inline-Perl5: Arrays were always flattened. Fixed to pass them as arrayrefs instead.
09:12 dalek Inline-Perl5:
09:12 dalek Inline-Perl5: Uncovered by roast++
09:12 dalek Inline-Perl5: review: https://github.com/niner/Inline-Perl5/commit/e939cf1844
09:13 nwc10 Ven: Yes, the test harness certainly supports that
09:13 jnthn Ven: Sonds like subtests
09:14 jnthn *sounds
09:14 jnthn Test.pm supports those.
09:14 nwc10 but I don't know how to get the test modules to do subtests.
09:14 * Ven goes off to Google
09:14 [ptc] Ven: no need to google: http://doc.perl6.org/language/testing
09:16 masak I wonder if there would be a market demand for a Perl 6 module that provided an object-oriented API to regex ASTs.
09:16 masak i.e. build your regex programmatically. or take a given regex and traverse its AST.
09:16 Ven [ptc]: google gave me that link :)
09:16 jnthn masak: I'd figured that'd fall under the QTree work :)
09:17 masak jnthn: it sure would.
09:17 dalek rakudo/nom: 7adc750 | lizmat++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
09:17 dalek rakudo/nom: Improve Invocant requires a type object message
09:17 dalek rakudo/nom:
09:17 dalek rakudo/nom: - show the name of the object
09:17 dalek rakudo/nom: - if an instance was needed, nudge towards a possibly missing .new
09:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/7adc7504a4
09:17 dalek rakudo/nom: d603ba4 | lizmat++ | src/core/Attribute.pm:
09:17 dalek rakudo/nom: Auto-generated accessors need an instance now
09:17 dalek rakudo/nom:
09:17 dalek rakudo/nom: This improves the error:
09:17 dalek rakudo/nom:
09:17 dalek rakudo/nom:    Cannot look up attributes in a type object
09:17 dalek rakudo/nom:
09:17 dalek rakudo/nom: now to:
09:17 dalek rakudo/nom:
09:17 dalek rakudo/nom:   Invocant requires a 'Foo' instance, but a type object was passed.
09:17 dalek rakudo/nom:   Did you forget a .new?
09:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d603ba4723
09:17 masak jnthn: but it strikes me that this could be cheated long before Qtree is in place.
09:17 Ven subtests work, amazing
09:17 masak jnthn: and maybe it'd give useful clues/hints on how Qtree oughta work, too.
09:18 lizmat Ven: they have been for a while  :-)
09:18 [ptc] Ven: great!
09:18 Ven EDIDNTKNOW
09:18 masak jnthn: OO'd regex building could be cheated worst-case with EVAL. introspection would probably have to drop down to the nqp level, I guess.
09:18 lizmat don't look at the way it is coded, though  :-)   It's very Perl 4ish
09:19 masak lizmat++ # better error messages
09:19 [ptc] Ven: was talking to steven++ about misleading perl6 doc links at nlpw and he said he'd not found doc.perl6.org in that which google spits out
09:19 masak that's QA! :)
09:19 nine lizmat++ waking us up occasionally by pinging
09:19 Ven [ptc]: my google might be biased :)
09:19 [ptc] Ven: glad to hear that doc.perl6.org has gone up a bit in Google's ranking :-)
09:19 masak lizmat++ # nice to hear that ping :)
09:20 vendethiel joined #perl6
09:21 dalek perl6-examples: 6052e63 | paultcochrane++ | lib/HomePage.pod:
09:21 dalek perl6-examples: Add missing categories to HomePage
09:21 dalek perl6-examples:
09:21 dalek perl6-examples: Thanks to japh++ for pointing this out
09:21 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/6052e63ead
09:22 dalek rakudo/nom: bf00dd1 | jnthn++ | src/Perl6/Optimizer.nqp:
09:22 dalek rakudo/nom: Explicitly detect Failure in constant folding.
09:22 dalek rakudo/nom:
09:22 dalek rakudo/nom: Before, we set $*FATAL, but since "use fatal" isn't meant to be done
09:22 dalek rakudo/nom: that way, we can't use this approach any more.
09:22 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/bf00dd1086
09:23 dalek rakudo/nom: db45d92 | jnthn++ | src/ (4 files):
09:23 dalek rakudo/nom: Re-implement 'use fatal' to be more correct.
09:23 dalek rakudo/nom:
09:23 dalek rakudo/nom: Per TimToady++, a dynamic variable is the wrong approach. Rather, we
09:23 dalek rakudo/nom: should do it by AST re-writing in the leixcal scope where 'use fatal'
09:23 dalek rakudo/nom: is in force. This is a first attempt at implementing that. It's good
09:23 dalek rakudo/nom: enough to pass all of the spectests that the previous 'use fatal'
09:23 dalek rakudo/nom: implementation did. $*FATAL goes away as a result.
09:23 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/db45d92be1
09:30 dalek roast: 7d91cd7 | jnthn++ | S04-exceptions/fail.t:
09:30 dalek roast: More tests for 'use fatal' and boolifiers.
09:30 dalek roast: review: https://github.com/perl6/roast/commit/7d91cd7ee8
09:30 dalek roast: 0251db6 | jnthn++ | S32-exceptions/misc.t:
09:30 dalek roast: Test 'use MONKEY-TYPING' acts lexically.
09:30 dalek roast: review: https://github.com/perl6/roast/commit/0251db605c
09:34 Ven joined #perl6
09:35 Ven my very basic idea: https://github.com/vendethiel/Sixcheck/blob/master/t/01-create.t#L17. my very basic implem: https://github.com/vendethiel/Sixcheck/blob/master/lib/Sixcheck.pm#L27
09:36 Ven should "check-sub" (or check-code or check-callable) call every single .candidates?
09:36 dalek rakudo/nom: b2a928e | jnthn++ | src/Perl6/Actions.nqp:
09:36 dalek rakudo/nom: Add defined to 'use fatal' defusers.
09:36 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b2a928e431
09:36 leont joined #perl6
09:36 dalek roast: be7773b | jnthn++ | S04-exceptions/fail.t:
09:36 dalek roast: Test 'use fatal' respects defined also.
09:36 dalek roast: review: https://github.com/perl6/roast/commit/be7773b556
09:37 dalek rakudo/nom: b8f4051 | peschwa++ | src/core/Any.pm:
09:37 dalek rakudo/nom: Don't implicitly return a VM array from &dd.
09:37 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b8f4051a0a
09:37 psch &dd shouldn't be hot enough to not want an explicit return, i hope
09:39 dalek rakudo/nom: df38418 | lizmat++ | src/core/Attribute.pm:
09:39 dalek rakudo/nom: Hide auto-generated accessors from backtraces
09:39 dalek rakudo/nom:
09:39 dalek rakudo/nom: There is no point in guiding developers to the location in the core settings
09:39 dalek rakudo/nom: where they are generated!
09:39 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/df38418ff0
09:40 lizmat psch: dd is supposed a debugging aid to be called in sink context
09:40 Ven lizmat++ # good catch
09:40 psch lizmat: so it's not supposed to be used as the last statement in the REPL?
09:40 psch lizmat: because that's where the VM array can't be stringified
09:40 lizmat ah, ok
09:40 lizmat makes sense  :-)
09:41 * lizmat hardly ever uses the REPL
09:42 dalek rakudo/newio: b55263a | jnthn++ | / (3 files):
09:42 dalek rakudo/newio: Give a good error for solitary backtrack control.
09:42 dalek rakudo/newio:
09:42 dalek rakudo/newio: Resolves RT #77786, which complained about a poor error for / : /.
09:42 dalek rakudo/newio: review: https://github.com/rakudo/rakudo/commit/b55263afb0
09:42 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=77786
09:43 dalek joined #perl6
09:43 masak ooh, that was one of mine. jnthn++
09:43 Ven m: for ^10 -> Int $i { $i.say }
09:43 camelia rakudo-moar 753dae: OUTPUT«0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤»
09:46 Ven m: my @args = do for ^10 { "hey" when 1; "bar" when 2; "baz" when 3;  default { $_ } }; say @args;
09:46 camelia rakudo-moar 753dae: OUTPUT«0 1 2 3 4 5 6 7 8 9␤»
09:47 Ven m: my @args = do for ^10 { when 1 { "hey" }; when 2 { "bar" }; when 3{"baz"};  default { $_ } }; say @args; # I need to remember this
09:47 camelia rakudo-moar 753dae: OUTPUT«5===SORRY!5=== Error while compiling /tmp/FgUWYzoNva␤Missing block␤at /tmp/FgUWYzoNva:1␤------> 3"hey" }; when 2 { "bar" }; when 3{"baz"}7⏏5;  default { $_ } }; say @args; # I need␤    expecting any of:␤        parameterized block␤»
09:47 Ven m: my @args = do for ^10 { when 1 { "hey" }; when 2 { "bar" }; when 3 {"baz"};  default { $_ } }; say @args; # I need to remember this
09:47 camelia rakudo-moar 753dae: OUTPUT«0 hey bar baz 4 5 6 7 8 9␤»
09:47 konsolebox joined #perl6
09:48 konsolebox joined #perl6
09:48 dalek rakudo/nom: 9dada5e | usev6++ | src/core/Cool.pm:
09:48 dalek rakudo/nom: Make .subst-mutate on non-strings return match object(s)
09:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/9dada5ef69
09:49 dalek roast: 8986659 | peschwa++ | S05-substitution/subst.t:
09:49 dalek roast: Add test for PR #403.
09:49 dalek roast: review: https://github.com/perl6/roast/commit/8986659f41
09:49 psch hm
09:49 psch so i've merged the PR manually, does github realizse that?
09:49 psch or do i just "Close and comment"?
09:49 tadzik it should realize
09:49 tadzik usually does for me
09:50 psch hm
09:53 pecastro joined #perl6
09:53 psch i'm making a mess again it seems :P
10:02 psch tadzik: so i still click "Merge PR" on github?
10:02 jnthn psch: Probably you want to just comment you merged it manually and press "comment and close"
10:03 tadzik psch: did you push after merging? :)
10:03 psch tadzik: yeah, it's the one reported by dalek credited a usev6 a few minutes ago
10:04 psch jnthn: aw shucks, so i did it right all along and made a mess out of insecurity? :)
10:04 psch oh
10:04 psch i think i know the problem
10:04 psch i apparently missed --no-ff
10:04 psch 'cause there's no merge commit
10:05 psch grml
10:05 jnthn Well, you maybe rebased or avoided the merge commit, which is good, but may have thrown github off
10:05 jnthn I'm happy not to litter history with lots of merge commits, though :)
10:07 tinyblak joined #perl6
10:08 psch it's a bit unfortunate that github doesn't think that the right way to merge though
10:08 psch seeing as PRs can be "closed" or "merged", with no way to decide that directly
10:11 nwc10 sadly github has made some daft choices.
10:11 nwc10 torturing users for the benefit of implementors
10:12 laouji joined #perl6
10:13 _mg_ joined #perl6
10:15 psch i'm wondering if #299 actually has any merit
10:16 psch on the one hand it simplies the code in make_smartmatch and fits StrDistance into the ACCEPTS interface, but on the other it's probably a tad slower and the ACCEPTS method looks weird to me
10:16 psch https://github.com/rakudo/rakudo/pull/299/files for reference
10:16 FROGGS psch: is it really slower?
10:17 psch FROGGS: right, don't guess, meassure :)
10:17 dalek rakudo/nom: 225d3d8 | jnthn++ | src/Perl6/Actions.nqp:
10:17 dalek rakudo/nom: s/QAST::Stmt/QAST::Stmts/ in p6fatalize code-gen.
10:17 dalek rakudo/nom:
10:17 dalek rakudo/nom: Otherwise we can cause premature reclaim of various locals.
10:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/225d3d83c8
10:17 dalek rakudo/nom: 89ed334 | jnthn++ | src/Perl6/Actions.nqp:
10:17 dalek rakudo/nom: It's Failure.sink, not Failure.Sink.
10:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/89ed334750
10:17 dalek rakudo/nom: b3a5c79 | jnthn++ | src/Perl6/Actions.nqp:
10:17 dalek rakudo/nom: Fix incorrect fatalization of method calls.
10:17 dalek rakudo/nom:
10:17 dalek rakudo/nom: They get wrapped in hllize, and that should be transparent to the "in
10:17 dalek rakudo/nom: boolean context".
10:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b3a5c791be
10:17 dalek Inline-Perl5: 913a47a | (Stefan Seifert)++ | / (2 files):
10:17 dalek Inline-Perl5: Prevent inherited Any methods from interfering with calls to P5 methods
10:17 dalek Inline-Perl5:
10:17 dalek Inline-Perl5: Perl5Object inherits methods like "push" and "list" from Any. This
10:17 dalek Inline-Perl5: prevents the fallback that passes calls to such methods to the wrapped
10:17 dalek Inline-Perl5: P5 object from kicking in. Work around that by explicitly adding wrapper
10:17 dalek Inline-Perl5: methods.
10:17 dalek Inline-Perl5:
10:17 dalek Inline-Perl5: Thanks to lizmat++ for giving the inspiration.
10:17 dalek Inline-Perl5: review: https://github.com/niner/Inline-Perl5/commit/913a47a1d9
10:17 dalek roast/fudge: 09d96ff | usev6++ | t/README:
10:17 dalek roast/fudge: Add dir to test fudge itself
10:17 dalek roast/fudge: review: https://github.com/perl6/roast/commit/09d96ffd78
10:17 tadzik masak: yt?
10:18 psch i'll bench it first
10:18 nine woohoo...this should fix most of the gotchas I mentioned in my FOSDEM talk :)
10:18 tadzik noice :)
10:19 masak tadzik: kinda.
10:19 cognominal joined #perl6
10:21 tadzik masak: I'm trying to find the author of topo-sort, that was imported into Panda::Builder from ufo, I believe
10:21 tadzik or otherwise someone who could help me understand where and why it stringifies what it gets
10:22 colomon twas masak++, wasn’t it?
10:22 tadzik I think so
10:22 masak I wrote the original for ufo.
10:22 masak I believe moritz++ copied it into panda, perhaps?
10:23 masak tadzik: could you link me to the line and file in panda?
10:23 tadzik well, I'm not trying to assign the blame :)
10:23 tadzik masak: yes, will push it in a moment
10:24 rindolf joined #perl6
10:24 Ven Would it make sense to have Int.pick / Int.roll?
10:26 DrForr Sounds rather Postscript :)
10:27 jnthn Ven: Not really given it's arbitrary precision.
10:28 lizmat int8.pick might make sense
10:28 Ven jnthn: so I should just go with (-5000..5000).pick, say?
10:28 lizmat m: int8.Range.pick.say
10:28 camelia rakudo-moar 9dada5: OUTPUT«-31␤»
10:28 lizmat m: uint8.Range.pick.say
10:28 camelia rakudo-moar 9dada5: OUTPUT«253␤»
10:28 lizmat m: uint8.Range.pick.say
10:28 camelia rakudo-moar 9dada5: OUTPUT«33␤»
10:28 lizmat m: uint8.Range.pick(*).say
10:28 camelia rakudo-moar 9dada5: OUTPUT«5 77 207 231 175 204 19 111 143 251 190 188 174 209 164 232 160 149 23 106 39 163 124 219 199 123 211 72 89 221 25 127 138 234 217 182 22 82 248 215 141 36 133 17 31 26 27 101 189 192 59 132 226 206 15 6 220 94 95 158 21 41 99 84 58 33 156 125 44 246 148 2…»
10:29 diana_olhovik_ joined #perl6
10:29 aborazmeh joined #perl6
10:29 aborazmeh joined #perl6
10:29 leont joined #perl6
10:29 dalek roast: 410bcb4 | jnthn++ | S32-str/numeric.t:
10:29 dalek roast: Adapt test in prep for try doing 'use fatal'.
10:29 dalek roast: review: https://github.com/perl6/roast/commit/410bcb417a
10:30 tadzik masak: https://github.com/tadzik/panda/blob/revdep-rebuild/lib/Panda/Ecosystem.pm#L150
10:31 tadzik masak: I'm passing a list of Panda::Project-s into topo-sort, and the dependency tree. topo-sort does its magic but sometimes (!) it gives me back a string instead of Panda::Project
10:33 dalek roast/fudge: 609a62b | FROGGS++ | t/fudge.t:
10:33 dalek roast/fudge: add test file to test fudge in-/outputs
10:33 dalek roast/fudge: review: https://github.com/perl6/roast/commit/609a62bf00
10:34 nine We're using title case for use :from<Perl5> but EVAL still defaults to $lang = 'perl6'. Should the latter be using title case as well? Would be more consistent.
10:35 psch four runs each with 10000 iterations of the same transliterations give me between .05 and .2 faster runtime with ACCEPTS instead of special casing in make_smartmatch
10:35 psch on hack, which i guess might be just noise
10:36 nwc10 measure it with cachegrind?
10:36 nwc10 which will count the instructions
10:36 psch nwc10: how do i do that?
10:36 nwc10 OK, given that perl6-m is not (yet) a real executable, but a shell script
10:37 nwc10 and valgrind doesn't cope with a shell script
10:37 nwc10 if you were testing it as
10:37 nwc10 ./perl6-m foo ...
10:37 nwc10 then do this:
10:37 nwc10 cat perl6-m
10:37 lizmat m: my Int @y = 2..3,5..*; say @y.map( { say $_ >= @y.gimme( $_ + 1 ); last } )   # Tux's problem golfed down
10:37 camelia rakudo-moar 9dada5: OUTPUT«False␤␤»
10:37 nwc10 which gives you something like:
10:37 lizmat that should be True
10:37 nwc10 #!/bin/sh
10:37 nwc10 exec /home/nc/Sandpit/moar-O2/bin/moar  --execname="$0" --libpath="/home/nc/Sandpit/moar-O2/share/nqp/lib" --libpath="." /home/nc/Perl/rakudo/perl6.moarvm "$@"
10:38 RabidGravy In the "Obsolete Functions" section of S29 it says several times "The NameServices role in S16 covers most of these."  but there is no apparent mention of the "NameServices role" in S16 that I can see
10:38 nwc10 take that second line
10:38 nwc10 grab this bit:
10:38 nwc10 exec /home/nc/Sandpit/moar-O2/bin/moar  --execname="$0" --libpath="/home/nc/Sandpit/moar-O2/share/nqp/lib" --libpath="." /home/nc/Perl/rakudo/perl6.moarvm "$@"
10:38 nwc10 and go
10:38 psch nwc10: yeah, i know about that.  i don't know how to invoke cachegrind, but it's apparently a valgrind flag
10:38 psch sorry for being unclear there :)
10:38 nwc10 valgrind --tool=cachegrind /home/nc/Sandpit/moar-O2/bin/moar  --execname="$0" --libpath="/home/nc/Sandpit/moar-O2/share/nqp/lib" --libpath="." /home/nc/Perl/rakudo/perl6.moarvm foo ...
10:38 nwc10 OK, sorry, guessed the detail a bit wrong
10:38 Ven m: subset MultiSub of Sub where *.candidates.elems > 1; sub x(MultiSub){}; multi sub f(Int){}; multi sub f(Str){}; x(&f);
10:38 camelia rakudo-moar 9dada5: OUTPUT«Cannot look up attributes in a type object␤  in sub x at /tmp/_ZpFkDXORn:1␤  in block <unit> at /tmp/_ZpFkDXORn:1␤␤»
10:39 Ven ^ jnthn: does that look like a bug?
10:39 nwc10 I think that last bit is what you need
10:39 nwc10 you can probably drop the --execname="$0" bit
10:39 nwc10 but I've not bothered
10:40 _mg_ joined #perl6
10:41 psch not having --execname can through "uninitialized value of type Str" iirc
10:41 psch *throw
10:41 masak tadzik: looking.
10:45 dalek roast/fudge: 1c13068 | usev6++ | t/README:
10:45 dalek roast/fudge: Add minimial explanation to README
10:45 dalek roast/fudge: review: https://github.com/perl6/roast/commit/1c13068670
10:45 dalek roast/fudge: 57211c4 | usev6++ | t/01-implname. (3 files):
10:45 dalek roast/fudge: Add example in-/output to test 'implname'
10:45 dalek roast/fudge: review: https://github.com/perl6/roast/commit/57211c46cb
10:46 rurban_ joined #perl6
10:46 psch hm, pretty much all numbers are bigger with ACCEPTS :)
10:47 * psch goes to read up how to read cachegrind output
10:48 masak tadzik: there's nothing in that code that suggests to me that topo-sort would stringify.
10:48 tadzik masak: yeah, invisible for me too :/
10:48 masak tadzik: rather, I'd look at the earlier parts of revdeps.
10:49 masak tadzik: maybe try to run revdeps and topo-sort in isolation, mocking the rest, trying to reproduce the stringification thing under known circumstances.
10:49 tadzik no, I checked before and after the call to topo-sort
10:49 tadzik somewhere there Panda::Project(panda) turns into 'panda'
10:49 tadzik yeah, I'll try that
10:49 masak the only thing is that there are some hashes involved whose key type is Str()
10:49 tadzik well, it doesn't have to be
10:50 masak but looking at topo-sort, I don't really see how that would make the list of returned modules strings.
10:50 tadzik we do have hashes on objects, there's nothing in topo-sort that turns those into strings
10:50 nine What does \%hash mean exactly in Perl 6?
10:50 jnthn Ven: Looks like, yes.
10:51 masak m: my %hash; say %hash.WHAT; say (\%hash).WHAT
10:51 camelia rakudo-moar b3a5c7: OUTPUT«(Hash)␤(Capture)␤»
10:51 masak nine: takes a Capture of the hash. kind of like a reference to it.
10:51 psch m: my %h; say \%h ~~ :(%)
10:51 camelia rakudo-moar b3a5c7: OUTPUT«True␤»
10:52 psch nine: http://doc.perl6.org/type/Capture
10:52 masak tadzik: right. aka "inexplicable" or "this shouldn't happen"
10:52 psch "The flip-side of Signatures"
10:52 masak tadzik: which is why I'm really interested in an isolated case where it's reproduced :)
10:52 tadzik yeah
10:53 masak psch: right, that's a good way of saying it. Signatures are what declare parameters in the callee; Captures bundle up arguments at the call site.
10:53 nine masak: so does line 38 in S01-perl-5-integration/basic.t make sense? { my $test = '%h.kv received as hash'; my ($k,$v) = $p5_dumper(%h.kv);
10:54 nine masak: sorry, wrong line
10:54 nine masak: { my $test = '\%h received as hashref'; my %o := $p5_dumper(\%h); is(%o<a>, 1, $test);
10:54 lizmat m: my @a; say @a[^Inf].perl   # better golf of Tux's problem
10:54 camelia rakudo-moar b3a5c7: OUTPUT«()␤»
10:55 lizmat do we consider this to be correct or not?
10:55 psch masak: skids++ then, he's apparently the one who wrote that to doc.perl6.org :)
10:55 jnthn lizmat: I think that one is correct
10:55 masak nine: think so. that'd be kind of like passing `$%h` in Perl 5.
10:55 lizmat m: my @a; say @a[^4].perl   # is this?
10:55 camelia rakudo-moar b3a5c7: OUTPUT«()␤»
10:55 masak er.
10:55 masak kind of like passing `\%h` in Perl 5.
10:55 jnthn lizmat: That one I'm less sure on; would need to see the design docs.
10:56 nine masak: to me \%hash looks like Perl 5 while $%hash would be the Perl 6 equivalent
10:56 lizmat m: my @a; say @a[0,1,2,3].perl   # is this?
10:56 camelia rakudo-moar b3a5c7: OUTPUT«(Any, Any, Any, Any)␤»
10:57 jnthn lizmat: Pretty sure that one is correct.
10:57 masak nine: yeah, I was confused there for a while.
10:58 jnthn lizmat: If it wasn't you couldn't say @a[0,1,2,3] = ...;
10:58 lizmat jnthn: but how is 0,1,2,3 different from ^4 ?
10:58 masak nine: but functionally \%h in Perl 6 is quite similar to \%h in Perl 5.
10:59 jnthn lizmat: The first is a list, the second is a range object. I agree it's weird they differ; again, we should check design docs to see if they have any hint,s but my guess is it's an accidental over-generalization of ^Inf handling.
10:59 psch m: sub f (%h) { say %h.perl  }; my %h = 1..4; f(%h); f(\%h)
10:59 camelia rakudo-moar b3a5c7: OUTPUT«{"1" => 2, "3" => 4}<>␤Type check failed in binding %h; expected 'Associative' but got 'Capture'␤  in sub f at /tmp/m1Yy8hxkXO:1␤  in block <unit> at /tmp/m1Yy8hxkXO:1␤␤»
11:00 lizmat well, the former when used as an array index, does not check the result of gimme() on the array
11:00 psch aiui, Captures usually want to smartmatch against of be flatted into a Signature
11:00 nwc10 https://www.youtube.com/watch?v=BhMSzC1crr0&amp;feature=youtu.be
11:00 lizmat the latter does, hence it produces an empty list
11:00 nwc10 poor thing. you can see it firing the lateral thruster just after it landed
11:01 lizmat nwc10: and when it starts going wrong, it fires the lateral thruster on the wrong side quite aggresively as if to hasten the blowup
11:02 dalek roast/fudge: 049e6b4 | FROGGS++ | t/fudge.t:
11:02 dalek roast/fudge: run our first two fudge tests
11:02 dalek roast/fudge: review: https://github.com/perl6/roast/commit/049e6b4987
11:04 dalek roast: de516e7 | jnthn++ | S02-names-vars/names.t:
11:04 dalek roast: Fix an overly-specific test.
11:04 dalek roast:
11:04 dalek roast: The message it was looking for is gone soon; throwing an exception on
11:04 dalek roast: asking for a type check causes too much pain.
11:04 dalek roast: review: https://github.com/perl6/roast/commit/de516e7e3d
11:04 dalek rakudo/nom: 3fb51c7 | jnthn++ | src/core/ (2 files):
11:04 dalek rakudo/nom: Declare Failure early, in prep for fatalizing try.
11:04 dalek rakudo/nom:
11:04 dalek rakudo/nom: We'll need it stubbed before encountering the first 'try' in the
11:04 dalek rakudo/nom: setting.
11:04 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3fb51c7a6a
11:05 hahainternet lizmat: they were experiencing control system lag
11:05 hahainternet you can see the oscillations it's causing
11:06 hahainternet and how the last firing was clearly significantly late
11:06 hahainternet they've definitely got this next time
11:07 dalek rakudo/nom: 0a122c6 | jnthn++ | src/Perl6/Actions.nqp:
11:07 dalek rakudo/nom: Don't re-visit things when fatalizing.
11:07 dalek rakudo/nom:
11:07 dalek rakudo/nom: Avoids getting duplicate p6fatalize insertions in the tree.
11:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0a122c676a
11:07 dalek rakudo/nom: d4cc3d9 | jnthn++ | src/core/Str.pm:
11:07 dalek rakudo/nom: Make :37<a> a Failure, not an exception.
11:07 dalek rakudo/nom:
11:07 dalek rakudo/nom: It now matches the other failrure modes of Str.Numeric, which also
11:07 dalek rakudo/nom: fail rather that die. (Note that the exception was thrown by the
11:07 dalek rakudo/nom: nqp::radix_I op before.)
11:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d4cc3d9ae5
11:07 nine masak: sorry, this still doesn't make any sense to me. Capture is Positional. It's a kind of a list. In my eyes this is far away from a reference in Perl 5.
11:08 dalek specs: e32d821 | (Cédric VINCENT)++ | S17-concurrency.pod:
11:08 dalek specs: s/excuse/cause/ for Promise.
11:08 dalek specs: review: https://github.com/perl6/specs/commit/e32d821d99
11:09 tinyblak joined #perl6
11:13 eli-se joined #perl6
11:13 eli-se hmm
11:13 eli-se .botsnack
11:13 yoleaux :D
11:13 synbot6 om nom nom
11:13 eli-se It should be possible to make yoleaux go OOM.
11:15 dalek rakudo/nom: 04f78eb | jnthn++ | src/Perl6/Metamodel/GenericHOW.nqp:
11:15 dalek rakudo/nom: Don't explode on trying to type-check type var.
11:15 dalek rakudo/nom:
11:15 dalek rakudo/nom: It gives little benefit, at the cost of having to guard various kinds
11:15 dalek rakudo/nom: of type check against it.
11:15 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/04f78ebd5d
11:15 dalek rakudo/nom: e843eff | jnthn++ | src/Perl6/Actions.nqp:
11:15 dalek rakudo/nom: Don't lose returns on call node when fatalizing.
11:15 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e843eff361
11:15 eli-se it converts arbitrary user input into Ruby symbols, for which the memory is never freed
11:18 dalek rakudo/nom: ce73705 | jnthn++ | src/Perl6/Actions.nqp:
11:18 dalek rakudo/nom: Unbust hash/block distinction under 'use fatal'.
11:18 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ce7370569b
11:20 vendethiel joined #perl6
11:21 _mg_ joined #perl6
11:23 dalek rakudo/nom: d9fc6c6 | jnthn++ | src/Perl6/Actions.nqp:
11:23 dalek rakudo/nom: Correctly fatalize code in thunks.
11:23 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d9fc6c65dc
11:24 brrt joined #perl6
11:28 psch hm, maybe i confused the two pastes before
11:28 psch right now i get ~12M less I refs
11:28 psch which sounds kind of much
11:29 dalek rakudo/nom: 2a3e1bf | jnthn++ | src/Perl6/Grammar.nqp:
11:29 dalek rakudo/nom: Apply 'use fatal' inside of try blocks.
11:29 dalek rakudo/nom:
11:29 dalek rakudo/nom: This brings us in line with S04. The new 'use fatal' implementation
11:29 dalek rakudo/nom: does not cause action-at-a-distance. Only one spectest needed some
11:29 dalek rakudo/nom: adaptation for this change, so hopefully fallout in the ecosystem
11:29 dalek rakudo/nom: will be rather minimal.
11:29 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2a3e1bfbae
11:31 dalek roast/fudge: 17504b1 | usev6++ | t/02-version. (3 files):
11:31 dalek roast/fudge: Add example in-/output to test 'version'
11:31 dalek roast/fudge: review: https://github.com/perl6/roast/commit/17504b165f
11:32 lizmat m: try die
11:32 camelia rakudo-moar d4cc3d: ( no output )
11:33 jnthn m: try +'foo'
11:33 camelia rakudo-moar d4cc3d: OUTPUT«Unhandled exception: Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏foo' (indicated by ⏏)␤   at <unknown>:1  (/home/camelia/rakudo-inst-1/share/perl6/runtime/CORE.setting.moarvm:throw:4294967295)␤ from src/…»
11:33 jnthn m: try ...
11:33 camelia rakudo-moar d4cc3d: OUTPUT«Unhandled exception: Stub code executed␤   at src/gen/m-CORE.setting:14345  (/home/camelia/rakudo-inst-1/share/perl6/runtime/CORE.setting.moarvm:throw:121)␤ from src/gen/m-CORE.setting:16201  (/home/camelia/rakudo-inst-1/share/perl6/runtime/CORE.settin…»
11:33 jnthn Both of these are fixed
11:34 lizmat jnthn++
11:37 dalek roast: cfd0c6b | jnthn++ | S04-statements/try.t:
11:37 dalek roast: Unfudge tests for RT #123053.
11:37 dalek roast: review: https://github.com/perl6/roast/commit/cfd0c6b26d
11:37 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=123053
11:40 dalek roast: 800eff0 | jnthn++ | S04-statements/try.t:
11:40 dalek roast: Tests for RT #117217.
11:40 dalek roast: review: https://github.com/perl6/roast/commit/800eff06aa
11:40 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=117217
11:40 eternaleye joined #perl6
11:41 dalek Inline-Perl5: 020dcff | (Stefan Seifert)++ | / (2 files):
11:41 dalek Inline-Perl5: Make Perl5Callables real Callables
11:41 dalek Inline-Perl5: review: https://github.com/niner/Inline-Perl5/commit/020dcff14b
11:44 nine This is madness! my $self = "some text"; is ~EVAL(q/"self is $self"/,:lang<perl5>),"self is some text","lexical inside an EVAL";
11:45 sjn a/me managed to get Perl6 into a Computerworld article :D (in Norwegian, but still... :) http://www.cw.no/artikkel/utvikling/samfunnsnyttig-hacking-pa-kode-konferanse
11:46 chenryn joined #perl6
11:46 tadzik awesome :)
11:46 lizmat jnthn: bare startup time has gone up from .16 to .20 for me
11:47 jnthn nine: Nice!
11:47 jnthn lizmat: Do you know exactly when-ish?
11:47 lizmat today
11:47 lizmat :-(
11:47 andreoss` joined #perl6
11:48 lizmat sort of bisecting now
11:48 nwc10 I think I noticed it yesterday
11:48 lizmat ah, ok
11:48 lizmat that could be
11:48 jnthn OK. I need to eat somehting...bbi15
11:49 lizmat the last commit 2a3e1bfbae669ffc took it from .19 to .20 for me
11:50 aborazmeh joined #perl6
11:50 aborazmeh joined #perl6
11:51 Alina-malina joined #perl6
11:51 brrt is there a perl6 way to get assign a container directly to a class attribute
11:52 brrt like
11:52 brrt m: my $a = 3; my $b := $a; $a *= 3; say $b;
11:52 camelia rakudo-moar 2a3e1b: OUTPUT«9␤»
11:52 Ven joined #perl6
11:52 brrt ... but for attributes
11:52 Ven jnthn: noted, thanks. I'll find a way to work around it for now
11:53 Ven the "problem" 5..* is that it can change meaning based on its context
11:54 Ven (I hit that trying `@a[5..*] = infinite-list`)
11:57 dalek roast/fudge: e998023 | usev6++ | t/02-version. (4 files):
11:57 dalek roast/fudge: Fix expected output for skipped tests; add another output example
11:57 dalek roast/fudge: review: https://github.com/perl6/roast/commit/e99802394f
11:57 andreoss` is rakudo running on cygwin?
11:58 Ven .tell eli-se ruby symbols are GC'd
11:58 yoleaux Ven: I'll pass your message to eli-se.
11:58 Ven andreoss`: it runs fine in cmd.exe :)
11:58 brrt andreoss`: the rakudo star packages are actually windows-native (i.e compiled with the whole visual studio shebang)
11:59 lizmat m: class A { has $.b is rw }; my $a = A.new; $a.b = 42; say $a.b  # brrt, this what you mean?
11:59 camelia rakudo-moar 2a3e1b: OUTPUT«42␤»
11:59 andreoss` i want normal paths
11:59 brrt lizmat: maybe :-), lets try
11:59 nine jnthn: just to be clear. The line I posted is _not_ working right now. Many other tests in S01-perl-5-integration do however
11:59 andreoss` windows-native build doens't run inside cygwin
11:59 anaeem1 joined #perl6
12:00 Ven andreoss`: normal path? a/b/c works inside cmd
12:00 brrt m: class A { has $.b is rw }; my $a = A.new; my $b = 42; $a.b = $b; $b *= 2; say $a.b;
12:00 camelia rakudo-moar 2a3e1b: OUTPUT«42␤»
12:00 brrt m: class A { has $.b is rw }; my $a = A.new; my $b = 42; $a.b := $b; $b *= 2; say $a.b;
12:00 camelia rakudo-moar 2a3e1b: OUTPUT«5===SORRY!5=== Error while compiling /tmp/2HDmOdBlFs␤Cannot use bind operator with this left-hand side␤at /tmp/2HDmOdBlFs:1␤------> 3}; my $a = A.new; my $b = 42; $a.b := $b7⏏5; $b *= 2; say $a.b;␤»
12:00 brrt i had expected that, yes
12:01 lizmat I wonder if that's a shortcoming of the autogenerated accessor
12:01 RabidGravy andreoss`, I'd be suprised if it wouldn't build for cygwin, assuming all the dependencies are met
12:02 andreoss` ok..i will give it a try, since rakudobrew already failed on cygwin
12:02 brrt i wonder...
12:02 tinyblak joined #perl6
12:03 lizmat fwiw, the newio branch doesn't have any specific Cygwin support anymore
12:03 andreoss` Ven: i didn't know about this feature, still no normal escaping though
12:03 tinyblak_ joined #perl6
12:03 Ven normal escaping?
12:03 konsolebox joined #perl6
12:04 brrt m: class A { has $.b; method set-b($b is rw) { $!b := $b; } }; my $a = A.new; my $b = 21; $a.set-b($b); $b *= 2; say $a.b;
12:04 camelia rakudo-moar 2a3e1b: OUTPUT«42␤»
12:04 andreoss` Ven: '' "" are different from UNIX
12:04 brrt the key question is of course, which of these is expected
12:04 Ven Yes, use "", escaping works inside :P
12:05 konsolebox joined #perl6
12:05 andreoss` i better run cygwin bash, less pain
12:06 mr-foobar joined #perl6
12:08 brrt i'd argue that the current behavior is expected. binding is a low-level concept that should probably not sneak up on you
12:09 brrt why the asking? i'm thinking of writing a (scientific) modelling library with perl6
12:09 brrt because perl6 is actually a really nice language to write something like that in
12:10 moritz brrt: which is why I wrote Math::Model in it :-)
12:10 Ven joined #perl6
12:10 brrt oh you did that? awesome
12:10 andreoss` left #perl6
12:10 moritz (though that's just a fancy way to write and integrate a system of PDEs)
12:10 tadzik masak: mystery solved :)
12:11 dalek roast/fudge: 11c2412 | usev6++ | t/02-version.out_v6. (3 files):
12:11 dalek roast/fudge: Use required versions as default for description of skipped tests
12:11 dalek roast/fudge: review: https://github.com/perl6/roast/commit/11c24125db
12:11 brrt that's basically what i need, too
12:11 tadzik or so I think
12:13 brrt 'Math::RungeKutta has last been verified to work on contemporary rakudo on 2011-02-13.'
12:13 Ven should quickcheck stop on the first "wrong" value it's found? (effectively only planning one test)
12:13 masak tadzik: tell me tell me
12:13 moritz brrt: that information is out of date; it used to be in star until 2015.01 or so
12:14 brrt ah ok, so it'll probably just work
12:14 chenryn joined #perl6
12:14 moritz brrt: yes; and if not, do tell me :-)
12:14 tadzik masak: so, there's the dependencies hash
12:14 tadzik it's values will sometimes end up in @order
12:14 tadzik and those values were strings
12:14 brrt btw, what is the perl6 stance on modules? very many small ones or a small number of do-it-alls
12:15 masak ok, so the reason we suspected
12:15 tadzik yeah, something was leaking after all :)
12:15 masak tadzik: oh, the hash *values*!
12:15 masak I see now.
12:15 nine How's v5 doing these days?
12:15 masak tadzik: I guess topo-sort could easily be rewritten so that the values are always objects.
12:16 tadzik masak: well, they can be
12:16 tadzik but if you pass Str in, Str will get out too :)
12:16 jnthn nine: Oh, it'd be a cool thing to make work though:)
12:16 moritz brrt: I don't think there's a shared stance
12:16 tadzik I also simplified it a little bit, because the 'color-of' confused me
12:17 tadzik I mean, I'm not used to calling things that are black and white colored :)
12:17 moritz brrt: all I can say is that when people contribute usefull stuff to my modules, I usually accept :-)
12:17 moritz (maybe with the exception of JSON::Tiny, which should stay ::Tiny)
12:17 tadzik so I turned that into %visited which holds bools, and now it reads nicely
12:17 brrt right
12:17 masak sjn++ # http://www.cw.no/artikkel/utvikling/samfunnsnyttig-hacking-pa-kode-konferanse
12:18 nine jnthn: I think this is the first time that I have no idea whatsoever how I could implement that :) And I'm really not sure if the feature is worth it. Haven't come across a use case so far.
12:18 masak tadzik: I think it makes more sense in the original code.
12:18 jnthn lizmat: Hm, that is only 0.01 different, though, not the whole thing...
12:18 masak tadzik: a real bfs has three colors: black, grey, white.
12:18 masak tadzik: they kind of mean "unseen", "seen but not visited", "visited", respectively
12:19 tadzik masak: yeah, but this isn't bfs :)
12:19 rmgk_ joined #perl6
12:19 tadzik it's dfs
12:19 masak hm, you're right.
12:19 masak yeah, then the naming doesn't make sense.
12:19 masak or maybe it does, but the reason was lost along the way.
12:19 * brrt afk
12:20 tadzik ISTR this code looking differently
12:21 tadzik masak: oh, it used to have black-white-grey
12:21 jnthn lizmat: Almost 50% is spent in Inc.pm, looking at a --profile-compile
12:21 lizmat jnthn: well aware of that
12:21 lizmat making @*INC initialization breaks panda, however  :-(
12:21 lizmat *lzay
12:21 tadzik masak: https://github.com/masak/ufo/blob/1011bf0790195c57f8b4defffadab2fdc60d32dd/ufo#L47
12:21 lizmat *lazy
12:22 jnthn lizmat: Yeah, I plan to look at these bits soonish
12:22 tadzik this indeed has 3 shades of gray
12:22 jnthn lizmat: Want to spend this afternoon continuing with NFG work, though...
12:22 jnthn hm, I wonder why we spend so long in Str.Numeric...
12:23 lizmat sure, it's been bugging me for 9 months now, it can wait now  :-)
12:23 lizmat Str.Numeric is not a simple method
12:24 jnthn I agree, more "what calls it"
12:25 Ven Maybe quickcheck should actually run ONE test with the failing value? else it's just really spammy (the default is 100 iterations per check)
12:26 lizmat m: (-Inf..0).infinite.say  # fail
12:26 camelia rakudo-moar 2a3e1b: OUTPUT«0␤»
12:29 lizmat it's a fail because a: it should be True and b. it is not a Bool
12:29 lizmat m: (-Inf..42).infinite.say  # checking where the 0 comes from
12:29 camelia rakudo-moar 2a3e1b: OUTPUT«0␤»
12:36 dalek roast/fudge: 646f693 | usev6++ | t/03-count. (2 files):
12:36 dalek roast/fudge: Add example in-/output for '#?DOES'
12:36 dalek roast/fudge: review: https://github.com/perl6/roast/commit/646f693ee0
12:39 dolmen joined #perl6
12:42 Ven Okay, my sixcheck is now able to generate values from a sub signature to try the sub out!
12:44 Ven Seriously, the runtime introspection capabilities are amazing.
12:44 Akagi201 joined #perl6
12:48 dalek Inline-Perl5: e8589a5 | (Stefan Seifert)++ | / (3 files):
12:48 dalek Inline-Perl5: Fix passing strings containing NULL bytes from P6 to P5.
12:48 dalek Inline-Perl5: review: https://github.com/niner/Inline-Perl5/commit/e8589a5a2a
12:53 Ven .oO( I always loved pascal strings )
12:54 dalek rakudo/nom: eadbae0 | lizmat++ | src/Perl6/ (2 files):
12:54 dalek rakudo/nom: Speedup $_ S/ S! container initialization
12:54 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/eadbae09a3
12:54 lizmat this brings me back in the .19 startup range
12:55 lizmat m: my Int @x; @x[40..41] = ^10; @x.perl.say    # another fail  :-(
12:55 camelia rakudo-moar 2a3e1b: OUTPUT«Array[Int].new()␤»
12:55 lizmat m: my Int @x; @x[40,41] = ^10; @x.perl.say    # this works
12:55 camelia rakudo-moar 2a3e1b: OUTPUT«Array[Int].new(Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, Int, 0, 1)␤»
13:02 Ven Should sixcheck try to generate an invocant? or should you use `-> {$f.x(|@_, |%_)}`? Maybe that's a non-question, actually
13:17 lizmat m: my @a; say @a[0,1,2,3]; say @a[^4]; # should these give the same result, or not?
13:17 camelia rakudo-moar 2a3e1b: OUTPUT«(Any) (Any) (Any) (Any)␤␤»
13:17 lizmat if not, why?  if they should be the same, what should it be?  (Any,Any,Any.Any) or () ?
13:18 lizmat I just tried a patch that would make them both return (Any...), but that breaks splicing from an empty array
13:18 lizmat (it hangs on it)
13:20 dalek roast: 9180f5a | lizmat++ | S32-array/splice.t:
13:20 dalek roast: Make sure we never hang
13:20 dalek roast: review: https://github.com/perl6/roast/commit/9180f5a9f0
13:21 moritz m: my @a; @a[^4] = <x y z a>; say @a.perl
13:21 camelia rakudo-moar eadbae: OUTPUT«[]<>␤»
13:21 _mg_ joined #perl6
13:22 moritz lizmat: iirc the difficutlty is that people expect @a[5..*] to return the whole array except for the first four elements
13:22 lizmat moritz: the above fails because the array is empty at the time of assignment
13:22 lizmat my patch fixes that
13:23 lizmat *but*
13:23 lizmat $ 6 'my @a; say @a[^4]'
13:23 lizmat (Any) (Any) (Any) (Any)
13:23 lizmat m: my @a; say @a[^4]
13:23 camelia rakudo-moar eadbae: OUTPUT«␤»
13:23 skids joined #perl6
13:24 lizmat $ 6 'my @a; @a[^4] = <a b c d>; say @a.perl'
13:24 lizmat ["a", "b", "c", "d"]<>
13:25 lizmat m: my @a; say @a[^Inf] = <a b c d>   # this should probably work as well, no?
13:25 camelia rakudo-moar eadbae: OUTPUT«␤»
13:25 moritz m: my @a := 1, 2, 4, 8 ... *; my @b := @a[2..*]; say @b[^3]
13:26 camelia rakudo-moar eadbae: OUTPUT«(timeout)»
13:26 moritz :(
13:31 konsolebox joined #perl6
13:38 masak Perl 6: Let's See What Happens When We Combine Dozens Of Neat But Tricky Features
13:39 jnthn I thought array indexing isn't lazy...
13:39 jnthn (As in, by design)
13:41 * moritz has lost overview
13:52 dalek nqp/no-readlineint: cbea790 | hoelzro++ | / (6 files):
13:52 dalek nqp/no-readlineint: Remove references to readlineint_fh
13:52 dalek nqp/no-readlineint:
13:52 dalek nqp/no-readlineint: This corresponds to recent changes in MoarVM, in the no-moar-linenoise
13:52 dalek nqp/no-readlineint: branch.
13:52 dalek nqp/no-readlineint:
13:52 dalek nqp/no-readlineint: I haven't removed readlineintfh from the Parrot stage 0 stuff, because
13:52 dalek nqp/no-readlineint: the tests are currently failing, and I don't want to bork Parrot worse
13:52 dalek nqp/no-readlineint: than it already is.
13:52 dalek nqp/no-readlineint: review: https://github.com/perl6/nqp/commit/cbea790f91
13:52 dalek nqp/no-readlineint: 92163dd | hoelzro++ | src/HLL/Compiler.nqp:
13:52 dalek nqp/no-readlineint: Restore prompt to REPL
13:52 dalek nqp/no-readlineint: review: https://github.com/perl6/nqp/commit/92163dd68d
13:52 dalek nqp/no-readlineint: c71650f | hoelzro++ | src/HLL/Compiler.nqp:
13:52 dalek nqp/no-readlineint: Break reading of lines out into a helper method
13:52 dalek nqp/no-readlineint: review: https://github.com/perl6/nqp/commit/c71650f41b
13:52 dalek nqp/no-readlineint: f38ce8a | hoelzro++ | tools/build/MOAR_REVISION:
13:52 dalek nqp/no-readlineint: DON'T MERGE ME Bump MoarVM version
13:52 dalek nqp/no-readlineint: review: https://github.com/perl6/nqp/commit/f38ce8a825
13:52 dalek nqp/no-readlineint: c9d1eae | hoelzro++ | src/HLL/Compiler.nqp:
13:52 dalek nqp/no-readlineint: Preserve interactive eval context as an attribute of the compiler
13:52 dalek nqp/no-readlineint: review: https://github.com/perl6/nqp/commit/c9d1eae60c
13:54 raiph joined #perl6
13:55 Ven $checker.check-sub(-> Int $x, Int $y { $x + $y }, * == *.reduce(*+*)); <- This now passes with Sixcheck!
14:02 timotimo cute :)
14:07 lizmat m: my @a = ^Inf; my @b = @a[^Inf]; say @b[^10]
14:07 lizmat m: my @a = ^Inf; my @b := @a[^Inf]; say @b[^10]
14:08 camelia rakudo-moar eadbae: OUTPUT«(timeout)»
14:08 camelia rakudo-moar eadbae: OUTPUT«(timeout)»
14:09 dalek roast/fudge: 0fccf4e | FROGGS++ | / (2 files):
14:09 dalek roast/fudge: allow to fudge for specific language versions
14:09 dalek roast/fudge:
14:09 dalek roast/fudge: Examples:
14:09 dalek roast/fudge:   #?v6.0.0..v6.0.5
14:09 dalek roast/fudge:   #?v6+ * "test file approved for sixyness"
14:09 dalek roast/fudge:   #?v6.1+ "upcomming feature"
14:09 dalek roast/fudge: review: https://github.com/perl6/roast/commit/0fccf4e69d
14:10 tadzik ===CONFUSED!=== ¯\(°_o)/¯
14:10 Ven Parameter has a "named_names" method. should it be "named-names"?
14:10 moritz yes
14:11 * sjn supports tadzik's update to this error message
14:13 timotimo "gah! your compiler ate a SPARC!"
14:15 dalek rakudo/nom: 54fbdfe | lizmat++ | src/core/Range.pm:
14:15 dalek rakudo/nom: Simplify Range.BUILD
14:15 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/54fbdfe43f
14:18 dalek rakudo/tab-completion: ba05a15 | hoelzro++ | tools/build/Makefile-Moar.in:
14:18 dalek rakudo/tab-completion: Remove reference to linenoise in Moar config
14:18 dalek rakudo/tab-completion: review: https://github.com/rakudo/rakudo/commit/ba05a15579
14:18 dalek rakudo/tab-completion: 42bec6d | hoelzro++ | src/Perl6/Compiler.nqp:
14:18 dalek rakudo/tab-completion: Use new readline method from NQP for prompting
14:18 diana_olhovik joined #perl6
14:18 dalek joined #perl6
14:20 hoelzro psch: with your latest more input changes, is CTRL-d in the REPL supposed to keep trying to get input?
14:20 hoelzro or is that something I broke in my tab completion branch?
14:26 dalek roast/fudge: b97f53f | usev6++ | t/02-version. (4 files):
14:26 dalek roast/fudge: Fix tests for 'fudge'
14:26 dalek roast/fudge: review: https://github.com/perl6/roast/commit/b97f53f87c
14:29 hoelzro ok, I must've broken something
14:29 hoelzro commute&
14:38 tadzik FROGGS: https://github.com/tadzik/panda/issues/132
14:38 tadzik confirm pls :)
14:39 psch hoelzro: i've mostly removed multiline support from nom again.  i'm still trying to figure out how to approach it less cheaty
14:44 [TuxCM] .tell ptc https://github.com/travis-ci/travis-ci/issues/2978#
14:44 yoleaux [TuxCM]: I'll pass your message to ptc.
14:45 [ptc] [TuxCM]: agreed, I'd like to see fewer resources wasted as well
14:45 nine Updated S01-perl-5-integration in https://github.com/perl6/roast/pull/57. Please comment :) Some are plain bug fixes, some changes may need discussion.
14:45 [TuxCM] we met the Travis people here in Berlin. would you be willing to coordinate this with them?
14:46 [ptc] [TuxCM]: I'm sort of hoping to get moarvm/nqp/rakudo as a set of packages in Debian (at least experimental packages of some sort), and then use these to bootstrap perl6 on Travis
14:46 [ptc] [TuxCM]: re: coordination: definitely!
14:46 * [ptc] wishes he were at the perlqa hackathon....
14:47 [TuxCM] Carla Drago <carla@travis-ci.org>
14:47 [ptc] [TuxCM]: what should I say other than that which has been mentioned in the GH issue?
14:48 [TuxCM] that we had contact and that you would be willing to discuss the most usefull solution
14:48 rurban_ joined #perl6
14:48 [ptc] ok, I can do that :-)
14:48 [TuxCM] they kinda agreed that perl6 should be added
14:48 [ptc] cool!
14:49 [TuxCM] yeah
14:55 nine jnthn: why did you forbid overwriting registered module loaders in commit e40c9bc80267da19de6d80c2927aea25dd87160f?
14:56 jnthn nine: To flag up accidental conflicts, which I figured would most likely lead to confusing bugs.
14:56 molaf__ joined #perl6
14:57 jnthn nine: Also 'cus I didn't know of any use case where you'd need to replace it. Do you have one?
14:57 lizmat m: .say for Range.new(Inf,-42)
14:57 camelia rakudo-moar 54fbdf: OUTPUT«(signal XFSZ)-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-9223372036854775808␤-922337203685…»
14:58 lizmat DIHWIDT  :-)
14:59 nine jnthn: I'm thinking about having a stub module loader for Perl 5 that tries to load Inline::Perl5 which would then replace the stub.
14:59 moritz DIMWIT? :-)
14:59 nine jnthn: Would help with some tests in S01-perl-5-integration
15:01 jnthn nine: ah
15:01 [ptc] moritz: Did I mean what I thought?  ;-)
15:01 ugexe perl5 already has tools that result in perls being built from scratch every time. i think its a mistake to not consider various build options/flags/etc
15:01 ugexe re: travis
15:02 jnthn nine: Feel free to add a :force option there
15:02 ugexe i've found a lot of bugs to the ecosystem using travis like that hours after rakudo commits
15:03 [ptc] ugexe: I agree with you, however want to get stable versions into travis for module builders and other users who want stability
15:03 ugexe [ptc]: yea, but its trivial to have it build from source *if* the version you request doesnt exist
15:03 [ptc] ugexe: don't know how to specify the flexibility to get extra build options/flags etc..., how does perl5 handle it atm?
15:04 hoelzro psch: ok, thanks for the info
15:04 ugexe it uses perlbrew, just like travis-ci. if travis has a build for that specific perl/flags, it will just use that. otherwise it will build it with perlbrew
15:05 [ptc] ok, so as a simple user of perlbrew (I usually just say "install"), it's possible to specify build flags (I'm guessing)
15:05 [ptc] can rakudobrew also handle extra flags to configure the build in specific ways?
15:06 ugexe well, at a minimum, you can specify threaded vs non threaded perls
15:06 colomon joined #perl6
15:07 ugexe the other flags are tied to perlbrews install command
15:07 ugexe --clang etc
15:08 dalek roast/fudge: 8c5b533 | FROGGS++ | fudge:
15:08 dalek roast/fudge: clear $DOES flag after loop iteration
15:08 dalek roast/fudge: review: https://github.com/perl6/roast/commit/8c5b533474
15:08 [ptc] at present, one can (at the very least) say "language: perl" and the rest "just works (TM)", what would be good is "language: perl6" and then the latest release is chosen
15:09 ugexe right. or if you added other things to the matrix, you just if those options match whatever perl6 is being used. if not, build it with rakudobrew/configure.pl/whatever
15:09 ugexe you just check^
15:10 [ptc] sounds doable.  Am trying to visualise what the .travis.yml would look like.  Will paste something into the issue in a mo
15:11 ugexe building on jvm is trivial as well. the only problem is that the interpreter get invoked every time a module is compiled so it takes way too long
15:11 * FROGGS hopes that pmichaud and TimToady like the latest changes to fudge
15:11 araujo joined #perl6
15:12 ugexe if you could compile multiple modules without having to startup a perl6 interpretter every time it would be slick
15:12 [ptc] that's probably why having Rakudo* on various VMs as prebuilt options would be a good idea
15:12 [ptc] then at least one can reduce the module compile times to the not-yet-available modules
15:13 ugexe its a great idea, because a lot of people dont want to install the jvm but want their stuff to work on it
15:14 ugexe you can test your module on jvm on travis right now, but if you have 3 or 4 dependencies then it will exceed the build time limit
15:14 ugexe and thats with --notests
15:16 dalek roast: b71e0ce | usev6++ | t/README:
15:16 dalek roast: Add dir to test fudge itself
15:16 dalek roast: review: https://github.com/perl6/roast/commit/b71e0ce3ff
15:16 dalek roast: 6f83501 | FROGGS++ | t/fudge.t:
15:16 dalek roast: add test file to test fudge in-/outputs
15:16 ugexe [ptc]: https://github.com/travis-perl/helpers check this out sometime
15:16 dalek joined #perl6
15:19 sqirrel joined #perl6
15:20 [ptc] ugexe: thanks, will do
15:21 [ptc] ugexe: just posted an idea as to how the .travis.yml could look like.  Comments welcome
15:21 lizmat_ joined #perl6
15:21 ugexe i tried to test your travis build script, but ill be damned if i can get a travis enviroment actually working
15:22 [ptc] did you use vagrant to set things up?
15:22 [ptc] it wasn't overly easy...
15:22 ugexe i setup vagrant. but i couldnt get the travis run command working as intended
15:25 sjn tadzik: http://0pointer.net/blog/
15:26 ugexe [ptc]: if you include the VM as a matrix ENV then it will allow it to fire a build for each automatically
15:27 Ven joined #perl6
15:28 ugexe [ptc]: if you include the VM as a matrix ENV then it will allow it to fire a build for each automatically
15:28 ugexe oops
15:29 ugexe env: - BACKEND=moar\n - BACKEND=jvm
15:29 ugexe then you get to see each backend it succeeded or failed on in your branch result page
15:30 [ptc] wow, didn't know you could do that.  Mind you, my Travis-foo is still only at the basics stage
15:31 ugexe https://travis-ci.org/ugexe/P6TCI and https://github.com/ugexe/P6TCI/blob/master/.travis.yml
15:31 muraiki joined #perl6
15:31 ugexe you can even allow failures for certain env values so your badge doesnt go red when it fails on, say , parrot :)
15:32 [ptc] heh :-)
15:32 [ptc] ugexe: just found my build process, let me piece things back together
15:32 Ugator joined #perl6
15:34 tadzik jnthn: https://github.com/jnthn/test-mock/pull/5 pls merge :)
15:34 [ptc] ugexe: vagrant up; vagrant ssh;  (in vagrant vm) git clone https://github.com/travis-ci/travis.rb.git; git clone my-perl6-module; cd my-perl6-module; ~/travis.rb/bin/travis compile > build.sh; bash build.sh
15:34 dalek rakudo/nom: 67df04e | lizmat++ | src/core/Range.pm:
15:34 dalek rakudo/nom: Add .infinite as a BUILD-time attribute
15:34 dalek rakudo/nom:
15:34 dalek rakudo/nom: Also fixes the (-Inf..42) case (previously, this was not infinite)
15:34 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/67df04e425
15:34 [ptc] ugexe: I *think* it went like that...
15:34 [ptc] ugexe: hope it helps you get your build working
15:35 [ptc] ugexe: I never actually got it running the test suite for my test perl6 module though.  Nevertheless, perl6 worked fine and did everything I expected.
15:36 [ptc] ugexe: it took *ages* to build (mainly at the parse step, *lots* of IO going on), nevertheless, I think this was a vagrant vm problem (I'm using virtualbox) rather than a problem which will show up on travis
15:36 jnthn tadzik: done!
15:36 tadzik ossum thanks :)
15:36 leont joined #perl6
15:37 * jnthn merged a copule of similar ones for his other modules too :)
15:38 grondilu joined #perl6
15:38 FROGGS joined #perl6
15:38 dolmen joined #perl6
15:38 dalek roast: 0bdd7bd | usev6++ | t/ (4 files):
15:38 dalek roast: Add another test case for testing 'fudge'
15:38 dalek roast: review: https://github.com/perl6/roast/commit/0bdd7bdbc0
15:39 [TuxCM] joined #perl6
15:41 ugexe [ptc]: ill give it a shot in a bit. i remember following instructions where I had to install the travis CLI, then install the build module for the CLI, then the run module for the CLI
15:41 [ptc] ugexe: yeah, that's basically what I just outlined.  It's a bit of a pita but it's sufficient to debug the build script
15:42 ugexe yeah, i notice you dont do 'travis run' which is where i got hung up at
15:43 ugexe where are you putting the perl6.rb script though
15:43 lizmat m: my @a; @a[^4] = 1,2,3,4; say @a.perl
15:43 camelia rakudo-moar 54fbdf: OUTPUT«[]<>␤»
15:43 lizmat m: my @a = ^10; @a[^4] = 1,2,3,4; say @a.perl
15:43 camelia rakudo-moar 54fbdf: OUTPUT«[1, 2, 3, 4, 4, 5, 6, 7, 8, 9]<>␤»
15:44 FROGGS m: my @a; @a[0,1,2,3] = 1,2,3,4; say @a.perl
15:44 camelia rakudo-moar 54fbdf: OUTPUT«[1, 2, 3, 4]<>␤»
15:44 [ptc] ugexe: maybe travis run is something I missed out...
15:44 telex joined #perl6
15:45 [ptc] ugexe: the perl6.rb script is in /vagrant/lib/travis/build/script
15:46 [ptc] ugexe: I ran 'vagrant up' from within my travis-build branch mentioned in the pr
15:47 ugexe ah ok. your process is most likely correct, i wouldnt look too much into the travis run thing i mentioned
15:51 rjbs new postfix operator 'plusplus' which increments the number described by a string
15:51 rjbs $x = "two"; $x plusplus;
15:52 spider-mario joined #perl6
15:55 masak rjbs: it'd have to be $x\plusplus because of the postfix rule.
15:55 Ven Oh, I just learned France turned into Big Daddy. Amazing. Great.
15:55 masak m: sub postfix:<plusplus>($s) { $s++ }; my $t = "42"; say $t\plusplus
15:55 camelia rakudo-moar 67df04: OUTPUT«Cannot assign to a readonly variable or a value␤  in sub postfix:<++> at src/gen/m-CORE.setting:2305␤  in sub postfix:<plusplus> at /tmp/ZcI3wOw_VL:1␤  in block <unit> at /tmp/ZcI3wOw_VL:1␤␤»
15:56 masak m: sub postfix:<plusplus>($s is rw) { $s++ }; my $t = "42"; $t\plusplus; say $t
15:56 camelia rakudo-moar 67df04: OUTPUT«43␤»
15:56 masak m: sub postfix:<plusplus>($s is rw) { $s++ }; my $t = "42"; $t plusplus; say $t
15:56 camelia rakudo-moar 67df04: OUTPUT«5===SORRY!5=== Error while compiling /tmp/hWSvyI1IZg␤Two terms in a row␤at /tmp/hWSvyI1IZg:1␤------> 3us>($s is rw) { $s++ }; my $t = "42"; $t7⏏5 plusplus; say $t␤    expecting any of:␤        infix␤        infix stopper␤        sta…»
15:56 masak rjbs: ^^
15:57 tadzik sooooo, loading HTTP::UserAgent takes 16 seconds for me
15:57 tadzik that's precompiled
16:00 rjbs masak: ????
16:01 ugexe thats odd. HTTP::UserAgent, including IO::Socket::SSL, takes no where near that long to load for me.
16:01 chenryn joined #perl6
16:01 masak rjbs: Postfix Depression Syndrome
16:02 nbdsp joined #perl6
16:02 Ugator left #perl6
16:02 tadzik ugexe: I installed Task::Star, and now my MANIFEST is 68K
16:04 rjbs masak: Postfix often depresses me, but usually it's the other postfix.
16:04 masak heh.
16:05 moritz is there also a Qmail Depression Syndrome?
16:05 rjbs Yes, much more serious.
16:05 rjbs There's a whole book about understanding the corresponding Sendmail problem.
16:05 rjbs It's called the DS.m4
16:05 * jnthn doesn't mention Microsoft Exchange... :P
16:06 FROGGS Exchange is quite nice, from a user perspective
16:06 tadzik hmmm, how do I profile CompUnitRepo? :)
16:06 jnthn tadzik: use happens at BEGIN time, so try --profile-compile
16:06 gfldex joined #perl6
16:06 tadzik oh, perfect :)
16:08 nbdsp m: module M { sub foo{ say "foo" } }; M::foo;
16:08 camelia rakudo-moar 67df04: OUTPUT«Could not find symbol '&foo'␤  in method <anon> at src/gen/m-CORE.setting:16202␤  in any find_method_fallback at src/gen/m-Metamodel.nqp:2908␤  in any find_method at src/gen/m-Metamodel.nqp:1052␤  in block <unit> at /tmp/wULSupUzMX:1␤␤»
16:09 jnthn nbdsp: Needs to be "our sub foo ..."
16:09 nbdsp Greetings! Could someone advise please how to have two or more namespaces in a file?
16:09 nbdsp Oh.. thanks!
16:09 cschwenz left #perl6
16:11 masak at #perl6, we answer your question *before* you ask them :)
16:11 jnthn :P
16:12 eli-se joined #perl6
16:16 FROGGS m: say $_
16:16 camelia rakudo-moar 67df04: OUTPUT«(Any)␤»
16:20 lizmat .tell TimToady I think 'my @a; @a[^2] should say Any,Any, just like @a[0,1] does.  Thoughts ?
16:20 yoleaux lizmat: I'll pass your message to TimToady.
16:30 dalek nqp/sprintf: aa86255 | usev6++ | t/hll/06-sprintf.t:
16:30 dalek nqp/sprintf: Adjust tests for '%b'
16:30 dalek nqp/sprintf: review: https://github.com/perl6/nqp/commit/aa86255e75
16:32 lizmat maybe my @a; @a[^inf] should return a infinite lazy list of Any's
16:33 lizmat but then we would have to differntiate between ranges with Inf and ranges with Whatever
16:40 dalek perl6-examples: 8d705f8 | paultcochrane++ | / (2 files):
16:40 dalek perl6-examples: Build menu-tabs attr to allow setting of menu tabs on website
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/8d705f8fce
16:40 dalek perl6-examples: 1ca59a1 | paultcochrane++ | / (2 files):
16:40 dalek perl6-examples: Convert header-html into a method
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/1ca59a1c07
16:40 dalek perl6-examples: 4979048 | paultcochrane++ | lib/Pod/Htmlify.pm6:
16:40 dalek perl6-examples: Use menu-tabs to populate menu tabs in html header
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/4979048d43
16:40 dalek perl6-examples: f858493 | paultcochrane++ | t/004-website.t:
16:40 dalek perl6-examples: Check setting menu-tabs explicitly
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/f858493c1b
16:40 dalek perl6-examples: ec6972c | paultcochrane++ | / (2 files):
16:40 dalek perl6-examples: Specify menu tab link fully
16:40 dalek perl6-examples:
16:40 dalek perl6-examples: Don't assume we want the link to be somewhere under the /categories/ dir.
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/ec6972cff5
16:40 dalek perl6-examples: 66425da | paultcochrane++ | htmlify.pl:
16:40 dalek perl6-examples: Explictly configure menu tabs
16:40 dalek perl6-examples:
16:40 dalek perl6-examples: This allows the tabs to be a bit cleaner looking as well as remove some
16:40 dalek perl6-examples: inconsistency in presentation.
16:40 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/66425da148
16:42 timotimo [ptc]: do you know why so many of the examples look like this? http://examples.perl6.org/categories/games/tictactoe.html
16:42 timotimo as in: the source code twice in a row ...
16:42 timotimo also, it would probably be awesome to pygmentize the source code, like the doc.perl6.org thing does :)
16:42 timotimo shall i open tickets for that?
16:42 FROGGS $ perl6-m --optimize=off -e 'sub postfix:<^^^>($a) is looser(&infix:<+>) { $a; 77 }; say 6^^^ + 8'
16:42 FROGGS Cannot invoke this object (REPR: Null, cs = 0)
16:42 FROGGS https://rt.perl.org/Ticket/Display.html?id=116012
16:43 FROGGS bbl
16:44 timotimo why would you define the precedence of a postfix operator in relation to an infix operator?
16:44 timotimo that confuses me
16:45 timotimo but the failure mode is still not right
16:45 [ptc] timotimo: doubled up code: if there isn't any pod describing an example, the code is inserted in its place.  Then I add a stripped-down version of the code at the end.
16:45 [ptc] timotimo: you're right, I should stop doing that...
16:46 [ptc] timotimo: the pygmentize stuff is in the back of my mind.  Patches are certainly welcome ;-)
16:46 [ptc] timotimo: you can open tickets for that if you want :-)
16:47 nine What do you think? https://github.com/rakudo/rakudo/pull/409 Transparently support Inline::Perl5. This allows most of the S01-perl-5-integration spec tests to pass
16:47 nine if Inline::Perl5 is installed.
16:51 lizmat range slices issues now rakudobugged as #124316
16:51 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=124316
16:51 lizmat dinner&
16:51 PerlJam nine++ nice!
16:53 ashleydev nine: example?
16:53 PerlJam nine: I'm assuming it doesn't do the lexical "use v5;" part yet
16:53 PerlJam nine: and that's probably for the best IMHO
16:56 PerlJam nine: why https://github.com/niner/rakudo/commit/5eff25a6fe06e278a33e70b5e0d2f99e78051d9e#diff-15453ceaa1e29c1ff703ba4b89bf3425R198 instead of the more straight-forward version on line 213?
16:57 PerlJam i.e. multi sub EVAL(Cool $code, :$lang = 'perl5', PseudoStash :$context) {
17:01 dalek perl6-examples: 974e959 | paultcochrane++ | lib/Pod/ (2 files):
17:01 dalek perl6-examples: Stop adding source code when no pod in source
17:01 dalek perl6-examples:
17:01 dalek perl6-examples: This is because the source code (without pod) is being added anyway, thus it
17:01 dalek perl6-examples: would be added twice if there isn't pod in the source, which would be silly.
17:01 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/974e9599a1
17:02 japhb masak: Yes, I knew that (re: the definition of public attributes).  I was trying to talk the questioner through things a little at a time.
17:02 mohij joined #perl6
17:03 nine ashleydev: perl6 -e 'use DBI:from<Perl5>; my $dbh = DBI.connect(...);'
17:03 nine PerlJam: no lexical use v5 yet, no.
17:04 ashleydev wow
17:04 ashleydev nine++
17:07 Zoffix nine++
17:08 rurban_ joined #perl6
17:10 japhb Definitely nine++
17:12 Akagi201 joined #perl6
17:14 RabidGravy is there any reason that the parrot features that IO::Select uses can't be exposed through nqp?
17:15 _mg_ joined #perl6
17:15 leedo i was looking for select in the p6 docs the other day, mainly out of curiosity
17:22 RabidGravy yeah unfortunately the IO::Select only works for parrot backend
17:22 muraiki joined #perl6
17:23 RabidGravy a straight up NativeCall implementation wouldn't be too tricky but I couldn't work out how to got the actual FD from an IO::Handle
17:23 KCL_ joined #perl6
17:27 timotimo RabidGravy: IO::Socket::SSL has to get the actual FD, so there's something somewhere that can do it
17:28 RabidGravy cool, will look
17:32 timotimo i think we're also in need of a module that could set low-level operating-system provided special-use flags on sockets
17:34 Aurelie joined #perl6
17:40 ugexe should @array[^0] return the same value as @array[0..0]?
17:41 grondilu no
17:41 grondilu ^0 is Nil, isn't it?
17:41 ugexe yeah
17:41 masak m: say (^0).WHAT
17:41 camelia rakudo-moar 67df04: OUTPUT«(Range)␤»
17:42 masak no, it's a Range.
17:42 ugexe well, i mean i get a no value from the array
17:42 grondilu m: say ^0,
17:42 camelia rakudo-moar 67df04: OUTPUT«0..^0␤»
17:42 grondilu m: say Nil,^0
17:42 camelia rakudo-moar 67df04: OUTPUT«Nil0..^0␤»
17:42 masak anyway, agree that @array[^0] should be *empty* while @array[0..0] should contain one element (@array[0])
17:43 ugexe so if you want to use a variable as a range, you should probably use @array[0..$index], not @array[^$index] i presume?
17:43 masak ugexe: depends what you want.
17:43 masak ugexe: I do ^$size more often than I do 0..$index
17:57 ugexe m: my @a = 300,301; my $max = 0; my $code = 300; given $code { when /^3/ { when all(@a[^$max]) { say "xx" } } };
17:57 camelia rakudo-moar 67df04: OUTPUT«xx␤»
17:57 ugexe thats what was tripping me up
17:59 ugexe at one time months ago that would not say "xx"
18:12 agentzh joined #perl6
18:12 Akagi201 joined #perl6
18:22 moritz m: say :16('D835')
18:22 camelia rakudo-moar 67df04: OUTPUT«55349␤»
18:23 dalek json: 215b406 | (Anthony Parsons)++ | t/05-utf16.t:
18:23 dalek json: Add tests for utf16 surrogate pairs
18:23 dalek json: review: https://github.com/moritz/json/commit/215b40673c
18:23 dalek json: 60b3d80 | (Anthony Parsons)++ | lib/JSON/Tiny (3 files):
18:23 dalek json: Implement surrogate pair handling using Bufs
18:23 dalek json:
18:23 dalek json: Tested on Rakudo 2013.08-3-g7cb364b (Parrot & JVM)
18:23 dalek json: review: https://github.com/moritz/json/commit/60b3d80a0d
18:23 dalek json: 9a0d31f | (Anthony Parsons)++ | README:
18:23 dalek json: Strike surrogates off todo list
18:23 dalek json: review: https://github.com/moritz/json/commit/9a0d31fc96
18:23 dalek json: 7278e40 | moritz++ | / (5 files):
18:23 dalek json: Merge branch 'master' of https://github.com/flussence/json
18:23 dalek json:
18:23 dalek json: Conflicts:
18:23 dalek json: lib/JSON/Tiny/Actions.pm
18:23 dalek json: review: https://github.com/moritz/json/commit/7278e4053d
18:24 Shozan joined #perl6
18:27 Ugator joined #perl6
18:27 timotimo and now someone could implement the surrogate pair handling in JSON::Fast ...
18:33 cognominal joined #perl6
18:33 SHODAN joined #perl6
18:34 * DrForr scratches his head at 'Calling rl_get_screen_size(Pointer, Pointer) will never work with declared signature (Pointer, Pointer)'.
18:37 ugexe m: my IO::Path $path = "/home".IO; say $path.resolve; # maybe related to this?
18:37 camelia rakudo-moar 67df04: OUTPUT«Type check failed in assignment to '$path'; expected 'IO::Path' but got 'IO::Path'␤  in block <unit> at /tmp/3U7PZA6bqe:1␤␤»
18:37 ugexe its actually returning a native str
18:38 DrForr Possibly. It occurs consistently where I'm declaring a Pointer[Int] function signature.
18:38 yogan joined #perl6
18:38 TimToady perhaps parameterized types need to count their parameters as part of the longname
18:38 yoleaux 16:20Z <lizmat> TimToady: I think 'my @a; @a[^2] should say Any,Any, just like @a[0,1] does.  Thoughts ?
18:39 DrForr Nod, the fact that the signature is 'Pointer[Int]' but displayed as just 'Pointer' could lead to further confusion.
18:40 DrForr Should I file a bug?
18:40 zakharyas joined #perl6
18:40 RabidGravy ugexe, I thought that got fixed?
18:41 DrForr I just rebuilt rakudo-moar 5 minutes ago.
18:41 psch RabidGravy: no, it's PR 407
18:41 psch IO.resolve that is
18:41 nbdsp m: class B{ submethod foo{ say "B::foo" } }; class D is B { method meth { self.foo } }; D.new.meth;
18:41 camelia rakudo-moar 67df04: OUTPUT«Method 'foo' not found for invocant of class 'D'␤  in method meth at /tmp/uaQprMw41w:1␤  in block <unit> at /tmp/uaQprMw41w:1␤␤»
18:41 RabidGravy yeah, oh didn't get merged :)
18:42 nbdsp Greetings! Could someone advise please what is the syntax of a call of base class submethod?
18:43 ugexe i think its the same as you could call a subroutine
18:43 ugexe s/could/would/
18:44 psch i guess you need to look through the MRO and check the submethod table for each entry
18:44 TimToady because submethods are infrastructural, we don't generally have submethods call each other, but have a normal method that calls all the submethods
18:44 psch 'cause the class itself doesn't know the submethod, because those aren't inherited, iirc
18:45 * psch might be wrong there, never looked closely at what submethods are and do
18:46 TimToady why do you need submethods rather than ordinary methods?
18:46 ugexe RabidGravy: as mentioned its fixed in a pr, but the underlying error message problem isnt fixed
18:46 TimToady or, were youusing "submethod" just to mean "the method I want to call"?
18:47 ugexe well, underlying isnt the right word
18:47 nbdsp I want to overload a field accessor in a base class.
18:47 TimToady then why not just overlaod it virtually?
18:48 TimToady that's why we distinguish $!foo from $.foo, after all
18:48 b2gills m: use v7; # shouldn't this be an error?
18:48 camelia rakudo-moar 67df04: ( no output )
18:48 ugexe i.e. it didn't get a IO::Path, it was getting a str. the pr makes it actually return an IO::Path, but why it originally reported it was returning an IO::Path is a different beast
18:48 TimToady b2gills: probably a no-op currently
18:49 nbdsp I want to call it from a constructor, where virtual calls don't work yet.
18:49 TimToady they do if you say self.foo rather than $.foo
18:49 b2gills v5 and v6 are optional matches instead of parallel matches in grammar
18:50 TimToady we just put in the restriction on $.foo to keep people from sloppy thinking
18:50 TimToady but you can still get past it
18:51 nbdsp Oh, with self.foo it works. Thanks!
18:51 TimToady the other point is that if your constructor is trying to do infrastructural things, those things probably belong in BUILD anyway
18:52 spider-mario joined #perl6
18:54 nbdsp Well, I referenced to BUILD as 'constructor' here, since 'new' seems to be needed only for positional arguments.
18:54 TimToady we tend to reserve "constructor" for 'new' and things like 'new, and use 'initializer' for things like BUILD
18:56 TimToady so 'constructor' for the outward-facing API, and 'initializer' for the inward facing, as it were
18:56 vendethiel o/
18:59 nbdsp Thanks. Will be using these terms correctly.
18:59 TimToady so basically the programmer calls the constructor at the class boundary, the constructor calls bless to convey its "blessing" upon the arguments, bless calls some number of initializers as it deems appropriate, and the initializers call into the reprs to actually initialize the representations, which even the class doesn't need to care about
18:59 TimToady (representational polymorphism being the technical term there)
19:00 TimToady so Perl 6 doesn't care in the class definition (much) whether the represenation is P6Opaque, P5Hash, or CStruct
19:00 TimToady *sentation
19:00 masak orthogonal reprs are a really good idea.
19:01 TimToady "given a sufficiently smart optimizer"
19:01 masak which we need anyway :P
19:02 TimToady eye
19:04 DrForr Bug #124317 filed, incidentally.
19:04 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=124317
19:07 masak DrForr++
19:07 masak DrForr: is the 'is native' part necessary to reproduce the bug?
19:08 DrForr Hadn't checked, but I would assume not.
19:09 masak it'd be significant to know either way.
19:09 masak slightly more so if it is, though :)
19:10 DrForr Checking now.
19:10 eli-se joined #perl6
19:12 DrForr Looks like it is required, I just created a 'role Pointer[::Type] { }' so I didn't have to change the rest of the code, no error.
19:14 masak interrrresting.
19:14 * masak purrs
19:16 DrForr I also haven't checked to see if two 'sub's will do the same thing, I'm wondering if there's an implicit 'self' causing the problem but don't know the core.
19:21 TimToady m: multi sub foo(:bar(42)) { say "HERE" }; foo(:bar(42))
19:21 camelia rakudo-moar 67df04: OUTPUT«5===SORRY!5=== Error while compiling /tmp/gcPH3dhotM␤Malformed parameter␤at /tmp/gcPH3dhotM:1␤------> 3multi sub foo(:bar(7⏏42)) { say "HERE" }; foo(:bar(42))␤    expecting any of:␤        formal parameter␤»
19:21 TimToady m: multi sub foo(:bar([$a,$b])) { say "HERE $a,$b" }; foo(:bar([1,2]))
19:21 camelia rakudo-moar 67df04: OUTPUT«HERE 1,2␤»
19:22 TimToady m: multi sub foo(:bar(@foo [$a,$b])) { say "HERE $a,$b" }; foo(:bar([1,2]))
19:22 camelia rakudo-moar 67df04: OUTPUT«5===SORRY!5=== Error while compiling /tmp/YFkgf9pK1F␤Unable to parse named parameter; couldn't find right parenthesis␤at /tmp/YFkgf9pK1F:1␤------> 3multi sub foo(:bar(@foo7⏏5 [$a,$b])) { say "HERE $a,$b" }; foo(:ba␤»
19:22 TimToady we seem to be a bit inconsistent about whether the inside of :bar() can be treated as a subsig
19:22 TimToady I wonder if we can relax that somewhat...
19:23 robinsmidsrod joined #perl6
19:25 TimToady m: multi sub foo(:bar(:(@foo [$a,$b]))) { say "HERE $a,$b" }; foo(:bar([1,2]))
19:25 camelia rakudo-moar 67df04: OUTPUT«Cannot call foo(Array); none of these signatures match:␤    (Any :bar(:($)) (@foo (Any $a, Any $b)))␤  in sub foo at /tmp/oGW6T4onoP:1␤  in block <unit> at /tmp/oGW6T4onoP:1␤␤»
19:28 DrForr masak: Also it's probably specific to the calling args, I just wrote a paramtrized return value and it didn't throw an error.
19:31 robinsmidsrod joined #perl6
19:33 TimToady m: say :(42) ::= 42;
19:33 camelia rakudo-moar 67df04: OUTPUT«Too few positionals passed; expected 1 argument but got 0␤  in block <unit> at /tmp/buVskeoy2Q:1␤␤»
19:33 TimToady m: say :(42) ::= \(42);
19:33 camelia rakudo-moar 67df04: OUTPUT«(Int $ where { ... })␤»
19:33 masak DrForr: then maybe -- hypothesizing here -- it's something to do with how parameters are appropriated by the 'is native' trait.
19:34 TimToady m: multi sub foo(:bar(:(42))) { say "HERE" }; foo(:bar(42))
19:34 camelia rakudo-moar 67df04: OUTPUT«Cannot call foo(Int); none of these signatures match:␤    (Any :bar(:($)) (Int $ where { ... }))␤  in sub foo at /tmp/92YTZanGHt:1␤  in block <unit> at /tmp/92YTZanGHt:1␤␤»
19:34 [TuxCM] joined #perl6
19:34 TimToady erm?
19:34 TimToady m: multi sub foo(:bar(:(42))) { say "HERE" }; foo(:bar(\(42)))
19:34 camelia rakudo-moar 67df04: OUTPUT«HERE␤»
19:34 TimToady so close...
19:36 TimToady jnthn: seems like we just need a touch more cowbell^Wautocapture
19:38 DrForr masak: It's more random than that. I have one that returns 'CArray[Str]' cleanly, and another which returns the same but throws the error. The clean one has a single argument, the bad one has two arguments.
19:40 masak DrForr: the plot thickens. I don't immediately have a rationale for that behavior.
19:40 DrForr Neither do I offhand.
19:40 masak btw, caller:arguments :: callee:parameters
19:40 DrForr Let me push the file so you can see the variants...
19:42 DrForr https://github.com/drforr/perl6-readline/blob/master/lib/ReadLine.pm6 - Just look for the XXX markers.
19:43 masak yeah, doesn't tell me much. too many details.
19:43 masak too many moving parts.
19:43 DrForr Yep, I understand.
19:43 Akagi201 joined #perl6
19:44 DrForr The nested classes don't seem to interact with the problem, if it helps.
19:45 masak I/you/we need to identify the smallest set of circumstances that causes the error.
19:46 yqt joined #perl6
19:46 masak by removing all the circumstances that don't.
19:46 masak I find the only reliable way of understanding these things is to remove all the distractions from the problem.
19:47 * TimToady removes himself to eat lunch
19:47 DrForr Oh, I completel understand. I was just presenting a single instance as part of the bug.
19:49 masak can you remove the NativeCall dependency, for example? that would be extremely useful.
19:50 lizmat joined #perl6
19:50 DrForr Not without replicating the Pointer role, apparently. I don't yet know enough of the language to be able to create a useful mimic.
19:51 DrForr Or at least when I created an empty Pointer[::Type] role it wasn't enough to recreate the problem.
19:53 dalek rakudo/nom: 5eff25a | (Stefan Seifert)++ | src/ (3 files):
19:53 dalek rakudo/nom: Transparently support Inline::Perl5
19:53 dalek rakudo/nom:
19:53 dalek rakudo/nom: This allows most of the S01-perl-5-integration spec tests to pass
19:53 dalek rakudo/nom: if Inline::Perl5 is installed.
19:53 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5eff25a6fe
19:53 dalek rakudo/nom: dd77b78 | lizmat++ | src/ (3 files):
19:53 dalek rakudo/nom: Merge pull request #409 from niner/nom
19:53 dalek rakudo/nom:
19:53 dalek rakudo/nom: Transparently support Inline::Perl5
19:53 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/dd77b783c1
19:54 masak DrForr: right. I think that's our biggest clue so far.
19:54 gtodd joined #perl6
19:54 dalek Inline-Perl5: 189699f | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
19:54 dalek Inline-Perl5: Support transparent use of Inline::Perl5 by Rakudo
19:54 dalek Inline-Perl5: review: https://github.com/niner/Inline-Perl5/commit/189699fe06
19:54 masak DrForr: what about copy-pasting the Pointer role out of it's NativeCall (pun intended) environment?
19:54 masak (and then getting rid of the NativeCall dependency)
19:55 gtodd Jonathan's blog makes it possible to use rare unicode characters and mean it  ????
19:55 DrForr That's what I was thinking, let me give it a try.
19:55 gtodd ????++
19:57 dalek roast: c6135c2 | (Stefan Seifert)++ | S01-perl-5-integration/ (3 files):
19:57 dalek roast: Replace nonsensical VAR usage by proper itemization
19:57 dalek roast:
19:57 dalek roast: According to S12, VAR on a non-scalar is a no-op. The intention in these
19:57 dalek roast: tests seems to be to pass arrays and hashes to Perl 5 code so they arrive
19:58 dalek joined #perl6
20:00 jnthn TimToady: I *think* :bar(:(42)) is parsing as a named param with two possible names: bar and the empty string... I dunno exactly what parses the 42... :)
20:03 DrForr masak: Trimming things down.
20:04 espadrine joined #perl6
20:04 masak DrForr++
20:04 mr_ron joined #perl6
20:05 leont joined #perl6
20:06 mr_ron m: sub f(Int $x){ return $x + 42 }; CATCH {default{ say 'caught exception: ', $_; $_.resume} }; f(1/2); say 'after catch';
20:06 camelia rakudo-moar 67df04: OUTPUT«5===SORRY!5=== Error while compiling /tmp/ECgM5IqIX_␤Whitespace required after keyword 'default'␤at /tmp/ECgM5IqIX_:1␤------> 3nt $x){ return $x + 42 }; CATCH {default7⏏5{ say 'caught exception: ', $_; $_.resum␤»
20:06 mr_ron m: sub f(Int $x){ return $x + 42 }; CATCH {default { say 'caught exception: ', $_; $_.resume} }; f(1/2); say 'after catch';
20:06 camelia rakudo-moar 67df04: OUTPUT«caught exception: Type check failed in binding $x; expected 'Int' but got 'Rat'␤  in sub f at /tmp/zDmS8GdBGC:1␤  in block <unit> at /tmp/zDmS8GdBGC:1␤␤after catch␤»
20:06 mr_ron OK so far but now look
20:07 mr_ron m: sub f(Int $x){ return $x + 42 }; CATCH {default { say 'caught exception: ', $_; $_.resume} }; f(0.5); say 'after catch';
20:07 camelia rakudo-moar 67df04: OUTPUT«5===SORRY!5=== Error while compiling /tmp/5plRGrqPpK␤Calling f(Rat) will never work with declared signature (Int $x)␤at /tmp/5plRGrqPpK:1␤------> 3'caught exception: ', $_; $_.resume} }; 7⏏5f(0.5); say 'after catch';␤»
20:07 mr_ron should the two cases behave so differently?
20:08 geekosaur no constant folding yet? so the former is caught at runtime but the latter at compile time?
20:10 jnthn Compilers are free to catch code that they can prove can never work at runtime at compile time.
20:10 jnthn However, they're not mandated to.
20:11 jnthn Te 1/2 case will likely end up being spotted at compile time at some point.
20:13 TimToady so tests that assume it's one way or the other are bogus
20:13 TimToady I suspect we have a lot of tests in that category
20:14 gtodd masak:  any "masakism workshop" solutions on http://examples.perl6.org/ ?
20:14 jnthn *nod*
20:14 jnthn I fix 'em when I spot 'em.
20:16 gtodd not sure everything still works but I remember being quite impressed by  https://github.com/masak/workshop  ...
20:18 dalek roast: 3c233f3 | lizmat++ | integration/weird-errors.t:
20:18 dalek roast: Mention RT #123686 & RT #124318 together
20:18 dalek roast: review: https://github.com/perl6/roast/commit/3c233f3f91
20:18 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=123686
20:20 TimToady we probably have to glare at every test someday for over/underspecificity, but the one's containing "will never" or dies_ok without an EVAL, or throws_like are all deeply suspicious from that standpoint
20:20 TimToady *ones
20:20 jnthn TimToady: is "foo".codes desired as an O(1) or an O(n) operation?
20:21 lizmat TimToady: so you're saying a "dies_ok" is better than a specific "throws_like" ?
20:21 [ptc] gtodd: not aware of any masakism workshop solutions on examples.perl6.org.
20:21 [ptc] gtodd: feel free to submit some new ones :-)  Patches welcome!
20:21 masak gtodd: no, but that's a great idea! remind me again at a time when I'm not going to bed. ;)
20:21 masak 'night, #perl6
20:21 [ptc] 'night masak!
20:21 jnthn o/ masak
20:22 DrForr Night, I'll post a new bug when I have it narrwed down.
20:22 jnthn lizmat: No, thrwos_like has an overload that can EVAL too
20:22 gtodd OK :-)  I was just looking through and remembered I even edited the links in the SVG "map"
20:22 gtodd ... using perl5 ;-)
20:23 [ptc] as suggested by [Coke]++, I've been looking into the opscode docs in nqp.
20:23 [ptc] is there any obvious way to work out what arguments an opcode takes?
20:23 TimToady throws_like is okay iff we say that a compile-time caught "will never work" returns the same error code the run-time failure does, and we don't test parts of the message that change "didn't work" to "will never work"
20:24 [ptc] also, what is the xor opcode for?  I mean, there are bitwise versions of xor, but there is an xor which seems not to do much (and I don't think has any tests)
20:24 jnthn Testing the message always feels smelly to me anyway.
20:24 jnthn We have typed exceptions so you don't have to test the message...
20:24 TimToady from an I18n pov if nothing else
20:24 [ptc] and on another note, there are lots of failures for parrot opcodes, what to do with the parrot stuff?  Should it go from nqp?
20:25 lizmat well, X::AdHoc being the exception to that rule, I guess
20:25 jnthn I guess part of the issue is a lot of the RTs we have read "I got a crappy erorr for X"
20:25 jnthn lizmat: Yeah, though in general we're trying to have less of those... :)
20:25 jnthn Whenever I need to write a test to close an RT about an error, I'm adding a typed exception and testing against that.
20:26 lizmat I guess going through roast and changing all dies_ok to throws_like (even when it's X::AdHoc) would give us a good statistic
20:26 TimToady dies_ok is okay as long as it's on an EVAL, to hide compile-time vs run-time distinction
20:27 TimToady but it does tend to be underspecific, compared to throws_like
20:27 lizmat but how can you be sure it died for the right reason ???
20:27 mr_ron I feel a little underqualified to ask further, but it sounds like Perl 6 code that is running with exception handling might break because a smarter update of the compiler decides it can't work..
20:27 lizmat a few months ago I changed about 100 dies_ok's to throws_like and found about 5 false positives
20:28 mr_ron s/compiler/interpreter or whatever/
20:28 lizmat aka, dying for the wrong reason, but passing the test because it did die
20:28 TimToady mr_ron: that's probably about the time the compiler should be paying attention to which version of Perl 6 it's emulating
20:30 TimToady one could argue for an automatic deprecation warning at that point: this code will not compile when you update your current language to v6.Triceratops
20:31 jnthn Maybe. We probably need to get a better feel for how often these things will happen in the real world.
20:31 cschwenz joined #perl6
20:32 TimToady .oO("Warning: emulation support for v6.Dinosaur will go away in v6.Mammal")
20:34 eli-se I wrote APL code today. It was a refreshing experience.
20:34 yoleaux 11:58Z <Ven> eli-se: ruby symbols are GC'd
20:34 eli-se vendethiel: since what version?
20:34 vendethiel 2.2
20:34 vendethiel (IIRC)
20:34 TimToady eli-se: well of course, it's the reading that ain't so exciting
20:34 eli-se vendethiel: fascinating
20:34 eli-se I bet yoleaux runs on an ancient Ruby version!
20:35 vendethiel no idea :-)
20:39 colomon joined #perl6
20:40 grondilu (Dinosaurs are not deprecated.  They're still flying around nowadays)
20:41 dalek perl6-examples: ece01d9 | (Steve Mynott)++ | categories/cookbook/17sockets/17-0 (2 files):
20:41 dalek perl6-examples: start of 17sockets
20:41 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/ece01d98d7
20:42 eli-se One of my pets is a dragon.
20:42 FROGGS joined #perl6
20:44 Rounin joined #perl6
20:44 colomon joined #perl6
20:47 vendethiel eli-se: (LRIO doesn't count as one)
20:48 [ptc] did I ask a silly question about nqp before, or was it just the wrong time to ask?
20:50 DrForr What's the bot syntax to leave messages
20:50 DrForr s/$/?
20:50 jnthn [ptc]: Ah, I see them. What an op takes - guess the JVM backend's Compiler.nqp is the easier one to parse them out of...
20:50 lizmat [ptc]: if this is about parrot, I understand that nqp will continue to support parrot, no?
20:50 eli-se .tell yoleaux .botsnack
20:50 yoleaux eli-se: Thanks for the message.
20:50 synbot6 om nom nom
20:50 jnthn [ptc]: xor is the Perl 6 ^^ operator
20:50 lizmat I need a .botsnack as well
20:50 synbot6 om nom nom
20:51 [ptc] .tell lizmat .botsnack
20:51 yoleaux [ptc]: I'll pass your message to lizmat.
20:51 synbot6 om nom nom
20:51 eli-se Can synbot6 also .tell things?
20:51 lizmat I think synbot6 is not very picky about its .botsnack
20:51 yoleaux 20:51Z <[ptc]> lizmat: .botsnack
20:51 synbot6 om nom nom
20:51 synbot6 om nom nom
20:51 [ptc] jnthn: ok, thanks, I'll need to look up the ^^ operator
20:52 jnthn [ptc]: Should be spectests for it also.
20:52 DrForr .tell masak #124321 - The minimal criminal appears to be monkeypatching of Pointer.parameterize.
20:52 yoleaux DrForr: I'll pass your message to masak.
20:52 synbot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=124321
20:52 [ptc] jnthn: one can use the repl in nqp much like in rakudo, right?
20:52 * lizmat goes to bed
20:52 [ptc] jnthn: ah, spectests I missed.  Right, cool
20:52 jnthn [ptc]: Pretty much, though it's less tested/polished I guess :)
20:52 * [ptc] starts taking notes
20:53 jnthn Some things implemented in the NQP repo probably only get their real testing thorugh Rakudo's spectests.
20:53 mr_ron thanks to all for clarification ...
20:53 jnthn Then, MoarVM doesn't even have a test suite, so you're forced to test it using the NQP and Rakudo test suites. :)
20:53 [ptc] jnthn: yes, it's interesting that moarvm is tested via nqp...
20:54 [ptc] ah, bet me to it
20:54 jnthn Yes, it's a deliberate choice to make sure those working on MoarVM test it from the perspective of its customers.
20:55 [ptc] jnthn: what to do with parrot stuff in the nqp repo though?  I mean, some of the opcodes won't be implemented which are currently documented, right?
20:55 jnthn [ptc]: Well, the Parrot stuff stays there; I'm guessing the question is more like "we get ops documentation test failures 'cus of the missing ops"?
20:56 [ptc] jnthn: that's an interesting perspective wrt testing moar.  I stumbled across that while trying to test changes I'd made to moarvm after a coverity scan check
20:56 [ptc] jnthn: yes, there are ops docs test failures due to missing ops...
20:56 jnthn [ptc]: Note that you don't have to rebuild NQP nor Rakudo after doing a "make install" of Moar
20:57 mr_ron left #perl6
20:58 jnthn [ptc]: Even my dual-core laptop can manage the NQP test suite of 4,000 or so tests in around 8s.
20:58 jnthn So it's possible to get a quick sanity check.
20:58 [ptc] e.g. not ok 931 - documented op 'cancel' exists in parrot
20:58 jnthn Yeah. Maybe the best way with that is to not treat Parrot's failure to implement an op as a test failure?
20:59 jnthn Or mark them skip/todo
20:59 [ptc] jnthn: thanks for your help.  Now I've got enough to work on to get the number of missing ops down.  :-)
20:59 jnthn :-)
21:00 jnthn [ptc]: btw, if yo're doing NQP level documentation work, it may be good to be aware of https://github.com/edumentab/rakudo-and-nqp-internals-course/ if you ain't already.
21:03 * [ptc] makes more notes
21:04 dalek perl6-examples: e0eda16 | (Steve Mynott)++ | categories/cookbook/17sockets/17-0 (2 files):
21:04 dalek perl6-examples: more 6ish
21:04 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/e0eda16fd9
21:06 [ptc] ha!  Permanent head Damage!
21:06 [ptc] ... piled higher and deeper  ;-)
21:08 jnthn :)
21:08 jnthn Sleep time...'night
21:10 [ptc] gn8
21:20 dalek doc: 95a354b | (Steve Mynott)++ | lib/Language/syntax.pod:
21:20 dalek doc: typo
21:20 dalek doc: review: https://github.com/perl6/doc/commit/95a354be4b
21:25 nine There are spectests that pass when run individually via prove -e 'perl6' but fail with Dubious, test returned 255 (wstat 65280, 0xff00) Failed 6/6 subtests when run through make spectest.
21:25 nine How can I debug this?
21:28 tony-o are they compiled?
21:28 tony-o nine: ^
21:29 nine How can I find that out?
21:29 tony-o you can see if there is a blib folder or .moarvm files
21:30 tony-o (the blib folder would have .moarvm files in it ^)
21:30 telex joined #perl6
21:30 nine Doesn't seems like
21:32 Akagi201 joined #perl6
21:33 aborazmeh joined #perl6
21:33 aborazmeh joined #perl6
21:47 raiph joined #perl6
21:53 tony-o you could try make --debug=v
21:54 tony-o not sure what will come of it, though
21:54 Vlavv_ joined #perl6
21:57 tinyblak joined #perl6
22:03 dalek nqp: bebba4b | paultcochrane++ | t/docs/opcodes.t:
22:03 dalek nqp: Skip tests for documented ops in parrot
22:03 dalek nqp:
22:03 dalek nqp: Not all ops are as yet implemented in parrot and checking for documented but
22:03 dalek nqp: not implemented ops is currently distracting for this vm.
22:03 dalek nqp: review: https://github.com/perl6/nqp/commit/bebba4be48
22:19 [TuxCM] joined #perl6
22:23 kaare_ joined #perl6
22:37 [particle] joined #perl6
23:01 skids joined #perl6
23:02 nbdsp joined #perl6
23:03 nbdsp Greetings! I'm trying to call MySQL natively and don't know what type should be used for fetching binary columns. Currently have the following stub: sub mysql_fetch_row( OpaquePointer $result_set ) returns CArray[Str] is native('libmysqlclient') { * } . But it fails on binary fields with an error about "Malformed UTF-8". And return type CArray[Buf] is not supported.
23:11 Woodi joined #perl6
23:21 Akagi201 joined #perl6
23:26 skids nbdsp: maybe see if CArray[CPointer] or something like that is supported, then nativecast?  How does mysql tell you the length of the binary fields anyway?
23:28 Woodi joined #perl6
23:30 nbdsp Field lengths are fetched with mysql_fetch_lengths. But how to construct a Buf from CPointer, given a length?
23:33 cschwenz left #perl6
23:34 dalek rakudo/tab-completion: 8fa167c | hoelzro++ | src/Perl6/Compiler.nqp:
23:34 dalek rakudo/tab-completion: Return null string (instead of undefined) if linenoise is done
23:34 dalek rakudo/tab-completion: review: https://github.com/rakudo/rakudo/commit/8fa167c039
23:38 timotimo that's a tough question
23:38 timotimo i don't think we have something like that yet; except you can nativecall into memcpy to copy the contents of a Pointered thing into a Buf maybe?
23:40 nbdsp Also there is no way to create a List or Buf from CArray if length is known?
23:42 timotimo i don't think so :(
23:45 nbdsp Strange, strings are not native C type and CArray[Str] works. Maybe there is a way to convert Str to Buf with something other than 'encode('utf8')'?
23:50 timotimo well, you have an "is encoded" trait from NativeCall

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo