»ö« 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.
mort96 hey 00:00
Ulti then the .grep(Even) worked the same as the .grep(Int) it found things which were of type Even which are Ints that also satisfy %% 2
mort96 I now have perl 6 installed :)
Ulti and Linux at the same time? :3
AlexDaniel m: my Int subset Even where * %% 2; my Even $x = 24
camelia ( no output )
AlexDaniel m: my Int subset Even where * %% 2; my Even $x = 25
camelia rakudo-moar a7ea8e: OUTPUT«Type check failed in assignment to $x; expected Even but got Int␤ in block <unit> at /tmp/JkT3TjxJm9 line 1␤␤»
herby_ Ulti, thats pretty dang cool
mort96 ya, /bin still exists
AlexDaniel herby_: ↑
mort96 _both_ perl6 _and_ system binaries 00:01
Ulti m: my Int subset Even where * %% 2; my Even subset SmallEven where * < 25; my SmallEven $x = 25;
camelia rakudo-moar a7ea8e: OUTPUT«Type check failed in assignment to $x; expected SmallEven but got Int␤ in block <unit> at /tmp/atZ_QnTGu6 line 1␤␤»
Ulti m: my Int subset Even where * %% 2; my Even subset SmallEven where * < 25; my SmallEven $x = 24;
camelia ( no output )
00:01 jcrespo__ left
Ulti you can see how it could eventually get crazy :S 00:02
herby_ hah yeah
Ulti herby_ you can use the where keyword in parameter lists too
so you can have multi dispatch on a method or function with those sorts of constraints
Skarsnik m: my Int subset Int where * > 42; my Int $a = 42; 00:03
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
Skarsnik m: my Int subset Int where * > 42; my Int $a = 43;
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
Skarsnik m: my Int subset Int where * > 42;
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
Skarsnik m: my Int subset Num where * > 42;
camelia ( no output )
Skarsnik that... not good x)
dalek c: 4f85dec | (Wenzel P. P. Peppmeyer)++ | doc/Language/objects.pod:
doc Mixins of Roles
00:04
c: e1d78ca | (Wenzel P. P. Peppmeyer)++ | doc/Language/objects.pod:
Merge pull request #276 from gfldex/master

doc Mixins of Roles
Ulti m: my Int subset Num where * > 42; Num $x = 43; say $x.^methods; 00:05
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/kgXjgpW3pZ␤Two terms in a row␤at /tmp/kgXjgpW3pZ:1␤------> 3my Int subset Num where * > 42; Num7⏏5 $x = 43; say $x.^methods;␤ expecting any of:␤ infix␤ infix stopper␤ …»
00:05 Andrew_Scone left
Ulti m: my Int subset Num where * > 42; my Num $x = 43; say $x.^methods; 00:06
camelia rakudo-moar a7ea8e: OUTPUT«(Int Num Rat FatRat abs Bridge chr sqrt base polymod expmod is-prime floor ceiling round lsb msb narrow Range sign sin tan cotan acosech conj atan2 cosec pred asec acotan cosh acos acosec sech unpolar log10 atanh log exp acosh truncate sinh tanh acotanh Re…»
lucasb creating a subset named Num should die earlier
Ulti m: my Num $x = 43; say $x.^methods;
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/FOyTnWzWGi␤Cannot assign a literal of type Int (43) to a variable of type Num. You can declare the variable to be of type Real, or try to coerce the value with 43.Num or Num(43), or just write the value as 43…»
lucasb m: subset Num of Int; say 'hi'
camelia rakudo-moar a7ea8e: OUTPUT«hi␤»
lucasb m: subset Num of Int; 1e1
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
Ulti yeah it does fail atleast 00:07
[Coke] I don't think 127050 is a bug, I think it's a DIHWIDT 00:09
yoleaux 27 Dec 2015 22:40Z <nine> [Coke]: yes, I'm quite sure panda will get an uninstall
Ulti m: my Int subset Prime where *.is-prime; say ^100.grep(Prime);
camelia rakudo-moar a7ea8e: OUTPUT«Potential difficulties:␤ Precedence of ^ is looser than method call; please parenthesize␤ at /tmp/tIbNh_HFxR:1␤ ------> 3 subset Prime where *.is-prime; say ^1007⏏5.grep(Prime);␤^0␤»
Ulti m: my Int subset Prime where *.is-prime; say (^100).grep(Prime);
camelia rakudo-moar a7ea8e: OUTPUT«(2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97)␤»
Ulti that *always* gets me
AlexDaniel m: say (^100).grep(*.is-prime); 00:10
camelia rakudo-moar a7ea8e: OUTPUT«(2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97)␤»
herby_ m: say (^1000).grep(*.is-prime);
camelia rakudo-moar a7ea8e: OUTPUT«(2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97 101 103 107 109 113 127 131 137 139 149 151 157 163 167 173 179 181 191 193 197 199 211 223 227 229 233 239 241 251 257 263 269 271 277 281 283 293 307 311 313 317 331 337 347 349 353 …»
Ulti m: say (^1000).hyper.grep(*.is-prime) 00:11
camelia rakudo-moar a7ea8e: OUTPUT«()␤»
00:11 virtualsue left
Ulti guess its still only fixed for map 00:11
m: say (^10).hyper.map(* + 1) 00:12
camelia rakudo-moar a7ea8e: OUTPUT«HyperSeq.new␤»
gfldex [Coke]: i'm fine with that not being a bug (i do like fast). But I need to know exactly where mixins break so I can properly document it.
Ox0dea m: say grep &is-prime, ^100 # herby_
camelia rakudo-moar a7ea8e: OUTPUT«(2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67 71 73 79 83 89 97)␤»
Ulti m: say |(^10).hyper.map(* + 1)
camelia rakudo-moar a7ea8e: OUTPUT«12345678910␤»
Ulti ahh
herby_ m: say (^100).grep(*.is-prime).map(* + 1) 00:14
camelia rakudo-moar a7ea8e: OUTPUT«(3 4 6 8 12 14 18 20 24 30 32 38 42 44 48 54 60 62 68 72 74 80 84 90 98)␤»
herby_ m: say (^100).grep(*.is-prime).map(* + 1).map(* %% 3)
camelia rakudo-moar a7ea8e: OUTPUT«(True False True False True False True False True True False False True False True True True False False True False False True True False)␤»
AlexDaniel m: say (^100).grep(*.is-prime).map(*.succ) 00:15
camelia rakudo-moar a7ea8e: OUTPUT«(3 4 6 8 12 14 18 20 24 30 32 38 42 44 48 54 60 62 68 72 74 80 84 90 98)␤»
herby_ what is that .succ?
Ox0dea herby_: The successor.
AlexDaniel m: say (^100).grep(*.is-prime)».succ
camelia rakudo-moar a7ea8e: OUTPUT«(3 4 6 8 12 14 18 20 24 30 32 38 42 44 48 54 60 62 68 72 74 80 84 90 98)␤»
herby_ as in, += 1?
AlexDaniel yes
herby_ wow
AlexDaniel pred is - 1
herby_ ok, thats cool
AlexDaniel m: say ^100 .grep(*.is-prime)».succ
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/3NlYWC395B␤Missing « or »␤at /tmp/3NlYWC395B:1␤------> 3say ^100 .grep(*.is-prime)».7⏏5succ␤»
AlexDaniel ouch
gfldex herby_: it's not just += 1 see doc.perl6.org/routine/succ 00:16
herby_ thats pretty neat, you can apply it to dates and filenames etc 00:17
Ox0dea m: say "z".succ # herby_
camelia rakudo-moar a7ea8e: OUTPUT«aa␤»
gfldex m: 'img001.png'.succ.say
camelia rakudo-moar a7ea8e: OUTPUT«img002.png␤»
Ox0dea That's neat.
herby_ m: DATE
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/iDoekKm5co␤Undeclared name:␤ DATE used at line 1. Did you mean 'Date'?␤␤»
herby_ bleh
can camelia tell me the current date? 00:18
Skarsnik m: say Date.today
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-28␤»
herby_ m: say Date.today.succ
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-29␤»
Ulti m: say DateTime(now)
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-28T00:18:38.125984Z␤»
Ulti need moar accuracy
AlexDaniel m: say now
camelia rakudo-moar a7ea8e: OUTPUT«Instant:1451261963.683468␤»
herby_ m: say now.succ
camelia rakudo-moar a7ea8e: OUTPUT«Instant:1451261971.057185␤»
Ox0dea m: say now.Date
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-28␤»
herby_ m: say now.Date.succ 00:19
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-29␤»
herby_ pretty neat stuff
m: say now.Date.succ.succ.succ
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-31␤»
herby_ m: say now.Date.succ.pred
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-28␤»
00:19 pneuma joined
herby_ where is camelia located? 00:19
where its the 28th already 00:20
Ulti m: say DateTime.now.day-of-week
camelia rakudo-moar a7ea8e: OUTPUT«1␤»
Skarsnik 1?
Ulti I was going to say that's wrong then I looked at the time :)
Skarsnik Oh yeah it's Monday
gfldex m: say DateTime.now;
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-28T01:20:46.857133+01:00␤»
herby_ say now.Date.month
AlexDaniel herby_: UTC is 28 actually
herby_ m: say now.Date.month
camelia rakudo-moar a7ea8e: OUTPUT«12␤»
herby_ m: say now.Date.month.succ 00:21
camelia rakudo-moar a7ea8e: OUTPUT«13␤»
gfldex +01:00 is central EU
herby_ gotcha
m: say Date.today.succ.succ.succ.succ.succ
camelia rakudo-moar a7ea8e: OUTPUT«2016-01-02␤»
herby_ m: say Date.today.month
camelia rakudo-moar a7ea8e: OUTPUT«12␤»
herby_ m: say Date.today.month.succ
camelia rakudo-moar a7ea8e: OUTPUT«13␤»
herby_ m: say DATEISH.is-leap-year(2016) 00:23
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/A9nAC0o5WZ␤Undeclared name:␤ DATEISH used at line 1. Did you mean 'Dateish'?␤␤»
gfldex m: say "I'm close to juniper2.rz16.hetzner.de"
camelia rakudo-moar a7ea8e: OUTPUT«I'm close to juniper2.rz16.hetzner.de␤»
herby_ m: DATEISH.year
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/d4UKn2TzKo␤Undeclared name:␤ DATEISH used at line 1. Did you mean 'Dateish'?␤␤»
ShimmerFairy herby_: camelia's most likely running on UTC, it became Monday about 20min ago
Ox0dea Who operates camelia?
herby_ ShimmerFairy, thanks 00:24
gfldex #perl6 camelia H+ 0 ~p6eval@ns1.niner.name
.seen niner
yoleaux I haven't seen niner around.
Ox0dea Hmm.
herby_ m: is-leap-year(2016) 00:25
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/5H5vUQrhU2␤Undeclared routine:␤ is-leap-year used at line 1␤␤»
herby_ what am I missing there. to check is a year is a leap year
ShimmerFairy m: say Date.^methods
camelia rakudo-moar a7ea8e: OUTPUT«(BUILD new-from-daycount today truncated-to later clone succ pred daycount day-of-month IO day-of-week days-in-month earlier week week-number is-leap-year week-year weekday-of-month yyyy-mm-dd day-of-year new WHICH Str perl ACCEPTS gist <anon> <anon> <anon…»
Skarsnik m: say Dateish.is-leap-year(2016);
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
Skarsnik Just read the error message x) 00:26
herby_ m: say Dateish.is-leap-year(2016)
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
herby_ lol
I'm a dummy
AlexDaniel m. say now.Date.is-leap-year
gfldex m: say Date.new(:2016year).is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
AlexDaniel m: say now.Date.is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«False␤»
AlexDaniel m: say now.Date.succ.is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«False␤»
herby_ the docs have DATEISH in caps, does that matter at all?
gfldex m: say Date.new(year => 2016).is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
Skarsnik Error in the docs then
AlexDaniel m: say now.Date.succ 00:27
camelia rakudo-moar a7ea8e: OUTPUT«2015-12-29␤»
AlexDaniel m: say now.Date.succ.is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«False␤»
00:27 llfourn joined
AlexDaniel I don't get it 00:27
Skarsnik succ inc on day
AlexDaniel aaa
dammit, looking at the wrong number
herby_ m: say now.Date.succ.succ.succ.succ.succ.is-leap-year 00:28
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
herby_ :)
AlexDaniel m: say now.Date.later(:1year).is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
AlexDaniel m: say now.Date.later(:10days).is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
Ox0dea m: 1.+(1)
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/r80bvQTxpK␤Cannot use .+ on a non-identifier method call␤at /tmp/r80bvQTxpK:1␤------> 031.+(1)7⏏5<EOL>␤»
AlexDaniel m: say Date.today.later(:10days).is-leap-year
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
Ox0dea Why not?
dalek c: 77546e0 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Dateish.pod:
s/DATEISH/Dateish/g
c: 04a80a2 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Dateish.pod:
Merge pull request #277 from gfldex/master

s/DATEISH/Dateish/g
herby_ say Date.today.later(:5days) 00:29
m: say Date.today.later(:5days)
camelia rakudo-moar a7ea8e: OUTPUT«2016-01-02␤»
herby_ yeah, thats pretty dang handy to have all that
ShimmerFairy herby_: that syntax is short for :days(5), which itself exists so s:2nd/a/b/ could work nice :) 00:30
(er, s/itself//, not sure what that's doing there :P)
herby_ ShimmerFairy, could you give an example? Not sure what you mean
ShimmerFairy m: say "foo" ~~ S:1st/o/a/ 00:31
camelia rakudo-moar a7ea8e: OUTPUT«Potential difficulties:␤ Smartmatch with S/// can never succeed because the subsequent string match will fail␤ at /tmp/YasAtdeVwq:1␤ ------> 3say "foo" ~~ 7⏏5S:1st/o/a/␤False␤»
ShimmerFairy m: say "foo" ~~ s:1st/o/a/
camelia rakudo-moar a7ea8e: OUTPUT«Cannot modify an immutable Str␤ in block <unit> at /tmp/xj2MgEhWmA line 1␤␤»
Ox0dea Jeeze.
ShimmerFairy m: my $a ="foo"; $a ~~ s:1st/o/a/; say $a
camelia rakudo-moar a7ea8e: OUTPUT«fao␤»
gfldex S02: "For identifiers that take a non-negative integer argument, it is allowed to abbreviate, for example, :sweet(16) to :16sweet. (This is distinguishable from the :16<deadbeef> form, which never has an alphabetic character following the number.) Only literal non-negative integers numbers may be swapped this way. Please note that this abbreviation allows:"
00:31 llfourn left
herby_ wow ok, i see now 00:31
Ox0dea herby_: It's just `Date.today + 5` in Ruby, mind. :P
(But ignore me.) 00:32
herby_ no, I'm all about these little tidbits
ShimmerFairy m: my $a ="foo"; $a ~~ s:2st/o/a/; say $a # and yes, we don't really check that the number matches the ordinal suffix :P
camelia rakudo-moar a7ea8e: OUTPUT«foa␤»
AlexDaniel Ox0dea: what about months?
Ox0dea AlexDaniel: Hm?
AlexDaniel Ox0dea: in ruby I mean
herby_ ShimmerFairy, thats pretty handy
ShimmerFairy herby_: sure, I just wanted to pre-emptively answer a "what even is this?" question :)
Ox0dea AlexDaniel: Still not clear what you're asking? 00:33
You can say `Date.today.next_month(6)` to fast-forward half a year.
AlexDaniel ah ok
00:34 camelia left
herby_ m: my $a = "foo"; $a ~~ s:2st/o/bar/; say $a; 00:34
Ox0dea Weird.
herby_ come baaaack
Ox0dea nine: Y U DO DIS?
lucasb oops, I was evaluating something... have I killed her?
ShimmerFairy herby_: unless I'm horribly mistaken, we have all the suffixes for english ordinals for regexes there (so, :st, :nd, :rd, :th), but the "general" form is :nth, which can be clearer in cases like :nth($x) or whatever :)
lucasb: did you try to invoke nqp-p by accident? 00:35
lucasb just 'nqp' :)
is that trouble? /o\
Ox0dea ShimmerFairy: Is it "zeroth" or "zeroeth"?
00:35 camelia joined
herby_ m: my $a = "foo"; $a ~~ s:2st/o/bar/; say $a; 00:35
ShimmerFairy lucasb: yep, that calls nqp-p along with -j and -m. Then dies :P
lucasb ah, good :)
Ox0dea m: say "I'm alive!"
herby_ she isn't happy about being booted
ShimmerFairy Ox0dea: I can't recall, it's been a while since I touched on my Lingua::En::Numbers::Ordinal thing 00:36
(but I did look it up when I made that module)
lucasb ShimmerFairy: thanks for the tip. I thought 'nqp' was alias for just 'nqp-m' :)
00:36 ChanServ sets mode: +v camelia
camelia rakudo-moar a7ea8e: OUTPUT«fobar␤» 00:36
rakudo-moar a7ea8e: OUTPUT«I'm alive!␤»
Ox0dea She lives!
ShimmerFairy lucasb: yeah, it's weird it hasn't been disabled yet 00:37
"it" being "nqp parrot" :P
herby_ m: my $a = "foobar"; $a ~~ s:2nd/o/hello/; say $a;
camelia rakudo-moar a7ea8e: OUTPUT«fohellobar␤»
herby_ alright, i'm out. thanks for the tips and tricks! 00:38
lucasb nqp-m: oh-hai-there; say('alive') # I was testing this
camelia nqp-moarvm: OUTPUT«alive␤»
lucasb ShimmerFairy: do you know if random identifiers are ok in nqp?
00:38 herby_ left
ShimmerFairy lucasb: I don't know, I should hope not. 00:38
nqp-m: xyzzy; say('a hollow voice says "fool"') 00:39
camelia nqp-moarvm: OUTPUT«a hollow voice says "fool"␤»
ShimmerFairy nqp-m: say('first statement'); second-stmt
camelia nqp-moarvm: OUTPUT«first statement␤»
ShimmerFairy Ox0dea: to answer your question, turns out "zeroth", at least when I had to look it up 5 years or so ago :) 00:41
Ox0dea ShimmerFairy: That does look to be the standard variant. 00:42
[Coke] if you find yourself sending a dozen things to camelia in a row that only differ by one character, maybe consider moving to private sends. :|
ShimmerFairy Wow, my code is really old if I didn't even think to use quoteword lists :P github.com/ShimmerFairy/Lingua--EN...rdinal.pm6 00:43
00:44 regreg left
[Coke] flussence: is #73 only impacting people with a previous install? 00:45
Ox0dea m: say 4073930972120442021941899024580558813626659657148635604951730592.base(16).trans("0..9A..E"=>"pwn givestomach") 00:46
camelia rakudo-moar a7ea8e: OUTPUT«the voices want me to stop wanting the voices to stop␤»
00:46 mscha joined
mscha p6: say τ 00:47
camelia rakudo-moar a7ea8e: OUTPUT«6.28318530717959␤»
mscha say τ == 2×π
p6: say τ == 2×π
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
Ox0dea That's nifty.
mort96 hey, I have a question
Skarsnik p6: say τ.Rat == 2×π.Rat
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
AlexDaniel mort96: what's your question? :) 00:48
mscha p6: say τ.Rat;
camelia rakudo-moar a7ea8e: OUTPUT«6.283186␤»
mort96 with regexes, by default, whitespace isn't significant. However, a warning is emitted telling you to either remove spaces, or make whitespace significant.
mscha say τ.Rat.perl;
mort96 Why not just make whitespace significant in the first place?
mscha p6: say τ.Rat.perl;
camelia rakudo-moar a7ea8e: OUTPUT«<710/113>␤»
AlexDaniel mort96: well, in Perl 5 it turned out to be a bad idea
00:49 lucasb left
flussence [Coke]: nope, in my case it was the opposite: 2015.12 only builds when there's *already* an installed rakudo, because it reads existing stuff from that (which is wrong) instead of trying to mkdir there 00:49
mort96 so it's a backwards compatibility thing in perl 6?
mscha say π - π.Rat;
p6: say π - π.Rat;
camelia rakudo-moar a7ea8e: OUTPUT«-2.66764189404967e-07␤»
mort96 I don't think 6 is backwards compatible anyways, is it?
AlexDaniel mort96: yes, kinda. So that people coming from Perl 5 will see it immediately. That's what I think
m: say ‘hello’ . ‘world’ 00:50
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/X4fK2cZ6qf␤Unsupported use of . to concatenate strings; in Perl 6 please use ~␤at /tmp/X4fK2cZ6qf:1␤------> 3say ‘hello’ .7⏏5 ‘world’␤»
AlexDaniel mort96: ↑ like this, that's also what Perl 5 programmers might do eventually :)
mort96 makes sense
AlexDaniel m: say ‘hello world’ ~~ /o w/ 00:52
camelia rakudo-moar a7ea8e: OUTPUT«Potential difficulties:␤ Space is not significant here; please use quotes or :s (:sigspace) modifier (or, to suppress this warning, omit the space, or otherwise change the spacing)␤ at /tmp/YENPnucWPQ:1␤ ------> 3say ‘hello world’ ~~ /o…»
mort96 kind of weird of perl6intro.com to advertise the whitespace insignificance of regexes then, but idk if that's affiliated with perl 6 in any way or just community things
00:52 gamo joined, pierrot_ joined, pierrot left
gamo What is the feature hyper/vectorize »op« ? 00:53
AlexDaniel m: say (1,2,3) »+« (10,20,30)
camelia rakudo-moar a7ea8e: OUTPUT«(11 22 33)␤»
AlexDaniel gamo: ↑ 00:54
mort96: well, it is not going to throw a warning everywhere else
mort96: that being said, I still wonder how is it possible to hide it without making a mess
mort96 what do you mean with "everywhere else"?
timotimo starts madly chopping pages from the perl6 tpf wiki 00:55
AlexDaniel mort96: oh
gamo ok, does it makes something paralellizable?
AlexDaniel m: 'say ‘hello world’ ~~ / ‘o’ ‘w’ /
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/kUNEAfUmaC␤Unable to parse expression in single quotes; couldn't find final "'" ␤at /tmp/kUNEAfUmaC:1␤------> 3'say ‘hello world’ ~~ / ‘o’ ‘w’ /7⏏5<EOL>␤ expecting any of:␤ …»
AlexDaniel m: say ‘hello world’ ~~ / ‘o’ ‘w’ /
camelia rakudo-moar a7ea8e: OUTPUT«Nil␤»
AlexDaniel mort96: ↑ no warning
mort96: I've never seen this warning for example in grammars
timotimo stmuk: the ssh certificate on pl6anet.org expired 51 days ago :( 00:56
AlexDaniel gamo: well, yes, although that's not what the current implementation will do, I think
gfldex gamo: not right now, but it will be in the future. Be careful with side effects.
mscha p6: say "hello world" ~~ / 'o w' /
camelia rakudo-moar a7ea8e: OUTPUT«「o w」␤»
AlexDaniel gamo: but you should expect that it will be parallelized one day, yes
Ox0dea timotimo: Good. That's a terrible name.
mort96 I'd still probably point out that it's generally considered a bad idea to have insignificant whitespace and it thus emits a warning in the perl6intro page
AlexDaniel mort96: considered a bad idea by who? 00:57
Skarsnik isignifiant whitespace are good for readability
gamo thank you, all, specially Alex and gfldex
mort96 by whomever made perl 6 emit that warning when you have a regex with insignificant whitespace?
you yourself said it emits the warning because it was generally considered a bad idea in perl 5 00:58
mscha p6: say "hello world" ~~ m:s/o w/
camelia rakudo-moar a7ea8e: OUTPUT«「o w」␤»
00:59 gamo left
ShimmerFairy mort96: for what it's worth, I've never managed to trigger the warning (though it probably helps I don't know what the conditions are for doing so :P) 00:59
[Coke] m: "JEEBUS IT'S LOUD IN HERE".say
camelia rakudo-moar a7ea8e: OUTPUT«JEEBUS IT'S LOUD IN HERE␤»
AlexDaniel mort96: I meant that significant whitespace was probably a bad idea
mort96: because people ended up writing unreadable regexes
mort96: sorry for the confusion
mort96 "hey" ~~ /n o/ triggers it 01:00
AlexDaniel m: “hey” ~~ /n o/
camelia rakudo-moar a7ea8e: OUTPUT«Potential difficulties:␤ Space is not significant here; please use quotes or :s (:sigspace) modifier (or, to suppress this warning, omit the space, or otherwise change the spacing)␤ at /tmp/E7LL3uLm61:1␤ ------> 3“hey” ~~ /n7⏏5 o/␤»
AlexDaniel m: “hey” ~~ /‘n’ ‘o’/
camelia ( no output )
AlexDaniel m: “hey” ~~ /‘n o’/
camelia ( no output )
AlexDaniel that is, just be explicit
Skarsnik The warning is annoying, I agree x)
mort96 so /'n' 'o'/ will match "no", while /'n o'/ will match "n o"? That kinda makes sense, had no idea about '' 01:01
Ox0dea What's the idiomatic approach to creating method aliases?
Skarsnik method aliases? 01:02
AlexDaniel mort96: yes
m: say so “oh no” ~~ /‘n’ ‘o’/ 01:03
camelia rakudo-moar a7ea8e: OUTPUT«True␤»
AlexDaniel m: say so “oh no” ~~ /‘n o’/
camelia rakudo-moar a7ea8e: OUTPUT«False␤»
mort96 then it seems like a great solution really, just a slightly confusing error message
Skarsnik m: “hey” ~~ r/n o/
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/SY5WtPiTNn␤Missing required term after infix␤at /tmp/SY5WtPiTNn:1␤------> 3“hey” ~~ r/n o/7⏏5<EOL>␤ expecting any of:␤ prefix␤ term␤»
timotimo Ox0dea: i think pl6anet is a cool name
AlexDaniel timotimo: I agree. Very recognizable
timotimo anyway, you're unlikely to see or type that name anyway. plop the feed into your reader and you're fine for the rest of your life 01:04
01:04 pierre-vigier joined 01:05 [particle] left 01:07 [particle] joined 01:08 BenGoldberg left, pierre-vigier left 01:09 BenGoldberg joined
timotimo [Coke]: it seems an extension in my mail client has gone a bit haywire and i sent a mail to casey with a From: of your mail address and name ... maybe expect confusion in your inbox 01:10
mort96 oh, I love the `my regex {regex}` thing
timotimo www.perlfoundation.org/perl6/index.cgi?fud - do we want to keep this? 01:11
[Coke] timotimo: I saw that one, it was weird.
timotimo: kill it. 01:12
AlexDaniel “I will never be able to type Unicode operators!” – haha… 01:13
01:14 yeahnoob joined
Skarsnik night #perl6 01:14
vendethiel 'night :)
01:15 Skarsnik left 01:17 mscha left
timotimo does somebody, anybody, want to put a little bit of text or example about "put" onto the faq entry about print vs say? 01:18
mort96 what's the difference? 01:20
according to the docs, the difference seems to be that put uses the .Str method to stringify, while say uses the .gist method 01:22
timotimo aye 01:23
but put puts a newline, too
so put is a mix between print and say
mort96 the docs also seem to recommend to use put to generate machine readable output, and say to generate human readable
timotimo either this is very exhausting, or i'm just very exhausted
yeah, that's the difference between .gist and .Str 01:24
m: say (^10000)
camelia rakudo-moar a7ea8e: OUTPUT«^10000␤»
timotimo m: say (^10000).list.gist
camelia rakudo-moar a7ea8e: OUTPUT«(0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 8…»
timotimo bad example
m: say (1 xx *).list.gist
camelia rakudo-moar a7ea8e: OUTPUT«(...)␤»
timotimo grmbl.
anyway, the .gist of a long list will terminate at some point and print "..." there
that's not how you put a list over the wire for a computer program to read :P
01:27 Ox0dea left, snarkyboojum joined, llfourn joined 01:28 rjbs left
mort96 # What's the difference between put and say? \n The routine `say` is designed for humans to read, and will make certain transformations to make the output more readable. It will for example truncate long lists, or round numbers with a lot of decimals. `put`, on the other hand, is designed for machine readable output, and will not make transformations to make 01:28
the text more readable.
^ little bit of text
no clue how to put anything on any FAQ, and probably wouldn't have permission either unless you can pull request some repo somewhere
timotimo www.perlfoundation.org/perl6/index....l_6_people - we don't have an equivalent of this page, do we? 01:29
you can pull request the repo. i think it says so at the far bottom
with a link to said repo
01:29 Ben_Goldberg joined 01:30 lustlife` left, BenGoldberg left
llfourn mort96: fork this and pull github.com/perl6/doc :) 01:31
01:31 CoconutC1ab is now known as CoconutCrab
mort96 ya, am there now, in the faq file 01:31
llfourn mort96: Cool. Thanks! 01:32
ugexe jdv79: so as far as i can tell, meta-spec 2 does not support alternative prereqs like `[ "JSON::Pretty", "JSON::Fast" ]`
mort96 what section would it make sense to put it in?
timotimo um, is that repo really where we generate the faq from?
mort96 " Generated on 2015-12-28T00:08:12.169418Z from Language/faq.pod from perl6/doc on GitHub. This is a work in progress to document Perl 6, and known to be incomplete. Your contribution is appreciated. "
timotimo doc.perl6.org/language/faq#How_and_..._differ%3F - i meant for this to be edited
mort96 from the footer
timotimo ah, very good 01:33
01:35 thomax_ joined, BenGoldberg_ joined
timotimo heads to bed 01:35
super tired
llfourn o/ gnight
01:36 sumdumgoi joined, rjbs joined, thomax left, thomax_ is now known as thomax 01:37 Ben_Goldberg left 01:45 xinming_ joined 01:48 xinming left
mort96 k, github.com/perl6/doc/compare/maste...ie:patch-1 01:49
or rather, github.com/perl6/doc/pull/278 01:50
dalek osystem: ac4720c | (Andy Weidenbaum)++ | META.list:
add TXN
osystem: 2f5a844 | (Zoffix Znet)++ | META.list:
Merge pull request #104 from atweiden/mktxn

add TXN
Zoffix URL for above: github.com/atweiden/mktxn 01:51
dalek c: 0eaa15c | (Martin Dørum Nygaard)++ | doc/Language/faq.pod:
Some more documentation about put

  timotimo in IRC wanted some more text about put in the FAQ. Thoughts?
01:52
c: fc1214e | (Zoffix Znet)++ | doc/Language/faq.pod:
Merge pull request #278 from mortie/patch-1

Some more documentation about put
01:52 zengargoyle left
c: ae85596 | (Zoffix Znet)++ | doc/Language/faq.pod:
Fix typo
01:53
c: 9bfe56b | (Zoffix Znet)++ | doc/Language/faq.pod:
Merge pull request #279 from zoffixznet/patch-2

Fix typo
Zoffix stupid github, why are you creating a fork during on-page edits when I have commit perms? 01:54
01:55 sdsgdfh joined 01:56 sdsgdfh left 01:57 pierrot joined, b4284 joined
Zoffix m: (^10000).list.gist.comb(/\d+/).elems.say 01:58
camelia rakudo-moar a7ea8e: OUTPUT«100␤»
01:58 pierrot_ left
AlexDaniel Zoffix: yeah, gist is used by say. That is, it is meant for human-readable output 02:02
m: (^10000).list.Str.comb(/\d+/).elems.say
camelia rakudo-moar a7ea8e: OUTPUT«10000␤»
AlexDaniel m: (~(^10000).list).comb(/\d+/).elems.say 02:03
camelia rakudo-moar a7ea8e: OUTPUT«10000␤»
Zoffix Yeah, I was just pointing the point where it stops in response to "will terminate at some point" above :)
02:03 vendethiel left
b4284 hello 02:03
Zoffix hai
b4284 congrats on the release, i'm looking at the intro right now 02:04
02:04 vendethiel joined
Zoffix Thanks. 02:04
AlexDaniel Zoffix: ah well, backlog is getting a bit fat. Sorry 02:05
Zoffix Fat backlogs are a good thing \o/
b4284 very interesting sytax, making subroutines with `sub' allows it to be called without parenthesis 02:06
time10 time10 10, this would be times10 $ times10 10 in haskell
AlexDaniel mort96: good job! 「put」 is actually a fairly new addition, IIRC 02:07
mort96: so no wonder it was not documented. Thanks
mort96 No problem, glad I could help 02:08
Zoffix b4284, heh, that stuff isn't even knew. Perl 5 can do the same as well :)
b4284 ah 02:09
konobi how goes the post-launch?
Zoffix m: sub term:<(⌒▽⌒)☆> { say "But this is!" }; (⌒▽⌒)☆; (⌒▽⌒)☆; (⌒▽⌒)☆;
camelia rakudo-moar a7ea8e: OUTPUT«But this is!␤But this is!␤But this is!␤»
Zoffix konobi, alright I guess, if we don't count one person running rakudobrew as root and nuking their /bin :P 02:10
Or that trolls on Raspberry Pi site think Perl's logo is an onion
b4284 i'm surprised to see that perl6 uses rational numbers by default
what goes floating numbers now ? 02:11
where, not what
mort96 Zoffix: don't worry, that person is up and running with a fresh install of arch again ;)
AlexDaniel m: say 20e0.WHAT 02:12
camelia rakudo-moar a7ea8e: OUTPUT«(Num)␤»
Zoffix m: say π.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«(Num)␤»
02:12 rjbs left
Zoffix mort96, good :) 02:12
AlexDaniel m: say 20.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«(Int)␤»
AlexDaniel m: say 20.5.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«(Rat)␤»
Zoffix m: say 0/0.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«Parameter 'de' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/twtb_wu9m1 line 1␤␤»
AlexDaniel m: say 20.5e0.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«(Num)␤»
Zoffix ^_^
llfourn (Num means floating point number)
AlexDaniel Zoffix: wtf is this
Zoffix What... de? what?
Was that mine?
m: say 0/0.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«Parameter 'de' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/Bf6yZrFqvS line 1␤␤»
Zoffix m: say 0/0 .WHAT
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤Method call must either supply a name or have a child node that evaluates to the name␤»
Zoffix :o 02:13
AlexDaniel Zoffix: what the
Zoffix heh
llfourn m: (0/0).WHAT
camelia ( no output )
Zoffix m: say 0+0 .WHAT
AlexDaniel m: 0 / (0.WHAT)
camelia rakudo-moar a7ea8e: OUTPUT«===SORRY!===␤Method call must either supply a name or have a child node that evaluates to the name␤»
rakudo-moar a7ea8e: OUTPUT«WARNINGS for /tmp/dU5rtnOlkd:␤Useless use of "/" in expression "0 / (0.WHAT)" in sink context (line 1)␤Parameter 'de' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/dU5rtnOlkd line 1…»
Zoffix m: say 0+0.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«Invocant requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/r7mnzkrRHJ line 1␤␤»
AlexDaniel m: say 0 / (0.WHAT)
camelia rakudo-moar a7ea8e: OUTPUT«Parameter 'de' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/nmOCbN_dpl line 1␤␤»
AlexDaniel m: say 0 / (.WHAT)
camelia rakudo-moar a7ea8e: OUTPUT«Use of uninitialized value of type Any in numeric context in block <unit> at /tmp/ULCcOm42yE line 1␤Attempt to divide by zero using div␤ in block <unit> at /tmp/ULCcOm42yE line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/ULCcOm42yE line 1…»
02:13 rjbs joined
Zoffix m: my $x = 0/0; say $x.WHAT 02:13
camelia rakudo-moar a7ea8e: OUTPUT«(Rat)␤»
AlexDaniel Zoffix: what an interesting finding… consider submitting a bug report 02:14
Zoffix I will
konobi hey rjbs
Zoffix m: my $x = 0/0; say $x.denominator
camelia rakudo-moar a7ea8e: OUTPUT«0␤»
llfourn AlexDaniel: what's the bug? The LTA error?
02:14 Ch0c0late left
Zoffix m: class Foo {}; say 0 / (Foo.new) 02:15
camelia rakudo-moar a7ea8e: OUTPUT«Cannot call Numeric(Foo: ); none of these signatures match:␤ (Mu:U \v: *%_)␤ in block <unit> at /tmp/tNzJTG8ENI line 1␤␤»
Zoffix m: class Foo {}; say 0 / (Foo.WHAT)
camelia rakudo-moar a7ea8e: OUTPUT«Use of uninitialized value of type Foo in numeric context in block <unit> at /tmp/oLzZwujTd4 line 1␤Attempt to divide by zero using div␤ in block <unit> at /tmp/oLzZwujTd4 line 1␤␤Actually thrown at:␤ in block <unit> at /tmp/oLzZwujTd4 line 1…»
Zoffix m: say 1/1.WHAT
camelia rakudo-moar a7ea8e: OUTPUT«Parameter 'de' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/ht6mu8fx2K line 1␤␤»
02:15 zhi joined
Zoffix Yeah, I'd say it's just an LTA error rather than a bug 02:15
02:16 geraud left 02:17 Milijus left
Zoffix Done: rt.perl.org/Ticket/Display.html?id=127051 02:17
mort96 The more I'm reading about perl 6's OOP, the more I'm liking it 02:18
bpmedley Is there a good overview of Promises, Supplies, and Channels available?
llfourn bpmedley: you mean apart from: docs.perl6.org/language/concurrency? 02:19
Zoffix bpmedley, there's this presentation by jnthn++, but it's from before the remake of Supplies jnthn.net/papers/2015-yapcasia-concurrency.pdf
02:19 xpen joined
bpmedley Yes, in addition to that. I'm just doing as much reading as possible right now. 02:19
llfourn bpmedley: if you prefer watching there is a nice youtube to go with the pdf zoffix just mentioned 02:20
bpmedley I'll try reading for now, thanks.
Zoffix bpmedley, I believe I saw an Advent post on the topic 02:21
Can't figure out how to get a table of contents on the site tho -_- Wordpress-- 02:22
llfourn hmm yes Zoffix++ that was a useful one
bpmedley: perl6advent.wordpress.com/2015/12/...nous-data/ :) 02:23
Zoffix llfourn++
m: say Int/Int.WHAT 02:26
camelia rakudo-moar a7ea8e: OUTPUT«Parameter 'nu' requires an instance of type Int, but a type object was passed. Did you forget a .new?␤ in block <unit> at /tmp/LnnSdb0IY8 line 1␤␤»
AlexDaniel llfourn: yes
Zoffix :)
llfourn I guess if it was changed to 'numerator' it would be better 02:28
Zoffix Yeah, if you don't see both 'nu' and 'de' it's less than obvious what those refer to 02:29
Oh, which reminds me about The Evil Error.....
dalek href="https://perl6.org:">perl6.org: 433ce56 | (Zoffix Znet)++ | source/index.html:
Fix aligment of Jump In well
02:33
autarch [Coke]: so updating rakudo didn't help - building the site still c. 2.5 hours and 3.6gb of memory :( 02:34
02:36 herby_ joined
llfourn autarch: is this related to pod? 02:36
autarch llfourn: yes 02:37
llfourn autarch: you are building docs using your new Pod::To::HTML?
autarch llfourn: yes, and it seems to be very slow and memory hungry
02:38 patrickz left
llfourn autarch: normally it takes like 10 mins or so and takes 700mb for me 02:38
autarch yeah, obviously this is much worse 02:39
I really don't know why though, the new Pod::To::HTML code isn't doing anything crazy, AFAICT
llfourn goes to take a look
autarch I'd appreciate the help 02:40
I guess the other option is to go work on the profiler ;) 02:41
since I can't profile this very effectively right now
geck so.. did perl6 do anything to improve pod or provide a better documentation mechanism?
llfourn autarch: The POD parser in the compiler is not great either rt.perl.org/Public/Bug/Display.html?id=127020
Zoffix geck, I think so, but... I ironically the Pod stuff isn't well documented yet :P 02:42
geck so I'm seeing
llfourn and not well implemented :S
autarch llfourn: but clearly that isn't the problem here, I'm not doing any additional pod parsing
geck hrrm
Zoffix geck, I think you can actually examine POD from within your program even...
llfourn but great things are on their way for pod I think
autarch: yep :) 02:43
Zoffix I dunno, so far it sounds like my program is wasting precious cycles parsing POD when it should be running
llfourn Zoffix: with precomp it shouldn't matter
Zoffix fair point
But still, the fact that documentation affects my program itself is a bit weird. 02:44
AlexDaniel geck: you can still write your comments in a very convenient way
llfourn to me is cool :)
Zoffix and the whole .WHY bit encourages spaghetti docs
geck AlexDaniel: tbh, I was hoping that something a bit more javadoc like would be in perl6
llfourn I like spagetti docs :D
geck or considered part of 02:45
AlexDaniel geck: there is! Let me find it…
Zoffix chucks POD6 to the same pile as :auth<> in the bucket of questionable design decisions.
02:45 ilbot3 left
autarch I do sometimes wonder if pod is worth the trouble - just use markdown and be done with it 02:45
Pod6 is easier to write than Pod(5) but markdown is easier than either
Zoffix autarch, there is the extra benefit of linking to sections 02:46
llfourn I don't care much for pod the format but I do like WHY
b4284 what is the :D after type names in function prototypes
autarch Zoffix: [...](#section)
Zoffix L<MyOther::Module/foo>
b4284 eg, Int:D Routine:D ?
autarch b4284: defined
Zoffix autarch, that only works for the current document.
autarch meaning undefined values are not allowed
02:46 ab6tract joined
Zoffix Otherwise I need a full URL which has obvious problems. 02:46
autarch Zoffix: [...](/other/doc#section) - but yes, that's not that easy
ab6tract "Or that trolls on Raspberry Pi site think Perl's logo is an onion" ... umm, Zoffix... the onion is a classic Perl logo 02:47
Zoffix ab6tract, but it's not Perl 6's logo
ab6tract well, that's not what you said
autarch if not markdown, then markdown + little tweaks to make certain things easier
02:47 ilbot3 joined
llfourn with GH Markdown you can just do [MyModule::Foo](MyModule/Foo) and it will link to the correct place 02:47
autarch though really, that's more the domain of the parser - [...](module:Foo::Bar] - let the parser sort it out
llfourn Foo.pm*
b4284 autarch: like with `with {}' blocks ?
Zoffix llfourn, how would it know where the "correct place" is? 02:48
autarch b4284: I'm not followed you - the Int:D $foo means that $foo must be an integer type value, and it must be defined
llfourn Zoffix: you're right lib/MyModule/Foo.pm
autarch it's possible to have an undefined Int value too
Zoffix llfourn, L<MyOther::Module/foo> is linking to another module not in the current repo
geck that sounds very fixable 02:49
autarch m: my $val = (Int); say $val.defined; say $val.^name
camelia rakudo-moar a7ea8e: OUTPUT«False␤Int␤»
autarch so it's an Int but it's not defined
llfourn Zoffix: ah, but surely github can link to other repos without full URL
AlexDaniel geck: web.archive.org/web/20150905083140/...tor_blocks
b4284 autarch: wow, great, thank you 02:50
Zoffix llfourn, doubt it, as it'll surely involve specifying the username and the name of the repo that is not necessarily the name of the module itself
b4284 would it be the same with `my Int $val';
geck AlexDaniel: oh neat
autarch b4284: let's see ...
m: my Int $val; say $val.defined; say $val.^what
camelia rakudo-moar a7ea8e: OUTPUT«False␤Method 'what' not found for invocant of class 'Perl6::Metamodel::ClassHOW'␤ in block <unit> at /tmp/LeBjKpaxNU line 1␤␤»
AlexDaniel geck: there are some great examples
autarch oops
m: my Int $val; say $val.defined; say $val.^name
camelia rakudo-moar a7ea8e: OUTPUT«False␤Int␤»
AlexDaniel I'm not sure why the current page is “Forbidden”
autarch yeah, looks like to be the same 02:51
llfourn Zoffix: yeah ofc but you would have to do that with pod too no?
b4284 autarch: thanks for helping out
autarch you're welcome
AlexDaniel geck: basically #| and #= :)
Zoffix llfourn, no, I leave it to the parser to figure out where MyOtherModule is located. In fact, I think GitHub rightnow links to MetaCPAN 02:52
llfourn #| and #= are pretty flimsy though as I am just finding out
b4284 looks like the intro is not enough for me now
llfourn Zoffix: ah I see. 02:53
b4284 are there other postfix decorators like :D ?
Zoffix b4284, :U
:D (defined) :U (undefined)
llfourn b4284: and :_ which is means the same as without it 02:54
b4284 i don't know, i find perl 6 syntax is somehow unfamaliar
llfourn: i don't understand
llfourn b4284: I'd say that's normal :)
Zoffix m: multi foo ($:D) { say "it's defined, bruh" }; multi foo ($:U) { say "where's the number, bruh?"}; foo Int; foo 42
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5===␤In signature parameter, placeholder variables like $:D are illegal␤you probably meant a named parameter: ':$D'␤at /tmp/7xs3ejFE4v:1␤------> 3multi foo ($:D7⏏5) { say "it's defined, bruh" }; multi fo␤In signature parameter…»
bpmedley b4284 : Unfamiliar, or new and exciting?
Zoffix O-oh... Illegal!
Zoffix waits for the police 02:55
llfourn m: my $a = Any:_; say $a.perl;
camelia rakudo-moar a7ea8e: OUTPUT«Any␤»
Zoffix I wonder if the above should actually DWIM?
What's the right syntax?
llfourn Zoffix: Any:D?
Zoffix m: multi foo (Any:D) { say "it's defined, bruh" }; multi foo (Any:U) { say "where's the number, bruh?"}; foo Int; foo 42
camelia rakudo-moar a7ea8e: OUTPUT«where's the number, bruh?␤it's defined, bruh␤»
Zoffix k
b4284 bpmedley: guess i'll have to write something to figure it out 02:56
AlexDaniel b4284: that's the way to do it :)
02:59 Su-Shee_ joined
llfourn autarch: so thinking about the memory usage -- is that going up linearly over time? 03:01
autarch llfourn: it seems like it
03:02 Su-Shee left, skyl4rk left
konobi so... the Perl6 experience for a new user is really pretty terrible =0( 03:04
Zoffix konobi, oh
konobi, what in particular?
konobi well, i go to the website... I have no idea that there's a "stable" release... nor what the release is... the download/install instructions are pretty terrible 03:05
bpmedley konobi : What platform are you on?
konobi osx/linux/bsd/solaris
03:06 tef left
bpmedley konobi : Have you tried rakudobrew on OS X? 03:06
konobi bpmedley: I already have rakudo installed... and I've been familiar with perl6 and development for years.
bpmedley My bad
konobi I'm just saying that the "new user" story is really bad
03:07 rafl left
konobi it's all under TPF though, right? 03:07
Zoffix konobi, I'd think the new users would be using Rakudo Star, which hasn't been released yet 03:08
And the install instructions were written in a rush during holidays (in fact, I was passed out drunk when release happened).
It's just a really bad idea to release on Christmas and there was a shortage of hands.
konobi "so.. there's perl6, but then there's this thing called rakudo, but that talks about moarvm and I believe JVM is mentioned in there too."
03:09 ELBeavers joined
Zoffix konobi, I see 4 lines of install instructions: perl6.org/downloads/ 03:09
Not sure what you're talking about
konobi Zoffix: it's a problem... I've been seeing it unfortunately. 03:10
03:10 leont left
Zoffix has seen more text written by people complaining about terrible install instructions than it would take to write decent instructions in a PR 03:11
03:11 BenGoldberg_ left
konobi Zoffix: I'm not complaining per-se... just forwarding concerns 03:12
ugexe sub foo(%a, %b?, %c?) # is 2 positional optional hashes as parameters a good design decsion, since they aren't exactly always optional? (such as having %c but not %b requires passing an empty hash for %b)
konobi Zoffix: I'll ping karen about it.
Zoffix ugexe, I'd use named args
konobi, ether?
ugexe because thats what CUR.install uses
konobi Zoffix: nah, not ether... pauley 03:13
gfldex ugexe: have a multi maybe?
03:13 BenGoldberg_ joined
Zoffix looks up 03:13
Pres of TPF, got it 03:14
ugexe why arent the various hashes just passed in with the Distribution object itself? 03:15
03:15 noganex joined
konobi Zoffix: =0) 03:15
Zoffix: is ether doing much with perl6?
Zoffix konobi, I thought I saw a post somewhere with her asking community feedback on jnthn++'s extension of the grant 03:16
ugexe method install(Distribution $dist, %sources, %scripts?, %resources?, :$force)
Zoffix maybe I misread the last name :/
konobi Zoffix: yeah... Karen Etheridge. 03:17
03:18 noganex_ left
konobi Zoffix: I used to be the leader of van.pm, so just trying to work out if there's folks in town who could talk about Perl6 03:18
03:18 vendethiel left
konobi Zoffix: (since I've had my head in node.js for the last few years) 03:19
Zoffix :o 03:20
03:25 ab6tract left
llfourn is there any way to say this is a hash and not a block when using {}? 03:27
konobi %{} ? 03:28
llfourn konobi: thanks! 03:29
03:31 kid51 left, BenGoldberg_ left
llfourn m: sub t { { one => "two"} }; say %{ |t(),three => "four"}; 03:32
camelia rakudo-moar a7ea8e: OUTPUT«Odd number of elements found where hash initializer expected␤ in block <unit> at /tmp/mjL0vQ2KBb line 1␤␤»
llfourn how do I flatten the hash as a result of a call?
03:32 BenGoldberg_ joined
sumdumgoi is working on a wilderness roguelike game in perl 6. (imgur.com/sdZ9oP5) 03:37
llfourn is excited 03:38
ugexe sub parse-include-specS(Str:D $specs) { # the routine is called twice with the same (what i can only assume is) c&p+replace name. or is it like that for a reason? 03:39
sumdumgoi llfourn: :D
03:44 sumdumgoi left
AlexDaniel m: sub t { { one => “two”} }; say %( |t(),three => “four”) 03:46
camelia rakudo-moar a7ea8e: OUTPUT«one => two, three => four␤»
AlexDaniel llfourn: ↑
m: sub t { { one => ‘two’} }; say %(t(), three => ‘four’) 03:47
camelia rakudo-moar a7ea8e: OUTPUT«one => two, three => four␤»
llfourn AlexDaniel: neat!
AlexDaniel m: sub t { %{ one => ‘two’, ten => ‘eleven’} }; say %(t(), three => ‘four’) 03:48
camelia rakudo-moar a7ea8e: OUTPUT«one => two, ten => eleven, three => four␤»
AlexDaniel yeah, works as expected
llfourn why does %() work but not %{}?
maybe %{} only parses kv pairs 03:49
AlexDaniel I'm not quite sure. Maybe 03:50
llfourn ...hmm but it works if you are *not* flatting a call result
AlexDaniel m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; say (t(), three => ‘four’).WHAT
camelia rakudo-moar a7ea8e: OUTPUT«(List)␤»
AlexDaniel so you are getting a list
m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; dd (t(), three => ‘four’)
camelia rakudo-moar a7ea8e: OUTPUT«({:one("two"), :ten("eleven")}, :three("four"))␤»
llfourn m: my %h1 = ( one => "two" ); my %h2 = ( three => "four", |%h1 ); say %h2.perl
camelia rakudo-moar a7ea8e: OUTPUT«{:one("two"), :three("four")}␤»
llfourn m: my %h1 = ( one => "two" ); my %h2 := { three => "four", |%h1 }; say %h2.perl 03:51
camelia rakudo-moar a7ea8e: OUTPUT«{:one("two"), :three("four")}␤»
AlexDaniel m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; (t(), three => ‘four’).Hash
camelia ( no output )
AlexDaniel m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; say (t(), three => ‘four’).Hash
camelia rakudo-moar a7ea8e: OUTPUT«one => two, ten => eleven, three => four␤»
llfourn it's kind weird
geck that's pretty neat
AlexDaniel so it seems like .Hash flattens the whole thing? Is it supposed to work this way?
gfldex m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; dd(t(), three => ‘four’); 03:52
camelia rakudo-moar a7ea8e: OUTPUT«Hash % = {:one("two"), :ten("eleven")}␤»
llfourn AlexDaniel: isn't it just the () flattening
AlexDaniel llfourn: I don't see why () would flatten anything
llfourn becomes more confused 03:53
oh dd is just taking first arg
gfldex m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; my \v = \(t(), three => ‘four’); dd t;
camelia rakudo-moar a7ea8e: OUTPUT«Hash % = {:one("two"), :ten("eleven")}␤»
gfldex not just dd
m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; my \v = \(t(), three => ‘four’); dd v; 03:54
camelia rakudo-moar a7ea8e: OUTPUT«\({:one("two"), :ten("eleven")}, :three("four"))␤»
gfldex ahh
llfourn :)
gfldex :three('four') become an optimal named arg to dd
llfourn gfldex: ah yeah ofc. I'm still not used to that :P
gfldex and the capture is a list of a hash and a pair
\() <-- makes a capture 03:55
AlexDaniel m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; say (t(), three => ‘four’).Hash.keys
camelia rakudo-moar a7ea8e: OUTPUT«(three one ten)␤»
AlexDaniel m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; say (t(), three => ‘four’).perl
camelia rakudo-moar a7ea8e: OUTPUT«({:one("two"), :ten("eleven")}, :three("four"))␤»
gfldex m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; my \v = (t(), three => ‘four’).flat.list; dd v; 03:56
camelia rakudo-moar a7ea8e: OUTPUT«(:one("two"), :ten("eleven"), :three("four"))␤»
AlexDaniel I don't really understand why a list of a hash and a pair becomes a hash. It kinda makes sense, but why?
gfldex it doesn't become a hash
AlexDaniel I mean, why does it flatten before becoming a hash :)
llfourn AlexDaniel: you mean you .Hash?
when you* 03:57
AlexDaniel yes
gfldex m: sub t { %( one => ‘two’, ten => ‘eleven’ ) }; my \v = (t(), three => ‘four’).flat.hash; dd v;
camelia rakudo-moar a7ea8e: OUTPUT«Hash % = {:one("two"), :ten("eleven"), :three("four")}␤»
03:58 BenGoldberg_ left
AlexDaniel m: sub t { %( one => ‘two’, ten => %(foo => ‘bar’) ) }; say (t(), three => ‘four’).Hash.perl 03:58
camelia rakudo-moar a7ea8e: OUTPUT«{:one("two"), :ten(${:foo("bar")}), :three("four")}␤»
AlexDaniel hm, no, it does not flatten it. OK
llfourn m: sub make-hash(*%h) { say %h.perl }; ({ one => 'two'},thee => 'four').&make-hash #maybe
camelia rakudo-moar a7ea8e: OUTPUT«Too many positionals passed; expected 0 arguments but got 1␤ in sub make-hash at /tmp/vXhqxBzRP1 line 1␤ in block <unit> at /tmp/vXhqxBzRP1 line 1␤␤»
llfourn ... 03:59
AlexDaniel it just works automagically. Neat.
03:59 BenGoldberg_ joined 04:00 dcd joined 04:01 BenGoldberg_ left
llfourn m: sub make-hash(*@h) { my %h = @h; say %h.perl}; ({ one => "two"},thee => "four").&make-hash 04:01
camelia rakudo-moar a7ea8e: OUTPUT«{:one("two"), :thee("four")}␤»
llfourn it flattens because of slurpyness somewhere I think
04:01 dcd left
gfldex if i read /src/core/Any.pm#L539 correctly the named param should not vanish 04:02
04:02 BenGoldberg_ joined
gfldex in dd that is 04:02
04:02 kaare_ joined
gfldex m: dd {:a(1), :b(2)}, :c(3); 04:03
camelia rakudo-moar a7ea8e: OUTPUT«Hash % = {:a(1), :b(2)}␤»
gfldex m: dd({:a(1), :b(2)}, :c(3));
camelia rakudo-moar a7ea8e: OUTPUT«Hash % = {:a(1), :b(2)}␤»
04:04 BenGoldberg_ left
gfldex .tell lizmat should the last pair vanish in 'm: dd({:a(1), :b(2)}, :c(3));' ? 04:05
yoleaux gfldex: I'll pass your message to lizmat.
04:05 BenGoldberg_ joined 04:07 BenGoldberg_ left, regreg joined 04:08 BenGoldberg_ joined 04:09 BenGoldberg_ left 04:10 BenGoldberg_ joined, BenGoldberg_ left 04:11 herby_ left 04:15 yurivish joined 04:36 uvtc joined
ugexe there is both a `sub parse-include-spec` and a `sub parse-include-specS`? this is rather confusing 04:36
04:38 xpen left, xpen joined 04:43 cognominal joined
ugexe m: use MONKEY-SEE-NO-EVAL; say $*REPO.repo-chain[0]; EVAL "say {$*REPO.repo-chain[0].perl}" 04:44
camelia rakudo-moar a7ea8e: OUTPUT«inst#/home/camelia/.perl6/2015.12-23-ga7ea8e6␤Too many positionals passed; expected 1 argument but got 2␤ in block <unit> at EVAL_0 line 1␤ in block <unit> at /tmp/2R7h9RHfRY line 1␤␤»
04:52 kaare_ left 04:58 thomax left 05:02 gist_nb joined
gist_nb m: say "hello" 05:03
camelia rakudo-moar a7ea8e: OUTPUT«hello␤»
gist_nb m: 1..10 ==> say
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5===␤Argument to "say" seems to be malformed␤at /tmp/pimTR2AX2_:1␤------> 031..10 ==> say7⏏5<EOL>␤Other potential difficulties:␤ Unsupported use of bare "say"; in Perl 6 please use .say if you meant $_, or use an explicit i…»
gist_nb m: 1..10 ==> say ''
camelia rakudo-moar a7ea8e: OUTPUT«1..10␤»
TimToady m: 1..10 ==> say() 05:04
camelia rakudo-moar a7ea8e: OUTPUT«1..10␤»
TimToady that also works
gist_nb m: 1..10 ==> say ()
camelia rakudo-moar a7ea8e: OUTPUT«()1..10␤»
TimToady ==> adds args
and () is a separate arg if you put space there
05:05 rickbike joined
gist_nb timtoady: ah i c ... thanks! 05:05
[1,2,3] ==> say)_
m: [1,2,3] ==> say()
camelia rakudo-moar a7ea8e: OUTPUT«[1 2 3]␤»
05:06 pierre-vigier joined 05:08 molaf joined
gist_nb one more question. is the ==>> operator implemented? 05:08
TimToady I don't think so. feeds are still in a fairly rudimentary state 05:09
gist_nb ok ... thanks again
05:09 torax joined
TimToady m: my @foo = 1,2,3; 4,5,6 ==>> @foo; say @foo 05:09
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/E6EHihuxQ2␤==>> feed operator not yet implemented. Sorry. ␤at /tmp/E6EHihuxQ2:1␤------> 3my @foo = 1,2,3; 4,5,6 ==>> @foo7⏏5; say @foo␤»
gist_nb yup .. 05:10
uvtc Just noticed the gcd operator ... I'd always thought that was "greatest common factor", or "greatest common divisor"... not greatest common denominator.
05:10 pierre-vigier left
TimToady a divisor and a denominator are the same thing 05:12
uvtc Mmm. 05:14
05:15 Tonik joined 05:18 yqt left 05:20 regreg left 05:23 nash joined 05:29 nash left
Zoffix m: dd @({:a(1), :b(2)}, :c(3)); 05:31
camelia rakudo-moar a7ea8e: OUTPUT«({:a(1), :b(2)}, :c(3))␤»
05:35 molaf left 05:40 vendethiel joined 05:42 xtreak left 05:45 khw left 05:47 edehont joined
ugexe m: my (@a, @b, @c); @a ==>> @b ==> @c 05:48
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/_3XCaEFqRy␤Operators '==>>' and '==>' are non-associative and require parentheses␤at /tmp/_3XCaEFqRy:1␤------> 3my (@a, @b, @c); @a ==>> @b7⏏5 ==> @c␤ expecting any of:␤ infix␤ …»
ugexe m: my (@a, @b, @c); @a ==> @b ==> @c 05:50
camelia ( no output )
ugexe that error message is slightly ambiguous 05:51
TimToady intentionally so, since we don't really know which way it was intended to be grouped in general with list associative operators 05:52
m: say 1,2,3 X 4,5,6 Z 7,8,9 05:53
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/8fGDOBAS9_␤Operators 'X' and 'Z' are non-associative and require parentheses␤at /tmp/8fGDOBAS9_:1␤------> 3say 1,2,3 X 4,5,6 Z7⏏5 7,8,9␤ expecting any of:␤ infix␤ infix stoppe…»
ugexe what i mean is, it can be interpretted that the pipe operators (of which there are 2?) always require the parentheses instead of that specific combination of them
TimToady I see what you're saying 05:54
would help if it said "non-identical" or some such to show what's actually bothering int 05:55
*it
though there's only so much teaching you can do in error messages...
ugexe m: my (@a, @b, @c); @a ==> @b ==>> @c # yeah. doing it again and getting this error message swapping the operators also clarified to me what is meant 05:59
camelia rakudo-moar a7ea8e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/JriDELOPq3␤Operators '==>' and '==>>' are non-associative and require parentheses␤at /tmp/JriDELOPq3:1␤------> 3my (@a, @b, @c); @a ==> @b7⏏5 ==>> @c # yeah. doing it again and gett␤ expecting …»
06:00 xpen left, [particle] left 06:01 xpen joined, [particle] joined
uvtc I thought the colon made a colon pair, such as :a<4> ---> 'a', 4. But, I think I've seen it used to describe "adverbs". But then I think I've also seen it as a kind of function call syntax alternative to parens... Are the three connected? 06:01
ugexe as i now know `'==>>' and '==>'` is not a hard coded string meant to convey all pipe operators, but rather some combination 06:02
06:02 xpen_ joined, edehont left 06:04 vendethiel left
TimToady is testing a tweak to the error message 06:05
06:05 xpen left 06:06 xpen_ left, xpen joined
Hotkeys I'm attempting to access individual values in a shaped array and am getting "Partially dimensioned views of arrays not yet implemented. Sorry." 06:06
is there a way to actually access values in one of these? 06:07
and by access I mean set mutably
geekosaur uvtc: adverbs and colonpairs are related. colon method syntax is not. (note however that :a<4> makes ('a' => '4'); in perl6, => is not just a fat comma, it is the constructor for a pair, which is a distinct type)
06:08 xpen_ joined 06:09 nige1 joined
uvtc geekosaur, thanks! I don't yet know about colon method syntax, but how are adverbs and colon pairs related? 06:09
TimToady the only place we confuse the notations is in a smartmatch, where a pair is interpreted as a method call tests 06:10
(intentionally confuse, I should say)
06:10 mempko joined
TimToady it lets you stack boolean methods (such as on a filehandle) using junctions that way 06:10
geekosaur uvtc: colonpairs can be used to pass named arguments; adverbs are, as I understand it, just named arguments to things like operators 06:11
TimToady we tend to use "colonpair" to describe the notation, and "adverb" to describe the semantics use of the notation
*tic
06:11 xpen left
geekosaur yes, that 06:11
06:12 [particle]1 joined, [particle] left
geekosaur should not still be up but body is playing up; was trying to phrase that... 06:12
uvtc Thank you. Could you please point me to an example of how adverbs are used in connection with subs/functions? (Ex. do I pass a function an adverb? Do I declare a sub to take an adverb? Looking around the docs at doc.perl6.org ...) 06:13
TimToady as far as the function is concerned, they're just named arguments 06:14
it's just the syntax for the call gets a little fancier when you're applying an adverb to an operator rather than a normal function call 06:15
but the call '1 + 2 :foo' is really just the same as infix:<+>(1,2,:foo) 06:16
uvtc TimToady: typo? `1 + 2 + :foo` ? 06:18
geekosaur no. in '1 + 2 :foo', :foo is applied to + not to 2 06:19
2 is not a thing that can be adverbed. another operator could , or a function could (in the latter case it'd be inside the call parens) 06:20
uvtc I see that `:foo` yields / evaluates to `foo => True`. ... I know in english an adverb modifies a verb... An adverb in Perl 6 is applied to a function?
geekosaur yes
dalek kudo/nom: 373adc0 | TimToady++ | src/core/Exception.pm:
improve error message on differing list assoc ops
TimToady ugexe++
geekosaur functions and operators being the verbs of perl 6
uvtc Can you give me an example of adverbing a function/sub? Do I create my own adverbs to apply? 06:21
geekosaur although there are other verbs as well; for example, if you index into an array or hash ([] or {}/<>/<<>> suffixes), the suffixes are also verbs and can take adverbs
like, for example, :exists on hash lookups
06:22 aindilis joined
uvtc Yes. I don't get why it's `%h<foo>:exists` rather than `%h<foo>.exists`. 06:22
geekosaur an adverb is just a named parameter
because . would apply too late 06:23
the lookup would already have happened and it would be made to exist, with an "undefined" value if it didn't exist before
but the adverb modifies the lookup itself
uvtc Oh. So I'm passing `exists => True` to the hash lookup post-circumfix op? That is, in addition to passing what's in the <>'s? 06:24
geekosaur the <> there, the compiler rewrites <foo> to {'foo'} and then calls postcircumfix:<[ ]>(key) (and adds :exists as a parameter if you specified that)
06:25 xpen_ left, xpen joined, nige1 left
ugexe definitely no ambiguity now 06:25
TimToady :)
and it's still officially 6.c, according to the spec tests :) 06:26
geekosaur and the declaration for that is something like: sub postcircumfix:<{ }>(::keytype $key, :exists = False)
(where ::keytype is the type of the key in this hash; it's not really a sub but a method, I miswrote that)
06:26 rickbike left
TimToady actually, it is a sub 06:26
geekosaur (also wrote [] instead of {} e first time through)
TimToady used to be a method
geekosaur ah
and that :exists should be :$exists 06:27
TimToady but subs can be optimized better at compile time
06:27 b4284 left
geekosaur so the body can test $exists to see if you specified that named parameter / adverb 06:27
TimToady which will become really important for indexing native multi-dim arrays 06:28
geekosaur in your own functions you can also use that :$name syntax to declare a named parameter, which then functions as an adverb
uvtc Ok. Ok, thanks. It looks like using an adverb is a way to pass an extra named arg to an opp that doesn't usually take an extra arg.
Right, and if it's one of my own regular subs, I can just use that :$name syntax, as you just said. 06:29
06:29 Averna joined
geekosaur yes, and you can use it to modify behavior without having to have a bunch of extra parameters (which is better: foo(1, :do-this, :and-do-that) or foo(1, False, True)?) 06:30
geekosaur sees a lot of the latter in a C++ project he helps out with, and it's annoying to have to hunt down the prototype to see what it means... 06:31
uvtc Ah, cool. I think I just repeated what you said in your first reply. :) 06:32
TimToady m: say 1,2,3 X 4,5,6 Z 7,8,9 06:33
camelia rakudo-moar 373adc: OUTPUT«5===SORRY!5=== Error while compiling /tmp/P2bPwuwr11␤Only identical operators may be list associative; since 'X' and 'Z' differ, they are non-associative and you need to clarify with parentheses␤at /tmp/P2bPwuwr11:1␤------> 3say 1,2,3 X 4,5,6 Z…»
ugexe m: class A { method ZEN-KEY(:$foo!) { say "ZEN-KEY:foo" } }.new{}:foo 06:35
camelia rakudo-moar 373adc: OUTPUT«ZEN-KEY:foo␤»
06:37 xpen_ joined 06:40 karl_ joined, xpen left 06:45 Averna left, karl_ left
uvtc Oh, forgot to say thanks. Thanks! I think I got it now. :) 06:46
dalek c: cb428ce | (John Gabriele)++ | doc/Language/glossary.pod:
typo (s/5/4/)
06:54
06:58 Averna joined 07:00 uvtc left
Hotkeys for looping through ints is a c style loop any faster than a for loop using a range? 07:00
stmuk_ me-- # replying to chromatic on reddit 07:01
07:03 gist_nb left 07:04 Averna left 07:06 pierre-vigier joined
AlexDaniel Hotkeys: test it 07:06
Hotkeys I wanted to be lazy and just ask 07:07
07:10 znpy joined 07:13 nrnoble joined
AlexDaniel stmuk_: link? :) 07:15
07:16 Averna joined
flussence the only winning move is not to play 07:18
AlexDaniel ah found it. Well, I expected it to be funnier 07:21
stmuk_ "The Only Way to Win is Not to Play the Game" 07:22
www.reddit.com/r/programming/comme..._released/ was mostly nice 07:23
07:24 CIAvash joined
AlexDaniel holy sh… -8°C 07:24
07:27 znpy left, SwellJoe left
stmuk_ www.learning-perl.com/2015/12/were-...h-edition/ 07:31
"We’re starting to think about Learning Perl 6."
:D
Hotkeys I figured out a way to make the interpreter angry i.imgur.com/MmpM9Mh.png 07:36
07:39 Averna left 07:42 zostay left 07:43 geekosaur left, frew left, simcop2387 left 07:44 rjbs left 07:46 snarkyboojum left 07:48 _nadim left, _nadim joined
ChoHag What's the difference between Nil and Any, and why does this produce output: 07:52
m: my $no = Nil; given 42 { when Nil { say "Maybe"; proceed }; when $no { say "Impossible" }; }
camelia rakudo-moar 373adc: OUTPUT«Impossible␤»
07:52 ellybelly joined
TimToady you can't store "the absence of a value" without taking special precautions to tell the variable it is allowed to store that 07:54
m: my $no = Nil; say $no
camelia rakudo-moar 373adc: OUTPUT«(Any)␤»
TimToady so all you're test is 'when Any' 07:55
*testing
23:52 < ChoHag> m: my $no is default(Nil) = Nil; given 42 { when Nil { say "Maybe"; proceed }; when $no { say "Impossible" }; }
Woodi o, and how to "undefine" variable ?
TimToady m: my $no is default(Nil) = Nil; given 42 { when Nil { say "Maybe"; proceed }; when $no { say "Impossible" }; }
camelia ( no output )
Woodi hallo #perl6 :) 07:56
Hotkeys Can I store a reference to a value in a hash value in another hash value eg
%foo{'a'} = %foo{'b'} * 2
TimToady all values are references, unless they're native
ChoHag Hmm.
Hotkeys and even if I change %foo{'b'}
%foo{'a'} will reflect that
TimToady you could use binding if you want that
ChoHag Well 'what-exactly-undefined-means' issues aside, what I actually have is 4 when clauses against variables (when $foo, when $bar, etc.), where 2 of them variables may be invalid matches under certain circumstances. 07:57
Hotkeys how could I do that?
with binding
TimToady use := instead of = 07:58
ChoHag Apparently undefining $foo didn't cause $foo to not match but to match, which was somewhat off.
odd
And off.
TimToady you told it to revert to its default value, and the default value is 'Any', which matches most things
smartmatching can't always read your intent 07:59
because people intend contradictory things 08:00
Woodi I tried @a = Any; to undefine @ but it ended with @a having Any as first element...
Hotkeys m: my %foo = 'a' => 2; %foo<b> := %foo<a> * 2; say %foo<b>; %foo<a> = 3; say %foo<b>
camelia rakudo-moar 373adc: OUTPUT«4␤4␤»
Hotkeys I don't think I'm doing this right
ChoHag The main thing here is that undefined is not as clear a concept as I thought it was.
TimToady Any is a discrete undefined value; why would you expect it to empty an array? 08:01
08:01 geekosaur joined, geekosaur left
TimToady use @a = () for that 08:01
ChoHag Which I remember reading about in the docs a while back but apparently it didn't sink in enough.
TimToady undef is many concepts, and Perl 6 requires you to be more precise than Perl 5 here
08:01 simcop2387 joined
TimToady m: undef 08:01
camelia rakudo-moar 373adc: OUTPUT«5===SORRY!5=== Error while compiling /tmp/OkaK9KDY4q␤Unsupported use of undef as a value; in Perl 6 please use something more specific:␤ an undefined type object such as Any or Int,␤ :!defined as a matcher,␤ Any:U as a type constraint,␤ Nil a…»
Woodi TimToady: cargoculting from somewhere ? :) = () will be good
ChoHag Well I can get away with setting it to False rather than undefining it. 08:02
This function's rubbish anyway, I just don't want to fix it yet.
08:02 geekosaur joined
Woodi ChoHag: but @a = False; is strange thing and IMO it;s syntax error... 08:03
08:03 frew joined
ChoHag Yes it is. 08:03
TimToady I see a list of 1 element, False
ChoHag But as TimToady said - what you're doing with the undefined value matters.
Hotkeys m: my %foo = 'a' => 2; %foo<b> := { %foo<a> * 2 }; say %foo<b>(); %foo<a> = 3; say %foo<b>()
camelia rakudo-moar 373adc: OUTPUT«4␤6␤»
Woodi ChoHag: but it's Perl6, you never can be sure what happens ;)
Hotkeys this works but feels wrong
ChoHag And we happen to have come inat the same time with a vaguely related problem and I was solving mind, not yours. 08:04
mine
MOAR COFFEE
Woodi Chemex is good :)
08:05 zostay joined, rjbs joined
ChoHag How do you set a variable to the result of a function but only have that function called when the variable gets used (printed, tested against, munged, etc.)? 08:07
08:10 Amnez777 left, mojca joined, darutoko joined
mojca I would like to make a package for rakudo or rakudo-star and need a tiny bit of help from upstream. 08:12
Woodi ChoHag: some half-"await" :)
mojca I tried building with --backends=moar --gen-moar, but the problem is that the build puts files under destroot and fails to find moar
08:12 mempko left
Woodi --prefix 08:13
mojca sh: /opt/local/bin/moar: No such file or directory
Woodi, if that was for me, I have --prefix=/opt/local
the problem is that the binary is not yet in /opt/local during the build of rakudo 08:14
Woodi mojca: at least when i put moar in /opt nqp and raqudo don't know how to use $path...
08:14 cpage joined
Woodi mojca: you need to have moar first :) 08:14
mojca I understand, but I thought that rakudo would build it automatically
and it does build it, it's just that moar is not yet in $prefix 08:15
Should I build moar as a separate package?
and put moar as a dependency rather than building it as part of rakudo?
Woodi mojca: it's strange, maybe --gen-moar don't work with prefix...
mojca: thing is that ppls use that auto-building for development purposes 08:16
mojca quick question: what exactly is the difference between rakudo and rakudo-star?
Woodi r* have additional modules
mojca which one should I package (one of them fetches things on the fly which I don't particularly like)
Woodi mojca: distro-packagers would probably like separate packages 08:17
mojca so auto-building of moar is there just for convenience and a package should not bother about it but rather install it separately?
Woodi mojca: in my opinion :)
but I'm not a developer :)
mojca ok, so I'll try to create a package for moarvm first
nevertheless, should I bother about getting the installation problem fixed? 08:18
and if so, what is the best place (I don't know enough about internals to be able to provide a perfect description for the bug report)
I can try though
Woodi mojca: sure, any help is appreciated 08:19
08:19 domidumont joined, nash joined
mojca what's the right place to report installation problems of rakudo? 08:21
ChoHag mojca: I've found the best way to install in a non-standard location is to eschew the --gen-* options and build the components individually.
I intend to fix this in the next week or so.
Woodi mojca: you install moar, then nqp and then rakudo. you can unpack rakudo, check in tools/build/NQP_REV which one nqp you need then unpack nqp, check tools/build/MOAR_REV which one moar you need :)
08:21 pistacchio joined
nine mojca: you can ignore the "/opt/local/bin/moar: No such file or directory" message during build. As long as the build continues afterwards. 08:21
08:21 domidumont left
Woodi mojca: but ATM you need 2015.12 for everything :) 08:22
08:22 domidumont joined
pistacchio hi, if i get it correctly, the "&" sigil indicates a named function. why in doing so (1, 2, 3)>>.&{ $_ * 2 } i have to use the ampersand sigil AND a dot before the lambda block? thanks 08:23
nine mojca: that message should just be the result of the check if we actually need to build moar and nqp.
mojca I can ignore the message, but it doesn't build. 08:24
08:24 joydo left
mojca among other errors there is "Cannot chmod 755 /opt/local/bin/moar:No such file or directory at /opt/local/lib/perl5/vendor_perl/5.22/ExtUtils/Command.pm line 281." 08:24
08:24 labster joined, joydo joined
nine Ok that sounds more serious 08:24
mojca: then I'd go with the recommendation to build the components separately. From a distro perspective, you will want separate packages anyway, won't you? 08:25
mojca Maybe. I don't know how exactly moar is used anyway. If it's just for perl6, it could be bundled together, but I agree that it's probably better to package it separately. 08:26
I've seen that HomeBrew packages it together 08:27
unless I was mistaken ... I don't know why they don't run into problems though
nine Well it was built for Perl 6 and the only known user is Perl 6. In theory it could be used for another language though.
ChoHag perl6 can run against the jvm (and there were other backends in the past). While perl6-moar could come with moar where perl6-java doesn't come with a jvm, for clarity it seems to me it'd make moar sense (heh) to have a moar package.
s/doesn't/shouldn't/ 08:28
08:29 lnrdo_ joined
nine Oh, that's certainly a valid perspective: while moar may have only rakudo as user, rakudo doesn't actually need moar, so it should be optional, hence a separate package. 08:30
08:33 lnrdo left
[Tux] csv-ip5xs 50000 18.547 18.437 08:33
test 50000 23.472 23.362
test-t 50000 13.864 13.754
csv-parser 50000 50.598 50.488
Woodi oh, WOW... first company ThinkPad (the only one with Win10) didn't wanted to boot (but was unplugged from power (and battery is dead anyway) :) ) THEN it displayed that some update is ready to install... but after installing Win10 month ago and seeing packets int tcpdump EVERY second I firewalled it from inet... you just can't air gap that new beasts! ;) 08:35
08:36 lnrdo_ left
Woodi anyway installing Win10 was final proof that internet white-listing is way to go :) schools do this, Chinese too so users probably should too 08:37
08:43 pistacchio left 08:44 Amnez777 joined 08:45 Guest73034 joined
Guest73034 Hi! 08:45
So, cool to see a room with so many people interested in Perl
mojca Just curious, when I was building rakudo, moarvm built successfully. Now I see that it keeps failing due to a number of missing libraries like libuv, dynload, ...
I will add those libraries, I was just wondering why the difference in the default builds 08:46
08:46 azawawi joined
azawawi hi 08:46
yoleaux 13 Dec 2015 22:44Z <RabidGravy> azawawi: would you be cool with a PR to File::Which to make it optionally export 'whence' instead of which? It's an ancieunte SysV user thing ;-)
08:46 Amnez777 left, Amnez777 joined
mojca Where does dynload.h come from? 08:47
azawawi Merry Christmas to #perl6 :)
Guest73034 I'm in a but of a conundrum
I can't decide between nodejs or perl for re-writing my personal website 08:48
I've got experience with both
node is convenient because it can send javascript objects using that neat, convenient library 'socket.io'
perl is awesome because of its best regex support, the $_ variable, and how it allows me to type action then condition 08:49
and just like the http module for node, perl now has perldancer, which is easy as pie to work with
but with perl6 coming out I'm trying to come up with a reason to use perl + perldancer 08:50
since I think perl6 is going to blow ecmascript6 out of the water in terms of expressability and power 08:51
08:51 nash_ joined, peteretep left 08:52 pierre-vigier left 08:53 nash left 08:55 aenaxi left
nine mojca: ./nqp/MoarVM/3rdparty/dyncall/dynload/dynload.h 08:58
08:59 pmurias joined
mojca ok, but isn't moarvm a dependency of nqp? So how do I get nqp's files while building moarvm? 08:59
nine Guest73034: well it's no easy decision. Perl 6 is the better language, hands down. It's not even a competition. It's also very new, so with node you'll just build that website and be done. With Perl 6 you'll spend quite some time on writing libraries or getting into Inline::Perl5.
mojca I'm running into an error while building moarvm.
nine Guest73034: with Perl 5 you'll get Dancer, but also have a harder Perl to learn :) 09:00
mojca I can somehow circumvent the problem by providing --has-libffi and by adding -I${prefix}/lib/libffi-3.2.1/include to CFLAGS
09:00 pierre-vigier joined
Guest73034 Wait - Are you saying dancer2 won't work with perl6? 09:01
mojca and even if I configure with --no-jit, I get this error: src/jit/compile.c:2:10: fatal error: 'dasm_proto.h' file not found
ChoHag What's the opposite of recursive? 09:02
mojca: What system? 09:03
mojca x86_64-darwin (OK, an old one, 10.7)
ChoHag Darwin. Of course. The one that'll be a PITA to run a test VM of. 09:04
09:04 andreoss joined
mojca Does that mean that Darwin is not fully supported yet? 09:04
ChoHag I don't think there's a 'supported' umbrella for anything to even fall under. 09:05
09:05 Axord joined
ChoHag And I don't think any/many of the devs use OSX. 09:06
Woodi mojca: it's strange. those libraries are included in tarbal. and there are Configure switches if you want your own
mojca Which tarball? MoarVM's?
Woodi mojca: yes, moarvm. but if you use git then they should be included too 09:07
ChoHag If you use git you may need to update the submodules to get them.
mojca I'm using 2015.12
ChoHag git submodule update --init in src's root.
mojca the tarballs from github
Woodi ok, I was not sure about git :)
ChoHag ... _after_ git checkout/pull/whatever.
09:07 luiz_lha left 09:08 luiz_lha joined
mojca should I fetch the tarball from somewhere else? 09:08
I'll check
09:08 luiz_lha is now known as Guest44389, RabidGravy joined
mojca ok, I see now 09:09
the tarball I fetched from github is only 1,7M
ChoHag dynasm, dyncall, libuv and linenoise in $src/3rdparty should not be empty. If they are, the tarball lacks them and they need to be obtained somehow. If you have a $src/.git you can probably get then with the afformentioned submodule command.
mojca The one in the link is 3,1M
these folders are indeed empty 09:10
I fetched github.com/MoarVM/MoarVM/archive/2015.12.tar.gz 09:11
and that was most likely the problem
ChoHag Apparently osx works in kvm.
FSVO work.
Woodi mojca: I got moar from it's web page and it was fully functional :) 09:12
mojca I'll switch the source of downloads
Using GitHub is very handy, but useless if it fails to work 09:13
:)
Woodi mojca: few days ago was big release day so for some time official release tarbals are best thing, IMO :) 09:14
09:17 rindolf joined 09:18 keenan joined
andreoss should `rakudobrew build moar коледа` work properly? 09:18
mojca perfect, it almost works now; it stops with 3rdparty/libuv/src/unix/getaddrinfo.c:102:68: error: no member named 'res' in 'struct uv_getaddrinfo_s', but that's progress 09:19
andreoss for me it dies with 'Unhandled exception: Will not decode invalid ASCII (code point > 127 found)'
RabidGravy andreoss the probably not
09:20 ellybelly left
mojca (libuv itself can be installed without a problem) 09:20
09:20 dotness joined
nine Guest73034: you probably can combine Dancer2 with Perl 6. But that's experimental high tech territory. Note that Perl 5 and Perl 6 are really different languages. Bridging technology exists, but hasn't seen that much real world code yet: niner.name/talks/Building%20Bridges...ridges.pdf 09:20
AlexDaniel ChoHag: hmmm there's 「lazy」 but I'm not sure what is it supposed to do (is it even implemented?) 09:22
andreoss RabidGravy: seems like moarvm issue
Guest73034 I figure perl6 would have backwards compatibility
nine ChoHag: the opposite of "recursive" in programming is usually "iterative" 09:24
ChoHag I'd say that's alternative, not opposite.
09:25 pierre-vigier left
ChoHag At least outside of programming, which is what I meant. 09:25
09:25 keenan left
nine Remind me, why again we forcefully push people in rakudobrew's direction, when it's causing so many problems while building rakudo is just perl Configure.pl --gen-moar && make install 09:25
ChoHag Recursively in a 'searching through a tree' sense.
nine: Because it has bells and whistles.
RabidGravy nine, beats me 09:26
ChoHag Also, it's never "just".
That wouldn't have worked for mojca, for example.
nine To top it off it's barely maintained at all! So the first contact users have with rakudo is with a build tool that's barely maintained and known to cause all sorts of strange problems. 09:27
ChoHag Admittedly because one of the 3rd party libs doesn't seem to build on OSX, but still...
AlexDaniel ChoHag: so in DWIM fashion that would be something like 「sub foo { say ‘world’; return 42 }; my $x := lazy { foo }; say ‘hello’; say $x」, but it does not work
mojca which library doesn't build on OS X? 09:28
ChoHag Having not paid much attention to the public side of the announcement, where exactly are new folks directed to perl 6?
mojca (just out of curiosity)
09:28 pierre-vigier joined
nine ChoHag: mojca is hardly a normal user. He tries to build packages for distribution. Normal first time users really just need what I wrote above. 09:28
ChoHag mojca: libuv, apparently.
andreoss RabidGravy: should i report it?
09:28 atweiden left, azawawi left
mojca oh, no, libuv builds just fine 09:28
ChoHag nine: Experience teaches me that there's no such thing as a normal user, even outside of development circles.
mojca I figured out what the build problem was 09:29
Guest73034 Well personally as a new folk, I found my way thanks to some forum post. Watched a few youtube videos, was amazed.
09:29 keenan joined
mojca I was initially trying to build from github that was missing some 3rdparty libraries, including libuv 09:29
so I installed (an outdated) libuv from the package manage
ChoHag You pasted an error above of it failing to build. I jumped to a conclusion.
mojca *manager
RabidGravy andreoss, against "rakudobrew" possibly, it's not a moarvm issue as far as I can tell 09:30
mojca and then the build issue arised because the compiled used outdated headers from $prefix rather than headers from 3rdpart
nine ChoHag: rakudo.org/how-to-get-rakudo/ "Building from source", perl6.org/downloads/
andreoss it dies on compiling moarvm code 09:31
RabidGravy right, but it is almost certainly being given garbled up utf-8 by rakudobrew 09:34
andreoss but checkout from git works well 09:35
09:36 pierre-vigier left
RabidGravy yes 09:37
mojca I believe there is a bug in build scripts that put ${prefix}/include before the includes from 3rdparty in CFLAGS, but I eventually managed to compile MoarVM 09:38
the main problem now is that it wants to install a number of libraries that don't belong there 09:39
09:39 pierre-vigier joined
mojca for example, MoarVM now wants to install ${prefix}/include/libuv/uv.h 09:39
which it shouldn't
09:40 keenan left
ChoHag Can I specify a Signature in which extra named parameters are not welcome? 09:40
RabidGravy I'm not sure, doesn't nqp need to know about some parts of uv?
ChoHag Alternatively how can I construct a collection of multis which have 2 or more optional adverbs?
RabidGravy ChoHag, it is possible (the former) but a but of a mouthful 09:41
m: sub foo(:$foo!, *%b where *.keys == 0) {}; foo(:foo, :bar) 09:42
camelia rakudo-moar 373adc: OUTPUT«Constraint type check failed for parameter '%b'␤ in sub foo at /tmp/lI6uuivpfY line 1␤ in block <unit> at /tmp/lI6uuivpfY line 1␤␤»
09:42 zhi left
RabidGravy bit of a mouthful that is 09:43
ChoHag Don't like the look of that.
09:43 yeahnoob left
RabidGravy there has to be a slurpy hash as there is a default slurpy that you get if don't specify it and that will get any other nameds 09:44
you could probably make a sub or method trait that did it for you 09:45
Guest73034 I wonder what my little program in Javascript: pastebin.com/KAbJxniu would look like written in Perl? I'll have to get to it! 09:46
09:47 nowan_ joined 09:48 ellybelly joined
RabidGravy Guest44389, it wouldn't be any longer in P 6 09:49
09:50 nowan left 09:51 pierre-vigier left 09:52 pierre-vigier joined 09:53 pierre-vigier left, pierre-vigier joined 09:54 niceperl joined
mojca nine, ChoHag, Woodi: installation of moarvm was finally successful, but I need to get rid of all the additional libraries which shouldn't be installed together with that package 09:55
09:55 nowan joined, nowan_ left 09:56 znpy joined
ChoHag Dependency tracking is a hairy problem. 09:56
I expect including those 3rd party libraries was a solution deemed good enough for development time. 09:57
09:58 nash_ left
ChoHag Now that it's reached 'production' (FSVO) they need a bit more nuance. 09:58
RabidGravy I know of things that have been around for years that bundle some of their dependencies, usually because there is so much variance in version in the wild
09:59 labster left
ChoHag Including dependencies is fine. Building them and installing them without consideration of the external environment less so. 09:59
RabidGravy yeah, should go in a private place 10:00
10:00 lnrdo joined, lnrdo left
ChoHag foo():bar:baz just calls foo(:bar, :baz) right? 10:01
10:01 lnrdo joined
ChoHag So what does foo():bar:baz($bing) do? 10:02
RabidGravy in the former case you get booleans, in the latter baz haz the value of $bing and bar is still a boolean 10:04
ChoHag Not that. 10:05
nine After reading many posts on hacker news of all sites it's really depressing to see so much negativity on lwn.net.
ChoHag It doesn't appear to call foo(:bar, :baz($bing)). 10:06
nine: Welcome to the internet.
nine ChoHag: lwn.net used to be a shining safe haven with comments that really add to the site's content. 10:07
RabidGravy ChoHag, no really it does
m: sub foo(*%foo) {say %foo}; foo():foo:bar("ghshs")
camelia rakudo-moar 373adc: OUTPUT«bar => ghshs, foo => True␤»
ChoHag RabidGravy: I think it changes when there are (possibly mis-Signatured) multis. 10:08
10:08 sno left
RabidGravy ah 10:08
10:10 espadrine joined
ChoHag Another problem for later. 10:11
10:12 Su-Shee_ is now known as Su-Shee 10:15 FritzZaucker joined 10:18 Arrowhead joined 10:19 FritzZaucker left
mojca I submitted github.com/MoarVM/MoarVM/issues/320 github.com/MoarVM/MoarVM/issues/321 github.com/MoarVM/MoarVM/issues/322 10:20
Feel free to comment if I got anything of that wrong
andreoss > $ /home/andreoss/rakudo/коледа/bin/moar --libpath=src/vm/moar/stage0 src/vm/moar/stage0/nqp.moarvm --bootstrap --setting=NULL --no-regex-lib --target=mbc 10:21
> Unhandled exception: Will not decode invalid ASCII (code point > 127 found)
10:21 FritzZaucker joined
andreoss RabidGravy: definitely not a rakudobrew issue 10:21
FritzZaucker github.com/jnthn/perl6-reactive-sa...olf-helper .... the callbacks on schedule have errors with 6.c .... can anybody advice what must be changed? 10:22
10:24 moritz_ joined
moritz_ oh hai 10:24
10:24 znpy left
Guest73034 oh hai 10:24
moritz_ how are things here, post-christmas?
RabidGravy FritzZaucker, for one thing it predates NativeCall being in core so that part is un-necessary 10:25
andreoss, that doesn't mean it's Moars fault, it just means that "something" is putting a badly encoded string somewhere it shouldn't 10:26
10:27 FritzZaucker left, FritzZaucker joined
andreoss RabidGravy: i run moar directly from shell, what else could it be? 10:29
RabidGravy how did the moar get built? 10:30
andreoss with non-ascii prefix yes 10:31
dalek : 6eec18f | moritz++ | util/update-design.perl6.org.sh:
Attempt to fix design.perl6.org/S26.html 403 error
RabidGravy I would contend then that "something" while configuring moar caused a poorly encoded string to get into the compiled moar, so my first suspect in this case would be rakudobrew, my second suspect would be moar's configure 10:33
moritz_ .tell Ulti re irclog.perlgeek.de/perl6/2015-12-26#i_11782724 please ping in 2016 about that, currently not at home
yoleaux moritz_: I'll pass your message to Ulti.
moritz_ thanks everybody, and most of all [Coke]++, for the great release 10:35
moritz_ disappears into the bottomless void of mobile-only Internet again 10:36
10:36 moritz_ left
andreoss also, why moarvm uses Windows-style path separator? 10:36
in its trace stack
nine andreoss: it usually doesn't? 10:38
andreoss may be i haven't noticed before 10:39
nine: is it a default? why? 10:40
lizmat good *, #perl6!
yoleaux 04:05Z <gfldex> lizmat: should the last pair vanish in 'm: dd({:a(1), :b(2)}, :c(3));' ?
RabidGravy marnin
pmurias lizmat: HI 10:41
lizmat .tell gfldex dd only takes positionals and ignores nameds: that was the only way to get positionals to work and keep order of specification
yoleaux lizmat: I'll pass your message to gfldex.
lizmat pmurias o/
RabidGravy FritzZaucker, it appears that if you change the schedule_on to schedule-on and use the GTK::Simple from the ecosystem it dies in an altogether more interesting way
lizmat pmurias: I understand you have a grant proposal? do you have a url handy ? 10:42
nine andreoss: it does _not_ use Windows path separators: install/share/perl6/runtime/perl6.moarvm:<dependencies+deserialize>:6
andreoss paste.debian.net/356698/ 10:43
> at gen\moar\stage2\NQPHLL.nqp:6 (src/vm/moar/stage0/NQPHLL.moarvm::48)
nine andreoss: the gen\moar\stage2\NQPHLL.nqp is what the source code claims for a file name 10:44
diakopter nqp is usually bootstrapped on a windows machine 10:48
re-bootstrapped
10:48 Guest73034 left
diakopter there's a version of nqp in its repo (called stage0) that is built from the last successfully bootstrapped one. it was originally bootstrapped from a port of pmichaud's original nqp compiler/regex engine for parrot 10:49
10:50 FritzZaucker left
pmurias lizmat: grant proposal draft -> github.com/pmurias/grant_proposal/.../draft.pod 10:50
10:50 FritzZaucker joined
andreoss diakopter: how can i cleanse this ugly stuff? 10:51
10:51 dotness left
diakopter I suppose you could make your own bootstrap build 10:51
FritzZaucker RabidGravy: thanks, I'll try later. 10:52
10:52 nexysno_ joined
andreoss diakopter: rakudobrew does --gen-moar isn't it enough? 10:53
10:54 cygx joined
nine andreoss: more importantly: why do you wish to "cleanse" this stuff? 10:54
andreoss nine: it looks bad 10:55
10:55 skyl4rk joined
cygx andreoss: you understand how bootstrapping works? 10:57
nine andreoss: you will see this only when NQP's build fails. Once NQP is built, it will show paths according to your platform's conventions.
cygx packaging an nqp build for both *nix, windows, $whatever just to make it look better is not a good idea
andreoss cygx: probably not, but i guess you need a existing nqp to build a new one
diakopter andreoss: but yes, there is a bug there preventing using that коледа tag 10:58
I suspect it's in the filename annotation system 10:59
10:59 vendethiel joined 11:00 sno joined
diakopter when I originally wrote it for moarvm it handled only ascii filenames/paths; I wonder if that old convention persisted to today 11:00
11:00 _mg_ joined
cygx andreoss: yes, and that nqp version can be found in github.com/perl6/nqp/tree/master/s...oar/stage0 according to the platform conventions used by the system it was last updates from 11:01
11:01 sno left, patrickz joined, patrickz left 11:02 crux left
cygx there might a discussion to be had if some conventions should be checked at run-time instead of compile-time if we wanted to distribute .moarvm files 11:02
that's not the direction we seem to be going in, though
11:03 patrickz joined 11:05 FritzZaucker left 11:09 pierre-vigier left
lizmat m: say DateTime.new(1972,12,31,23,59,60,0).later(:86400second) 11:09
camelia rakudo-moar 373adc: OUTPUT«1973-01-01T23:59:59Z␤»
lizmat m: say DateTime.new(1972,12,31,23,59,60,0).later(:1day) 11:10
camelia rakudo-moar 373adc: OUTPUT«1973-01-02T00:00:00Z␤»
lizmat these results seem inconsistent to me
if we take the same logic as we have with leap-days, then :1day result should be the same as the :86400second result 11:11
.tell masak is there a reason why DateTime.new(1972,12,31,23,59,60,0).later(:86400second) and DateTime.new(1972,12,31,23,59,60,0).later(:1day) should give different results ? 11:16
yoleaux lizmat: I'll pass your message to masak.
11:18 niceperl left
timotimo oh my word, the backlog is gigantic 11:21
cygx lizmat: depends on whether you define a day as a (variable-length) calendar day, or a constant unit of time
11:22 _mg_ left
cygx tough the former doesn't really make sense if yo use the day as a duration 11:23
11:23 xinming joined
cygx I guess what it comes down to is whether 11:24
11:24 nowan left, vendethiel left
cygx * .later(:1day) should add a day, or refer to the same time on the next day 11:24
mojca Is it OK to fetch NQP from github.com/perl6/nqp/archive/2015.12.tar.gz or are there any caveats like for MoarVM as well? 11:25
nine timotimo: yes, the usual slow down during European night is far less visible now 11:26
timotimo ugh :)
11:26 xinming_ left 11:27 nowan joined
ShimmerFairy considering we already take a day to be 24 hours in this case, I'd lean towards the more human-friendly choice :) 11:28
11:28 crux joined
lizmat cygx: so would you consider the current result correct or incorrect ? 11:29
cygx mojca: I think it's fine, but the 'supported' ways to get the source via `git clone` or from moarvm.com/releases.html and rakudo.org/downloads/
lizmat I mean, if we go from 2016-01-31 + 1 month, we wind up in 2016-02-29 11:30
aka, we don't carry over to the next month
this is even documented in the code:
# If we overflow on days in the month, rather than throw an 11:31
# exception, we just clip to the last of the month
ShimmerFairy lizmat: I think I'd expect it to be the same as :86400seconds , since that will be "tomorrow, at this same time" according to human eyes :)
cygx ShimmerFairy: not if there's a leap second
11:33 araujo left
ShimmerFairy cygx: technically, yes, but a human would see the clock and say that 1973 Jan 1 23:59:59 is exactly one day since 1972 Dec 31 23:59:59 11:33
cygx ShimmerFairy: but then :1day !== :8400seconds, and your comment no longer makes sense ;) 11:34
ShimmerFairy oh wait, I was misreading the tests.
lizmat: is there any case where we can really expect someone to try 60 as a number of seconds and then get upset that :1day and :86400seconds aren't the same? 11:35
cygx lizmat: I guess same time next day would be more DWIM-y 11:36
11:36 araujo joined
cygx which opens up the question, what should :24hours do 11:36
11:36 hassoub joined
lizmat well, I've been looking at making DateTime.later more efficient 11:36
11:37 araujo left
lizmat and my patch breaks a number of tests... the above being one of them 11:37
(basically)
11:37 araujo joined, sno joined
lizmat so I was asking masak what his thinking was when implementing this 11:37
as this behaviour seems to be different from the behaviour seen when moving 1 month from a day that doesn't exist in the next month 11:38
11:39 araujo left
ShimmerFairy lizmat: my feeling is that :second is a precise statement of how many seconds you want to advance, while :day will read as "give me the next day", a less precise measure to be asking for. 11:39
11:39 araujo joined, pneuma left, hassoub left
ShimmerFairy lizmat: so, my feeling on :day is the same as it was on :month; when I say the next month of Jan 31, I'm really expecting February, not March :) 11:39
lizmat right, so you agree with my point :) 11:40
m: say DateTime.new(1972,12,31,23,59,60,0).later(:1day) # should be on Jan 1
camelia rakudo-moar 373adc: OUTPUT«1973-01-02T00:00:00Z␤»
ShimmerFairy lizmat: yes, because I at least mean the next square on the calendar when I say "1 day later", not a precise accounting for leap seconds and such :) 11:41
ChoHag Maths on dates? 11:43
Hold on. Need popcorn.
OK continue. 11:44
cygx personally, I only measure time in beats of (86400/1024)s since Unix epoch 11:46
who cares about such h´things as 'minutes', 'hours' or 'days' :p
mojca What's the proper way to check the output of tests and the proper place to report failures? 11:48
I get t/hll/06-sprintf.t .................... Failed 7/265 subtests
t/nqp/60-bigint.t ..................... Failed 1/80 subtests
ChoHag minutes and hours are arbitrary but the day and year are perfectly cromulent units of measure. 11:51
And, incidentally, why decimal time measurement is a ridiculously stupid idea.
cygx mojca: moarvm an nqp bugs are tracked on github, for rakudo proper, send an email to [email@hidden.address] with a subject starting in [BUG]
you can run test files manually (./nqp 11:52
11:52 Psyche^ joined
llfourn mojca: perl t/harness --verbosity=5 t/spec/[the test(s)] 11:52
cygx * `./nqp t/nqp/60-bigint.t`
llfourn mojca: usually with --fudge --moar as well
cygx ChoHag: my atomic clock has no setting for 'days' or 'years'
ChoHag Well that's a shame because the planet you live on does, and they're hard-coded. 11:53
mojca nqp doesn't accept --fudge or --moar
I get not ok 39 - mod_I - positive and negative 11:54
llfourn mojca: sorry I thought you were talking about rakudo :)
mojca but I'll try perl5
11:56 Psyche^_ left
mojca anyway, nqp::mod_I(box(12), box(-4), $bi_type) from that test suite returns -4 11:58
I guess I should report that to the nqp bug tracker then?
12:00 pierre-vigier joined
nine mojca: yes, nqp 12:00
llfourn mojca: if nqp test suite is failing for you I think so
Woodi but in humans languages :nextMonth != +30days and last day in a month is a special case in speaking language 12:05
12:09 joydo left, Skarsnik joined
cygx m: say <42>.^name 12:13
camelia rakudo-moar 373adc: OUTPUT«IntStr␤»
cygx ^^ bug? single values without spaces shouldn't be allomorphic
m: say <42+3i>.^name; say < 42 + 3i >.^name
camelia rakudo-moar 373adc: OUTPUT«Complex␤List␤»
cygx m: say <42+3i>.^name; say < 42+3i >.^name 12:14
camelia rakudo-moar 373adc: OUTPUT«Complex␤ComplexStr␤»
12:17 zengargoylew left 12:18 zengargoylew joined
cygx got to go o/ 12:19
12:19 cygx left 12:21 asa_ joined, asa_ is now known as Guest15478 12:25 lustlife joined 12:26 xpen_ left, kovi joined, xpen joined 12:27 xpen left 12:28 CIAvash left
mojca I now installed MoarVM and NQP. The build of rakudo is successful (many tests fail though or have a parse error). 12:29
But I'm unable to run the destroot phase.
./perl6-m tools/build/install-core-dist.pl
No writeable path found in block <unit> at tools/build/install-core-dist.pl line 12
nine mojca: do you build rakudo nom or 2015.12?
mojca 2015.12 12:30
nine Oh, a fix for that issue is in nom
12:32 CIAvash joined, lnrdo left
nine mojca: I'm more worried about your test failures though. Are you sure, your MoarVM build uses only the bundled libraries? 12:32
12:32 lnrdo joined 12:33 mohij joined 12:34 vendethiel joined
mojca is nom just a "synonym" for "master/trunk"? 12:35
I'll try to use that one then
lizmat mojca: yes
mojca I'll double-check the libraries being used
lizmat hysterical raisins
it stands for "new object model" (which was once new) 12:36
mojca I need to figure out what to do about the libraries though because it will be a bit annoying to have perl6 conflict with a number of other ports
vendethiel
.oO( we still think it's cute )
mojca ports = packages
12:37 mohij left
jdv79 ugexe: yeah. i've just started looking into this stuff. might be a while til i get anything useful done as i'll be traveling more in the next few weeks. 12:37
mojca would it be acceptable to use perl6 with external libraries if I make sure that all external libraries are really up-to-date?
that is: as the long-term goal
jdv79 ugexe: maybe someone else could pitch in:) but if not i'll hit it when i get back. 12:38
mojca for testing it's fine if I use the internal ones
RabidGravy mojca, if it can be made to work then I am sure the input would be much appreciated :)
mojca Or this one would have to be addressed: github.com/MoarVM/MoarVM/issues/321
12:38 kid51 joined 12:42 Arrowhead left 12:45 TEttinger left
nine mojca: please note that AFAIK MoarVM uses a somewhat outdated version of libuv currently. It needs to be updated at some point. I guess it's very much dependent on libuv's stability (as in API) track record if we can use external libraries 12:45
12:47 kid51 left
RabidGravy mojca, fwiw there's a #moarvm channel where there may be less noise to discuss these matters :) 12:47
12:47 CIAvash left
mojca thank you 12:47
RabidGravy but I think there would probably be broad agreement with what you are suggested 12:48
er suggesting
timotimo lizmat: "nom regression" :) 12:50
12:50 Guest15478 left
cosimo hi folks! 12:52
timotimo hey cosimo
cosimo (my first message of the post-Christmas era) :-)
12:53 saaki left
RabidGravy yo! 12:53
cosimo any comments on such issues? github.com/cosimo/perl6-digest-md5/issues/15
why should I or shouldn't I change the code to kebab-case?
12:54 saaki joined
RabidGravy well, the expectation set by the Perl 6 core API is for kebab-case rather than snake_case but it's probably a matter of taste in modules 12:55
12:55 nash_ joined, lustlife left
RabidGravy I'd go with add kebab-case, deprecate the camel_case and remove them some point in the future to minimise the fallout 12:56
cosimo specifically for modules that are transposed from p5, I would expect the same names
RabidGravy do both then
:)
cosimo is there some *md5-hex = *md5_hex kind of aliasing?
timotimo constant &md5-hex = &md5_hex
nine cosimo: I'd use camel_case for the P5 interface and if you add a more 6ish interface, use kebab-case for that
cosimo nine: yes. makes sense to me. In that case, I would drop Digest::MD5 entirely and have a Digest module (sort of python's hashlib) 12:57
thanks guys 12:58
13:00 nash_ left
RabidGravy .seen tony-o 13:01
yoleaux I saw tony-o 18 Dec 2015 18:38Z in #perl6: <tony-o> lol
RabidGravy not entirely missing then
RabidGravy fixes HTTP::Server::Async anyway 13:02
13:10 lustlife joined 13:12 Guest44389 is now known as luiz_lha
cosimo stupid q. what's the difference between 'constant T = 42' and 'my \T = 42' ? what's 'my \T' anyway? 13:13
Skarsnik A sigil less variable 13:14
nine cosimo: \T is a sigilless variable, that's a variable that doesn't impose any interface at all on its contents (while e.g. an @array forces the contained object to do the Positional role)
13:15 Grrrr joined
nine cosimo: my $foo forces a Scalar container, i.e. something that can be assigned to. 13:15
cosimo next q is why would I need a sigilless variable? 13:16
f.ex. here github.com/cosimo/perl6-digest-md5...est/MD5.pm
nine cosimo: you mostly don't. It's an advanced too for when you know you need it :)
s/too/tool
13:17 kovi left
timotimo sonic-pi.net/ - this is cute! 13:19
13:22 rburkholder joined 13:23 _mg_ joined
Skarsnik quick, someone do a perl 6 implementation in a slang x) 13:24
of this
RabidGravy timotimo, yeah I saw that before, it's just a shame there doesn't appear to be any source code available
13:25 Ch0c0late joined, X-Scale left
timotimo no source code? 13:26
awwaiid nine: I like this terminology of sigils being Role restrictions
timotimo wtf.
awwaiid timotimo: Skarsnik: there is definitely source, lemme see...
RabidGravy Skarsnik, a binding to libpd or supercollider would work too, I've got one of those on my TODO but way way down
awwaiid github.com/samaaron/sonic-pi
RabidGravy aha, awwaiid++ just not obvious enough for me then ;-) 13:27
awwaiid I've read through the source -- it is from one of the authors of Overtone (clojure), and interestingly one of the first thing the author does in sonic-pi is to add some functional helpers to ruby
13:27 _mg_ left
awwaiid RabidGravy: yeah -- the site is more for consumers than for developers 13:27
timotimo just watching the lightning talks from the 32c3 right now
of course the topics wildly differ 13:28
streaming.media.ccc.de/ - there's also a switch at th ebottom between "native" and "translated"
so if the tack is german, you can get the synchronous translation instead
RabidGravy so supercollider binding then - shouldn't me much of an ask
13:29 n0xff left 13:30 lustlife` joined 13:31 n0xff joined
awwaiid RabidGravy: timotimo: github.com/samaaron/sonic-pi/blob/...pi/atom.rb -- port of clojure's atom to ruby, give or take. Kind of a gem hidden in here! 13:32
Skarsnik I should try atom, how well it fair on not so new PC? 13:34
13:34 lustlife left
awwaiid Skarsnik: this 'atom' is a concurrency construct, not the editor 13:36
timotimo yeah, but i think he just got inspired
awwaiid ah :)
timotimo by the name alone
Skarsnik ? Oh I was lost watching if there was an update of my perl6 syntaxhightligh for Kate
RabidGravy jnthn's OO::Monitor does something similar I think 13:37
gah, HTTP::Server::Async has a bug in chunked decoding brought on by the \r\n thing 13:40
where is that guy who fixed up the chunked stuff for H::UA when you need him
awwaiid OO::Monitor looks like a superset of the functionality of atom's swap! ; in clojure (def foo (atom 5)) (swap! foo inc) does an optimistic increment of the contents of foo -- if some other thread modifies foo at the same time, the swap! will throw away its result and try again (over and over until it "wins"). so swap! takes an atom and a function, passing the function the current contents of the atom 13:41
vendethiel atom, agents, ref... clojure's STM is lovely
awwaiid yeah
and very-built-in
seems like one could build equivalent apis with clean syntax in p6 13:43
RabidGravy yeah all the bits are there I guess
awwaiid my Atom $foo = 5; $foo.swap(*++) 13:44
garu everyone++ # great work!
awwaiid Greetings garu 13:45
garu hi awwaiid :) 13:46
vendethiel fwiw, monitor is not really akin to swap!, because it doesn't in any way. Doesn't 13:47
13:47 aenaxi joined
awwaiid vendethiel: because it doesn't retry? 13:47
vendethiel ask for purity... Instead, it just locks
Skarsnik hm, does roles get copied/cloned when doing my $b = $a ? 13:48
timotimo that's not a copy or clone operation
that.s just an assignment
awwaiid vendethiel: yeah, I see what you mean
m: my Int $x = 2; my $y = "foo"; my Str $z = "bar"; $y = 2; $z = $x; 13:49
camelia rakudo-moar 373adc: OUTPUT«Type check failed in assignment to $z; expected Str but got Int␤ in block <unit> at /tmp/fGYjavM_Ea line 1␤␤»
awwaiid er. close enough 13:50
Skarsnik I suspect NC lead to leak when copying Str returned because there are tagged with the role ExplicitlyManaged and if this role get propagated on copy... well it's suck x)
ChoHag Can perl6 print a trace of function calls as they're made? 13:53
13:53 disturbingly_rea joined
ChoHag It'd save me sticking print statements at the beginning of every function. 13:53
garu I'm getting "Could not find symbol '&bool' in block at /Users/garu/.rakudobrew/moar-nom/install/share/perl6/sources/8C0492C68474778534A631C115702858D0FF276E line 13" during rakudobrew build moar
Skarsnik remove an old install 13:54
garu a-ha! thanks
13:54 daxim joined
Skarsnik We should do a small FAQ 13:54
but it will mostly end in "nuke and reinstall" x) 13:55
garu I should have tried this before... guess I'm just not used to "reinstall" as a way to fix things on a non-windows box :)
awwaiid ChoHag: I think I saw something about tracing in a commit message. Lemme see here.... but in the mean time you should try out my LREP lib ;) 13:56
RabidGravy garu, quite a few imcompatible changes went in the last few weeks
incompatible viz installation that is
13:57 loren joined
garu RabidGravy: I see... I did do a rakudobrew self-upgrade, guess I was expecting it to be on par with the recent updates 13:57
loren Evening , #Perl 6
disturbingly_rea m: say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}})[1]; say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}}).flat[1];
camelia rakudo-moar 373adc: OUTPUT«((2 1) (2 2))␤1␤»
disturbingly_rea what's the correct way of getting (2 1) here?
flat does more flattening than I expected 13:58
Skarsnik I am tempted to add State in DBIish x)
13:58 _wiz_ joined
awwaiid m: say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}})[1]; say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}}) 13:58
camelia rakudo-moar 373adc: OUTPUT«((2 1) (2 2))␤(((1 1)) ((2 1) (2 2)) ((3 1) (3 2) (3 3)) ((4 1) (4 2) (4 3) (4 4)) ((5 1) (5 2) (5 3) (5 4) (5 5)))␤»
awwaiid m: say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}})[1]; say ((1..5).map:{my $t = $_; (1..$t).map:{($t,$_)}}).flat 13:59
camelia rakudo-moar 373adc: OUTPUT«((2 1) (2 2))␤(1 1 2 1 2 2 3 1 3 2 3 3 4 1 4 2 4 3 4 4 5 1 5 2 5 3 5 4 5 5)␤»
awwaiid ah, I see
loren m: my @x = (1, 2, 3, 4, 5, 6, 7, 8);for @x -> $y { say $y; my $z = @x.shift; say $z; }; ## access '@x' in 'for' make output a mess
camelia rakudo-moar 373adc: OUTPUT«1␤1␤3␤2␤5␤3␤7␤4␤»
_wiz_ how can I subscribe to perl6 bugs on rt.perl.org? when I log in, I don't have any rights to any open bug reports.
I can't even search for them.
ChoHag awwaiid: Your lrep evangelism doesn't come with a link I'll be able to check out when I come home later.
loren Someone can explain this ?
_wiz_ using a bitcard login.
mojca Can someone please suggest me about these test results? pastebin.com/qFHHgbRu 14:00
awwaiid ChoHag: github.com/awwaiid/p6-lrep ; panda install LREP, then 'use LREP; ... ; LREP::here;' <- will open a REPL prompt 'here'
14:01 madjestic joined
Skarsnik mojca, try running one of the test alone? 14:01
garu _wiz_: you should be able to search rt without an account by going to rt.perl.org/Public/ and clicking on the "perl6" queue
Skarsnik the harness on Test is really bad most of the time..
awwaiid ChoHag: then from the prompt you can look around. It's not a trace, but lets you dynamically explore what is going on in the middle of your proggie
_wiz_ garu: yes, that works, but I want to subscribe to a bug I didn't file 14:02
and for that I need an account
garu _wiz_: oh, right
awwaiid disturbingly_rea: I don't know what to do, but maybe you need to sprinkle in a 'flatmap' instead of a map for one of those things
cosimo what do you guys use as repl? just perl6? 14:03
mojca what does the file $prefix/share/perl6/repo.lock do on the list of installed files?
disturbingly_rea m: say (1..5).flatmap:{my $t = $_; (1..$t).map:{($t,$_)}};
camelia rakudo-moar 373adc: OUTPUT«(1 1 2 1 2 2 3 1 3 2 3 3 4 1 4 2 4 3 4 4 5 1 5 2 5 3 5 4 5 5)␤»
Zoffix looks up and notices we have 40 more people than usual here
ChoHag Consider it logged.
ChoHag out
disturbingly_rea cosimo: yeah, I just use perl6
cosimo any possibility of readline support and/or tab completion?
Zoffix cosimo, there's Linenose 14:04
awwaiid cosimo: right now perl6 by itself is the main option. I'm building a toy named LREP (it provides perl6-lrep), but it has less features. someone is also working on a jupyter backend (aka iPython) which should be awesome
Zoffix cosimo, modules.perl6.org/repo/Linenoise
cosimo ah, cool
awwaiid cosimo: yes, if you 'panda install linenoise' then your perl6 built-in repl will be a lot more useable
hoelzro cosimo: Readline support also exists as of yesterday
cosimo there's already multiple efforts to build a repl :)
awwaiid hoelzro: orly?
Zoffix cosimo, there may be a module named Readline or something that's better.... Totally forget the name, but I saw a commit fly by mentioning it
madjestic hey guys, I am new to perl6. I am getting Unable to load setting CORE; maybe it is missing a YOU_ARE_HERE? error in REPL. What am I missing? 14:05
awwaiid cosimo: the more the merrier :)
hoelzro awwaiid: yeah, I added it yesterday
cosimo cool
hoelzro unfortunately, the Readline support doesn't yet have tab completion
timotimo madjestic: sounds a bit like installation went wrong; does it work without the REPL?
like, with a simple -e 'say "hi"' or a perl6 source file?
loren Anyone can explain this code's problem #_#
awwaiid hoelzro: is it better than linenoise because it is doesn't need an additional lib?
loren m: my @x = (1, 2, 3, 4, 5, 6, 7, 8);for @x -> $y { say $y; my $z = @x.shift; say $z; }; ## access '@x' in 'for' make output a mess
camelia rakudo-moar 373adc: OUTPUT«1␤1␤3␤2␤5␤3␤7␤4␤»
disturbingly_rea m: say (1..5).flatmap:{my $t = $_; (1..$t).map:{$($t,$_)}}; 14:06
camelia rakudo-moar 373adc: OUTPUT«((1 1) (2 1) (2 2) (3 1) (3 2) (3 3) (4 1) (4 2) (4 3) (4 4) (5 1) (5 2) (5 3) (5 4) (5 5))␤»
disturbingly_rea that's the badger
awwaiid disturbingly_rea: woo!
madjestic timotimo: I'll try a hello world example
hoelzro awwaiid: the linenoise module bundles the linenoise lib; a lot of people just prefer GNU readline it seems
awwaiid hoelzro: ahh. I thought linenoise was just another readline interface 14:07
ShimmerFairy loren: looks like the internal pointer (or whatever it is) doesn't update along with a change in the array's size or something. The solution of course is to not modify an array you're looping over :) 14:08
awwaiid loren: that's pretty interesting. I think the for loop maybe iterates over a copy or snapshot of @x?
mojca Skarsnik: how do I run a single test? I can run "perl5.22 t/harness --moar t/01-sanity", but I don't know how to run a single one 14:09
RabidGravy takes all the "no precompilation" out of H::UA finds it still works 14:10
mojca running "perl6 53-transpose.t" is successful though
loren m: my @x = (1, 2, 3, 4, 5, 6, 7, 8);for @x -> $y { say $y; my $z = @x.shift; say '-' ~ $z; }; ## access '@x' in 'for' make output a mess
camelia rakudo-moar 373adc: OUTPUT«1␤-1␤3␤-2␤5␤-3␤7␤-4␤»
loren awwaiid, i think it's not a copy .. 14:11
Skarsnik mojca, err, that not a good sign x)
Zoffix m: my @x = (1, 2, 3, 4, 5, 6, 7, 8);for [@x] -> $y { say $y; my $z = @x.shift; say '-' ~ $z; };
camelia rakudo-moar 373adc: OUTPUT«1␤-1␤2␤-2␤3␤-3␤4␤-4␤5␤-5␤6␤-6␤7␤-7␤8␤-8␤»
mojca which part is not a good sign? 14:12
Skarsnik if it's run fine without the harness
14:13 madjestic left
loren ShimmerFairy, em, but sometime we have to do this . 14:13
_wiz_ what are the files in pandas.pydata.org/ 14:14
aehm
share/perl6/short
?
ShimmerFairy loren: I think I just have a habit of using a separate "output" array; I have no clue what I would expect further iterations to be if I modified the array beyond the current element, so I wouldn't risk trying it. 14:15
loren Zoffix, i want get element one by one from '@x'
Zoffix loren, what's with the shift business?
mojca Skarsnik: ok, but how should I run the tests? I know "make test" and don't know what to do if a number of tests don't even start 14:16
14:16 ab6tract joined
Zoffix m: my @x = 1..8; for @x -> $y { say $y; say "-$z"; }; 14:16
camelia rakudo-moar 373adc: OUTPUT«5===SORRY!5=== Error while compiling /tmp/7vsqSQPTR3␤Variable '$z' is not declared␤at /tmp/7vsqSQPTR3:1␤------> 3@x = 1..8; for @x -> $y { say $y; say "-7⏏5$z"; };␤»
Zoffix m: my @x = 1..8; for @x -> $y { say $y; say "-$y"; };
camelia rakudo-moar 373adc: OUTPUT«1␤-1␤2␤-2␤3␤-3␤4␤-4␤5␤-5␤6␤-6␤7␤-7␤8␤-8␤»
ab6tract loren: the for loop construct is not the one you want for mutating and array
use while or until for that 14:17
Skarsnik mojca, I don't know, I was hoping running a test alone give some clue or why it fail
mojca as I said, it doesn't fail
it just doesn't start
Zoffix m: my @x = 1..8 .map: {$_, -$_ }; say @x
camelia rakudo-moar 373adc: OUTPUT«Seq objects are not valid endpoints for Ranges␤ in block <unit> at /tmp/WubEYUfVpA line 1␤␤»
Zoffix orly
mojca I mean, "make test" skips the test
loren Zoffix, oh, For instance, i have a file content like this 'EN = A\n CN = \n EN=...'
mojca Dubious, test returned 1 (wstat 256, 0x100), No subtests run
_wiz_ does panda support DESTDIR?
ab6tract m: my @x = (1, 2, 3, 4, 5, 6, 7, 8); while +@x { my $z = @x.shift; say $z; say '-' ~ $z; }; 14:18
14:18 rburkholder left
camelia rakudo-moar 373adc: OUTPUT«1␤-1␤2␤-2␤3␤-3␤4␤-4␤5␤-5␤6␤-6␤7␤-7␤8␤-8␤» 14:18
Zoffix _wiz_, I think I have seen someone open a bug report that --prefix doesn't work
loren Zoffix, when a read a EN line, i want read next line immediately
Zoffix loren, why? What are you trying to accomplish?
loren ab6tract, which loop control should i use ? 14:19
ab6tract loren: see my example above
_wiz_ zoffix: PREFIX is something else than DESTDIR, but good to know.
mojca Skarsnik: oh, I have found the way
loren Sorry, my example is in the company's computers
mojca perl5.22 t/harness --verbosity=9 --moar t/01-sanity/53-transpose.t
Failed to create directory '/opt/local/share/perl6/vendor/dist' with mode '0o777': Failed to mkdir: 13
Zoffix m: my @x = 1..8; for @x -> $y, $z { say $y; say "-$z"; }; 14:20
camelia rakudo-moar 373adc: OUTPUT«1␤-2␤3␤-4␤5␤-6␤7␤-8␤»
Zoffix loren, ^ you can also do that
ab6tract m: my @x = (1, 2, 3, 4, 5, 6, 7, 8); while +@x { my $z = @x.shift; my $y = @x.shift if $z %% 2; say $y if $y; say '-' ~ $z; };
camelia rakudo-moar 373adc: OUTPUT«-1␤3␤-2␤5␤-4␤7␤-6␤-8␤»
Skarsnik mode 777 what the hell
mojca This is expected because the package manage wouldn't let the package mess up with $prefix
RabidGravy quick straw-poll is anyone seeing the problem rt.perl.org/Ticket/Update.html?id=126832 ? H::UA doesn't do it and the easy reproduction doesn't
ab6tract loren: " $z %% 2;" this would be your test for EN line
mojca until it's asked to do so
is there any remedy for that? 14:21
nine _wiz_: the files in share/perl6/short are quick lookup files that map from module name to distribution containing such a module.
Zoffix RabidGravy, that link sucks :)
Skarsnik RabidGravy, thta the update page x)
RabidGravy oh
nine mojca: does make test work _after_ a make install?
ab6tract loren: does this make more sense? 14:22
14:22 _mg_ joined
_wiz_ nine: thanks. are the hashes stable across operating system versions or operating systems? 14:22
RabidGravy rt.perl.org/Ticket/Display.html?id=126832 :-p
mojca what should a make install change?
I already installed rakudo, yes
loren Wait a moment, i make a example
nine _wiz_: yes. It's just a sha1 of the module name
Zoffix ab6tract, that code is terrible :|
_wiz_ nine: good news! thank you.
ab6tract Zoffix: I'm getting a bit tired of your negativity tbh
Skarsnik nine, mkdir with 777 permission sucks x)
mojca nine: but the package manager doesn't let the package create a directory 14:23
ShimmerFairy Skarsnik: it will respect your umask, fwiw, it's just LTA that it doesn't factor that in :)
nine Skarsnik: that 0o777 is subject to your umask
mojca and I'm not sure where that is done
ShimmerFairy *that in to the message, that is
ab6tract some days it feels like every other line out of your irc client is trash talk
mojca because 53-transpose.t doesn't have any signs of creating directories
Zoffix Only some days? :)
ab6tract dude, it's not cute
Zoffix Wasn't trying to be
nine mojca: rakudo tries to create the directory when it's looking for a module
mojca scratching my head ... 14:24
why?
nine mojca: that was just a shortcut I took and was never meant to be a permanent solution. It's just that the release came in between.
Zoffix RabidGravy, do I need to set NETWORK_TESTING and install IO::Socket::SSL to get the error?
Skarsnik RabidGravy, did you change UA so I can update?
mojca is there any way to disable that behaviour temporary, just to see if the tests pass?
loren ab6tract, actually i have other way to solve the parser problem, i take more attention to the behavior of 'for'. 14:25
mojca or is there much more that would go wrong?
14:25 dotness joined
RabidGravy Zoffix, no it just blows up as soon as it gets to the third test 14:25
Zoffix RabidGravy, I got successful install. Trying now with Pastebin::Gist that is also mentioned on that ticket
==> Successfully installed Pastebin::Gist 14:26
Seems like it was fixed at some point
ab6tract loren: ack. the thing is that for is just not a good construct if you want to pop/shift an array.
RabidGravy Skarsnik, not quite yet but it only reverts the "no precompilation" which I put in when it all went on fire the other week
ab6tract Zoffix: please explain what is so horrible about my code example
RabidGravy readies a pony drop
14:27 kaare_ joined
loren ab6tract, so i should use loop or while ? 14:27
cosimo Zoffix: hoelzro: Readline works nicely, thanks 14:28
ab6tract and provide an alternative way to conditionally pull a value from an array on the condition of a current value
Skarsnik Attribute should have a method to get the sigiless name of a attribute x)
ab6tract loren: i'm still a bit fuzzy on what you are trying to accomplish
loren ab6tract, ok, wait me a moment, i write a example 14:29
ab6tract but if you want to pull one element, inspect it, and conditionally pull another one in the same iteration, than what i've provided should do what you want
mojca nine: files under $prefix are owned by root, while package manager uses its own user and only allows certain actions to be done as root
14:30 leont joined, talexb left
nine mojca: I'm testing a fix that ought to at least make make test work 14:30
14:30 talexb_ joined
mojca perfect, thank you 14:31
Zoffix ab6tract, because it's unreadable. And the real problem is this: "<ab6tract> loren: i'm still a bit fuzzy on what you are trying to accomplish". Which is why I asked loren to elaborate on the goal and not just on their current means of trying to achieve. I think programming is more than just writing a bunch of characters. But sorry you think it's tiring negativity on my part.
RabidGravy Skarsnik, I have now update H::UA and even bumped the version so you can just do "panda install ...." without it blowing up 14:34
:)
nine mojca: gist.github.com/niner/fb4979e3d5c90cd476e8
RabidGravy as a side benefit the tests seem to run quicker 14:35
Skarsnik and why it's a super slow :(
30-cookies took forever
wtf
RabidGravy well previously there was "no precompilation" in Message, Request and Response 14:36
nine Skarsnik: does HTTP::UserAgent still carry the 'no precomplation;'?
RabidGravy no I just ridded it nine
14:36 Guest15478 joined
Skarsnik I am surprised nobody felt on a bug I left in cookies, but I feel like I was the only one using h:ua to login on a website xD 14:37
nine RabidGravy: that carries the risk of provoking run_alt again. But I guess it would actually be a good thing if we could reproduce it reliably again.
Skarsnik ==> Installing HTTP::UserAgent
HTTP::UserAgent:ver<1.1.10>:auth<github:sergot>:api<> already installed
I hate this bug
AlexDaniel Skarsnik: --force it
timotimo --force? :P
Zoffix what's the bug?
RabidGravy eh? I upped there version
Skarsnik why it run the test all?
Zoffix Ah, right, I already asked last night. 14:38
nine Skarsnik: that's no bug.
Skarsnik I don't see how it's not a bug...
RabidGravy - "version" : "1.1.10",
+ "version" : "1.1.11",
ab6tract m: my @a = 1..10; while +@a and @a.shift -> $x { if $x %% 2 and +@a { my $y = @a.shift; say "x:$x\ty:$y" } }
camelia rakudo-moar 373adc: OUTPUT«x:2 y:3␤x:4 y:5␤x:6 y:7␤x:8 y:9␤»
Zoffix LTA behaviour, I'd think: bail out of install if the version is already installed.
RabidGravy it's a bug somewhere if it hasn't used the right version
nine Skarsnik: you try to install an already installed version and rakudo refuses to do useless work. Where's a bug in that?
RabidGravy but I upped the version 14:39
it's 1.1.11 now
Skarsnik why trying bothering trying to install of it's already here..
nine RabidGravy: yep, that's more of a bug.
Skarsnik It should just say "It's already up to date"
awwaiid yeah. more like a warning than an error
nine Skarsnik: then implement just that 14:40
ab6tract Zoffix: ok man. it was unreadable. glad to know, because i did not notice. and yeah, it's the cumulation of reading you say things like "Failador" and "binning this with questionable design decisions"
Skarsnik It should not throw at least if it's an expected result x)
lustlife` can anyone tell me how to show camelia output normally in emacs irc buffer, do i need set some font for this ? the new line symbol show 2424, but in browser irc log,it shows normally with nl.
loren Zoffix, ab6tract , em, my english is so poor, haha ^_^, here the example gist.github.com/ihateme/6f3bb7c8683958c06c8b 14:41
Skarsnik RabidGravy, well all the test passed at least ^^
ab6tract loren: link 404s.
awwaiid loren: link says 404, maybe you accidentally made a private gist
RabidGravy as nine says it may go on fire again, but it's a canary if you will
_wiz_ are there MoarVM people here? 14:42
awwaiid lustlife`: what do you mean by camelia output?
Zoffix awwaiid, the robot
awwaiid ahh
RabidGravy _wiz_, for reliable try #moarvm
_wiz_ rabidgravy: thanks
timotimo events.ccc.de/congress/2015/Fahrpl.../7130.html - oh, look who's back! 14:43
lustlife` awwaiid: when i run some p6 code to perl6 evalbot i mean.
timotimo With more WATs, more broken concepts, and more wildly popular 0-days, we will finally prove the Perl language is a broken concept, one that stood tall for way too many years.
loren ab6tract, But i am sure it's public .. 14:44
I clicked public gist .
ab6tract loren: any chance some of the url got cropped? 14:45
14:45 Averna joined
timotimo "private" gists are still public to everyone who knows the URL 14:45
Skarsnik Yes
hm... 14:46
14:46 FritzZaucker joined
Skarsnik How I can have a "sorted" hash? 14:46
mojca nine: All tests successful.\nFiles=43, Tests=553, 284 wallclock secs ( 0.23 usr 0.14 sys + 237.48 cusr 10.09 csys = 247.94 CPU)\nResult: PASS 14:47
thank you
I guess that it only makes sense to do a simple "make test" or should I attempt other tests as well?
timotimo Skarsnik: you can add a role that records the order of key insertions and removes keys on deletion
and then uses nextsame to do the actual stuff the hash does 14:48
an implementation of that almost fits into a single IRC line
Skarsnik I want to handle DB field in a hash but I would want to have them always in the same order when going through it with kv x)
nine mojca: make spectest will download and run the spectest suite, but that's completely overblown for a simple installation 14:49
timotimo why not just .kv.sort(*.key) then?
Skarsnik Oh right
RabidGravy timotimo, was that guy scared by a Perl as kid or something? 14:50
mojca nine: ok. The question is whether this should be run at least once to confirm whether I missed something while preparing a package (users of the package would not run it)
but if that is mainly for developers, I'll skip it as I don't plan to participate in the actual development 14:51
Zoffix timotimo, heh. wow, that's quite an event description. Funny, I'm pretty sure I know what the issue they're going to describe really is. 14:52
nine mojca: I'd say you already are :)
RabidGravy that's how it always starts ;-) 14:53
FritzZaucker github.com/vendethiel/moarvm-gcerr-gtk ... jnthn's golf-helper.p6 (with schedule-on() instead of schedule-off() with 6.c and current GTK::Simple give the same error: "Invalid GC status observed". Does that mean that this is not working at the moment?
vendethiel FritzZaucker: yeah, that's why I created this rpeo 14:54
repo*
14:54 lustlife` left
RabidGravy I have an instinct it's the NativeCall/schedule-on combo but no evidence to back it up 14:55
FritzZaucker Ok ... too bad, I was just trying to implement my first (useful) p6 program and that would need a GUI and a timer ... I guess I'll have to think about something else then.
cosimo wow, I had a different idea of ccc... www.youtube.com/watch?v=noQcWra6sbU 14:57
mspo that talk was ridiculous 14:58
loren Zoffix, ab6tract awwaiid, please try this again , gist.github.com/araraloren/8e91279a76868b5810eb
maybe another account has some problem ..
dalek ast: f9ff1b3 | (Stefan Seifert)++ | S11-repository/curli-install.t:
Fix "no writable path" found in curli-install.t

This test relied on a bug in rakudo that made it create the repository directory during completely unrelated actions. When that bug is fixed, the test would fail due to the non-existing repository directory.
14:59
15:00 ilbelkyr left
RabidGravy vendethiel, FritzZaucker fwiw it's the first schedule-on that causes the problem 15:00
15:00 ilbelkyr joined, xpen joined
leont RabidGravy: more likely, he was a schoolyard bully who just happened to pick a new target 15:02
Zoffix loren, yeah, that one works.
15:02 FritzZaucker left
Zoffix loren, is the output always going to be EN/CN/EN/CN or do some lines contain EN/EN? 15:03
RabidGravy leont true
ab6tract loren: i think you want to try the variation i provide
m: m: my @a = 1..10; while +@a and @a.shift -> $x { if $x %% 2 and +@a { my $y = @a.shift; say "x:$x\ty:$y" } }
camelia rakudo-moar 373adc: OUTPUT«x:2 y:3␤x:4 y:5␤x:6 y:7␤x:8 y:9␤»
Skarsnik I can't find the operator to create a list of the same element repeated a X number of time 15:04
loren Zoffix, yeah, like that format
15:04 orbus joined
Zoffix loren, then you can use for @lines -> $en, $cn. And you can use grep when you create @lines to filter out any unwanted crap 15:05
vendethiel lol, "we expect other languages to use the first element of the list" well no, I can prove that more languages even do like perl :D. but yeah, your talk sucks
Zoffix loren, gonna show you an example if my editor finally decides to start up -_-
loren ab6tract, thanks , check the element count is one way ..
ab6tract loren: as Zoffix mentions, if you know they come in EN/CN pairs, then pulling two at a time in a for loop is perfect 15:06
loren Zoffix, will it work on a large file ? 15:07
vendethiel "list is not a data type, they are just expressions" now you're just making up words :')
loren ab6tract, yeah, i also think so .. ^_^
ab6tract, we all want to find a easy way to deal with problem .. 15:08
{deal}{solve} # may be solve be better 15:09
mojca nine: here's another failed test pastebin.com/0umC2XjN 15:11
15:11 poldepaor joined
poldepaor hey guys :) 15:11
15:11 SwellJoe joined
loren poldepaor, hi 15:12
Juerd timotimo: Are you at 32c3?
mojca I'm not sure about the best way to post long chunks of code
RabidGravy I think a Language/ page on "lists and arrays" is probably in order
nine mojca: what's the permissions of /path/to/rakudo/work/rakudo-373adc0/lib/.precomp?
Skarsnik vendethiel, I don't even want to watch more of his talk, I guess it's like "Oh look there is no type on the language, so no data check, ohoho"
RabidGravy mojca, most people use github gists but ymmv
Zoffix Ugh, Sublime Text 2-- 15:13
loren, um, probably. I'm not sure if grep returns a lazy list in Perl 6. You could try it out: gist.github.com/zoffixznet/3c563a64d5c760983d85
vendethiel Skarsnik: nah, I mean, the issue is real. I consider wantarray a bug, and the API "param returns a scalar or a list" to be awful. But everything else is stupid
mojca nine: lib/.precomp is drwxr-xr-x (755) 15:14
nine param is very much deprecated by now due to this issue
Zoffix I have tons of code with scalar or list APIs.
nine mojca: and it's owned by the user running the tests?
mojca yes
ab6tract grep returns Seq which is lazy
Zoffix Sweet 15:15
leont Yes, it is awful, but as a community we've been telling people that for a decade.
nine mojca: does .precomp/.lock exist and have the same owner/permissions?
leont In particular, we've been telling them not to use CGI.pm
15:15 AlexDaniel left
Juerd leont: Unfortunately, "we" do tell people to use drop-in replacements for it... 15:15
mojca .precomp/.lock exists and has permissions 644
but it's true that one test suite is still running and I ran the failed test separately if that makes any difference 15:16
Juerd But yeah, the problem identified in that talk is not new and not very interesting.
15:16 ab6tract left
poldepaor Any links to any good documentation and programs to get started with perl6? Looks like a mashup between C and Python 15:16
nine mojca: then I don't get why it's not allowed to write :/
Juerd poldepaor: Have you seen doc.perl6.org yet?
mojca oh, wait
Juerd poldepaor: For example code, from simple to complex, see rosettacode.org
15:17 pierre-vigier left
Zoffix poldepaor, there's perl6intro.com/ and we also have an Advent Calendar with some neat articles: perl6advent.wordpress.com/ 15:17
dalek kudo/nom: 4cf630b | (Stefan Seifert)++ | src/core/CompUnit/Repository/Installation.pm:
Fix make test failing on an unwritable install path

Even if a CompUnit::Repository::Installation was never used for loading modules, it tried to mkdir its $.prefix and prefix/dist just to read the listing of an empty directory when calculating its identity.
We're now a bit smarter and only read the directory if it actually exists.
mojca I ran that extra test manually, I'm sorry
nine mojca: the fix I posted before ^^^
poldepaor Thanks a lot guys. What do ye think of perl for automation?
nine mojca: thanks for patiently reporting :)
RabidGravy poldepaor, depends on what you want to automate :) 15:18
mojca thanks a lot
poldepaor Test automation mostly I guess?
loren Zoffix, that's very helpful, i think something like this 'for problem or behavior' should be share more, and people will avoid these mistakes 15:19
RabidGravy there should also be a doc page on lists and arrays
Skarsnik RabidGravy, if you are bored you could fix github.com/sergot/http-useragent/b...es.pm6#L92 I write this so the test pass (because they give expire string looking like DATE1 or DATE2)
I don't even know how the old code was not failing (probably because the field get lost or something xD° 15:20
RabidGravy Skarsnik, oh I'm not bored :) I'm just taking a break from trying to work out my GDBM code is segfaulting
Skarsnik ^^ 15:21
15:21 nrnoble left
btyler timotimo: huh, wonder if that guy's talk will be any better informed than his last one was 15:21
Skarsnik when is that?
mojca nine: gist.github.com/mojca/ff1ad0db5156acef2676
dalek c: 87d0bfc | (Wenzel P. P. Peppmeyer)++ | doc/Type/IO.pod:
dd will ignore named params (by design)
c: dec1b8e | (Wenzel P. P. Peppmeyer)++ | doc/Type/IO.pod:
Merge pull request #280 from gfldex/master

dd will ignore named params (by design)
btyler kind of surprised he's getting stage time again, but I guess it did get people chatting about CCC 15:22
RabidGravy Skarsnik, my approach would be find some other cookie library in any language and rip it's test data off 15:23
dalek c: 1c503c7 | (Wenzel P. P. Peppmeyer)++ | doc/Language/containers.pod:
minimal fix of minimal typo
c: 4907cc2 | (Wenzel P. P. Peppmeyer)++ | doc/Language/containers.pod:
Merge pull request #281 from gfldex/master

minimal fix of minimal typo
Skarsnik or pick from perl5 x)
I looket at lwp code a bit to patch cookies 15:24
15:24 zmyrgel joined
nine mojca: those tests are only run on OS X which I don't have 15:24
poldepaor Has anyone been doing any QA test automation with perl5 and or 6? 15:25
nine mojca: that's probably also why no one has fixed that WARNING
15:25 spider-mario joined
nine poldepaor: quite a bit, yes 15:25
poldepaor: automated testing is at the very heart of Perl culture 15:26
zmyrgel hi, I tried to test perl6 but I can't get panda to install 15:27
it errors out: gist.github.com/anonymous/00c064486194fc20e270
I'm using rakudo 2015.12
RabidGravy that's odd, how did you install it? 15:28
zmyrgel pkg_add rakudo 15:29
RabidGravy on a BSD?
Woodi mojca: about your moar install: you finished it with included libuv or with one from system packags ?
gfldex zmyrgel: what does perl6 --version and uname -a say? 15:30
yoleaux 10:41Z <lizmat> gfldex: dd only takes positionals and ignores nameds: that was the only way to get positionals to work and keep order of specification
Woodi poldepaor: actually Perl was created to look like C and Python was created long long later :)
15:31 Cabanossi joined
poldepaor Woodi: That's pretty cool to know. Thanks for pointing that out 15:31
zmyrgel RabidGravy: OpenBSD-current
Woodi poldepaor: I forgot there was APL somewhere involved :) 15:32
15:32 _mg_ left
zmyrgel seems there are some changes done to rakudo port recently, just recompiling the package to see if it fixes the panda issue 15:32
gfldex Woodi: not that lone actually. Python was released in 1991. It seams much younger because nobody used it before 2.0, released in 2000.
mojca Woodi: I used the included libuv just in case, but declared the package to conflict with libuv which is not the best
15:32 _mg_ joined
RabidGravy zmyrgel, I *think* the person who did the port was around at some point 15:33
but I may mis-remember
15:34 Averna left, _mg_ left
Woodi gfldex: that's good to know too :) 15:34
dalek kudo-star-daily: 6cd9466 | coke++ | log/ (9 files):
today (automated commit)
15:35
rl6-roast-data: d6f92b2 | coke++ | / (7 files):
today (automated commit)
15:35 ponbiki left
zmyrgel that didn't solve this yet, going to grab some dinner and then to continue to solve this 15:36
15:36 lustlife joined
TimToady by 1991 we were up to Perl 4 :) 15:37
dalek p: 6a74da8 | paultcochrane++ | t/nqp/19-file-ops.t:
Clean up test file when testing file ops
15:37 yqt joined 15:38 Guest15478 left
loren zmyrgel, why not download the Rakudo source and compile it ? 15:38
RabidGravy zmyrgel, sorry can't be too much help don't have an OpenBSD handy to help
loren I misunderstand ? o_O? 15:39
Zoffix Which is a reference to the 4 bash commands mentioned here: perl6.org/downloads/ 15:40
RabidGravy no, no, but it would be *nice* if the packaged version did work. On OpenBSD it actually does build it from source but just set up in a certain way
15:40 regreg joined
mspo the pkgsrc version is broken/too old too 15:41
15:41 poldepaor left
mspo but a manual build works 15:42
15:42 spider-mario left, Zoffix left
mspo one issue is that nqp needs to be available at build time for the rest but DESTDIR isn't well supported 15:42
Woodi nine: is it possible that in repositories dist/[sha] would be dist/[sha]/ (directory) and sources and precompilations for a distro live there ?
mspo so you end up needing to use three distinct packages
loren oh, packaged will be better, i have always compile it on my fedora.Of course, that are reason about fedora has no package about Rakudo now . 15:43
15:43 spider-mario joined
loren Seem like i am wrong, that do have a package rakudo-star .. 15:45
15:46 randomguy joined, testoh joined
testoh hello? 15:46
diakopter yoooooo
loren -_- Night, everyone.. o////
testoh how is perl 5 different from perl 6?
is anyone here? 15:47
loren Powerful, has a lot of feature .. testoh
testoh yeah explain please
can it draw dank memes on its own?
RabidGravy er 15:48
nine Woodi: precomp files are dependent on the compiler's exact version (including build) while sources and meta data aren't.
testoh is perl 6 compiled?
RabidGravy it compiles to bytecode yes 15:49
randomguy I found a small typo on perl6intro.com/#_arrays The @animals assignment is using brackets instead of parenthesis. Is this the right place to tell someone about it?
gfldex testoh: it is comiled to bytecode and there is a fairly limited JIT
loren doc.perl6.org/language.html, perlgeek.de/en/article/5-to-6, maybe you can look these article, testoh
Skarsnik nine, should precomp follow a fixed version instead of just each compiler version? 15:50
mst randomguy: looks like you want to send an issue or PR to github.com/hankache/perl6intro if possible
RabidGravy we ought to steal the guys who wrote the mono JiT
randomguy mst: k, thanks
mst nine: oh, I never followed up, where did you get with the whole 'trying to see through to lower repo precomps' thing?
zmyrgel yeah I'd like to use the OS provided packages as much as possible
15:51 adrusi joined
testoh WOW perl 6 is a real syntac 15:51
syntax mess
wtf
space goes after keywords with args but not after method names 15:52
wtf
who thought of that
I put a space wherever I well damn please
fuck this
back to python
mst I'm sure you'll have much less trouble with whitespace restrictions that way 15:53
adrusi can't tell if you're being sarcastic
dalek pan style="color: #395be5">perl6-examples: 99dd877 | (Rodrigo Siqueira)++ | categories/cookbook/02numbers/02-14complex-number.pl:
Update 02-14complex-number.pl
pan style="color: #395be5">perl6-examples: 13301f8 | (Zoffix Znet)++ | categories/cookbook/02numbers/02-14complex-number.pl:
Merge pull request #39 from rsiqueira/patch-1

Update 02-14complex-number.pl
RabidGravy unlikely
havenwood testoh: bye!
loren testoh, starting form the basic syntax
nine testoh: who thought of that? People who worked very hard to find solutions to the 1000s of problems that language designers face.
testoh C U L8R haven wood
RabidGravy randomguy, in effect it doesn't make a great deal of difference on the outcome: 15:54
m: my @f = [1,2,3]; say @f.perl; my @g = (1,2,3); say @g.perl
camelia rakudo-moar 4cf630: OUTPUT«[1, 2, 3]␤[1, 2, 3]␤»
[ptc] testoh: have a look at Slang::Tuxic for a way to adapt perl 6 to how you like to space things yourself
randomguy RabidGravy: @array.elems
zmyrgel perl6 syntax seems tad excessive at first glance 15:55
testoh you.goFuck(self)
RabidGravy randomguy, yeah both the same
in that specific case
nine mst: I got to the point where I wished that having all users nuke their install directories was still a viable option :)
hoelzro o/ #perl6 15:56
havenwood hoelzro: hi!
[ptc] hoelzro: \o
nine hugs testoh
15:56 CIAvash joined
randomguy RabidGravy: huh, not for me. I was following the tutorial at the link. :-/ 15:56
testoh how u hug ppl?
[Coke] autarch: I tried to run your code through the profiler, it ded.
RabidGravy m: my @f = [1,2,3]; say @f.elems; my @g = (1,2,3); say @g.elems
camelia rakudo-moar 4cf630: OUTPUT«3␤3␤»
adrusi RabidGravy, this is part of what I'm trying to wrap my head around too; what *is* the difference between the two
loren zmyrgel, yeah, that's a lot of .....
Skarsnik hm, that's confused me: gist.github.com/Skarsnik/0fe190087758c4f39232 15:57
mst nine: well, given we're tying the precomp stuff to the compiler version, a new vcersion of the compiler is an implicit nuke, no?
15:57 nash_ joined
Skarsnik I don't really get this error :( 15:57
RabidGravy randomguy, what version are using?
zmyrgel loren: just after learning and using Go in few projects... looking at perl6 syntax seems to be in the other end of the scale :)
hoelzro o/ havenwood [ptc] 15:58
RabidGravy adrusi, well one is a List () and one is an Array [] but both get assigned to the @variable the same
testoh ŁŁŁŁ
15:58 skids joined
nine mst: only a nuke of the precomp files, not of those other files we generate. But there's always solutions. They are just not as simple anymore. 15:58
testoh: I just typed: /me hugs testoh
loren zmyrgel, but i think Golang's grammar is too simple 15:59
testoh ŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁ¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸ŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁŁÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐТ¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢¢®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®®ªªªªªªªªªªªªªªªªªªªªªªªªªªªªªªªªª􏿽xC2
mst nine: which other files get generated that are affecting this?
testoh hugs nine
nine :)
RabidGravy that's nice
testoh blow nine
zmyrgel loren: yeah, but I value the maintainability of it more.
diakopter misses hugme
testoh cum on nine's face
loren zmyrgel, also maybe suitable with it's positioning.
randomguy RabidGravy: Crap, I thought I fully installed the new one today. :-/ version 2014.07 16:00
16:00 ChanServ sets mode: +o mst
RabidGravy oops 16:00
16:00 testoh left
zmyrgel perl6 seems to get lot of stuff right, like having actual language spec 16:00
RabidGravy randomguy, ah that would explain it, mucho changes on the way lists/arrays work since then
nine "requested by mst" that's a nice way to put it :)
RabidGravy mst++
[ptc] mst++ 16:01
orbus good morning #perl6
16:01 mst sets mode: -o mst
diakopter moarning 16:01
zmyrgel What I would like to see would be great portability so I could write my stuff on linux and have it run on windows with little to no modificatios
orbus any NativeCall wizards happen to be about?
loren zmyrgel, I usually don't want to use what gorgeous grammar, scalability and maintainability is an important aspect, i am a 'c/c++'er
mst zmyrgel: given the libuv basis that's actually significantly available
orbus having some problems and I want to see if I'm way off base with what I'm trying 16:02
skids orbus: not a wizard but I've dabbled, go ahead.
mst orbus: I'm not sure exactly who in here is going to take an interest in that, but I bet there's at least a couple around, so go for it and let's find out who they are
RabidGravy orbus, depends on the length of beard and it's colour you want but shoot anyway, there are people who do NativeCall stuff
orbus thanks all :)
okay, so I'm dabbling with the Oracle client library
mst I'm so sorry.
orbus lol 16:03
yeah
RabidGravy :)
orbus tell me about it
and I haven't written any substantial c in probably 15 years
randomguy RabidGravy: Thanks for the help.
16:03 krshn joined
nine mst: the part of module finding that takes ages is parsing the dist meta data, that's stored in a json file. What we actually need of this file is the name of the modules, the version and auth. We already have the quick lookup files for module names. If they contained version and auth, we wouldn't have to parse json anymore 16:03
orbus but anyway, I have a week off and I though I'd take a stab at getting perl6 to talk to oracle
zmyrgel orbus: luckily the oracle client hasn't changed in that time :)
Skarsnik I have to use ~~ to test if a class does a role?
orbus heh
yeah
Skarsnik orbus, there is already work on that 16:04
RabidGravy orbus, ah, you may want to speak to abraxxa who isn't actually here it the moment, he's been working on the same thing
orbus oh nice
16:04 xpen left
orbus well it's a good learning exercise regardless 16:04
RabidGravy anyway carry on
orbus but I will keep that in mind
so the first thing you have to do is call OCIEnvCreate()
which gives you an environment handle
Skarsnik github.com/abraxxa/DBIish
mst abraxxa is #dbix-class' longest standing oracle user
orbus which you then use to do other stuff
16:05 domidumont left
skids m: say List.does(Iterable) # Skarsnik 16:05
RabidGravy yep
camelia rakudo-moar 4cf630: OUTPUT«True␤»
orbus yeah, let me see if abraxxa's stuff does what I"m trying to do
Skarsnik oh thx
orbus basically this function takes a bunch of pointers to callback functions and things
most of which you apparently don't actually need
mst nine: right, because in perl6, effectively, the version and auth are part of the FQ name, ala the PAUSE if and version being part of the DQ dist name on CPAN
orbus the example code in the docs is passing in 0 for most of the pointers
16:05 perlpilot joined
leedo nine: ohhhh, so that may explain why it can take my toy module like 20s to load, but only when i'm useing a bunch of panda installed modules 16:06
orbus so I'm trying to do the same thing from nativecall
mst nine: I guess that's a question of declaring a new version of the quick lookup file format?
orbus and it doesn't blow up, but the function is returning -1 which is error
diakopter leedo: which ones
Skarsnik Cannot use 'does' operator with a type object.
RabidGravy it's pass a Code type object I believe
Skarsnik hm
nine leedo: if it's much faster on the second try, you're actually waiting for compilation
leedo diakopter: HTTP::UserAgent and Inline::Perl5
orbus so hang on
leedo nine: yeah, it gets down to 10s after the first run
orbus docs.oracle.com/cd/B28359_01/appde...tm#i556149
function definition is there 16:07
mst orbus: it might also help to take DBD::Oracle apart
diakopter leedo: are you running on a pebble smartwatch?
skids Skarsnik: I'm surprised .does is hitting the "does operator"
diakopter [only half kidding]
leedo diakopter: i5 2.3 GHz :P
16:07 loren left
Skarsnik orbus, github.com/abraxxa/DBIish/blob/mas...Native.pm6 16:08
diakopter leedo: is your hard disk on the moon?
[only mostly kidding]
mst leedo: is your hard drive an EBS volume? If so, have you considered a disk on the moon instead? :D
leedo diakopter: ssd!
orbus so I tried defining it like this in NativeCall
sub OCIEnvCreate(Pointer, int32, long, long, long, long, size_t, Pointer) returns int16 is native('clntsh') { * }
leedo gist.github.com/leedo/803b429654bcbb2c0a24
orbus okay, let me look at abraxxa's stuff
that was the next thing I was going to do
leedo mst: diakopter afaik this hard drive is operating normally 16:09
RabidGravy orbus, it would be Code for the function pointers
afaik
mst leedo: sure, I was just complaining about EC2 while I got a chance
leedo hehe, yeah i've experienced that pain
orbus hmm
even if the function pointers shouldn't point to anything?
Skarsnik skids, I am dumb, it's another line 16:10
orbus looks like abraxxa's stuff is using Pointer for them
randomguy yay, new version fully installed. all is better now.
RabidGravy yeah, just pass a Code type object
that would work too
orbus like a random undefined one?
just Code.new or Pointer.new?
RabidGravy literally foo(Code)
orbus well that's on the definition 16:11
Skarsnik Oh, you can't use does on an uninitialised object?
orbus but what do I pass in when I call the function
RabidGravy that give you NULL
orbus so I do sub foo(Code)
but then when I call it foo(??)
16:11 randomguy left
orbus ? 16:11
skids orbus: No call it with Code
orbus oh
hrm 16:12
RabidGravy literally
skids Code is a NULL of type Code
orbus oh weird
okay, let me give it a shot
brb
Woodi nine: I think that if repo work is interrupted then in current form it will be messed. if distros or modules (sources at least) would be in it's separate dir then it can be easy to verify and repair. and links already are used. 16:13
16:13 thowe left
skyl4rk is it possible to set SA_NODEFER for signal handling, e.g. for signal(Signal::SIGINT).tap: { dostuff } 16:13
orbus Unknown type Code used in native call.
It didn't like that much
should it be Pointer in the definition and Code when I call it?
Woodi nine: as for quick lookup format: cdb like used by tinydns for domains - domain changes and installations arn't so often so read-only database like cdb works good. and it is regenerated on modifing domain or installing module 16:14
zmyrgel ok, rakudo reinstalled with latest changes but panda still gives following: gist.github.com/anonymous/a7c1830f0ff2ac5864f6
RabidGravy orbus, that's odd 16:15
mst nine: if I want to understand this stuff, is my best approach to read all of the current src/core/CompUnitRepo tree?
orbus tried this
sub OCIEnvCreate(Pointer, int32, Code, Code, Code, Code, size_t, Pointer) returns int16 is native('clntsh') { * }
16:15 nash_ left
orbus my $x=OCIEnvCreate($p,0,Code,Code,Code,Code,0,$z); 16:15
nine mst: after reading jnthn's gist, that's the best source, yes. Of course I'm happy to answer questions :) 16:16
orbus let me try with Pointer
Skarsnik hm, how I can add a new role to a class outisde the class definition?
orbus hrm
well that runs
but it still returns -1 16:17
skids Skarsnik: For lexical use or as a monkey patch?
nine Woodi: sounds like you have some interesting ideas. You could try them out easily, since repositories have a clearly defined API and can be plugged into rakduo
16:17 cdg joined
orbus going to look what abraxxa is doing a little deeper 16:17
16:18 cdg left
[ptc] should the .precomp dirs (in lib/ and t/04-nativecall/) be deleted as part of `make clean` (or possibly `make realclean`) in rakudo? 16:18
Skarsnik NC use does in its trait x) but it does not work here x)
RabidGravy orbus, yeah that should definitely work, with a Code there - I'm using it some of my own code (which fails for other reasons)
orbus well
16:18 cdg joined
Skarsnik skids, I am trying to achieve this gist.github.com/Skarsnik/3b3b2f52faa4128c9931 16:19
orbus it definitely didn't like Code in the sub definition
mst nine: yes, but it's taking you five minutes a time, the answers are user level so I don't honestly understand them because I'm mid source dive, and you missed the last one entirely
orbus this is on 2015.12
with Pointer it doesn't blow up
but it's still failing
mst nine: so I'm concluding "christmas has happened to nine, this head cold means I'm asking the wrong questions, time to UTSL first"
RabidGravy ah in the sub definition maybe it wants a &foo or something
orbus it looks like abraxxa is using an array of some sort for the handle it returns though
instead of a straight Pointer
need to look at that
skids Skarsnik: does should be used on an instance, so you'd have to have something in $s first. 16:20
orbus CArray[OCIEnv]
mst note that I don't think abraxxa's really a C hacker anyway
orbus and OCIEnv is constant OCIEnv is export = Pointer;
ohhh
mst so it's entirely possible that you're both wrong
orbus so maybe it's supposed to be an array of pointers 16:21
ha
true
16:21 Atrox joined
mst (it's programming, "everything is differently broken" is always a possibility ;) 16:21
Skarsnik skids, I don't know NC use does to extend Str github.com/rakudo/rakudo/blob/nom/...l.pm6#L310
RabidGravy orbus, maybe if you try "sub OCIEnvCreate(Pointer, int32, &a, &b, &c, &d, size_t, Pointer) returns int16 is native('clntsh') { * }" or some such
nine mst: I was just eating, is all :) A new file format will be the answer. Of course we didn't think about a versioning mechanism before putting the first version out however...
orbus what do the & do?
RabidGravy it's a sigil for a "Callable" 16:22
mst nine: right. so we're going to have to mint some sort of version detection that handles 'pre-christmas unversioned' too
RabidGravy which includes a Code
orbus mst: the Oracle call interface is a special kind of nightmare - I can tell that already
skids Skarsnik: but explicitly-manage is probably called with an instantiated Str.
orbus this is why when I need to talk to Oracle I usually go through perl or java
mst nine: which classes/methods are reading/writing that lookup file? I'll have a skim of the code once I've taken a moment to sob quietly into my coffee over unversioned file format ;)
Atrox Hello, just a little question from a newbie. I'm very interested to try out Perl 6 (after reading the announcement) but Radoku Star is not updated for Perl 6 right? (Its from 2015.11) Should I have to wait or is there any other way to try it? (I'm on Windows) Thanks already!
nine mst: I guess we just need some VERSION file where non-existence means version 1
Skarsnik skids, Hooo so the object need to be instancied? damn
nine mst: it's all contained in CompUnit::Repository::Installation 16:23
TimToady Atrox: depends on your threshold of pain :)
orbus RabidGravy: let me give it a shot - I'm starting to think the problem is with the output pointer though
TimToady and on how well your system matches our systems
Atrox TimToady: so hard to get it working on windows :/?
skids Skarsnik: unless you monkey-patch the class, which should be avoided unless really necessary, yes.
orbus namely, the first argument
TimToady Atrox: windows can be easy if you have the right prereqs installed
leedo had a thought to try --profile to see what is taking so long using HTTP::UserAgent, since strace wasn't informative. the profile output says it ran for 4.12ms, but it actually took 6s :P
RabidGravy yeah that's a really peculiar interface, most things just return a pointer 16:24
TimToady is not a windows expert, but some of our devs work on windows
Atrox TimToady: is there any resource/tutorial online how I get it working? Or should I just setup vagrant ...
hoelzro Atrox: I've gotten it built on Windows using Mingw
Skarsnik skids, I try using this approch to say "This variable from the class B will be DB managed on some ways" without havint to do it in the class itself ~~
disturbingly_rea Is there a takeWhile or takeUntil construct on lazy sequences? I'd like to be able to do something like `takeWhile {$_ * $_ <= i}, @primes` 16:25
Atrox hoelzro: How? I got MingW installed.
hoelzro others have had success with the VS toolchain, but I couldn't get that working...
mst I think for a win32 build you need mingw for gcc plus some sort of git?
Atrox hoelzro: Just compile?
[ptc] Atrox: try this out: perltricks.com/article/135/2014/11/...tudio-2013
hoelzro Atrox: you'll need git (as mst says) to grab the source
TimToady and you need perl 5
hoelzro ah, yes of course =)
mst needs to look at what it'll take to make rakudobrew use tarballs optionally
16:25 gist_nb joined
hoelzro I did strawberry perl and that worked 16:26
Atrox Awesome. I will take a look. Thank you all!
skids Skarsnik: "This variable from the class B" perl understands merely as "This variable that can only contain things of the class B"
[ptc] Atrox: it might help, but could be a bit old. You have to install from source until the Rakudo Star .msi files are available
mst I think a lot of us forget there's such a thing as "computers that don't have perl5 installed"
RabidGravy leedo, how recently did you install H::UA? I only just an hour ago took a bunch of "no precompilation"s out
hoelzro in fact, I think that strawberry has all the toolchain you need, sans git
16:26 Arrowhead joined
hoelzro mst: I forget that all the time =P 16:26
RabidGravy and previous to that it did load rather slowly
nine mst: lies!
16:27 Guest15478 joined
leedo RabidGravy: i'll update, probably a few days old 16:27
RabidGravy mst that's crazy talk
mst nine: does the JSON meta format at least have a version?
Arrowhead What's the canonical way to build and test a module, but not install it?
skids Skarsnik: what you probably need is something like "class MyDBVar is B does DBROLE { }; my MyDBVar $s"
leont The only piece of p5 dependency in rakudo's build that'd be hard to convert is Configure, I think
TimToady remembers a time when only one computer had perl on it...and before that, everything is lost in the mists of time...
RabidGravy leedo, yeah the first time might be slowish but after that it's quite zippy comparitively
Skarsnik skids, yes but I am not fan of having a new class just for that x) 16:28
leedo unfortunately HTTP::UA tests seem to fail currently
RabidGravy er
mst TimToady: pretty sure we have regulars who were born after that point.
RabidGravy whaddyamean?
skids Well, when you do a does you generate a class, it just does not show you that.
Skarsnik on older rakudo
nine mst: not that I'm aware of
leont I had a brainstorm with Nicholas at some point about having a DSL that could be compiled to Perl5/shell on unix and Powerscript on Windows, but that never got beyond the idea stage
16:29 ponbiki joined
[ptc] Arrowhead: probably an incantation along the lines of `prove --exec="perl6 -Ilib" -r t` 16:29
Skarsnik leedo, it probably fail on old rakudo yes
mst nine: wut. even META.yml had a spec version 10 years ago :/
leedo Skarsnik: RabidGravy well i've got 6.c release installed :/
RabidGravy leedo, oh if you've got a rakudo more than a week or so old it will fail
leedo i'll try again
Skarsnik skids, wait, if I still can use does on instancied stuff it's fine for me ^^ 16:30
RabidGravy it definitely passed it's tests before I pushed the change
skids m: (1 does role { }).WHAT.say # Skarsnik: that's actually a new class there. Classes are pretty cheap.
camelia rakudo-moar 4cf630: OUTPUT«(Int+{<anon|58207552>})␤»
nine mst: yes, unfortunately we were very good at ignoring all the experience with Perl 5 in that area :(
16:30 khw joined
skids Skarsnik: then that would be a good way to go. 16:30
Arrowhead ptc: thanks, that does it. Less intuitive than what I know from perl5.
dalek kudo/nom: db8a6c5 | paultcochrane++ | t/04-nativecall/16-rt125408.t:
Remove exec bit from 16-rt125408.t

This is a test file, which will be called through the test harness and thus doesn't need to be executable.
16:31
kudo/nom: 95dd6c5 | lizmat++ | t/04-nativecall/16-rt125408.t:
Merge pull request #658 from paultcochrane/pr/remove-test-file-exec-bit

Remove exec bit from 16-rt125408.t
16:31 mscha joined
Skarsnik skids, because I don't work to work on a "special" class, just attach them the role before saving them in a DB for example 16:31
*want
mst nine: ah well, 'no version is version 0' isn't a terrible thing really and then we can go from there
nine: I've done that on plenty of projects where I failed to add versioning to a format early enough; it seems to be one of those mistakes that's totally possible to make repeatedly even when you know it's a terrible idea 16:32
skids Skarsnik: sounds like a plan. Classes/runtime mixins are supposed to be relatively cheap these days.
nine mst: same here
Skarsnik another question is how to strip a role from a class x)
[ptc] Arrowhead: no worries :-) 16:33
orbus hrmmm
well I give up for now
[ptc] leont: have you seen this? Bash and Powershell from one source: www.linux-magazine.com/Issues/2015/...%29/eng-US
orbus I'll ask abraxxa when he/she is around
skids Skarsnik: dunno save a copy ahead of time?
orbus nice to know someone's looking at it already though 16:34
16:34 bpmedley_ joined
mst having met him at a conference, abraxxa is Alexander Hartmeier and 'he' 16:34
orbus okay, cool
16:34 lalos joined
orbus I try not to assume 16:34
RabidGravy :) 16:35
16:35 lustlife left, u0- joined, camelia left
orbus the programming community definitely skews male, but it's by no means an absolute 16:35
RabidGravy gosh, nearly an hour without a strange newbie question about arrays
orbus oh, I had another question 16:36
(not about arrays)
skids :)
16:36 camelia joined
orbus anybody know the current status of Inline::Perl5? 16:36
skids Pretty working.
nine mst: for the short/ files we can in the future write <sha>.full files containing all the info needed and leave the <sha> files as they are and transparently fall back to them if no .full file is available.
orbus tried building on two different machines yesterday and it compiled but failed all the tests
RabidGravy I'm sure there's someone here who knows
orbus one was ARM though
and the other was x86_32
16:37 lalos left
orbus so that might be the problem? 16:37
RabidGravy ARM may be asking for trouble
orbus yeah, I kind of wrote that one off
mst nine: sounds reasonable, though we definitely want to stick a version on the front of the contents anyway since presumably we'll've made more mistakes implementing .full files
orbus but the x86 one didn't work either
16:37 ChanServ sets mode: +v camelia
nine orbus: I'd never even thought that ARM was on the table. x86 should be possible, but you may also be the first to actually try it. 16:37
orbus I did get rakudo to build on my Raspberry Pi2 though 16:38
ha
nine orbus: I tried to be careful about native types, but they have not all been available when I started and it's easy to overlook something.
RabidGravy yeah, I've been testing it regularly on RPi
nine orbus: can you get me a gdb backtrace?
orbus I'm the same guy who's been trying to build on sparc lately
on arm?
Skarsnik I get the same issue on x86_32
nine orbus: on x86_32 16:39
orbus oh
yeah probably - I have an old laptop with ubuntu on it
that's what I was trying it on
have to install gdb
nine I didn't even know that rakudo worked on ARM
orbus and figure out how to make a backtrace :)
Skarsnik could it be an NC oversight?
nine Skarsnik: possible
Skarsnik like a Int or Num used instead of int32, num63
16:40 vividsnow1 joined
TimToady num63 is an odd type 16:40
not quite sure we support that one yet ;)
Juerd num62 is even again though :)
orbus one of these boxes I forced it to install even though the tests failed
and it core dumps if you try to load the module anyway 16:41
but I couldn't find the core file
Skarsnik sub p5_is_array(Perl5Interpreter, OpaquePointer)
returns int { ... }
could be that
orbus need to check which box it was
16:41 vividsnow left
orbus might have to reinstall rakudo to get a clean install 16:41
must have been the pi 16:42
okay, let's see here
leedo RabidGravy: ok, nuking my install seems to have fixed it... i've had to do this a lot.
mst TimToady: hey, I started off on arm26 ... arm is awesome but also totally weird ;)
orbus I was trying to install from panda
RabidGravy leedo, yeah, it was suffering a precompilation related issue a few weeks ago
orbus I guess I better clone the repository?
Atrox Thanks guys! Got it running on Windows. Was not even that hard thanks to that tutorial. :) 16:43
[ptc] Atrox++
leedo RabidGravy: ah, well thanks for fixing! i'm glad it exists :)
hopefully i can remove my Inline::Perl5 dependency soon
nine orbus: yes, makes everything easier 16:44
16:44 vividsnow1 left
RabidGravy well, let us know what else you might made and we'll see if we can help ;-) 16:44
leont [ptc]: that looks rather interesting :-)
orbus okay, so perl6 configure.pl spat out this 16:45
gcc -Wall p5helper.c `perl -MExtUtils::Embed -e ccopts -e ldopts` -shared -o ./resources/libraries/libp5helper.so -fPIC -g
Skarsnik nine, to sad you don't export your routine in i:p5 so I can't use NativeCall::Typediag directly, but yes, you should not have int in that
orbus so that seems right-ish
leedo RabidGravy: i've started github.com/leedo/p6-web-scraper - just messing around though
orbus running make test now 16:46
~/perl6/christmas/Inline-Perl5$ make test
prove -e 'perl6 -Ilib' t
t/autoload.t .................. No subtests run
t/call.t ...................... Failed 12/12 subtests
t/call_back.t ................. No subtests run
t/call_hash.t .................
timotimo btyler: are you going to watch it?
dalek ecs: 3694407 | lizmat++ | S99-glossary.pod:
Added NC as lemma, NativeCall explanation
mst orbus: please consider using paste.scsys.co.uk/ to show output 16:47
RabidGravy orbus, can you run just one of the tests e.g. "perl6 -Ilib t/autoload.t"
16:47 vividsnow joined
nine Skarsnik: NativeCall docs are still unclear on what a C int would be in Perl 6 16:47
leont Though given our infrastructure, we may be able to make something better ourselves (powerscript > bat)
orbus mst: roger that
16:47 u0- left
orbus RabidGravy: sure 16:47
hang on
Skarsnik nine, int is int32
dalek kudo/nom: 098929e | paultcochrane++ | CREDITS:
Update ptc's email address
kudo/nom: a352f81 | lizmat++ | CREDITS:
Merge pull request #659 from paultcochrane/pr/fix-ptc-email

Update ptc's email address
Skarsnik nine, I mean C int is int32
RabidGravy the prove hides the gory details somewhat 16:48
orbus mst: #perl6 isn't in the channel list on there?
Skarsnik doc.perl6.org/language/nativecall#P...ing_Values the left list
RabidGravy super sekrit we is
16:49 _mg_ joined
mst orbus: you don't -need- to supply a channel 16:49
TimToady sshh! it's a secret that it's a secret
mst that's not even the copy on this network
orbus oh
never used this site before - is it basically like pastebin with irc integration?
Skarsnik *should really merge a part of NC::Typediag in NC* 16:50
16:50 _mg_ left
dalek line-Perl5: f199d2e | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
Fix some 32 Bit issues

  < Skarsnik> nine, I mean C int is int32
Thanks to Skarsnik++ and orbus++ for the report and help.
16:50
nine orbus: please test ^^^
orbus okay, one sec
got distracted
nine Skarsnik: I'm just confused by the "64-bit int in C" 16:51
RabidGravy nine++ # so patchy today
16:51 Guest15478 left
timotimo it's [ptc]! 16:51
Skarsnik nine, int probably act the same as Int in : gist.github.com/Skarsnik/d4e9b31b2859114ac643
mst orbus: right, one moment, blowing up the bot 16:52
16:52 shadowpaste joined 16:53 _mg_ joined, mscha left
[ptc] timotimo: moin moin! 16:53
Skarsnik nine, but I get your confusion, I don't know what is a int 64bit in C
RabidGravy On an Rpi2 : "Short: 2, Int: 4, Long: 4" (sizeof(short),sizeof(int), sizeof(long)) 16:54
16:54 _mg_ left
Skarsnik apparently there is a int64_t in stdint.h 16:54
it's probably for this kind of case
16:54 molaf joined
RabidGravy "long long" is int64 16:55
Skarsnik let me change the NC doc to be more explicit x)
like: int64 (For explicitly 64 bits integer in C)
orbus okay 16:56
sorry, keep getting pulled awa
away
RabidGravy I think the "long" may be the one that changes most 32 vs 64
16:56 _mg_ joined
orbus so with the original clone I made 16:56
16:56 vendethiel left
nine mst: what do you think? Should we blow up loudly on stubling over inconsistencies within the repo (like short/ points to a dist, but we can't find the dist file), or should we ignore them and give the next-repo a chance? 16:56
orbus running t/autoload.t by itself segfaults
nine Skarsnik: also aren't there platforms where int is 64 bit? 16:57
orbus I'm not super familiar with github
mostly worked with git locally on solo projects
mst orbus: it's git plus crayon drawings plus animations that give you a headache
mst kicks github off his lawn
orbus okay, I just did git pull
and I see your commit in the log 16:58
mst nine: not entirely sure.
orbus so I guess we're good there
let me re-test
nine orbus: did you run make after the git pull?
orbus: ignore that, you don't have to this time
mst nine: actually, I think if you have something corrupt in the top repo, you should be really suspicious of the top repo entirely
timotimo btyler: i'll watch the perl jam 2 talk just so i know what's going to come at us
nine orbus: can you please try perl6-gdb-m -Ilib t/autoload.t
orbus one sec
after the git pull I did make clean
then I re-ran configure 16:59
now I'm doing make test
RabidGravy nine, on x86-64 (i7) int is still 32 but long is 64
orbus still failing
nine mst: yeah, I guess blowing up as loudly as possible is the way to go. Otherwise we'll never find the bugs leading to the inconsistencies in the first place
orbus let me try the gdb test
mst nine: also I haz epic fear of other things in the same repo only -looking- not-corrupt
Skarsnik nine, hm, tricky question maybe it work if int32 work as a C int in the internal? 17:00
mst nine: so I think an immediate HCF before things go even more badly wrong is going to be the best thing to start with
orbus it's thinking
mst nine: we can always add a Repo::MightBeBroken::DontWorryTooMuchAboutIt or something later :)
17:00 dha joined 17:02 disturbingly_rea left
Skarsnik Do you think is clear enought : int64 (64-bit explicited int in C like int64_t in C99) 17:02
orbus it's still thinking
it's super duper slow
how long should I expect it to run? any guess?
17:03 bbkr joined
nine Skarsnik: definitely better 17:03
orbus: damn...precompilation is interfering 17:04
17:05 Begi joined
mst nine: thinking, actually, we should consider having a repo type thing on disk 17:06
nine mst: what do you mean?
dalek c: 36742e6 | (Sylvain Colinet)++ | doc/Language/nativecall.pod:
Clarify int64 type and add something about using int and num type
mst nine: basically, the setup code seems to be taking a list of paths then converting each one to a standard CUR
nine yep 17:07
mst nine: I'm thinking maybe we should have a repotype file or something optionally in the root that can specify a different CUR class
and then that bit will also be responsible for ensuring we have a new enough version of whatever CUR class to handle the sha1.full format etc. etc.
orbus nine: it's still sitting there - anything I should try?
mst "defensively version ALL the things" basically
nine orbus: kill it, it won't finish 17:08
orbus okay
dha Why are you people still here? Perl 6 is out the door! Take a vacation! ;-)
orbus this *is* my vacation
I'm off work all week so I have time to mess around with perl 17:09
Skarsnik abraxxa had an issue with CArray[CArray[int8]] when working on DBIish Oracle x)
github.com/niner/Inline-Perl5/blob...l5.pm6#L88
RabidGravy well as we have discovered, there a thousand and one ways to break an installation and people don't understand lists
orbus Skarsnik: interesting 17:10
17:10 jme` joined
RabidGravy Skarsnik, that problem was actually something bit more general about typeconstraints working properly with typed CArrays 17:10
orbus is there any other documentation on native call besides doc.perl6.org/language/nativecall
?
RabidGravy no, and even that isn't complete 17:11
orbus I've seen some things in DBIish that don't seem to be documented
nine mst: I've already got plans for how custom repository classes can be registered by just installing them. It involves a directory containing e.g. a "github" file, containing the class name "CompUnit::Repository::Github". This directory is read by CompUnit::RepositoryRegistry to populate %short-id2class
Skarsnik nine, you still have some int instead of int32
RabidGravy orbus, the tests in the rakudo/t directory are a good source of information
orbus ah, okay
will take a look
when I'm less burned out
Skarsnik github.com/niner/Inline-Perl5/blob...5.pm6#L169 for example
Hm, there is not that much missing in the doc for the C part 17:12
orbus yeah
mst nine: let's not implement said plans until we've thought it through at more length
Skarsnik maybe thing about nativecast
orbus well like, the docs don't talk at all about OpaquePointer
mst nine: e.g. I don't understand why you'd have 'github' as a filename, rather than just a 'repoformat' thing
orbus and what the difference is between that and a normal Pointer
Atrox Hi, another question in terms of modules. Does the name of the github repo really has to match the name of the module?
Skarsnik OpaquePointer is an old thing
Atrox, not really, lot of module are nameed like perl6-module 17:13
Atrox Skarsnik: Great. Thanks. Because I want to name it the same way :)
nine mst: distro packages
mst also, I'm not convinced that the same repository should necessarily always map to the same repo class
Atrox Skarsnik: I just asked because in the official guide it states that. Thank you.
RabidGravy github doesn't let you put :: in a repo name afaik
mst nine: eh? 17:14
RabidGravy Atrox, the important part is the name in the META6 file
nine mst: when CompUnit::Repository::Github is installed via distro package, all it has to do is place a file in a directory to register the name. Otherwise we'd need a post-install script modifying the repoformat file
mst: and I think, right now CompUnit::Repository::Installation has the same nice characteristics. 17:15
orbus nine: I need to head out for a bit - is there anything else you want me to try before I go?
Atrox RabidGravy: Ok nice, then it is working as expected. Thank you for the answer.
mst nine: I'm not sure what you're imagining here.
17:15 _mg_ left
mst nine: I was talking about having a repoformat file in the root of the repository itself 17:16
nine mst: ooooh
lnrdo installed latest Rakudo with Panda and Task::Star. It only worked after deleting .rakudobrew folder and starting again from scratch.
nine mst: yeah, of course. That does have a bit of a startup performance penalty though, since we have to read a file for every default repo
lnrdo But it worked after all.
patrickz .tell ugexe: Do the precomp pain points for zef have RTs? For purposes of easier naging at respective devs during the christmas pause... 17:17
yoleaux patrickz: What kind of a name is "ugexe:"?!
patrickz .tell ugexe Do the precomp pain points for zef have RTs? For purposes of easier naging at respective devs during the christmas pause...
yoleaux patrickz: I'll pass your message to ugexe.
lizmat nine: wouldn't that file need to be read on the first -use- or -require- though?
dalek kudo/nom: f5b437a | paultcochrane++ | tools/build/Makefile-common-rules.in:
Remove .precomp dirs in realclean target

