»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend! | feather will shut down permanently on 2015-03-31
Set by jnthn on 28 February 2015.
00:00 bowtie_ joined 00:07 bowtie_ left 00:13 bowtie_ joined 00:23 bowtie_ left 00:24 laouji joined 00:26 jepeway joined 00:28 bowtie_ joined
jepeway hm...anybody about? got a likely think-o I could use some help with. 00:30
TimToady nope, nobody here
jepeway heh. "us chickens," eh? 00:31
timotimo i'm still here
jepeway coolio. 00:32
so, i'm trying to create a role that specifies a/some multi methods.
00:32 bowtie_ left
jepeway when i do that role in a class and call one of those methods, I get a "ambiguous method call" error. 00:33
so...
m: role A { multi method a(Int $i) {...}; multi method a(Str $s) {...}; }; class B does A { multi method a(Int $i){0xa}; multi method a(Str $s) {"a"}; } ; B.new.a(0).say 00:34
camelia rakudo-moar a94d68: OUTPUT«Ambiguous call to 'a'; these signatures all match:␤:(B $: Int $i, *%_)␤:(B $: Int $i, *%_)␤ in block <unit> at /tmp/bibrhPJqwr:1␤␤»
jepeway what do I miss, here?
timotimo huh, interesting 00:35
well, you could make it work by providing a proto method a inside B, perhaps
TimToady looks kinda like a bug to me
timotimo agreed
TimToady a ... shouldn't be counted as a real candidate
jepeway ah. 00:36
timotimo right, we should already be detecting that
jepeway so, proto method would be a workaround?
s/would/might/
TimToady mebbe
timotimo hopefully it won't give you a "you should have provided these two multi methods!" thing 00:37
TimToady I'm not sure the ... stub really works to require multi candidates
timotimo m: role A { multi method a(Int $i) {...}; multi method a(Str $s) {...}; }; class B does A { multi
camelia rakudo-moar a94d68: OUTPUT«5===SORRY!5===␤Whitespace required after keyword 'multi'␤at /tmp/VswDEPkWIy:1␤------> 3tr $s) {...}; }; class B does A { multi7⏏5<EOL>␤Missing block␤at /tmp/VswDEPkWIy:1␤------> 3tr $s) {...}; }; class B does A { multi7⏏5<EOL>…»
timotimo oops
TimToady it's mostly been used at an only/proto granularity till now
timotimo m: role A { multi method a(Int $i) {...}; multi method a(Str $s) {...}; }; class B does A { proto method a(|) { * }; multi method a(Int $i){0xa}; multi method a(Str $s) {"a"}; } ; B.new.a(0).say
camelia rakudo-moar a94d68: OUTPUT«Ambiguous call to 'a'; these signatures all match:␤:(B $: Int $i, *%_)␤:(B $: Int $i, *%_)␤ in block <unit> at /tmp/3YYp8pIGwG:1␤␤»
timotimo huh.
the multis from the role are at the same "level"
TimToady they aren't being overridden the way an only or proto method would be 00:38
00:38 bowtie_ joined 00:39 telex left, laouji left
timotimo maybe an "only proto" would help :P 00:39
00:39 laouji joined
TimToady m: role A { proto method a(|) { * }; multi method a(Int $i) {...}; multi method a(Str $s) {...}; }; class B does A { multi method a(Int $i){0xa}; multi method a(Str $s) {"a"}; } ; B.new.a(0).say 00:40
camelia rakudo-moar a94d68: OUTPUT«Ambiguous call to 'a'; these signatures all match:␤:(B $: Int $i, *%_)␤:(B $: Int $i, *%_)␤ in block <unit> at /tmp/eV7FzX4tMQ:1␤␤»
TimToady protos are already only
00:40 telex joined
TimToady well, for now, don't stub multis in a role 00:40
timotimo well, well, well. this begs for some roast tests
00:40 LLamaRider left
jepeway hokay. 00:41
TimToady but it seems kinda reasonable to want to do that
jepeway does that mean there's no way to say "if you do this role, you gotta implement this multi method"? 00:42
TimToady unless there's some deep jnthn-sized reason to not want to do that...
not currently
jepeway or do I just drop the stub ... ?
TimToady that will still be ambiguous, and wrong as well :)
00:42 bowtie_ left
TimToady at the moment, all you can do is write a backstop method there that checks the type against a list 00:43
00:44 laouji left
TimToady m: role A { multi method a(::T $i) { die "Oops" if T ~~ Int|Str}; }; class B does A { multi method a(Int $i){0xa}; multi method a(Str $s) {"a"}; } ; B.new.a(0).say 00:45
camelia rakudo-moar a94d68: OUTPUT«10␤»
TimToady m: role A { multi method a(::T $i) { die "Oops" if T ~~ Int|Str}; }; class B does A { multi method a(Str $s) {"a"}; } ; B.new.a(0).say
camelia rakudo-moar a94d68: OUTPUT«Oops␤ in method a at /tmp/KGNLFSDhXK:1␤ in block <unit> at /tmp/KGNLFSDhXK:1␤␤»
TimToady m: role A { multi method a(::T $i where Int|Str) { die "Oops" }; }; class B does A { multi method a(Str $s) {"a"}; } ; B.new.a(0).say 00:46
camelia rakudo-moar a94d68: OUTPUT«Oops␤ in method a at /tmp/NMLnwxjpPV:1␤ in block <unit> at /tmp/NMLnwxjpPV:1␤␤»
TimToady equivalently
00:47 alini joined
TimToady but that won't help you at COMPOSE time 00:47
m: role A { multi method a(::T $i where Int|Str) {...}; }; class B does A { multi method a(Str $s) {"a"}; } ; B.new.a(0).say
camelia rakudo-moar a94d68: OUTPUT«Stub code executed␤ in block <unit> at /tmp/vFSlanz6je:1␤␤»
00:49 bowtie joined, bowtie is now known as Guest56933, laouji joined
jepeway gets the backstop method after a hard stare 00:52
should I submit a bug report? 00:53
and thanks, tt^2 :)
00:53 Guest56933 left
jepeway err.../[Tt][Tt] ** 2/? 00:55
00:58 bowtie_ joined
jepeway well, gtg. hope to be around a bit more. 01:00
ciao.
01:00 jepeway left
ugexe is there some way to augment the class composing the role somehow to include the proto whatever() { ... } ? 01:02
01:03 bowtie_ left 01:07 Ben_Goldberg joined 01:09 yeahnoob joined, bowtie_ joined 01:20 bowtie_ left 01:24 grettis left 01:26 bowtie_ joined 01:48 cognominal left 01:54 aborazmeh joined, aborazmeh left, aborazmeh joined 01:56 alini left 01:58 egrep left 01:59 egrep joined 02:01 chenryn joined 02:03 noganex_ joined 02:06 noganex left 02:15 aborazmeh left 02:17 bowtie_ left 02:23 bowtie joined, bowtie is now known as Guest65897 02:42 aborazmeh joined, aborazmeh left, aborazmeh joined 02:46 colomon left 02:50 Guest65897 left 02:51 colomon joined 02:56 bowtie_ joined 03:10 spider-mario left 03:12 spider-mario joined 03:14 bowtie_ left 03:16 colomon left, colomon joined 03:21 bowtie joined, bowtie is now known as Guest96239 03:31 jack_rabbit joined 03:34 Guest96239 left 03:41 bowtie_ joined 03:45 laouji left 03:48 chenryn left 03:52 kaare_ joined 03:55 bowtie_ left, dayangkun joined, mtj_ joined 03:56 mtj_ left, mtj_ joined 03:57 aborazmeh left 04:01 bowtie_ joined 04:06 bowtie_ left 04:11 bowtie_ joined 04:23 cschwenz joined 04:38 bowtie_ left 04:41 skids left 04:43 aborazmeh joined, aborazmeh left, aborazmeh joined 04:45 bowtie joined 04:46 bowtie is now known as Guest606, laouji joined 04:48 chenryn joined 04:50 laouji left 04:51 Ben_Goldberg left 04:54 kaare_ left 04:58 laouji joined 05:15 Guest606 left 05:20 bowtie joined 05:21 bowtie is now known as Guest95031 05:25 Guest95031 left 05:30 cschwenz left, bowtie_ joined 05:35 bowtie_ left 05:40 bowtie_ joined 05:42 alini joined 05:44 bowtie_ left 05:45 Patterner joined 05:49 Psyche^ left, bowtie_ joined 05:51 tinyblak joined 05:54 bowtie_ left 05:55 chenryn left 05:59 bowtie_ joined 06:00 diana_olhovik joined 06:04 bowtie_ left 06:06 yeahnoob left, chenryn joined 06:09 yeahnoob joined 06:10 bowtie_ joined 06:14 kaare_ joined 06:15 bowtie_ left 06:16 kaare__ joined 06:19 kaare_ left 06:20 bowtie joined, bowtie is now known as Guest66879 06:21 domidumont joined, RabidGravy joined 06:24 Guest66879 left 06:25 domidumont left 06:26 domidumont joined 06:27 chenryn left 06:28 Alina-malina joined 06:29 chenryn joined 06:31 bowtie_ joined 06:33 FROGGS joined 06:35 bowtie_ left 06:41 bowtie_ joined 06:44 domidumont left 06:45 bowtie_ left 06:48 yvan1 left 06:49 fhelmberger_ joined 06:50 bowtie_ joined 06:51 alini left 06:52 fhelmberger left 06:53 cognominal joined
moritz \o 06:56
06:57 Ven joined 06:58 _mg_ joined 06:59 brrt joined
nwc10 o/ 06:59
06:59 bowtie_ left
FROGGS o/ 07:00
07:03 aborazmeh left 07:06 bowtie_ joined
Ven \o, #perl6 07:07
nwc10 yay, we have balance again 07:08
07:10 bowtie_ left 07:12 spider-mario left
brrt \o 07:13
07:14 chenryn left, aborazmeh joined, aborazmeh left, aborazmeh joined 07:16 chenryn joined, bowtie_ joined
jnthn \o/ 07:16
07:19 chenryn left 07:20 MARTIMM joined, rindolf joined
[Tux] o/ 07:20
07:21 bowtie_ left
[Tux] tony-o, good work on CSV::Parser. that did a huge speedup! 07:21
dalek ecs: 6e2a5ae | (Stéphane Payrard)++ | S99-glossary.pod:
S99 : fixing broken links
07:22
[Tux] gist.github.com/Tux/e8a6036ccb2a69abe1a1 07:23
still I do see an overall slowdown
brrt compared to p5? 07:24
07:25 rindolf left 07:26 bowtie joined, bowtie is now known as Guest62233 07:27 domidumont joined
[Tux] brrt, see gist: compared to itself over time 07:27
github.com/Tux/CSV/blob/master/README.speed for a longer table (since 2014.10) 07:28
07:29 laouji_ joined
[Tux] commutes ... 07:29
07:29 chenryn joined 07:30 chenryn left, Guest62233 left 07:31 chenryn joined
sergot moarning \o 07:32
07:32 yeahnoob left 07:33 laouji left 07:35 yeahnoob joined 07:36 aborazmeh left 07:37 bowtie_ joined 07:39 chenryn left 07:41 Rounin joined, bowtie_ left 07:42 chenryn joined 07:43 espadrine joined 07:46 yvan1 joined, bowtie_ joined, _mg_ left 07:48 bjz joined 07:49 laouji_ left
RabidGravy boom! 07:49
07:49 laouji joined, alini joined 07:51 bowtie_ left 07:58 bowtie_ joined, bjz left 08:01 RabidGravy left 08:02 bowtie_ left 08:03 rurban joined 08:08 colomon left, colomon joined 08:09 bowtie_ joined 08:10 darutoko joined
labster morning all o/ 08:13
08:15 cschwenz joined 08:16 bowtie_ left 08:17 bjz joined 08:21 zakharyas joined, bowtie joined, bowtie is now known as Guest24074 08:25 sergot joined, bjz left 08:30 cognominal left 08:31 kst left 08:32 brrt left 08:34 MilkmanDan joined 08:35 abraxxa joined 08:37 Guest24074 left
tadzik 'morning! 08:40
08:42 bowtie_ joined 08:45 dakkar joined 08:46 chenryn left 08:47 bowtie_ left 08:49 ab5tract_ joined 08:51 ab5tract_ left 08:52 bowtie_ joined 08:54 chenryn joined 08:55 scumdog joined 08:56 bowtie_ left 08:57 bjz joined 09:02 bowtie_ joined 09:06 bowtie_ left 09:11 bowtie_ joined 09:15 bowtie_ left 09:17 zakharyas left 09:18 leont joined
nine A good, quiet morning to everyone! 09:18
09:21 bowtie joined, bowtie is now known as Guest61428 09:23 Ven left 09:25 Guest61428 left
moritz morning? which timezone are you in? :-) 09:29
FROGGS UGT of course :o) 09:30
moritz good ol' UGT 09:31
09:32 yeahnoob left, bowtie_ joined 09:35 bowtie_ left 09:39 lizmat joined 09:40 bowtie_ joined 09:43 eli-se joined
eli-se good morning 09:44
lizmat good morning, #perl6! (still legal in my timezone :-) 09:45
lizmat gently nudges timotimo
09:45 bowtie_ left 09:48 eli-se left 09:50 bowtie_ joined, rurban left 09:54 bowtie_ left 09:59 bowtie_ joined 10:04 bowtie_ left 10:08 telex left, telex joined 10:09 bowtie_ joined 10:10 sjn joined 10:13 bowtie_ left 10:18 bowtie_ joined 10:20 leont left 10:24 andreoss joined
andreoss what is __SUB__ in perl6? 10:24
moritz &?SUB 10:25
iirc
no, &?ROUTINE
10:25 bowtie_ left 10:32 bowtie joined, bowtie is now known as Guest9982 10:36 rurban joined, zakharyas joined 10:40 alini left 10:42 _mg_ joined, Sysaxed joined 10:45 Guest9982 left 10:46 alini joined, rindolf joined 10:51 _mg_ left, dayangkun left 10:52 bowtie_ joined 10:54 xfix joined 10:55 lolisa joined 10:56 xfix left 11:03 bowtie_ left 11:09 bowtie_ joined 11:12 nbdsp joined 11:13 bowtie_ left 11:18 bowtie_ joined 11:23 jiajia joined 11:24 chenryn left 11:25 jiajia left, bowtie_ left 11:30 kaare__ is now known as kaare_ 11:32 bowtie joined, bowtie is now known as Guest36573 11:36 Guest36573 left
lizmat m: my @a = ^10; @a>>.say # I assume this is intentional, even though we don't hyper this just yet ? 11:44
camelia rakudo-moar a94d68: OUTPUT«9␤7␤5␤3␤1␤8␤6␤4␤2␤0␤»
11:47 chenryn joined
lizmat m: my @a = "A", "C", "E"...*; say @a[^10] # is this a bug, sorta expected A C E G I K M O Q S 11:49
camelia rakudo-moar a94d68: OUTPUT«A C E F G H I J K L␤»
11:50 zakharyas left
lizmat afk& 11:51
psch lizmat: S03:1939 says only numeric sequence don't need a generating closure 11:53
synbot6 Link: design.perl6.org/S03.html#line_1939
psch m: my @a = "A", "C", "E", { .succ.succ } ... *; say @a[^10]
camelia rakudo-moar a94d68: OUTPUT«A C E G I K M O Q S␤»
11:56 chenryn left 12:09 lolisa left 12:10 lolisa joined 12:23 andreoss left 12:33 Ven joined 12:35 _mg_ joined
dalek kudo-star-daily: 61e174d | coke++ | log/ (2 files):
today (automated commit)
12:48
12:48 andreoss joined 12:49 aborazmeh joined, aborazmeh left, aborazmeh joined
andreoss &?ROUTINE seems to refer only to one multi sub from which it was called, to to the whole defenition of function 12:49
*not to the ... 12:50
12:50 _mg_ left, zakharyas joined
andreoss moritz: is there a way to call the multi sub (not one of multies) within itself? 12:52
not using its name i mean
psch m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) { ::('&' ~ &?ROUTINE.name)($a.Str) }; say f(3/4) # horribly hacky, there's probably a better way... 12:53
camelia rakudo-moar a94d68: OUTPUT«Str␤»
moritz m: m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) {
camelia rakudo-moar a94d68: OUTPUT«5===SORRY!5=== Error while compiling /tmp/iuEivf7nAW␤Missing block␤at /tmp/iuEivf7nAW:1␤------> 3multi f(Str $) { "Str" }; multi f($a) {7⏏5<EOL>␤»
moritz m: m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) { &?ROUTINE.proto.('Str') } 12:54
camelia ( no output )
moritz m: m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) { &?ROUTINE.proto.('Str') }; f Any
camelia rakudo-moar a94d68: OUTPUT«Method 'proto' not found for invocant of class 'Sub'␤ in sub f at /tmp/9XzHe3nLCR:1␤ in sub f at /tmp/9XzHe3nLCR:1␤ in block <unit> at /tmp/9XzHe3nLCR:1␤␤»
moritz m: m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) { &?ROUTINE.dispatcher.('Str') }; f Any 12:55
camelia ( no output )
12:55 _mg_ joined
moritz m: m: multi f(Int $) { "Int" }; multi f(Str $) { "Str" }; multi f($a) { say &?ROUTINE.dispatcher.('Str') }; f Any 12:55
camelia rakudo-moar a94d68: OUTPUT«Str␤»
moritz andreoss: ^^ seems that &?ROUTINE.dispatcher does what you want
andreoss thanks
colomon wonders if he can get his system up and running on JSON::Fast before his current $work run using JSON::Tiny finishes. 12:56
12:56 aborazmeh left
timotimo o/ 12:57
colomon: as i said, JSON::Fast ought to be just replacing the use statement
12:57 Sysaxed left
colomon timotimo: here’s hoping! 13:01
first step, however, is building a new rakudo on my Mac. :) 13:02
then I can do some timings.
timotimo right
colomon luckily for my process, I suspect the JSON::Tiny-based $work will take at least 4 more hours.
(that’s running on my Linux box)
13:02 laouji left 13:06 _mg_ left
colomon timotimo: JSON::Fast 13:12
*fetch stage failed for JSON::Fast: source-url meta info missing
btyler colomon: I remember you poked around with the Jansson binding, but found it unsuitable -- why was it no good again?
timotimo damn, didn't i fix that?
colomon btyler: I don’t remember the exact issues, but I think the fact that it required a complete overhaul of my code was the problem. 13:13
timotimo it's in support.source, isn't it?
because that's where i put it
btyler oh O_o
timotimo it used to be in support.source-url, but i was told that's wrong
13:14 _mg_ joined
colomon timotimo: I don’t have any idea what you are talking about there. 13:15
what is the url of the JSON::Fast source?
timotimo META.info
FROGGS timotimo: github.com/FROGGS/p6-Inline-C/blob...A.info#L11
timotimo "source" : "git://github.com/timo/json_fast.git"
btyler it exports to-json and from-json, which should be pretty much indistinguishable from the JSON::Tiny versions
timotimo huh?
btyler: actually, it doesn't export to-json, because rakudo's core setting already seems to have that
13:16 muraiki joined
timotimo and trying to export that gives a nasty redeclaration error 13:16
btyler wat
timotimo m: say to-json(["hi", "btyler"])
camelia rakudo-moar a94d68: OUTPUT«[␤ "hi",␤ "btyler"␤]␤»
btyler well, maybe I'll poke at it this evening. I didn't see that when I was fixing the tests a few days ago
13:17 _mg_ left
timotimo now i have a source-url in my meta.info as well 13:17
btyler to the new AT-POS methods
colomon btyler: when I tried it, the data structure it returned was 100% different from the one JSON::Tiny returned. 13:18
timotimo: panda install git://github.com/timo/json_fast.git worked for me. :)
timotimo oh, cool 13:19
13:19 zakharyas left
btyler colomon: ah, maybe before I split it into 'dump into native p6 data structure' (from-json) and 'keep this as a jansson object' (jansson-from-json) 13:19
timotimo ah, i must have somehow missed you mentioning jansson
btyler keeping it as a jansson object is way faster, but emulating everything you might do with a normal p6 structure was a bit much
anyways, no big deal, just pondering, because 4 hours of mostly JSON processing sounds painful 13:20
timotimo yes! ouch.
btyler also, timotimo, what's going on with the core to-json? I have a sub to-json is export, and that's the one that gets called 13:22
and no warnings about redec
timotimo er 13:23
wow
that's dumb
i made a silly copy-paste mistake
and now i'll need a fully built rakudo to run the tests 13:24
moritz btyler: redeclarations in inner scopes never warn
btyler makes sense. now I'm wondering how timo encountered it, though 13:25
FROGGS good question
13:26 _mg_ joined
timotimo don't look at the source 13:26
it's very embarassing 13:27
13:27 _mg_ left
btyler colomon: anyways, if you have a test case where JSON::Jansson::from-json returns something wildly different from JSON::Tiny::from-json, I'd be delighted to take a look and fix it 13:28
(unless it's just jansson being broken, but that would surprise me)
dalek kudo/nom: abc3875 | timotimo++ | src/Perl6/Compiler.nqp:
mention --profile-filename in the usage message
13:30
13:31 aborazmeh joined, aborazmeh left, aborazmeh joined 13:32 _mg_ joined
hoelzro o/ #perl6 13:33
13:34 _mg_ left 13:36 aborazmeh left
DrForr just booked for YAPC::NA, and I gather Evozon is booking me for ::EU. 13:39
timotimo JSON::Fast now has to-json again 13:40
or ... for the first time
13:46 aborazmeh joined, aborazmeh left, aborazmeh joined 13:52 ssqq joined 13:56 ssqq left 13:57 aborazmeh left 13:59 ssqq joined 14:00 ssqq left 14:02 ssqq joined 14:03 Ven left 14:04 dayangkun joined 14:07 nbdsp left, xfix joined 14:08 cognominal joined 14:10 zakharyas joined
timotimo i'll have some more modules to "fix" 14:10
hm. or maybe not 14:11
DrForr grouses about line comments. 14:13
14:17 Sysaxed joined 14:24 dayangkun left 14:30 skids joined
[ptc] does anyone have admin rights on the perl6/perl6-examples repo? 14:40
I'd like to turn on Travis builds for that repo 14:41
moritz I do 14:43
what do I have to do?
PerlJam greetings
moritz \o PerlJam
PerlJam What's new in the world today? (Is there a release tomorrow?) 14:44
FROGGS PerlJam: there is AFAIK 14:45
PerlJam masak++ for that at least :) 14:48
Doesn't look like anyone has signed up for future releases though.
14:49 kaare_ left
[Coke] wonders if anyone else is avoiding it due to the new signing requirements. 14:49
PerlJam huh. 14:50
PerlJam takes a stab at predicting the future ...
dalek kudo/nom: bd25f32 | PerlJam++ | docs/release_guide.pod:
claim the August release
PerlJam not I. I'm just busy-ish 14:51
14:51 pyrimidi_ left
PerlJam Also ... is it really a *requirement*? OR just a suggestion? 14:52
14:53 konsolebox joined, konsolebox left, konsolebox joined
moritz it says you can skip the step 14:53
14:55 konsolebox left, konsolebox joined
moritz [Coke]: why do the signing requirements make you avoid the release process? 14:56
[Coke]: I'm wondering if there's something I can do to lower the threshold
14:58 lizmat left, Ven joined
[Coke] it was already a pita. What's the purpose of adding the signatures? 14:58
(those are two separate things. doing a release was already a pita. this just puts it over my threshold of time investment) 14:59
15:00 lizmat joined
moritz [Coke]: the purpose is to strengthen trust by making the downloads verifiable 15:04
timotimo would it be problematic to let someone else do the signature for the release manager? 15:05
15:05 lizmat left
FROGGS creating the key just took 5 minutes here fwiw 15:06
15:06 lizmat joined
[Coke] "strengthen trust" ? 15:06
[ptc] moritz: sorry, had to zip off for a minute
timotimo a freshly created key isn't worth terribly much, though ;)
[ptc] moritz: it'd be good if you could flip the build switch on travis-ci.org for perl6-examples
timotimo we perl6ers need to network among ourselves and especially people outside the perl6 community with our gpg keys
[ptc] moritz: that's all that's needed :-)
moritz timotimo: well, I wouldn't sign a package that somebody made and that I downloaded over plain http 15:07
timotimo right, that's what i feared
moritz [Coke]: how would you check if a tarball was tempered with?
timotimo tampared* iirc
[Coke] by verifying with the hashes posted by the release manager.
btyler tampered :)
[Coke] btyler++ 15:08
timotimo er, did i really type "tampared"? :)
i did mean "tampered"
thanks
[Coke] the tarballs aren't tied back to git necessarily anyway. 15:09
moritz [Coke]: if somebody compromised the webserver, they can just change the hashes; and our release announcements and the downloads are hosted on the same server
timotimo that's correct, especially the star tarballs
moritz [Coke]: hence signing the tarballs
[Coke] ah, two signatures. 15:10
timotimo .o( starballs )
dalek ecs: 7a811c0 | (Stéphane Payrard)++ | S99-glossary.pod:
S99: new entries. Expanded some others
15:11 Ven left, gfldex joined 15:12 FROGGS left
moritz [ptc]: done 15:13
[ptc] moritz: sweet! thanks :-)
colomon loading an 8 meg JSON file takes a long time. 15:14
timotimo i hear you :(
dalek ecs: 5cc19b5 | lizmat++ | S99-glossary.pod:
Fix typo, cognominal++
15:15
colomon timotimo: it’s been more than 40 minutes now even with JSON::Fast
timotimo ah, damn 15:16
how's the RAM usage?
colomon looks like 2 GB
15:17 yvan1 left
timotimo mhm 15:17
15:17 mr-foobar left
cognominal Someday we need to hook the glossary to the IRC log 15:18
dalek pan style="color: #395be5">perl6-examples: 9f9be8f | paultcochrane++ | .travis.yml:
Add initial Travis-CI configuration
15:21
pan style="color: #395be5">perl6-examples: 92b0269 | paultcochrane++ | categories/cookbook/0 (6 files):
Merge branch 'master' of github.com:perl6/perl6-examples
15:26 RabidGravy joined
nine colomon: what JSON file is that? 15:27
tony-o [Tux]: did you run that with the Buffer only version?
|Tux| latest checkout
gist.github.com/Tux/de990d9294125224c129 15:28
*that* is my test-script 15:29
colomon nine: it’s generate by my $work software to try to quanitfy what the CAD file it loaded in looks like, so I can compare between different runs of the importer.
nine colomon: so non-publishable?
colomon nine: this particular one, yes 15:30
nine: here’s the beginning: gist.github.com/colomon/afed34519bcd4f82ebb5
dalek Heuristic branch merge: pushed 54 commits to rakudo/newio by lizmat
15:30 Rounin left
colomon nine: I can generate one a public domain CAD file and share it. 15:31
probably not the same length, but...
tony-o |Tux|: i wonder how the 'buf' branch compares, it only uses Buffers
nine colomon: I found a 1.1 MB json file on my disk. I guess that suffices for a quick test
15:31 Ven joined
|Tux| sh$ for i in $(seq 1 10000); do echo 'hello,","," ",world,"!"'; done > /tmp/hello.csv 15:32
that is what the CSV file looks like. You can do the tests yourself 15:33
colomon nine: I just found a 2.8 MB file I can share, if you’d like. 15:34
btyler colomon: I'd be interested too :)
particularly if you find something where JSON::Tiny and JSON::Jansson generate different data structures using from-json
colomon btyler, nine: Google Drive upload okay for you guys? 15:35
btyler sure
timotimo we have a fast xml parser already, right? something based on libxml?
tony-o timotimo: froggs was working on libxml 15:36
timotimo: someone else wrote a PP xml parser, i wrote an html to xhtml parser based on it (both are slow) 15:37
timotimo right, i've been using exemel, i think
to parse the opengl api file
(i haven't done more than from-xml it yet)
took about a minute, IIRC
tony-o the exemel one is what i was referring to ^ 15:38
15:38 alini left
tony-o it's slow, so is my xhtml converter 15:38
nine colomon: time perl6 -e 'use JSON::XS:from<Perl5>; JSON::XS::decode_json("Holtkamp.json".IO.slurp(:bin))'
colomon: real 0m3.858s
colomon: With a 1.1 MB test file. Maybe interesting to you?
btyler nine: the question is how long it takes to serialize into a P6 data structure :)
JSON::XS is beastly fast at both parsing and creating the data structure, but I bet crossing the p5/p6 boundary is going to hurt 15:39
colomon btyler, nine: drive.google.com/file/d/0BzQNY9oWj...sp=sharing
timotimo sort of like an hllize operation?
nine btyler: that call returns it as a P6 data structure. Add a say and it'll take a second more
dalek pan style="color: #395be5">perl6-examples: 9e74d4f | paultcochrane++ | categories/euler/prob002- (2 files):
[euler] make output consistent for prob002
pan style="color: #395be5">perl6-examples: 4019e24 | paultcochrane++ | .travis.yml:
Add missing module dependencies to install step
timotimo nine: only a second? that probably means that perl5 is doing the stringification of the whole structure, eh? 15:40
colomon nine: yes, that’s definitely interesting. I’ve been trying to resist rewriting it in p5, so if I can get the speed of p5 from p6, that’s definitely intriguing. :)
dalek kudo/newio: b4f2ad9 | lizmat++ | src/core/Str.pm:
Fix mergo
nine timotimo: no, I get a Hash 15:41
timotimo oh? wow
that's the many megabytes big file, yes? that's neat
colomon afk
nine To be honest, I'm quite a bit surprised myself. I thought it could be faster than JSON::Fast, but had no idea about those orders of magnitude
timotimo: 1.1 MB 15:42
15:43 CurtisOvidPoe joined
nine 15 seconds for the 2.7 MB parasolid-globe.x_t.json 15:43
nine@sphinx:~> time perl6 -e 'use JSON::XS:from<Perl5>; JSON::XS::decode_json("parasolid-globe.x_t.json".IO.slurp(:bin)).keys.say' 15:44
Instances Objects Counts Header
real 0m15.601s
Did I mention that I really love the integrated Inline::Perl5 support? Saves me a lot of typing :)
hoelzro since tomorrow is the release, is it possible to have the tab completion stuff I wrote merged in?
dalek ecs: dd31858 | lizmat++ | / (6 files):
Turn @*INC/%*CUSTOM_LIB into @?INC/%?CUSTOM_LIB

These should only be changeable at compile time, so make them at least look like compile-time constants.
15:45
15:46 FROGGS[mobile] joined
lizmat hoelzro: I'm afraid looking at your branch, fell through the cracks at the QA hackathon :-( 15:46
nine I wonder if JSON::Tiny could transparently switch to JSON::XS if Inline::Perl5 and JSON::XS are installed. That could speed up rakudo startup until FROGGS++'s serialization changes land...
hoelzro =(
I wish I could've been there!
FROGGS[mobile] nine: I dont think this would work out in the setting 15:48
nine FROGGS[mobile]: yeah, to load Inline::Perl5 you'd have to have the JSON parsed already for one...
timotimo right, the point is that we require the json stuff in order to be able to load the database of installed modules
nine Easy fix: merge Inline::Perl5 into Rakudo ;)
timotimo ouch :)
FROGGS[mobile] :p
and nativecall
timotimo "use NativeCall" goes through the database, too, though
dalek kudo/nom: e0b3401 | TimToady++ | src/Perl6/Grammar.nqp:
remove silly YOU_ARE_HERE restriction

We're supposed to be able to define settings in terms of other settings in the outer scope. That's why they're settings, not preludes.
15:49
masak good afternoon, #perl6
FROGGS[mobile] TimToady: that means we have to reopen a certain RT 15:50
TimToady good, because that's the wrong way to fix whatever the problem was
FROGGS[mobile] I'll provide the ticket number as soon as I am at my laptop 15:51
TimToady 'kay, thanks
FROGGS[mobile] star-m: say {YOU_ARE_HERE} # something like that 15:52
camelia star-m 2015.03: OUTPUT«1␤»
TimToady if there's a closed RT for which that is the fix, it should surely fail a test, right?
nine Our little JSON experiment tells me that converting data is quite fast already. So NativeCall's call overhead seems to be the main performance blocker in Inline::Perl5.
FROGGS[mobile] TimToady: aye 15:53
TimToady part of the problem is that the actual mechanism is currently acting more like a prelude than a setting
if you put the {YOU_ARE_HERE} in a loop, it only gets called once, despite the loop 15:54
but we can use {YOU_ARE_HERE} already in settings based on other settings 15:55
TimToady notes also that the RESTRICTED setting doesn't have a {YOU_ARE_HERE} because of this arbitary restriction, so it assumes it has prelude semantics instead 15:56
well, except it does add the lexical scope, I'll give it that
Ven \o, masak
TimToady in any case, the intent of the original design is nestable settings, each with its own {YOU_ARE_HERE} 15:58
15:59 mr-foobar joined
lizmat TimToady: how would one setting load another ? 16:00
TimToady it's compiled with that other setting 16:01
I mean statically nestable, not dynamically
RT #115372 is the YOU_ARE_HERE test in question, I think 16:02
synbot6 Link: rt.perl.org/rt3//Public/Bug/Displa...?id=115372
[ptc] m: my @a = 1, 2, [3, 4], 5; say @a.perl
camelia rakudo-moar bd25f3: OUTPUT«[1, 2, [3, 4], 5]<>␤»
hoelzro lizmat: any chance you or someone else could look at it today? =) 16:03
16:05 lolisa left
hoelzro I made that chance shortly after 2015.03 went out, hoping it would make it into 2015.04 16:06
16:06 diana_olhovik left
lizmat hoelzro: I really feel too noob to be able to judge the branch :-( 16:07
hoelzro bummer 16:08
I remember FROGGS[mobile] wanted to take a look a while ago
but it needed updating against master/nom
dalek pan style="color: #395be5">perl6-examples: 14825c2 | paultcochrane++ | categories/euler/prob (4 files):
[euler] rename *.p6 to *.pl

This is to be consistent with the other files in this category
16:12
pan style="color: #395be5">perl6-examples: c742177 | paultcochrane++ | t/categories/99-problems.t:
Correct expected output after .perl output changes

See rakudo(nom):80afb7d for more details
16:15 zakharyas left 16:16 tinyblak left
ssqq dalek: specs S05-regex.pod line:596 <say "@()"> should be <say "{@()}"> 16:19
16:20 spider-mario joined
ssqq p6: if 'str' ~~ m:g/ \w / { say "@() {@()}" } 16:20
camelia rakudo-moar e0b340: OUTPUT«@() s t r␤»
ssqq p6: 'str' ~~ / <any> / 16:22
camelia rakudo-moar e0b340: OUTPUT«P6opaque: no such attribute '$!pos'␤ in method ACCEPTS at src/gen/m-CORE.setting:16803␤ in block <unit> at /tmp/tmpfile:1␤␤»
16:23 cognominal left
andreoss is there a function to split a list in X parts or in parts of Y length? 16:23
moritz you can use comb to do the latter 16:24
with a regex /.**1..4/ for example
m: say 'abcdefghijklm'.comb(/.**1..4/) 16:25
camelia rakudo-moar e0b340: OUTPUT«abcd efgh ijkl m␤»
andreoss comb is a method of Str, not Array
moritz oh, list, sorry 16:26
[ptc] yay! the examples tests now pass!
moritz m: my @a = 1..10; say gather while @a take @a.splice(4) 16:27
camelia rakudo-moar e0b340: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Hee0_56KpI␤Missing block␤at /tmp/Hee0_56KpI:1␤------> 3my @a = 1..10; say gather while @a7⏏5 take @a.splice(4)␤ expecting any of:␤ infix␤ infix stopper␤ parameterized…»
moritz m: my @a = 1..10; say gather while @a { take @a.splice(4) }
m: my @a = 1..10; .say for gather while @a { take @a.splice(4) } 16:28
camelia rakudo-moar e0b340: OUTPUT«(timeout)»
rakudo-moar e0b340: OUTPUT«(timeout)5␤6␤7␤8␤9␤10␤»
16:28 eli-se joined 16:29 konsolebox left, cschwenz left
moritz m: my @a = 1..10; say @a.splice(4) 16:30
camelia rakudo-moar e0b340: OUTPUT«5 6 7 8 9 10␤»
moritz m: my @a = 1..10; .say for gather while @a { take @a.splice(0, 4) }
camelia rakudo-moar e0b340: OUTPUT«1␤2␤3␤4␤5␤6␤7␤8␤9␤10␤»
moritz m: my @a = 1..10; .say for gather while @a { take item @a.splice(0, 4) }
ugexe comb is a method of cool
camelia rakudo-moar e0b340: OUTPUT«1 2 3 4␤5 6 7 8␤9 10␤»
moritz ugexe: but if you call it on a list, it'll coerce to Str first -- not what andreoss wants
ugexe ah
PerlJam andreoss: .rotor would almost work if it did the right thing with an overlap of 0 16:31
ssqq p6: 'str' ~~ / <print> /
camelia rakudo-moar e0b340: OUTPUT«Cursor<140104630153016>Cursor<140104630197984>P6opaque: no such attribute '$!pos'␤ in method ACCEPTS at src/gen/m-CORE.setting:16803␤ in block <unit> at /tmp/tmpfile:1␤␤»
moritz the downside of the method above is that it destroys the array
ssqq built-in token <print> have not implement, so the debug info should be more readable.
dalek rl6-roast-data: 7dcbd9f | coke++ | / (9 files):
today (automated commit)
PerlJam m: my @a = 1..10; say @a.rotor(4,0).perl 16:32
camelia rakudo-moar e0b340: OUTPUT«($(1, 2, 3, 4), $(5, 6, 7, 8), $(9, 10))␤»
PerlJam oh, it does do the right thing with a 0 overlap.
I wonder why I thought it was broken
(whoever implemented rotor)++ 16:33
16:33 kaare_ joined
PerlJam Mouq++ looks like 16:34
moritz PerlJam++ has the best solution
moritz has never used rotor before
dalek c: ad05f16 | moritz++ | WANTED:
Add List.rotor to WANTED
andreoss m: multi split-by(\n, *[]) { } ; multi split-by(\n, *@xs ) { @xs[0 ... n -1] , split-by(n, |@xs[n .. *]).list; } ; say split-by(3, 1 ... 10).perl; 16:35
camelia rakudo-moar e0b340: OUTPUT«Nil␤»
andreoss m: multi split-by(\n, *[]) { } ; multi split-by(\n, *@xs ) { @xs[0 ... n -1] , split-by(n, |@xs[n .. *]).list; } ; say split-by(3, @(1 ... 10)).perl; 16:37
camelia rakudo-moar e0b340: OUTPUT«((1, 2, 3), ((4, 5, 6), (7, 8, 9), (10, Any, Any)))␤»
andreoss .splice is an ugly mutator
PerlJam andreoss: why 0 ... n-1 instead of just ^n ?
dalek pan style="color: #395be5">perl6-examples: 65086c1 | paultcochrane++ | categories/euler/prob003-eric256.pl:
[euler] simplify output to ease testing
16:38
pan style="color: #395be5">perl6-examples: aabe746 | paultcochrane++ | categories/euler/prob003-hexmode.pl:
[euler] finish partially complete implementation
pan style="color: #395be5">perl6-examples: 34d4855 | paultcochrane++ | t/categories/euler.t:
Add initial tests for Euler project examples
ugexe m: my @a = 1,2,3; my $x = 0; say @a[0 ... $x].perl; say @a[^$x].perl 16:39
camelia rakudo-moar e0b340: OUTPUT«(1,)␤()␤»
andreoss PerlJam: i'm yet not used to it 16:40
though this won't work with infinite lists, since they cannot be slurped 16:41
16:42 diana_olhovik_ joined
ugexe i had that 0..0 vs ^0 confusion trick me before 16:42
16:46 mohij joined, domidumont left 16:48 dakkar left 16:53 telex left 16:54 telex joined, yvan1 joined
dalek ast: 1c80e0b | TimToady++ | S04-blocks-and-statements/pointy.t:
{YOU_ARE_HERE} is reserved for settings
16:56
kudo/nom: 4bf8538 | TimToady++ | src/Perl6/Grammar.nqp:
{YOU_ARE_HERE} is reserved for settings
PerlJam Will that be YOU-ARE-HERE in the future? 16:58
17:00 molaf joined
TimToady thinks the s:g/_/-/ business is a bit hobgobliny 17:02
_ is still perfectly fine for internals
PerlJam perhaps, but I *like* - more than _ :-)
TimToady how many settings have you written lately?
PerlJam good point 17:03
TimToady maybe we should make it {yOUaREhERE} instead...
ugexe {*~*urhere*~*} 17:05
TimToady
.oO(we have ur here here)
anyway, at least I can compile my CORN setting now, even if it doesn't work quite right yet 17:06
PerlJam
.oO( Will the other one be named CORP? )
17:08
TimToady ayup
that's how niecza++ has 'em
and we probably need a setting that does nothing except be a derived setting, just for namespace testing purposes 17:10
not sure if we want to make RESTRICTED official...
m: say SETTING::pi; # though it did flush out this one
camelia rakudo-moar e0b340: OUTPUT«3.14159265358979␤»
TimToady m: say UNIT::OUTER::pi; # though it did flush out this one
camelia rakudo-moar e0b340: OUTPUT«(Any)␤»
TimToady (what it used to say) 17:11
17:11 _mg_ joined
TimToady anyway, roast currently has 0 tests for settings 17:11
andreoss why there's grep-index, but no map-index? 17:13
timotimo what is map-index supposed to be? 17:14
PerlJam still thinks *-index should go away, so map has it right :)
timotimo i mean, grep-index gives you the index of things it matched back
andreoss .map-index would pass an index to mapper function
PerlJam andreoss: why? 17:15
timotimo so ... kind of like @foo.keys.map?
or more like @foo.pairs.map?
andreoss @x.map-index: { @y[$_] } # replaces @x with @y 17:16
TimToady why wouldn't you just map the list of indices then?
@x.keys.map: { @y[$_] } 17:17
andreoss it's two calls indead of one
17:17 grettis joined
TimToady it's mental baggage 17:17
17:17 FROGGS joined
TimToady and why not just subscript in that case? 17:18
@y[@x.keys]
17:18 diana_olhovik_ left
PerlJam andreoss: you're optimizing the wrong thing if that's the argument for map-index 17:18
TimToady or even @y[^@x] 17:19
TimToady agrees that the -index forms probably should go away in favor of adverbs, in which case we get more than just :k semantics 17:21
17:22 _mg_ left
TimToady grep is just a content-based slicer, if you think about it 17:25
17:26 espadrine left 17:30 ssqq left, ssqq joined 17:31 ssqq left 17:33 ssqq joined
TimToady andreoss: slurpies can take infinite lists; the "slurpiness" is notional 17:37
m: sub foo(*@stuff) { say @stuff[^10] }; foo(0,1,*+*...*) 17:38
camelia rakudo-moar 4bf853: OUTPUT«0 1 1 2 3 5 8 13 21 34␤»
andreoss m: multi split-by(\n, *[]) { } ; multi split-by(\n, *@xs ) { @xs[^ n].item , split-by(n, |@xs[n .. *]).list; }; say split-by(3, my @x = 1..10)[^2].perl; 17:42
camelia rakudo-moar 4bf853: OUTPUT«($(1, 2, 3), $(4, 5, 6), $(7, 8, 9), $(10,))␤»
andreoss m: multi split-by(\n, *[]) { } ; multi split-by(\n, *@xs ) { @xs[^ n].item , split-by(n, |@xs[n .. *]).list; }; say split-by(3, my @x = 1..*)[^2].perl; 17:43
camelia rakudo-moar 4bf853: OUTPUT«()␤»
17:45 ssqq left
timotimo interesting, i hadn't realized that yet 17:45
skids
.oO(Just think of _ as uppercase -)
17:47
17:53 Ven left 17:54 MARTIMM left 18:01 eli-se left 18:12 gfldex left 18:13 Rounin joined 18:14 gfldex joined 18:15 rurban left
DrForr Could someone riddle me this: gist.github.com/drforr/2f5407a2479731ff4082 18:18
FROGGS DrForr: 18:30
- { <COMMENT>*
+ { [ <COMMENT> \s*]*
TimToady or \n? 18:33
DrForr So whitespace only applies inside a rule, not between invocations. Got it.
(lazy wording, I know, but I'm doing several hings...)
TimToady or <COMMENT> *
DrForr I'll take the latter form, thanks. 18:34
18:35 Zoffix joined 18:37 brrt joined
colomon btw, reading in the 8 MB file with JSON::Fast is now up to 4.94 GB. 18:42
just killed it 18:43
TimToady Headline: "France foils terror attack"...no, unless France somehow encourages people to shoot themselves in the leg if they're about to be bad 18:44
FROGGS hoelzro: did you force-pushed to your three branches by any change? 18:46
brrt waitwhat 18:47
FROGGS chance*
brrt TimToady: headlines have been nonsense since there have been headlines
almost as much as deadlines
raydiak m: 'foo' ~~ /<{'o ** 2'}>/ # known? 18:49
camelia rakudo-moar 4bf853: OUTPUT«5===SORRY!5=== Error while compiling EVAL_0␤Quantifier quantifies nothing␤at EVAL_0:1␤------> 3anon regex { ^o\c[32]**7⏏5\c[32]2}␤»
FROGGS eww 18:50
nine colomon: may sound strange, but have you tried JSON::Tiny? Sounds more like you encounter an endless loop.
18:51 _mg_ joined
raydiak FROGGS: that's the exact same thing I thought last night before I ran around an ripped all the spaces out of my project's pattern strings :P 18:51
FROGGS raydiak: why do you have pattern strings at all? 18:52
raydiak FROGGS: my project uses the strings for other things too, so I need them in a string form, so I just generate the regexen from the strings (along with other stuff) 18:53
colomon nine: yes, I tried it, and it took just as long. 18:54
hoelzro FROGGS: yes 18:56
nine colomon: that's not exactly encouraging :(
FROGGS hoelzro: that does not help
grrr, and my connection to github is flaky 18:57
hoelzro =/
18:58 alini joined
hoelzro if you have the tab-completion branch checked out, just git fetch and git reset --hard origin/tab-completion 18:58
after that, you can perl Configure.pl --gen-moar and it should work fine
moritz hopes nobody wants to merge before the release tomorrow
hoelzro moritz: I would like to, but I am willing to hold off to guarantee stability 18:59
dalek kudo/nom: f1d5d0f | lizmat++ | src/core/Any.pm:
Deprecate grep-index in favour of grep :index
19:01
19:02 andreoss left, colomon left
lizmat TimToady: suggestions on how to handle last-index ? :index and :from-end ? 19:03
19:05 Zoffix left
FROGGS hoelzro: github.com/rakudo/rakudo/pull/391#...t-95306400 19:06
brrt oh btw
hoelzro interesting...thanks FROGGS
I'll have a look 19:07
brrt i apparently made a new perl convert in the last few months
(that brings me up to two, if i may brag)
FROGGS a new perl convert? what does that mean? 19:08
19:08 zakharyas joined
lizmat TimToady: re grep vs grep-index: I always thought that it was a design smell if the return value changed depending on an attribute 19:09
brrt somebody who didn't use perl and now does. he's
FROGGS brrt: ahh, gotcha
lizmat also: grep() "is rw", whereas I don't think grep :index should be "is rw"
brrt our new sysadmin, used to use sed/awk and now perl 19:10
lizmat TimToady: so maybe the whole f1d5d0f is bogus, as some of the candidates are "is rw" and some aren't
jnthn: is it a problem if some mmd candidates are "is rw" and some aren't ?
19:13 _mg_ left 19:16 Patterner left, Patterner joined
TimToady :k, :kv, :p should follow the same policy as subscripting does 19:22
lunch & 19:23
hoelzro FROGGS: thanks for the test; I seem to have forgotten to test the situation where linenoise isn't installed =/
19:25 rindolf left, colomon joined
tony-o where does panda install bin/ files to when used in conjunction with rakudobrew ? 19:26
19:30 kst joined
FROGGS tony-o: to "%*CUSTOM_LIB<site>/bin" I guess 19:32
19:34 rurban joined
tony-o for rakudobrew, shouldn't it install to .rakudobrew/bin ? 19:39
or at least be linked there. .
hoelzro FROGGS: I'll fix that after work tonight; I guess it'll have to wait until May =/ 19:41
FROGGS hoelzro: well, quite some ppl use HEAD anyway (via rakudobrew for example) 19:42
hoelzro true
19:43 eli-se joined
hoelzro that's something I hadn't thought of; in order to get history back, in addition to the new features, one needs to install Linenoise 19:43
perhaps I should patch rakudobrew to tell people that post-install? 19:44
FROGGS dunno how rakudobrew could handle that 19:45
hoelzro FROGGS: just after installing rakudo, it would print "you should probably 'panda Linenoise'" 19:46
FROGGS yes, we can put that into our makefile perhaps 19:47
hoelzro that works too 19:48
that can come post-merge =)
FROGGS sure :o) 19:49
timotimo i'll most likely cover the week + a half when the release comes out tomorrow 19:50
19:52 Rounin left 19:59 yqt joined
torbjorn im using a grammar to parse some javascript (or dart actually), a portion of which contains foo:"bar", baz:"test" , which I parse with a rule. is there a way to add those key:value pars to real names in the capture? ie have foo => "bar" be in there as if it were a named capture 20:03
ofcourse its a small matter to fix it afterwards, but it would be nice to have it all served on a platter from the grammar
arnsholt torbjorn: $<sensible_name>=[...] 20:05
torbjorn yeah, but could i pick up that sensible_name from the text that im parsing? 20:06
arnsholt Or if it's a subrule you want to have a less generic name <key=.identifier>
FROGGS torbjorn: that's what you do in the actions
torbjorn otherwise it'd be foo:$<foo>=[\w+]
arnsholt Oh, like that. No, I don't think there's a simple way to do it
Can't really see why you'd want it either, TBH 20:07
FROGGS make that pair a subrule, and then: make ~$<key> => ~$<val>
... in the action
arnsholt Yeah, that's the sensible way to do it
torbjorn googles grammar actions
my perl 6 fu is not all that (yet!)
FROGGS m: say ("foo:bar" ~~ /(\w+) ':' (\w+) { make ~$0 => ~$1 } /).made 20:08
camelia rakudo-moar f1d5d0: OUTPUT«foo => bar␤»
arnsholt torbjorn: Nothing magical, just a class with the same names as your grammar rules
FROGGS torbjorn: what is happening here in the block would have to go into an action method
arnsholt Then, when a rule matches, the corresponding action method is called, with the match object as an argument
torbjorn ah. so i see, seems to fit perfectly, as you say
arnsholt Then MyGrammar.parse($string, :actions(MyActions.new)) 20:10
torbjorn great
FROGGS m: grammar G { rule TOP { (\w+) ':' (\w+) } }; class A { method TOP($/) { make ~$0 => ~$1 } }; say G.parse( "foo:bar", :actions(A) ).made
camelia rakudo-moar f1d5d0: OUTPUT«foo => bar␤»
20:18 FROGGS[mobile] left 20:21 darutoko left
dalek pan style="color: #395be5">perl6-examples: f97eb16 | (David Warring)++ | categories/parsers/CSSGrammar.pm:
[CSSGrammar.pm] removed case sensitivity
20:23
20:26 FROGGS left 20:29 beastd joined 20:30 colomon left, brrt left, brrt joined, brrt left
dalek kudo/nom: 049fe61 | lizmat++ | src/core/Any.pm:
Revert "Deprecate grep-index in favour of grep :index"

  <TimToady> :k, :kv, :p should follow the same policy as subscripting does
My patch only partially addresses this, and it seems inappropriate to put this in just before the release tomorrow.
20:32
20:34 xfix left
dalek ast: dc55cec | TimToady++ | S05-interpolation/regex-in-variable.t:
test things broken if we escape in MAKE_REGEX

  (Injection attacks need to be solved in a more fundamental way anyway.)
20:37
kudo/nom: 7bef4a3 | TimToady++ | src/core/Cursor.pm:
remove EVAL bandaid in MAKE_REGEX for now

Escaping characters obscures the actual injection attack vulnerability, and breaks other things. (A better solution will be to not use interpolation.)
20:39 zeleiadi joined 20:42 zeleiadi left 20:43 kaare_ left 20:44 diana_olhovik joined 20:47 molaf left 20:49 dolmen joined 21:18 alini left 21:21 rurban left 21:22 skids left 21:23 zakharyas left
TimToady m: say "foo" ~~ /<{" o ** 2 "}>/ 21:24
camelia rakudo-moar 7bef4a: OUTPUT«「oo」␤»
TimToady m: say "foo" ~~ /<{"^ o ** 2 ";}>/ 21:26
camelia rakudo-moar 7bef4a: OUTPUT«「oo」␤»
TimToady m: say "foo" ~~ /<{"« o ** 2 ";}>/
camelia rakudo-moar 7bef4a: OUTPUT«「oo」␤»
TimToady m: say "foo" ~~ /<{"<![o]> o ** 2 ";}>/ 21:27
camelia rakudo-moar 7bef4a: OUTPUT«Nil␤»
TimToady something's eating some zero-width assertions but not others
lizmat maybe something's on a diet ? 21:28
TimToady m: say "foo" ~~ /<{"<!after 'f'> o ** 2 ";}>/ 21:29
camelia rakudo-moar 7bef4a: OUTPUT«「oo」␤»
TimToady it's like something's doing a substr
m: say "foo" ~~ /<{"<at 1> o ** 2 ";}>/ 21:31
camelia rakudo-moar 7bef4a: OUTPUT«cannot numify this␤ in regex at EVAL_0:1␤ in method ACCEPTS at src/gen/m-CORE.setting:16795␤ in block at src/gen/m-CORE.setting:16682␤ in method INTERPOLATE at src/gen/m-CORE.setting:16671␤ in method ACCEPTS at src/gen/m-CORE.setting:16795…»
TimToady m: say "foo" ~~ /<{"<at(1)> o ** 2 ";}>/
camelia rakudo-moar 7bef4a: OUTPUT«Nil␤»
TimToady m: say "foo" ~~ /<{"<at(0)> o ** 2 ";}>/
camelia rakudo-moar 7bef4a: OUTPUT«「oo」␤»
TimToady sure seems like something is doing substr
21:41 rurban joined 21:51 beastd left, eli-se left
masak 'night, #perl6 21:53
lizmat gnight masak 21:54
21:55 vendethiel left 21:58 mohij left 21:59 ponbiki left, vendethiel joined 22:03 bjz left 22:07 telex left 22:08 telex joined 22:11 RabidGravy left 22:12 ponbiki joined 22:21 vendethiel left
tony-o what is that supposed to do TimToady ? 22:21
raydiak it *should* do the same thing as if you removed the '<{"' and '";}>' (which runs the code in the <{ }> and inserts the resulting string as part of the regex instead of as a literal string) 22:27
22:27 cognominal joined 22:31 dolmen left 22:33 jferrero joined, jferrero left, jferrero joined 22:36 vendethiel joined 22:38 cognominal left 22:55 gfldex left 22:56 diana_olhovik left 22:58 estrabd left 22:59 skids joined
lizmat good night, #perl6! 23:00
23:01 vendethiel left
raydiak good night lizmat 23:01
23:02 cognominal joined 23:03 rmgk_ joined, rmgk left, rmgk_ is now known as rmgk 23:08 hahainternet left 23:09 hahainternet joined 23:12 rurban left, vendethiel joined
raydiak anyone know some good words for a state in between purely fixed vs variable, static vs dynamic, along those lines? only thing I can think of is "slushy" which underwhelms me 23:17
(or a bunch of prefixes which make longer more awkward words, like quasi- etc) 23:18
skids flexible? 23:19
cognominal and persistent vs mutable, another axis where your slushy may lie? a way to say, I have no idea about what ur thinking about. 23:20
raydiak yes I need more words to make me seem more articulate when I have no idea what I'm thinking about :) 23:21
skids Well, flex would imply bending without breaking. Transient would imply having a normal value which is occasionally changed then reverted back. 23:22
Then there's hard/firm/soft but that's overloaded already. 23:25
cognominal In the persistent world à la clojure, a transient is somehing that you can't revert. It is a stateful hack hidden within the confine of a function.
clojure.org/transients
raydiak need something to have a name before it can be used, but what "it" is, and thus the most appropriate name, is often still a very "flexible" concept when the name is chosen...same problem with children 23:26
cognominal Not to say that transient is not an appropriate word for what you think but it is already taken. 23:27
I am reading Programming Clojere and it is eye opening. Too bad Rich Hickey is hang on ??? (whatever is the lipian word for code as data) 23:30
raydiak I will have to think more specifically about how to describe this, and that will probably help find the word...thanks for the words and ideas, they help the entropy pool immensely :)
timotimo what kind of insights does the "programming clojure" book hold? 23:32
cognominal it is a long time that a O'Reilly book made me such a big effect comparable to Programming Perl
skids cognomial: I think "transient" got that connotation because engineers get overheard talking about derivatives as if they were quantities. 23:33
cognominal I guess a TimToady is necessary here.
for the beotian I am, transient in electronic sounds like some intermediary step you don't want to know about (just like the transient in Clojure that breaks the functional fiction) 23:34
TimToady++
23:35 vendethiel left
cognominal en.wikipedia.org/wiki/Homoiconicity was the word I searched. 23:36
skids cognomial: and in electronic, that's exactly what it means when viewed outside the time domain, but the people saying it, are working in the time domain :-)
cognominal Probably a curse word in the Perl world where we believe on the merits of syntax.
skids erm s/time/frequency/ 23:37
ugexe metamorphic perhaps, or differentiation 23:39
cognominal timotimo, one insight is the merit of persistent structures for concurrency
TimToady raydiak: what activity might cause it to vary? 23:41
cognominal I have not yet read Masak blog about mazes but in PJ there is an interesting maze implementation, a conway life game as well that may interest him
23:41 ssqq joined 23:47 vendethiel joined
ssqq p6: map(* * 2, ^5) 23:55
camelia ( no output )
ssqq p6: say map(* * 2, ^5) 23:56
camelia rakudo-moar 7bef4a: OUTPUT«0 2 4 6 8␤»
ssqq p6: say map(**2, ^5)
camelia rakudo-moar 7bef4a: OUTPUT«5===SORRY!5=== Error while compiling /tmp/tmpfile␤Unable to parse expression in argument list; couldn't find final ')' ␤at /tmp/tmpfile:1␤------> 3say map(**7⏏052, ^5)␤ expecting any of:␤ infix␤ infix stopper␤»
TimToady m: say **.WHAT
camelia rakudo-moar 7bef4a: OUTPUT«(HyperWhatever)␤»
23:58 perturbation joined