»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend! | feather will shut down permanently on 2015-03-31
Set by jnthn on 28 February 2015.
ash_gti Whats the perl6 alternative to `<cmd>` 00:09
00:13 coffee` left
ash_gti ah, I found it, shell and run 00:14
00:17 aborazmeh joined, aborazmeh left, aborazmeh joined 00:19 kjs_ left, kaare__ left 00:26 aborazmeh left 00:29 kaare__ joined 00:30 njmurphy left 00:41 tinyblak left 00:56 Hor|zon joined 01:00 Hor|zon left 01:02 jnthn_ joined
dalek kudo/nom: 61c59db | (Geoffrey Broadwell)++ | src/core/IO/Path.pm:
Implement IO::Path.resolve on r-m/POSIX

ONLY expected correct on POSIX filesystems, but committing now because
  "implemented on r-m/POSIX" is better than purely NYI. Other backends
need only support nqp::readlink to get the POSIX support, but someone else will need to do the non-POSIX filesystem work.
01:03 jnthn_ left
kudo-star-daily: 421b28d | coke++ | log/ (9 files):
today (automated commit)
rl6-roast-data: 624dda9 | coke++ | / (9 files):
today (automated commit)
01:09 aborazmeh joined, aborazmeh left, aborazmeh joined 01:18 aborazmeh left 01:21 aborazmeh joined, aborazmeh left, aborazmeh joined
ash_gti does `qx/foobar/` set any variable like $? to indicate the exit status of the subprocess? 01:22
psch ash_gti: &shell gives you a Proc::Status
ash_gti: qx// only cares about stdout 01:23
ash_gti can you also get the output with &shell?
psch doc.perl6.org/type/Proc::Status
m: Proc::Status.^methods.say
camelia rakudo-moar 61c59d: OUTPUT«status Numeric Bool <anon> <anon> <anon>␤»
01:24 cognominal left
psch m: say Proc::Status.^can('out') 01:25
camelia rakudo-moar 61c59d: OUTPUT«␤»
psch ah, no, i'm remembering Test::<&is_run> i think... 01:26
01:27 telex left
ash_gti Proc::Async seems like it would work for both reading from stdout and finding the exit status 01:27
$? is pretty easy though, oh well
01:28 telex joined
psch on a different note, i have a «public String run(String code)» in EvalServer that works 01:29
unfortunately it needs a ~2600 characters long CLASSPATH
because our .jar loading is patently weird™ 01:30
though for some reason i get an «unitialized value of type Any in string context» in ModuleLoader.nqp, from the looks of it in a nqp::loadbytecode call..? 01:33
01:46 laouji joined 02:04 beastd left 02:14 colomon left, colomon joined
colomon don’t suppose we have rakudo to C++ NativeCall working yet? processing command line args is a pain in C++ 02:16
ash_gti that would be nice 02:20
psch the tests in rakudo/cpp look rather minimal at present, but i don't know what there really is on C++ feature that's needed to make NativeCall neat for it 02:22
ash_gti colomon: getopt_long ?
colomon looking at it now… 02:24
02:25 aborazmeh left 02:26 bjz left
ash_gti for me its man 3 getopt_long 02:26
psch & 02:28
02:29 bjz joined 02:32 raiph joined
ash_gti can you have a named param with a default value? 02:40
02:40 jack_rabbit joined 02:41 colomon left 02:43 colomon joined 02:45 Hor|zon joined 02:46 ilbot3 left 02:47 jack_rabbit left 02:48 ilbot3 joined 02:49 aborazmeh joined, aborazmeh left, aborazmeh joined, Hor|zon left 02:55 ssutch joined 03:07 jack_rabbit joined
TimToady .tell lizmat (key => 0).Bag must remove key or it violates the bag's contract; the whole point of a Bag with 0 items in it is that that is no different from an empty Bag 03:18
yoleaux TimToady: I'll pass your message to lizmat.
TimToady .tell lizmat Throwing info away is not our lowest ideal, or however you say that... 03:19
yoleaux TimToady: I'll pass your message to lizmat.
TimToady ash_gti: are you asking about getopt_long or about Perl 6? In P6, sure, just add "= stuff()" 03:22
ash_gti no, I metioned getopt_long for @colomon
colomon TimToady: I was lamenting not having sub MAIN in C++ 03:23
ash_gti I was putting the ‘= stuff’ before I closed the ), thats all, sub MAIN(:t(:$theme) = 'atom-light-syntax’) vs sub MAIN(:t(:$theme = 'atom-light-syntax’))
Mouq m: sub (:t(:th)) {} 03:25
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0AEXZTScqb␤Malformed parameter␤at /tmp/0AEXZTScqb:1␤------> 3sub (:t(:7⏏5th)) {}␤ expecting any of:␤ named parameter␤ formal parameter␤»
Mouq m: sub (:t(:$th)) {} 03:26
camelia ( no output )
Mouq m: sub (:t( :$th )) {}
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0yAAc9tKQn␤Unable to parse named parameter; couldnt find right parenthesis␤at /tmp/0yAAc9tKQn:1␤------> 3sub (:t( :$th7⏏5 )) {}␤ expecting any of:␤ shape declaration␤»
Mouq std: sub (:t( :$th )) {}
camelia std 28329a7: OUTPUT«ok 00:00 138m␤»
Mouq rakudobugs
03:27 cognominal joined 03:35 noganex_ joined
Mouq I'm closing RT #123939, moritz++ TimToady++ 03:36
synopsebot Link: rt.perl.org/rt3//Public/Bug/Displa...?id=123939
TimToady m: sub foo(::T $f, ::T $g) { say T }; foo(1,"foo") 03:37
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/iBATkJS9lD␤Redeclaration of symbol T␤at /tmp/iBATkJS9lD:1␤------> 3sub foo(::T $f, ::T 7⏏5$g) { say T }; foo(1,"foo")␤»
TimToady \o/
03:38 noganex left, jack_rabbit left 03:39 colomon left
PerlJam m: Bag.new-from-pairs( tea => 42 ).perl.say; 03:40
camelia rakudo-moar 61c59d: OUTPUT«().Bag␤»
Mouq m: Bag.new-from-pairs( 'tea' => 42 ).perl.say; 03:41
camelia rakudo-moar 61c59d: OUTPUT«("tea"=>42).Bag␤»
Mouq :|
PerlJam aye. But I'm also wondering why it didn't complain about an unexpected named parameter 03:42
Mouq Methods don't
PerlJam ah.
oh, that's right. I forgot
Mouq Should I bug that too :9 03:43
PerlJam I'm not sure it is a bug. But it could surely surprise people. 03:44
ShimmerFairy forgot if there was a reasonable explanation for an implicit *% parameter on methods, which she still disagrees with 03:45
TimToady design.perl6.org/S12.html#Interface_Consistency is the argument 03:47
Mouq PerlJam: Considering that method is neither designed nor tested, except a bit on MixHashes, I'd say it'd be good to at least get in the system 03:48
TimToady jnthn++ has said that we might be able to find a bit in the captures to tell whether a given argument has ever been bound, and warn on unbounds at the end
PerlJam That would help 03:49
ShimmerFairy The reason why I disagree with it is that I've yet to see a case where implicit *%_ was a helpful thing to have, and plenty of times where you really wanted to pass a Pair instead of a named argument.
TimToady m: ( tea => 42 ).Bag.perl.say
camelia rakudo-moar 61c59d: OUTPUT«("tea"=>42).Bag␤»
TimToady how is that method needed? 03:50
Mouq m: ( 'tea' => 42 ).Bag.perl.say
camelia rakudo-moar 61c59d: OUTPUT«("tea"=>42).Bag␤»
Mouq Hmm
PerlJam huh
TimToady coercion to Bag already handles pairs
PerlJam I just saw it in the email thread.
TimToady and doesn't have the named arg problem
Mouq m: say MixHash.new-from-pairs("blood" => 1.1, "love" => 1.3, "rhetoric" => 2.2); say ("blood" => 1.1, "love" => 1.3, "rhetoric" => 2.2).MixHash
camelia rakudo-moar 61c59d: OUTPUT«MixHash.new(blood(1.1), love(1.3), rhetoric(2.2))␤MixHash.new(blood(1.1), love(1.3), rhetoric(2.2))␤»
Mouq (That's the way it's used in the tests we have involving new-from-pairs) 03:51
03:51 cognominal left
ShimmerFairy I wonder if %_.unbounded-pairs would be a feasible thing, either for standard Perl 6 or some sort of module... 03:52
TimToady that's why coercers are different from composers
Mouq So, new-from-pairs is really in want of deprecation?
03:53 colomon joined
Mouq ShimmerFairy: Isn't that just *%_ ? :P 03:53
ShimmerFairy well, it would have to account for arguments that get bounded later on. 03:54
TimToady unfortunately, polymorphism kinda demands that you be able to talk to each layer in the hierarchy in its own terms, and you have to do that through a single method call that can go to multiple methods 03:55
but we can certainly find some way of detecting when you misspelled a named arg
03:56 colomon left
TimToady btw, ShimmerFairy++ on new name :) 03:56
ShimmerFairy thanks :)
03:57 colomon joined
Mouq m: say {a => "b", c => "d"}.pairs.Bag 04:00
camelia rakudo-moar 61c59d: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏b' (indicated by ⏏)␤ in method Int at src/gen/m-CORE.setting:15023␤ in method Int at src/gen/m-CORE.setting:6830␤ in block at src/gen/m-CORE.setting:1975…»
04:01 FROGGS_ joined
PerlJam WAT 04:01
TimToady coercers are not composers
m: say {a => "b", c => "d"}.pairs.bag 04:02
camelia rakudo-moar 61c59d: OUTPUT«No such method 'bag' for invocant of type 'List'␤ in block <unit> at /tmp/nx8OLNFwNz:1␤␤»
TimToady m: say bag {a => "b", c => "d"}.pairs
camelia rakudo-moar 61c59d: OUTPUT«bag(a => b, c => d)␤»
ShimmerFairy last I checked, "b" is not a number :) (nor is "d")
TimToady that's a composer
PerlJam that first message is _so_ LTA though
TimToady m: say new Bag: {a => "b", c => "d"}.pairs 04:03
camelia rakudo-moar 61c59d: OUTPUT«bag(a => b, c => d)␤»
TimToady that's also a composer
m: say Bag({a => "b", c => "d"}.pairs)
camelia rakudo-moar 61c59d: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏b' (indicated by ⏏)␤ in method Int at src/gen/m-CORE.setting:15023␤ in method Int at src/gen/m-CORE.setting:6830␤ in block at src/gen/m-CORE.setting:1975…»
TimToady coercer, so fails
Mouq Gotcha 04:04
colomon output seems wrong, though? shouldn’t it be bag(a => b => 1 …) or something like that?
m: say bag <a b c>.list
camelia rakudo-moar 61c59d: OUTPUT«bag(a, b, c)␤»
Mouq m: say {a => "b", c => "d"}.pairs.&bag.perl
camelia rakudo-moar 61c59d: OUTPUT«("a" => "b"=>1,"c" => "d"=>1).Bag␤»
04:04 Sqirrel left
TimToady .gist 04:04
04:04 FROGGS left
colomon m: say bag <a b c a>.list 04:04
camelia rakudo-moar 61c59d: OUTPUT«bag(a(2), b, c)␤»
colomon ah
interesting 04:05
TimToady we really did name "gist" that to mean something tl;dr-ish 04:07
chops infinite lists off too
m: say 1,2,4 ... *
camelia rakudo-moar 61c59d: OUTPUT«1 2 4 8 16 32 64 128 256 512 1024 2048 4096 8192 16384 32768 65536 131072 262144 524288 1048576 2097152 4194304 8388608 16777216 33554432 67108864 134217728 268435456 536870912 1073741824 2147483648 4294967296 8589934592 17179869184 34359738368 68719476736…»
TimToady that used to fail
m: say 1 xx * 04:08
camelia rakudo-moar 61c59d: OUTPUT«1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...␤»
TimToady note the Texas ...
that was put by .gist
ShimmerFairy was about to say; any reason it's different from the other list's … ?
TimToady the other one was truncated by evalbot 04:09
ShimmerFairy ah
TimToady colomon: is your client still doing smart quoting for you? :) 04:10
colomon TimToady: ya sure
TimToady I fixed it fer ya
colomon ?? 04:11
Mouq haha
04:11 lizmat left
TimToady colomon: try typing an expression to camelia with "" or ... 04:11
colomon m: say “like this?” 04:12
camelia rakudo-moar 61c59d: OUTPUT«like this?␤»
colomon TimToady++
TimToady .u ’
TimToady I notice it puts that for your apostrophe though
colomon m: say ‘hmm'
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/BJFc1i3828␤Unable to parse expression in smart single quotes; couldn't find final "’" ␤at /tmp/BJFc1i3828:1␤------> 3say ‘hmm'7⏏5<EOL>␤ expecting any of:␤ argument list␤ p…»
TimToady we don't handle that one yet as part of an identifier
they have to balance 04:13
m: say ““like this?””; # curious
camelia rakudo-moar 61c59d: OUTPUT«“like this?”␤»
TimToady \o/
Mouq QLang++ 04:14
04:14 lizmat joined
ShimmerFairy m: say „hallo!“ # I obviously don't expect this to work 04:16
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5===␤No valid term seen where one is required␤at /tmp/jvue_Uqrkw:1␤------> 3say 7⏏5„hallo!“ # I obviously don't expect this␤Bogus term␤at /tmp/jvue_Uqrkw:1␤------> 3say 7⏏5„hallo!“ # I obviously don't expect thi…»
TimToady m: my \Q = "protogospel"; say Q
camelia rakudo-moar 61c59d: OUTPUT«protogospel␤»
TimToady ShimmerFairy: other night I said we should make that work :)
shouldn't be a problem, since only the opener has to be unique
the closers can be shared like that 04:17
04:17 colomon left
ShimmerFairy I vaguely remember the general rule was in S02, but there was already an exception to that rule, so it shouldn't be an issue :) 04:18
04:21 colomon joined
TimToady oh, except that's the wrong closer 04:23
Mouq m: say q„ 04:24
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/cHVl03sPhc␤Couldn't find terminator ”␤at /tmp/cHVl03sPhc:1␤------> 3say q„7⏏5<EOL>␤»
TimToady > say „hallo”
dalek kudo/nom: 37f8dd9 | TimToady++ | src/Perl6/ (2 files):
reduce cultural imperialism slightly
ShimmerFairy TimToady: it's the right closer in German, though :) 04:27
ash_gti so, I made a set of scripts for using the perl.tmbundle perl6 grammar to create an html page github.com/ashgti/perl6-syntax-hig...validation 04:29
dalek p: 63987b2 | TimToady++ | src/QRegex/P6Regex/Grammar.nqp:
allow low openers in regex too
TimToady thinks there are more Spanish speakers in the world than German... 04:30
ash_gti en.wikipedia.org/wiki/List_of_langu...e_speakers agrees with you 04:31
TimToady waits for someone to put in a vote for high-reversed-9 quotes.. 04:33
m: say q‟foo” 04:34
camelia rakudo-moar 61c59d: OUTPUT«foo␤»
04:34 Hor|zon joined
TimToady who uses those? 04:34
ash_gti would that make “ not interpolate? 04:37
m: my $f = 123; say q”f is $f”;
camelia rakudo-moar 61c59d: OUTPUT«5===SORRY!5=== Error while compiling /tmp/7MM6CvEVEM␤Use of a closing delimiter for an opener is reserved␤at /tmp/7MM6CvEVEM:1␤------> 3my $f = 123; say q7⏏5”f is $f”;␤»
04:38 Hor|zon left
ash_gti m: my $f = 123; say q"f is $f"; 04:39
camelia rakudo-moar 61c59d: OUTPUT«f is $f␤»
TimToady actually, the Spanish don't apparently use the low quotes, according to en.wikipedia.org/wiki/Quotation_mark
ShimmerFairy Dutch does the „...” thing, though
TimToady that's mostly in .eu, and it's a mess, not surprisingly :)
ShimmerFairy at least we won't be supporting lojban quotes any time soon :P 04:41
TimToady I think we can handle Esperanto though 04:47
ShimmerFairy Hmm... I'm not sure about that one. :P 04:49
Mouq mo nabmi zo'e lu nu curmi la lojbo sitsku valsi… dang that's verbose
05:05 asdf12z_ left 05:07 adu joined 05:18 sirdancealot left 05:25 sivoais left
ash_gti heres an example of the syntax I started for TextMate and atom if anyone is curious rawgit.com/ashgti/b9f21f21bbcc63e4...ample.html 05:29
I think I am going to work on quotes next, like regexp and heredocs
05:31 renormalist left 05:34 kaare__ is now known as kaare_ 05:36 sivoais joined 05:37 renormalist joined
Mouq ash_gti: Nice! 05:37
05:41 tmch left
ash_gti does anyone know off the top of their head where the .LANG('MAIN','quote') is found? 05:44
or how I would find out where its defined? 05:45
05:52 xinming left 05:53 tmch joined 05:55 ash_gti left 05:58 asdf12z_ joined 06:02 Alina-malina left 06:05 ash_gti joined 06:16 colomon left, colomon joined 06:17 ssutch left 06:19 laouji left 06:21 Ben_Goldberg left 06:22 Hor|zon joined 06:27 Hor|zon left 06:32 aborazmeh left 06:49 raiph left 06:54 xfix joined 07:15 rindolf joined
Mouq ash_gti: github.com/perl6/nqp/blob/master/s...r.nqp#L643 07:18
(sorry for late reply)
Or do you mean… 07:19
What do you mean?
07:19 Sqirrel joined, laouji joined
ash_gti well, I am trying to figure out how to match different types of quotes so I was looking up the grammar for them 07:20
but in the rakudo perl6 grammar it loads the .LANG(‘MAIN’, ‘quote’)
Mouq .LANG('MAIN', 'quote') looks up the 'quote' rule in 'MAIN', which just means Perl6::Grammar 07:21
(usually :P)
m: my $interpolation = "here"; say 'no $interpolation\qq[ $interpolation]!' 07:22
camelia rakudo-moar 37f8dd: OUTPUT«no $interpolation here!␤»
Mouq ^^ That's what it means
Does that help? 07:24
ash_gti github.com/rakudo/rakudo/blob/nom/....nqp#L4661 is where I think the ‘q{foobar}’ is parsed, I think 07:25
07:25 laouji left
ash_gti m: say q{{foo bar foobar}}.perl; 07:25
camelia rakudo-moar 37f8dd: OUTPUT«"foo bar foobar"␤»
ash_gti m: say qw{{foo bar foobar}}.perl;
camelia rakudo-moar 37f8dd: OUTPUT«("foo", "bar", "foobar")␤»
07:29 davido__ left 07:31 davido_ joined 07:44 gfldex joined 07:47 fhelmberger joined 07:48 jack_rabbit joined 07:52 fhelmberger left, pyrimidi_ joined 07:53 pyrimidi_ left 08:03 aborazmeh joined, aborazmeh left, aborazmeh joined 08:05 prime- left 08:07 Alina-malina joined 08:11 virtualsue joined, Hor|zon joined, prime joined 08:16 Hor|zon left, darutoko joined 08:22 Kristien joined 08:25 Kristien left 08:28 diana_olhovik_ joined
ash_gti rawgit.com/ashgti/055797e1199b5cff...ar.pm.html I ran the Perl6/Grammary from Rakudo through the syntax highlighter, let me know if anyone sees any glaring mistakes, its not complete yet, but its an improvement 08:29
08:30 virtualsue left
Mouq ash_gti++ 08:30
ash_gti: It doesn't seem to handle "$<B>" 08:31
ash_gti ya, its not recongizing any of the regexp language either yet
I also need to match package names and subnames
I am getting a bit tired, but I’ll try to work on this a bit more tomorrow, cya 08:33
08:34 ash_gti left 08:36 diana_olhovik__ joined 08:37 diana_olhovik_ left 08:43 MadcapJake left, MadcapJake joined 08:44 Aurelie joined 08:52 aborazmeh left 08:53 _mg_ joined 08:54 virtualsue joined 08:55 wicope joined 08:59 _mg_ left
lizmat .botsnack 09:04
yoleaux :D
03:18Z <TimToady> lizmat: (key => 0).Bag must remove key or it violates the bag's contract; the whole point of a Bag with 0 items in it is that that is no different from an empty Bag
03:19Z <TimToady> lizmat: Throwing info away is not our lowest ideal, or however you say that...
09:12 jack_rabbit left, Hor|zon joined 09:14 rurban joined 09:16 dj_goku left 09:17 Hor|zon left 09:20 espadrine joined
dalek kudo/nom: 300167d | lizmat++ | src/core/Baggy.pm:
Allow Failure to percolate up

Pretty sure this is tested with a "dies_ok" in the spectest, and not with a
  "throws_like", so the test was passing for the wrong reason on (a=>-1).Bag
09:25 Rounin joined 09:27 dj_goku joined, dj_goku left, dj_goku joined 09:32 diana_olhovik__ left 09:34 diana_olhovik joined
DrForr_ G'morning. Is there a specific place to report bugs? I've got a fairly simple test case that takes out te VM I ru perl6 on. 09:43
(was looking at the p6 wiki for a site, nothing really stood out.)
09:44 virtualsue left
moritz DrForr_: [email@hidden.address] 09:46
DrForr_ Thanks. I'm stripping down the test case, will send it soonish.
jnthn .tell TimToady it's a little pain with our one-passness, but I wonder if *%_ generation being triggered by the presence of a nextsame/callsame somewhere in the method body would do it. 09:48
yoleaux jnthn: I'll pass your message to TimToady.
09:49 mr-foobar left 09:50 mr-foobar joined 09:53 rurban left 09:56 lizmat left 09:59 adu left 10:02 lizmat joined 10:03 rurban joined 10:06 kst` joined, kjs_ joined 10:07 kst left
dalek c: ea1a253 | moritz++ | lib/Type/Cool.pod:
Cool: sub forms of abs, sqrt; examples
10:16 jack_rabbit joined 10:17 mr-foobar left 10:18 mr-foobar joined 10:28 jack_rabbit left 10:29 kjs_ left
lizmat commute& 10:42
10:42 lizmat left 10:47 kjs_ joined
dalek kudo/nom: dcda6c3 | (Carl Masak)++ | src/core/Temporal.pm:
disallow .later() without any named arguments
masak someone(tm) is welcome to add a spectest to check for that, too. 10:48
jnthn m: use Test; dies_ok { now.later } 10:50
camelia rakudo-moar 300167: OUTPUT«ok 1 - ␤»
jnthn m: now.later
camelia rakudo-moar 300167: OUTPUT«No such method 'later' for invocant of type 'Instant'␤ in block <unit> at /tmp/V9f7kygmlw:1␤␤»
jnthn Oh :)
m: DateTime.now.later
camelia rakudo-moar 300167: OUTPUT«use of uninitialized value $unit of type Any in string context in sub thread_junction at src/gen/m-CORE.setting:1␤␤use of uninitialized value $unit of type Any in string context in sub thread_junction at src/gen/m-CORE.setting:1␤␤use of uninitial…»
jnthn m: dies_ok { DateTime.now.later }
camelia rakudo-moar 300167: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Ajkgtwv4Vw␤Undeclared routine:␤ dies_ok used at line 1␤␤»
jnthn m: use Test; dies_ok { DateTime.now.later } 10:51
camelia rakudo-moar 300167: OUTPUT«use of uninitialized value $unit of type Any in string context in sub thread_junction at src/gen/m-CORE.setting:1␤␤use of uninitialized value $unit of type Any in string context in sub thread_junction at src/gen/m-CORE.setting:1␤␤use of uninitial…»
jnthn masak: Does that one pass with your branch?
uh, your commit
masak $ perl6 -e 'use Test; dies_ok { DateTime.now.later }' 10:54
ok 1 -
DrForr_ bug report sent.
masak DrForr_++
10:56 diana_olhovik left 10:57 laouji joined
DrForr_ It's a rare edge case I imagine, but it should still throw a compile-time error rather than what it did. 11:00
11:01 Hor|zon joined 11:02 laouji left
jnthn m: say 5.54 / 19.86 11:04
camelia rakudo-moar 300167: OUTPUT«0.278953␤»
11:06 Hor|zon left
FROGGS_ you are calculating your hight divided by the year of birth in percent? 11:09
jnthn haha :P 11:14
That's off by one on my birth year though :P
DrForr_ Is that the bug? :) 11:15
jnthn No, the calc was time after / time before of a benchmark (the after being when I implemented a few things missing in the JIT so it could JIT-compile a benchmark :)) 11:16
Which accounts entirely for some of the native-ref performance slowdowns.
And partially for a couple of them.
11:17 sirdancealot joined
FROGGS_ ewww 11:18
[ptc] how does one extract the Pod structure of a file containing code and Pod? I've found that EVAL("filename") on a pure-Pod file returns this structure, but a file containing both runs the code only 11:19
there's probably something simple I'm missing, but grepping the specs, docs, rakduo hasn't turned up much 11:20
11:20 spider-mario joined
jnthn m: say 606 / 1155 11:27
camelia rakudo-moar dcda6c: OUTPUT«0.524675␤»
11:44 telex left 11:46 telex joined 11:50 vendethiel left 11:55 vendethiel joined 12:00 kjs_ left
[Tux] FROGGS_, Slang::Tuxic fails on nameless sub with arg-spec - gist.github.com/Tux/c57969dc265fb0012408 12:02
FROGGS_ [Tux]: that's kinda expected
[Tux] :(
FROGGS_ since 'sub' can be a subroutine name, unlike in other lanugages 12:03
[Tux] hmmm
12:04 kjs_ joined
jnthn Try spelling it out as "anon sub" maybe 12:05
Alternatively, if you don't need to use "return" in there, go with a pointy block 12:06
12:08 kjs_ left, mr-foobar left, isBEKaml joined
[Tux] anon sub works. I'll go with that for now 12:09
dalek kudo/native-ref: ed74d05 | jnthn++ | src/Perl6/Optimizer.nqp:
Annotate return type on node post-inline.

Allows full inlining on chains like '$x ~ $y ~ $z', where the types of
  $x, $y, and $z are all known.
12:15 vendethiel left 12:17 vendethiel joined 12:22 virtualsue joined 12:23 perl6_newbee joined
perl6_newbee hi all 12:28
what happened to MIME::Base64?
I want to install LWP::Simple but got error: MIME::Base64 is not present in the module ecosystem
temporarly vanished?
12:28 laouji joined
perl6_newbee also gone by purpose? 12:29
dalek kudo/native-ref: 1145f2a | jnthn++ | src/Perl6/Optimizer.nqp:
Optimize away ref taking when args are known ro.

This only works for subs, and then only those we can compile-time analyze. Still, that covers quite a lot of ground for code using native types.
kudo/native-ref: 45f77e5 | jnthn++ | src/core/Stringy.pm:
Add prefix:<~> candidates for native int/num.

We can handle these very cheaply, and have them inlinable.
jnthn perl6_newbee: No idea, it's still listed on modules.perl6.org/ 12:30
perl6_newbee yeah, listed it is.
I will update rakudobrew and panda and try again 12:31
12:33 laouji left
moritz ecosystem-api.p6c.org/projects.json also includes it 12:34
12:35 coffee` joined 12:38 vendethiel left
perl6_newbee I had to update panda, now it is installing. However, I had to git ignore the panda/ext directory, before it did the pull request 12:40
dalek Heuristic branch merge: pushed 44 commits to nqp by jnthn 12:43
jnthn That was the merge of native-ref in NQP
moritz \o/
12:45 virtualsue left
[ptc] moritz: have you got a minute? 12:45
moritz [ptc]: yes
dalek p: a01002f | jnthn++ | tools/build/MOAR_REVISION:
Bump MoarVM for JIT of some native ref ops.
[ptc] I'm trying to extract pod from source files containing both code and pod, however have hit a bit of a wall
I've worked out that one can slurp in the file and EVAL that (with $=pod on the end) and that creates a pod structure
however, that's only if there is *only* pod in the file
moritz right, otherwise it runs the code 12:47
[ptc] how does one extract the pod structure without running the code in the file?
moritz [ptc]: maybe it requires a rakudo patch
[ptc] and the EVAL trick I found inside htmlify, hence why I thought you'd know :-)
moritz [ptc]: at least off-hand, I can't think of anything clever
[ptc] oh
how does --doc work then?
moritz from inside rakudo :-) 12:48
[ptc] ah
moritz but that's a good lead
check what it does
[ptc] already have, and got a bit lost...
moritz here's a really, really hacky idea
write to Pod::To::Perl module
that simply returns $pod.perl
then run perl6-m --doc=Perl thefile 12:49
12:49 rurban left
moritz capture the output, eval it 12:49
did I mention it was really, really hacky? :-)
[ptc] you're right, that *is* hacky! :-D
[ptc] grings
12:50 Hor|zon joined
[ptc] how do I write to the Pod::To::Perl module? 12:50
moritz class Pod::To::Perl { method render($pod) { $pod.perl } } 12:51
[ptc] ok
[Tux] wonders if he did not understand defaults correct ... 12:52
method foo (Str $needed, Int $optional = 0) { ... }
$optional being default, right? And set to 0 if not passed 12:53
jnthn [Tux]: Yes
moritz yes
[Tux] but it *also* renders it to be readonly
jnthn Sure
[Tux] if '$optional--' is used inside the sub, Cannot assign to an immutable value
moritz all parameters are
jnthn Just making something have a default doesn't magic up a container. 12:54
Add "is copy" for that
moritz unless marked 'is rw' or 'is copy'
[Tux] alters assumptions in his mind (that might take a bit)
12:55 Hor|zon left
perl6_newbee FYI: installing LWP::Simple failed, because get-unsized.t tries to get rakudo.org, and that is down. Had to install with --notests 12:55
12:56 vendethiel joined, rurban joined
[ptc] moritz: it works! 12:56
moritz [ptc]: that's a bit scary
[ptc] it's also very cool, and allows me to get a bit further :-) 12:57
thanks heaps!
moritz you're welcome 13:01
jnthn: fwiw I got no new spectest failures due to the nqp merge (with a rakudo that uses the new nqp, of course) 13:06
FROGGS_ moritz: there seems to be a problem with NULLs in DBIish with the Pg driver 13:07
moritz FROGGS_: care to elaborate (or even better, open an issue?) 13:08
FROGGS_ moritz: when I select row, I get a NULL back as an empty string
moritz :(
FROGGS_ when I then select rows with a where clause and that empty string, I of course dont get back the said rows 13:09
jnthn moritz: Yay. And rakudo native-ref merge coming up soon too :)
FROGGS_ moritz: so I think we want to use the Str type object for NULLs
13:09 Aurelie left
dalek Heuristic branch merge: pushed 63 commits to rakudo/nom by jnthn 13:15
jnthn Vive le native-ref
Or something. :)
13:15 laouji joined 13:16 isBEKaml_ joined 13:17 isBEKaml left
[Tux] if @aoa is a list of @aof's, like [[1,2,3],[4,5,6],[6,7,8]], how do I do «for @aoa -> @aof { for @aof -> $f { ... }}»? 13:17
jnthn [Tux]: As in, without needing the outer loop? 13:18
[Tux] no, as in how will @aof be a list
as in perl5's @$ref
jnthn m: sub foo(@a) { say elems @a }; foo(my @ = 1, 2, 3); foo([1,2,3]); 13:20
camelia rakudo-moar dcda6c: OUTPUT«3␤3␤»
jnthn The signature binding itself removes the outer Scalar
And -> @aof { ... } is just a lambda, so the @aof is a signature, so it's normal sig binding semantics there 13:21
arnsholt jnthn++ # Habemus i++!
13:21 Alina-malina left, Alina-malina joined
[Tux] my sub has a (*@args) signature. If @args.elems == 1 and @args[0].^name ~~ /Array/ I want to expand @args[0] instead of using @args 13:21
arnsholt, for native int ? 13:22
[Tux] compiles again
jnthn oh... 13:23
[Tux] gist.github.com/Tux/a1e61d22f31d30a5c8bf <= code example speaks louder than words
moritz FROGGS_: can you please open an issue for the NULL thingy? 13:24
FROGGS_ moritz: will do in a bit
jnthn m: sub has-a(*@args) { @args = @args>>.flat; say @args.perl; }; has-a(1); has-a(1, 2, 3); has-a([1,2,3]);