These directories are created as part of a `make test` run and should be removed when cleaning up.
kudo/nom: 482075d | niner++ | tools/build/Makefile-common-rules.in:
Merge pull request #660 from paultcochrane/pr/rm-precomp-dirs-in-realclean

Remove .precomp dirs in realclean target
mst nine: right, but then that file can e.g. say "this repo was minted as a v2, you can skip looking for a non-full sha file for anything in here"
so I think by like the second require() that passes through it you'd make the I/O back 17:18
nine mst: true
lizmat: true
[Coke] catches up to the part where mojca appears on channel....
awwaiid nine: Inline::Perl5 and Inline::Python is you on github, ya?
nine awwaiid: yes
awwaiid nine: are you working on making Inline::Python also work like use Blah:from<Python>, or is that an exercise for the reader? 17:19
mst nine: sorry. I'm doing impressively badly at understanding the code, I finally get some time off and my sinuses have eaten themselves
17:19 anaeem1_ joined
Skarsnik Atrox, don't hesitate to create an issue on perl6/doc on github when something is not clear/wrong on the doc 17:19
17:19 Arrowhead left, anaeem1_ left
awwaiid nine: I'm interested in that and also Inline::Ruby for the same 17:20
17:21 rfinner joined
[Coke] mojca++ for all her work on getting macports in shape. Saved me a bunch of time. :) 17:22
nine awwaiid: I've put Inline::Python development on hold to have more time for Inline::Perl5 and can figure out what exactly the whole inheritance support should look like, so I don't have to do the whole back and forth with Inline::Python, too.
[Coke] i-have-no-idea-what-im-doing.jpg
RabidGravy :)
nine awwaiid: I'd happily accept paches porting Inline::Perl5 features to Inline::Python, though! It already feels like I neglected it far too long. 17:23
awwaiid nine: ok cool. I'm not sure how much I'll dig into this in reality, but wanted to touch base. thanks!
dalek line-Perl5: b77e376 | (Stefan Seifert)++ | lib/Inline/Perl5.pm6:
Replace the last of the ints by int32

