Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2011-10-23

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:01 lue threads as in a computer's, right? (/me only knows them from extensively reading N64 system documentation)
00:03 Trashlord joined #perl6
00:09 Trashlord joined #perl6
00:13 flussence threads as in "if you segfault here, the rest of it comes crashing down" :)
00:15 lue Ooh, then I guess that was a segfault in the most recent Doctor Who episode...
00:18 sorear good * #perl6
00:19 lue hello sorear o/
00:27 colomon \o
00:27 colomon sorear: it seems declaring the basic arithmetic operators as multi subs is enough to bring niecza to its knees
00:28 sorear I'm not suprised
00:30 sorear so I'm now awake and have no remaining major obligatons today.  perl6 time :D
00:30 Trashlord joined #perl6
00:30 colomon \o/
00:32 colomon huh.  I tried making just infix:<+> and infix:<*> multi, but it still worked.  But if you make all of infix:<->, infix:</>, infix:<%>, and infix:<**> multi too, "mono run/Niecza.exe" just hangs.
00:34 sorear phenny: tell masak to read about --author and --date in git-commit(1)
00:34 phenny sorear: I'll pass that on when masak is around.
00:34 Trashlord joined #perl6
00:39 colomon It's multi sub infix:</>  that's the culprit, it seems
00:47 cyfi joined #perl6
00:47 colomon crap.  you get the command line with + - * multi, but t/fudgeandrun t/spec/S03-metaops/reduce.t just hangs.  sigh.
00:54 sorear colomon: can you actually do any math that way?
00:54 sorear I'm suprised it works at all
00:54 Trashlord joined #perl6
00:54 sorear and it'll definitely be very slow - niecza's inlining mechanism doesn't work with multis yet
00:54 colomon ah.
00:55 colomon well, I guess I won't be fixing this bug tonight, then.
00:59 colomon the good news: my wife just declared she is too tired to watch the dreary romantic comedy we were just watching, so I'm able to switch to the football game.  :)
01:00 lue .oO(You can't be watching it *that* closely if you have time for #perl6)
01:02 colomon it wasn't the sort of film that required close watching.
01:02 colomon in fact, it was the sort of film that was worse the closer you were paying attention, I think.
01:06 Trashlord joined #perl6
01:15 wolfman2000 joined #perl6
01:16 Trashlord joined #perl6
01:18 [Coke] joined #perl6
01:23 daniel-s joined #perl6
01:25 [Coke] joined #perl6
01:27 Trashlord joined #perl6
01:27 masonkramer joined #perl6
01:27 tokuhiro_ joined #perl6
01:28 sorear heh, the issue was I broke C3
01:29 sorear or did I?
01:34 [Coke] joined #perl6
01:36 sorear ...yes, I did.
01:36 sorear disagrees with Perl5's C3
01:40 Trashlord joined #perl6
01:40 [Coke] joined #perl6
01:43 dalek niecza/serialize: 049b617 | sorear++ | lib/ObjModel.cs:
01:43 dalek niecza/serialize: Fix misreimplementation of C3 MRO
01:43 dalek niecza/serialize: review: https://github.com/sorear/niecza/commit/049b6174a8
01:48 [Coke] joined #perl6
01:54 [Coke] joined #perl6
01:54 Trashlord joined #perl6
02:02 [Coke] joined #perl6
02:10 Trashlord joined #perl6
02:11 dalek niecza/serialize: a3850e3 | sorear++ | lib/Cursor.cs:
02:11 dalek niecza/serialize: Reimplement LTM handling for parametric role variables
02:11 dalek niecza/serialize: review: https://github.com/sorear/niecza/commit/a3850e36ee
02:11 sorear \o/ All tests successful.
02:11 sorear now for the things that test.pl (deliberately) doesn't test..
02:15 Transformer joined #perl6
02:18 Transformer left #perl6
02:25 Trashlord joined #perl6
02:32 colomon sorear: If you're there at the moment, any idea how to get access to http://msdn.microsoft.com/en-us/library/microsoft.visualbasic.fileio.filesystem(v=vs.110).aspx (FileSystem class) from mono?
02:33 colomon I'm trying to get at a mkdir command (like FileSystem.MkDir)
02:34 colomon hmmm, maybe System.IO.Directory.CreateDirectory instead?
02:35 sorear yes, use System.IO.Directory
02:35 * sorear wanders back
02:36 colomon sorear++
02:36 Trashlord joined #perl6
02:42 benabik joined #perl6
02:44 dalek niecza: 8b9e1af | (Solomon Foster)++ | lib/ (2 files):
02:44 dalek niecza: Add simple form of mkdir.
02:44 dalek niecza: review: https://github.com/sorear/niecza/commit/8b9e1afff0
02:49 Trashlord joined #perl6
03:05 Trashlord joined #perl6
03:17 uasi joined #perl6
03:20 Trashlord joined #perl6
03:37 Trashlord joined #perl6
03:45 skangas joined #perl6
03:55 Trashlord joined #perl6
04:06 dalek roast: 02c1b47 | Coke++ | S0 (5 files):
04:06 dalek roast: rakudo fudging
04:06 dalek roast: review: https://github.com/perl6/roast/commit/02c1b47f8e
04:15 Trashlord joined #perl6
04:23 cyfi joined #perl6
04:29 dalek rakudo/nom: 1937529 | Coke++ | t/spectest.data:
04:29 dalek rakudo/nom: run fudged tests
04:29 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1937529da8
04:36 aindilis joined #perl6
04:42 Trashlord joined #perl6
04:45 thou joined #perl6
04:46 Trashlord joined #perl6
04:48 skangas joined #perl6
05:00 uasi joined #perl6
05:04 Trashlord joined #perl6
05:17 orafu joined #perl6
05:20 Trashlord joined #perl6
05:24 Trashlord joined #perl6
05:47 Trashlord joined #perl6
05:51 sorear perl6: say 5 || 2 ?? 1 !! 0;
05:51 p6eval pugs b927740, rakudo 193752, niecza v10-60-g8b9e1af: OUTPUT«1␤»
05:56 cognominal___ joined #perl6
05:58 cognominal___ joined #perl6
06:00 Trashlord joined #perl6
06:04 GlitchMr joined #perl6
06:15 kaare_ joined #perl6
06:23 dalek niecza/serialize: d0a95e5 | sorear++ | / (6 files):
06:23 dalek niecza/serialize: Reimplement eval.  Currently breaks stash merging when used
06:23 dalek niecza/serialize: review: https://github.com/sorear/niecza/commit/d0a95e56a5
06:29 drbean joined #perl6
06:31 dukeleto joined #perl6
06:34 Trashlord joined #perl6
06:39 Trashlord joined #perl6
06:42 wamba joined #perl6
07:01 Trashlord joined #perl6
07:15 Trashlord joined #perl6
07:20 SHODAN joined #perl6
07:31 kfo_ joined #perl6
08:04 wk joined #perl6
08:05 snarkyboojum what's the time line for current master to get back to the kind of regex support that ng enjoyed?
08:07 snarkyboojum I ask, because this lack of regex goodness is blocking most of my private projects currently - and nom rocks, so I want to use it ;)
08:09 cognominal___ joined #perl6
08:10 tadzik we're blocking on pmichaud++
08:12 im2ee joined #perl6
08:23 Woodi Hi today :)
08:24 Woodi again about git/rakudo/nqp... cat rakudo/tools/build/NQP_REVISION -> 2011.09-31-gd2d759f
08:24 Woodi cd nqp ; git log | grep gd2d759f -> null
08:25 Woodi it means: git log do not look enough long in back ? or other branch or something ?
08:26 uasi joined #perl6
08:26 moritz Woodi: the leading 'g' is not part of the sha1
08:27 drbean joined #perl6
08:28 Woodi oops :) didn't know that...
08:29 Woodi now works :) thanx
08:32 grondilu joined #perl6
08:32 grondilu I wrote four sentences to help remember operator precedence in Perl6
08:34 grondilu http://s0.barwen.ch/~grondilu/methodist.txt
08:35 sirmacik http://s0.barwen.ch/~grondilu/methodist.txt
08:35 sirmacik http://s0.barwen.ch/~grondilu/methodist.txt
08:35 sirmacik http://s0.barwen.ch/~grondilu/methodist.txt
08:35 sirmacik ops, sorry ;x
08:35 grondilu (that was weird)
08:35 moritz nice :-)
08:36 grondilu it almost sound like a poem, doesn't it?  :)
08:36 sirmacik grondilu: I'm not used to putty :/
08:51 cognominal_ joined #perl6
09:08 snarkyboojum sirmacik: enjoyable read :D
09:09 snarkyboojum "tights" == "tightens"?
09:16 PacoLinux joined #perl6
09:17 manildomin joined #perl6
09:17 manildomin hi everyone
09:18 tadzik hi manildomin
09:18 manildomin I am reading Using Perl6 but I've got a few issues with the first example
09:19 manildomin can you give me some help?
09:21 snarkyboojum manildomin: I reckon you should just ask ;)
09:22 manildomin ok, I have tried to run the first example in the book "Using Perl6", which is about parsing a file containing scores of a table tennis tournament
09:22 manildomin when I try to run it with "perl6 test.pl", I get:
09:22 manildomin Use of uninitialized value in numeric contextUse of uninitialized value in numeric context
09:23 manildomin and the code I strive to run is exactly the same as the code given in the book
09:23 tadzik it appears that the book examples need some review, ney? We should probably turn them into tests or such
09:24 tadzik manildomin: it may be that the code did not follow the latest compiler changes, sorry for that
09:24 tadzik I'll take a look at it now
09:24 manildomin ok thanks
09:24 manildomin I'm using rakudo 2011.09
09:25 tadzik manildomin: I just tried it and it works fine for me
09:25 Kivutarrr joined #perl6
09:25 tadzik the code starting with my $file  = open 'scores';, right?
09:26 manildomin no, mine start with "use v6;"
09:26 manildomin but the next line is the one you put
09:26 tadzik yeah, that's fine
09:26 tadzik use v6 doesn't really matter
09:26 tadzik manildomin: https://gist.github.com/1307166
09:27 tadzik I'm using a bit newer Rakudo, but I don't think that matters. Are you sure you're running the same code with the same data?
09:28 manildomin yes
09:28 manildomin I replaced my code with yours and I've got the same result
09:29 manildomin perl6 --version gives me:
09:29 manildomin This is perl6 version 2011.09 built on parrot 3.8.0 revision 0
09:29 tadzik snarkyboojum: do you have 2011.09 in handy, maybe?
09:29 tadzik sirmacik: or you?
09:30 snarkyboojum tadzik: nope - just latest master
09:30 tadzik manildomin: that may be the version issue then, do you haev a possibility to upgrade to 2011.10?
09:31 manildomin I will have to compile the new version manually then
09:31 colomon are you sure there's not an extra blank line or two at the end of the data file?
09:31 manildomin there are no extra blank lines
09:31 TiMBuS hey, is there a version of p6eval on github somewhere? i wanna run it on another server..
09:31 TiMBuS also hi
09:31 tadzik TiMBuS: isn't that perl6/evalbot or so?
09:32 moritz it is
09:32 TiMBuS probably!
09:32 snarkyboojum we should definitely have tests run as part of 'make'ing the book imo
09:32 TiMBuS is it safe or do i gotta jail it etc
09:32 moritz it's not safe at all.
09:32 TiMBuS :<
09:33 moritz I run it as a separate user in a chroot on a VM that isn't used for important stuff
09:35 TiMBuS i guess i might do that
09:36 xinming joined #perl6
09:36 alvis joined #perl6
09:37 MayDaniel joined #perl6
09:37 snarkyboojum manildomin: fwiw, I get errors trying to run that example too :)
09:37 manildomin ah
09:38 manildomin I will compile the latest rakudo release
09:38 snarkyboojum and my perl 6 isn't that old either
09:39 moritz works on current rakudo
09:40 moritz what's the error message you get?
09:40 snarkyboojum https://gist.github.com/1307178
09:40 tadzik trailing blank lines
09:41 tadzik oh, it's something different
09:42 masak morron, #perl6
09:42 phenny masak: 00:34Z <sorear> tell masak to read about --author and --date in git-commit(1)
09:43 masak sorear: I did, but decided against that option.
09:43 snarkyboojum tadzik: trailing blank lines?
09:43 masak mostly because it felt like I'd have to clear that before TheDamian before making commits in his name.
09:43 masak s:1st/before/with/
09:44 tadzik snarkyboojum: in scores, maybe?
09:44 snarkyboojum tadzik: nope
09:44 snarkyboojum tadzik: just using space in gist for clarity ;)
09:45 tadzik ok ;)
09:45 tadzik I should probably write a blogpost about MuEvent
09:47 mj41_nb joined #perl6
09:47 mj41 joined #perl6
09:48 snarkyboojum what's MuEvent? :D
09:48 tadzik yes, I should :)
09:48 tadzik this: https://gist.github.com/1305904
09:48 tadzik it's an anyevent lookalike
09:49 snarkyboojum ah - I thought it was a new cool Perl6 conference :D
09:49 snarkyboojum but this is a new cool anyevent lookalike
09:49 snarkyboojum awesome
09:51 masak we should totally have a MuEvent Perl 6 event ;)
09:51 tadzik :)
09:52 tadzik let's define it. Oh, wait
09:52 masak I object!
10:02 snarkyboojum tadzik: look forward to the post
10:02 masak man, Yudkowsky keeps rocking my world.
10:06 masak "If you want to sound deep, you can never say anything that is more than a single step of inferential distance away from your listener's current mental state." :)
10:06 tadzik heh
10:06 tadzik phenny: "mów do głupca mądrze a nazwie cię idiotą"?
10:06 phenny tadzik: "Speak to the wise fool and called you an idiot" (pl to en, translate.google.com)
10:06 tadzik not really
10:06 tadzik "speak wisely to the fool, and he'll call you an idiot"
10:10 masak maybe "wisely" could be taken as "taking more than a single step of inferential distance away from the fool's current mental state", then.
10:11 tadzik probably
10:11 masak I see the same things happening in understanding programming and design concepts.
10:11 masak first you need to understand that DRY is everything.
10:11 masak *then* you need to understand that DRY isn't everything. :)
10:12 masak but it's quite important to learn it in that order.
10:12 tadzik like with optimization
10:12 masak how is it like with optimization?
10:13 tadzik "don't do it", is the first rule
10:13 tadzik then, how do I wrap it in words
10:13 tadzik if you're wise enough to optimize correctly, then you're wise enough to know when to break the first rule
10:14 Mowah_ joined #perl6
10:15 masak rightright.
10:17 masak it's interesting what topics are like that, where people need to be *told* that they aren't competent enough to do a good enough job.
10:17 masak security/encryption seems to be another.
10:28 masak perl6: my $a = 1; my $b = 2; ($a, $b) = $b, $a; say $a; say $b
10:28 p6eval pugs b927740, rakudo 193752, niecza v10-60-g8b9e1af: OUTPUT«2␤1␤»
10:29 masak \o/
10:37 Grrrr joined #perl6
10:46 masak perl6: say 1 +^ 2 +^ 3
10:46 p6eval pugs b927740, rakudo 193752, niecza v10-60-g8b9e1af: OUTPUT«0␤»
10:46 masak perl6: say 1 +^ 4 +^ 5
10:47 p6eval pugs b927740, rakudo 193752, niecza v10-60-g8b9e1af: OUTPUT«0␤»
10:49 * masak wonders if it'd be worth it to manually translate his June blogging games into JavaScript, so they can be played online
10:51 masak maybe I should translate them into Dart. ;)
10:52 manildomin joined #perl6
10:52 manildomin I'm back
10:53 masak re-greetings, manildomin
10:53 manildomin I compiled an older version of rakudo (This is Rakudo Perl 6, version 2011.04 built on parrot 3.8.0 0) and the source code doesn't work either!!
10:53 manildomin I get :
10:53 manildomin Method 'split' not found for invocant of class ''   in <anon> at line 12:test.pl   in main program body at line 1:src/metamodel/RoleToInstanceApplier.nqp
10:53 masak yeah, I saw in the backlog that you had problems with the first example in the book.
10:54 masak allow me to try it out locally to see if I can reproduce your warnings.
10:54 manildomin yes
10:54 manildomin ok
10:54 masak I'm running Rakudo 2011.06 here, for some reason.
10:55 masak ooc, how did you copy the source code? from the PDF?
10:55 manildomin I wrote it myself
10:55 masak how diligent. :)
10:55 manildomin and I checked for errors
10:55 masak I'll take a shortcut and copy it from the source repository.
10:55 manildomin ok
10:57 masak hm. no warnings here.
10:57 masak how about I make a gist of the contents of my two files, and then you can compare at your leisure?
10:57 manildomin which version of parrot and rakudo do you have ?
10:57 manildomin ok
10:58 masak Rakudo 2011.06, and the Parrot that goes with that release, 3.5.0.
10:59 masak manildomin: https://gist.github.com/1307245
11:00 masak I didn't even de-indent things, so everything has a four space indentation. but I don't think it much matters one way or another.
11:01 manildomin thanks I try it
11:02 masak the script also works fine on current HEAD revision. no warnings.
11:08 manildomin it works with (Rakudo Perl 6, version 2011.04 built on parrot 3.8.0 0)
11:08 manildomin I understood the problem:
11:09 manildomin I have a blank line at the beginning of the 'scores' files
11:09 manildomin how stupid i am
11:09 masak not to worry.
11:09 masak you found the problem :)
11:09 manildomin I will try this again with the newer rakudo 2011.09
11:10 manildomin thanks
11:10 masak I think it'll work there. it works fine on HEAD.
11:10 masak no problemo.
11:12 cognominal___ joined #perl6
11:13 masak std: my @names; my @sorted = @names.sort({ %sets{$_} }).sort({ %matches{$_} }).reverse; say @sorted.perl
11:13 p6eval std 580b69a: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable %sets is not predeclared at /tmp/6FwKmw6DRP line 1:�------> [32mmy @names; my @sorted = @names.sort({ [33m�[31m%sets{$_} }).sort({ %matches{$_} }).reve[0m�Variable %matches is not predeclared at /tmp/6FwKmw6DRP line 1:�----…
11:14 masak std: my (@names, %sets, %matches); my @sorted = @names.sort({ %sets{$_} }).sort({ %matches{$_} }).reverse; say @sorted.perl
11:14 p6eval std 580b69a: OUTPUT«ok 00:01 125m␤»
11:14 masak std: my (@names, %sets, %matches); my @sorted = @names.sort: { %sets{$_} }.sort: { %matches{$_} }.reverse; say @sorted.perl
11:14 p6eval std 580b69a: OUTPUT«ok 00:01 125m␤»
11:14 masak std: my (@names, %sets, %matches); @names ==> sort: { %sets{$_} } ==> sort: { %matches{$_} } ==> reverse ==> my @sorted; say @sorted.perl
11:14 p6eval std 580b69a: OUTPUT«[31m===[0mSORRY![31m===[0m�Illegal redeclaration of symbol 'sort' (see line 1) at /tmp/YWCtyqEueC line 1:�------> [32mnames ==> sort: { %sets{$_} } ==> sort: [33m�[31m{ %matches{$_} } ==> reverse ==> my @sor[0m�Preceding context expects a term, but found infi…
11:15 masak std: my (@names, %sets, %matches); @names ==> sort { %sets{$_} } ==> sort { %matches{$_} } ==> reverse ==> my @sorted; say @sorted.perl
11:15 p6eval std 580b69a: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix ==> instead at /tmp/_6mh8ci_7D line 1:�------> [32m} ==> sort { %matches{$_} } ==> reverse [33m�[31m==> my @sorted; say @sorted.perl[0m�Parse failed�FAILED 00:01 126m�»
11:15 masak std: my (@names, %sets, %matches); @names ==> sort({ %sets{$_} }) ==> sort({ %matches{$_} }) ==> reverse ==> my @sorted; say @sorted.perl
11:15 p6eval std 580b69a: OUTPUT«[31m===[0mSORRY![31m===[0m�Preceding context expects a term, but found infix ==> instead at /tmp/OndsN7L2vG line 1:�------> [32m ==> sort({ %matches{$_} }) ==> reverse [33m�[31m==> my @sorted; say @sorted.perl[0m�Parse failed�FAILED 00:01 126m�»
11:15 masak hm.
11:26 im2ee nom: class a { method abc ( @l ) { say @l.perl; };  }; my $a = a.new; $a.abc(<a b c>);
11:26 p6eval nom 193752: OUTPUT«("a", "b", "c")␤»
11:26 im2ee nom: class a { method abc ( @l is rw ) { say @l.perl; };  }; my $a = a.new; $a.abc(<a b c>);
11:26 p6eval nom 193752: OUTPUT«("a", "b", "c")␤»
11:30 cognominal___ joined #perl6
11:31 SHODAN joined #perl6
11:35 whiteknight joined #perl6
11:38 Psyche^ joined #perl6
11:40 araujo joined #perl6
11:42 Manildomin joined #perl6
11:42 Manildomin hi again
11:42 Manildomin I confirm that with rakudo 2011.09, the code works too
11:44 cognominal___ joined #perl6
11:48 masak \o/
12:07 im2ee masak, that bug, which we found yesterday is repaired? :)
12:08 flussence anyone remember that thing TimToady++ said about most of the helpful errors just being TTIAR rephrased in context? Maybe that'd be a good idea for undef errors too...
12:09 snarkyboojum I definitely found the first book example breaking on my Rakudo, until I updated to latest nqp, parrot, rakudo
12:09 snarkyboojum fwiw
12:09 masak im2ee: you will have to be more specific :) which bug?
12:10 masak https://rt.perl.org/rt3/Ticket/Display.html?id=101964 ?
12:10 tokuhiro_ joined #perl6
12:11 im2ee masak, yes. This one. :)
12:12 masak it hasn't been fixed yet. but I could debug it with you, if you want.
12:12 overrosy joined #perl6
12:12 im2ee masak, it'll be great, if so. :)
12:12 im2ee masak, but.. how? :)
12:13 masak well, we should probably start by generating out the PAST.
12:14 masak the interesting question is "why do attribute arrays behave differently when passed to a method?"
12:14 im2ee Right.
12:14 masak nom: class A { has @!c is rw; method foo { self!bar(@!c) };
12:14 p6eval nom 193752: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 1␤»
12:15 masak hrm.
12:15 masak nom: class A { has @!c is rw; method foo { self!bar(@!c) }; method !bar(@r is rw) { say "OH HAI" } }; A.new.foo
12:15 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/qIZtOSVxUz:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/qIZtOSVxUz:1␤  in block <anon> at /tmp/qIZtOSVxUz:1␤  in <anon> at /tmp/qIZtOSVxUz:1␤»…
12:15 masak nom: class A { has @!c is rw; method foo { bar(@!c) } }; sub bar(@r is rw) { say "OH HAI" }; A.new.foo
12:15 p6eval nom 193752: OUTPUT«OH HAI␤»
12:15 masak so it has to be a method.
12:16 masak nom: class A { has @!c is rw; method foo { self.bar(@!c) }; method bar(@r is rw) { say "OH HAI" } }; A.new.foo
12:16 p6eval nom 193752: OUTPUT«OH HAI␤»
12:16 Thrawn joined #perl6
12:16 masak and it has to be a private method.
12:16 masak then my hunch is that we'll find the problem somewhere in the code that handles private method invocation.
12:17 Thrawn hey everyone
12:17 im2ee Where is it?
12:18 im2ee masak, will it be rakudo's code?
12:19 Kivutarrr left #perl6
12:24 masak im2ee: the bug is inside Rakudo, most likely, yes.
12:25 cognominal joined #perl6
12:46 Manildomin joined #perl6
12:50 mj41 joined #perl6
12:50 tokuhiro_ joined #perl6
12:55 finanalyst joined #perl6
12:56 finanalyst rakudo: my $x = 1.2345678912
12:56 p6eval rakudo 193752:  ( no output )
12:56 finanalyst rakudo: my $x = 1.234567891
12:56 p6eval rakudo 193752:  ( no output )
12:57 finanalyst rakudo: my $x = 1.2345678912 ; $x.say
12:57 p6eval rakudo 193752: OUTPUT«1.2345678912␤»
12:57 finanalyst rakudo: my $x = 1.2345678912345 ; $x.say
12:57 p6eval rakudo 193752: OUTPUT«1.2345678912345␤»
12:59 finanalyst hello. I seem to have a problem on rakudo on my machine that is not happening here
13:00 finanalyst I am getting an error message: "no bigint lib loaded" when i assign 1.2345678912 to a variable
13:00 masak that's because you didn't compile Parrot with the biging library.
13:00 masak bigint*
13:01 finanalyst i used the standard perl Configure.pl --gen-parrot
13:01 finanalyst what else do i need to add?
13:01 masak which OS/distro are you on?
13:01 finanalyst linux ubuntu
13:02 masak ISTR there's a package you download to get the bigint functionality.
13:02 masak but I might be mistaken.
13:02 finanalyst its never happened before
13:02 masak I can't seem to get at the IRC logs right now to confirm this.
13:03 finanalyst and perl6 code that was working stopped working
13:04 finanalyst couldnt work out why. seems a simple multiplication failed because there was a number with lots of decimal positions
13:04 gfldex finanalyst: 32 or 64bit?
13:04 finanalyst i dont even need the precision: the data was generated by perl 5 script
13:05 flussence reproducible on 32bit
13:05 finanalyst does it matter 32/64 bit?
13:05 finanalyst why should $x=1.234567891 be acceptible, but $x=1.2345678912 not?
13:06 flussence > my $x = 1.2345678912  ␤bigint_get_long: number too big
13:06 flussence version string here - This is perl6 version 2011.09-173-g5af761e built on parrot 3.9.0 revision RELEASE_3_9_0
13:07 donri joined #perl6
13:08 finanalyst I have: This is perl6 version 2011.10-7-g142c416 built on parrot 3.9.0 revision RELEASE_3_9_0
13:08 flussence parrot 3.9 bug?
13:09 finanalyst so why do i get it on my computers (both home and work) and not reproducible here?
13:09 flussence p6eval runs on x86-64
13:09 Manildomin I've got another issue with another piece of code from the book "Using Perl6" ><
13:09 flussence there's lots of problems with numeric data on 32bit right now
13:09 Manildomin can someone try to run the piece of code I put there : http://pastebin.com/PNLUTxvy ?
13:10 Manildomin when I try it I have no error message but the program does nothing and never ends
13:10 finanalyst flussence: I have a samsung laptop. is that 32 or 64 bit? how do i test?
13:11 flussence finanalyst: if this hangs on the REPL, it's 32-bit:
13:11 Manildomin uname -m in the terminal to know whether it's 32 or 64 bits
13:11 flussence perl6: say now
13:11 p6eval rakudo 193752: OUTPUT«Instant:1319375514.09358␤»
13:11 p6eval ..pugs b927740: OUTPUT«*** No such subroutine: "&now"␤    at /tmp/aCbE1Fx9AJ line 1, column 5 - line 2, column 1␤»
13:11 p6eval ..niecza v10-60-g8b9e1af: OUTPUT«Instant.new(...)␤»
13:12 finanalyst uname -m => i686
13:12 Manildomin 32 bits
13:12 finanalyst thanx
13:13 finanalyst how far back do i need to go to get a rakudo that starts working again? Lots of problems and I wanted this code to work
13:14 finanalyst that is, working code stopped working fairly recently
13:16 flussence try 2011.07 or 04 from https://github.com/rakudo/star/downloads
13:16 flussence Manildomin: on line 8 you have a space between - and ' that shouldn't be there
13:17 flussence oh wait, never mind
13:17 flussence that code all looks right to me.
13:18 Manildomin ok
13:18 jnthn finanalyst: If you are mostly concerned with stuff keeping working, then the star releases are the best bet. There's a reason we haven't done one from nom yet: as you've noticed, there are some areas where things aren't working as well as they should be yet (of note, protoregexes and some numeric bits)
13:18 phenny jnthn: 21 Oct 21:02Z <[Coke]> tell jnthn --gen-parrot is definitely easier with activestate if you're using msvc.
13:18 phenny jnthn: 21 Oct 21:08Z <[Coke]> tell jnthn (except that the build failed. hurm.)
13:18 phenny jnthn: 22 Oct 01:27Z <[Coke]> tell jnthn there are like 4 tickets that all involve weird issues when defining a sub called "if".
13:18 phenny jnthn: 22 Oct 11:21Z <masak> ask jnthn if I read dispatch:<.*> correctly, callsame/nextsame has nothing whatsoever to do with .* dispatch. is that right?
13:18 jnthn phenny: tell masak yes
13:18 phenny jnthn: I'll pass that on when masak is around.
13:19 jnthn masak: The reason being that whether a method chooses to defer is a decision of the method itself - that is, an implementation detail of it. .+ and .* are saying "I want to call all method up the chain". You shouldn't be concerning yourself with their internal implementation details.
13:21 masak phenny: you don't need to tell me yes.
13:21 phenny masak: 13:18Z <jnthn> tell masak yes
13:21 masak jnthn: makes sense.
13:22 masak jnthn: so there are only two types of dispatchers, then. not three.
13:22 masak the (outer) mro dispatchers, and the (inner) proto dispatchers.
13:22 masak no, wait. there's wrapper dispatchers too, I guess.
13:23 flussence rakudo: my $bar-graph = 'X' x *; say $bar-graph(5)
13:23 jnthn .?, .* and .+ are just different outer mro dispatchers really.
13:23 p6eval rakudo 193752: OUTPUT«XXXXX␤»
13:23 finanalyst jnthn: thanx
13:23 masak if they're dispatchers, they're dispatchers without any effect on 'nextsame' et al.
13:23 masak I always thought all dispatchers had that.
13:24 jnthn masak: I'm not sure what you mean by "without any effect"
13:25 jnthn Oh, I think I see what you might be getting at...
13:25 masak oh phew.
13:25 masak because it's what we were just talking about ;)
13:25 masonkramer joined #perl6
13:26 jnthn masak: Is there something you'd expect to work that doesn't?
13:26 jnthn I'd not expect nextsame et al to mean you don't visit things in the "top level" list of things .+ and .* work through just because you deferred to them
13:27 jnthn But the individual methods, when visited, should be able to nextsame as an implementation detail. If they can't, then that's a bug.
13:28 djanatyn|afk joined #perl6
13:32 masak jnthn: I'm just trying, as I have been for the past three years, to build an accurate model of 'nextsame' et al.'s semantics. without that, I won't feel comfortable using them, or explaining them to others.
13:35 masak for some reason I had assumed until now that .* would have something to do with nextsame. I see now that it doesn't.
13:35 jnthn masak: Well, generally you should be able to work out what nextsame will do from relatively local context
13:35 masak aye.
13:36 jnthn If you're in a multi, then you know it's going to defer to the next multi candidate. If you're in an only method, you know it's going to defer to the next thing in the MRO. If you're in a wrapper, you know it's going to go to the inner wrapper or original.
13:37 masak jnthn: on a different note: im2ee and I are investigating https://rt.perl.org/rt3/Ticket/Display.html?id=101964 -- we've found so far that in dispatch:<!> in core/Mu.pm, @pos is empty. I suspect that there's something odd with the PAST.
13:37 masak care to have a look?
13:37 jnthn The problem with tying it to .* and .+ is that you as the method don't know that you're under a different dispatcher than the one you expected, so it's probably better to leave the two disassociated, and each method call gets a "fresh"dispatcher.
13:38 jnthn (for the purposes of nextsame)
13:38 masak I agree.
13:38 masak the more predictable, the better.
13:39 jnthn (101964) weird.
13:40 jnthn nom: class A { has @!c is rw; method foo { self!bar(@!c) }; method !bar(@r is rw) { say "OH HAI" } }; A.new.foo
13:40 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/RoP9N2aq9m:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/RoP9N2aq9m:1␤  in block <anon> at /tmp/RoP9N2aq9m:1␤  in <anon> at /tmp/RoP9N2aq9m:1␤»…
13:40 jnthn nom: class A { has @!c is rw; method foo { self!bar(@!c) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:40 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/0Ac5k5z8qO:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/0Ac5k5z8qO:1␤  in block <anon> at /tmp/0Ac5k5z8qO:1␤  in <anon> at /tmp/0Ac5k5z8qO:1␤»…
13:40 jnthn nom: class A { has @!c; method foo { self!bar(@!c) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:40 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/nOzwVfg1FQ:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/nOzwVfg1FQ:1␤  in block <anon> at /tmp/nOzwVfg1FQ:1␤  in <anon> at /tmp/nOzwVfg1FQ:1␤»…
13:40 jnthn nom: class A { has @!c; method foo { self!A::bar(@!c) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:40 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/eeBSmJQvqW:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/eeBSmJQvqW:1␤  in block <anon> at /tmp/eeBSmJQvqW:1␤  in <anon> at /tmp/eeBSmJQvqW:1␤»…
13:41 masak we've isolated the necessary ingredients: private method call, array attribute.
13:41 masak hm, did I ever check whether't needed to be an array?
13:41 masak yes, I think I did.
13:42 jnthn yeah, think I see it
13:42 masak wow.
13:42 masak do explain.
13:43 jnthn nom: sub foo($a, :$b) { say "$a $b" }; sub bar(|$c) { foo(|$c) }; bar(1, :b<2>)
13:43 p6eval nom 193752: OUTPUT«1 2␤»
13:44 jnthn The dispatchers should be using |$c to get the args to pass on
13:44 jnthn But that wasn't implemented when they were written.
13:44 jnthn Which causes horrible wrongness.
13:45 masak nom: class A { has @!c; method foo { self!bar(@!c) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:45 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/uX2c_xedpk:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/uX2c_xedpk:1␤  in block <anon> at /tmp/uX2c_xedpk:1␤  in <anon> at /tmp/uX2c_xedpk:1␤»…
13:45 jnthn You don't need the attribute.
13:45 masak oh?
13:45 masak I haven't been able to produce it without the attribute.
13:45 jnthn nom: class A { method foo { self!bar([]) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:45 p6eval nom 193752: OUTPUT«OH HAI␤»
13:45 jnthn hm
13:46 masak nom: class A { method foo { my @c; self!bar(@c) }; method !bar(@r) { say "OH HAI" } }; A.new.foo
13:46 p6eval nom 193752: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method bar at /tmp/bSxfrTQ8VY:1␤  in method dispatch:<!> at src/gen/CORE.setting:710␤  in method foo at /tmp/bSxfrTQ8VY:1␤  in block <anon> at /tmp/bSxfrTQ8VY:1␤  in <anon> at /tmp/bSxfrTQ8VY:1␤»…
13:46 masak oh.
13:46 jnthn Right.
13:46 masak there we go :)
13:46 masak whassedifference?
13:46 masak between [] and @c, I mean.
13:46 jnthn One is marked with flatten
13:47 masak ah.
13:47 masak eventually I'll get the hang of flatten, I'm sure.
13:47 masak ok, is there anything I can do to patch this?
13:48 masak change *@pos to |$c ?
13:48 jnthn spectesting a patch now
13:51 jnthn crap, I mussed it to master, not nom
13:51 dalek rakudo: d7f45ff | moritz++ | src/core/Cool.pm:
13:51 dalek rakudo: Cool.eval
13:51 dalek rakudo: review: https://github.com/rakudo/rakudo/commit/d7f45ff8cf
13:51 masak jnthn: good thing there's cherry-pick.
13:52 jnthn think I stopped it just in time
13:53 masak :)
13:54 dalek rakudo/nom: ca26563 | jnthn++ | src/core/Mu.pm:
13:54 dalek rakudo/nom: Fix various dispatchers.
13:54 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ca26563fe7
13:54 jnthn ...mussed...messed + pushed :)
13:54 agentzh joined #perl6
13:55 jnthn .oO( dammit, my fingers pun when my brane is too tired to... )
13:55 masak it's interesting that dalek's reaction to your mussing was to publish the last commit that went into master, one from 19 September.
13:56 jnthn hm, I guess I shoulda tested that the patch actually fixed the bug
13:56 jnthn > class A { has @!c is rw; method foo { self!bar(@!c) }; method !bar(@r is rw) { say "OH HAI" } }; A.new.foo
13:56 jnthn yes, it does :)
13:56 jnthn OH HAI
13:57 masak \o/
13:57 masak jnthn++
13:57 masak ah, so anything empty that flattened turned into 0 positional parameters?
13:57 masak I think I get it now.
13:58 Manildomin joined #perl6
13:58 jnthn .oO( pushed to wrong branch, didn't actually check my patch fixed the bug...yeah, maybe I shouldn't touch my keyboard much more today :) )
13:58 jnthn masak: yes, that.
13:58 masak yay
13:58 jnthn ticket updated
13:59 jnthn oh my
13:59 jnthn nom: say 699 - 102
13:59 p6eval nom 193752: OUTPUT«597␤»
13:59 jnthn Wow. :)
14:01 jnthn It's also a nice sign that the oldest bug on the final page on RT is from 3 months ago
14:01 jnthn Put another way, many new bugs getting filed are getting dealt with.
14:02 im2ee jnthn++, what is |$c? :)
14:02 jnthn im2ee: It means "put all the arguments not bound yet into a Capture
14:02 jnthn "
14:02 jnthn (when ti's in the signature)
14:03 jnthn When it's in a call it means "take all the arguments from this capture and flatten them into this call's arguments"
14:04 im2ee Thanks jnthn :)
14:04 im2ee Hmm, what means the "proto" keyword before a method?
14:05 overrosy joined #perl6
14:06 djanatyn|afk joined #perl6
14:07 jnthn im2ee: Means that it is a dispatcher; you normally don't write one as writing multi methods causes a proto to be auto-generated for you.
14:07 masak im2ee: it means that method dispatches to several 'multi' methods, possibly in subclasses.
14:07 * jnthn afk for a little bit
14:08 im2ee Thanks ! :)
14:21 overrosy joined #perl6
14:23 jfried joined #perl6
14:31 wolfman2000 joined #perl6
14:40 static_perl joined #perl6
14:48 jaldhar joined #perl6
14:51 overrosy joined #perl6
14:53 * moritz was kinda surprised to see a commit to rakudo/master, and even more surprised who the author was :-)
14:54 masak just a dalek hiccup ;)
14:54 moritz my first thought was that maybe somebody had cherry-picked a commit of mine to master
14:57 mj41 joined #perl6
14:59 jnthn I think it was a jnthn hiccup... :)
15:11 jnthn grr, I can't reproduce the Buf segfault here
15:11 jnthn I can, it seems, make Buf a bunch faster though...
15:13 grondilu joined #perl6
15:14 _jaldhar joined #perl6
15:14 jaldhar joined #perl6
15:16 moritz that would be welcome too :-)
15:16 moritz jnthn: fwiw I've re-coded the same logic in PIR, and there it didn't segfault
15:17 jnthn moritz: I can't make it segfault on this box :(
15:18 Gothmog_ joined #perl6
15:19 moritz jnthn: http://nopaste.snit.ch/89845 is the backtrace I get
15:21 jnthn wow.
15:21 bluescreen10 joined #perl6
15:22 moritz what's impressive about it? that it's not the GC?
15:22 masak ;)
15:23 jnthn hmm
15:23 jnthn In VTABLE INTVAL get_integer_keyed_int(INTVAL position) it dereferences content without ensuring it's not null.
15:24 [Coke] joined #perl6
15:24 jnthn oh, also
15:25 jnthn set_string_native is wrong.
15:25 jnthn It doesn't zero allocated_size
15:26 moritz it has
15:26 moritz SET_ATTR_allocated_size(INTERP, SELF, 0);
15:26 jnthn oh, yes
15:27 jnthn ah, it's not that then.
15:28 * moritz would love to see mls_++' exception and ENTER/LEAVE work merged
15:29 jnthn moritz: I've got plenty of time in the next couple of days. I'll look at it then.
15:30 jnthn I may look later today, but I'm a little headachey and can't concentrate as much as that patch needs
15:31 dual joined #perl6
15:35 moritz jnthn: don't hurry, BUT DO IT SOON :-)
15:35 jnthn :P
15:35 jnthn Got a patch that makes that code get up to the first 25 iterations 3 times faster.
15:35 jnthn spectesting it now
15:36 * benabik has had a boss tell him "no hurry, but we needed it by the end of today."
15:36 jnthn Runs in 9ish seconds instead of 27
15:36 jnthn That's still too slow but it's an improvement.
15:36 moritz \o/
15:36 * moritz wonders what stupid things he did
15:36 jnthn .keys
15:37 jnthn Granted this was almost certainly written before we had nice things like native ints so we could do fast lops
15:38 jnthn *loops
15:38 dalek nqp: 5ed5bc0 | jnthn++ | src/PAST/NQP.pir:
15:38 dalek nqp: Fill out nqp op space a little more.
15:38 dalek nqp: review: https://github.com/perl6/nqp/commit/5ed5bc0664
15:41 dalek rakudo/nom: 977b33b | jnthn++ | tools/build/NQP_REVISION:
15:41 dalek rakudo/nom: Bump NQP revision.
15:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/977b33b11f
15:41 dalek rakudo/nom: 7ac6d1e | jnthn++ | src/core/Buf.pm:
15:41 dalek rakudo/nom: Improve performance of Buf creation and listification.
15:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/7ac6d1ea6d
15:42 abercrombie joined #perl6
15:43 kemit_khulet joined #perl6
16:02 moritz jnthn: I just wondered if we have a nice, efficient path for Array.[int]
16:03 jnthn moritz: not yet
16:05 * moritz starts with a small benchmark
16:05 moritz nom: multi f(Int $x) { 'Int' }; multi f (int $x) { 'int' }; say f 3
16:05 p6eval nom 7ac6d1: OUTPUT«int␤»
16:05 moritz nom: multi f(Int $x) { 'Int' }; multi f (int $x) { 'int' }; say f 3 + 3
16:05 p6eval nom 7ac6d1: OUTPUT«int␤»
16:05 moritz nom: multi f(Int $x) { 'Int' }; multi f (int $x) { 'int' }; say f 3 + 3 * 5
16:05 jnthn Yes but...it's a method call
16:05 p6eval nom 7ac6d1: OUTPUT«int␤»
16:05 moritz I know
16:05 jnthn The optimizer can't resolve those
16:06 jnthn I think at the moment the assumption is "we have to box"
16:06 moritz but the dispatcher can distinguish them, right?
16:06 jnthn Hm
16:06 jnthn Potentially
16:06 jnthn It should be doable now
16:06 jnthn I'll have to check exactly what it's doing with code-gen there.
16:07 moritz I'm thinking of a multi method postcifucmix:<[ ]>(int $pos) is rw { ... }
16:07 jnthn *nod*
16:07 moritz in Any
16:07 moritz and a List.at_pos(int)
16:09 jnthn Sounds sane.
16:09 jnthn Just need to check the generated code to ensure it's as efficient as we'd actually like it to be.
16:09 moritz well, I'd benchmark :-)
16:09 jnthn sure :)
16:10 jnthn Well, looking at the generated PIR will probably be telling too :)
16:10 jnthn Feel free to work on it; I'm happy to help if the code gen side needs tweaks.
16:10 jnthn I think there's still some bits from the time when the binder and multi dispatcher didn't know how to handle natives.
16:12 jnthn OK, got some more speedups :)
16:12 jnthn Got it over 5 times faster getting up to 25 now :)
16:13 moritz it seems we will box eventually, because I'm not going to write native int variants of all the methods involved (exists, gimme)
16:14 jnthn *nod*
16:15 moritz but we can save a method call to .Int at least
16:15 jnthn Well, checking if $!items is already long enough to give us the index we want without having to gimme is probably doable without boxing too
16:16 dalek rakudo/nom: fc3d314 | jnthn++ | src/core/Buf.pm:
16:16 dalek rakudo/nom: Eliminate unrequired slurpiness.
16:16 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fc3d31425d
16:16 dalek rakudo/nom: f7995a5 | jnthn++ | src/core/metaops.pm:
16:16 dalek rakudo/nom: Optimize reduction meta-op by avoiding inferior runloop for boolification - just do what .Bool does anyway.
16:16 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f7995a5538
16:16 dalek rakudo/nom: f7d3d5d | jnthn++ | src/core/List.pm:
16:16 dalek rakudo/nom: Optimize push a little.
16:16 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f7d3d5d3bc
16:16 dalek rakudo/nom: 81ce668 | jnthn++ | src/core/Buf.pm:
16:16 dalek rakudo/nom: Don't use .push in Buf.list when we already know exactly what index we're going to use.
16:17 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/81ce668bea
16:21 jnthn ooh, I got the segfault
16:22 jnthn Looks like memory corruption.
16:22 abercrombie Hi, is the lookaround not implemented yet in nom/rakudo?
16:22 tokuhiro_ joined #perl6
16:23 tadzik lookahead is, methinks
16:24 abercrombie Oh, yes, I was tring to use <!before> and <?before>
16:24 [Coke] phenny: ask moritz if 5fe92c09 on roast is another example of the eval issue. (had to todo this for niecza.)
16:24 phenny [Coke]: I'll pass that on when moritz is around.
16:27 moritz [Coke]: no, eval_dies_ok needs to catch exceptions, and does
16:27 phenny moritz: 16:24Z <[Coke]> ask moritz if 5fe92c09 on roast is another example of the eval issue. (had to todo this for niecza.)
16:36 jaldhar joined #perl6
16:54 nebuchadnezzar joined #perl6
16:55 moritz .u plus minus
16:55 phenny U+00B1 PLUS-MINUS SIGN (±)
16:55 soh_cah_toa joined #perl6
16:57 dalek roast: 1c1df5b | Coke++ | S (3 files):
16:57 dalek roast: niecza fudging
16:57 dalek roast: review: https://github.com/perl6/roast/commit/1c1df5bced
16:59 dalek niecza: bacff10 | Coke++ | t/spectest.data:
16:59 dalek niecza: Skip this test.
16:59 dalek niecza:
16:59 dalek niecza: (too many failures, test has platform based skips instead of impl-based)
16:59 dalek niecza: review: https://github.com/sorear/niecza/commit/bacff109a5
17:01 dalek nqp: d7cec32 | jnthn++ | src/6model/reprs/P6opaque.c:
17:01 dalek nqp: Ensure we don't try to change the type of a type object.
17:01 dalek nqp: review: https://github.com/perl6/nqp/commit/d7cec329ed
17:01 dalek nqp: bbe37f3 | jnthn++ | src/6model/reprs/P6opaque.c:
17:01 dalek nqp: Ensure that when a type object is cloned, we don't lose the type object flag.
17:01 dalek nqp: review: https://github.com/perl6/nqp/commit/bbe37f36a9
17:01 dalek nqp: 7bc5fcd | jnthn++ | src/ops/nqp.ops:
17:01 dalek nqp: Add a missing write barrier.
17:01 dalek nqp: review: https://github.com/perl6/nqp/commit/7bc5fcdaae
17:06 dalek rakudo/nom: ecc293a | jnthn++ | src/ (2 files):
17:06 dalek rakudo/nom: Add write barriers in a couple of places they are potentially needed.
17:06 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ecc293ae8d
17:06 dalek rakudo/nom: ee65d38 | jnthn++ | tools/build/NQP_REVISION:
17:06 dalek rakudo/nom: Bump NQP_REVISION to get fix for the mixin to type object segfault issue.
17:06 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/ee65d38f3d
17:08 Chillance joined #perl6
17:11 arnsholt masak: Thanks for mentioning MJD's blog yesterday. Even though I probably don't have time to read all the archives =)
17:12 cognominal why List.Bool code is not  { self.elems.Bool }  ?              self.gimme(1).Bool   does not make any sense to me.
17:12 sorear good * #perl6
17:12 sorear cognominal: .elems would hang with an infinite list
17:13 moritz .u sigma
17:13 phenny U+03C3 GREEK SMALL LETTER SIGMA (σ)
17:14 cognominal ok, what if the first element has a false value?
17:15 cognominal I suppose List.Bool returns thru if List has a least one element (or can generate one)?
17:15 masak arnsholt: they're worth reading.
17:16 masak when I grow up, I want to be like MJD.
17:16 cognominal ok, I did not understandd what gimme does
17:16 jnthn cognominal: gimme gives you the number of elements it can actually give.
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme
17:17 p6eval rakudo 81ce66: OUTPUT«Not enough positional parameters passed; got 1 but expected 2␤  in method gimme at src/gen/CORE.setting:4304␤  in block <anon> at /tmp/m072rwC3DO:1␤  in <anon> at /tmp/m072rwC3DO:1␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(5)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(10)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(Inf)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(-5)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(*)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak rakudo: my @a = <a b c d e>; say @a.gimme(1i)
17:17 p6eval rakudo 81ce66: OUTPUT«5␤»
17:17 masak what a boring function ;)
17:17 jnthn Is somebody hunting for a rakudobug? :P
17:18 masak I would never...!
17:18 masak :P
17:18 jnthn "How boring, I can't make it explode!"
17:18 arnsholt masak: That's pretty much one of my thoughts as well. "MJD is really cool. I wouldn't mind being like that."
17:19 plobsing joined #perl6
17:21 kaare_ joined #perl6
17:23 Kivutarrr joined #perl6
17:26 jnthn moritz: What exactly did your PIR version of the segfaulting program do?
17:26 jnthn (the buf one)
17:28 jnthn moritz: I can reliably segfault it also in ByteBuffer with my $b = Buf.new(1); for ^5000 { $b~=Buf.new(1..100); }
17:31 im2ee What means *? The same what in unix system?
17:31 im2ee And "
17:31 im2ee "li"?
17:31 im2ee From  @a.gimme(1i)
17:31 im2ee oh, its 1 not l. :)
17:31 tadzik 1i, like i, which is sqrt(-1)
17:32 moritz jnthn: nopaste forthcoming
17:32 tadzik yes, in school they tell you there can be no sqrt(-1). They lie. I was disappointed too
17:32 moritz jnthn: https://gist.github.com/1307615
17:34 sorear wait, wait, what?  gimme takes Complex?
17:34 moritz uhm, where?
17:34 sorear 10:31 < im2ee> From  @a.gimme(1i)
17:35 moritz yes, but where is that code from?
17:35 tadzik masak wrote that
17:35 moritz jnthn: https://gist.github.com/1307619
17:36 pmurias joined #perl6
17:37 uasi joined #perl6
17:37 moritz jnthn: so with the patch it seems to be a wee bit faster, erm wait, I may not call it "faster", becaues it's not statistically significant
17:37 jnthn moritz: Erm.
17:37 jnthn I get 5 times faster here with the bunch of patches I've put in for Buf today.
17:37 jnthn (was testing it up to 25)
17:38 moritz jnthn: that patch is not related to Buf at all
17:38 jnthn moritz: oh, wait
17:38 jnthn moritz: What are we talking bout? :)
17:38 moritz just postcircumfix:<[ ]>
17:38 jnthn moritz: The array access?
17:38 jnthn oh!
17:38 moritz the patch is in the gist :-)
17:38 jnthn moritz: oooh!
17:38 jnthn You gisted me two things
17:38 jnthn I missed the second one :)
17:39 jnthn moritz: On https://gist.github.com/1307615 - byte buffer one
17:39 jnthn moritz: I can make it segfault here by upping the iteration count.
17:39 jnthn moritz: Changing it to:
17:39 jnthn unless $I0 == 10000 goto loop
17:40 jnthn (e.g. 10 times more iterations)
17:40 jnthn gets the segfault here
17:40 jnthn Guess in Rakudo we just have more GC churn going on so it needs less.
17:41 masak im2ee: 1i is a http://en.wikipedia.org/wiki/Complex_number
17:42 masak sorear: I just wanted to see what .gimme did about a Complex. seems it did pretty OK.
17:42 jnthn moritz: I *think* that you'd need to have an at_pos variant in Array.pm too, not just List.pm
17:42 moritz jnthn: doesn't segfault with 1000 iterations here
17:43 jnthn moritz: 10000
17:43 moritz my OOM killer just shot down thunderbird :-)
17:44 tadzik :P
17:44 jnthn ouch
17:44 moritz and before dying, it printed
17:44 moritz this should not be happening! arrgggggh!
17:44 moritz several times :-)
17:44 jnthn lol
17:45 jnthn moritz: I've got a rough guess at what is going on.
17:45 jnthn moritz: It looks like Parrot does string heap compaction.
17:45 jnthn That means it may move strstart...but ByteBuffer caches that.
17:45 masak very nice "how do I fix my git mess?" flow chart: http://justinhileman.info/article/git-pretty/git-pretty.png
17:48 moritz nice indeed
17:48 benabik masak: Important question there:  "Enough to form a lynch mob?"
17:48 moritz I menat to make similar instructions one day, in form of a blog post
17:48 moritz *meant
17:49 jnthn The bottom left hand corner is great :)
17:50 jnthn moritz: Did you manage to get the segfault with 10000 iterations?
17:50 jnthn moritz: I did so I guess I can file a ticket somewhere ;)
17:50 jnthn Where am I meant to file tickets on Parrot things these days?
17:50 moritz jnthn: no, I did not. Aborted before it ate all of my RAM
17:50 moritz jnthn: github
17:50 dukeleto joined #perl6
17:51 jnthn moritz: heh. Some days 16 gigs come in handy :)
17:51 dukeleto joined #perl6
17:51 jnthn Only ate 2.7 gigs before it explodes :)
17:51 dukeleto joined #perl6
17:52 jnthn but wait a moment...
17:52 dukeleto joined #perl6
17:52 jnthn nom: say 100 * 10000
17:52 p6eval nom 81ce66: OUTPUT«1000000␤»
17:52 jnthn The largest string we get up to should be about a meg in size?
17:53 moritz I think I had another factor of 10 somewhere
17:53 moritz still, 10M shouldn't be too bad
17:53 jnthn right
17:53 jnthn something is horribly wrong if it's getting into the gigs range then.
17:55 sftp joined #perl6
17:55 dukeleto joined #perl6
17:56 dukeleto joined #perl6
17:56 im2ee joined #perl6
17:57 Grrrr joined #perl6
17:57 dukeleto joined #perl6
17:57 dukeleto joined #perl6
17:58 dukeleto joined #perl6
17:58 jnthn Filed https://github.com/parrot/parrot/issues/182
17:58 dukeleto joined #perl6
17:59 sorear I s'pose we need a dalek thingie for reporting on github issues
17:59 sorear .oO( luckily, github just added push notification for those )
17:59 dukeleto joined #perl6
18:00 dukeleto joined #perl6
18:00 tadzik the more I look at the parameter documenting syntax the more I fell that not many people will like it and use it
18:00 sorear what syntax?
18:00 dukeleto joined #perl6
18:01 tadzik sorear: http://perlcabal.org/syn/S26.html#Declarator+blocks scroll to 'sub fu'
18:01 dukeleto joined #perl6
18:01 tadzik I suppose people will just put everything into the sub documentation, it seems easier and more convenient
18:01 dukeleto joined #perl6
18:02 tadzik that's how I fell when documenting MuEvent
18:02 masak tadzik: the advantage of documenting the paramters is that you don't have to repeat their names.
18:02 dukeleto joined #perl6
18:03 dukeleto joined #perl6
18:03 dukeleto joined #perl6
18:03 tadzik well, I suppose it's still less typing than #= and whitespace you have to put there to make those things work *and* not look like *&!#^*!$^
18:04 dukeleto joined #perl6
18:04 dukeleto joined #perl6
18:05 * sorear ponders banning dukeleto
18:05 tadzik I wish Pod and Declarators were convenient enough for people to prefer them to plain old... well, pod
18:05 jnthn afk, shop
18:05 tadzik sorear: ever tried turning off join/part events?
18:05 dukeleto joined #perl6
18:05 tadzik I did that some time ago and I don't think I ever regretted that
18:06 tadzik it still displays those if this person was active a short enough while ago
18:06 dukeleto joined #perl6
18:06 sorear tadzik: I *did* regret it.
18:06 dukeleto joined #perl6
18:07 tadzik ok then
18:07 dukeleto joined #perl6
18:07 sorear tadzik: I beleive in fixing problems at their source, not forcing 100s of downstream users to implement countermeasures
18:07 masak dukeleto: hey! you're doin' it again! :(
18:07 colomon joined #perl6
18:07 dukeleto joined #perl6
18:08 colomon dukeleto!!
18:08 sorear o/ colomon
18:08 tadzik sorear: I agree with that
18:08 * moritz ignores joins and leaves/quits in #perl6, and consults the IR clogs when he's interested in joins/leaves
18:08 dukeleto joined #perl6
18:09 dukeleto joined #perl6
18:09 sorear moritz: the irclogs have reliable join/part data now?
18:09 moritz sorear: reliable joins and leaves; not quites
18:09 moritz *quits
18:13 nornagest joined #perl6
18:13 nornagest Hi
18:14 moritz hi nornagest
18:14 moritz jnthn: added at_pos to List, still not significant (this time 0.4 sigma slower)
18:17 sorear o/ nornagest
18:18 pmurias joined #perl6
18:19 nornagest \o
18:20 [Coke] sorear,colomon: had to comment out an IO test today from niecza spectest. dunno if it was new tests or what.
18:20 colomon more details?
18:20 colomon sorear, \o
18:21 sorear hmm, nornagest != nornagon
18:21 sorear welcome, nornagest
18:21 nornagest indeed - thanks
18:31 [Coke] joined #perl6
18:32 masak hi nornagest
18:35 jnthn moritz: try this patch: https://gist.github.com/1307684
18:35 jnthn moritz: And explicitly write out the postcircumfix call
18:35 dalek niecza/serialize: 8edc022 | sorear++ | / (4 files):
18:35 dalek niecza/serialize: Starting inventory of globals that need isolation
18:35 dalek niecza/serialize: review: https://github.com/sorear/niecza/commit/8edc022827
18:36 jnthn moritz: e.g. instead of @a[$j] do @a.postcircumfix:<[ ]>($j)
18:36 jnthn (yes, I can fix the other case up too...it's just a tad more involved)
18:38 jnthn oh, that patch causes issues :(
18:41 im2ee Does "do" exists in p6? :)
18:41 tadzik yep
18:41 im2ee And how to include, just like perl5 ?
18:41 im2ee include some code
18:42 masak im2ee: 'require' or 'use'
18:42 im2ee Great. :)
18:42 hanekomu joined #perl6
18:42 masak but, hm, that's for modules.
18:42 masak maybe you mean just a regular script file?
18:42 masak then it's probably eval(slurp("file.pl"))
18:44 im2ee masak++, thanks. :)
18:44 wk joined #perl6
18:44 im2ee do doesn't include the code? (like in p5)
18:45 moritz im2ee: there are two 'do's in Perl 5, a do BLOCK and a do EXPR. The former still persists in Perl 6
18:45 moritz rakudo: do { say 1 }
18:45 p6eval rakudo ee65d3: OUTPUT«1␤»
18:45 sorear do EXPR is very strongly deprecated in Perl 5
18:46 im2ee Where the do functions is declared?
18:46 im2ee function*
18:46 moritz sorear: that's not what perldoc -f do  says
18:46 hanekomu_ joined #perl6
18:47 hanekomu joined #perl6
18:48 sorear im2ee: do isn't a function, it's a special syntactic form
18:51 jnthn moritz: Here's another patch that doesn't mess up setting compilation and that means you can leave it as @a[$j]: https://gist.github.com/1307705
18:52 GlitchMr perl6: (*..3).perl.say
18:52 p6eval niecza v10-61-gbacff10: OUTPUT«-Infinity..3␤»
18:52 p6eval ..rakudo ee65d3: OUTPUT«-Infe0..3␤»
18:52 p6eval ..pugs b927740: OUTPUT«()␤»
18:52 GlitchMr I know it doesn't make sense :P
18:52 masak im2ee: 'do' in Perl 6 has a different function than in Perl 5. in Perl 6, it's used for turning a statement into (part of) an expression.
18:53 masak why does Rakudo do Infe0?
18:53 GlitchMr Because it's garbage?
18:54 GlitchMr There is no way of accessing that 3 which I have specified
18:54 GlitchMr perl6: (*..*).perl.say
18:54 jnthn rakudo: say -Inf
18:54 p6eval niecza v10-61-gbacff10: OUTPUT«-Infinity..Infinity␤»
18:54 p6eval ..pugs b927740: OUTPUT«pugs: out of memory (requested 1048576 bytes)␤»
18:54 p6eval ..rakudo ee65d3: OUTPUT«Failure.new()␤»
18:54 p6eval rakudo ee65d3: OUTPUT«-Inf␤»
18:54 jnthn rakudo: say ~(-Inf)
18:54 benabik *..* is Failure?
18:54 p6eval rakudo ee65d3: OUTPUT«-Inf␤»
18:54 jnthn Hmm
18:55 jnthn Wonder how on earth it ends up with the e0
18:55 benabik nom: Int.WHAT.say
18:55 p6eval nom ee65d3: OUTPUT«Int()␤»
18:55 benabik nom: Inf.WHAT.say
18:55 p6eval nom ee65d3: OUTPUT«Num()␤»
18:55 im2ee Thanks sorear, masak. :)
18:55 im2ee and moritz too. :)
18:56 jnthn rakudo: say (*..3).from
18:56 p6eval rakudo ee65d3: OUTPUT«Method 'from' not found for invocant of class 'Range'␤  in block <anon> at /tmp/Co5C5txBKZ:1␤  in <anon> at /tmp/Co5C5txBKZ:1␤»
18:56 jnthn rakudo: say (*..3).min
18:56 p6eval rakudo ee65d3: OUTPUT«-Inf␤»
18:56 GlitchMr perl6: (0, *+0.1...100).perl.print
18:56 jnthn rakudo: say ~(*..3)
18:56 jnthn oh, that may take a while... :)
18:56 jnthn duh. :)
18:56 p6eval niecza v10-61-gbacff10: OUTPUT«␤Unhandled Exception: Unable to resolve method print in class Str␤  at /tmp/7MOOYyOz5J line 1 (MAIN mainline @ 3) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2181 (CORE C1041_ANON @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 2182 (CORE module-C…
18:56 p6eval ..rakudo ee65d3: OUTPUT«(0, 1/10, 1/5, 3/10, 2/5, 1/2, 3/5, 7/10, 4/5, 9/10, 1/1, 11/10, 6/5, 13/10, 7/5, 3/2, 8/5, 17/10, 9/5, 19/10, 2/1, 21/10, 11/5, 23/10, 12/5, 5/2, 13/5, 27/10, 14/5, 29/10, 3/1, 31/10, 16/5, 33/10, 17/5, 7/2, 18/5, 37/10, 19/5, 39/10, 4/1, 41/10, 21/5, 43/10, 22/5,…
18:56 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected "100"␤    expecting operator or ")"␤    at /tmp/cIvAuZtnNx line 1, column 13␤»
18:57 p6eval rakudo ee65d3: OUTPUT«(timeout)»
18:57 GlitchMr perl6: (2, *+0.05...3).perl.say
18:57 p6eval rakudo ee65d3, niecza v10-61-gbacff10: OUTPUT«(2, 41/20, 21/10, 43/20, 11/5, 9/4, 23/10, 47/20, 12/5, 49/20, 5/2, 51/20, 13/5, 53/20, 27/10, 11/4, 14/5, 57/20, 29/10, 59/20, 3/1).list␤»
18:57 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected "3"␤    expecting operator or ")"␤    at /tmp/4NKFB9z28X line 1, column 14␤»
18:59 GlitchMr perl6: (reverse 1..*).perl.say
18:59 GlitchMr I'm probably crazy, but whatever
18:59 p6eval niecza v10-61-gbacff10: OUTPUT«(timeout)»
18:59 p6eval ..pugs b927740: OUTPUT«pugs: out of memory (requested 1048576 bytes)␤»
18:59 p6eval ..rakudo ee65d3: OUTPUT«Failure.new()␤»
19:00 GlitchMr perl6: 1>2>print('wrong')
19:01 p6eval pugs b927740, rakudo ee65d3, niecza v10-61-gbacff10:  ( no output )
19:02 GlitchMr perl6: 'a' ==> print()
19:02 p6eval niecza v10-61-gbacff10: OUTPUT«␤Unhandled Exception: Feed ops NYI␤  at /home/p6eval/niecza/lib/CORE.setting line 790 (CORE die @ 2) ␤  at /home/p6eval/niecza/lib/CORE.setting line 1955 (CORE infix:<==>> @ 2) ␤  at /tmp/756_KL3OMT line 1 (MAIN mainline @ 1) ␤  at /home/p6eval/niecza/lib/…
19:02 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected " print"␤    at /tmp/mQV4bebEZv line 1, column 8␤»
19:02 p6eval ..rakudo ee65d3: OUTPUT«a»
19:02 GlitchMr perl6: 'a' ==> print
19:02 p6eval niecza v10-61-gbacff10: OUTPUT«[31m===[0mSORRY![31m===[0m��Unsupported use of bare 'print'; in Perl 6 please use .print if you meant $_, or use an explicit invocant or argument at /tmp/EYpE8bKX0S line 1 (EOF):�------> [32m'a' ==> print[33m�[31m<EOL>[0m���Unhandled Exception: Che…
19:02 p6eval ..pugs b927740: OUTPUT«*** ␤    Unexpected " print"␤    at /tmp/2qkwFVA1lc line 1, column 8␤»
19:02 p6eval ..rakudo ee65d3: OUTPUT«a»
19:02 GlitchMr ... ok...
19:08 GlitchMr perl6: [Z].perl.say
19:08 p6eval rakudo ee65d3: OUTPUT«Any␤»
19:08 p6eval ..niecza v10-61-gbacff10: OUTPUT«(timeout)»
19:08 p6eval ..pugs b927740: OUTPUT«()␤»
19:19 [Coke] joined #perl6
19:27 sivoais joined #perl6
19:29 ksi joined #perl6
19:31 kaare_ joined #perl6
19:31 mberends joined #perl6
19:33 sorear o/ mberends
19:34 diakopter .
19:34 sorear o/ diakopter
19:34 diakopter o/
19:36 ab5tract joined #perl6
19:37 mberends o/ (home in .nl after a week in .si)
19:42 tadzik hello mberends!
19:42 masak welcome home, mberends!
19:43 mberends hi tadzik! hi masak! It's nice to catch up the backlog :)
19:46 [Coke] joined #perl6
19:58 [Coke] joined #perl6
19:59 im2ee joined #perl6
20:04 masak perl6: say 10 ... 0
20:04 p6eval pugs b927740: OUTPUT«*** ␤    Unexpected "0"␤    expecting operator, ":" or ","␤    at /tmp/ZzlEHDRKld line 1, column 12␤»
20:04 p6eval ..rakudo ee65d3, niecza v10-61-gbacff10: OUTPUT«10 9 8 7 6 5 4 3 2 1 0␤»
20:04 [Coke] joined #perl6
20:06 Manildomin joined #perl6
20:07 Manildomin hi everybody
20:11 masak hi Manildomin
20:11 Manildomin I said I have an issue with the second example code given in the book "Using Perl6"
20:12 Manildomin I virtualized Debian Wheezy and installed in it its own version of rakudo and parrot, and with these the same code just works fine
20:14 masak what was your issue? could you perhaps make a gist of the error you get?
20:14 Manildomin I had no error messag
20:14 Manildomin message*
20:15 Manildomin the program ran but never output what it was intended to output
20:15 Manildomin and it never stopped
20:16 masak this is interesting to us.
20:16 Manildomin this is that piece of code : http://pastebin.com/rnyutrH2
20:16 [Coke] joined #perl6
20:16 masak any idea what might have differed between the two setups?
20:16 masak different Rakudo versions?
20:16 Manildomin the one I have on my real system (archlinux) is the most up to date
20:16 Manildomin yes
20:16 sorear Manildomin: which version is it?
20:17 Manildomin rakudo 2011.07 on debian wheezy
20:17 Manildomin 2011.09 on archlinux
20:17 Manildomin parrot 3.8.0 on archlinux
20:17 Manildomin parrot 3.6.0 on debian wheezy
20:18 masak aha! seems I need a wrap_return_handler for my macros to fix moritz++' bug.
20:20 masak Manildomin: I run it locally with no problem on Rakudo HEAD.
20:23 im2ee joined #perl6
20:30 [Coke] joined #perl6
20:31 dalek rakudo/macros: b1c555f | masak++ | src/Perl6/Actions.pm:
20:31 dalek rakudo/macros: make it possible to return from macros
20:31 dalek rakudo/macros:
20:31 dalek rakudo/macros: Kudos to moritz++ for discovering this use case.
20:31 dalek rakudo/macros: review: https://github.com/rakudo/rakudo/commit/b1c555fe89
20:31 Manildomin I am installing an older version of rakudo (rakudo-star 2011.04) and see if it runs the piece of code
20:34 wk Manildomin: i tried your example with rakudo 2011.07 and it worked well (Ubuntu 11.04)
20:35 Manildomin yes, I use rakudo 2011.07 on debian wheezy and it works too
20:35 wk Manildomin: but igot same behaviour with nom snapshot installed about two month ago
20:35 Manildomin ok
20:35 wk Manildomin: with "same beahaviour" i meant: it runs forever without output
20:36 Manildomin nice, so we seem to encounter the same issue
20:36 masak here's the current status of the macros branch: 'my $a = 42; macro foo { quasi { say $a } }; foo' works and prints 42.
20:36 masak 'macro foo { my $a = 42; quasi { say $a } }; foo' dies with a Null PMC Access, for fairly obvious reasons.
20:37 masak I feel I should fix the latter before proposing we merge the D1 work. (and I'm going to write tests too, of course)
20:37 soh_cah_toa what's the quasi() subroutine for? never heard of it
20:38 masak it's not a subroutine, it's a syntactic form, like 'while' or 'sub'.
20:38 wk Manildomin: i hope it helps to localise period, where it come in, because my nom is installed on YAPC:EU, so around 13th August
20:40 Kivutarrr left #perl6
20:41 Manildomin I installed rakudo 2011.09 from here : http://aur.archlinux.org/packages.php?ID=29068
20:50 Manildomin with (Rakudo Perl 6, version 2011.04 built on parrot 3.8.0 0), the same code works fine
20:50 Manildomin on archlinix
20:51 Manildomin archlinux*
20:54 quuxrev joined #perl6
21:00 fsergot joined #perl6
21:04 fsergot joined #perl6
21:04 y3llow_ joined #perl6
21:05 pothos_ joined #perl6
21:11 ab5tract joined #perl6
21:13 whiteknight joined #perl6
21:21 masak nom: sub foo { my $*a = 42; return { say $*a } }; foo
21:21 p6eval nom ee65d3:  ( no output )
21:21 masak nom: sub foo { my $*a = 42; return { say $*a } }; my $c = foo; $c()
21:21 p6eval nom ee65d3: OUTPUT«Failure.new()␤»
21:25 dalek rakudo/nom: 18dea93 | jnthn++ | src/ (15 files):
21:25 dalek rakudo/nom: Add an nqp::p6decont and eliminate pir::perl6_decontainerize in the setting in favor of it.
21:25 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/18dea93802
21:42 aloha joined #perl6
21:48 masak good night, #perl6
21:48 tadzik good night masak
21:49 jnthn nom: my $a = 1; my $b = 2; my $c = [$a, $b]; $a++; say $c.perl
21:49 p6eval nom ee65d3: OUTPUT«[2, 2]␤»
21:50 jnthn perl6: my $a = 1; my $b = 2; my $c = [$a, $b]; $a++; say $c.perl
21:50 p6eval rakudo ee65d3: OUTPUT«[2, 2]␤»
21:50 p6eval ..pugs b927740, niecza v10-61-gbacff10: OUTPUT«[1, 2]␤»
21:50 jnthn b: my $a = 1; my $b = 2; my $c = [$a, $b]; $a++; say $c.perl
21:50 p6eval b 1b7dd1: OUTPUT«[1, 2]␤»
21:50 jnthn tssk
21:52 jnthn Turns out that a bug in take and return masked this issue in various tests.
21:52 jnthn Now I've fixed take and return I have broken tests, seemingly because of the above.
22:02 dorlamm joined #perl6
22:04 jnthn perl6: sub foo(*@a) { @a[0]++ }; my $a = 1; foo([$a]); say $a;
22:04 p6eval pugs b927740: OUTPUT«*** Can't modify constant item: VRef <Array:0x7f7a165a3459>␤    at /tmp/aEdoMWmRdK line 1, column 16-24␤»
22:04 p6eval ..niecza v10-61-gbacff10: OUTPUT«␤Unhandled Exception: cannot increment a value of type Array␤  at  line 0 (ExitRunloop @ 0) ␤  at /home/p6eval/niecza/lib/CORE.setting line 25 (CORE Mu.succ @ 8) ␤  at  line 0 (ExitRunloop @ 0) ␤  at /tmp/tAEBNKPPi_ line 0 (MAIN foo @ 0) ␤  at /tmp/tAEBNKP…
22:04 p6eval ..rakudo 18dea9: OUTPUT«Method 'succ' not found for invocant of class 'Array'␤  in sub postfix:<++> at src/gen/CORE.setting:1065␤  in sub foo at /tmp/M_C4AkFn8l:1␤  in block <anon> at /tmp/M_C4AkFn8l:1␤  in <anon> at /tmp/M_C4AkFn8l:1␤»
22:04 jnthn perl6: sub foo(*@a) { @a[0]++ }; my $a = 1; foo($a); say $a;
22:04 p6eval niecza v10-61-gbacff10: OUTPUT«2␤»
22:04 p6eval ..rakudo 18dea9: OUTPUT«1␤»
22:04 p6eval ..pugs b927740: OUTPUT«*** Can't modify constant item: VInt 1␤    at /tmp/IiGrqIKufP line 1, column 16-24␤»
22:05 jnthn b: sub foo(*@a) { @a[0]++ }; my $a = 1; foo($a); say $a;
22:05 p6eval b 1b7dd1: OUTPUT«1␤»
22:23 dju joined #perl6
22:27 nornagest Good night!
23:08 molaf_ joined #perl6
23:22 thou joined #perl6
23:40 dukeleto joined #perl6
23:41 dukeleto joined #perl6
23:41 dukeleto joined #perl6
23:42 dukeleto joined #perl6
23:52 lue rakudo: role A { }; role B is A { }; say "alive!"; # I thought roles could only be applied with does. bug?
23:52 p6eval rakudo 18dea9: OUTPUT«alive!␤»
23:53 tokuhiro_ joined #perl6

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo