»ö« 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!
Set by masak on 12 May 2015.
00:04 LLamaRider left 00:14 laouji joined 00:23 b2gills left 00:27 b2gills joined
tony-o m: -- 00:27
camelia rakudo-moar 553f0e: OUTPUT«5===SORRY!5=== Error while compiling /tmp/31yOaG3fRu␤Prefix -- requires an argument, but no valid term found␤at /tmp/31yOaG3fRu:1␤------> 3--7⏏5<EOL>␤ expecting any of:␤ prefix␤»
tony-o m: -- "yo" 00:28
camelia rakudo-moar 553f0e: OUTPUT«Cannot modify an immutable Str␤ in block <unit> at /tmp/FoZ4OwLsK4:1␤␤»
00:39 laouji left 00:41 pochi left 00:43 laouji joined, BenGoldberg joined 00:46 pochi joined
tony-o raiph: i'm running into a problem trying to give EVALFILE scope of a variable 00:48
00:50 adu joined 00:54 khw left
raiph tony-o: oh? 00:59
00:59 aborazmeh joined, aborazmeh left, aborazmeh joined
tony-o raiph: i accidentally uncommented something 01:01
it's working now, working on the grammar to do the interpolating 01:02
raiph tony-o: Did you basically agree or disagree with what I wrote in the issue? Is "the grammar to do the interpolating" the slang to switch from `{` and `}` delimiters? 01:06
tony-o raiph: i totally agree, i think it could be a really cool templating system 01:07
the grammar is to parse the templates and figure out which interpolation to use, separate the blocks from the qqw[] stuff
the problem is the client sockets and server are both running in different threads and they can't talk very well because of the cross thread crap 01:08
oops
01:09 khw joined
raiph tony-o: I'm confused about you writing a grammar to separate the blocks. I was thinking you just let the Perl 6 grammar do its thing. 01:09
tony-o raiph: i can't see how to do that, maybe i'm confused about '--' 01:10
01:13 yqt left
tony-o m: my $l = ' { $raiph } '; my $raiph = 'hello world'; say qqw{$l}; 01:15
camelia rakudo-moar 553f0e: OUTPUT«{ $raiph }␤»
raiph m: my $data; $data<what> = 'that'; print "Hello { "WORLD!" }␤␤Oh, did you want variables too? I can do { $data<what> } too.␤{ (for ^3 -> $a { $a ~ ($a == 2 ?? '' !! ', '); }) }" 01:17
camelia rakudo-moar 553f0e: OUTPUT«Hello WORLD!␤␤Oh, did you want variables too? I can do that too.␤0, 1, 2»
tony-o yea i understand how that interpolation works, but now how to get that interpolation from a file or a string 'slurp'd from a file 01:18
because essentially you end up with literal '{' in the string
raiph tony-o: ooooh 01:20
tony-o i guess that might be called lazy interpolation, i can't think of a good way to achieve that without writing a grammar 01:21
raiph m: my $raiph = 'hello world'; my $l = " { $raiph } "; say qqw{$l};
camelia rakudo-moar 553f0e: OUTPUT«hello world␤»
tony-o before the 'say' happens, $l already contains 'hello world' 01:22
01:22 leont left 01:26 flussence joined
tony-o jnthn: i have a patch for Grammar::Debugger that makes it work, it fails the debugger test because it times out waiting for input but the thing outputs as i'd expect. the tracer also works with the patch *and* it passes the test. it's a hack though. do you want a PR or how else can i make this useable until we figure out the right solution? 01:32
raiph m: my $raiph = 'hello world'; my $l = ' { $raiph } '; say EVAL qqw{$l}; 01:33
camelia rakudo-moar 553f0e: OUTPUT«hello world␤»
raiph tony-o: What's the weakness in ^^ ? 01:34
tony-o m: my $r = 'sup'; my $s = 'hello { $r }'; say EVAL qqw{$s}; 01:35
camelia rakudo-moar 553f0e: OUTPUT«5===SORRY!5=== Error while compiling EVAL_0␤Undeclared routine:␤ hello used at line 1. Did you mean 'shell'?␤␤»
raiph m: my $r = 'sup'; my $s = 'hello { $r }'; say EVAL qqw{"$s"} 01:36
camelia rakudo-moar 553f0e: OUTPUT«hello sup␤»
tony-o m: my $r = '{ for ^3 { .say; } }'; say EVAL qqw{$r}; 01:37
camelia rakudo-moar 553f0e: OUTPUT«0␤1␤2␤Nil␤»
tony-o m: my $r = 'count to 3: { for ^3 { .say; } }'; say EVAL qqw{"$r"};
camelia rakudo-moar 553f0e: OUTPUT«0␤1␤2␤Use of Nil in string context in block <unit> at EVAL_0:1␤count to 3: ␤»
raiph don't .say 01:38
tony-o m: my $r = 'count to 3: { for ^3 { print $_; } }'; say EVAL qqw{"$r"};
camelia rakudo-moar 553f0e: OUTPUT«012Use of Nil in string context in block <unit> at EVAL_0:1␤count to 3: ␤»
raiph do wrap (last statement in a block) in parens
don't say or print 01:39
m: my $r = 'count to 3: { (for ^3 { $_ } ) }'; say EVAL qqw{"$r"};
camelia rakudo-moar 553f0e: OUTPUT«count to 3: 0 1 2␤»
raiph tony-o: I think the semantics of a block inside a string are that it interpolates the return value 01:41
ugexe depends on what you use to quote it though
raiph ugexe: indeed 01:42
if EVAL'd using default double quoted string semantics
01:42 dayangkun joined
tony-o yea i'm not sure i want to expect people with templates to have to do that for a loop 01:43
raiph tony-o: Yeah, that Perl 6 wrinkle is about the weakest aspect of the approach. 01:48
01:48 FROGGS joined 01:50 atroxaper joined
raiph tony-o: Maybe redirect writes to STDOUT to make say/print work as expected? 01:52
01:53 Ben_Goldberg joined 01:54 adu left 01:55 atroxaper left 01:56 BenGoldberg left
raiph tony-o: does a PHP `print` command insert it's output in to the page at the point it occurs? 01:56
tony-o not really sure, i have the STDOUT redirection working right now 01:57
raiph tony-o++ 01:58
tony-o: I'm thinking that a generic redirect-stdout-to-enclosing-string option for strings would be cool. 02:01
tony-o what do you mean? 02:02
raiph m: say "foo { print 'bar' } baz" :dwim # says 'foo bar baz' 02:03
camelia rakudo-moar 553f0e: OUTPUT«barUnexpected named parameter 'dwim' passed␤ in block <unit> at /tmp/Ye9Ue8ZfAd:1␤␤»
02:03 yeahnoob joined
tony-o ahh, yea that's what i'm trying to do so if you need to manipulate something in a loop you can just 'print' it instead of fooling around with ending a block and restarting a block or whatever 02:04
then you're not stuck buffering crap into a temp str to use that as the return value
02:05 adu joined
raiph tony-o: I was thinking that you (the implementor, not user) would redirect STDOUT to a temp str per block and then prepend that temp str to a block's returned value. 02:10
tony-o: and that that would be a useful feature in its own right 02:11
02:11 noganex_ joined 02:14 noganex left
tony-o first i need to figure out matching the right brace for nested { } 02:18
02:19 FROGGS left
ugexe just require putting a \r\n\r\n before each ending }! 02:19
raiph tony-o: Is that so you can switch from `{...}` to some other delimiter? 02:20
tony-o yea
02:21 BenGoldberg joined
dalek c: 56f6381 | hoelzro++ | lib/Type/Str.pod:
Document Str.substr(Range)
02:21
02:22 Ben_Goldberg left
raiph tony-o: I recall reading the blog post that announced PHP. Iirc I read it the same day it was posted. ("Personal Home Page" iirc. 1996 or thereabouts.) It was very simple and low key. A quick hack that was easier than SSIs and Perl. And look what happened. 02:31
(iirc it was before blogs were called blogs, or even weblogs) 02:32
02:33 telex left 02:34 FROGGS joined, telex joined 02:35 adu left 02:38 rmgk_ joined, rmgk left, rmgk_ is now known as rmgk 02:41 vendethiel joined 02:54 davido_ joined 03:20 aborazmeh left 03:23 FROGGS left 03:30 aborazmeh joined, aborazmeh left, aborazmeh joined 03:31 laouji left 03:32 laouji joined 03:33 vendethiel left 03:39 Ben_Goldberg joined 03:43 BenGoldberg left 03:48 raiph left 04:08 nys left 04:09 aindilis joined 04:14 sftp joined, vendethiel joined 04:22 nightfrog joined, laouji left 04:30 dr- joined 04:31 dr- left 04:32 Ben_Goldberg left 04:34 khw left 04:38 adu joined, adu left 04:53 laouji joined 04:59 vendethiel left 05:06 atroxaper joined 05:08 rickbike joined, rickbike left 05:10 rickbike joined 05:11 vendethiel joined, [Sno] left 05:23 quester joined
TimToady waves from tahoe, after driving 700 miles 05:24
moritz particles back 05:25
05:25 atroxaper left, atroxaper joined 05:26 atroxaper left 05:27 rickbike left 05:34 vendethiel left, aborazmeh left 05:44 vendethiel joined 05:52 atroxaper joined 05:55 _mg_ joined 06:03 diana_olhovik joined 06:14 FROGGS joined 06:21 gfldex joined 06:29 RabidGravy joined
RabidGravy morning 06:30
06:32 vendethiel left, mj41 joined
mj41 .tell tony-o See my POC github.com/mj41/SP6/ :-) 06:34
yoleaux mj41: I'll pass your message to tony-o.
06:35 mj41 left 06:42 domidumont joined 06:43 gfldex left 06:46 Ven joined 06:47 domidumont left 06:48 domidumont joined 06:50 amurf left 07:00 zakharyas joined 07:04 atroxaper left 07:09 vendethiel joined 07:15 skids left 07:18 atroxaper joined
masak good morning, #perl6 07:19
pmichaud` # irclog.perlgeek.de/perl6/2015-06-24#i_10801409 07:21
er, pmichaud++
nwc10 good *, masak 07:23
nwc10 wonders what it will take to bootstrap jnthn this morning. Fortutious cosmic ray?
www.planetary.org/blogs/jason-davis...-test.html 07:24
07:25 rindolf joined
masak nwc10: jnthn bootstrapping being slow is (seemingly) a tradeoff to increase the rest of jnthn performance. :P 07:25
nwc10 after the past couple of days, I'm somewhat concerned about the difference betwen "slow" and "Saturday" 07:26
07:33 vendethiel left 07:34 Ven left
masak m: sub foo($a;; $b) { say "OH HAI" }; foo(1, 2); say &foo.signature 07:35
camelia rakudo-moar 553f0e: OUTPUT«OH HAI␤(Any $a, Any $b)␤»
masak submits rakudobug
arguably, that should say `(Any $a;; Any $b)`, because the difference affects the behavior of the signature. 07:36
07:36 espadrine joined 07:39 darutoko joined 07:43 Ven joined 07:44 abraxxa joined 07:45 quester left 07:49 pdcawley joined, pdcawley_ left
RabidGravy masak, what does the semicolon signify? 07:50
Ven masak: separates the mmd-impacting part from the other one 07:51
moritz the double semicolon indicates that everything behind it shouldn't be considered for multi dispatch
Ven oops.
moritz pretty useless in an only-sub
m: multi foo($a;; $b) { say "OH HAI" }; say &foo.signature 07:52
camelia rakudo-moar 553f0e: OUTPUT«(|)␤»
moritz m: multi foo($a;; $b) { say "OH HAI" }; say &foo.candidates[0].signature
camelia rakudo-moar 553f0e: OUTPUT«(Any $a, Any $b)␤»
moritz ... but multis have the same problem :-)
07:53 g4 joined
RabidGravy ah okay 07:53
masak allow me to recommend codewords.recurse.com/issues/three...ata-types/ to anyone with an interest in Category Theory.
I just skimmed it, and it looks quite nice.
07:53 Ven left 07:54 cfa joined
moritz opens it in a browser tab, and hopes to get around to reading it later on 07:54
07:55 vendethiel joined 07:56 [Sno] joined 08:00 zakharyas left
lizmat .tell tony-o I think jnthn would appreciate a PR for the debugger/tracer fixes 08:01
yoleaux lizmat: I'll pass your message to tony-o.
FROGGS masak: what is ;; in a signature? 08:03
lizmat disregard other params for MMD 08:05
DrForr .tell tony-o Might it be possible to have Data::Dump default to non-colorized when output is not going to a tty?
yoleaux DrForr: I'll pass your message to tony-o.
FROGGS lizmat: aha 08:09
masak FROGGS: details are in S06, I believe. 08:11
08:11 jack_rabbit left
masak .oO( when I was young we didn't ask questions on channel; we just pored over the apocalypses, trying to understand them ) :P 08:12
you young'uns with your "synopses" and your "spec" and your "docs" and your "blogs" and your "learnxiny"...
get off my apocalawn! :P 08:13
FROGGS :P 08:15
FROGGS .oO( do they do :S in #scala? )
08:15 dakkar joined
TEttinger FROGGS: they do ;( 08:16
masak the only way to understand Perl 6 back then was to read the Apocalypses, aloud, in TimToady's voice.
DrForr There's a "History of the World, Part 2" joke in there somewhere.
FROGGS .oO( '}' is meant to terminate a statement... except when it's not ) 08:18
nwc10 and, if you were lucky, and could also do an Australian accent, you might be able to read an Exergesis. 08:19
08:20 Ven joined, espadrine left 08:22 gagalicious joined
lizmat and that was quite an Exercise! 08:25
std: sub ($a;;$b;;$c) {} 08:26
camelia std 28329a7: OUTPUT«Potential difficulties:␤ $b is declared but not used at /tmp/BWLZr7O4fp line 1:␤------> 3sub ($a;;7⏏5$b;;$c) {}␤ $c is declared but not used at /tmp/BWLZr7O4fp line 1:␤------> 3sub ($a;;$b;;7⏏5$c) {}␤ $a is declared but not used at /tmp/B…»
lizmat std: sub ($a;;$b;;$c) { $a,$b,$c }
camelia std 28329a7: OUTPUT«ok 00:00 141m␤»
lizmat would multiple use of ;; make any sense ?
moritz no 08:27
08:27 jack_rabbit joined, TEttinger left
dalek kudo/nom: 3e1dab7 | lizmat++ | src/Perl6/Grammar.nqp:
Make use of ;; in sig a NYI compile error for now

This at least prevents #125482 for now.
08:27
08:37 atroxaper left 08:38 amurf joined 08:39 Ven left 08:41 atroxaper joined 08:42 zakharyas joined 08:43 amurf left 08:44 atroxaper left
masak prevents? not if it's just a .worry 08:44
I was also thinking how strict we want to be with `;;` in only subs/methods. they don't make much sense there. 08:45
09:01 vendethiel left
moritz huh? I thought ;; was implemented? 09:03
seems I was wrong 09:04
09:06 espadrine joined
moritz m: multi a(Int;;Cool) { say 1 }; multi a(Int;;Int) { say 2 }; a 0, 0 09:08
camelia rakudo-moar 3e1dab: OUTPUT«Potential difficulties:␤ Use of ;; in signature not yet implemented␤ at /tmp/5GiFBqHgu2:1␤ ------> 3multi a(Int;;7⏏5Cool) { say 1 }; multi a(Int;;Int) { say␤ Use of ;; in signature not yet implemented␤ at /tmp/5GiFBqHgu2:1␤…»
moritz lizmat: in my old rakudo, I get a "Ambiguous call to 'a'" with the ;;, and 2 (second candidate) without the ;; 09:09
lizmat: so I'm pretty sure ;; is actually implemented
even if the information isn't carried to the Signature object
09:10 vendethiel joined 09:11 ][Sno][ joined 09:13 [Sno] left
masak right, the problem might be only in the presentation of the siggie. 09:15
09:21 atroxaper joined
masak m: sub foo($x, $y;; $z) {}; say &foo.arity; say &foo.count 09:23
camelia rakudo-moar 3e1dab: OUTPUT«Potential difficulties:␤ Use of ;; in signature not yet implemented␤ at /tmp/bI6cxCdO5o:1␤ ------> 3sub foo($x, $y;;7⏏5 $z) {}; say &foo.arity; say &foo.count␤3␤3␤»
masak oh, right.
locally, that gives "3\n3\n" 09:24
09:25 laouji left 09:26 laouji joined 09:28 cognominal joined 09:29 andreoss joined
jnthn morning, #perl6 09:30
;; is implemented 09:31
It's just .perl of it that's not
It's also obvious it's being paid attention to; grep Actions.nqp for ;; 09:32
And since it works, code could easily be using it out there.
masak ok. 09:33
dalek kudo/nom: 2bafa97 | (Carl Masak)++ | src/Perl6/Grammar.nqp:
Revert "Make use of ;; in sig a NYI compile error for now"

This reverts commit 3e1dab79af5ddc31aa200305d63348dbf9211dea.
  ';;' is implemented, and hence not NYI.
jnthn The SIG_ELEM_MULTI_INVOCANT flag not being set on a param is what indicates it is opted out of multi-dispatch 09:34
iirc, everything before a ;; has it set
(so if you see the next param doesn't, and the current one does, then you can emit a ;;) 09:36
nwc10 yay, jnthn bootstrapped 09:37
masak .oO( jnthn, dropping implementation clues on channel since 2007 ) :P
jnthn Allergies seem less annoying today than yesterday also :) 09:38
jnthn wonders if he'll get a couple of hours Perl 6 hacking in before going to $work-party :)
nwc10 the alternative is running a class in coffee brewing? 09:41
jnthn Well, or more usefully doing a few final tidying up tasks in the apartment, since I'm leaving it for good tomorrow :) 09:44
09:45 yeahnoob left 09:52 leont joined
RabidGravy m: use NativeCall; for (num64, num32 ) -> $type { my @buff := CArray[$type].new; @buff[$_] = Num(0) for ^10; } 09:52
camelia ( no output )
RabidGravy that almost exact code fails with "Wrong kind of access to numeric CArray in method ASSIGN-POS at lib/NativeCall.pm:333" in Audio::Sndfile but not when isolated like that 09:54
masak RabidGravy: your mission, should you choose to accept it, is to find out why one fails and not the other. 09:56
RabidGravy frankly it's doing my head in, the code in #125408 is fine now, but the original code I started with fails worse 10:00
10:03 atroxaper left
DrForr Speaking of NativeCall, I'm putting together an OpenCV2 binding now that the ANTLR4 port seems to be stabilizing. 10:04
10:06 atroxaper joined
RabidGravy cool 10:17
10:18 leont left 10:19 husanu3 joined, bjz joined 10:25 husanu3 left 10:26 husanu2 joined 10:28 amurf joined, husanu2 left, sqirrel joined 10:29 rindolf left, husanu3 joined
itz_ hahaha I hadn't seen www.youtube.com/watch?v=zC7uPC6KeA4 10:30
10:31 husanu3 left 10:32 amurf left
lizmat jnthn++ moritz++ masak++ for showing the error of my ways :-) 10:34
masak lizmat++ # learning together, the best kind of learning 10:35
lizmat yup, and I learned a bit about the P6 grammar :)
jnthn
.oO( lizmat++ # showing us the way of her errors )
The seperator thing is one of the icky bits of the grammar... 10:36
iirc it actually collects them into an array held in a dynvar...
lizmat yeah, I saw that :-) 10:37
10:37 dayangkun left
jnthn I think there is (by now, perhaps "was") a bug that meant captures on the RHS of %% got lost 10:38
So it may be possible to clean up
If the bug is fixed already, or when the bug gets fixed.
10:40 darutoko- joined
dalek c: cc155f6 | paultcochrane++ | lib/Language/regexes.pod:
Minor wording improvements in regexes.pod
10:41
c: efbb139 | paultcochrane++ | lib/Language/testing.pod:
Convert variable names to kebab-case

This is then more consistent with general Perl6 usage.
10:42 rindolf joined 10:43 darutoko left
RabidGravy boom! got it! 10:46
lizmat masak jnthn moritz : I just realized that the ;; feature is *not* spectested atm, as I did a spectest before pushing and saw no failures 10:50
10:50 ][Sno][ is now known as [Sno]
jnthn RabidGravy: A golf of the nasty bug? 10:55
lizmat: Yes, I was wondering about that...
timotimo i really wouldn't mind if we got a stream-based xml parser for perl6 10:57
masak timotimo: "wouldn't mind" is like the most diluted form of volunteering there is :P 10:59
homeopatic volunteering
lizmat m: sub a (;;$a) { } # jnthn: does this signature make sense?
camelia ( no output )
masak lizmat: ;; in only subs doesn't make much sense in the first place. 11:00
m: sub a (;;$a) { say "OH HAI" }; a(5)
camelia rakudo-moar 2bafa9: OUTPUT«OH HAI␤»
timotimo also not really without a type
lizmat well, ok
masak lack of type is fine after ;; I think
lizmat multi then
it was more about *not* having anything before the ;; 11:01
masak m: multi foo(;;$a) { "OH HAI" }; foo(5)
camelia ( no output )
masak m: multi foo(;;$a) { say "OH HAI" }; foo(5)
camelia rakudo-moar 2bafa9: OUTPUT«OH HAI␤»
masak lizmat: seems to make sense.
RabidGravy jnthn yeah, I added gist.github.com/jonathanstowe/2776...15f42cbd4d to the rt#125408
lizmat masak: how?
masak I guess it means something like "no part of this siggie takes part in candidate resolution" 11:02
lizmat then how does it get to find any method then?
masak lizmat: it's not about finding the method. it's about disambiguating several methods.
lizmat m: multi a (;;$b) { }; multi a (;;$a,$b) { }; say a(42)
camelia rakudo-moar 2bafa9: OUTPUT«Nil␤»
lizmat m: multi a (;;$b) { say "one" }; multi a (;;$a,$b) { say "two" }; a(42) 11:03
camelia rakudo-moar 2bafa9: OUTPUT«one␤»
masak again, there is only one possible candidate in that case.
lizmat m: multi a (;;$b) { say "one" }; multi a (;;$a,$b) { say "two" }; a(42,666)
camelia rakudo-moar 2bafa9: OUTPUT«two␤»
lizmat m: multi a (;;$b) { say "one" }; multi a (;;$a) { say "two" }; a(42)
camelia rakudo-moar 2bafa9: OUTPUT«Ambiguous call to 'a'; these signatures all match:␤:(Any $b)␤:(Any $a)␤ in block <unit> at /tmp/AQPjykgBxr:1␤␤»
masak right.
lizmat: disambiguating performs a narrowness analysis. 11:04
11:04 sqirrel left
masak lizmat: only things to the left of the ;; participate in it. 11:04
RabidGravy in summary it only does it in a loop and it only does it when the number of elements isn't known to the method at compile time
masak so in the cases above, there is basically no narrowness analysis performed.
jnthn m: multi a (;; Any $b) { say "one" }; multi a (;; Int $a) { say "two" }; a(42)
camelia rakudo-moar 2bafa9: OUTPUT«two␤»
jnthn I...think that one is a bug
masak I think so too
jnthn We probably mis-handled initial ;;
That should be ambiguous
masak unless some other tiebreaking thing kicks in. 11:05
but I don't think it does.
jnthn It shouldn't, I think we just don't handle initial ;; properly
masak m: multi a ($b) { say "one" }; multi a ($a) { say "two" }; a(42)
camelia rakudo-moar 2bafa9: OUTPUT«Ambiguous call to 'a'; these signatures all match:␤:(Any $b)␤:(Any $a)␤ in block <unit> at /tmp/F1MBK0dd_e:1␤␤»
masak that's the behavior I expect.
masak submits rakudobug
jnthn Right, same
timotimo RabidGravy: can you try it with MVM_SPESH_DISABLE=1 set in your environment? 11:07
RabidGravy timotimo, yeah that makes it go away (as it does in the actual code) 11:08
timotimo god damn it :S
masak ok, now it's a *cursed* bug.
timotimo can you upload the MVM_SPESH_LOG=broken_carray_access.txt ?
best gzip it :)
11:09 _mg_ left 11:10 _mg_ joined
lizmat jnthn: indeed, SIG_ELEM_MULTI_INVOCANT is set on the first param in (;; $a) 11:11
timotimo ah, good catch. that's probably wrong, then :)
RabidGravy timotimo, added to ticket. bastarding big even gzipped 11:14
timotimo sorry, i recently improved the speshlog to become bigger :) 11:15
RabidGravy :-)
11:19 Alina-malina joined
jnthn Bastarding big? Nodes in the dominance tree are unsure who their parents are? :P 11:19
timotimo RabidGravy: can i has the RT# again?
moritz nah, the parents just didn't marry :-)
RabidGravy timotimo, rt.perl.org/Ticket/Display.html?id=125408 11:20
timotimo 1.6m is bastarding big to you? :)) 11:21
that's nothing! ;) 11:22
jnthn lunch & 11:23
timotimo RabidGravy: is the file called "tz"?
RabidGravy yeah, for no particular reason. I was just running out of two letter filenames 11:24
(ancient practice of mine - give scratch files two letter names to make them easy to delete ;) 11:27
right off out now
11:28 gcole left
timotimo fair enough :) 11:31
11:32 RabidGravy left, gcole joined
lizmat m: (sub a { @_ }).signature.perl.say # shouldn't that be :(;; *@_) ?? 11:33
camelia rakudo-moar 2bafa9: OUTPUT«:(*@_)␤»
dalek kudo/nom: 4e1fa3c | lizmat++ | src/core/Parameter.pm:
Implement multi-invocant method

To check for SIG_ELEM_MULTI_INVOCANT flag
11:35
11:36 laouji left 11:39 El_Che joined 11:40 telex left 11:42 telex joined
lizmat There is a subtle difference in the signature of "sub a { @_ }" and sub a(*@_) { }" that was so far unseen: 11:42
$ 6 '(sub a { @_ }).signature.params[0].multi-invocant.say'
False
$ 6 '(sub a(*@_) { @_ }).signature.params[0].multi-invocant.say'
True
jnthn masak: should @_ have the multi-invocant bit set or not (in either case?) 11:44
alternately: should slurpies ever have the multi-invocant bit set ? 11:46
masak I don't really see why it should. 11:47
but I don't know exactly what multi-invocant is.
dalek kudo/nom: f43725a | lizmat++ | src/core/Signature.pm:
Show ';;' in signatures if they need to be

Fixes #125482
11:48 atroxaper left
lizmat jnthn just said that params with that bit set, are included in MMD? 11:48
masak m: say (sub a(*@_) { @_ }).signature.params[0].WHAT
camelia rakudo-moar 2bafa9: OUTPUT«(Parameter)␤»
11:49 salva joined
lizmat hmmm... musty have inferred that 11:49
11:49 atroxaper joined, atroxaper left
lizmat anyway, the fix causes 3 spectest failures because of difference in handling auto-generated sigs 11:50
masak it's odd. I don't see `multi-invocant` defined or referred to anywhere.
lizmat it's probably an implementation detail
I just added the multi-invocant method
(if you're looking at the source) 11:51
t/spec/S06-signature/unspecified.rakudo.moar (Wstat: 768 Tests: 17 Failed: 3)
Failed tests: 5, 9, 13
feels to me either the test is wrong (now), or having the flag set on auto-generated sigs is wrong 11:52
masak: should there be a difference between the sig of "sub a { @_ }" and "sub a(*@_) { }" ?
jnthn lizmat: I suspect it should probably be set on anything that isn't after a ;; 11:53
lizmat ?? I thought you just said it should be set on anything *before* ;; ? 11:54
ah, uh. duh :-)
jnthn I...yeah, negations are not unbad. :)
lizmat so the autogenned sig is wrong ? 11:55
masak .oO( but what about the excluded middle? what about parameters that are exactly on top of the ;; ? ) :P
jnthn lizmat: Yeah, that's probably just an oversight 11:56
lizmat should I create a ticket for that and todo the failing tests?
or can you give me a pointer as to where to look to fix this oversight ?
jnthn Yeah, please. I think there'll be a good way to fix it generally
Well, probably in World.nqp's create_parameter method 11:57
lizmat ah, ok, lemme check
jnthn I think if the param info hash doesn't have the multi_invocant key we should default it to setting the bit, whereas today we probably default to not doing so
You may be able to eliminate places that actions.nqp sets it as a result of this...
(expect the place that sets it to 0)
11:58 Ven joined 12:00 domidumont left
timotimo do we now get a ;; before every *%_? 12:03
jnthn shouldn't
timotimo it would be kind of nice to have that hint for people who tend to forget about nameds only being used for tie-breaking
jnthn Well, we will if the bug isn't fixed...
timotimo you know, the thing where the order of subs decides
lizmat $ 6 '(sub a(:$n) { }).signature.params[0].multi-invocant.perl.say' 12:04
Bool::True
jnthn The language in the spec suggests that maybe, post-6.0, we will have nameds play into the candidate sort 12:05
timotimo oh
i see
lizmat so any named param seem to have the multi-invocant bit set atm
jnthn I'm not sure how viable that is, but I'd rather keep .multi-invocant only ever show up after a ;;
That is, keep it aligned with what the programmer wrote
masak +1 12:06
simple rule: "was there a ;; before this parameter?"
jnthn aye 12:07
timotimo fair enough
jnthn I like simple rules
lizmat $ 6 '(sub a($a;;:$n;) { }).signature.perl.say'
:(Any $a;; Any :n($n))
jnthn ...and I can not lie
masak jnthn: doesn't preserve the meter. you have to like big rules or something :P
lizmat so: the current rule is: all params have multi-invocant bit set unless there was a ';;' seen, in which case only the params before the ;; have it 12:08
masak .oO( I like excessively bending the meter of original works and I cannot lie )
lizmat: or, shorter, all params not after a ;; have it 12:09
jnthn masak: As a Brit, I think it's the foot and inch I'm meant to be preserving, not the meter :P 12:10
lizmat
.oO( said in true British syncopation )
masak the sun never sets on antiquated measurements. 12:11
12:13 domidumont joined
daxim docs.perl6.org needs an explanation of its usage examples under the headlines. I cannot figure out what :D: means or **@p or |p 12:16
masak daxim: +1 12:18
daxim: saying things in words (besides showing the symbols) would help immensely.
moritz it would also be cause for lots of redundancy
daxim just hyperlink the things to its appropriate page, that already would make me happy 12:19
moritz (which isn't a priori a bad thing in docs, but it does lead to more maintenance)
masak moritz: the words describing things like **@p don't change all that often 12:21
jnthn Maybe the bits of signature syntax could link to the appropriate bit of the signatures doc 12:22
Ah, I htink that's what daxim meant...
daxim yes!
masak ok, good. 12:25
dalek ast: 6948ef3 | lizmat++ | S06-signature/unspecified.t:
Fudge failing tests for RT #125486
12:27
timotimo is something wrong with *.WHAT? 12:28
m: say ("hi", 1, 0.9).map(*.WHAT)
camelia rakudo-moar f43725: OUTPUT«hi 1 0.9␤»
timotimo m: say ("hi", 1, 0.9).map({ $_.WHAT })
camelia rakudo-moar f43725: OUTPUT«(Str) (Int) (Rat)␤»
timotimo star: say ("hi", 1, 0.9).map(*.WHAT)
camelia star-m 2015.03: OUTPUT«hi 1 0.9␤»
jnthn I don't think .WHAT auto-curries (by design)
moritz right; it's not a method 12:29
timotimo hm
fair enough
moritz it's a macro in method disguise
timotimo and >>.WHAT isn't supposed to work either?
moritz m: say (1, 'foo')>>.WHAT 12:30
camelia rakudo-moar f43725: OUTPUT«(Parcel)␤»
12:30 g4 left 12:33 aborazmeh joined, aborazmeh left, aborazmeh joined
dalek ast: ce42e09 | hoelzro++ | S32-str/substr (2 files):
Add basic tests for substr/substr-rw + Range
12:37
12:37 zakharyas left
lizmat afk for a bit& 12:38
12:39 zakharyas joined
hoelzro morning #perl6 12:45
12:50 atroxaper joined, husanu3 joined 12:52 husanu3 left 12:54 atroxaper left 12:56 husanu2 joined 13:00 husanu2 left 13:01 Ven left 13:10 domidumont left, domidumont joined
Woodi hi #perl6 :) 13:12
hoelzro can anyone think of why *not* inlining a block would prevent phasers + return from working properly? I was trying to fix RT #125480 last night, but this is my first dance with the optimizer
ahoy Woodi
13:13 husanux5 joined, husanux5 left
Woodi hoelzro: becouse it returns to not inlined block ? :) 13:13
but I have no idea what I'm talking about :) 13:14
hoelzro =)
13:14 husanux7 joined 13:15 rindolf left
Woodi let assume big photo is a list... user read it into memory and views or edit. so big memory blobs are valid cases. but this is "slurp" case... 13:18
13:18 husanux7 left
Woodi in "for lines()" for should use lines-iterator... if it create array of all lines in file then lines work like slurp, not lines :) 13:20
13:20 husanux9 joined, leont joined 13:21 husanux9 left
Woodi but probably we want something like "workflows" in photo editing... load, remove noise, up curves, sharper, save; one after one or batch... 13:21
psch Woodi: but lines() is just "lazy slurp" until the input record seperator..? 13:22
Woodi so keeping things in memory is like DOM xml parsing and for iterators we want SAX-like processing...