»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
BenGoldberg m: say Numeric.^methods; 00:00
camelia rakudo-moar b54294: OUTPUT«(log log10 exp roots succ pred)␤»
BenGoldberg m: say Numeric.new.succ; 00:01
camelia rakudo-moar b54294: OUTPUT«Memory allocation failed; could not allocate 58208 bytes␤»
BenGoldberg m: say Numeric.succ;
camelia rakudo-moar b54294: OUTPUT«Use of uninitialized value of type Numeric in numeric context in any at gen/moar/m-Metamodel.nqp line 1718␤1␤»
AlexDaniel BenGoldberg: LTA 00:02
00:02 patrickz left
BenGoldberg I wonder if there's a missing :D somewhere. 00:02
00:02 Yary left, FreezerburnV left 00:04 NZKindest joined 00:05 firstdayonthejob left 00:09 vendethiel left 00:12 BenGoldberg left, arlenik joined 00:13 BenGoldberg joined, BenGoldberg left 00:15 BenGoldberg joined 00:16 arlenik left, espadrine left 00:19 Guest46973 left, mohae left 00:21 mohae joined
sortiz BenGoldberg, In Numeric. github.com/rakudo/rakudo/blob/nom/...ic.pm#L28, Indeed missing! 00:25
BenGoldberg :) 00:31
00:34 raiph joined 00:37 SCHAAP137 left 00:39 pukku joined, pukku left
BenGoldberg m: say Mu.new; 00:41
camelia rakudo-moar b54294: OUTPUT«Mu.new␤»
BenGoldberg m: say so Mu.new;
camelia rakudo-moar b54294: OUTPUT«True␤»
BenGoldberg m: class Foo is Mu { }; say Foo.new; 00:42
camelia rakudo-moar b54294: OUTPUT«Foo.new␤»
BenGoldberg m: class Foo is Mu { }; say so Foo.new;
camelia rakudo-moar b54294: OUTPUT«True␤»
BenGoldberg m: say Numeric.^find_method('Bool') 00:44
camelia rakudo-moar b54294: OUTPUT«Bool␤»
00:52 Ben_Goldberg joined 00:53 BenGoldberg left, Ben_Goldberg is now known as BenGoldberg
timotimo goes to(wards) bed 00:56
01:00 sufrostico joined
skids Who's Ward? :-) 01:03
01:03 wamba left 01:04 wamba joined
BenGoldberg is confused by something. 01:13
I *think* that these should produce the same output:
m: say map *.perl, Numeric.^find_method('Bool').candidates;
camelia rakudo-moar b54294: OUTPUT«(method Bool (Mu $: *%_) { #`(Method|40928744) ... })␤»
BenGoldberg m: say map *.perl, .^find_method('Bool').candidates for Numeric; 01:14
camelia rakudo-moar b54294: OUTPUT«(method Bool (Mu $: *%_) { #`(Method|39740968) ... } method Bool (Numeric:D $: *%_) { #`(Method|50390536) ... })␤»
flussence m: say map *.perl, (.^find_method('Bool').candidates for Numeric); 01:24
camelia rakudo-moar b54294: OUTPUT«((method Bool (Mu $: *%_) { #`(Method|44369480) ... }, method Bool (Numeric:D $: *%_) { #`(Method|55019352) ... }))␤»
flussence hm, now I'm confused too 01:25
BenGoldberg m: my $m = Numeric.^find_method('Bool'); $m( Numeric.new ).say; 01:26
camelia rakudo-moar b54294: OUTPUT«True␤»
Hotkeys m: say Numeric.^find_method('Bool').candidates.elems; say (.^find_method('Bool').candidates for Numeric).elems 01:29
camelia rakudo-moar b54294: OUTPUT«1␤1␤»
Hotkeys m: say Numeric.^find_method('Bool').candidates.elems; say (.^find_method('Bool').candidates for Numeric)[0].elems
camelia rakudo-moar b54294: OUTPUT«1␤2␤»
BenGoldberg Ooh, it's producing a one element list with a two element list in it. 01:30
Hotkeys m: say Numeric.^find_method('Bool').candidates; say (.^find_method('Bool').candidates for Numeric)
camelia rakudo-moar b54294: OUTPUT«(Bool)␤((Bool Bool))␤»
Hotkeys seems like
BenGoldberg m: my @c = !(.^find_method('Bool').candidates for Numeric); say +@c 01:31
camelia rakudo-moar b54294: OUTPUT«1␤»
BenGoldberg m: my @c = !(.^find_method('Bool').candidates for Numeric); say @c
camelia rakudo-moar b54294: OUTPUT«[False]␤»
BenGoldberg m: my @c = !(.^find_method('Bool').candidates for Numeric); say @c[0]
camelia rakudo-moar b54294: OUTPUT«False␤»
BenGoldberg m: my @c = !(.^find_method('Bool').candidates for Numeric); say @c[0].WHAT
camelia rakudo-moar b54294: OUTPUT«(Bool)␤»
BenGoldberg m: my @c := !(.^find_method('Bool').candidates for Numeric); say @c[0].WHAT
camelia rakudo-moar b54294: OUTPUT«Type check failed in binding; expected Positional but got Bool␤ in block <unit> at /tmp/ja_AnGGOkn line 1␤␤» 01:32
BenGoldberg m: my @c := (.^find_method('Bool').candidates for Numeric); say @c[0].WHAT
camelia rakudo-moar b54294: OUTPUT«(List)␤»
BenGoldberg m: my @c := (.^find_method('Bool').candidates for Numeric); say @c[0].elems;
camelia rakudo-moar b54294: OUTPUT«2␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; say +@c; 01:33
camelia rakudo-moar b54294: OUTPUT«2␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; say .perl for 2c;
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/OB4HS1fIDP␤Missing semicolon␤at /tmp/OB4HS1fIDP:1␤------> 3meric); my @c := @c0[0]; say .perl for 27⏏5c;␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; say .perl for @c;
camelia rakudo-moar b54294: OUTPUT«method Bool (Mu $: *%_) { #`(Method|38913848) ... }␤method Bool (Numeric:D $: *%_) { #`(Method|49563264) ... }␤»
Hotkeys m: Numeric.^find_method('Bool').say
camelia rakudo-moar b54294: OUTPUT«Bool␤»
Hotkeys m: Numeric.^find_method('Bool').perl.say
camelia rakudo-moar b54294: OUTPUT«method Bool (Mu $: | is raw) { #`(Method|48415024) ... }␤»
Hotkeys m: Numeric.^find_method('Bool').candidates.perl.say
camelia rakudo-moar b54294: OUTPUT«(method Bool (Mu $: *%_) { #`(Method|53024216) ... },)␤»
skids m: say map *.perl, .^find_method("Bool").candidates for Numeric, Bool 01:34
camelia rakudo-moar b54294: OUTPUT«(method Bool (Mu $: *%_) { #`(Method|67184200) ... })␤(method Bool (Bool:D $: *%_) { #`(Method|67725320) ... } method Bool (Bool:U $: *%_) { #`(Method|67725472) ... })␤»
skids m: say map *.perl, .^find_method("Bool").candidates for IterationEnd
camelia rakudo-moar b54294: OUTPUT«Method 'map' not found for invocant of class 'Mu'␤ in block <unit> at /tmp/CryDmE5hf8 line 1␤␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; my $n = Numeric.new; for @c -> \cand { say cand($n) }
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/u2AMVIuL6l␤Variable '&cand' is not declared␤at /tmp/u2AMVIuL6l:1␤------> 3$n = Numeric.new; for @c -> \cand { say 7⏏5cand($n) }␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; my $n = Numeric.new; for @c -> $cand { say $cand($n) }
camelia rakudo-moar b54294: OUTPUT«True␤Memory allocation failed; could not allocate 82944 bytes␤»
Hotkeys m: say map*.perl, (.^find_method('Bool').candidates with Numeric) 01:35
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/0eGNb8HzJm␤Calling map() will never work with any of these multi signatures:␤ (&code, + is raw)␤at /tmp/0eGNb8HzJm:1␤------> 3say 7⏏5map*.perl, (.^find_method('Bool').candid␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; my $n = Numeric.new; $c[0]($n);
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/73EY4XvyS0␤Variable '$c' is not declared. Did you mean '@c'?␤at /tmp/73EY4XvyS0:1␤------> 3; my @c := @c0[0]; my $n = Numeric.new; 7⏏5$c[0]($n);␤»
Hotkeys m: say map *.perl, (.^find_method('Bool').candidates with Numeric)
camelia rakudo-moar b54294: OUTPUT«()␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; my $n = Numeric.new; @c[0]($n);
camelia ( no output )
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; my $n = Numeric.new; @c[1]($n);
camelia rakudo-moar b54294: OUTPUT«Memory allocation failed; could not allocate 82944 bytes␤»
01:36 addison left
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; say .perl for @c; 01:36
camelia rakudo-moar b54294: OUTPUT«method Bool (Mu $: *%_) { #`(Method|50939704) ... }␤method Bool (Numeric:D $: *%_) { #`(Method|61589120) ... }␤»
BenGoldberg m: my @c0 := (.^find_method('Bool').candidates for Numeric); my @c := @c0[0]; say @c[1].file;
camelia rakudo-moar b54294: OUTPUT«gen/moar/m-CORE.setting␤»
BenGoldberg Drat... that's annoying.
skids m: say map *.perl, .^find_method("Bool").candidates for Numeric, IterationEnd
camelia rakudo-moar b54294: OUTPUT«(method Bool (Mu $: *%_) { #`(Method|49890952) ... })␤»
BenGoldberg ponder submittting a bug report, to the effect that the genenerated setting ought to have the equivilant of '#file' in it, indicating the file from which it was generated. 01:39
m: Numeric.new != 0; 01:40
camelia rakudo-moar b54294: OUTPUT«WARNINGS for /tmp/J5pUO24vUB:␤Useless use of "!=" in expression ".new != 0" in sink context (line 1)␤Memory allocation failed; could not allocate 61472 bytes␤»
BenGoldberg m: Numeric.new == 0; 01:41
camelia rakudo-moar b54294: OUTPUT«WARNINGS for /tmp/3oYjw3Btyy:␤Useless use of "==" in expression ".new == 0" in sink context (line 1)␤Memory allocation failed; could not allocate 61456 bytes␤»
skids m: say map {$_.WHAT}, .^find_method("Bool").candidates for Numeric 01:44
camelia rakudo-moar b54294: OUTPUT«((Method) (Method))␤»
skids Hotkeys: yep, as you saw ^^ 01:45
BenGoldberg I think I might possibly have found it: 01:48
m: role Foo { method Foo { self } }; proto sub infix:<eq-like>(Mu $?, Mu $?) is pure { * }; multi sub infix:<eq-like>($?) { Bool::True }; multi sub infix:<eq-like>(\a, \b) { a.Foo eq-like b.Foo }; say Foo.new eq-like Foo.new;
camelia rakudo-moar b54294: OUTPUT«Memory allocation failed; could not allocate 118816 bytes␤»
BenGoldberg Compare this with: github.com/rakudo/rakudo/blob/nom/...ic.pm#L248
skids $? ... ? 01:52
BenGoldberg No idea, just copy-pasting ;)
skids Oh, optional discarded $ 01:53
gfldex optional anonymous positional argument
skids Wouldn't that recurse infinitely without annother multi? 01:54
BenGoldberg Precisely.
It's recursing infinitely, and thus runs out of memory. 01:55
That's my guess, anyway. 01:56
skids m: &infix:<==>.candidates.say
camelia rakudo-moar b54294: OUTPUT«(sub infix:<==> ($?) { #`(Sub|60059064) ... } sub infix:<==> (\a, \b) { #`(Sub|60061344) ... } sub infix:<==> (Real \a, Real \b) { #`(Sub|60061192) ... } sub infix:<==> (Int:D \a, Int:D \b) { #`(Sub|60059520) ... } sub infix:<==> (int $a, int $b) { #`(Sub|…»
skids There are other multis, unless they are not defined in some internal scope
BenGoldberg Sure, but which of them match on a value which is defined, and Numeric, and not a subtype of Numeric? 01:58
skids m: multi sub infix:<==> (Numeric:D $?, Numeric:D $?) { "OHAI".say }; say so Numeric.new; 02:02
camelia rakudo-moar b54294: OUTPUT«Memory allocation failed; could not allocate 82944 bytes␤»
02:05 cdg left 02:07 raiph left 02:16 Ben_Goldberg joined 02:17 BenGoldberg left 02:21 NZKindest left, leont left, kid51 left 02:23 kid51 joined 02:25 kid51 left 02:26 kid51 joined 02:27 wamba left
awwaiid is someone named "raiph" around here? they left a comment adding some more colons to my collection. I thank them! thelackthereof.org/Perl6_Colons 02:29
02:29 molaf_ joined
masak yes, raiph frequents this channel. 02:29
awwaiid .tell raigh Thanks for the comments, I've updated thelackthereof.org/Perl6_Colons 02:30
yoleaux awwaiid: I'll pass your message to raigh.
awwaiid thanks masak
TEttinger that was to raigh not raiph? 02:32
02:33 molaf left
awwaiid .tell raiph Thanks for the comments, I've updated thelackthereof.org/Perl6_Colons 02:33
yoleaux awwaiid: I'll pass your message to raiph.
awwaiid :)
02:34 jameslenz joined, yqt left, apiw joined 02:35 partly__ joined 02:38 partly_ left
revhippie awwaiid: don't forget the number-first colon-pair :5foo 02:42
awwaiid got that one 02:43
it was in there as :1day, I changed it to :73day to make it easier to see 02:44
revhippie ohh sorry. 02:46
02:47 hippie1 joined, apiw left
awwaiid hmm. Almost all colon-pair is some sugar for Pair.new($key, $val). Is there a longhand for number conversion :16<d00d>? 02:48
02:48 hippie left 02:49 apiw joined
skids m: :16[0xd, 0, 0, 0xd] # ?? 02:51
camelia ( no output )
sortiz m: "d00".UNBASE(16) 02:52
camelia rakudo-moar b54294: OUTPUT«Method 'UNBASE' not found for invocant of class 'Str'␤ in block <unit> at /tmp/zF50ACZbW2 line 1␤␤»
sortiz m: "d00".UNBASE(16,"d000")
camelia rakudo-moar b54294: OUTPUT«Method 'UNBASE' not found for invocant of class 'Str'␤ in block <unit> at /tmp/1_vOB8tLXL line 1␤␤»
sortiz m: UNBASE(16,"d000")
camelia ( no output )
sortiz m: UNBASE(16,"d000").say
camelia rakudo-moar b54294: OUTPUT«53248␤»
awwaiid UNBASE. Interesting. Why so loud? 02:53
skids That's more a rakudo internal thing, not a Perl 6 thing
awwaiid ah
sortiz For promote the sugared form, I suppose 02:54
awwaiid m: say 255.base(16)
camelia rakudo-moar b54294: OUTPUT«FF␤»
02:55 sufrostico left
awwaiid pretty weird syntax, since all the other similar colon-pairs end up as a Pair 02:55
dalek kudo-star-daily: 20bb739 | coke++ | log/ (9 files):
today (automated commit)
02:56
sortiz m: say :16[1, 3]; say UNBASE_BRACKET(16, 1, 3):
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/VNGLw1Lncx␤Calling UNBASE_BRACKET(Int, Int, Int) will never work with declared signature ($base, @a)␤at /tmp/VNGLw1Lncx:1␤------> 3say :16[1, 3]; say 7⏏5UNBASE_BRACKET(16, 1, 3):␤»
sortiz m: say :16[1, 3]; say UNBASE_BRACKET(16, [1, 3]):
camelia rakudo-moar b54294: OUTPUT«19␤19␤»
02:57 mr-foobar joined
awwaiid my $x = 24; say :$x<2034> 02:58
m: my $x = 24; say :$x<2034>
camelia rakudo-moar b54294: OUTPUT«(Mu)␤»
awwaiid equivalent to (:$x)<2034>, uselessly looking up the 2034 key in x => 24. 03:00
03:12 noganex joined 03:13 kid51 left 03:15 noganex_ left 03:17 hacst left, apiw left 03:20 hacst joined, chace joined, Herby_ joined
Herby_ Evening, everyone! 03:20
\o
03:21 mohae left 03:22 mohae joined 03:24 adu joined 03:27 Actualeyes joined 03:46 kurahaupo_ joined
Herby_ \o 03:49
o\
\o/
03:50 kurahaupo left
MadcapJake i have a derived class that has an overridden method but it's one that is used only internally to the base class and it seemingly won't use my derived version, how can make it do that? 03:50
gfldex how do you call that methdod? 03:52
MadcapJake it's called inside a method in the base class
gfldex code pls tyvm
MadcapJake here's one of the calls (there are a bunch in this class), the method in question is `died` github.com/MadcapJake/Test-Lab/blo...t.pm6#L113 03:54
Here's my derived class's overridden version github.com/MadcapJake/Test-Lab/blo...ment.t#L11 03:55
gfldex i don't thinks self.self is going to work. It's very late here and I will need to sleep over it. 03:57
MadcapJake alright :D
any quick thoughts that could lead me in the right direction?
gfldex no, but you may want to check what self.self. actually points to 03:59
MadcapJake self.self?
oh wow
that's bug
sadly, not the root cause here :P 04:01
04:05 dolmen joined 04:10 jolts left
masak m: class C { method self { "OH HAI" }; method foo { self.self } }; say C.new.foo 04:13
camelia rakudo-moar b54294: OUTPUT«OH HAI␤»
MadcapJake figured it out, any derived class needs to implement a `new` method or a call to new will just create a Cls::Default object 04:21
Is there a way to detect what class name is calling a method? I could put a guard in there that only defaults to Cls::Default is the calling class is the base. 04:22
figured that out too! :D 04:23
self.WHICH
04:31 mohae left 04:33 squach joined, skids left, mohae joined 04:35 squach1 left 04:42 Herby_ left 04:43 molaf_ left 04:48 kurahaupo_ left
ugexe you could also use multis like: multi bar(Cls::Base:D $foo) { set-defaults(); nextsame; }; multi bar($foo) { work($foo) } 04:54
05:00 revhippie left 05:02 rindolf joined 05:15 adu left 05:16 chace left 05:18 vendethiel joined 05:20 Ben_Goldberg left 05:25 adu joined 05:29 adu left 05:30 adu joined, adu left 05:32 mr-foobar left 05:33 mr-foobar joined 05:41 vendethiel left, dolmen left 05:42 mr-foobar left 05:47 Cabanossi left, vendethiel joined, mr-foobar joined 05:49 Cabanossi joined
MadcapJake is it mentioned anywhere that CATCH blocks will interfere with returning? Just figured this out x_x 06:00
jdv79 in what way is this manifesting? 06:02
MadcapJake ugexe, thanks for the tip, my current logic for new is «if self.WHICH.Str ~~ 'Test::Lab::Experiment' { Test::Lab::Experiment::Default.bless(:$name) } else { !!! }»
jdv79, I had a few methods with the body entirely wrapped in try/catch block 06:03
and the CATCH blocks were the last line
the only way I could get any values returned was either explicitly returning or by moving the CATCH block prior the implicit return statement
jdv79 iirc its not CATCH related at all. its just last line or explicit return. 06:05
MadcapJake oh! i assumed the CATCH would just be considered not a part of the sub's body 06:06
or rather the try's body 06:07
jdv79 well, its in there. again i believe that's the deal but i could be wrong.
MadcapJake m: sub foo { try { 'foo'; CATCH { default { die 'a horrible death' } } } }
camelia rakudo-moar b54294: OUTPUT«WARNINGS for /tmp/JpEbUrKd5x:␤Useless use of constant string "foo" in sink context (line 1)␤»
MadcapJake m: sub foo { try { CATCH { default { die 'a horrible death' } }; 'foo'; } }
camelia ( no output )
MadcapJake yep definitely is a thing :P
06:08 vendethiel left
MadcapJake the example in language/exceptions shows a CATCH at the beginning of the block, but it never really delves into the question as all of the logic is just printing to stdout 06:09
i guess my problem is I was thinking of a CATCH block as a kind of branch of a conditional 06:10
06:10 CIAvash joined 06:14 geraud left 06:15 mathw joined
jdv79 maybe that deserves a doc issue about returning less simply than doc.perl6.org/type/Block descibes 06:18
*describes
06:38 solarbunny left 06:40 solarbunny joined
jdv79 MadcapJake: i created github.com/perl6/doc/issues/388 06:47
nite
sortiz jdv79++ # For the issue opened, I'm in the same camp. 06:50
o/ jdv79
06:54 khw left 07:03 domidumont joined 07:06 mr-foobar left 07:08 mr-foobar joined, domidumont left 07:09 domidumont joined
rindolf jdv79: hi, sup? 07:12
07:17 vendethiel joined 07:32 sno left 07:39 vendethiel left
[Tux] test 21.943 07:39
test-t 11.839
csv-parser 51.701
07:39 firstdayonthejob joined
El_Che same as yesterday's 07:40
so it's not getting slower :)
07:46 RabidGravy joined 07:48 FROGGS joined 07:54 fireartist joined
MadcapJake jdv79, thanks! i'm off to bed too 07:55
07:55 nakiro joined
rindolf MadcapJake: good night. 07:56
08:03 vendethiel joined 08:05 Ven joined 08:06 nige1 left 08:11 darutoko joined 08:12 zakharyas joined 08:15 ely-se joined
RabidGravy morning 08:18
ely-se hi
RabidGravy need more coffee, just did "git init", "git add ." in the parent of the one I intended and wondered why it was taking so long 08:19
sortiz ups! 08:21
my \p = :what<foo>; .say for p<what>.WHAT, p<what> # All expected 08:22
08:22 mr-foobar left
sortiz m: my \p = :what<foo>; .say for p<what>.WHAT, p<what> # All expected 08:22
camelia rakudo-moar b54294: OUTPUT«(Str)␤foo␤»
sortiz m: my \p = :what<foo bar>; .say for p<what>.WHAT, p<what> # Beware, I was expecting also Str! 08:23
camelia rakudo-moar b54294: OUTPUT«(List)␤(foo bar)␤»
08:25 vendethiel left 08:29 Yary joined, Yary left 08:30 pdcawley joined 08:35 squach1 joined 08:36 [Tux] left 08:37 squach left 08:41 abraxxa joined 08:45 Ven left 08:46 Ven joined 08:48 [Tux] joined 08:51 pmurias joined
pmurias jnthn: +1 to everything in you versioning blog post, good that we use git tags instead of per version subdirectories 08:57
09:02 zakharyas left
pmurias jnthn: re MoarVM and it's opset, (as rakudo/nqp is as far as I know are the only clients, do we really need to lock the opset down for years?) 09:03
09:03 kurahaupo joined, vendethiel joined 09:04 sno joined
RabidGravy is there a thing which can turn something like "0d 00h 09m 38s" or some parsed set of numbers into a Duration? 09:05
moritz not in core 09:06
RabidGravy obviously not that difficult to do in a dumb way 09:07
09:08 nige1 joined 09:11 Actualeyes left 09:14 ocbtec joined 09:16 kurahaupo left 09:24 ely-se left, ely-se joined 09:26 vendethiel left
stmuk_ replies to versioning blog post 09:27
dalek c: c08878c | (Salvador Ortiz)++ | doc/Type/Pair.pod:
Update Pair.pod

Add some more examples of the adverbial form
09:31
09:35 dakkar_ joined
lizmat m: Real.new.Num # this is the loop: it calls Real.Bridge.Num., and Real.Bridge calls Real.Num again 09:36
camelia rakudo-moar b54294: OUTPUT«Memory allocation failed; could not allocate 81920 bytes␤»
lizmat this code has been in there for at least 4 years :-( 09:38
09:41 Hor|zon left, leont joined 09:43 fireartist left 09:55 espadrine joined
RabidGravy boo! 09:57
AlexDaniel Bool 09:58
lizmat eek!
dalek c: 1601312 | (Salvador Ortiz)++ | doc/Language/nativecall.pod:
Update nativecall.pod

Describe how to pass allocated pointers to native types in native calls
09:59
lizmat added RT #127503 about Real.new.num infinilooping, Yary++ BenGoldberg++ 10:03
10:03 fireartist joined
AlexDaniel m: my $foo = ‘hello’; say :$foo 10:04
camelia rakudo-moar b54294: OUTPUT«Unexpected named parameter 'foo' passed␤ in block <unit> at /tmp/wzMnCeL9yd line 1␤␤»
AlexDaniel m: my $foo = ‘hello’; say (:$foo)
camelia rakudo-moar b54294: OUTPUT«foo => hello␤»
10:06 rdmsno joined
AlexDaniel m: say (::a) 10:06
camelia rakudo-moar b54294: OUTPUT«===SORRY!===␤Could not locate compile-time value for symbol a␤»
AlexDaniel :/
10:07 vendethiel joined
rdmsno When I re-run "make && make install" on nqp & rakudo-star (eg. after libc update and subsequent jvm rebuild and consequently nqp -> rakudo-star rebuild), I get 10:07
~# perl6 -V
Unhandled exception: java.lang.RuntimeException: Missing or wrong version of dependency 'gen/jvm/stage2/QRegex.nqp'
in
in load_module
in
in load_module
in
in load_module
in
lizmat m: ::a # seems correct to me, AlexDaniel
camelia rakudo-moar b54294: OUTPUT«===SORRY!===␤Could not locate compile-time value for symbol a␤»
rdmsno where do I have to force a rebuild to get rid of that?
lizmat rdmsno: rm -rf install usually does the trick 10:08
rdmsno lizmat: that's a complete rebuild - what isn't sane
the intention of my question is to avoid the "rm -rf" hack 10:09
AlexDaniel lizmat: okay, so let's say I have a source file with 1000 lines… --ll-exception does not help too
lizmat AlexDaniel: I see your point
rdmsno: I'm afraid I have no other suggestion to offer at this point: I always went the rm -rf way :-( 10:10
rdmsno lizmat: than we should take half an hour on 18th and we find a better way - when you like
10:11 nige1 left
lizmat rdmsno: sure :-) 10:11
rdmsno lizmat: "rm -rf install" on nqp or rakudo-star?
lizmat you could try nqp first :-)
rdmsno nods 10:12
10:12 nige1 joined 10:13 molaf joined 10:17 wamba joined
lizmat AlexDaniel: looking at the ::a issue, fwiw 10:25
10:28 vendethiel left
FROGGS what should ::a mean btw? 10:28
10:31 pmurias left
lizmat probably nothing, but a typo of that kind in a large source file, would be hard to track 10:33
afk for a bit& 10:35
sortiz ::a means "Search for the package or symbol a"
m: my \a = 8; say ::a: 10:36
camelia rakudo-moar b54294: OUTPUT«8␤»
sortiz m: module a {}: say ::a:
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/1ktnIHfnGz␤Confused␤at /tmp/1ktnIHfnGz:1␤------> 3module a {}:7⏏5 say ::a:␤ expecting any of:␤ colon pair␤»
sortiz m: module a {}; say ::a:
camelia rakudo-moar b54294: OUTPUT«(a)␤»
10:37 leont left, zakharyas joined
sortiz m: class Foo {}; my $b = 'Foo'; say ::($b) 10:37
camelia rakudo-moar b54294: OUTPUT«(Foo)␤»
10:43 Ven left
sortiz As far as I understand... 10:44
10:45 apiw joined 10:47 FROGGS left 10:50 apiw left 10:56 nige1 left 10:57 virtualsue joined 10:58 pmurias joined
pmurias rdmsno: I encounter that sort of problems when there is a bug in the Makefile 11:01
rdmsno: I use "make clean" as a workaround for those sort of things 11:02
sortiz m: try { EVAL 'my $x = ::P' }; say ~$! 11:04
camelia rakudo-moar b54294: OUTPUT«Could not locate compile-time value for symbol P␤»
11:05 apiw joined
El_Che I love the flexibilitiy of Datetime.earlier(days => $negative_int) and later 11:08
but sometimes my head blows :)
11:11 apiw left 11:12 mscha joined
mscha m: say '[hello]' ~~ / <[ [ ]> /; # This one works fine ... 11:13
camelia rakudo-moar b54294: OUTPUT«「[」␤»
mscha m: say '[hello]' ~~ / <[ ] ]> /; # but this one does not. Isn't tha a bug?
camelia rakudo-moar b54294: OUTPUT«5===SORRY!5=== Error while compiling /tmp/nHFWkjQgsw␤Unable to parse expression in metachar:sym<assert>; couldn't find final '>' ␤at /tmp/nHFWkjQgsw:1␤------> 3say '[hello]' ~~ / <[ ] 7⏏5]> /; # but this one does not. Isn't␤»
11:14 FROGGS joined
jnthn mscha: I don't think we can make the second one work 11:15
mscha: And so we'd only be forbidding the first because you can't do the second, which may be consistent-er, but not sure it's worth the breaking change. 11:16
mscha jnthn: so, we're back to LTS? :(
m: say '[hello]' ~~ / <[ \] ]> /; 11:17
camelia rakudo-moar b54294: OUTPUT«「]」␤»
jnthn mscha: It just semes too small a reason to go breaking things. 11:18
11:18 kaare_ joined 11:19 RabidGravy left
jnthn It's well within the realm of things we could change and manage with version guarding. 11:20
But for me it's below the threshold of being worth bothering with. But I'm not the language designer... :)
lizmat jnthn: the ::a issue is a naked nqp::die in World.find_symbol
11:20 gcole_ joined
jnthn lizmat: How rude! 11:21
lizmat jnthn: it is being called at Actions:8928
jnthn I don't actually know what the ::a issue is :)
jnthn didn't really backlog... :)
lizmat m: ::a # note lack of where this happend
camelia rakudo-moar b54294: OUTPUT«===SORRY!===␤Could not locate compile-time value for symbol a␤»
jnthn Aha
Yeah...
That could do with a fix :) 11:22
lizmat and I'm looking at that
this happend at Actions:8928: trying to wrap that in a try
jnthn Cool. I guess $/ is available where we die?
lizmat it is there
11:23 gcole left
lizmat my assumption was that $type would be null if the find_symbol died 11:23
jnthn OK, shouldn't be too bad...
moritz while you're at it, "could not locate" is one of those weird error messages
lizmat but a nqp::isnull after the try doesn't fire
moritz why couldn't you locate it?
"No compile-time value for symbol a" would be better 11:24
perhaps adding a verb too, "No compile-time value available for symbol a"
lizmat moritz: that message will be replaced by a proper exception, e.g. X::NoSuchSymbol 11:25
jnthn lizmat: In NQP, scalars start out holding NQPMu
lizmat which means that nqp::isnull on them would be true, no?
jnthn No
lizmat ah?
jnthn NQPMu is not a null
null means a real null
lizmat so how do I check for that then?
unless $type ? 11:26
jnthn I'd probably do something in CATCH.... 11:27
lizmat ok, I'll try that
jnthn But you could explicitly initialize $type to nqp::null() before the try block too
Then your null check would work
lizmat no, it didn't :-( 11:28
tried that already :-(
hmmm... CATCH seems to fix it 11:30
running spectest now
11:33 apiw joined 11:37 nige1 joined
lizmat jnthn: there is one test in roast that tests for the specific error message we got before 11:43
should I just correct that one in roast/master 11:45
11:45 Guest63689 left
jnthn lizmat: Yes, that will have to be 6.c-errata at some point too :) 11:45
lizmat so fix in errata as a todo, and fix properly in master, is what you're saying ? 11:46
rdmsno pmurias: I asked because I expected one knows about that 11:47
dalek kudo/nom: b9f90bc | lizmat++ | src/Perl6/Actions.nqp:
Fix for RT #127504
rdmsno seems not, so I make an appointment with lizmat to dig into the Makefiles (I'm not familiar with nqp/rakudo* sources)
jnthn lizmat: I'd commit in master, then create the errata branch and cherry-pick. If you're not quite comfortable with doing that, then feel free to file this as a roast ticket and I can take care of it. 11:49
lizmat I'd prefer the latter :-) 11:50
jnthn OK. Maybe won't get to it today.
lizmat I'll commit to master
dalek ast: 5dcda3c | lizmat++ | integration/weird-errors.t:
Minimal change to make test pass after b9f90bc592f

Should be cherry picked and todo'd in errata branch
11:54
ast: 5a079b2 | lizmat++ | integration/weird-errors.t:
Add test for RT #127504
11:57
12:00 ribasushi left 12:01 ely-se left, Ven joined 12:02 apiw left 12:03 ely-se joined 12:07 ribasushi joined 12:08 apiw joined
AlexDaniel that was really quick 12:09
lizmat++
lizmat sometimes it can be quick :-)
12:14 M-Illandan left 12:15 kid51 joined 12:19 nekrodesk joined
dalek kudo/nom: b2e57f6 | lizmat++ | src/core/Hash.pm:
Improve Int %h by 20% by removing code

Why? Because the candidates that handle the type constrained values Hash, were less optimised. But the only difference really was how they tried to get at the Hash descriptor (which is the only thing that really separates a type constrained Hash from a
  "normal" Hash). So removing the code, will revert back to the
better optimised un-constrained candidates, and thus get better performance.
12:32
kudo/nom: a68d91c | lizmat++ | src/core/Hash.pm:
Cosmetics: use same order of method definitions
12:40
12:40 sufrostico joined 12:43 domidumont left 12:44 nanis joined, kid51 left, nanis left
dalek kudo/nom: 0b3beb6 | lizmat++ | src/core/Hash.pm:
Add comment why we didn't optimize Hash.BIND-KEY
12:55
12:57 nanis joined
nanis Is someone looking at RT #127473? <rt.perl.org/Public/Bug/Display.htm...127473> 12:58
lizmat nanis: I don't think that has a high priority, as it feels sufficiently away from "normal" usage that most users will never see it 13:00
but jnthn might think differently -)
13:00 nekrodesk left
nanis On the other hand, I am concerned that it makes perl6 look funny and fragile. It seems to be due to github.com/rakudo/rakudo/blob/f903....nqp#L1978 13:01
There, a check is made to see if one can invoke returns, and the code proceeds even if "can returns" fails.
jnthn Worth fixing, but not high priority for me. Others are welcome to take it on. :) 13:02
nanis Similar to proceeding to read from a file after open failed. I don't know enough about the internals to proceed, but looks like it might be possible to at least aovid the infinite loop.
AlexDaniel lizmat: that's not one of my hand-fuzzied bugs 13:03
lizmat: I actually got that when I was trying to get some kind of an array slice
lizmat as jnthn said: PR's welcome :-) 13:04
AlexDaniel sure-sure, I just commented on “most users will never see it” part 13:05
dalek c: feaed2e | (David Brunton)++ | doc/Type/Regex.pod:
Bool() doesn't return a Match object.

Bool() returns a Bool.
c: 661dd54 | (Zoffix Znet)++ | doc/Type/Regex.pod:
Merge pull request #389 from dbrunton/patch-6

Bool() doesn't return a Match object.
lizmat ah, ok, noted :-)
nanis I am leaving this observation here for what it is worth as I can't seem to comment on the bug on RT as an anonymous user, and I am not authorized to view the bug when I am logged in.
AlexDaniel m: my @a = [‘a’, ‘b’, <c d>]; say @a[2;1] 13:06
camelia rakudo-moar a68d91: OUTPUT«d␤»
lizmat
.oO( maybe we need something other than RT :-( )
AlexDaniel m: my @a = [‘a’, ‘b’, <c d>]; say @a[;1]
camelia rakudo-moar a68d91: OUTPUT«Non ast passed to WANTED: BOOTInt␤Non-QAST node visited BOOTInt␤Weird node visited: BOOTInt␤Non-QAST node visited BOOTInt␤Weird node visited: BOOTInt␤Weird node in analyze: BOOTInt␤===SORRY!===␤Unknown QAST node type BOOTInt␤»
arnsholt So the thing that triggers the error is if there's nothing before the semicolon, presumably? 13:07
13:07 uruwi left
nanis Ooooops! I didn't see the `next` in column 196 ... 13:10
13:10 apiw left, nige1 left 13:11 nanis left
AlexDaniel lizmat: thanks. I was playing around with it today and it only confirmed my dissatisfaction. For example, I cannot find a way to filter “Unowned tickets” section to just perl6 queue (I'm not interested in perl5 bugs). I even tried to “order by“ by queue but then some pugs bugs appeared. And when I click on perl6 queue the list is reversed so I have to sort it by ticket number. Perhaps there is a way to get it right but it's definite 13:11
beyond me.
lizmat hmmm... AT-POS on a shaped array with 1 dimension is 60x slower than without shape: I guess there is room for improvement there
timotimo yes, verily 13:12
pmurias nqp dynamic arrays can be used with the nqp shaped ones ops, not sure if it helps much
lizmat feels to me the AT-POS for 1 dimensions shapes should basically be: nqp::atpos, check bounds if a null was returned? 13:13
13:14 RabidGravy joined
lizmat starts trying to wrap her head around shaped arrays 13:14
pmurias nqp/t/moar/02-multidim.t contains a bunch of tests for the shaped arrays at low level 13:16
nqp::atpos can be used for the 1 dimensional ones 13:17
13:18 mscha left 13:21 sufrostico left 13:22 apiw joined
jnthn The shaped arrays code in Rakudo is very much "make it work" 'cus that's all I had time to do :) 13:22
The underlying design at the VM level supports "make it fast" better
lizmat yeah, got that :-)
jnthn We may want to break up the multi-dim from the shaped
So that the role we mix in doesn't override the AT-POS and so on for 1-dim shapes
But we do always get the push/pop etc. throw methods
nine AlexDaniel: Tickets/New Search in the menu gives you a great many options for filtering and sorting tickets 13:24
El_Che There is a huge thread on perl6 github issues page about the bug tracker: github.com/perl6/user-experience/issues/8
AlexDaniel nine: so I should create a custom search query and then list that query on the main page?
nine AlexDaniel: yes, you can turn any saved query into a panel on your main page ("Home" in the menu and otherwise called "RT at a glance") 13:25
AlexDaniel nine: also, is there any way to change the “New ticket in” default behavior? I'm pretty sure that one day I'll report a perl6 bug in perl5 queue and people will get mad at me 13:26
13:26 uruwi joined
nine AlexDaniel: I don't think so. The list ist simply sorted alphabetically 13:27
AlexDaniel: your desired search is Owner = 'Nobody' AND Queue = 'perl6' and ( Status = 'new' OR Status = 'open')
AlexDaniel yeah I see 13:28
dalek kudo/nom: 08710a2 | lizmat++ | src/core/Array.pm:
Mark private method as not returning anything
13:36
lizmat afk&
13:41 d4l3k_ joined, polyfloyd left, dalek left, [Tux] left, luiz_lha left 13:42 d4l3k_ is now known as dalek, ChanServ sets mode: +v dalek, luiz_lha joined
AlexDaniel m: min(+'a', +'a').say 13:42
camelia rakudo-moar 0b3beb: OUTPUT«Cannot convert string to number: base-10 number must begin with valid digits or '.' in '3⏏5a' (indicated by ⏏)␤ in block <unit> at /tmp/hrNGXUgZPH line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/hrNGXUgZPH line 1␤␤»
13:43 luiz_lha is now known as Guest42178
AlexDaniel m: say min() 13:43
camelia rakudo-moar 0b3beb: OUTPUT«Inf␤»
AlexDaniel m: say max()
camelia rakudo-moar 0b3beb: OUTPUT«-Inf␤»
AlexDaniel hehe
13:43 polyfloyd joined
AlexDaniel I see why it does that, but… perhaps max without args should return Inf? :) 13:44
arnsholt Why should it ever return Inf? 13:45
13:46 [Tux] joined, virtualsue left
dalek p: afe4963 | (Pawel Murias)++ | / (7 files):
[js] Unbitrot webpack support.

Using a setting, wrapping js values and making webpack serve source maps still NYI.
13:46
timotimo because Inf is the neutral element for min. for max, the neutral element is -Inf
that is, you can min($something, Inf) and always get $something
arnsholt timotimo: Exactly
max() returning Inf would make absolutely no sense =) 13:47
timotimo if max() would result in Inf, you would get a different result for max($something) and max($something, max())
13:48 eternaleye left
AlexDaniel m: my @a; say max @a 13:48
camelia rakudo-moar 0b3beb: OUTPUT«-Inf␤»
timotimo in other words, if you have an empty @a, and you add something to it, ideally you'd end up with a higher number than before for the maximum 13:49
arnsholt Which is the correct answer
AlexDaniel I know, I see why it does that 13:50
timotimo you could potentially be annoyed that it returns something that isn't an element of the list
but we do this for all(?) reduction-like things
masak I always think of max() as a number that *wants* to be as low as possible, but is forced upwards by elements in the list. no elements -- it can go all the way down to -Inf, like it has always dreamed of 13:51
arnsholt Yeah, that's a nice analogy
AlexDaniel okay, whatever, let's talk about this:
masak of course, that's also just a visceral way to express "-Inf is the unit of max()"
AlexDaniel m: say max NaN, Inf 13:52
camelia rakudo-moar 08710a: OUTPUT«NaN␤»
AlexDaniel m: say min NaN, Inf
camelia rakudo-moar 08710a: OUTPUT«Inf␤»
masak AlexDaniel: excellent question. :)
AlexDaniel that wasn't a question, but yeah. Why is it so?
masak AlexDaniel: somehow I don't feel NaN should be counted at all in max() and min() 13:53
arnsholt My gut-reaction is basically "Oh no, NaNs!" =)
masak AlexDaniel: the asymmetry you're seeing is because comparisons with NaN always yield False
AlexDaniel masak: either that or the answer should be NaN in both cases…
masak AlexDaniel: which gives the wrong answer for max but the right one for min
AlexDaniel ohhh, right
masak AlexDaniel: please submit a rakudobug! :D
timotimo we should obviously use the opposite comparison function for those
rather than negating the result
masak I think we should just filter out NaNs 13:54
timotimo could also do that
AlexDaniel m: say max NaN, Inf, -Inf
camelia rakudo-moar 08710a: OUTPUT«NaN␤»
AlexDaniel m: say min NaN, Inf, -Inf
camelia rakudo-moar 08710a: OUTPUT«-Inf␤»
masak NaN doesn't have a scalar magnitude that you can compare in a min/max operation
arnsholt Yeah, I think that sounds reasonable
masak that's what it means to not be a (real-valued) number! 13:55
arnsholt Although I'm generally wary about making pronouncements about anything involving NaNs, as they're generally a bit counter-intuitive
timotimo yeah, just like NULL in SQL
arnsholt That was exactly my follow-up comment! 13:56
Just like nulls in ternary logic
timotimo "dunno" 13:57
13:57 vendethiel joined
arnsholt Yeah, you need to properly internalize the logic of how the various values interact 13:57
masak that's the problem with "safety vent" values like NaN and NULL and Nil and Failure. they're very useful when you do want to express failure, but (being naturally "sad paths") they tend to slip from people's minds when constructing the happy path, and show up as confusing/unexpected behavior 14:00
14:01 Ven left
masak the solution, of course, is Option types. also known as the Maybe monad. but that's a pattern that can't be applied partially, or after the design of the rest of the language. 14:01
moritz so, let's design Maybe[Perl 6] 14:03
pmurias it should be mostly possibly as a slang 14:04
AlexDaniel m: my @a = NaN, Inf, -Inf; say NaN ~~ @a; say NaN == any(@a)
camelia rakudo-moar 08710a: OUTPUT«False␤any(False, False, False)␤»
AlexDaniel m: my @a = NaN, Inf, -Inf; say NaN === any(@a) # this works
camelia rakudo-moar 08710a: OUTPUT«any(True, False, False)␤»
14:04 M-eternaleye joined
AlexDaniel m: sub min(*@a) { return ‘Oh no, NaNs!’ if NaN === any(@a); max @a }; say min 3, 5 14:05
camelia rakudo-moar 08710a: OUTPUT«5␤»
AlexDaniel m: sub min(*@a) { return ‘Oh no, NaNs!’ if NaN === any(@a); max @a }; say min NaN, 5
camelia rakudo-moar 08710a: OUTPUT«Oh no, NaNs!␤»
AlexDaniel # ideas for Acme::NaNs 14:06
14:06 prammer joined
AlexDaniel notice how it returns a string, which makes it even funnier 14:07
14:13 M-matthew joined, M-Illandan joined
lizmat m: use nqp; say nqp::isconcrete(NaN) # why not make that return 0 ? 14:13
camelia rakudo-moar 08710a: OUTPUT«1␤»
14:19 Actualeyes joined
[Coke] fyi, 6.c is not a tag, it's a branch, specifically so we can add errata. 14:19
Feel free to change that.
arnsholt lizmat: NaN isn't a type object, so probably not a good idea 14:20
jnthn lizmat: Because isconcrete is an operation on objects, and NaN will be boxed to an instance
14:21 Ven joined, uruwi left
jnthn Also, isconcrete is *really* low level (and needs to be) 14:21
nine Someone at work just suggested using this slack thingy. Seems like I'll have to have a look at it afte all.
jnthn nine: Same at mine, but I avoided getting roped in so far ;)
arnsholt It's basically IRC for the enterprise, isn't it?
jnthn Something like 14:22
14:26 apiw left 14:28 sufrostico joined
mspo same at my work 14:31
14:31 uruwi joined
mspo isn't this how git was adopted? 14:31
AlexDaniel except that git was not proprietary? 14:33
nine If it's even remotely like IRC, it won't help us a bit as it helps nothing with which part of which customer feedback is processed by whom and what the status is. IOW it won't give us project management.
mspo nine: it's just another chat client that supports some /commands 14:34
nine: you can also post to it via curl 14:35
perlpilot I thought the appeal of slack was that it gave us visibility to a larger audience.
mspo so far the appeal has been "it works better on my phone"
perlpilot that too :) 14:36
nemo mspo: funny. I do most of my IRC on my phone using connectbot ☺ 14:38
but I guess I'm a bit of a relic
I'm pretty sure there are phone friendly setups using relays tho 14:39
mspo nemo: in my case it's vs jabber
nemo can ask my friends
14:39 nige1 joined
mspo and so far all xmpp phone apps have sucked 14:39
nemo AlexDaniel: it's funny. git isn't proprietary, but the main reason git dominates now is entirely due to the 100% proprietary github which standardised on git and nothing else
geekosaur (xmpp sucks, tbh)
mspo they can't seem to keep up with a 700+ list of people online or whatever
nemo AlexDaniel: open source world is crippled every time github goes down or gets blocked
mspo git was adopted due to loud mouth agitators in various companies 14:40
like most technology- it's entirely trend-based
FROGGS though one could say that the github user interface is quite nice 14:41
ugexe github hit the sweet spot with functionality + UI
nemo *shrug*
I don't use it enough to appreciate it
ugexe but now stagnate
nemo I know it is totally unusable in my tmux session
perlpilot
.oO( git was adopted because the best open source software at the time was subversion and it sucked for merging )
mspo github?
14:41 apiw joined
nemo luckily I recently learned of some commandline tools to help w/ their lack of familiarity w/ progressive enhancement 14:41
mspo git also sucks at merging since it still uses merge3 and can corrupt files :) 14:42
nemo github.com/git-commands/
mspo: I just find git profoundly unintuitive for a DVCS, and much prefer mercurial - actually I use mercurial as an interface to git which helps
14:42 vendethiel left
mspo tahoe-lafs.org/~zooko/badmerge/con...ntics.html 14:43
FROGGS I prefer git over svn for a single reason: you cannot push while you are not on latest
nemo mspo: but there's also the problem w/ DVCS in general. At work made some effort to switch and it would have required significantly more user training and fragmenting the repo
mspo nemo: it's hard to use; I don't think anyone denies that
nemo FROGGS: well... you can keep a local svn repo if you want
but that's admittedly convoluted
FROGGS: although. why would you not want to update to latest? 14:44
FROGGS nemo: I want all hackers to be forced to pull before pushing stuff
nemo bitquabit.com/post/unorthodocs-aba...to-sanity/ This probably sums up the situation at work
FROGGS nemo: git enforces that, svn doesnt
arnsholt nemo: Didn't they make local SVN repos significantly more git/hg-like in one of the more recent versions?
ISTR reading about that
nemo arnsholt: there's only one .svn dir
arnsholt: but it is still is not a DVCS 14:45
arnsholt Sure, sure
nemo arnsholt: the mapping between svn and hg is a lot better than between git and svn I learned tho, from my efforts at setting up a proxy
timotimo nemo: really, you prefer mercurial to git? last few times i tried to use mercurial, it drove me MAD. i ragequit working on an open source project because i just couldn't cope with the bullshit that mercurial did
i realize it's probably just personal preference, but ...
nemo shrugs
timotimo: funny. I have 'sact same reaction every time I'm forced to use git ☺ 14:46
timotimo da-yum.
nemo also. ♥ hg grep --all
timotimo like, i accidentally commited stuff to the wrong branch
i was advised to just throw away the repo and clone it afresh
arnsholt But I guess we can all agree to hate SVN? =)
nemo O_o
timotimo: what? that's just stupid
timotimo and the other devs keep a fresh clone around locally for making fresh clones easier
nemo who told you that
timotimo i think it was when i worked on pypy, or perhaps it was when i was working on xmms2?
nemo shrugs 14:47
timotimo (i contributed only tiny amounts to either of those projects)
colomon is okay with svn, but slowly transitioning his personal repos over to git.
timotimo but the amount of force mercurial applies against you when it thinks you're going to do something you don't want to ... is impressive
arnsholt colomon: After a long time away from SVN, going back to it drove me completely nuts
Figuring out how to use git-svn saved me a lot of hair-pulling
timotimo git is so much nicer in that regard
</rant> 14:48
nemo timotimo: hm. not too sure what you mean by that, but, yeah, I find git commands to be unintuitive and unnecessarily convoluted. I can explain to a graphics designer how to handle svn pretty trivially
mercurial w/ a little more effort
git. lol.
talk about throwing away local clone and recreating
arnsholt Yeah, the UI of git is atrocious. Just a complete mess
timotimo yeah, kind of
nemo UI and commandline
but the fun rant at the url I posted above kinda covers that too 14:49
timotimo but at least it lets me do shit i want to do, rather than trying to prevent me from doing shit i want to do
14:49 brrt joined
colomon arnsholt: the nice thing about svn is I mostly understand it all. after six years of using git I still routinely google for “how to X in git”. 14:49
arnsholt: but I definitely like git better.
nemo colomon: yeah. that's what I loved about mercurial. if I wanted to use it like svn, it would not stop me
jnthn Odd, git is the first version control system where I feel I understand what's going on inside of it :)
nemo colomon: that's probably why the svn repo maps so well to it
colomon: in fact most commands are same apart from the DVCS aspects 14:50
and ofc svn was same as cvs
jnthn It's just a DAG where each node points to a tree, and a set of tools to manipulate those data structures. :)
arnsholt I'm not sure I understand how git works, but after some years in Perl 6 land, I've learned how to do pretty much all the tasks I've come to want
timotimo yeah, that's what i like about git
nemo see? obvious. no problem teaching that to a graphics designer
timotimo every feature really comes down to that DAG kind of deal
nemo
jnthn Yeah, DAGs and trees are just about impossible to visualize. :P 14:51
brrt o.O
arnsholt nemo: Yeah, I wouldn't *dream* of foisting git on non-technical people
timotimo yeah, it's really bad because trees aren't anywhere in our real reality
brrt sarcasm detector initialisation process incomplete 14:52
nemo arnsholt: mhm. Mercurial at least has a shot, but, yeah, when I investigated work repo, I wasn't about to foist 20 gigabyte clones on people
timotimo hey brrt :3
nemo arnsholt: and there was like 0 advantage to fragmenting the repo
brrt could not open file: /usr/share/sarcasm
jnthn brrt: Yes, I was doing sarcasm. Always dangerous on IRC :)
brrt :-)
nemo arnsholt: obv the situation in FOSS is different
arnsholt Yeah, with existing stuff there's a high cost to moving
brrt i was not seeing it at first
jnthn All that said, I agree the git command line interface is horribly inconsistent
arnsholt I still remember Parrot's move from SVN to git...
jnthn Some things use subcommands. Some don't. grmbl. 14:53
jnthn has created a branch called "delete" a rew times :)
*few
mspo arnsholt: how did it go?
arnsholt Well, it happened in the end =)
brrt aye.. and i don't think it's likely a): that anybody will fix it b): that anyone will switch to another system by the virtue of a consistent command line
mspo fossil is nice 14:54
brrt therefore, we will be stuck with git for some time :-)
arnsholt brrt: Not to mention that fixing it will mean breaking absolutely all of the things
From scripts to people's muscle memory
brrt interesting how that works
14:55 apiw left
nemo brrt: I just use an hg-git bridge and call it a day 14:55
nine jnthn: our trees are completely incomprehensible for the layman because the latter thinks trees grow bottum up, while we all know that the root is on top. I don't know how we could fix this common misconception.
hoelzro mspo: I've been thinking about trying to use Fossil more
brrt is thoroughly confused now 14:56
hoelzro I think an alternative frontend to Git that just uses git's plumbing would be welcome
smooth over some of those interface issus
mspo hoelzro: it's really good for "personal stuff" since it self-hosts the entire project (bugs, website, and code)
brrt also, for pedantry's sake, trees grow on both ends
hoelzro: will never work
mspo hoelzro: but only about 1/100 people have heard of it
hoelzro brrt: why not?
nemo mspo: I've heard of it
mspo tig is an alternative interface to git
jast there are plenty of alternative frontends to git
nemo 1/100 in what community? 14:57
hoelzro mspo: it definitely has an appeal
oh, tig is very nice
ugexe (the official github ui for windows is actually good)
arnsholt A well-designed porcelain to git might work. But there's the inertia problem
brrt because there will be $feature that is not in $frontend but in git and $organisation requires its use
or $workflow, for that matter
mspo tortoisesvn is the best interface I've seen
hoelzro so if a feature isn't in $NEW_INTERFACE, use regular git for that feature
look at me, advocating a non-existent $NEW_INTERFACE =P
brrt in which case folks will have to learn both interfaces and forget about $glossy-interface 14:58
hoelzro I see what you're saying
brrt there is a reason why the porcelain-space is much more fluxy than git core
actually, i'm also kind of wrong
14:58 khw joined
brrt lots of kids use whatsitcalled... sourcetree and never learn the first thing about git command lines 14:59
14:59 hexhaxtron_ joined, zakharyas left
peteretep the time I spent really getting to grips with the git object model has been rewarded many many times over 14:59
My use of the porcelain is still pretty basic
jast git isn't very beginner-friendly, but it's extremely expert-friendly 15:00
nemo yeah. that's probably why I prefer mercurial. I just don't have the desire to be a VCS expert
and svn
jast to be fair, though, all the most common things aren't actually difficult in git, just the edge cases
[Coke] -i- remember parrot's move from cvs to svn!
nemo also. dislike social coding and sites that require a full browser to operate, so probably will never be a big github person which is the other big reason to use git 15:01
[Coke] (i'm kidding, that was actually too long ago. but I'm pretty sure I was around)
brrt hmm... i'd argue that git expert ness isn't actually that different from good-grasp-of-cs
jast there is some overlap, definitely
mspo jast: I think the main issue is how easy it is to screw up
brrt therefore the investment in being a 'git expert' is pretty small for most, which also explains its uptake
nemo brrt: ok. minor minor example. in svn and mercurial, coworker commits something, I pull/update, I want to know what they changed, I'd type hg diff -c revision or svn diff -c revision
[Coke] we are actually moving a bunch of dev teams here from * to git... and I'm basically going to force the gitflow workflow on them, so they don't hurt themselves.
brrt git log -p 15:02
nemo brrt: any git person I talked to would tell me. duh, that obviously won't give you the last set of changes
15:02 hexhaxtron_ left
brrt -p for 'patch' 15:02
nemo there's no imposed linear history like in those 2
brrt: and yeah, they gave me the commands, but again, diff -c was something I was familiar w/
brrt no.. that is by design :-)
jast git diff <old commit>. simple.
nemo I didn't want to learn a whole new set of commands
brrt git diff HEAD~1
jast pretty much identical
brrt oh come on.. that is unreasonable
things change
nemo brrt: they don't have to. the mercurial guys made the effort. that was nice of 'em 15:03
15:03 domidumont joined
brrt lots of people have made the effort to porcelain git so that it looks like svn 15:03
nemo brrt: obviously they change some. had to learn some new stuff when cvs appeared, then svn, but it was a lot more incremental 15:04
brrt: going from rcs to cvs to svn to hg has been a lot smoother a transition
aaand to hg-git
brrt hmmm
nemo brrt: also... does git have anything like hg grep --all ? 'cause I use that alllll the time
brrt i can't really judge from my keyboard
mspo git grep
nemo mspo: no
brrt dunno what the --all flagdoes
timotimo brrt: i always git log -u, for --unified; didn't know about -p 15:05
nemo mspo: git grep doesn't search history
brrt i always use gitk
nemo mspo: at least, I couldn't find any flags for it
gave up after 5m which is typical for me in git man pages
jast timotimo: they're exactly equivalent
brrt but in *general*, i think - no offense meant - that this is an unproductive discussion
i mean, i can't make you like git
jast and you can't make me *not* like git :} 15:06
brrt i'd suggest that it is a reasonable investment of time, given that it gives you great power and flexibility and reliability, even
but if you don't feel that way, fine :-)
jast fwiw the #git channel tends to be helpful 15:07
15:07 apiw joined
timotimo nemo: i think what you refer to with hg grep --all is git log --pickaxe 15:07
or what it's spelled
mspo nemo: git grep $firstcommit.. should probably do it 15:08
15:08 ivo_dev joined
mspo nemo: but you need to figure out the $firstcommit hash to do some kind of treeish 15:08
jast pickaxe actually only returns commits that add or remove that particular string, not the commits in between
nemo timotimo: hm. will try that out
dalek c: 53de585 | (David Brunton)++ | doc/Type/Supply.pod:
link to Block