Thanks again to Skarsnik++
17:24
17:25 mojca left, vividsnow1 joined
RabidGravy on an unrelated note can one grovel in $*REPO somehow to get all the available comp units? or is it RTFC? 17:26
Skarsnik m: say int.REPR;
[Coke] still catching up in backlog, but anyone with OSX wants to try out these portfiles for nqp & rakudo, it would be a great help:
camelia rakudo-moar a352f8: OUTPUT«P6int␤»
mst btw, I've reconfigured shadowpaste, so fpate.scsys.co.uk/perl6 should totally work now
argh
Skarsnik m: say int.REPR; say int32.REPR
camelia rakudo-moar a352f8: OUTPUT«P6int␤P6int␤»
mst fpaste.scsys.co.uk/perl6 even
[Coke] trac.macports.org/ticket/50154
nine RabidGravy: the API for that doesn't exist yet.
17:26 vividsnow left, vividsnow1 is now known as vividsnow
[Coke] mojca++ 17:26
shadowpaste "mst" at 217.168.150.38 pasted "moo" (1 line) at fpaste.scsys.co.uk/503564
dalek kudo/nom: 7b462f0 | lizmat++ | src/core/tai-utc.pm:
Add some utility class methods to tai-utc

  - is-leap-second-date($date)
  - tai-from-posix(posix,prefer-leap-second?)
  - posix-from-tai(tai)
