»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
00:00 snearch left, IngisKahn left 00:01 Ingis-Kahn joined 00:03 preflex joined, Ingis left, vlixes joined 00:04 mattp_ left 00:07 hundskatt left 00:08 dalek left 00:09 dalek joined, ChanServ sets mode: +v dalek 00:10 lutok joined 00:11 donri left 00:15 aindilis` joined 00:19 lutok left 00:20 bbkr left 00:24 bbkr joined 00:26 mkramer left, mkramer joined
dalek kudo/nom: de3e8e7 | jnthn++ | src/Perl6/ (2 files):
Implement an optimization for private method calls. If possible, it reduces them to sub calls. Can also detect and complain about missing private method calls at CHECK time (since they're non-virtual). Requires --optimize=3.
00:29
kudo/nom: 09097de | jnthn++ | docs/ChangeLog:
Couple of ChangeLog additions.
00:30
jnthn phenny: tell Woodi did a couple of optimzations to the core setting that seem to give a 10%-15% improvement on Simple::Redis benchmark. Also the optimizer does private method calls better; try it with --optimize=3 (not on by default just yet) 00:33
phenny jnthn: I'll pass that on when Woodi is around.
00:44 vmspb left 00:53 molaf_ left 00:57 kmwallio joined
flussence I like it when something blows up but with a well-written error message :) 01:03
perl6: say int(4, ...);
p6eval niecza v11-27-gdaa9117: OUTPUT«===SORRY!===␤␤Undeclared routine:␤ 'int' used at line 1␤␤Potential difficulties:␤ Comma found before apparent series operator; please remove comma (or put parens␤ around the ... listop, or use 'fail' instead of ...) at /tmp/XCeaQQIFCW…
..pugs b927740: OUTPUT«*** No compatible multi variant found: "&int"␤ at /tmp/p47PVgoJ4W line 1, column 5-16␤»
..rakudo da4426: OUTPUT«===SORRY!===␤Comma found before apparent series operator; please remove comma (or put parens␤ around the ... listop, or use 'fail' instead of ...) at line 1, near " ...);"␤»
01:05 molaf_ joined
flussence (and more languages should have a "...;" thing; much better than putting "TODO" comments everywhere :) 01:05
01:05 Chillance joined
snarkyboojum except you can grep for TODO whereas grep'ing for … would also show sequences 01:12
flussence hm, yeah
still, you won't forget to fix it when a test hits that line 01:13
dalek kudo/nom: 1e5b310 | jnthn++ | src/core/IO/Socket/INET.pm:
Method calls automatically coerce their results into Perl 6 things, so we don't need to re-do it in this case.
01:14
kudo/nom: 8fe7111 | jnthn++ | src/core/IO/Socket.pm:
Avoid various accidental v-table calls in socket IO.
kudo/nom: 78cf70e | jnthn++ | src/core/Str.pm:
Optimize chomp a little.
snarkyboojum seems that running like something like perl6 -e 'exit(...)' on the cli actually prints a message to stderr 01:17
"Stub code executed"
that's a bit weird
flussence looks like one of the things that should have a line number... 01:19
snarkyboojum a line number? 01:20
flussence "Stub code executed at line blah"
snarkyboojum should it print anything to stderr?
flussence well it returns a Failure, which stringifies to that.
snarkyboojum ah 01:21
flussence (well, emits a warning if you try to use it as a value)
snarkyboojum fair enough
jnthn sleep & 01:22
01:37 plutoid joined 01:38 vinian joined
Timbus are perl 6 exceptions resumable coroutines, and is it possible to use them to emulate yield/resume type functions, and is it a good idea to incorporate them into MuEvent to allow for 'pausable' callbacks 02:03
02:07 mkramer1 joined, mkramer left 02:15 mattp_ joined 02:29 mkramer1 left 02:31 mkramer joined 02:40 benabik joined 02:57 bacek joined 03:09 bacek left 03:39 skangas joined 04:03 icwiener left 04:07 kmwallio left 04:29 plutoid left 04:39 Chillance left 04:52 colomon joined
colomon Just updated github.com/colomon/mandelbrot with a new Gtk version. Still pretty simple, and I would desperately like to optimize it a good bit more.... 04:54
04:56 abercrombie left 04:59 aindilis` left 05:00 aindilis` joined 05:01 BinGOs joined 05:03 vlixes left 05:12 plutoid joined 05:31 vinian left 05:36 vinian joined 05:45 Sarten-X left 05:52 Sarten-X joined 06:00 localhost left 06:02 localhost joined 06:14 vinian left, am0c joined 06:15 vinian joined
Woodi Timbus: spec says: "Such a construct, where many calls made to the name of a sub with different parameters, expecting to reach the same sub every time, is not really compatible with multi-method-dispatch"... 06:16
phenny Woodi: 00:33Z <jnthn> tell Woodi did a couple of optimzations to the core setting that seem to give a 10%-15% improvement on Simple::Redis benchmark. Also the optimizer does private method calls better; try it with --optimize=3 (not on by default just yet)
Timbus :/ 06:17
wait, but that's not really the same thing
Woodi however yesterday I learned useful use case for yield... 06:18
Timbus in an event based system, "yield until ready;" is a very handy thing.. 06:19
Woodi from Ruby: def bench(descr) \n def bench(descr) \n yield \n ....
grr, second line is: start = Time.now 06:20
so nice benchmark helper
and Ruby have Fibers too ?
Timbus probably 06:21
Woodi jnthn: I will try with optimisations as sun as I get access to proper workstation :)
Timbus: second part of that spec cite is that gather/take work like coroutines 06:22
but I realy need some manual for them :)
Timbus but I can't see how 06:23
Woodi Timbus: want to know Perl6 tip ? :)
Timbus well, I can't see how you'd make an event system use gather/take
tip away.
Woodi a) go to perl6.org b) click Synopsis c) click 'C tags' down there d) use browser search for anything you want :) 06:25
maybe there is a better way for that :) 06:26
06:32 thou joined 06:55 [Sec] joined 07:08 mkramer left, mkramer joined 07:19 mkramer1 joined, mkramer left 07:20 vinian left 07:22 mkramer1 left 07:25 vinian joined 08:30 Trashlord left 08:47 alvis left 09:01 stepnem left 09:02 alvis joined 09:11 stepnem joined 09:19 thou left 09:37 hundskatt joined 09:39 plutoid left 10:28 fsergot left 10:30 fsergot joined 10:36 MayDaniel joined 10:54 mj41 joined 10:56 MayDaniel left 11:03 f00li5h joined 11:06 Trashlord joined 11:12 fsergot left, Trashlord left 11:15 grondilu joined
grondilu nom: say grep none(foo), <foo bar> 11:15
p6eval nom 78cf70: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&foo' called (line 1)␤»
grondilu nom: say grep none('foo'), <foo bar>
p6eval nom 78cf70: OUTPUT«bar␤»
grondilu weird. I thought I tried that yesterday on my machine and it didn't work. Nevermind, it does now. 11:17
jnthn Whenever I see somebody say "X didn't work on my machine" and it's got quotes in, I wonder if their shell eated the quotes. :) 11:30
11:36 fsergot joined, am0c left 11:52 grondilu left 11:56 zby_home joined 12:03 hundskatt left 12:05 HarryS left 12:09 mdxi left
masak good day, #perl6 12:09
colomon O/ 12:10
my head seems to have grown!
masak .oO( cOlOmOn ) 12:11
12:11 HarryS joined 12:13 Psyche^ joined 12:16 Patterner left, Psyche^ is now known as Patterner 12:17 mj41 left
moritz facts.learnpython.org/2008 12:23
"How can addition be more easier than this?", using eval and join 12:24
how 'bout [+] ?
masak :)
12:24 kokos joined 12:25 kokos is now known as Guest20913
masak nonsense! it's a Python Fact -- it has to be right! :P 12:27
12:31 mj41 joined, whiteknight joined 12:32 whiteknight is now known as Guest92238 12:46 mj41 left 13:01 mkramer joined 13:04 mkramer left 13:05 MayDaniel joined
tadzik oh, someone proposed to do this with Perl 6 13:13
'afternoon, #perl
6
jnthn o/ tadzik 13:14
masak tadzik! \o/ 13:15
jnthn wtf, I just implemented a basic version of wrap and it worked first time 13:16
tadzik know the feeling, had that during gsoc 13:17
wtf, no test failures? What did I miss...
jnthn OK, found something that doesn't work. Phew. :)
Underlying idea seems sound though. :) 13:18
It's by far less horrible than master's wrap implementation too.
er, ng's :)
tadzik ENOMASTER ;)
masak "Rakudo Perl 6 -- getting less horrible with each iteration" 13:26
dalek kudo/nom: 5f34902 | jnthn++ | src/Perl6/Actions.pm:
A routine will always need some kind of dispatcher slot, since it may be a wrapper (in fact, we probably need to generalize this to block level).
13:27
kudo/nom: f7053be | jnthn++ | tools/build/Makefile.in:
Shuffle Attribute.pm earlier in the bootstrap, since we're going to use a class with attributes in Routine.
kudo/nom: 4d35f0c | jnthn++ | src/ (2 files):
First cut implementation of Routine.wrap. No unwrap support yet, and the wrappers also need to be rutines until the dispatcher slot gets generalized to blocks.
jnthn eek, I caused a fail 13:30
ah, I fix stuff soon...shopping &
13:35 fsergot left 13:44 Guest20913 left 13:56 am0c joined 14:11 colomon left 14:17 hundskatt joined
felher How can i have two classes A,B in files A.pm, B.pm that 'use' each other? 14:19
tadzik class A { ... }; class B {}; class A {}; I think 14:20
I may be wrong though
(literal '...') 14:21
14:21 JimmyZ joined 14:22 colomon joined
felher tadzik: I'm not sure i understand your suggestion. The problem is that at the moment if they 'use' each other, they keep including recursively until maximum recursion depth is reached. 14:24
tadzik oh, I see
masak that sounds wrong.
is this on latest nom?
felher masak: yes. 14:25
jnthn It should die more gracefully than recursing. This came up within the last week, I think.
felher masak: well, two-day-ago-nom
i'll recompile nom an check again.
jnthn felher: I strongly doubt anything will have changed.
felher maybe its older nom and it already solved :)
jnthn I'm aware it fails in a bad way, but I didn't get to improving things, and I didn't see any other patches that would. 14:26
felher jnthn: i see :) So for classes in different files that need each other the best thing to do at the moment is to use master instead of nom? 14:27
jnthn felher: er
felher: The best thing to do is not design it like that. 14:28
master allowed things to work that it should not have done, because it didn't do separate compilation properly.
14:31 colomon left
jnthn Put another way, if two classes are so tightly coupled that they depend on each other by name, then there's never a case where you'd just need to load one of them, so there's no reason not to put them in the same compilation unit (that is, the same file) 14:33
felher jnthn: okay, but if i have a class DLX, that will emulate a DLX-Processor, with a method load-program, that loads a programm (long string). And a grammar DLX-Program and a class DLX-Programm-Actions. I wanted DLX-Program-Actions.TOP 'make' a list of closures that operate on a DLX-Object. So the Action-class needs to know the DLX-Class, while DLX-Class needs to know the Action-Class, so it can have a method 14:35
load-program. Is this considered bad design?
I hope it is understandable what i want to achieve
14:41 hundskatt left 14:42 Trashlord joined
felher Well, i write it without the load-program method for a start. This method isn't really needed :) 14:43
jnthn felher: That load-program method does sound a little misplaced. I'm having trouble working out what you mean by DLX-Class vs DLX-Object. Do you just mean there's a class DLX? And you then make instances of it to represent the data to be manipulated? 14:50
If so it sounds like that class is serving two responsibilities: being the facade to the module's functionality, and being the holder of data.
It may also be that load-program has no real reason to be a method at all, but instead a sub exported by the module. 14:52
felher jnthn: first: thanks for your help! :). second: I guess it is harder to explain than to show, so as soon as i got something working, i'll push the few lines on github so one can see instead of decrypting my explanations :) 14:54
jnthn felher: Probably the case :) 14:55
15:00 spine joined 15:05 Trashlord left, vinian_ joined 15:07 vinian left 15:14 abercrombie joined 15:16 mikemol left 15:17 mikemol joined
Woodi to get optimized rakudo I need to pass --optimize=3 to rakudo Configure ? or parrot/nqp ? 15:19
jnthn Woodi: To Rakudo itself.
perl6 --optimize=3
Woodi ok 15:20
jnthn Woodi: Note that it uses 2 by default. 3 means "new/experimental optimizations"
Woodi: We do compile the core setting with --optimize=3
Woodi: Because the spectest suite is big enough to point out the issues
15:22 dorlamm joined
Woodi with 3 looks little slower :) 15:24
I tested on yesterday version of Rakudo
jnthn Woodi: I found the benchmark had quite a huge variance between runs. 15:25
Woodi: I guess because it's doing network IO
Woodi yes, but difference is around 0.0x s 15:28
will check newer rakudo 15:29
jnthn Woodi: I was seeing a bit wider than that, I think. Disclaimer: I'm on Windows, and also just grabbed a Redis binary and ran it straight out of the ZIP package without installing it or anything :)
dalek ast: f37fce0 | jnthn++ | S06-advanced/wrap.t:
Unfudge some todo tests in wrap.t; fudge a test for .callwith, which we don't yet implement.
15:32
15:37 Chillance joined
dalek kudo/nom: 98b6731 | jnthn++ | src/ops/perl6.ops:
Ensure that dispatch searcher can handle frames with an unpopulated dispatcher slot.
15:38
kudo/nom: dcc9495 | jnthn++ | src/Perl6/Actions.pm:
Ensure every block gets a $*DISPATCHER slot, since they could all end up serving as wrappers.
kudo/nom: 927659c | jnthn++ | src/ (2 files):
Get unwrapping in place.
kudo/nom: ef81604 | jnthn++ | t/spectest.data:
Turn on wrap.t.
ast: 251efb0 | jnthn++ | S06-advanced/wrap.t:
A bunch more unfudging for wrap.t; think we pass more of this now than ever before.
jnthn And an RT down :)
masak \o/ 15:39
jnthn oh 15:40
the method on the wrap handle should be called restore, not unwrap
masak unwrap is cuter, and more mnemonic. 15:42
jnthn The one on sub is .unwrap 15:44
Anyway, I'll make it do what the spec says for the time being :) 15:45
If somebody wishes to change the spec and patch the name, I'm not going to argue :)
...well, unless they decide to call the method aadvark or something.
15:45 Moukeddar joined
dalek ast: 2a3fab4 | jnthn++ | S06-advanced/wrap.t:
Test for unwrapping using the handle itself.
15:46
kudo/nom: 046303e | jnthn++ | src/core/Routine.pm:
Rename method on the wrap handle to match the spec.
15:47
masak I'm thinking of renaming the method in the spec instead... :)
though I don't feel extremely strongly about it. 15:48
felher Did i get that right: I need to provide and BUILD-submethod if i want private attributes to be able to be initialized from new()?
jnthn masak: If you do so, please patch Rakudo to keep it in sync.
felher: yes
masak jnthn: gotcha.
felher jnthn: good :)
jnthn masak: It's in Routine.pm
masak: You may find the implementation cute too :)
masak felher: well, or initialize them at declation.
declaration*
jnthn: I'm sure I will :)
felher masak: yeah, or that :) 15:49
masak I'll wait and see if anyone else has an opinion on 'restore' vs 'unwrap'.
benabik Unwrap makes sense iff the opposite operation is called wrap. 15:50
benabik isn't really paying attention, can you tell?
jnthn benabik: There's a Routine.wrap which returns a handle. You can pass that to Routine.unwrap($the-handle) to remove the wrapping
However, the handle is currently spec'd to have a method that will just go ahead and do the unwrapping.
Currently it's called restore 15:51
masak oh!
jnthn So the restore method is the one on the handle itself.
Not the one on Routine.
masak I hadn't realized that there's already a .unwrap method on Routine.
jnthn masak: yeah
benabik I'd kinda expect unwrap to be a method on the handle.
masak yeah, maybe that's a distinction worth keeping, then.
benabik Not sure, that's odd.
masak benabik: I wouldn't.
it's the *Routine* that's unwrapped. 15:52
the handle is just an indicator to which layer of wrapping is to be removed.
jnthn There was some handwavey comment in the test file about there being an argumentless unwrap the pops the "latest" wrapper off
*that
15:52 rindolf joined
rindolf Hi all. 15:52
jnthn But it's neither implemented nor, afaik, spec'd.
rindolf jnthn: here?
Oh, you are.
jnthn o/ rindolf
rindolf jnthn: did you take a look at my test failures?
masak o/ rindolf
rindolf masak: hi. 15:53
jnthn: hi.
15:53 Moukeddar left
masak jnthn: sounds like a double-edged convenience. 15:53
jnthn rindolf: The range.t one is still problematic; believe the others are now resolved.
masak: Yeah, I'm not too fond of the idea. 15:54
masak jnthn: I mean, if you can unwrap without specifying the handle, you might "accidentally" unwrap someone else's wrapping, right?
jnthn masak: Correct.
masak: It feels like a bad idea in general.
masak the nice thing about the current design is that wrappings are "orthogonal" to each other.
which is quite a feat when you think about it.
jnthn Yes, that's a nice property.
masak (since they nest)
jnthn Well, they're called in a certain order
But provided you write composable ones, then sure, it's fine. 15:55
masak yeah.
jnthn What compostability means is quite situation specific though
er, composability
rindolf jnthn: OK, thanks.
masak I think the handle-less .unwrap would be at odds with the composability, if only indirectly.
but... I agree it might be nice, too :) 15:56
maybe it can be made to work only when there's exactly one layer of .wrap applied?
jnthn masak: maybe :)
heh, you can do the self-unwrapping wrapper now 15:59
masak I have forgotten about that one :) 16:00
jnthn > sub flag_first_call(&x) { my $h = &x.wrap(-> |$ { say "called!"; callsame; $h.restore }) }; sub foo() { say 42 }; flag_first_call(&foo); foo(); foo();
called!
42
I'm sure somebody would find a cute use for it some day :) 16:01
benabik Oh. &foo.wrap doesn't return a new method, it alters &foo. That makes sense
jnthn benabik: yes, it's in place
benabik Vivifying database connections?
jnthn mebbe
masak anything that needs to be done exactly once. 16:02
jnthn It may be that state variables are always more convenient for that kinda thing though.
We
*well
This lets you do it from the outside though
masak feels like the same could be done with a state v... dang :)
jnthn Where the routine may not be an active participant in the process
masak right.
jnthn Of course, you could wrap with state too
But then you'd call the outer wrapper every time.
masak hm, I gotta remember this pattern so I can just reach for it when I need it :> 16:03
16:11 JimmyZ left, benabik left
Woodi hmm, got 0.5 s improvement on 10k commands and 0.1 s on 10k strings concatenation 16:18
[Coke] yawns 16:20
16:37 dorlamm left 16:38 hundskatt joined 16:43 MayDaniel left, daxim joined 17:19 Moukeddar joined 17:20 Moukeddar left 17:21 Trashlord joined
masak nom: sub foo { say "unwrapped" }; my $h = &foo.wrap: { say "first call"; $h.restore }; foo; foo; foo 17:31
p6eval nom 046303: OUTPUT«first call␤unwrapped␤unwrapped␤» 17:32
masak \o/
jnthn The @a = @a bug is a real pain to solve...if you're not pmichaud
nom: my @array = <a b c d>; @array .= grep: { $_ ~~ /<[a..c]>/ }; say @array 17:35
p6eval nom 046303: OUTPUT«splice() not implemented in class 'Mu'␤ in method reify at src/gen/CORE.setting:3975␤ in method gimme at src/gen/CORE.setting:4336␤ in method eager at src/gen/CORE.setting:4312␤ in method STORE at src/gen/CORE.setting:4765␤ in method dispatch:<.=> at src/gen/CORE…
jnthn Fixed that one, but busted other stuff :/ 17:37
17:46 colomon joined 17:54 MayDaniel joined
dalek kudo/nom: 08e560e | jnthn++ | src/core/List.pm:
Make unshift handle the case where it's called and $!items is empty.
17:59
kudo/nom: 99fff11 | jnthn++ | src/core/Array.pm:
Try to fix Array.STORE a bit. This isn't perfect, but an improvement for sure; things like '@a = @a' and '@a .= uniq()' now work. Still something rotten in some of the lazy cases, though.
ast: b67998f | jnthn++ | S (2 files):
Various unfudges thanks to list fixes.
18:08
kudo/nom: de08cc8 | jnthn++ | docs/ChangeLog:
Some ChangeLog entries.
18:18
18:22 birdwindupbird joined, birdwindupbird left 18:26 sayu joined 18:37 am0c left 18:38 Guest2721 joined 18:39 vinian_ left 18:40 vinian_ joined 18:45 molaf_ left 18:49 alvis left 19:05 Sarten-X left
masak nom: class Pin { method drop { say "<tiny metal sound>" } }; .drop given Pin.new 19:08
p6eval nom de08cc: OUTPUT«<tiny metal sound>␤»
19:13 Sarten-X joined 19:15 vinian_ left 19:22 vinian_ joined
felher masak: given can be a statement modifier? 19:31
cognominal with masak's onliner, I discovered that too. :) 19:32
felher sweet :)
masak given is a very nice statement modifier. 19:35
what amazes me is that the two of you know the term "statement modifier" without having discovered that "give" could be one :P 19:36
there are two kinds of statement modifiers: conditional and loopy. 19:39
"given" is the loopy type.
moritz
.oO( like the "if-loop"? )
jnthn ;) 19:41
felher :D 19:42
masak g'ah, if-loops! :) 19:44
the reason that sub-classification matters is that it governs which statement modifiers you can nest without using parentheses.
you can nest if-mods inside loop-mods, but not the other way around.
nom: .say if $_ %% 3 for 1..20 19:45
p6eval nom de08cc: OUTPUT«3␤6␤9␤12␤15␤18␤»
masak nom: .say if $_ %% 3 given 15
p6eval nom de08cc: OUTPUT«15␤»
masak nom: .say given 15 if 2 + 2 == 4
p6eval nom de08cc: OUTPUT«===SORRY!===␤Missing block at line 1, near ""␤»
masak std: .say given 15 if 2 + 2 == 4
p6eval std be1f10e: OUTPUT«===SORRY!===␤Confused at /tmp/SCQdT97NIK line 1:␤------> .say given 15 ⏏if 2 + 2 == 4␤Parse failed␤FAILED 00:01 120m␤»
masak arguably there could be a better error there. 19:46
felher masak: ah, good to know :)
masak '<x> if <y> for <z>' is how Perl 6 does list comprehensions :) 19:47
like Haskell's [<x> | <z>, <y>] syntax. 19:48
felher yeah :) 19:49
19:50 sayu left
moritz perl6: say(5-7)/2 19:52
p6eval pugs b927740, rakudo de08cc, niecza v11-27-gdaa9117: OUTPUT«-2␤»
masak nom: sub is-prime { none ($^n %% $_ for 2..$n/2) }; my @primes = ($_ if .&is-prime for 2..100)
p6eval nom de08cc: ( no output )
masak nom: sub is-prime { none ($^n %% $_ for 2..$n/2) }; my @primes = ($_ if .&is-prime for 2..100); .say for @primes
p6eval nom de08cc: 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␤»
masak \o/
cognominal nom: grammar A { token TOP { <a>? }; token a { a } }; $/ = A.parse: "a"; say $/<a>.WHAT 19:55
p6eval nom de08cc: OUTPUT«Parcel()␤»
moritz nom: say (2 + 2i) > (2 + 3i)
p6eval nom de08cc: OUTPUT«(timeout)» 19:56
masak o.O
moritz: has that been reported?
moritz wonder if that should dispatch-error
masak: don't thinks so
cognominal I thought the quantifier ? now returned a Match instead of a Parcel in case of success
masak submits rakudobug 19:57
19:58 mj41 joined
jnthn nom: die 'foo' 19:58
p6eval nom de08cc: OUTPUT«foo␤ in block <anon> at /tmp/r9UjgElZwj:1␤ in <anon> at /tmp/r9UjgElZwj:1␤»
jnthn nom: multi foo() { }; foo(1) 19:59
p6eval nom de08cc: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'foo' will never work with argument types (int) (line 1)␤ Expected any of:␤ :()␤»
jnthn heh
masak moritz: as far as I'm concerned, it should either return Failure or die outright.
jnthn nom: multi foo(Rat) { }; foo(1)
p6eval nom de08cc: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'foo' will never work with argument types (int) (line 1)␤ Expected any of:␤ :(Rat)␤»
jnthn oh no, it's too smart...
nom: multi foo(Rat:U) { }; foo(1)
p6eval nom de08cc: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'foo' will never work with argument types (int) (line 1)␤ Expected any of:␤ :(Rat)␤»
jnthn nom: multi foo(Int:U) { }; foo(1)
p6eval nom de08cc: OUTPUT«No applicable candidates found to dispatch to for 'foo'. Available candidates are:␤:(Int)␤␤ in block <anon> at /tmp/MK7cye80g5:1␤ in <anon> at /tmp/MK7cye80g5:1␤»
jnthn Hm
OK, so it does report dispatch fails. Phew.:)
20:00 Trashlord left
jnthn oh, crap 20:00
phenny: tell mls it seems that any infinite recursion in Rakudo generates a hang when trying to find an exception handler 20:01
phenny jnthn: I'll pass that on when mls is around.
jnthn moritz: So it's doing infinite recursion for some reason. That then doesn't get reported.
moritz it probably tries something stupid like converting to .Numeric or so 20:02
20:03 molaf joined
cognominal S05: "If a subpattern is directly quantified with C<?>, it either produces a single C<Match> object, or C<Nil>. " 20:10
moritz we probably don't do that yet 20:11
(used to be different)
nom: sub f(Str $x) { }; my Int $y = 3; f($y) 20:12
p6eval nom de08cc: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'f' will never work with argument types (Int) (line 1)␤ Expected: :(Str $x)␤»
moritz so the optimizer knows about variables now?
20:12 Moukeddar joined
dalek ok: 7117803 | moritz++ | / (5 files):
Several text and markup fixes

Thanks to flip214++ for the thorough review
20:18
20:20 rindolf left
moritz is kinda tired of the well-phrased Perl 6 rants by chromatic, that all seem to contain much wisdom, but never leave me any wiser than before 20:36
jnthn So, what does he want us to do? Give up? Because that's all chromatic ever makes me feel like doing. 20:42
masak seems what made chromatic "give up on Perl 6" was something really trivial, such as, "I'd like to use Perl 6 in production now, in 2011, but none of the implementations are there yet" 20:47
moritz dunno. Get attention, maybe.
masak and just at the point when the implementations are really shaping up!
now we "just" need thousands of modules :)
awwaiid only positive thing I got out of it -- it would be a big win to have a perfectly functional magical bridge to perl5 CPAN. Duh. 20:48
arnsholt I feel the quote "[...] I want to solve my problems more than I want a better language." sums it up. Essentially, he's saying "I'm a late adopter"
And he thinks the early adopters are stupid (or however you wanna put it) for not agreeing with him
masak well, this "I'm a late adopter" attitude is fairly new from him. 20:49
moritz he's a later adopter to being a later adopter 20:52
fits, eh? :-)
masak RT #104594 is "the same" as that other lexical-related bug we had a few weeks ago. 20:53
jnthn moritz: on the optimizer - it's not worrying too much about variables. It does pay attention to the .type annotation on a node. And iirc the actions make sure lexical variables get marked with one.
masak: Yeah, I'm pretty sure it is. Somehow it must be taking a different code path. I can only guess because it's a code block in a quoting language or something...
moritz: So it's not so much variable aware, just type aware :) 20:54
masak jnthn: no, it's even the same "symptoms" as with the other ticket. an inner block is required, recursing is needed, etc. 20:55
jnthn masak: huh? I was agreeing with you :) 20:56
masak: And being a little surprised the last fix didn't cover this one :)
masak oh, ok. 20:57
20:57 Guest92238 left
moritz $ ./perl6 -e 'say (2+2i) > (2+3i)' 20:57
You can only coerce a Complex to Real if the imaginary part is zero
masak yes, maybe different code path then. 20:58
moritz++
20:59 worr joined, mj41 left
jnthn moritz: is rt.perl.org/rt3/Ticket/Display.html?id=104430 closable now? 21:00
moritz nom: say True.perl 21:01
p6eval nom de08cc: OUTPUT«Bool::True␤»
moritz jnthn: yes, I think we have tests too
jnthn moritz: Yeah, I saw various commits to rakudo/tests, but wasn't sure if there was a reason it was still open :) 21:03
21:03 vinian_ left
jnthn masak: spectesting a patch for it now :) 21:03
21:05 vinian_ joined
masak \o/ 21:05
dalek kudo/nom: 4a4601d | jnthn++ | src/Perl6/Actions.pm:
Make sure embedded blocks in strings get the correct lexical scope.
21:09
jnthn cognominal: le bug est vraiment fixed :) 21:11
Hopefully :)
21:11 Guest92238 joined
jnthn moritz: I closed it 21:13
Hmm. We need to recruit more test writers. The testneeded queue is quite big
I wonder if we can identify some suitable ones for GCI tasks?
cognominal jnthn++ # our $hero 21:16
21:17 spine left
masak GCI tasks for testneeded is a great idea. 21:24
21:32 donri joined 21:41 MayDaniel left 21:43 Ingis-Kahn left 21:51 mj41 joined 21:52 Sarten-X left 21:59 Sarten-X joined 22:13 vmspb joined, packetknife joined 22:16 packetknife left 22:20 mdxi joined 22:40 alvis joined 22:45 Ingis joined 22:46 Moukeddar left 23:00 mj41 left 23:07 zby_home left 23:18 daxim left, daxim joined 23:35 Guest2721 left 23:37 vmspb left
masak 'night, #perl6 23:51