Was displaying the link instead of linking the display.
15:09
c: 0604745 | (Zoffix Znet)++ | doc/Type/Supply.pod:
Merge pull request #390 from dbrunton/patch-7

  link to Block
15:09 ivo_dev left
arnsholt Pickaxe greps in the *diffs" of the commits which is sort of, but not exactly the same. mspo's solution is probably the closest option 15:09
jast no, it greps in the diffs, *minus* context lines 15:10
arnsholt (Reading the manpage, since I was't familiar with pickaze)
jast git grep doesn't traverse history AFAIK
arnsholt Well, it's still not exactly the same, since it'll match removed lines too
git grep can take a list of commits to grep in as well
15:10 brrt left
arnsholt So there's no convenient alias like --all to grep in all of the history, but it can do it 15:11
15:11 domidumont left 15:13 apiw left
nemo arnsholt: also sounds like my habit of doing it as a quick dump of blame for a file by grepping just one or more files by glob would be tricky to do 15:14
arnsholt: since it would search for that string anywhere in a diff, not just a single file?
arnsholt Well you can restrict git log to a particular set of files as well 15:16
15:17 apiw joined 15:20 nige1 left 15:24 musiKk joined, nakiro left 15:25 uruwi left 15:30 apiw left, skids joined 15:35 brrt joined 15:36 domidumont joined, fireartist left 15:37 apiw joined 15:44 cdg joined 15:47 vendethiel joined
prammer regarding slack vs irc (from backlog) drewdevault.com/2015/11/01/Please-...slack.html 15:52
15:53 brrt left
timotimo it's good that we're using irc primarily for development and community, and only offer slack for people who want the extra coolness of slack 15:56
15:57 Ven left 15:59 Guest52031 left
xiaomiao slack is bad, please don't enable others to use it 16:00
xiaomiao suffers from it at work
perlpilot "slack is bad" is an over-simplification IMHO
xiaomiao perlpilot: it's shiny crap # better? 16:01
perlpilot entirely accurate, so yes :)
16:03 FROGGS left
perlpilot But, for instance, if we're trying to get people to adopt Perl (5 or 6) there's a group of people that would use slack, but not IRC. Sometimes these people are high enough up the technical ladder in their company that they can affect change and encourage adoption. IF we *only* did IRC, it would be hard to reach these people. 16:03
jnthn There's more than one what to chat... :) 16:04
16:04 gcole_ left
nemo FWIW, I asked koda what he uses for IRC, and he said colloquy which I guess is useless as a response for android users. 16:05
16:05 kent\n left, zakharyas joined
nemo appears to be iOS only 16:05
16:05 domidumont left 16:06 domidumont joined, gcole joined
skids
.oO(So far MS Lync has not been forced down our throats here at work, thank goodness)
16:08
16:08 vendethiel left 16:11 nekrodesk joined, nekrodesk left
xiaomiao chat on android ... that's a confusing concept 16:11
16:19 CurtisOvidPoe left 16:20 apiw left
timotimo hehe. 16:20
you can have an external keyboard hooked up to your android device, you know ... :)
16:20 ely-se left 16:22 uruwi joined
pmurias the perl6 slack channel is #perl6? 16:25
16:26 apiw joined
DrForr Uh, you have to get an invite from someone, I think. And it's a cluster of channels. 16:26
timotimo yeah, but we do have an invitation site that you can just put your e-mail address into to get an invite 16:27
16:28 Actualeyes left, Skarsnik joined
Skarsnik Hello 16:28
timotimo greetings Skarsnik 16:29
perl6.bestforever.com/ <- pmurias 16:30
16:39 apiw left 16:41 apiw joined 16:43 vendethiel joined 16:47 virtualsue joined 16:48 abaugher_ is now known as abaugher, gcole left 16:50 abaugher left, abaugher joined 16:53 pmurias left 16:55 nige1 joined
Hotkeys Morning perlers 16:56
Got here just in time to say morning
jdv79 barely 16:57
17:00 M-matthew left 17:01 M-matthew joined 17:03 musiKk left 17:05 domidumont left, vendethiel left
[Coke] S99:UGT 17:06
timotimo [Coke]: sorry, i haven't set up synopsebot yet 17:07
poke me about that again soon? :S
[Coke] %after 30m poke timotimo 17:08
17:08 apiw left
moritz now is "soon", no? :-) 17:09
stmuk_ does moar need an executable stack? linux grsecurity/pax doesn't seem to like it
timotimo moritz: ;) 17:10
stmuk_: i think we might need it for dyncall/libffi, but not for our JIT because those pieces are on the heap
17:10 prammer left 17:16 apiw joined 17:17 uruwi left
MadcapJake [Coke], any update on @perlhex? 17:19
17:20 uruwi joined 17:23 zakharyas left, gcole joined 17:24 vendethiel joined
jdv79 how can you run without a stack? 17:24
17:25 apiw left
timotimo jdv79: can't tell if sarcasm :) 17:25
17:25 rindolf left
jdv79 none 17:25
i've never heard of running without a stack 17:26
not moar. just in general.
timotimo well, the question was about "executable stack"
17:27 prammer joined
timotimo but AFAIK, the absolutely earliest stage of turning on a computer are about running on the CPU without access to the RAM, which first uses only registers and code from a ROM and then setting up the caches as ram-replacement 17:27
turning on a cpu*
ilmari jdv79: stmuk_ was asking about the stack being executable, not its existence 17:28
17:29 pmurias joined
timotimo non-executable stack can make abusing stack overflows a bit harder, but there's Return Oriented Programming, which nullifies that benefit again :( 17:29
17:30 nige1 left 17:31 apiw joined
jdv79 i read his question wrong. cool. 17:32
ilmari yeah, ROP defeats most kinds of non-executable-memory-based mitigations 17:33
e.g. W^X
17:34 SCHAAP137 joined
jdv79 how about don't overflow in the first place:) 17:35
stmuk_ don't use C you mean?
ilmari rewrite moarvm in rust!
jdv79 maybe. or be like djb.
stmuk_ a nutter :) 17:36
timotimo how much does ASLR help against ROP? i suppose if you have the application itself in a fixed location (because only libraries are relocated, right?) that part can still be abused without changing the shellcode?
jnthn It'd be interesting to know what exactly needs the executable stack. 17:37
17:37 prammer left, Vitrifur left
jnthn As timotimo said, I don't think it's the JIT. My *guess* would be that if anything actually needs it at all, it's for supporting callbacks from C code 17:37
17:37 prammer joined, Vitrifur joined
timotimo jnthn: and can't we still just place that stuff on the heap? 17:38
nemo ilmari: funny you should bring up rust
ilmari: did you ever read os.phil-opp.com/remap-the-kernel.html ?
it's stuff I've never really learned, but he made it super readable.
"Unfortunately stack probes require compiler support. They already work on Windows but they don't exist on Linux yet."
jnthn timotimo: The thing I'm talking about would be inside libdyncall or libffi 17:39
timotimo oh, damn
ilmari nemo: I haven't really looked much at rust at all, but I keep thinking I should 17:40
nemo ilmari: github.com/carols10cents/rustlings 17:41
can try right now!
ilmari: also. one neat thing about the rust docs, is that a lot of the code samples have run buttons to try 'em out immediately
ilmari: for example... doc.rust-lang.org/std/primitive.array.html hover over the code in a JS enabled browser and click Run 17:43
stmuk_ I saw one of the rust people speak at FOSDEM a year or two back and his slides were unreadable ... he said he had found a bug in rust generating them :)
17:44 vendethiel left
nemo heh. well, I've hung out here long enough to encounter bugs discovered when feeding stuff to the bot ☺ 17:44
stmuk_: aaand I'm sure some people out there debate the readability of perl6 too
me, I love 'em both
17:45 buharin joined
nemo I like having syntax to annotate the code. ♥ {} - for me, reading, oh, python, is like reading English without capitalisation or punctuation. 17:45
stmuk_ nemo: I meant the HTML of the slides was actually corrupted not just unreadable code
nemo ah 17:46
17:46 prammer left
Hotkeys this golf questioner is smart codegolf.stackexchange.com/question...e-day-list 17:46
outsourcing creation of a useful script
17:46 dakkar_ left
nemo hah 17:47
Hotkeys: I dunno. random playlists has always been something I used shellscript for
hardly seems worth even breaking out perl
Hotkeys I was gonna 17:48
because more rep
but idk
seems like actual effort
timotimo "You may not use builtins for array shuffling"
stmuk_ hmmm maybe Alpine Linux will alert about one of the tests under the moar 3rdparty stuff
Hotkeys oh I didn't see that timotimo
that's even worse
does pick(*) count as an array shuffle builtin 17:49
timotimo i would say so
Hotkeys m: my @a = 1..10; say @a.pick(*)
camelia rakudo-moar 08710a: OUTPUT«(8 2 7 5 3 6 4 10 1 9)␤»
Hotkeys :p
17:49 rindolf joined 17:50 apiw left
Hotkeys Yeah I'm not gonna bother with that one 17:51
not allowing builtins for shuffling is lame 17:52
17:52 pmurias left
timotimo m: my @a = 1..10; say @a.sort({rand}); 17:55
camelia rakudo-moar 08710a: OUTPUT«(1 3 9 10 2 8 4 6 5 7)␤»
timotimo ^- does this count?
Hotkeys heh
17:55 vendethiel joined
nemo timotimo: yeh. that's the JS option due to lack of builtin 17:56
that is.. [].sort(function(){ return (Math.random()-0.5) } 17:57
17:57 kent\n joined, kent\n left, kent\n joined
timotimo ah 17:58
Juerd So much typing...
timotimo well, my line actually does the schwartzian transform
Juerd function(), return...
timotimo Juerd: could also () => (Math.random()-0.5) instead 17:59
Juerd timotimo: I wonder if it can still be called that.
timotimo: Given ES6, yes.
timotimo i refuse to consider "no ES6 features allowed" valid as "programming javascript" 18:00
Juerd You're obviously not building websites for broad audiences then :P
timotimo there is babelify with es2015 preset 18:02
Juerd Yeah, currently we're not using any translator or minimizer
I think I'd like to use that, but on the other hand, not having sane line numbers would drive me mad.
18:05 pmurias joined 18:16 nebuchadnezzar left 18:17 vendethiel left, Laurent_R joined 18:19 vendethiel joined
Hotkeys can I map over an array with overlaps 18:19
ie take two values
timotimo there ought to be a "sourcemap" mode for browserify
Hotkeys but still go one at a time
two in the map* 18:20
timotimo that's exactly what rotor is for
gfldex m: my @a = 1..10; my @b = do for @a -> $x1, $x2 { $x1 + $x2 }; dd @b;
camelia rakudo-moar 08710a: OUTPUT«Array @b = [3, 7, 11, 15, 19]␤»
gfldex Hotkeys: ^^^
18:20 apiw joined
timotimo that's not what hotkeys wants 18:21
Hotkeys that's going two at a time
I know rotor
timotimo m: my @a = 1..10; my @b = do for @a.rotor(2=>1) -> $x1, $x2 { $x1 + $x2 }; dd @b;
camelia rakudo-moar 08710a: OUTPUT«Too few positionals passed; expected 2 arguments but got 1␤ in code at /tmp/w7VYzXk3IF line 1␤ in block <unit> at /tmp/w7VYzXk3IF line 1␤␤»
timotimo oops
m: my @a = 1..10; my @b = do for @a.rotor(1=>2) -> $x1, $x2 { $x1 + $x2 }; dd @b;
camelia rakudo-moar 08710a: OUTPUT«Array @b = [2, 2]␤»
Hotkeys m: [1,2,3,4,5].rotor(2=>-1).say
camelia rakudo-moar 08710a: OUTPUT«((1 2) (2 3) (3 4) (4 5))␤»
Hotkeys I know this
but like
if I change 2
with the mpa
I want that in the next iteration
I almost want a sequence
but I'm mutating
timotimo oh, so you're not getting read-write containers there
that's interesting
i think that ought to work 18:22
Hotkeys like
I want to use the previous value in the array
to do something to the current position
I know I could loop over it
18:23 uruwi left
Hotkeys and do like @a[$_-1] #`(code) @a[$_] 18:23
but I was wondering if there's a better way
timotimo maybe we ought to give all array-y things a bit of a look-over for read-write-ness
Hotkeys I don't know in what situation a mutatey, overlappy map would be useful 18:24
but I was hoping to use something like it for this golf question
timotimo we don't really pay for keeping the mutable containers around
Hotkeys !!! NOT THAT WE SHOULD OPTIMIZE FOR GOLF !!!
timotimo because they basically already exist
Hotkeys but
seems like it might be useful idk 18:25
18:25 nebuchadnezzar joined
timotimo oh btw, if you don't spell "is rw" or <->, you won't get rwness at all 18:25
m: for [1,2,3,4,5].rotor(2=>-1) -> $a is rw, $b is rw { }
camelia rakudo-moar 08710a: OUTPUT«Parameter '$a' expected a writable container, but got List value␤ in block <unit> at /tmp/noYMIYCqti line 1␤␤»
timotimo m: for [1,2,3,4,5].rotor(2=>-1) -> ($a is rw, $b is rw) { }
camelia ( no output )
timotimo m: my @a = [1,2,3,4,5]; for @a.rotor(2=>-1) -> ($a is rw, $b is rw) { $a += $b }; say @a
camelia rakudo-moar 08710a: OUTPUT«[3 5 7 9 5]␤»
timotimo oh, neat!
see, it does already work!
m: my @a = [1,2,3,4,5]; for @a.rotor(2=>-1) -> ($a, $b) { $a += $b }; say @a 18:26
camelia rakudo-moar 08710a: OUTPUT«Cannot assign to a readonly variable or a value␤ in block <unit> at /tmp/_bdl6iYhvU line 1␤␤»
timotimo m: my @a = [1,2,3,4,5]; for @a.rotor(2=>-1) <-> ($a, $b) { $a += $b }; say @a
camelia rakudo-moar 08710a: OUTPUT«Cannot assign to a readonly variable or a value␤ in block <unit> at /tmp/8we5DQIOgu line 1␤␤»
timotimo not without the "is rw" in there
that's bad for golf
i wonder if <-> ($a, $b) can be made to work like that sanely
18:27 sufrostico left
Hotkeys m: @a[$_] += @a[$_-1] for 1..@a 18:27
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/NwzGR2udp7␤Variable '@a' is not declared␤at /tmp/NwzGR2udp7:1␤------> 3<BOL>7⏏5@a[$_] += @a[$_-1] for 1..@a␤»
Hotkeys angry
18:27 leont joined
Hotkeys m: my @a = ^5; @a[$_] += @a[$_-1] for 1..@a 18:28
camelia ( no output )
Hotkeys m: my @a = ^5; say (@a[$_] += @a[$_-1] for 1..@a)
camelia rakudo-moar 08710a: OUTPUT«(1 3 6 10 10)␤»
Hotkeys oh that doesn't work either
oh
yes it does
timotimo m: my @a = ^5; say @a[$_] for 1..@a
camelia rakudo-moar 08710a: OUTPUT«1␤2␤3␤4␤(Any)␤»
timotimo yeah 18:29
Hotkeys m: my @a = ^5; @a[$_] += @a[$_-1] for 1..^@a 18:30
camelia ( no output )
18:30 Laurent_R left
Hotkeys m: my @a = ^5; say( @a[$_] += @a[$_-1] for 1..^@a) 18:30
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/zgYLXRWjvy␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/zgYLXRWjvy:1␤------> 3my @a = ^5; say( @a[$_] += @a[$_-1] for 7⏏051..^@a)␤»
18:30 abraxxa left
Hotkeys m: my @a = ^5; say (@a[$_] += @a[$_-1] for 1..^@a) 18:30
camelia rakudo-moar 08710a: OUTPUT«(1 3 6 10)␤»
Hotkeys kool
timotimo yah
m: my @a = ^5; say (@a Z+ flat(1,@a)) 18:31
camelia rakudo-moar 08710a: OUTPUT«(1 1 3 5 7)␤»
timotimo m: my @a = ^5; say (flat(0,@a) Z+ flat(@a))
camelia rakudo-moar 08710a: OUTPUT«(0 1 3 5 7)␤»
Hotkeys I'm not looking for just adding though
timotimo ah, that doesn't carry
Hotkeys just an example
gfldex m: my @a = 1..10; my @b; while @a[1] { my $x = @a.shift; my $y = @a[0]; @b.push($x+$y) }; dd @b; 18:33
camelia rakudo-moar 08710a: OUTPUT«Array @b = [3, 5, 7, 9, 11, 13, 15, 17, 19]␤»
18:34 leont left
Juerd m: say 1, * + ($ //= 2)++ ... 10 18:34
camelia rakudo-moar 08710a: OUTPUT«(1 3 6 10)␤»
Juerd m: say 1, * + ($ //= 2)++ ... 100 18:35
camelia rakudo-moar 08710a: OUTPUT«(1 3 6 10 15 21 28 36 45 55 66 78 91 105 120 136 153 171 190 210 231 253 276 300 325 351 378 406 435 465 496 528 561 595 630 666 703 741 780 820 861 903 946 990 1035 1081 1128 1176 1225 1275 1326 1378 1431 1485 1540 1596 1653 1711 1770 1830 1891 1953 2016 …»
Juerd :)
timotimo cool
hippie1 ow my brain
Juerd Nah, I don't like that it goes past 100 if it never matches it exactly :P
Other than that, yeah, cool.
18:35 hippie1 is now known as hippie
Juerd hippie: Want an explanation? :) 18:35
hippie Juerd: I'm fuzzy on the $ //= 2 part. Assuming //= is still defined-or, is $ some kind of mini state variable? 18:36
Juerd Yes, exactly that.
A variable without a name is still a variable in Perl 6. And it's implicitly a state variable. 18:37
timotimo a variable by any other name ... :)
Juerd Each bare $ is a separate state variable
I'm not fond of this feature because I don't like it when state is barely visible (I want to declare it, and give it a long name), but... since it's there, let's just use it :) 18:38
18:38 zakharyas joined
Juerd And it's quite okay for use in a list generator, I think 18:38
gfldex m: say 1, * + (state $long-name-for-Juerd //= 2)++ ... 100
camelia rakudo-moar 08710a: OUTPUT«(1 3 6 10 15 21 28 36 45 55 66 78 91 105 120 136 153 171 190 210 231 253 276 300 325 351 378 406 435 465 496 528 561 595 630 666 703 741 780 820 861 903 946 990 1035 1081 1128 1176 1225 1275 1326 1378 1431 1485 1540 1596 1653 1711 1770 1830 1891 1953 2016 …»
gfldex there you go 18:39
Juerd gfldex: Yeah, I know, but thanks anyway :)
hippie I think Perl 6's potential for golf-abuse is really going to give Perl 5 a run for it's $$$.
Juerd That ... 100 doesn't do what I expected it to do by the way :)
18:40 addison_ joined
Juerd So in real code, ... Inf might be a lot better :) 18:40
18:40 ggoebel16 joined 18:42 apiw left, ggoebel15 left 18:43 zakharyas left
Hotkeys hippie: it already does 18:44
18:44 M-eternaleye left, M-eternaleye joined
timotimo yeah, because perl6 refuses to try to intuit whether or not your generating code is monotonic or not 18:44
so you'll * > 100 instead
18:44 M-eternaleye is now known as eternaleye
Hotkeys the place where you have to initilize positionals is interesting 18:47
m: {[@^a[$_]*=floor @a[$_-1]/@a[$_]+1 for 1..^@a]}([5,4,12,1,3])
camelia ( no output )
Hotkeys m: {[@^a[$_]*=floor @a[$_-1]/@a[$_]+1 for 1..^@a]}([5,4,12,1,3]).say
camelia rakudo-moar 08710a: OUTPUT«[8 12 13 15]␤»
Hotkeys I would have thought
it would be in the for bit
like for @^a
but nope
18:48 apiw joined 18:51 firstdayonthejob left 18:52 patrickz joined, vendethiel left 18:55 vendethiel joined
timotimo i don't get what you mean, sorry 19:03
Hotkeys uh 19:05
so when you have a function and use the positional twigil ^ to declare variables
like
timotimo ah 19:06
Hotkeys yeah
19:06 FROGGS joined
Hotkeys I knew that you only need the twigil once 19:06
timotimo yeah, i think it wants to be earliest in a lexical sense
Hotkeys yeah
I didn't immediately assume that
so I did for @^a
timotimo right
Hotkeys and it got mad
but now I know
timotimo we don't do more than one parsing pass
Hotkeys fair enough
timotimo and when we see a lexical like $a, it has to be declared already, or we explode for you 19:07
Hotkeys lol
I also like abusing positionals
m: {(0,1,1,4,{$^b;$^d;3*$^c-$^a}...*)[0..$_]}
camelia rakudo-moar 08710a: OUTPUT«Use of uninitialized value of type Any in numeric context in block at /tmp/p5Xvb5qFHh line 1␤Use of uninitialized value of type Any in numeric context in block at /tmp/p5Xvb5qFHh line 1␤»
Hotkeys oops
m: {(0,1,1,4,{$^b;$^d;3*$^c-$^a}...*)[0..$_]}(10).say
camelia rakudo-moar 08710a: OUTPUT«(0 1 1 4 3 11 8 29 21 76 55)␤»
19:08 khagan left
Hotkeys a nice abuse I think 19:08
for golf purposes
timotimo i don't call that abuse
19:08 khagan joined
Hotkeys maybe abuse is the wrong word 19:08
taking advantage maybe
19:10 domidumont joined, prammer joined 19:13 uruwi joined, sufrostico joined 19:16 vendethiel left, kaare_ left 19:18 vendethiel joined 19:23 cdg left
timotimo for people not In The Know™, the lexicographic ordering can be surprising indeed 19:23
especially when you just turn a sub with two "human-readable" named positionals into $^foo and $^bar and then wonder what's going wrong 19:24
Hotkeys heh 19:25
I knew that they're organized by name 19:26
I just wasn't sure when they were 'initilialized'
er
i don't know what I was thinking when I typed that word
DrForr While I'm waiting for tonight's build, is there a way to use Perl6::Grammar on its own without invoking ::Actions, or at least let me add a Role that overrides them? I've looked at the existing pretty printers and they don't seem ery clean.
19:27 apiw left
Hotkeys A grammar on its own just produces some matches 19:27
it's like a big regex
so you could use it on its own
DrForr I'm aware of that, I wanted to replace the actions with my own.
Hotkeys do youmean without having an Actions class? 19:28
I'm not sure what you're askin 19:29
DrForr I want to override the existing Perl6::Actions wit my own.
*with
Hotkeys docs.perl6.org/language/grammars#Action_Objects
arnsholt DrForr: Should just be a question of calling .parse or whatever method you want without an :actions parameter 19:30
Hotkeys like this?
arnsholt++
arnsholt Remember that a grammar and its actions class aren't intrinsically linked beyond the fact that you're generally going to want to use them together
19:31 lokien_ joined
DrForr One would think so, but that doesn't appear to be the case here. Let me look at what I've written again thoug. 19:31
*though
Hotkeys I misread your question, sorry 19:32
I read Perl6::Grammar as just like
you asking about grammars in general
DrForr Also keep in mind that Perl6::Grammar and ::Actions are NQP.
Aaah, yeah, I did mean exactly Perl6::Grammar.
Hotkeys You still should be able to use it like any grammar
then again I don't know too much about NQP 19:33
so I might be wrong
DrForr Right, I wasn't on crack, Perl6::Grammar loads Perl6::World which requires a Block symbol from somewhere. Maybe there's an actual grammar{} block hiding in there. 19:36
19:36 apiw joined
Hotkeys hmm 19:37
19:39 kurahaupo joined
timotimo we need that to allocate Block objects to hold code references 19:39
you can look for find_symbol to see what parts in particular need that
DrForr There's already a prettyprinter with the serious limitation of not being able to handle phasers because of how it loads the grammar. I thought that if I could load the grammar on its own I could dispense with that limitation.
Looking now. 19:40
19:40 lokien_ left, nekrodesk joined
DrForr experimental, use, label, what I'd expect from "load from outside" stuff. And there's a mixture of tokens, rules and methods in the grammar code itself which could get icky. 19:42
Maybe I can override TOP or something, there's a method already added that does braiding. 19:43
dalek osystem: f14ba76 | RabidGravy++ | META.list:
Add Test::Util::ServerPort