17:27
kudo/nom: 7c7e462 | lizmat++ | src/core/Instant.pm:
Use new tai-utc methods

This make Instant creation about 8x as fast
lizmat dinner&
Skarsnik m: say int.REPR eq P6opaque;
camelia rakudo-moar a352f8: OUTPUT«5===SORRY!5=== Error while compiling /tmp/FRi4KLddao␤Undeclared name:␤ P6opaque used at line 1␤␤»
Skarsnik m: say int.REPR eq 'P6opaque'; 17:28
camelia rakudo-moar a352f8: OUTPUT«False␤»
17:28 cygx joined
Skarsnik Oh I can't distinct int and int32 that way, hm 17:28
cygx m: say int.^nativesize; say int32.^nativesize
camelia rakudo-moar a352f8: OUTPUT«0␤32␤»
RabidGravy nine, so if one wanted a pluggable thingy one would be out of luck? or is there a hack available?
Skarsnik interesting cygx 17:29
nine RabidGravy: no hack that I'm aware of :/ Short of just implementing the API that is.
cygx also
* github.com/cygx/p6-tinycc/blob/lib...pes.pm#L47
Skarsnik m: say DateTime.^nativesize;
camelia rakudo-moar a352f8: OUTPUT«Method 'nativesize' not found for invocant of class 'Perl6::Metamodel::ClassHOW'␤ in block <unit> at /tmp/rqQHFzJBxR line 1␤␤»
RabidGravy Okay, cheers, I may look at it
cygx Skarsnik: only available for native ints/nums 17:30
17:30 andreoss left, sQuEE` is now known as sQuEE
Skarsnik I wish NC was using C name and not p6 native stuff directly xD 17:31
nine RabidGravy: that's a use case that really was better supported by the old CompUnit. With the new architecture, you'll have to ask for matching modules, probably get CompUnit::DependencySpecifications back and have the repo search all over just to load them. 17:33
Skarsnik Interesting, how I can find the name of the base class in a role? 17:34
hm, self.^name ?
flussence
.oO( arm26! I still have the 4-book programming manual set for those... )
gfldex m: my $i = 1; $i.^mro.put; 17:35
camelia rakudo-moar 7c7e46: OUTPUT«Use of uninitialized value of type Int in string context␤Any of .^name, .perl, .gist, or .say can stringify undefined things, if needed. in block <unit> at /tmp/Zo6o5_7bNz line 1␤Use of uninitialized value of type Cool in string context␤Any of .^nam…»
TimToady do you mean the meta class? roles in general do not have a base class
gfldex m: my $i = 1; $i.^mro.say;
camelia rakudo-moar 7c7e46: OUTPUT«((Int) (Cool) (Any) (Mu))␤»
cygx m: say <42>.^name; say <1+1i>.^name 17:36
camelia rakudo-moar 7c7e46: OUTPUT«IntStr␤Complex␤»
cygx TimToady: ^^ bug?
(as in, without spaces, afaik it should be just Int)
TimToady why wouldn't you just write 42 in that case?
Skarsnik TimToady, at run time, considering the role get 'affected' to a class 17:37
17:37 CIAvash left
gfldex Skarsnik: asking a class for a base class is kinda wrong, it's objects that have a base class. And there is monkey typing and mop-magic. So you have to ask at runtime, likely so more then once. 17:37
TimToady we make <> special for rat and complex because otherwise precedence might interfere
hard to find operators that would tear apart 42 by precedence :)
I admit it's a bit inconsistent 17:38
cygx TimToady: who cares about practical considerations - i'm talking PRINCIPLES, here!!1 ;)
timotimo perl6.org/specification/ - this probably wants a little re-wording to tell a bit more about the 6.c-ing we recently did 17:40
17:41 bpmedley_ left
Skarsnik m: my %hash = (b => 2, a => 1); say %hash.pairs.sort(*.key).values.join(",") # I try to have (1,2) here 17:42
camelia rakudo-moar 7c7e46: OUTPUT«a 1,b 2␤»
17:43 pierre-vigier joined
flussence golfed bug report now that I'm sufficiently awake: `perl Configure.pl --prefix=/usr [--sysroot=/usr]` works for perl6-m, fails `make test` for nqp-j, and completely barfs when building perl6-j. I'm seeing "javac [...] /usr/usr/" commands in rakudo's output. 17:44
17:45 supernovus joined 17:46 luis` is now known as luis 17:50 vividsnow1 joined 17:51 vividsnow left, vividsnow1 is now known as vividsnow
flussence awesome, I don't need the RAKUDO_PREFIX workaround any more. nine++ 17:52
17:52 sQuEE is now known as sQuEE`
mst flussence: /usr/usr/usr/usr/bin 17:52
Skarsnik m: my %hash = (a => 1, b => 2); say (%hash.keys.sort.map:{%hash{$_}}).join(",") #x) 17:53
camelia rakudo-moar 7c7e46: OUTPUT«1,2␤»
flussence before you ask, no I don't have any stupid symlinks there :)
17:55 Tonik left 17:58 cdg left 17:59 colomon left 18:00 colomon joined
Skarsnik m: my Str @m; say @m.^type; 18:02
camelia rakudo-moar 7c7e46: OUTPUT«Method 'type' not found for invocant of class 'Perl6::Metamodel::ClassHOW+{<anon>}+{<anon>}'␤ in block <unit> at /tmp/4jD5J6UP7F line 1␤␤»
Skarsnik m: my Str @m; say @m.^shortname; 18:03
camelia rakudo-moar 7c7e46: OUTPUT«Array[Str]␤»
18:03 virtualsue joined
Skarsnik m: class A {has Str @.m; method foo(say @!m.^shortname)}: my $a = A.new; $a.foo(); 18:04
camelia rakudo-moar 7c7e46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/IYgTjgGNSW␤Invalid typename 'say' in parameter declaration.␤at /tmp/IYgTjgGNSW:1␤------> 3class A {has Str @.m; method foo(say7⏏5 @!m.^shortname)}: my $a = A.new; $a.foo␤»
Skarsnik m: class A {has Str @.m; method foo {say @!m.^shortname}}: my $a = A.new; $a.foo();
camelia rakudo-moar 7c7e46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/pYKPHE4sry␤Confused␤at /tmp/pYKPHE4sry:1␤------> 3r @.m; method foo {say @!m.^shortname}}:7⏏5 my $a = A.new; $a.foo();␤ expecting any of:␤ colon pair␤»
Skarsnik m: class A {has Str @.m; method foo {say @!m.^shortname}}; my $a = A.new; $a.foo();
camelia rakudo-moar 7c7e46: OUTPUT«Array[Str]␤»
RabidGravy Skarsnik "of" 18:06
18:07 iH2O joined
Skarsnik hm when I try to print the type of a attribute (that I get with .^attributes) for a Str @m; I get can't find shortname method 18:07
RabidGravy m: my Str @f; say @f.^of
camelia rakudo-moar 7c7e46: OUTPUT«Method 'of' not found for invocant of class 'Perl6::Metamodel::ClassHOW+{<anon>}+{<anon>}'␤ in block <unit> at /tmp/w5IqJ4wN8F line 1␤␤»
RabidGravy m: my Str @f; say @f.of
camelia rakudo-moar 7c7e46: OUTPUT«(Str)␤»
supernovus Hmm, I apparently can't install panda with the newest Rakudo. It spews out a bunch of messages about EVAL being evil, and dies.
Skarsnik Method 'shortname' not found for invocant of class 'Perl6::Metamodel::CurriedRoleHOW' 18:08
iH2O when is release 1.0 expected?
Skarsnik iH2O, 2 days ago?
iH2O ???
TimToady supernovus: you have an old install that needs to be blown away
Skarsnik as it's realeased
mst iH2O: 6.c compiler was released on 25 Dec
supernovus Hmm, I'll nuke everything and start over.
mst iH2O: 6.c R* which contains Task::Rakudo, panda etc. will be out soon
flussence 1.0 was released bout quarter of a century ago...
autarch I'm guessing there an easy way to programmatically add subs to a package using the metamodel - could someone point me in the right direction? 18:09
iH2O i was looking at page rakudo.org
18:09 llfourn left
Skarsnik autarch, I think you can't 18:09
autarch oh, that's sad
flussence *sigh* yeah, that page is bad...
Skarsnik well not outside the package
nine autarch: I think, you can
autarch Skarsnik: right, this is inside the package
TimToady subs don't generally live in packages, they live in lexical scopes 18:10
autarch I'm trying to write a wrapper for File::LibMagic and it has about 30 flags it provides - it'd be nice to just make a list and iterate through thm
cygx can someone besides moritz add posts to rakudo.org?
autarch I guess maybe it should be adding methods?
nine autarch: github.com/niner/Inline-Perl5/blob...5.pm6#L823
autarch: github.com/niner/Inline-Perl5/blob...5.pm6#L799
18:11 lucasb joined
cygx hm... rakudo.org apparently only announces the R* releases 18:11
Skarsnik m: class A {has Str $.n; has Str @.m}; for A.^attributes -> $attr {say $attr.name, $attr.type}; #Is that a bug? 18:12
camelia rakudo-moar 7c7e46: OUTPUT«$!n(Str)␤Method 'shortname' not found for invocant of class 'Perl6::Metamodel::CurriedRoleHOW'␤ in block <unit> at /tmp/tqZw0cHL8M line 1␤␤»
nine m: class A {has Str $.n; has Str @.m}; for A.^attributes -> $attr {say $attr.name, $attr.type.^name}; 18:16
camelia rakudo-moar 7c7e46: OUTPUT«$!nStr␤@!mPositional[Str]␤»
18:16 hankache joined
hankache Good evening #perl6 18:17
18:17 iH2O left 18:18 _mg_ joined
supernovus TimToady: thanks, nuking everything and rebuilding from scratch did the trick. 18:18
TimToady we've all had to do that at some point in the last few days, eventually we'll run out of people who had rakudo up before christmas :) 18:19
hankache i nuked everything, should i rakudobrew build moar or rakudobrew build moar 2015.12 ?
TimToady how bleeding edge do you wanna be?
18:19 castj joined
TimToady 'course, not a lot has changed yet 18:20
hankache super mega bleeding edge, isn't that what Perl 6 is ;)
TimToady m: say 1,2,3 X 4,5,6 Z 7,8,9
camelia rakudo-moar 7c7e46: OUTPUT«5===SORRY!5=== Error while compiling /tmp/R7X2uhX51C␤Only identical operators may be list associative; since 'X' and 'Z' differ, they are non-associative and you need to clarify with parentheses␤at /tmp/R7X2uhX51C:1␤------> 3say 1,2,3 X 4,5,6 Z…»
TimToady that error message is upgraded over 2015.12 :)
maybe we need to distinguish a c: for chrismas version 18:21
supernovus At some point I should look at rakudobrew to replace my moon script that I've been using for the last 4 years.
Skarsnik nine, should I fill a RT to have shorname of this kind of stuff? (or have say work on it at least) 18:22
18:25 SwellJoe left
nine Skarsnik: if there is not already a ticket for this, yes, please. 18:26
18:26 _mg_ left
lucasb class Perl6::Metamodel::CurriedRoleHOW does Perl6::Metamodel::Naming 18:26
^^ would this help with the 'shortname' thing? 18:27
Skarsnik No ticket with this error x)
18:28 mcmillhj_ joined, davercc left, Arrowhead joined
Skarsnik There should be something like ! to force operator to check if the left part is defined x) 18:29
18:30 Begi left, davercc joined
[Coke] Richard Hainsworth points out we didn't mention the financial sponsors. We should mention Ian Hague and jnthn's core grants. anything else? (Do we need to delve back into parrot?) 18:31
18:32 perigrin joined 18:34 Ch0c0late left
flussence It'd be the right thing to do 18:35
mst [Coke]: at this point I think it'd be more accurate to say 'exhume'
argh argh void context map in rakudbrew sources argh 18:38
mst adds to list of things to change
tadzik 3>:o 18:40
yoleaux 27 Dec 2015 09:32Z <AlexDaniel> tadzik: well, if you are not going to fix the issue with POST params then consider giving me push access so that I can do it. Same nickname on github. Basically I will just merge the pull request and apply my 1-character patch, that should make the tests green as well (if not, then I'll try to look into it, but anyway it will fix the issue with POST params…)
27 Dec 2015 19:59Z <Zoffix> tadzik: can you please merge this, as we have some extreme destruction for some users: github.com/tadzik/rakudobrew/pull/72
tadzik wow
Atrox Guys, how can I remove a empty element from a array? Is there a easy way to filter?
tadzik @array.=grep(*) might work
flussence that's an error iirc 18:41
m: my @a = 1, 2, Nil, 4; @a.=grep(*)
camelia ( no output )
flussence or not
m: my @a = 1, 2, Nil, 4; say @a.=grep(*)
camelia rakudo-moar 7c7e46: OUTPUT«[1 2 (Any) 4]␤»
flussence m: my @a = 1, 2, Nil, 4; say @a.=grep(*.defined)
camelia rakudo-moar 7c7e46: OUTPUT«[1 2 4]␤»
flussence m: my @a = 1, 2, Nil, 4; say @a.=grep(*.so)
camelia rakudo-moar 7c7e46: OUTPUT«[1 2 4]␤»
flussence ↑ there you go, depending on what you want "empty" to mean 18:42
Atrox Awesome. Thanks.
cygx grep(?*) should also work
18:42 domidumont joined
cygx (as an alternative to *.so) 18:42
18:43 SwellJoe joined
TimToady m: my @a = 1, 2; @a[3] = 4; say @a[]:v 18:44
camelia rakudo-moar 7c7e46: OUTPUT«(1 2 (Any) 4)␤»
gfldex m: my @a = 1, 2, 0, 4; say @a.=grep(*.so)
camelia rakudo-moar 7c7e46: OUTPUT«[1 2 4]␤»
TimToady I thought :v was supposed to remove non-existing elements by default
gfldex please don't use *.so
TimToady it depends on the use case 18:45
m: my @a = 1, 2; @a[3] = 4; say @a[*]:v 18:46
camelia rakudo-moar 7c7e46: OUTPUT«(1 2 (Any) 4)␤»
nine Oh how I hate seeing my little mistakes baked into the language by badly written test code...
TimToady m: my @a = 1, 2; @a[3] = 4; say @a[^4]:v
camelia rakudo-moar 7c7e46: OUTPUT«(1 2 4)␤»
TimToady I guess it only does it with explicit subscripts
tadzik yoleaux: tell AlexDaniel merged now with the required fix, sorry to keep you waiting
.tell AlexDaniel merged now with the required fix, sorry to keep you waiting
yoleaux tadzik: I'll pass your message to AlexDaniel.
tadzik thank you
TimToady m: my @a = 1, 2; @a[3] = 4; say @a[^∞]:v 18:47
camelia rakudo-moar 7c7e46: OUTPUT«(1 2)␤»
TimToady uh, oopsie?
cygx if I wanted to make what happens on `use v5` pluggable, would it be ok to stuff some Callable into %*PRAGMAS<v5>?
18:48 Ara joined
TimToady m: my @a = 1, 2; @a[3] = 4; say @a[^*]:v 18:48
camelia rakudo-moar 7c7e46: OUTPUT«(1 2 4)␤»
Arrowhead is sub MAIN documented anywhere?
18:48 Ara left
TimToady I guess that's about the best we can do at the moment for "really non-existing" rather than just undefined 18:48
18:48 dfarrell joined 18:49 SwellJoe left
flussence Arrowhead: doc.perl6.org/language/5to6-nutshel...%3A%3ALong has examples, design.perl6.org/S06.html#Declaring...subroutine has details 18:50
gfldex m: my @a; @a[0] = 1; @a[2] = 3; dd @a.keys; 18:51
camelia rakudo-moar 7c7e46: OUTPUT«0..2␤»
gfldex i do not agree with rakudo on that
autarch I don't know exactly what this error is telling me - Calling magic_file(File::LibMagic::Cookie, Str) will never work with declared signature (NativeCall::Types::Pointer, Str --> Str)
Arrowhead flussence: thanks!
18:52 Guest15478 joined
nine cygx: use v5; is handled directly by the grammar. I don't see how %*PRAGMAS comes into this? 18:52
autarch no matter what I use for that sub signature I get basically the same error
hankache m: my @a; @a[0] = 1; @a[2] = 3; say @a[1]; 18:53
camelia rakudo-moar 7c7e46: OUTPUT«(Any)␤»
hankache m: my @a; @a[0] = 1; @a[2] = 3; say @a;
camelia rakudo-moar 7c7e46: OUTPUT«[1 (Any) 3]␤»
hankache gfldex ^^
cygx nine: currently, it doesn't - that's the change I want to make instead of hardcoding loading a module called `Perl5`
dfarrell hey folks, is there any documentation available on using different versions of the same module in the same program? 18:54
gfldex hankache: i do agree that there is a hole. I do not agree with a Range as a good way to represent something that can have holes. 18:55
nine dfarrell: I think, that's not fully supported yet
dfarrell: lots of infrastructure is already there, but not hooked up together.
Skarsnik autarch, magic_file does not want a File::LibMagic::Cookie if it's not a REPR Pointer 18:56
18:57 bpmedley_ joined
autarch Skarsnik: but it _is_ a pointer! my class Cookie is repr('CPointer') 18:57
hankache gfldex i got you, a better representation would be a list omitting the holes (0,2)
dfarrell nine: ok, thanks. That's what I thought too, until I read this post: wendyga.wordpress.com/2015/12/25/w...e-answers/
autarch and I have two other subs (magic_descriptor and magic_buffer) that work exactly the same way and don't cause warnings
lucasb so, there is a difference when you create an array with 'my @a; @a[10] = 42' and when you type 'my @a = Nil,Nil,...,42' ?
Skarsnik autarch, that pretty weird 18:58
I am not sure the --> Str work?
autarch here's the code - gist.github.com/autarch/d7153a6371f430289c10 18:59
they all return a Str
18:59 mojca joined
gfldex lucasb: assignment of Nil to a container will set the container to it's default value. Autovivication of arrays will result in Nil turn to Any (or the arrays containers type). 18:59
hankache m: my @a; @a[2] = 1; my @b; @b = Nil,Nil,2; say @a ~~ @b; 19:00
camelia rakudo-moar 7c7e46: OUTPUT«False␤»
hankache m: my @a; @a[2] = 1; my @b; @b = Nil,Nil,2; say @a == @b;
camelia rakudo-moar 7c7e46: OUTPUT«True␤»
hankache lucasb no difference ^^
lucasb m: my @a = Any,Any,Any,42; say @a[^4]:v 19:01
camelia rakudo-moar 7c7e46: OUTPUT«((Any) (Any) (Any) 42)␤»
lucasb m: my @a; @a[3] = 42; say @a[^4]:v
camelia rakudo-moar 7c7e46: OUTPUT«(42)␤»
Skarsnik autarch, put magic_file before magic-file?
autarch Skarsnik: doesn't help 19:02
Skarsnik wait you already do the same thing for the other
19:03 supernovus left
dfarrell Does anyone know of a resource that shows the implementation status of Perl6, e.g. which features are/aren't available? 19:03
Skarsnik autarch, did you try directly with the class name instead of just Pointer?
19:04 ggoebel9 left
flussence dfarrell: perl6.org/compilers/features (but it's growing moss) 19:04
Skarsnik rakudo main page maybe?
flussence the things in green are all correct, the others may not be
19:04 llfourn joined
dfarrell flussence: thank you! that's useful 19:05
lucasb what I meant is that those 2 arrays look exactly the same, but they behave different with regard to subscripting adverbs :k,:v,etc. maybe it's intended or not, idk. 19:06
19:06 SwellJoe joined
hankache m: my @a = Nil,Nil,Nil,42; say @a[^4]:v 19:07
camelia rakudo-moar 7c7e46: OUTPUT«((Any) (Any) (Any) 42)␤»
ChoHag Can a where clause in a Signature reference more than one of the incoming variables?
hankache lucasb dunno if it's intended or not 19:08
cygx bye o/
19:09 cygx left
gfldex m: sub f($a, $b where $a == $b) {'OK'}; say f(1,1); say 'alive'; say f(1,2); 19:09
camelia rakudo-moar 7c7e46: OUTPUT«OK␤alive␤Constraint type check failed for parameter '$b'␤ in sub f at /tmp/H20MCIT5yF line 1␤ in block <unit> at /tmp/H20MCIT5yF line 1␤␤»
gfldex m: sub f($a, $b where $a == $b) {'OK'}; say f(1,1);
camelia rakudo-moar 7c7e46: OUTPUT«OK␤»
gfldex ChoHag: yes ^^^
are signatures turing-complete?
19:09 llfourn left
autarch Skarsnik: no warning with the class name 19:10
nine gfldex: they must be since they can call arbitrary code
19:11 espadrine left 19:12 nash_ joined, Guest15478 left 19:13 lnrdo left, bpmedley_ left
gfldex .oO( Perl 6 begins to learn at a geometric rate. It becomes self-aware at 2:14 a.m. Eastern time, August 29th. ) 19:14
flussence
.oO( it OOMs at 2:15 )
dalek kudo/nom: 9053c4e | lizmat++ | src/core/DateTime.pm:
Use faster leap-date determination
19:15 kivutar joined
Atrox Is there a depends for tests/development only (for example Test::META)? Because my module only needs this in the test files. 19:17
Skarsnik I found an interesting bug x) self.^shortname on a role give the role name + }
flussence Atrox: "test-depends" in META is exactly that 19:18
Atrox flussence: Thanks ._.
Skarsnik test-depends feel like it's something panda will run
Atrox Why is this not in the official documentation.... ._. 19:19
Skarsnik I mean if you write 'xt' test and put the dep in test-depends I fear panda will install the deps x)
flussence Atrox: design.perl6.org/S22.html#META6.json has everything, sorta 19:20
lizmat hmmm... it appears that tai-utc isn't documented, specced or spectested
Atrox flussence: I looked at doc.perl6.org/language/modules Thanks for the link
lucasb Skarsnik: can you show the self.^shortname thing? I tried but couldn't reproduce
lizmat thinks she's going to make an internal module
19:20 madjestic joined
lizmat *it 19:20
Skarsnik actually I can't too for a small test x) 19:22
ChoHag Does returning multiple values from a sub still work the same way it did in perl 5?
Skarsnik probably not
lucasb Skarsnik: ah, ok
lizmat m: sub a() { 1,2,3 }; my ($a,$b,$c) = a; dd $a, $b, $c
camelia rakudo-moar 7c7e46: OUTPUT«Int $a = 1␤Int $b = 2␤Int $c = 3␤»
flussence alright, I've ruled out Standard Gentoo Crap and still can't get -jvm to build so I'll leave this here for someone more knowledgeable to look at:
shadowpaste "flussence" at 217.168.150.38 pasted "perl6-j test/build failures" (54 lines) at fpaste.scsys.co.uk/503571
lizmat Skarsnik ChoHag seems to me it does
madjestic is anybody running perl6 on gentoo? 19:23
flussence yeah
Skarsnik it work because you return a list :)
and ($a, $b, $c) = 'dispatch' the list 19:24
m: role R { method foo{say self.^shortname}; method bar{self.foo()}}; class A {}; my $a = A.new; $a does R; $a.bar 19:26
camelia rakudo-moar 7c7e46: OUTPUT«A+{R}␤»
gfldex the following talk will start in 4 minutes and may be of interest: events.ccc.de/congress/2015/Fahrpl.../7130.html 19:27
streaming.media.ccc.de/32c3/
stream Hall 1
lucasb Skarsnik: ah, thanks. but isn't it expected?
19:27 CIAvash joined
Skarsnik I have say "hello";say self.^shortname; and I get : hello QDBStorable} 19:27
19:28 madjestic left
RabidGravy how do I get around: 19:28
m: use NativeCall; class Foo is repr("CStruct") { has Str $.foo; }; Foo.new(foo => "dgdgd")
Skarsnik so I am confused x)
camelia rakudo-moar 7c7e46: OUTPUT«Cannot modify an immutable Str␤ in block <unit> at /tmp/y89eKM_PQ1 line 1␤␤»
Skarsnik I am not sure you can new a CStruct?
lizmat m: use NativeCall; class Foo is repr("CStruct") { has Str $.foo; }; Foo.new(foo => my $ = "dgdgd")
camelia rakudo-moar 7c7e46: OUTPUT«Cannot modify an immutable Str␤ in block <unit> at /tmp/s7FWWBpaxW line 1␤␤» 19:29
Skarsnik m: use NativeCall; class Foo is repr("CStruct") { has Str $.foo is rw; }; Foo.new(foo => "dgdgd")
camelia rakudo-moar 7c7e46: OUTPUT«Cannot modify an immutable Str␤ in block <unit> at /tmp/aK3eX0SMgj line 1␤␤»
RabidGravy Skarsnik, yeah you can, it's just something about the strings
Skarsnik I could be because NC will not know how to pass the Str later ? 19:30
RabidGravy now if you do
Su-Shee 8/win close
RabidGravy m: use NativeCall; class Foo is repr("CStruct") { has str $.foo; }; say Foo.new(foo => "dgdgd").perl
camelia rakudo-moar 7c7e46: OUTPUT«Foo.new(foo => "dgdgd")␤»
RabidGravy that's fine, but I'm pretty sure it shags the string up somehow 19:31
Skarsnik str is buggous
I had segfault with it
RabidGravy yeah, that's what I'm seeing, it's the only thing left
19:31 nash_ left
masak evenin', #perl6 19:31
yoleaux 11:16Z <lizmat> masak: is there a reason why DateTime.new(1972,12,31,23,59,60,0).later(:86400second) and DateTime.new(1972,12,31,23,59,60,0).later(:1day) should give different results ?
Skarsnik That why I exclude it in NC::TypeDiag x)
masak lizmat: yes, I think so. 19:32
lizmat: so, that's one of them 61-second minutes, right?
Skarsnik RabidGravy, damn this execption is from Core 19:33
lizmat masak: yup
Skarsnik Did you get bt in NC at some point?
masak lizmat: I'm a bit fuzzy on the exact details of the .later algorithm, but when you say .later(:1day), it's supposed to take you to "the same" hh:mm:ss on the next day. 19:34
lizmat: which isn't possible in this case. so it truncates.
lizmat: whereas if you say "this exact amount of seconds later", it's pretty clear you don't want the truncation
Skarsnik lucasb, btw my goals was to get the name of A and not R x)
lizmat masak: ok
19:35 domidumont left
masak lizmat: or, a much easier way to say it -- that's one of the few days where "1 day" and "86_400 seconds" don't coincide 19:36
19:36 arkvolk joined
mojca I managed to prepare packages for MoarVM, nqp, rakudo for a package manager; what's next? What else is needed to get closer to rakudo-star? 19:36
arkvolk How I make cperl-mode works with Perl6?
masak so I think the current semantics is sane -- it's just leap seconds that are really weird 19:37
TimToady
.oO(why doesn't time come with a snap-to-grid option?)
19:38
flussence is getting some Time Cube vibes from this C3 presentation
19:38 woolfy left
nine gfldex: err...that talk is not interesting at all. It's just more of the same crap as the last one. The first slide I see supposedly showing "common code that's used a lot" contains a bug on the second line that will make it not work at all. 19:39
RabidGravy mojca, it needs "panda" and all the modules in Task::Star as well afaik 19:41
nine "The whole perl security module is based on the asumption that CGI won't let you create hashes"
19:41 cbk_ left
autarch hmm, there's no NativeCall sugar for macros defined in .h files, is there? 19:41
masak wow, 007 has had 22 pull requests so far. people++
RabidGravy autarch, no. It's either make a tiny C helper or reimplement 19:42
autarch easy enough to copy I guess
19:42 jervo left
Skarsnik autarch, declare them as enum? 19:42
[Coke] Anyone have any input on the categorized search branch for docs?
Skarsnik should be easy to have a slang that transform #define foo 1 in a enum value? 19:43
japhb Aside from 'use nqp;' (or the new version thereof), is NQP currently a true subset of Perl 6? Meaning, is there any NQP code that would be interpreted semantically differently as Perl 6 code? 19:44
RabidGravy I think people have individually hacked up their own solutions for that, I did some sed thing a while back
[Coke] gets an email when is 6.0.0 and explains the 2 different versions to worry about. gets a reply back of thanks for the explanation. When is 6.0.0?
[Coke] sighs.
mort96 Morning
19:45 arkvolk left
dalek kudo/nom: a2c1d86 | lizmat++ | / (7 files):
Move tai-utc into Rakudo::Internals
19:45
autarch Skarsnik: they're not strictly ascending in this case 19:46
19:46 yurivish_ joined
Skarsnik this guys is dumb, it mix stuff x) 19:46
autarch, you can write PLOP => 42, NYO => 1
nine Are all CCC talks that bad? 19:47
flussence the 3DS one last night was kinda fascinating :)
19:48 mst left, mst joined
Skarsnik "You don't know" you can always test with ref what you get.. 19:48
RabidGravy anyone bored and want to figure out why the hell github.com/jonathanstowe/p6-GDBM is segfaulting? 19:49
perigrin nine: no that guy is particularly bad
19:49 jervo joined
RabidGravy I've exhausted nearly every possibility 19:49
autarch How do I call a method when the method name is in a scalar?
m: my class Foo { method bar { 42 } }; my $m = q{bar}; say Foo.new.$m
camelia rakudo-moar 9053c4: OUTPUT«Cannot find method 'CALL-ME'␤ in block <unit> at /tmp/loyAXr2vVB line 1␤␤»
autarch I'd expect that to work but clearly not
Skarsnik I did that 19:50
let me find it
RabidGravy m: my class Foo { method bar { 42 } }; my $m = q{bar}; say Foo.new.$m()
camelia rakudo-moar 9053c4: OUTPUT«Cannot find method 'CALL-ME'␤ in block <unit> at /tmp/fIcp3sTHAx line 1␤␤»
RabidGravy uh?
[Coke] tries again.
autarch I would really expect that to work - if this is harder in p6 than p5 it seems like a step backwards 19:51
19:51 hankache left
[Coke] mojca: I don't think a rakudo-star makes sense as a mac port. 19:51
Skarsnik $h."$foo"
RabidGravy m: my class Foo { method bar { 42 } }; my $m = 'bar'; say Foo.new.$m()
camelia rakudo-moar a2c1d8: OUTPUT«Cannot find method 'CALL-ME'␤ in block <unit> at /tmp/SVTX8JVzCb line 1␤␤»
autarch is probably missing something obvious
aha
RabidGravy nope that's weird
mst [Coke]: how not?
Skarsnik github.com/sergot/http-useragent/b...es.pm6#L37
autarch m: my class Foo { method bar { 42 } }; my $m = q{bar}; say Foo.new."$m"()
camelia rakudo-moar a2c1d8: OUTPUT«42␤»
autarch good enough
19:51 woolfy joined
lucasb I already asked in the backlog, but will ask again if anyone knows why nqp syntax is so permissive/forgiving? 19:51
[Coke] mojca: But, if we head down that path, I imagine you'd need a port for each of the various modules that were included into star; and then a rakudo-star port that depended on rakudo & the module ports. 19:52
lucasb nqp-m: foo + bar; a ~ b; x,y,z; my $x := Oh::Hai.new; say('alive')
camelia nqp-moarvm: OUTPUT«alive␤»
RabidGravy oh yes, it used to have an error message about the quotes
which is a step backward
[Coke] mst: is there a batteries included perl5 macport? (or other portage system por?)
autarch yay, I made it segfault! 19:53
Skarsnik aside from saying "look CGI perl is buggy" what this talk about?
mst [Coke]: perhaps then a rakudo port, plus a panda port, and then they get the rest via 'panda install Task::Rakudo' or so?
[Coke] will just merge the categorized search back to master and push it. :P
mst: certainly a panda port would be nice, sure. 19:54
flussence Skarsnik: "look Bugzilla is a huge ball of mud", I guess
mst [Coke]: I'm not sure. I'm not trying to disagree with you here, so much as figure out the reasoning so I can decide -if- I agree :)
[Coke] mojca++ # port mania!
mst but, I mean, we ship R* as a .msi
19:54 cbk_ joined
mst what should be the equivalent instructions to OS X users? 19:54
woolfy Hi all. I'm in a discussion that is too much over my head. How well is Perl 6 supporting (has implemented) IEEE 754? (I did try to find this myself, and found this on Wikipedia: en.wikipedia.org/wiki/IEEE_floating_point ) (but trying to find the specifics in Perl 6 code is over my head.
(discussion is elsewhere, not here)(d'oh) 19:55
[Coke] mst: I was never a fan of having a bajillion p5 ports (one per module); I suppose if it's automatable...
perigrin mst: buy a windows laptop and install hte msi?
perigrin hides.
[Coke] mst: use the non msi version; works fine.
mst perigrin: well if we're trying to be *sensible* I think the answer for both windows and OS X should be "here's a dollar, get yourself a debuntu VM already"
woolfy I've read Ovid's helpful blog: blogs.perl.org/users/ovid/2015/02/a...cobol.html
[Coke] you don't need macports to install R*
nine Now he's happily demonstrating a security issue in his own code where he uses $cgi->param to "get at the uploaded file's handle" contrary to all documentation
[Coke] woolfy: I have no idea on the specifics. 19:56
m: say NaN==NaN
camelia rakudo-moar a2c1d8: OUTPUT«False␤»
[Coke] So, at little, anyway
*a
perigrin mst: the equivlant to an MSI for OSX though is a full installer that probably installs to /usr/local rather than any of hte ports systems
autarch any idea why this code segfault - github.com/autarch/perl6-File-LibMagic 19:57
just run "perl6 t/basic.t"
mst perigrin: perhaps
woolfy [Coke] thanks, maybe I should stick with mentioning Ovid's post.
mst what I'm mostly saying is "we seem to be trying to make rakudo easier to get for macports users"
given that's the goal, we should at least have -a- way to get to an R* atop a macports rakudo
nine Ok, which NativeCall data type should I use if I need a 32 bit int on a 32 bit system, but a 64 bit int on a 64 bit system? Because that's what perl 5's IV is. 19:58
[Coke] So, I think my plan makes some sense; it's just a PITA to create N ports.
Skarsnik That a good question nine
[Coke] [meta] we might need to starting using threads to indicate what we're talking about. getting noisy in here. :)
lucasb or split another channel 19:59
awwaiid m: say "newline\ntest"
camelia rakudo-moar a2c1d8: OUTPUT«newline␤test␤»
Skarsnik nine, is that long?
perigrin [Coke]: to answer your earlier question ... as far as I can tell most of the ports systems on OSX (the two or three I've used at least) tend to be hands off once they've gotten you bootstraped into the language's build system.
nine Skarsnik: don't think so. I'm already using long and it's wrong for orbus's system as it seems 20:00
mst right, which is why I was thinking "we should make sure there's a defined way to get to a full R* using panda (or whatever), and make sure there's a port for panda (or whatever)"
perigrin ^^^
mst [Coke]: the threading was fine until somebody randomly stuck [meta] in front of a line in a weirdly un-irc-ish way and then my mental parser crashed :D
perigrin [Coke]: Added bonus to mst's plan is that it works for homebrew users too :)
RabidGravy autarch, I'd start with int32 rather than int 20:01
Skarsnik nine, our native long is Int is ctype("long") is repr("P6int") { };
wait 20:02
that's dumb
20:02 cygx joined
cygx nine: my native cintptr is Int is nativesize(nqp::nativecallsizeof(Pointer) * 8) is repr<P6int> {} 20:02
autarch RabidGravy: that gives me this - gist.github.com/autarch/cefa8b1ddb1606dba306 20:03
Skarsnik size_t maybe?
RabidGravy eh?
autarch, let me clone your code 20:04
'ang on
autarch RabidGravy: no permission needed ;)
[Coke] ... good point. get to panda, then run task::star. points.
20:05 llfourn joined
Skarsnik nine, can you link me perl5 header/doc ? 20:05
Atrox Hi, does anyone have time to take a look at: github.com/Atrox/haikunatorperl Would love to get feedback on the code itself.. I don't know if this is the idiomatic way of writing perl ._.
Skarsnik haikunate(:tokenHex(True)) you don't need the True here ^^ 20:06
:tokenHex
But this look fine 20:07
Atrox ah nice.
autarch Atrox: I don't know about Perl 6 but in 5 we use "snake_case", not "camelCase" - in 6 I mostly see "snake_case" or "what-is-this-case"
and by "we" I mean Perl 5 people who didn't first spend years writing Java ;) 20:08
Atrox autarch: yeah, I thought about the same... but I didn't find any style guide or linter at all for perl 6 :/
masak autarch: kebab-case, it seems to be called
Skarsnik kebab case is getting more common 20:09
mspo I just saw the term snake_cast for the first time today
case
autarch I just realized it should be flying-snake-case!
that's so much better than kebab
flussence
.oO( it's 2015, we have hoversnakes now )
20:10
autarch ooh, hover-snake-case is good too
20:10 lucasb left
masak .oO( ~~~flying~spaghetti~monster~case~~~ ) 20:10
lizmat
.oO( my hover-snake-case is full of eels )
dha masak++
20:10 llfourn left
Skarsnik hipster'case 20:10
dha lizmat++
konobi themetapicture.com/linguistic-lesson/ 20:11
masak .oO( basket🏀case )
oh, and today's autopun spotting: twitter.com/wellendonner/status/67...9705501696 20:12
mojca RabidGravy: thank you; [Coke]: yes, I also imagine one port/package per module, but I wanted to get the idea about what else was missing 20:13
20:13 gist_nb left, h3kker joined
orbus reverse case - all identifiers should be desrever for added clarity 20:13
20:14 darutoko left
[Coke] mojca: just getting panda working and then using panda to install modules is also fine. (and lets us minimize the amount of work, and have similar instructions for homebrew) 20:14
you'll need at least that much anyway.
20:15 h3kker left
nine Skarsnik: the P5 type is detected and generated by the Configure.pl script 20:15
mojca [Coke]: from what I've seen homebrew installs just rakudo-star
Skarsnik nine, in perl5 lib?
mojca [Coke]: let me know once you test the rakudo port 20:16
nine Skarsnik: gist.github.com/niner/6cda6646e81bbd377cc6 20:17
20:17 pdcawley joined
Skarsnik look like you will need to do the same check? 20:18
20:20 pierre-vigier left
timotimo lol the perl jam 2 dude showed an exploit with CGI.pm with code copied from its docs 20:20
Skarsnik m: role R { method foo{say self.^name}; method bar{self.foo()}}; class A {}; my $a = A.new; $a does R; $a.bar 20:21
camelia rakudo-moar a2c1d8: OUTPUT«A+{R}␤»
nine timotimo: no, if it were copied from the docs it would not have been exploitable
Skarsnik hm, How I can get only A ?
nine timotimo: he exchanged upload and param
timotimo nine: does it use << >> in the docs?
gfldex timotimo: that talk is fine advertisement for Perl 6
nine timotimo: oh, maybe you mean a different "exploit"
timotimo Juerd: i heard you gave him a question
20:22 cygx left
timotimo nine: where an uploaded file turned into a string instead of FD and he used it with < > and put | at the end of one of the params 20:22
nine timotimo: that's the one I mean. It should have been my $fh = $cgi->upload('file'); not $cgi->param('file')
Juerd timotimo: Yes, I did. The 'signal angel' did mangle the question a bit. But it's okay.
timotimo oh, he only used upload in the if statement, right? 20:23
gfldex the importent bit is that the string is ARGV, and CGI.pm will fill ARGV with the user input for you
nine timotimo: nowhere in CGI's docs does it ever tell you that param returns a file handle
Juerd nine: It used to.
nine timotimo: yes, it's completely his own screwup
timotimo Juerd: i was a signal angel in the past, it is quite hard to get that stuff right
Juerd nine: A long, long time ago.
timotimo: I phrase literal questions :)
leedo timotimo: wasn't CGI.pm even removed from perl 5 core?
Juerd leedo: It was
timotimo: Are you here?
flussence leedo: precisely *because* people keep screwing it up like this :) 20:24
nine And the crap about "the whole perl security module is based on <his very own bullshit> asumption!"
leedo that is weird, the abstract on that talk was all about "exploiting perl 5 core" or some such stupidity
timotimo Juerd: i am not
nine: can you give me a direct link to that part of the docss
Skarsnik well having <> doing special stuff with ARGV is weird xD
Juerd Skarsnik: Yes, I agree that <ARGV> doing 2-arg open is a security issue.
leont leedo: he's a lying bully, I didn't believe that for a moment
20:25 pdcawley left, frobisher joined
nine timotimo: perldoc.perl.org/CGI.html#PROCESSIN...LOAD-FIELD 20:25
leedo leont: yeah, sounds like it
Juerd leont: Well, the point about <ARGV> and 2-arg open is valid.
timotimo perldoc.perl.org/CGI.html#PROCESSIN...LOAD-FIELD - this doesn't have it
20:25 dha left
Juerd leont: It's a documented feature but an intensely dangerous one. 20:25
timotimo Juerd: doesn't <<ARGV>> not give you that problem?
gfldex leont: he got a working exploit and that means he is right
nine gfldex: an exploit in his own code 20:26
I can write exploitable code easily and blame it on some language
gfldex gfldex: i don't think he wrote bugzilla
leont I hate the feature as much as anyone else (except tchrist, who seemed to love it), but I wouldn't call that "exploiting perl 5 core"
Skarsnik what the use case to have <ARGV> to something?
timotimo nine: that doesn't have <$foo> in it at all
Juerd timotimo: IIRC something like that was introduced, yes. 20:27
gfldex nine: and his 2nd bit of code came from CGI.pod
timotimo and what idiot threatened this dude's life?
Juerd timotimo: I don't believe that anyone did. The dude has not refrained from lying about other stuff and I think this too is imagined, not real.
20:27 frobisher is now known as dha
flussence (and how hard was he baiting them to get that kinda reaction?) 20:27
timotimo flussence: well, last year's talk 20:28
dha Oh, is someone lying about stuff again? 20:29
gfldex flussence: if you take the troll bait, you are the troll
timotimo let's not just call him a liar just yet
until we find where he copy-pasted that piece of code from
Skarsnik hm what the eqv of my ($var1, $var2) = $str =~ /(\d);(\d)/ ?
flussence timotimo: well that was a github screenshot, so could be a million different places 20:30
gfldex and he got a point. It's incredible hard to write secure perl 5 code. What doens't make him less of an asshole ofc. There is however no reason not to learn from an assholes good points.
Juerd gfldex: He had 1 good point and a dozen instances of utter bullshit
nine gfldex: no, it's not hard at all if you just read the docs
Juerd gfldex: I disagree that it is hard to write secure Perl 5 code. It is hard to write really secure code in any language, Perl 5 being *easier* to write secure code in, than the average of all languages. 20:31
leont Yes, what Juerd says
nine gfldex: the whole DBI docs tell you to use placeholders. Not a single example strays from this. Some Bugzilla coder didn't get the message and suddenly it's "Perl's security module" that's wrong
timotimo Juerd: except if you're not careful in p5 about what's scalar, list, array or hash the functions you use will suddenly behave extremely differently
20:32 cygx joined
leont timotimo: there aren't that many functions that have that issue, really 20:32
timotimo maybe
i don't know anything about p5, actually
mst and we've been discouraging people from writing more for over a decade now
cygx examples/file_upload.cgi from CGI-4.25.tar.gz
timotimo cygx: thanks for spotting that!
mst gfldex: the file upload documentation mistake is extremely unfortunate, and definitely needs fixing 20:33
timotimo cygx: where can i access that on the 'net?
cygx timotimo: CPAN?
leont Juerd: Also, our knowledge of how to write secure code is improving. Some issues were gravely underestimated in all code 15 years ago
timotimo i am on cpan
mst OTOH CGI.pm hasn't been a recommended way to write code for some time
timotimo i have a download button or a "source" button for the pod only
mst: quite the opposite, no?
cygx search.cpan.org/CPAN/authors/id/L/L....25.tar.gz
mst timotimo: p3rl.org/CGI - then click to the dist, which will list all files, and the examples are clickable
Juerd leont: Agreed
timotimo mst: hasn't the reaction to CGI been "NO! STOP! GO AWAY! NO!" for a long tmie?
mst timotimo: yes. 20:34
timotimo: and then he rages about Catalyst and Mojolicious having different APIs ... which we did specifically because CGI.pm's were pretty terrible :)
timotimo i can't find the examples/ thing yet
mst timotimo: yeah, so if you click the CGI-4.25 link at the top of the page
timotimo: that takes you to metacpan.org/release/CGI
timotimo: which lists the examples
flussence has one Anecdote From Old $Dayjob involving CGI.pm that'd probably give people here a heart attack if I went into details
RabidGravy autarch, fixed it for you
timotimo ah 20:35
virtualsue so is this fallout from whatsisname at ccc?
timotimo that was hard to find
autarch RabidGravy: how'd you do it?
timotimo thanks
now i see it
and yeah, it's bad
RabidGravy I'll PR it but basically magic_setflags needed to be a sub *and* you were using open() instead of magic_open() 20:36
Skarsnik spend 4 hours generating 2 sql querry, is happy
timotimo nice. CGI.pm's readme actually tells potential users that there's better stuff available and what it is 20:37
gotta run grocery shopping now!
autarch RabidGravy: ah, I see - maybe NativeCall needs some more defensive code so it doesn't segfault on that sort of error
RabidGravy github.com/autarch/perl6-File-LibMagic/pull/1 20:38
autarch RabidGravy: thanks!
dha Yeah, but who reads the realm? 20:39
RabidGravy autarch++ for making a magic
dha dammit, the readme
flussence was trying to figure out if that was a jab at NTLM-over-HTTP for a minute
20:39 SwellJoe left
masak copying the entire contents of a well-known much-used module (and then modifying it in non-upstreamable ways) rather than just taking on a module dependency? discuss. 20:39
flussence Chromium tarballs. :) 20:40
masak moritz: by the way, github.com/moritz/json ain't got no LICENSE :P
(I might actually have the patience to turn my modification into a pull request, too. that'd be nice, now that I think about it.) 20:41
20:41 wingfold joined, brrt joined
gfldex timotimo: sadly the argument CGI.pm ain't no part of CORE anymore isn 20:41
gugod I'm a bit confused by this: [Int.max, Int.min]
gfldex timotimo: (sorry), really helpful see packages.debian.org/search?searcho...p;arch=any
gugod m: [Int.max, Int.min]
camelia ( no output )
gugod m: say [Int.max, Int.min].perl
camelia rakudo-moar a2c1d8: OUTPUT«[-Inf, Inf]␤»
20:41 Atrox left
gugod until I realize that there really are no min/max methods 20:42
is there a something similar to B::Deparse in perl6 land ? 20:43
nine gugod: perl6 --target=ast
flussence there's perl6 --t.. that :) 20:44
gugod nice
dalek osystem: 324779b | Atrox++ | META.list:
add Haikunator
osystem: cf3cb35 | RabidGravy++ | META.list:
Merge pull request #105 from Atrox/patch-1

Add Haikunator
masak how can I check whether there was a trailing separator in `<item>+ %% <sep>` ? (without reparsing)
flussence (one day in the distant future, we might even have a DOM-tree-style API...)
20:45 yurivish_ left
masak flussence: working on it :) 20:45
ChoHag Does EVAL $string do anything other than what eval $string does in perl 5?
20:45 webstrand joined
flussence masak: um, would `<item>+ %% <sep> <trailing-sep=.sep>?` work or am I misunderstanding %%? 20:45
autarch ok, so it doesn't segfault, but it doesn't actually work - how do I go about debugging NativeCall-using code? Like if I want to see what's happening on the C side? 20:46
lizmat ChoHag: it parses perl 6 by default ? 20:47
nine autarch: gdb?
autarch nine: ugh, right
autarch dusts off his minimal gdb skills ...
nine that's all you need :)
dalek kudo/nom: 64a61a3 | lizmat++ | src/core/Rakudo/Internals.pm:
Simplify $*TZ initialization
masak flussence: ooh, that's a nicer solution than the one I ended up with. :)
perlpilot masak: you could also probably count the items and the separators
gfldex ChoHag: it will not inject anything into the surrounding scope
masak flussence: but then it'd need a `%`, not `%%`
cygx masak: $<sep> == $<item>
webstrand What's the use of .precomp files? I'm trying to package panda for my distro, and when I give panda's bootstrap a prefix, it sticks a bunch of .precomp files in there. What should I do about them? I can't include them in the package because the names sometimes conflict with other modules. 20:48
masak perlpilot: yes, but that'd require me to catch all the separators, and I only really care about the trailing one
awwaiid ChoHag: it makes a new lexical scope, parses/compiles. unlike perl5 it does not catch exceptions.
lizmat awwaiid: good point :-) 20:49
I had completely forgotten about that
ChoHag Right.
flussence webstrand: you can safely rm -rf .precomp/, it usually happens because test files contain a "use lib" line
orbus perl6 basically compiles a module the first time it's run and stores the intermediate result right? 20:50
ChoHag So next step, Why does function-which-returns-an-object ~~ Type::Name (inside an EVAL because I'm debugging and Type::Name isn't loaded at that point) return false even though the object returned from the function does indeed have Type::Name mixed in to it?
leont ChoHag: EVAL is currently rather buggy. It doesn't work well in modules, see #126839
orbus I think python does something simmilar
flussence mono does the same thing too
ChoHag And if the smartmatch isn't, how can I force that specific test?
orbus been a while since I looked at python
webstrand flussence: Thanks. Is there an env-var I can set to generate them elsewhere?
leont ChoHag: probably because your function needs to know about your Type::Name 20:51
ChoHag Ah!
Because the function returns more than just the object.
flussence webstrand: not for .precomp specifically. I had a hack that moves them all to ~/.cache/perl6/ but people decided it wasn't enough of a problem to change it 20:52
autarch uh, how do I start perl6 under gdb? since my "perl6" is a perl6 wrapper that calls a shell wrapper that ... ?
leont perl6-m-gdb
hoelzro autarch: I believe rakudo ships perl6-gdb-m
autarch hoelzro: yes it does - that works 20:53
orbus I'm sure this has probably been discussed to death, but what was the thinking behind having a Match object coerce to a string with funny corner brackets around it?
like if $x is a Match object
and I do say $x
I get 「x」
but if I say $x.Str 20:54
I get x
flussence orbus: you asked for a human-readable string (by using say instead of put), so it calls .gist instead of .Str
leont That's because it's the .gist, not the .Str
hoelzro orbus: that's .Str vs .gist
orbus hrm
and .gist is supposed to be more a representation of the object as a whole?
hoelzro it's a friendlier representation 20:55
ChoHag Friendlier if you have a suitable font. 20:56
orbus heh
I'm just starting to explore the new regex engine
ChoHag Perl 6 likes to show me boxes.
orbus maybe it should be the poop emoji
RabidGravy autarch, btw the magic.h has a lot of const char * in the arguments, these should have explicitly-manage($str) called on them before passing them to the NC sub
20:56 geraud joined
flussence .u 「 20:56
autarch RabidGravy: ah, ok, maybe that's the problem
yoleaux U+FF62 HALFWIDTH LEFT CORNER BRACKET [Ps] (「)
flussence have cjk fonts, problem solved 20:57
orbus (everyone's favorite unicode character)
autarch nope, that's not it - though it may be another problem
RabidGravy: actually, do I have to call explicitly-manage? libmagic won't hold on to anything that gets passed in after the function returns 20:58
20:59 halto joined
RabidGravy dunno to be honest 20:59
autarch if moar frees the string after magic_file is called that's fine 21:00
[Coke] mojca: testing [email@hidden.address] 21:01
autarch hmm, without a moar compiled with -g I'm not sure using gdb is going to tell me anything 21:02
21:02 atweiden joined, wingfold_ joined 21:03 pierre-vigier joined
RabidGravy autarch, you can step through the library in libmagic functions if you have the debuginfos installed 21:04
Skarsnik autarch, you probably don't need explicity-manage yes
21:04 wingfold left, llfourn joined
[Coke] mojca: here's a slightly better description for NQP: 21:05
mojca great, thank you
lizmat masak: any idea why DateTime.now uses now() instead of time() as its source
mojca in advance
[Coke] gist.github.com/coke/c95e6d788eb00ba36f02
lizmat masak: as DateTime cannot represent leap seconds anyway... 21:06
21:06 virtualsue left, atweiden left, virtualsue joined
autarch RabidGravy: ah, I didn't know about that - I installed the file-dbg package and now I can see something useful 21:07
21:07 atweiden joined, pierre-vigier left
RabidGravy cool, I'm typically pretty useless with gdb tbh 21:07
[Coke] mojca: it seems to be trying to download stuff from github.
shouldn't we be forcing the tarballs we created on rakudo.org/ ? 21:08
mojca I don't know; personally I like fetching from GitHub; see what I did in rakudo for example
[Coke] the fake tarballs on github aren't going to have everything.... though I suppose the stuff they are missing doesn't strictly matter. 21:09
mojca: the tarball isn't the same as the one on the rakudo.org site, though.
so the checksums aren't going to match
mojca do only the checksums differ or also other stuff?
[Coke] did you make the checksums match the github version?
mojca yes
[Coke] there's stuff NOT in the github tarball.
21:09 llfourn left
mojca I will try to compare the two versions; I know that MoarVM doesn't work from GitHub 21:10
[Coke] that includes nqp/moar (which don't matter), spectests (probably don't matter)
21:10 HoloIRCUser5 joined, halto left 21:11 HoloIRCUser5 left
[Coke] seems like if we want checksums, it has to be one or the other. 21:11
atweiden m: subset Price of Rat where * >= 0; subset Quantity of Rat where * >= 0; class Basis { has Price $.price; has Quantity $.quantity }; my Basis @basis; push @basis, Basis.new(:price(12.57), :quantity(3.0)); push @basis, Basis.new(:price(1.19), :quantity(5.0)); my Price $value = [+] (.price * .quantity for @basis); say $value;
camelia rakudo-moar 64a61a: OUTPUT«WARNINGS for /tmp/uld2FmTvtp:␤Useless use of "*" in expression ".price * .quantity" in sink context (line 1)␤43.66␤»
mojca sure, one can only fetch the files from a single source
[Coke] ah, it is one or the other, and you picked github. *shrug* ok.
mojca (it can change in the process of course)
atweiden what's the idiomatic way of doing this?
21:12 woolfy left, wingfold joined
autarch remembers that error handling is a good thing 21:12
mojca if you strongly prefer the official source, I can switch to that
but for rakudo we would have to deal with a number of issues in separate patchfiles
[Coke] mojca: no worries. testing...
21:13 CIAvash left
mojca the advantage of github is that one can easily switch to a newer commit at any given time; in particular during testing (as perl6 is now) that might be handy 21:13
timotimo mst: how is the new release of CGI.pm with the fixed documentation coming along? is it out yet?
[Coke] mojca: what patchfiles? I don't see anything mentioned in the portfile...
masak atweiden: that looks like a spurious warning to me.
TimToady: ping ^
21:13 kivutar left
mst timotimo: people are still investigating. it looks like the exact code on his slides -isn't- the code in the examples. 21:14
mojca If you take 2015.12, some tests fail; in rakudo I used one of the latest commits which fixes those issues
if we would take it from 2015, we would need to manually extract the required patches
21:14 _mg_ joined, wingfold_ left
autarch doc.perl6.org/routine/%2F%2F 21:15
surprisingly, it's hard to link to '//'
atweiden masak: i get a similar warning with `my FatRat $actual_income_delta = [+] (.capital_gains - .capital_losses for @taxes);`
21:16 SwellJoe joined, _mg_ left
masak atweiden: I might have missed something recently, but that sure doesn't look wrong to me. 21:16
mojca [Coke]: if you are willing to come with a nice description for rakudo as well, that would be great 21:17
masak m: say [+] (2 + 2)
camelia rakudo-moar 64a61a: OUTPUT«4␤»
masak m: my @a = -1, 2, -3; say [+] (.abs + .abs for @a)
camelia rakudo-moar 64a61a: OUTPUT«WARNINGS for /tmp/uySpvnhOVb:␤Useless use of "+" in expression ".abs + .abs" in sink context (line 1)␤12␤»
autarch if I want to make my own exception class do I subclass X::AdHoc?
masak m: my @a = -1, 2, -3; say [+] SEQUENCE(.abs + .abs for @a)
camelia rakudo-moar 64a61a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/D09eF6nMQr␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/D09eF6nMQr:1␤------> 032, -3; say [+] SEQUENCE(.abs + .abs for 7⏏5@a)␤»
Skarsnik more sink context warning x)
masak autarch: no, just Exception
autarch: unless your own exception happens to be very ad hoc :P 21:18
autarch heh, no, not really
flussence I imagine those URLs would work better if they were spelled (url-encoded) “infix:<...>” instead of “routine/...”. It's completely impossible to link to a doc page for the range operator using the current method btw :)
21:18 pierre-vigier joined
[Coke] mojca: build looks fine on rakudo - working on desc. now 21:19
autarch and is there a naming standard for exceptions I should follow? 21:20
like "my class X" inside "unit class File::LibMagic"? is that sane or insane?
RabidGravy no, that's pretty much it 21:21
timotimo mst: if ( my $file = $cgi->param( 'filename' ) ) {
that one's much better than the one he had
RabidGravy so inside it will be X::Foo and will match that shortname but will be File::LibMagic::X::Foo so you don't have to worry 21:22
timotimo er
not much better*
because then $file is used inside < >
autarch RabidGravy: ok, that works well enough
21:22 dha left
autarch huzzah, it's working! 21:24
timotimo except if $cgi->uploadInfo would fatal-error if the $file doesn't point at a single uploaded file
autarch RabidGravy++ for fixing the segfault that got me stuck
RabidGravy autarch++ nice
_wiz_ what are the hashes in share/perl6/sources ?
autarch ultimately this is _way_ simpler than the Perl 5 version with XS
and a lot easier to follow too
Skarsnik Yes lol 21:25
lizmat missed what autarch is working on
autarch I really like having all the code in one file than having to constantly jump from .pm to .xs
21:25 pierre-v_ joined
autarch lizmat: File::LibMagic for Perl 6 21:25
[Coke] mojca: gist.github.com/coke/c95e6d788eb00ba36f02 has a slightly longer desc on rakudo - question - does rakudo need to depend on moarvm & nqp? or is just nqp sufficient?
21:25 kaare_ left
lizmat autarch++ 21:25
awwaiid What is the perl6 equivalent of :: namespace? I want to add a global sub but am already in a unit package (how to switch to MAIN I guess)
[Coke] autarch: we aim(ed) to please.
nine m: use Test:ver(* after v6.b) 21:26
camelia rakudo-moar 64a61a: OUTPUT«===SORRY!===␤Cannot invoke this object␤»
geekosaur GLOBAL:: I think?
Skarsnik Something cool will be someone to write a tool (with llvm) to parse C/C++ header and extract info to generate the binding x)
nine use Test:ver({$_ after v6.b})
m: use Test:ver({$_ after v6.b})
camelia ( no output )
21:26 yayster joined
[Coke] mojca: all looks good. Thank you SO MUCH for working on these! 21:26
_wiz_ nine: what are the hashes in share/perl6/sources ?
RabidGravy autarch, yeah that all in one file thing really does lead to a nicer experience, and probably better code to boot
yayster Hello there, everyone.
21:26 addison joined
mojca [Coke]: the question is whether rakudo links against some dylib or depends directly on moarvm; which it does, so I would include it 21:26
[Coke] yayster: hello. 21:27
21:27 lnrdo joined, domidumont joined
[Coke] mojca: ok, that's fair. Danke. 21:27
mojca even though theoretically it would work if we just used a dependency on nqp
nine _wiz_: the files are the source files of installed modules. The hashes contain the original name and the dist id
yayster I am encountering an error when installing perl 6 per the instructions on www.perl6.org/downloads/
[Coke] mojca: technically correct is the best kind of correct!
yayster: what's the error?
yayster there error that I get is gist.github.com/yayster/7b2f41db227cb96bc6d3
[Coke] yayster: what platform? 21:28
_wiz_ nine: is this supposed to be stable across platforms/ operating systems/ versions?
yayster raspberrypi
21:28 pierre-vigier left
_wiz_ (hint: doesn't look that way) 21:28
[Coke] that's not one of our core platforms, but I know someone had luck there recently; looks like a bug in the compiler, based on the error message.
you using an odd version of [g]cc? is there even a choice on the pi? 21:29
nine _wiz_: sounds like it would be a time safer if you just told me what you encountered
RabidGravy yayster, it's get a newer version of gcc
webstrand I've got File::Find installed to /usr/share/perl6/vendor/lib/File/Find.pm, but trying to `use File::Find` in any script fails. I'm manually installing the module, is there anything I might have missed?
yayster I do not believe that the version of gcc is in anyway odd.
[Coke] webstrand: how did you install it?
_wiz_ I'm packaging rakudo for pkgsrc.
[Coke] manually? You can't do that.
_wiz_ we have fixed PLISTs.
yayster just using apt_get 21:30
_wiz_ and the one for Darwin has different hashes than the one for NetBSD.
[Coke] unles you do everything panda/rakudo does when they install.
awwaiid m: unit package Foo; unit package GLOBAL; sub hiya { ... }
camelia rakudo-moar 64a61a: OUTPUT«===SORRY!===␤Cannot declare pseudo-package GLOBAL␤»
_wiz_ PLIST=list of installed files.
nine webstrand: you'd need to use perl6 -I /usr/share/perl6/vendor/lib to load modules from there
[Coke] listen to nine, he knows all about installing. :)
Skarsnik how the hell apt install p6 module?
mojca [Coke]: given that you participate in development, do you have any clue about the remaining test failure(s)? 21:31
[Coke] yayster: best bet is to find out what the other person that got it working on Pi used; if you check the logs (see the /title), you can probably find them.
yayster he is asking about gcc
RabidGravy yayster, er it appears that the moarvm tickles a subtle bug I did it fine with "gcc version 4.8.2 (Raspbian 4.8.2-21~rpi3rpi1)" the default version doesn't work
[Coke] mojca: I cut the release on a mac. there were no test failures.
21:31 lnrdo left
[Coke] we even removed some tests from Christmas to avoid failures! ;) 21:31
mojca you can add/uncomment "test.target test spectest" on rakudo
[Coke] Are you running the install and then trying to run tests from roast by hand somehow?
Skarsnik [Coke], could you write the tests for os X on t/04/17 ? 21:32
[Coke] Skarsnik: I don't know what t/04/17 means.
webstrand nine, [Coke]: It's already in my search path, dpaste.com/10JMJFQ is the error I get. I have to install the module manually, because I don't have any module installer such as Panda. I can't get panda until I've installed its dependencies
Skarsnik t/04-nativecall/17-libname.t
[Coke] mojca: running those tests will take ages.
Skarsnik in rakudo
[Coke] webstrand: listen to nine.
mojca [Coke]: sure, there were no failures in the standard tests, but there were some in spectest (one, to be precise; the other one is still a bit of a mystery)
[Coke] Skarsnik: probably not, nope.
mojca you can run just the failing test 21:33
autarch it seems like Test should have something that like "smartmatch( $got, $expect, ... )'
RabidGravy yayster, that version is a non-default option on raspian you just need yo apt-get install it and switch it to default
mojca I checked the rest
[Coke] mojca: what's the test that failed for you?
nine _wiz_: ah ok. I don't think I want to commit to fixed file names just yet.
mojca See trac.macports.org/ticket/50154
[Coke] also: if you're pulling from github... none of that will work
_wiz_ nine: so what is your recommendation for packagers?
[Coke] ... or rather, if it does, it's going to pull the tests from roast.. which is wrong
yayster RabidGravy: thank you for the input. I will continue to work on things.
[Coke] we bundled a specific set of tests in the release.
21:33 domidumont left
[Coke] you'd need to first do a (cd t/spec && git checkout 6.c) 21:34
and manually clone roast into t/spec first.
otherwise you're running a non-spec version of the spec tests.
21:34 domidumont joined, bpmedley left
bbkr what is the current best practice to define exceptions? for example for class Foo its exceptions should be in X::Foo:: namespace? 21:35
nine _wiz_: that's a tough question. Well as it is, the file names are sha hashes containing the repository identities, the original source file's path and the dist id (name, auth, api, version).
[Coke] the version from the 6.c branch works fine.
timotimo oh hey bbkr
_wiz_ nine: so does it depend on the path where I extract the source tree? 21:36
mojca one more question: what's better version numbering 2015.12 or 6.c?
RabidGravy bbkr, or Foo::X:... that way you can define them in you class
[Coke] 2015.12 is for the compiler.
6.c is for the language spec.
we're installing the former, so 2015.12
nine _wiz_: no, only the relative paths within the dist
mojca what's the expected future version for rakudo then? 21:37
Rotwang m: try { die "foo" }
camelia ( no output )
Skarsnik 2016.01 ?
Rotwang why is that uncaught exceptions are actually ignored in the try block?
cxreg there seems to be a fair bit of appetite for the jvm backend, is anyone currently working on completing whatever didn't make it to the christmas build for that backend?
_wiz_ nine: hm. so which other parameter causes the differences I see?
21:38 bpmedley_ joined
mojca ok, so rakudo will generally never be something like 6.22, but rather something like 2023.06? 21:38
nine _wiz_: I wonder, if we should actually use a different repository implementation for vendor provided packages. There are a couple of safeties that we probably don't need there.
cygx Rotwang: 'cause that'S what try does? you can add CATCH to any block
what try does is makes failures fatal and ignore exceptions by default
(IIRC)
21:39 miquelruiz_ joined
Rotwang cygx: ok, it was unexpected though 21:39
nine webstrand: panda does not have any dependencies. To be precise: it ships will all its required modules
mojca [Coke]: trac.macports.org/changeset/143947/ 21:40
yayster RabidGravy: I am going to upgrade to gcc-4.9 and try it again.
nine webstrand: you did _not_ use -I /usr/share/perl6/vendor/lib. That's something different than the standard repository.
cygx Rotwang: agreed - I only know what it does because I looked it up after using it wrongly
webstrand nine: dpaste.com/3NTKRGM
miquelruiz_ hi! I'm having an issue with "ufo": pastebin.com/szJLP33G 21:41
bbkr RabidGravy: indeed, Foo::Bar::X::SomeReason looks better than X::Foo::Bar::SomeReason (not obvious where class namespace ends and exception namespace begins)
21:41 domidumont left
Skarsnik nine, you should probably write a tibit for 'package maintainer' on how it's supposed work 21:41
miquelruiz_ whenever I run it crashes saying it can't find "%*CUSTOM_LIB" 21:42
[Coke] mojca: danke (and yes, rakudo versions will always be YYYY.MM)
cygx Rotwang: design.perl6.org/S04.html#line_1032
nine webstrand: -I doesn't seem to work with the REPL. perl6 -I/usr/share/perl6/vendor/lib -e 'use File::Find'
webstrand nine: The trouble is, with panda's bootstrap it doesn't play nice with fakeroot which I have to use to package panda. As far as I can tell, I can manually copy the bin and lib, providing I install the dependencies.
nine webstrand: but that's moot anyway. You should totally be able to use panda.
Rotwang cygx: Thank you.
Skarsnik Does ufo work?
nine webstrand: that will still not install panda properly 21:43
Skarsnik I am pretty sre will all the change it must fail x)
mojca [Coke]: that would be "hvala"
stmuk [coke]: what happens if an essential security is needed for say 2015.01 before the end of that month?
miquelruiz_ Skarsnik: lol, all the module docs point to it
skids I had heard that ufo was old, but that was a long time ago so my information may be old :-)
stmuk ^ security fix I mean
RabidGravy yayster, go for it but the 4.8.2 is known to work
nine webstrand: what does "doesn't play nice with fakeroot" mean?
21:44 dfarrell left
nine _wiz_: which systems are you comparing? 21:44
[Coke] stmuk: we've had point releases before.
Skarsnik miquelruiz_, use panda
[Coke] so YYYY.MM with an optional .x - but never 6.c
stmuk ok
miquelruiz_ Skarsnik: I tried, but I'm trying to install a module from the repo (Net::Packet is broken and doesn't pass the tests) 21:45
[Coke] hvala, then! (I use danke as a generic thanks reardless, despite the english)
stmuk and there is no way of tracking the last release automatically?
RabidGravy bbkr, yeah people tend to do "class Foo { class X::Whatever is Exception { ... } }" if they're only thrown from in there, so you have the notational convenience inside the class and less chance of a clash outside
21:45 Arrowhead left
Skarsnik miquelruiz_, look the date of the last commit, if it's like 6 month+ it's very likely that it fail. if not, fill an issue x) 21:46
[Coke] stmuk: automtaically... from where?
stmuk using a git branch for example
miquelruiz_ Skarsnik: there's a pull request with a patch, I just want to apply that patch and install the patched version 21:47
Skarsnik panda install .
miquelruiz_ Skarsnik: any way to install a custom version without ufo?
Skarsnik should work
webstrand nine: When run as "root", panda tries to open /usr/share/perl6/site/repo.lock which isn't writable. I'm trying to install using the command `./bootstrap.pl --prefix="/pkg/panda/"`
miquelruiz_ Skarsnik: awesome, I'll try
Skarsnik: Thx!!
cygx stmuk: there's github.com/rakudo/rakudo/blob/nom/VERSION and corresponding tags
21:47 Arrowhead joined
stmuk cygx: ah thanks 21:48
Skarsnik I had issue with --prefix with panda x)
21:48 ggoebel7 joined
Skarsnik it delete everything in prefix that was not panda x) 21:49
dalek kudo/query_repos: 7f789b2 | (Stefan Seifert)++ | src/core/CompUnit/Repository (3 files):
CompUnit::Repository::resolve

New method to ask the repository chain if a module matching the given DependencySpecification is available. This could for example be used by panda to avoid trying to install an already installed module.
Not yet 100 % sure about the method's name and return value.
stmuk maybe there could be a new rakudobrew option like 'build-last-release' which uses that file
I can't think of a good option name :/
nine webstrand: why doesn't it have write permission there? 21:50
webstrand: the RAKUDO_PREFIX environment variable may help there 21:51
21:51 nexysno_ left
masak m: say (Inf..Inf).elems 21:51
camelia rakudo-moar 64a61a: OUTPUT«Inf␤»
stmuk maybe 'build-release'
masak IMHO this should be 1 :) 21:52
webstrand nine: Because bootstrap.pl is being run inside of fakeroot. Fakeroot's required by my distro's packaging utility (makepkg from Archlinux).
21:52 itaipu left
awwaiid masak: maybe it should be Inf-Int to indicate it is infinite enumerable to the count of Int, as opposed to say Int-Real 21:53
RabidGravy didn't someone get arch linux fixed up yrsterday?
webstrand nine: Cursory search didn't turn up any results for RAKUDO_PREFIX, what does it do?
RabidGravy it was added recently for cases similar to this 21:54
masak awwaiid: that discussion has a long pedigree. it's currently at a kind of dead point where TimToady has said "it should work with Inf fitting inside both Int and Num", but there's no implementation in sight, and Architect jnthn has said he won't go near the thing.
autarch RabidGravy: hmm, my code is now segfaulting _some_ of the time 21:55
nine webstrand: it changes where rakudo expects its standard module repositories to be: RAKUDO_PREFIX=/fake/root perl6 -e 'say $*REPO.next-repo'
inst#/fake/root/site
awwaiid nine: wow. here and I thought I was just trollin
nine: I know of no particular practical use differentiating between countably infinite and uncountably infinite
masak awwaiid: I for one would love to see it work "intuitively" with Inf doing The Right Thing in both an Int context and a Num context -- but every time I think about it, it seems Weird and Hard to implement. :/
awwaiid er
masak: ^^. sorry nine
hahainternet there was some mention on HN of tab completion using rlwrap, anyone got any hints to that? 21:56
nine I'm off to bed now. Good night!
awwaiid hahainternet: "rlwrap perl6"
oh tab completion. hmm.
masak awwaiid: it's not even about the countable/uncountable distinction here, since Num is a (countable) approximation of the reals ;)
RabidGravy autarch, I hate it when that happens it's worse than all the time
awwaiid masak: ohh... deep.
21:56 mcmillhj_ left
awwaiid hahainternet: well... if you 'panda install linenoise', the plain 'perl6' repl has sme tab completion I've heard 21:57
hahainternet awwaiid: nah linenoise is not particularly great as far as things go
hoelzro Linenoise is the only way to get tab completions atm
masak .tell ZoffixW re irclog.perlgeek.de/perl6/2015-12-22#i_11758406 -- the IEEE 754 standard disagrees. 21:58
yoleaux masak: I'll pass your message to ZoffixW.
hoelzro I added support for Readline as the line editor last night, but it doesn't have tab completions yet
awwaiid hahainternet: other tab completion projects are in progress :)
hahainternet hoelzro: interesting, it didn't work correctly for me last i tried
hahainternet goes away to pull and rebuild
hoelzro hahainternet: when did you try last?
RabidGravy autarch, you have a DESTROY? If sometimes blame GC ;-)
hoelzro it was later last night that I added it
webstrand nine: Is that a newer feature? `RAKUDO_PREFIX=/fake/root perl6 -e 'say $*REPO.next-repo'` results in `inst#/usr/share/perl6/site` for me. I'm using rakudo tagged 2015.12
hahainternet hoelzro: a good question, some time ago!
still, rlwrap is preferable, but thanks for your work hoelzro!
RabidGravy webstrand, last couple of days 21:59
autarch RabidGravy: actually, this is happening much earlier - I think it's because I need to explicitly pass a string or NULL to magic_load - not sure how to pass a NULL
hoelzro hahainternet: rlwrap is preferable? may I ask why?
RabidGravy not in the 2015.12 tag I don;t think
hahainternet hoelzro: not to readline, but arrow keys, multibyte characters etc
autarch looks like passing Nil explicitly does the trick
hoelzro ah, rlwrap is preferable to Linenoise you mean
hahainternet neither of which seemed to work with linenoise on debian for me
RabidGravy autarch Str type object stands for null
hoelzro arrow keys *should* work
hahainternet hoelzro: or even 'the repl with linenoise' as i don't know where to lay blame 22:00
and i don't really want to complain
you guys have your hands full!
hoelzro haha, not me =)
I would be happy to take time to improve the REPL experience
that way other smarter people don't have to worry about it!
autarch RabidGravy: (Str) and Nil both did the trick
Hotkeys using certain types in the repl makes it very upset when you make an error i.imgur.com/CjraUqO.png 22:01
22:01 lnrdo joined
Skarsnik fun 22:02
Hotkeys I'd attempt to try and fix this but I've no idea where to look
hoelzro eesh
that looks bad
22:03 dindinx joined, skids left
Hotkeys i.imgur.com/xBw0Cca.png 22:04
22:06 llfourn joined
Hotkeys oh 22:06
so it seems to be this rt.perl.org/Public/Bug/Display.html?id=123187
22:06 s_kilk joined
masak Hotkeys: that happens here as well. :/ 22:08
'night, #perl6
22:09 pmurias left
hoelzro night masak 22:09
RabidGravy toodlepip masak
Hotkeys int64 breaks differently but less critically I suppose i.imgur.com/FEyPn2m.png
22:10 pierre-v_ left, pierre-vigier joined
Hotkeys 'int' breaks the same way as int64 22:11
int32 breaks the same as int16
lizmat also toodlepips 22:12
22:12 llfourn left
stmuk is raw.githubusercontent.com/rakudo/r...om/VERSION aways going to be the last release? 22:16
autarch how can I pass a Buf[uint8] into a C function?
Skarsnik You can't
RabidGravy autarch, simple answer NativeHelpers::Array or do what it does 22:17
autarch ah, I knew I'd read about that recently
22:17 jevin_ joined, jevin left 22:18 sumdumgoi joined 22:19 brrt left, ara joined, labster joined
RabidGravy it's basically my $carray = CArray[uint8].new; $carray[$_] = $buf[$_] for ^$buf.elems; 22:19
22:19 ara is now known as Guest32233
Guest32233 Heya. I'm trying to build Perl 6 on Windows via rakudobrew and I'm running into a failure to run Configure.pl. This is under cygwin. Are there known issues here? 22:20
22:20 Guest32233 is now known as araadkins, _nadim left, _nadim joined
Skarsnik rakudo does not build on cygwin 22:21
sumdumgoi this program ( pastebin.com/M0paG3ty ) dies with "No lexical found with name '$i' in block <unit> at ./dummy.p6 line 1" on Rakudo version 2015.12-36-g64a61a3 22:22
(it's a simple C-style loop :P )
Skarsnik well libuv does not work on cygwin
araadkins @skarsnik:Thanks. What's the recommendation for building on windows?
Skarsnik mingw or wait for the next rakudo star release
araadkins for simplicity's sake I think I'll stick to the rakudo star releas 22:23
for simplicity's sake I think I'll stick to the rakudo star release
thanks
22:23 webstrand left
orbus here's a question: say I have a function that returns a list and I want to capture a slice of the output - something like @x = [some_function][2.. LAST_ELEMENT-1] 22:23
how would I express LAST_ELEMENT?
or can I without storing the array first?
Skarsnik sumdumgoi, that... weird 22:24
m: loop (my int $i = 0; $i < 10; ++$i) { say $i }
camelia rakudo-moar 64a61a: OUTPUT«0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤»
cxreg Skarsnik: does node.js also not work on cygwin? 22:25
Skarsnik m: sub MAIN { loop (my int $i = 0; $i < 10; ++$i) { say $i } }
camelia rakudo-moar 64a61a: OUTPUT«No lexical found with name '$i'␤ in block <unit> at /tmp/0WpFhd96yW line 1␤␤»
Skarsnik No idea
sumdumgoi aha! even camelia is broken :)
cxreg Skarsnik: looks like it doesn't
gfldex m: sub f(){ 1,2,3,4 }; dd f[1,*-1-1];
camelia rakudo-moar 64a61a: OUTPUT«(2, 3)␤»
gfldex orbus: ^^^
Skarsnik m: sub plop { loop (my int $i = 0; $i < 10; ++$i) { say $i } }; plop();
camelia rakudo-moar 64a61a: OUTPUT«No lexical found with name '$i'␤ in block <unit> at /tmp/OhnXXnqsSf line 1␤␤»
cxreg Skarsnik: the reason I ask is that they're the stewards of libuv
orbus gfldex: ooooh
Skarsnik m: sub plop { loop (my $i = 0; $i < 10; ++$i) { say $i } }; plop(); 22:26
camelia rakudo-moar 64a61a: OUTPUT«Cannot call infix:«<»(Any, Int); none of these signatures match:␤ ($?)␤ (\a, \b)␤ (Real \a, Real \b)␤ (Int:D \a, Int:D \b)␤ (int $a, int $b)␤ (Num:D \a, Num:D \b --> Bool)␤ (num $a, num $b --> Bool)␤ (Rational:D \a…»
orbus hmmm
Skarsnik Hey
I reproduce the bug I have in Gumbo lol
sumdumgoi Yeah, that happens when I leave out the int as well. 22:27
RabidGravy that does look like a genuine little bugette
sumdumgoi any Rakudo devs in channel?
we have to tell the king! ;)
orbus m: say [1,2,3,4,5][1..*-2]
camelia rakudo-moar 64a61a: OUTPUT«(2 3 4)␤»
22:28 nash_ joined
orbus neat 22:28
so what does * mean? seems to be the number of elements, not the number of the last element
which is good enough
gfldex orbus: see doc.perl6.org/language/subscripts
22:28 jevin_ left
orbus thank you sir 22:28
22:29 jevin joined
gfldex m: dd (*-1).WHAT 22:29
camelia rakudo-moar 64a61a: OUTPUT«Cannot look up attributes in a type object␤ in block <unit> at /tmp/nNErrSIQ2g line 1␤␤»
gfldex m: dd (*-1).^name
camelia rakudo-moar 64a61a: OUTPUT«WhateverCode.new␤»
cygx nqp: I-do-not-exist := 42
22:29 camelia left
Skarsnik sumdumgoi, add your issue to rt.perl.org/Ticket/Display.html?id=127022 it's probably related 22:29
gfldex camelia knows WHAT it is :)
orbus some kind of sorcery 22:30
I'm quickly going to start mixing up p5 and p6 stuff
they're just similar enough to be dangerous
cygx did I... just kill camelia :'(
autarch here's a confusing error - gist.github.com/autarch/6b6fea440e56a805d062
the way I read this perl6 is telling me that two identical signatures don't match 22:31
22:31 camelia joined
Skarsnik nqp kill camelia yes 22:31
something about trying to load parrot x)
sumdumgoi Skarsnik, it craps out when I try to add a reply
El_Che lizmat: just saw your LWP talk. Very nice
camelia nqp-parrot: OUTPUT«Can't exec "./rakudo-inst/bin/nqp-p": No such file or directory at lib/EvalbotExecuter.pm line 206.␤exec (./rakudo-inst/bin/nqp-p /tmp/tmpfile) failed: No such file or directory␤Server error occurred! Closing Link: ns1.niner.name (Quit: camelia)␤Lost connect…» 22:32
( no output )
..nqp-jvm: OUTPUT«(signal ABRT)#␤# There is insufficient memory for the Java Runtime Environment to continue.␤# pthread_getattr_np␤# An error report file with more information is saved as:␤# /tmp/jvm-9711/hs_error.log␤»
22:32 ChanServ sets mode: +v camelia
cygx nqp-m: I-do-not-exist := 42; say("ok?!") 22:33
camelia nqp-moarvm: OUTPUT«ok?!␤»
perigrin autarch: return part of the signature maybe?
RabidGravy autarch, I think that is a known oopsie in something, relax the signature to an unqualified CArray and you'll be good
autarch RabidGravy: nope, that didn't help 22:34
dj_goku so I am getting an error when installing panda with rakudobrew
RabidGravy I might have misread what it is saying then
sumdumgoi hmm.... "$ rakudobrew nuke moar " ---> "Sorry, I have no idea what 'moar' is\nUpdating shims" 22:35
Skarsnik m: sub plop { loop (my int $i = 0; $i < 10; ++$i) { say $i }; say "hello" }; plop();
camelia rakudo-moar 64a61a: OUTPUT«0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤hello␤»
Skarsnik make loop return a value screw this 22:36
m: sub plop { loop (my int $i = 0; $i < 10; ++$i) { say $i };; }; plop();
camelia rakudo-moar 64a61a: OUTPUT«No lexical found with name '$i'␤ in block <unit> at /tmp/m_5PIgmB0g line 1␤␤»
RabidGravy Skarsnik, oh is that it
hahaha
22:36 jevin left
Skarsnik m: sub plop { loop (my int $i = 0; $i < 10; ++$i) { say $i }; return }; plop(); 22:36
camelia rakudo-moar 64a61a: OUTPUT«0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤»
Skarsnik m: sub plop { loop (my int $i = 0; $i < 10; ++$i) { say $i }; 0}; plop(); 22:37
camelia rakudo-moar 64a61a: OUTPUT«0␤1␤2␤3␤4␤5␤6␤7␤8␤9␤»
22:37 jevin joined
Skarsnik Yes because I found it was TimToady commit that add loop returning stuff that make this appear in my code 22:38
gfldex m: sub plop { gather loop (my int $i = 0; $i < 10; ++$i) { take $i } }; say plop();
camelia rakudo-moar 64a61a: OUTPUT«(0 1 2 3 4 5 6 7 8 9)␤»
Skarsnik I least I have an idea how to fix it
El_Che ¤
Skarsnik But I prefer to be fixed in rakudo x)
El_Che sorry
22:38 lnrdo left
Skarsnik I am surprised a test does do this in spec x) 22:40
RabidGravy it's the manifestation is weird 22:43
oh I see, it tries to return the $i from the outer scope but can't 22:44
22:44 s_kilk left
sumdumgoi so the lexical environment in the loop's block isn't being set up properly? 22:45
Skarsnik It's a bug
not a bug in your code
RabidGravy no, that's fine. It's trying to return the value of the loop from the sub, but it can't
22:46 dotness left
RabidGravy putting anything that has a value after the loop makes it go away 22:46
Skarsnik mine is even worst
22:46 nash_ left
Skarsnik it try to return the loop that is at the end of a when block inside a given 22:46
if I add 0; after the loop it work
sumdumgoi learns about gather/take :D 22:49
22:49 TEttinger joined
Skarsnik m: sub foo($a) {given $a { when List {loop (my $i = 0; $i < $a.elems; $i++) {say $a[$i]} } } }; foo((1, 2, 3)) 22:49
camelia rakudo-moar 64a61a: OUTPUT«Cannot call infix:«<»(Any, Int); none of these signatures match:␤ ($?)␤ (\a, \b)␤ (Real \a, Real \b)␤ (Int:D \a, Int:D \b)␤ (int $a, int $b)␤ (Num:D \a, Num:D \b --> Bool)␤ (num $a, num $b --> Bool)␤ (Rational:D \a…»
Skarsnik m: sub foo($a) {given $a { when List {loop (my $i = 0; $i < $a.elems; $i++) {say $a[$i]} 0;} } }; foo((1, 2, 3))
camelia rakudo-moar 64a61a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/1ESyazl3yh␤Strange text after block (missing semicolon or comma?)␤at /tmp/1ESyazl3yh:1␤------> 3i = 0; $i < $a.elems; $i++) {say $a[$i]}7⏏5 0;} } }; foo((1, 2, 3))␤»
Skarsnik m: sub foo($a) {given $a { when List {loop (my $i = 0; $i < $a.elems; $i++) {say $a[$i]} ;0} } }; foo((1, 2, 3)) 22:50
camelia rakudo-moar 64a61a: OUTPUT«1␤2␤3␤»
Skarsnik that... bad lol
RabidGravy I actually remember the conversation about the bare loop case and it's "value" only a short while ago
Skarsnik and I have a good reason for using loop => NativeCall 22:51
22:53 jeturcotte joined
jeturcotte ahoyhoy 22:53
22:53 hankache joined
autarch RabidGravy: any more thoughts on that signature error - I think that's the last thing I need to resolve in order to have a working library (he says optimistically) 22:54
RabidGravy autarch are you sure changing it to "magic_buffer(Cookie, CArray, int32)" didn't help ? 22:56
hankache Windows users what will work "panda install Linenoise" or "panda install Readline" ? Since Linenoise C files are distributed with the package it should work with Windows. Am I missing something?
hoelzro hankache: Linenoise should work
I just tested it a week or so ago 22:57
22:57 Arrowhead left
jeturcotte quick io::socket::async followup question... do I have access to any details about the client that has made a connection to the server? 22:57
autarch RabidGravy: yep
hoelzro Readline I haven't tested
22:57 Arrowhead joined
hoelzro (on Windows) 22:57
or any non-Linux OS, for that matter
autarch also, the whole in32 vs int thing was a red herring - making everything a plain int seems to work fine
hankache thanks hoelzro 22:58
Skarsnik That not good
I don't have issue with int32 on gumbo
autarch and I can't really make _everything_ an int32 anyway as it causes that bizarre bytecode error
Skarsnik did you check the headers?
don't trust the doc sometime
jeturcotte I have had, RabidGroovy, since had some luck with adding a tap, btw... I can send global messages back out to every connected client very nicely... i'm just trying to cobble together a means to single one out for a particular message 22:59
22:59 itaipu joined
jeturcotte grammar notwithstanding 22:59
23:02 zed00 joined
timotimo the "Fnord Jahresrückblick" is always a highlight of congress, and you can get it translated to english if you're interested 23:03
streaming.media.ccc.de/ on Hall 1
Skarsnik stop watching ccc and fix stuff! x)
timotimo starts at 00:15 23:04
huh? there's something to fix?
i wasn't aware
RabidGravy jeturcotte, not sure that you can as it stands, though yes that does seem a little strange omission
jeturcotte gotcha; i might be able to come up with another method int he meantime... the goal's really just to be able to tell one from another. Seemed like that would have made it easier 23:05
RabidGravy a bit late here now otherwise I'd poke around a bit harder
jeturcotte not to worry. And yeah, I'm about to deflate myself.
deflate comma myself 23:06
jdv79 you're inflated?
Skarsnik timotimo, irclog.perlgeek.de/perl6/2015-12-28#i_11793685 x)
jeturcotte a bit
mojca nine, [Coke]: I'm experiencing another permission issue gist.github.com/mojca/b2243593bc8a1f93d9ce 23:07
timotimo Skarsnik: huh, what causes this message to appear?
jeturcotte right; sleep... enjoy yourselveses
23:07 jeturcotte left
timotimo potentially $i contains something terrible 23:07
Skarsnik no
add ;0 after the loop
and it's fine
timotimo oh, so is this the code that turns a loop into something that can return values? 23:08
Skarsnik because it try to return the loop
mojca I find it weird that perl6 stops working just because I run a script with "--help" in a folder without write permissions
cygx autarch: using P6 int for C int will break on any platform where sizeof(int) != sizeof(long)
(eg win64)
autarch cygx: ah, interesting
23:08 llfourn joined
autarch anyway, I still need to figure out gist.github.com/autarch/6b6fea440e56a805d062 23:09
RabidGravy autarch, you in a position to push what you have, I'll take a look before the Belgo Russian Imperial Stout kills me
autarch RabidGravy: will do
Skarsnik timotimo, my bug in gumbo is vicious because the loop is at the end of a when statement in a given and the method on do the given
autarch RabidGravy: github.com/autarch/perl6-File-LibMagic/tree/wip
Skarsnik *only 23:10
autarch you can see the array just by running 'perl6 t/basic.t'
23:11 Begi joined
yayster this compile is taking a long, long time. ( on raspberrypi ) measured in hours. 23:11
timotimo mojca: is that because of precompilation or something?
yayster: yeah, mainly because it swaps a lot of memory in and out all the time
mojca what is precompilation?
timotimo yayster: our GC isn't optimized to handle low-memory situations well
mojca: if the script you're running loads a module, rakudo will compile it to a .moar file and store it in a precompilation cache 23:12
similar to the way .py turns into .pyc
yayster timotimo: it's cool. :-) I'm just having fun, sipping on some whiskey.
mojca panda's bootstrap starts with "use v6; use lib 'ext/File__Find/lib/'; ..."
if that wants to write a file to current directory ... 23:13
23:13 AlexDaniel joined
Skarsnik because of use lib I think 23:13
23:13 captain-adequate joined
timotimo ah, right, use lib makes precompilation "different" 23:14
23:14 llfourn left
timotimo though i don't know much about the details 23:14
i actually thought we just turn off trying to precompile when we are unable to write to precompilation folders
mojca also, bootstrapping panda ends up with 23:15
==> Please make sure that inst#/opt/local/var/macports/build/_weird_temporary_path_to_perl_lang_panda/panda/work/.home/.perl6/2015.12/bin is in your PATH
Skarsnik timotimo, I found this loop error when someone pasted pastebin.com/M0paG3ty and this does not work too (but not the same error)
mojca which is completely useless, but that's a completely different issue
Skarsnik lol 23:16
23:16 skyl4rk left
Skarsnik I definitly have that in my path x) 23:16
23:16 Begi2 joined
Hotkeys is there a way I can output a function's full definition 23:17
via reflection of some sort or something
23:17 rfinner left 23:18 Begi left, araadkins left
stmuk_ bugzilla.mozilla.org/show_bug.cgi?id=1230932 23:18
" The successful exploitation of the vulnerability allows an attacker to successfully exploit an SQL Injection flaw assuming Taint Mode is disabled at the vulnerable script." 23:19
Skarsnik hobbs, &foo.^signature
Hotkeys ><
stmuk_ ie. the script has to be modified for his attack to work .. it's a bug .. but not an exploit
23:21 vendethiel joined
perigrin stmuk_: to be fair mozilla disabled taint on _their_ installations I believe. 23:21
stmuk_ well that's misinstalled software 23:22
perigrin stmuk_: sure, but I believe he poitned to Mozilla installing it that way 23:23
Mind you I believe he's an idiot for trying to take a bug/flaw/possible exploit in a single application and tarring an entire language (or two!) with it.
23:26 yeahnoob joined
AlexDaniel oh, is there any new video from this guy? 23:27
yoleaux 18:46Z <tadzik> AlexDaniel: merged now with the required fix, sorry to keep you waiting
RabidGravy autarch, well that has me well and truly stumped, I have working code that does exactly the same thing which works (and I am just testing now to be sure)
autarch heh 23:28
well, I guess it'll stay as a work in progress for now
23:28 Begi2 left, andrewalker left
AlexDaniel .tell tadzik yeah, great! Travis status is a bit weird, why does it attempt to run it on 2015.09? Anyway, that means that github.com/tadzik/Bailador/issues/43 could be closed after the tests are added 23:29
yoleaux AlexDaniel: I'll pass your message to tadzik.
Hotkeys can I cache anonymous functions?
vendethiel m: my anon sub is cached { say 1; }
camelia rakudo-moar 64a61a: OUTPUT«5===SORRY!5===␤Type 'anon' is not declared␤at /tmp/I4HKnMWI6V:1␤------> 3my anon7⏏5 sub is cached { say 1; }␤Malformed my␤at /tmp/I4HKnMWI6V:1␤------> 3my7⏏5 anon sub is cached { say 1; }␤␤»
Hotkeys eg my $x = { ... } 23:30
23:30 cygx left
RabidGravy yeah, autarch just re-tested Audio::Libshout and it does almost exactly the same thing and it works (all my Audio:: modules are flinging big CArrays around) 23:32
23:32 hankache left 23:33 vendethiel left, vendethiel joined 23:35 Arrowhead left 23:36 sumdumgoi left
RabidGravy autarch, oh wait no I've got it 23:36
autarch I'm all digital ears 23:37
23:37 BenGoldberg joined
RabidGravy didn't even notice, take the multi off the sub magic_buffer and it's all good 23:37
23:39 pdcawley joined
RabidGravy dunno what's going on under the hood that causes it to behave like it does (maybe an infelicity) but that so works 23:39
ok 1 - standard magic file
1..1
autarch duh, I should've noticed that 23:41
23:41 rburkholder joined
autarch I can even leave the native sub as CArray[uint8] and it works 23:42
RabidGravy there may be something not quite right in multi-dispatch for native subs
23:43 pdcawley left
Skarsnik probably a bug with multi and { * } 23:43
maybe a proto could fix it
or the { * } is already a proto of some kind? x) 23:44
RabidGravy dunno, the native trait over-writes the CALL-ME of the sub with it's own anyway 23:45
ah, that's probably why it doesn't work
23:45 firstdayonthejob left
RabidGravy may have a play in the morning 23:45
it over-rides the proto and not the candidates 23:46
so it is possible that having a proto might fix multi native subs 23:47
23:48 kid51 joined
Skarsnik Good night #perl6 23:48
RabidGravy toodlepip Skarsnik
23:48 Skarsnik left 23:52 hankache joined
Hotkeys is there a way to have a hashmap where values only take the value of another value in the map when they're used? 23:53
eg %foo<a> = %foo<b> #stuff; %foo<b> = #stuff; %foo<a>.say #now evaluate %foo<b> to get %foo<a> 23:54
er never mind I don't need to do that 23:55
colomon Hey, CompUnit::Repository::Installable is where the broken code I’ve been looking at comes from.
23:56 skids joined
RabidGravy right, I'm outta here 23:56