See: github.com/jonathanstowe/Test-Util-ServerPort
19:44
DrForr Aha, overriding TOP seems to do something worthwhile, at least it doesn't throw the error I was getting.
RabidGravy that ^ is my second dumbest module, but I didn't want to waste the code that I was going to write anyway :) 19:47
19:47 firstdayonthejob joined
ilmari RabidGravy: nooo, that's racy! at least make (and prefer) a version that returns the bound socket, not the port number 19:49
hoelzro +1 to that
ilmari can't count the number of times the dancer and plack tests have failed at $ork because something else nicked the port number returned by Test::TCP
hoelzro makes me think of Test::TCP for Perl 5 - I would actually get random failures with TEST_JOBS>1
ilmari hoelzro: github.com/tokuhirom/Test-TCP/pull/48 19:50
hoelzro nice!
19:51 prammer left
hoelzro an alternative would be a callback that is guaranteed to fail or have bound the bound number once it's exited 19:51
RabidGravy Well for what I want I need the number to pass to a separate piece of software to over-ride it's default port
ilmari and github.com/plack/Plack/pull/550
hoelzro so if you have to pass it to a child process, you could use that
19:52 prammer joined
geekosaur if you have the socketm you can get the port 19:52
if you have the port, better hope the socket is where it's claimed to be
RabidGravy but then you can't start another server with the port
ilmari yes, ->sockport in perl5, I presume perl6's IO::Socket::INET has something similar
RabidGravy: unless it has a --sockfd argument or similar 19:53
19:53 firstdayonthejob left
hoelzro ilmari: it does, but iirc it's NYI 19:53
RabidGravy nope
hoelzro RabidGravy: nope to what? 19:54
ilmari hoelzro: there's a localport attribute, but it doesn't seem to get set when calling just .new(:listen)
hoelzro that's what I was thinking of
RabidGravy to being able to pass a file descriptor to an already opened socket
19:55 raiph joined
ilmari I don't know of anything that has that, but it would make race-free operation possible 19:55
hoelzro ah
systemd and inetd do something similar to that, don't they?
ilmari or you could make it bind to a random port itself and output it
arnsholt DrForr: Oh, if you're trying to do static analysis-like things, remember that the grammar will cheerfully try to execute compile-time constructs; which may not be what you want
19:55 leont joined
ilmari inetd passes the socket as stdin/stdout 19:55
hoelzro oh, right
ilmari not sure how systemd socket activation does it 19:56
RabidGravy nope to that as well
arnsholt And which may or may not require the actions to be supplied too, come to think of it
ilmari probably an environment variable
RabidGravy: nope as in "the server doesn't do that" or "that won't work"?
DrForr arnsholt: Yeah, I'm prety sure that's what I'm running into.
*pretty
hoelzro I think that my $port = get-random-port(); loop { start-child-with-port($port); last; CATCH { $port = get-random-port() } } should do an adequate job for most things, no?
RabidGravy the "server doesn't do that"
DrForr Replacing method TOP() seems to help a bit, but not quite enough. 19:57
arnsholt DrForr: Yeah, not unlikely, I think. Of course, what you *might* want to consider in this case is seeing if it would be possible to refactor/extend the grammar so that it can be run in a "static analysis" mode
Probably a non-trivial yak shave, though 19:58
raiph Hi #perl6. Is PERL6LIB no longer used in some/all scenarios? 19:59
yoleaux 02:33Z <awwaiid> raiph: Thanks for the comments, I've updated thelackthereof.org/Perl6_Colons
19:59 firstdayonthejob joined
hoelzro raiph: it should still work; 19:59
DrForr Nod. We'll need tooling like this eventually though, and I'd love to be able to instrument the grammar without having to assert that the code is compilable as well, through phasers.
20:00 musiKk joined
ilmari RabidGravy: actually, having something that implements the systemd socket activation protocol would probably be useful for a growing number of external servers 20:00
raiph hoelzro: Thanks.
arnsholt DrForr: Yeah, it might be a very useful feature to have. Might be useful to discuss it a bit with the chief Perl6::Grammar wranglers up front, though 20:01
They may know of subtle stumbling blocks and such, which can save you some time
20:01 prammer left 20:02 prammer joined
DrForr Yep. My primary goal is just to redecorate the grammar with a separate action tree, so I can do proper pretty-printing and such. 20:03
"just", he says.
RabidGravy ilmari, for reference this for a thing that needs to start up an instance of liquidsoap to test with and liquidsoap doesn't even have a command line switch to specify the port 20:05
20:05 prammer left
arnsholt DrForr: A simple matter of programming! =D 20:05
RabidGravy it has to be inserted into the first script it runs
ilmari RabidGravy: eww
RabidGravy all good fun, it can take more than one script as either a filename or literal on the command line and evaluates them in order to build the environment 20:09
but as far as I know it's the only software that does quite what it does
20:10 apiw left
DrForr Right now I'd settle for knowing how to pass a 'method MATCH(...)' with the proper signature. 20:10
dalek osystem: 4043373 | (Sterling Hanenkamp)++ | META.list:
Switch to META6.json for IO::Glob
20:12
20:12 buharin left, prammer joined 20:13 yqt joined, firstdayonthejob left
patrickz Is there a reason for the "v6.c" tag existing in the rakudo repo? That tag collides with the versioning draft of jnthn. 20:13
20:16 buharin joined 20:17 kamel joined 20:19 jercos joined
Hotkeys who here knows how to use the $ state var 20:19
looking to use it in {my$f=0;@^a.map:{$ =$_*($ div$_+1)}}([5,4,12,1,3]) 20:20
instead of $f
20:20 dupa joined
Hotkeys uh 20:20
I copied the wrong one
jercos m: {my$f=0;@^a.map:{$f=$_*($f+$_)div$_)}}([5,4,12,1,3])
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/_1xlUfdUEX␤Missing block␤at /tmp/_1xlUfdUEX:1␤------> 3{my$f=0;@^a.map:{$f=$_*($f+$_)div$_7⏏5)}}([5,4,12,1,3])␤ expecting any of:␤ statement end␤ statement modifier␤ …»
jercos erm, and I copied the wrong one too
haha
Hotkeys m: say {my$f=0;@^a.map:{$f=$_*($f div$_+1)}}([5,4,12,1,3]
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Qg1ex_E05D␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/Qg1ex_E05D:1␤------> 3a.map:{$f=$_*($f div$_+1)}}([5,4,12,1,3]7⏏5<EOL>␤»
Hotkeys m: say {my$f=0;@^a.map:{$f=$_*($f div$_+1)}}([5,4,12,1,3]) 20:21
camelia rakudo-moar 08710a: OUTPUT«(5 8 12 13 15)␤»
Hotkeys there
20:21 buharin left
Hotkeys that 20:21
20:21 espadrine left 20:22 molaf left 20:26 darutoko left
[Coke] has shared the keys with MadcapJake 20:29
twitter.com/perlhex/status/697519103322542083 20:35
Hotkeys m: :256(12345)
camelia rakudo-moar 08710a: OUTPUT«This call only converts base-256 strings to numbers; value 12345 is of type Int, so cannot be converted!␤(If you really wanted to convert 12345 to a base-256 string, use 12345.base(256) instead.)␤ in block <unit> at /tmp/kPFpkAqGlS line 1␤␤»
Hotkeys m: :256<12345>
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/2TLhC042Ne␤Radix 256 out of range (allowed: 2..36)␤at /tmp/2TLhC042Ne:1␤------> 3:256<12345>7⏏5<EOL>␤»
Hotkeys so angry
AlexDaniel Hotkeys: what characters did you expect beyond 36? :) 20:36
jnthn m: say :256[1,2,3,4,5]
camelia rakudo-moar 08710a: OUTPUT«4328719365␤»
20:38 sufrostico left 20:41 nekrodesk left 20:42 domidumont left
Hotkeys unrelated 20:42
does p6 have something akin to python's divmod
arnsholt What does divmod do? 20:43
Hotkeys in perl 6 speak 20:44
it returns $a div $b along with $a mod $b
I realize I could create it easily but I was wondering if there was a builtin
?p6> sub infix:<divmod> (Int:D $a, Int:D $b) {$a div $b, $a % $b}; my ($q, $r) = 11 divmod 3; say $q, say $r) 20:47
ugh
m: sub infix:<divmod> (Int:D $a, Int:D $b) {$a div $b, $a % $b}; my ($q, $r) = 11 divmod 3; say $q, say $r)
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/4IWW2Rzyr4␤Unexpected closing bracket␤at /tmp/4IWW2Rzyr4:1␤------> 3y ($q, $r) = 11 divmod 3; say $q, say $r7⏏5)␤»
geekosaur well, simulate it
Hotkeys oops
m: sub infix:<divmod> (Int:D $a, Int:D $b) {$a div $b, $a % $b}; my ($q, $r) = 11 divmod 3; say $q, say $r
camelia rakudo-moar 08710a: OUTPUT«2␤3True␤»
geekosaur (most CPUs do both operations at the same time, so it makes some sense to expose it) 20:48
Hotkeys why 'True'
[Coke] you have a comma not a semicolon
20:48 inokenty left
Hotkeys oh 20:48
m: sub infix:<divmod> (Int:D $a, Int:D $b) {$a div $b, $a % $b}; my ($q, $r) = 11 divmod 3; say $q; say $r
camelia rakudo-moar 08710a: OUTPUT«3␤2␤»
Hotkeys there we go
thanks
20:48 dbrunton joined
Hotkeys it could have a different name or maybe a pretty op like /% 20:49
idk
geekosaur do either jvm or moarvm actually have that kind of operation? not clear to me it's worth having divmod if it doesn't let you avoid doing the division twice 20:51
dupa why perl won't use wigs?
lizmat good *, #perl6!
dupa wsgi 20:52
b2gills m: my ($q, $r) = 11 .polyod: 3; say $q; say $r 20:53
camelia rakudo-moar 08710a: OUTPUT«Method 'polyod' not found for invocant of class 'Int'␤ in block <unit> at /tmp/0Z38OdT45p line 1␤␤»
b2gills m: my ($q, $r) = 11 .polymod: 3; say $q; say $r
camelia rakudo-moar 08710a: OUTPUT«2␤3␤»
Hotkeys not oh
oh
that's undocumented
but thanks 20:54
b2gills m: say now.polymod: 1,60,60,24,365 20:55
camelia rakudo-moar 08710a: OUTPUT«(0.443069219589233 37 55 20 51 46)␤»
Hotkeys i.imgur.com/lUwf7Yw.png :(
m: say Int.polymod.perl
camelia rakudo-moar 08710a: OUTPUT«Invocant requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/dlU4eJ98G_ line 1␤␤»
Hotkeys m: say &polymod.perl 20:56
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/fyYCZZ3cDq␤Undeclared routine:␤ polymod used at line 1␤␤»
Hotkeys m: Int.^find-method('polymod').perl
camelia rakudo-moar 08710a: OUTPUT«Method 'find-method' not found for invocant of class 'Perl6::Metamodel::ClassHOW'␤ in block <unit> at /tmp/w6YoqIDe2g line 1␤␤»
Hotkeys er
m: Int.^find_method('polymod').perl
camelia ( no output )
Hotkeys m: Int.^find_method('polymod').perl.say
camelia rakudo-moar 08710a: OUTPUT«method polymod (Int:D $: +, *%_) { #`(Method|52462000) ... }␤»
b2gills m: .say for Int.can('polymod')>>.signature 20:57
camelia rakudo-moar 08710a: OUTPUT«(Int:D $: +, *%_)␤»
b2gills No need to resort to .^find_method when .can is more useful (it can "find" methods that are implemented by FALLBACK) 20:58
20:59 TestTest joined
TestTest Hm 20:59
AlexDaniel What a shiny IRC client: designers.im/
Somehow I guess that it also has inline images: perl6.org/camelia-logo.png 21:00
yup
21:01 TestTest left, CIAvash left 21:03 uruwi left
jdv79 who is hanenkamp in here? 21:03
stmuk_ /j freebsd 21:05
oops
AlexDaniel I do agree that we have to support things besides IRC (TIMTOWTDI after all), but I don't understand why we should create a separate perl6 room in every existing chat system. Let's just bridge them all to this channel?
21:05 bazzaar joined, stmuk_ is now known as stmuk
bazzaar \o 21:06
Hotkeys AlexDaniel: #lojban does this
would be good
21:06 raiph left, prammer left
AlexDaniel Hotkeys: how many non-irc thingies do they have bridged? 21:07
21:08 inokenty joined
Hotkeys I think two 21:09
jdv79 there's too many comm channels these days... 21:10
bazzaar IMHO, I find that the 'How to get Rakudo Perl 6' page is not a good advert for those looking to try out perl 6.
21:12 apiw joined, geraud joined 21:13 dbrunton left, prammer joined, addison_ left 21:14 musiKk left
DrForr bazzaar: What turned you off about it? 21:14
timotimo AlexDaniel: as we grow more, it'll get really noisy in here if we bridge all everythings, eh? 21:15
21:15 apiw left
AlexDaniel timotimo: it'll get just as noisy as if everyone joined this channel in IRC 21:15
21:16 apiw joined 21:17 prammer left
bazzaar It seems to be a jumbled set of instructions first and foremost, never quite clear whether addressing Rakudo * or Rakudo compiler installation. 21:17
AlexDaniel We can create #perl6-offtopic or #perl6-2 or something if it gets really bad. And then we can bridge everything to these channels too!
Hotkeys Do we have other chat places?
AlexDaniel but until it is fine, let's not separate this channel into “slack perl6 room” and “irc #perl6”
I mean, while it is fine
Hotkeys Oh there's a slack?
AlexDaniel until it gets bad
Hotkeys Is there a slack module in the ecosystem yet 21:18
timotimo someone on the slack said "no" 21:21
Hotkeys Oh are you acting as the relay timotimo
Great now we don't need a bot
:p
21:21 nekrodesk joined, nekrodesk left
timotimo that was just from memory 21:22
Hotkeys Aw
21:22 addison joined
bazzaar Plus too much attempted on one page, I think. First page ought to be for newcomers to install Rakudo *, anyone else should click through to a different page with compiler installation details. 21:22
xenu so you also keep logs in your head
Hotkeys I might try my hand at making a module then
Because if we have a relay bot 21:23
It ought to be perl 6
flussence imo keeping #perl6 separate from the outside world is fine; we haven't had problems for lack of a direct line to the perl6 things on reddit/twitter/facebook 21:24
xenu bazzaar: perl6.org has simpler instructions
timotimo or github issue comments 21:25
xenu and probably newcomers will get to perl6.org, not rakudo.org
i think
timotimo do we have a proper link from rakudo.org to perl6.org? 21:26
it probably ought to have something
especially for newcomers who come to rakudo.org first before having ever seen perl6.org 21:28
bazzaar xenu: third line of Perl6.org section "Installing from Source" points the user over to the said Rakudo web page
21:29 dupa left, dolmen joined
bazzaar all very confusing! 21:29
b2gills I think that Rakudo Star needs to be prominent, and have something along the lines of "or you can get just the Rakudo compiler and build your own distribution from scratch" 21:30
AlexDaniel flussence: except that these are not irc-like
timotimo hm, how about we have a little widget on rakudo.org that shows a little timeline-like thing that shows what rakudo release, what rakudo star release, what we have a .msi for and what we have a .dmg for 21:32
21:32 ryan_ joined, sno left
Hotkeys flussence: I think it's more in reference to slack and other chats 21:33
timotimo since i have a graphics tablet nearby, i could totally whip something up in Paint
jercos So is there a clean reverse to :n[...]? It's fairly trivial to implement such a thing, but it seems like a language feature. :n(...) has .base, for example.
m: say :2(128.base(2)) 21:34
camelia rakudo-moar 08710a: OUTPUT«128␤»
jercos m: say :2[(-> $n is copy, $base {reverse gather while $n {take $n % $base;$n div= $base}})(128, 2)] 21:35
camelia rakudo-moar 08710a: OUTPUT«128␤»
Hotkeys Might want to use a bigger number :p
flussence m: say :16[97265465.polymod(16 xx *).reverse]
camelia rakudo-moar 08710a: OUTPUT«97265465␤»
bazzaar timotimo: that's good, it would help. Though the primary thing needs to be simple instructions to install Rakudo *, and not overly expose the newcomer to the compiler installation
Hotkeys Oh 21:36
21:36 nekrodesk joined
timotimo hm 21:36
Hotkeys m: 12345678910.polymod(256 xx *).reverse
camelia ( no output )
Hotkeys Can someone do that with say
It's a pain on mobile
timotimo well, on linux you still "grab tarball, configure, make install" 21:37
flussence m: 12345678910.polymod(256 xx *).reverse.say
camelia rakudo-moar 08710a: OUTPUT«(2 223 220 28 62)␤»
Hotkeys jercos:
The undocumented polymod saves the day again
jercos well yeah that's a cleaner deal... 21:39
21:39 prammer joined
Hotkeys Please to have documentation for polymod 21:39
jercos Hotkeys: it's in S32 21:40
Hotkeys (Someone who actually knows how to describe what it does because I don't)
Okay but
21:40 [particle]1 joined, mohae_ joined
Hotkeys It should be in docs.perl6.org 21:40
21:40 mattp__ joined
Hotkeys I'll look at doing a pull for it when I get home 21:40
21:40 risou_ joined
daxim how do I dynamically generate a `subset` type? what's the mop invocation? 21:40
21:40 apiw left 21:41 diego_k joined, mithaldu__ joined, DrParis___ joined, sQuEE` joined, peteretep_ joined 21:42 b2gills1 joined, mprelude_ joined
timotimo daxim: have a look at my ADT module 21:42
21:42 nebuchad` joined
timotimo it does that 21:42
21:43 kshannon_ joined, mkz joined, Brock joined
bazzaar how about camelia 'user' hand-held install, perl6 R* installs in your home dir, download this (the latest R*), open a terminal, cd to ... etc, run these commands, look out for failing tests, add perl6 / panda to your path like so, her's the REPL, run a perl 6 program like this, install an extra module like so .. etc 21:43
21:44 bhm joined, Rotwang_ joined
daxim Metamodel::SubsetHOW appears to be undocumented, is that intended? 21:44
21:44 apejens_ joined, apiw joined
lizmat daxim: probably not 21:44
moritz daxim: no; the whole MOP docs are just very incomplete
I tried to cover the parts that I used occasionally, but my energy and time was limited 21:45
skids Well, how fixed is the MOP api?
21:46 woolfy joined, woolfy left
moritz as long as it's not spectested, not very much 21:46
most parts aren't in the design docs either 21:47
21:47 DrParis___ is now known as parisba
moritz but, in practice, it changes little 21:47
skids It hasn't been through the sacred trials of bikesheddom either
21:47 nebuchadnezzar left, nebuchad` is now known as nebuchadnezzar 21:48 woolfy joined
moritz and that's a good thing 21:48
21:48 sQuEE left
moritz it's coherent, even if not always pretty 21:48
21:48 kurahaupo left, ribasushi left, mohae left, hacst left, sortiz left, pecastro left, awwaiid left, jsimonet left, anshin left, Rotwang left, clkao left, peteretep left, mkz_ left, risou left, mprelude left, bhm_ left, Woodi left, burnersk left, caasih left, apejens left, mattp_ left, b2gills left, exodist left, [particle] left, olinkl left, drforr1 left, DrParis__ left, kshannon left, mithaldu_ left, diegok left, Grauwolf left, haircode left, woolfy left, sQuEE` is now known as sQuEE, peteretep_ is now known as peteretep, nekrodesk left, mithaldu__ is now known as mithaldu_
skids Wow, threaten to bikeshed the MOP and look what happens 21:48
21:48 burnersk joined
jnthn :P 21:49
flussence
.oO( I thought nom *was* the bikeshedding )
dalek c: 2f4b6cc | (David Brunton)++ | doc/Type/Any.pod:
Any and all.

Looks like a copy/paste error.
c: bcb0fd2 | RabidGravy++ | doc/Type/Any.pod:
Merge pull request #391 from dbrunton/patch-8

Any and all.
moritz skids: woolfy had another disconnect two minutes prior :-)
21:49 hacst joined 21:50 Exodist joined, sno joined 21:51 ribasushi joined, pecastro joined, Woodi joined 21:54 anshin joined, jsimonet joined, yurivish left, drforr1 joined 21:55 Grauwolf joined, SCHAAP137 left, sortiz joined 21:56 caasih joined 21:57 olinkl joined 21:58 clkao joined, kamel left 21:59 addison left 22:01 skids left
daxim rakudo: use v6; BEGIN { Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee('Blob'), :refinement({$_.elems == 12}) ); } sub foo(Key96 $bar) { ... } 22:01
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tmpfile␤Strange text after block (missing semicolon or comma?)␤at /tmp/tmpfile:1␤------> 3ob'), :refinement({$_.elems == 12}) ); }7⏏5 sub foo(Key96 $bar) { ... }␤ expecting any of:␤ in…»
daxim rakudo: use v6; BEGIN { Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee('Blob'), :refinement({$_.elems == 12}) ); }; sub foo(Key96 $bar) { ... }; 22:02
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tmpfile␤Invalid typename 'Key96' in parameter declaration.␤at /tmp/tmpfile:1␤------> 3nt({$_.elems == 12}) ); }; sub foo(Key967⏏5 $bar) { ... };␤»
daxim where's my mistake? why is the type not available?
22:02 addison joined
[Coke] missing something compose like? 22:04
jnthn You didn't bind it anywhere 22:05
daxim how does that work?
jnthn Also refinee needs to be a type, not a type name
m: constant Key96 = Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee(Blob), :refinement({$_.elems == 12}) ); sub foo(Key96 $bar) { ... } 22:06
camelia ( no output )
jnthn m: constant Key96 = Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee(Blob), :refinement({$_.elems == 12}) ); sub foo(Key96 $bar) { ... }; foo([1]
camelia rakudo-moar 08710a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/LSSJI4kJZb␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/LSSJI4kJZb:1␤------> 3 ); sub foo(Key96 $bar) { ... }; foo([1]7⏏5<EOL>␤»
bazzaar imho, it's all very well having a butterfly designed to appeal, but the installation guide is for the system admin ... almost
jnthn m: constant Key96 = Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee(Blob), :refinement({$_.elems == 12}) ); sub foo(Key96 $bar) { ... }; foo([1])
camelia rakudo-moar 08710a: OUTPUT«Type check failed in binding $bar; expected Blob but got Array␤ in sub foo at /tmp/sIyq5K4rMY line 1␤ in block <unit> at /tmp/sIyq5K4rMY line 1␤␤»
jnthn Ah
22:06 spider-mario joined
jnthn m: constant Key96 = Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee(Blob), :refinement({$_.elems == 12}) ); sub foo(Key96 $bar) { ... }; foo(('x' x 11).encode) 22:06
camelia rakudo-moar 08710a: OUTPUT«Constraint type check failed for parameter '$bar'␤ in sub foo at /tmp/BkNeWjx7hE line 1␤ in block <unit> at /tmp/BkNeWjx7hE line 1␤␤»
jnthn m: constant Key96 = Metamodel::SubsetHOW.new_type( :name('Key96'), :refinee(Blob), :refinement({$_.elems == 12}) ); sub foo(Key96 $bar) { ... }; foo(('x' x 12).encode)
camelia rakudo-moar 08710a: OUTPUT«Stub code executed␤ in sub foo at /tmp/W8441W__nd line 1␤ in block <unit> at /tmp/W8441W__nd line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/W8441W__nd line 1␤␤»
jnthn There :) 22:07
daxim great, thanks!
assigning into a type identifier looks really weird to me
jnthn = on constant is binding really
You can write it as := if it makes you happier 22:08
22:10 Rotwang_ is now known as Rotwang, Rotwang left, Rotwang joined
[Coke] it's not a type identifier until you do that, if that makes you feel better. 22:11
lizmat m: sub a($a) { 42 }; for ^1000000 { a(666) }; say now - INIT now 22:12
camelia rakudo-moar 08710a: OUTPUT«0.2609628␤»
jnthn True...constant just introduces a symbol, up to you what you bind to it. :)
lizmat m: multi a($a) { 42 }; multi a($a,:$foo!) { 42 }; for ^1000000 { a(666) }
camelia ( no output )
lizmat m: multi a($a) { 42 }; multi a($a,:$foo!) { 42 }; for ^1000000 { a(666) }; say now - INIT now
camelia rakudo-moar 08710a: OUTPUT«0.34043487␤»
lizmat jnthn: don't you agree that these calls should be optimized to the same thing ? 22:13
jnthn lizmat: It'd be nice. 22:14
lizmat ok, so just a matter of NYI, right ?
jnthn lizmat: There's a couple of ways to do it: make spesh inlining better, or make static inlining better.
I suspect we'll get it through (a) 22:15
uh, through the first option
lizmat yeah, ok... I was just a bit taken aback by the difference in performance of "min @a" and [email@hidden.address]
trying to fix that with a multi, only made things worse 22:16
so giving up on that now
22:16 apiw left 22:17 bazzaar left, apiw joined 22:18 pmurias left, kamel joined
llfourn does anyone have an example of how to use %?RESOURCE 22:19
22:19 nebuchad` joined
Brock llfourn: I used it in Inline::Ruby somewhere, but I don't know how it worked... lemme see here... 22:20
llfourn nvm it's called %?RESOURCES apparently
Brock ah
22:20 Brock is now known as awwaiid
llfourn Brock: I think I got it >.< 22:20
it even works with -Ilib things which is good
awwaiid fancy 22:21
(had to change my nick back to the right one so our names line up better)
22:21 b2gills joined
llfourn d(o.o)b 22:22
22:23 b2gills1 left, camelia left, nebuchadnezzar left, camelia joined 22:24 ChanServ sets mode: +v camelia 22:26 apiw left
jnthn sleep & 22:27
22:30 Skarsnik left 22:32 apiw joined 22:36 spider-mario left 22:38 spider-mario joined
sortiz . 22:39
22:39 nekrodesk joined
diakopter . 22:39
22:40 Ulti_ is now known as Ulti 22:42 ryan_ left 22:51 vendethiel left 22:53 partly__ left 22:56 vendethiel joined 23:04 apiw left 23:11 prammer left
AlexDaniel 23:11
23:12 apiw joined, kid51 joined 23:16 RabidGravy left 23:18 vendethiel left 23:26 spider-mario left, dolmen left 23:30 vendethiel joined 23:31 ranguard left
timotimo i just heard about google summer of code "starting" in february; is that about "organizations can now apply for slots"? 23:32
MadcapJake anyone know what's going on with the fosdem videos? still nothing at video.fosdem.org 23:35
23:37 ocbtec left, Laurent_R joined
geekosaur timotimo, yes 23:37
"We are now accepting applications from open source projects interested in participating as mentor organizations for Google Summer of Code 2016."
23:40 skids joined, apiw left 23:43 bapa left 23:44 virtualsue left
MadcapJake What's this mean: video.fosdem.org/2016/h2214/STATUS.TXT 23:45
oh ok, at least they don't say `LOST` 23:46
MadcapJake doesn't understand how videos get lost at these kinds of things
23:47 kamel left 23:48 nebuchad` left 23:49 tardisx joined
timotimo MadcapJake: the number is still going up 23:49
i'm looking at the status.txt at least once a day 23:50
23:52 vendethiel left
jdv79 what will it take to get rid of the hashed filenames? 23:55
timotimo FROGGS: i wonder if you'd want to bring Archive::Tar back to good health?
leont geekosaur: why am I worried the parrot foundation may be more successful in being accepted than anyone relevant to us :-/ 23:56
jdv79 paste.scsys.co.uk/505241 looks like a mistake. and on a wrapping term it looks worse.
23:57 ranguard joined
timotimo leont: i mean no disrespect to the parrot devs, but looking at what they've been putting out in recent months/the recent year doesn't make it seem likely to me 23:57
leont I can remember that some 2-3 years ago they got in yet Perl foundation didn't 23:58
timotimo 2-3 years ago there was still activity, no? 23:59