Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2014-04-10

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:02 a3gis joined #perl6
00:15 Bryanstein joined #perl6
00:17 benabik joined #perl6
00:18 bjz_ joined #perl6
00:20 kurahaupo joined #perl6
00:38 dayangkun joined #perl6
00:56 FROGGS joined #perl6
00:56 dayangkun joined #perl6
00:56 Ben_Goldberg joined #perl6
01:08 kurahaupo left #perl6
01:09 kurahaupo joined #perl6
01:19 isacloud__ joined #perl6
01:20 flussenc1 joined #perl6
01:20 sftp_ joined #perl6
01:21 dagurval_ joined #perl6
01:21 cxreg2 joined #perl6
01:21 TimToady_ joined #perl6
01:22 simcop2387_ joined #perl6
01:22 Goodbox_ joined #perl6
01:22 jtpalmer_ joined #perl6
01:22 Vlavv joined #perl6
01:23 Bucciarati joined #perl6
01:32 * masak enjoyed http://skien.cc/blog/2014/04/09/unpythonic-python/
01:35 masak HN discussion has some gems, too: https://news.ycombinator.com/item?id=7560647
01:39 flussence joined #perl6
01:41 btyler joined #perl6
01:48 ilbot3 joined #perl6
01:48 Topic for #perl6 is now »ö« Welcome to Perl 6! | http://perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:,  niecza:, std:, or /msg camelia perl6: ... | irclog: http://irc.perl6.org | UTF-8 is our friend!
01:49 lustlife joined #perl6
01:56 klapperl_ joined #perl6
02:14 plobsing joined #perl6
02:28 xragnar_ joined #perl6
02:35 bjz joined #perl6
03:05 hoverboard joined #perl6
03:13 Ben_Goldberg joined #perl6
03:33 lizmat_ joined #perl6
03:35 lizmat__ joined #perl6
03:35 BenGoldberg joined #perl6
04:02 kaare_ joined #perl6
04:04 xinming joined #perl6
04:13 pdcawley joined #perl6
04:19 pencilk joined #perl6
04:35 Psyche^ joined #perl6
04:38 jk_ joined #perl6
04:58 SamuraiJack_ joined #perl6
05:06 BenGoldberg joined #perl6
05:13 cxreg joined #perl6
05:20 kaare_ joined #perl6
05:37 sorear joined #perl6
05:42 kaleem joined #perl6
05:44 klapperl joined #perl6
06:28 japhb /home/gjb/share/rakudo-jvm-9ff0bc002d060a291d62010c07bac9593d625846/install/bin/nqp-j --target=jar --output=blib/Perl6/World.jar --encoding=utf8 \ src/Perl6/World.nqp
06:28 japhb make: *** [blib/Perl6/World.jar] Segmentation fault (core dumped)
06:28 japhb ^^ Is that expected right now when building r-j?
06:31 Woodi hallo :)
06:32 Woodi masak: I wonder do C Pyton version run fastest... looks just 1 sub call :)
06:38 moritz the IO costs will dominate the runtime, I guess
06:38 Woodi foun http://www.somethingofthatilk.com/index.php?id=237  following links on that blog :)  but using game consoles sold with dumping prices and do noit buy any games is way to go. no one protect small bakers whet giant markets dump prices on bread. they dump quality also...
06:38 ldthien0 joined #perl6
06:38 Woodi in C-ly version ?
06:39 moritz Woodi: in both C-ish and pythonic
06:40 kurahaupo joined #perl6
06:40 Woodi in pythonic ver there is 100 sub calls
06:40 moritz wow
06:40 moritz 100 sub calls
06:41 moritz that'll take years.
06:41 moritz in both versions, there are also 100 print calls :-)
06:41 Woodi that was named "Pythonic Python"... ;)
06:45 sergot morning o/
06:45 Woodi hallo :)
06:47 Woodi btw. turring machines are probably proved to be universal computation model so do we shouldn't use more gotos ? ;)
06:48 * moritz has to quit firefox to compile the setting with for rakudo-j these days, otherwise he gets an OOM
06:48 moritz Woodi: Turing machines don't have gotos at all
06:48 Woodi jumps ?
06:48 moritz Woodi: neither
06:49 Woodi hmm, must correct my imagination with wiki..
06:49 moritz it just has states, transitions, and a tape with a movable head
06:49 lizmat joined #perl6
06:49 moritz one could emulate the states with gotos, but there are better ways to do that
07:02 darutoko joined #perl6
07:10 lizmat good *, #perl6!
07:10 lizmat from a sunny Zürich
07:11 lizmat sightseeing and commuting&
07:13 zakharyas joined #perl6
07:14 Ven joined #perl6
07:18 moritz \o
07:19 Ven o/
07:19 klapperl_ joined #perl6
07:19 moritz r: my $a = {:x}; my $role = role { has $.cool = "yeah" }; $a does $role; say $a.cool
07:19 camelia rakudo-jvm 9ff0bc: OUTPUT«(timeout)»
07:19 camelia ..rakudo-parrot 9ff0bc: OUTPUT«yeah␤»
07:19 camelia ..rakudo-moar 9ff0bc: OUTPUT«Type check failed in binding <anon>; expected '<anon>' but got 'Hash+{<anon>}'␤  in method  at /tmp/tmpfile:1␤  in block  at src/gen/m-CORE.setting:993␤  in method BUILD_LEAST_DERIVED at src/gen/m-CORE.setting:951␤  in sub infix:<does> at src/gen/m…»
07:20 Ven p: say {:x}.perl
07:20 camelia rakudo-parrot 9ff0bc: OUTPUT«{"x" => Bool::True}␤»
07:20 Ven p: say {+:x, -:x}.perl # can I get a false ?
07:20 camelia rakudo-parrot 9ff0bc: OUTPUT«Block.new()␤»
07:21 moritz m: say (:!x).perl
07:21 camelia rakudo-moar 9ff0bc: OUTPUT«"x" => Bool::False␤»
07:23 Ven moritz++
07:25 moritz r: my $a = []; my $role = role { has $.cool = "yeah" }; $a does $role; say $a.cool
07:25 camelia rakudo-parrot 9ff0bc: OUTPUT«yeah␤»
07:25 camelia ..rakudo-jvm 9ff0bc: OUTPUT«Nominal type check failed for parameter 'null'␤  in method  at /tmp/tmpfile:1␤  in block  at gen/jvm/CORE.setting:993␤  in method BUILD_LEAST_DERIVED at gen/jvm/CORE.setting:951␤  in sub infix:<does> at gen/jvm/CORE.setting:16514␤  in sub infix:<d…»
07:25 camelia ..rakudo-moar 9ff0bc: OUTPUT«Type check failed in binding <anon>; expected '<anon>' but got 'Array+{<anon>}'␤  in method  at /tmp/tmpfile:1␤  in block  at src/gen/m-CORE.setting:993␤  in method BUILD_LEAST_DERIVED at src/gen/m-CORE.setting:951␤  in sub infix:<does> at src/gen/…»
07:26 Ven p: my $a = []; my $role = role { has $.cool = "yeah" }; $a but $role; say $a.cool # do I remember that correctly ?
07:26 camelia rakudo-parrot 9ff0bc: OUTPUT«No such method 'cool' for invocant of type 'Array'␤  in block  at /tmp/SC_JKe7xA7:1␤␤»
07:26 moritz r: my $a = []; Ra does role { has $.cool = "yeah" }; $a does $role
07:27 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Variable '$role' is not declaredâ�¤at /tmp/tmpfile:1â�¤------> [32me { has $.cool = "yeah" }; $a does $role[33mâ��[31m<EOL>[0mâ�¤    expecting …»
07:27 moritz Ven: 'but' leaves the original unmodified
07:27 moritz and returns a clone with the mix-in
07:27 Ven moritz: hence the "do I remember that correctly" :p
07:27 moritz r: my $a = []; $a does role { has $.cool = "yeah" };
07:27 * Ven far prefers $'s position on azerty keyboards
07:27 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
07:29 moritz r: my $a = []; $a does role { has $.cool = "yeah" }; say $a.cool
07:30 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«yeah␤»
07:31 bjz_ joined #perl6
07:32 * moritz submits rakudobug
07:58 xinming joined #perl6
08:05 Ven What's "c'dent"?
08:06 Ven well, something from 2010 it seems
08:06 tadzik ingy's language
08:10 denis_boyun_ joined #perl6
08:27 dmol joined #perl6
08:30 Ven r: say (1, 2) Z- (3, 4); say (1, 2) >>-<< (3, 4); # not sure what's the diff
08:30 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«-2 -2␤-2 -2␤»
08:32 Ven r: sub sma(Int \P where * > 0) returns Sub {     sub ($x) {         state @a = 0 xx P;         @a.push($x).shift;         P R/ [+] @a;     } }
08:32 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
08:34 Ven r: (1, 2) Z- (3, 4) Z- (5, 6)
08:34 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
08:35 Ven r: say (1, 2) Z- (3, 4) Z- (5, 6); say (1, 2) >>-<< (3, 4) >>-<< (5, 6)
08:35 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«-7 -8␤-7 -8␤»
08:36 Ven http://en.wikibooks.org/wiki/Perl_6_Programming/Meta_Operators Doesn't even have Z :(
08:40 Ven r: class A { method Int { 5 }; method Numeric { 6 } }; say +A.new
08:40 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«6␤»
08:53 Ven r: gather for ^5 { say 'hey, listen !'; }; eager gather for ^5 { say 'die, navi !'; };
08:53 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«hey, listen !␤hey, listen !␤hey, listen !␤hey, listen !␤hey, listen !␤die, navi !␤die, navi !␤die, navi !␤die, navi !␤die, navi !␤»
08:53 virtualsue joined #perl6
08:54 pecastro joined #perl6
08:58 jnthn japhb: The JVM should never be expected to segfault...
08:59 * Ven kinda thought gather could be lazy
09:00 dakkar joined #perl6
09:01 jnthn Ven: It is, but you put it in sink context.
09:02 Ven Kinda makes sense.
09:02 Ven r: my @a = gather for ^5 { say 'hey, listen !'; }; eager gather for ^5 { say 'die, navi !'; };
09:02 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«hey, listen !␤hey, listen !␤hey, listen !␤hey, listen !␤hey, listen !␤die, navi !␤die, navi !␤die, navi !␤die, navi !␤die, navi !␤»
09:03 Ven ("kinda" because the other option would be to give a warning "useless statement" )
09:03 Ven (which is certainly not what most people would expect -- I'd argue it's pretty useless to use gather in sink context, only for side-effects, though)
09:05 jnthn Use binding also :)
09:05 jnthn = is a mostly eager construct.
09:05 Ven r: my @a := gather for ^5 { say 'hey, listen !'; }; eager gather for ^5 { say 'die, navi !'; } # getting through it !
09:06 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«die, navi !␤die, navi !␤die, navi !␤die, navi !␤die, navi !␤»
09:06 jnthn .oO( the, navi, the )
09:06 Ven jnthn++ # thanks -- Only 4 questions I kinda don't understand :D
09:09 jnthn Well, Perl generally associated semantics with operators more strongly than types. Assignment will consistently be "mostly eager" (that is, evaluate up until known infinite things).
09:11 Ven my @a = ^Inf; # mostly is the word
09:11 Ven well, that'll probably get executed because it's the last expression
09:11 Ven r: my @a = ^Inf; 1 # mostly is the word
09:11 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
09:17 jnthn meeting &
09:18 tadzik hmm. Can anyone in the US be my postal relay? Complementary beer will be provided at the earliest social gathering
09:19 tadzik long story short, I really want that t-shirt: http://shirt.thatdailydeal.com/home.php?id=23458
09:22 kaleem joined #perl6
09:25 eMBee joined #perl6
09:27 anaeem1 joined #perl6
09:27 d^_^b joined #perl6
09:29 clkao joined #perl6
09:31 ingy hi ClarusCogitatio
09:31 ingy er
09:31 ingy hi clkao :)
09:31 ingy Ven: where did you find c'dent?
09:32 Ven hi clkao, hi ingy
09:32 colomon Iingy!  \o/
09:32 colomon ingy!  \o/
09:32 Ven found it from rosetta, I think. That along with several questions I still have
09:35 masak ingy! \o/
09:37 Ven r: class A { method Int { !!! } }; subset Intable where *.^can('eat'); role IntableExt[Intable ::T] { has T intval; }; class B does Intable[A]; say B.new.perl;
09:37 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Malformed has (did you mean to declare a sigilless \intval or $intval?)�at /tmp/tmpfile:1�------> [32me IntableExt[Intable ::T] { has T intval…»
09:38 Ven r: class A { method Int { !!! } }; subset Intable where *.^can('eat'); role IntableExt[Intable ::T] { has T $intval; }; class B does Intable[A]; say B.new.perl;
09:38 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc: OUTPUT«===SORRY!===␤No such method 'parameterize' for invocant of type 'Perl6::Metamodel::SubsetHOW'␤»
09:38 camelia ..rakudo-moar 9ff0bc: OUTPUT«===SORRY!===␤Cannot find method 'parameterize'␤»
09:38 Ven r: class A { method Int { !!! } }; subset Intable of Any where { .^can('eat') }; role IntableExt[Intable ::T] { has T $intval; }; class B does Intable[A]; say B.new.perl;
09:38 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc: OUTPUT«===SORRY!===␤No such method 'parameterize' for invocant of type 'Perl6::Metamodel::SubsetHOW'␤»
09:38 camelia ..rakudo-moar 9ff0bc: OUTPUT«===SORRY!===␤Cannot find method 'parameterize'␤»
09:38 dbane joined #perl6
09:38 Ven r: class A { method Int { !!! } }; subset Intable of Any where { .^can('eat') }; role IntableExt[Intable ::T] { has T $intval; }; class B does IntableExt[A]; say B.new.perl;
09:39 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Too late for semicolon form of class definition�at /tmp/tmpfile:1�------> [32m$intval; }; class B does IntableExt[A]; [33m�[31msay B.new.p…»
09:39 Ven r: class A { method Int { !!! } }; subset Intable of Any where { .^can('eat') }; role IntableExt[Intable ::T] { has T $intval; }; class B does IntableExt[A] { }; say B.new.perl;
09:39 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«===SORRY!===␤None of the parametric role variants for 'IntableExt' matched the arguments supplied.␤Cannot call ''; none of these signatures match:␤:(Mu ::$?CLASS ::::?CLASS, Any ::T $ where { ... })␤»
09:39 Ven r: class A { method Int { !!! } }; subset Intable of Any where { .^can('Int') }; role IntableExt[Intable ::T] { has T $intval; }; class B does IntableExt[A] { }; say B.new.perl;
09:39 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«B.new()␤»
09:43 ingy heya colomon
09:43 ingy greetings masak!
09:44 ingy masak: just added initial PR supports to git-hub
09:45 ingy I'll have to make a LT video for you :)
09:45 * ingy is in .tw waiting for audreyt to appear
09:47 nwc10 hi ingy. Have fun. Say hi to audreyt
09:47 fridim_ joined #perl6
09:48 moritz aye, say hi to au from #perl6!
09:51 masak yes, please do say hi to au++ from us!
09:54 JimmyZ say hi to au from china :)
09:57 ingy :D
09:57 ingy will do
09:58 masak "from china" -- I see what you did there :P
09:59 JimmyZ :P
09:59 Ven Really, what's R/ ? R meta-operator ??
09:59 jercos pirate meta-op :D
10:00 ingy arrrr
10:00 Ven yerrrr meta-op'reter
10:00 jercos (Looks like it reverses operand order for convenience?)
10:00 jercos > 2 R/ 5
10:00 jercos 2.5
10:00 Ven uuhhhhhhh
10:01 Ven r: (1, 2) R[Z-] (3, 4)
10:01 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
10:01 Ven r: say (1, 2) R[Z-] (3, 4)
10:01 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«2 2␤»
10:01 dbane joined #perl6
10:01 Ven Uhmmm ... fair enough ? I guess ... Thanks jercos !
10:01 jercos :) np
10:02 Ven couldn't find anything from S03
10:03 colomon indeed Rop reverses the operands
10:04 Ven r: say 2 * [+] (1, 2 ... 10) Z* (10, 9 ... 1);
10:04 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«440␤»
10:04 Ven r: say 2 * [+] (1, 2 ... *) Z* (10, 9 ... 1);
10:04 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«440␤»
10:22 Ven r: (1, 2) Z- (3)
10:22 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: ( no output )
10:22 Ven r: say (1, 2) Z- (3)
10:22 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«-2␤»
10:22 Ven r: say (1, 2) >>Z<< (3)
10:22 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Missing << or >>â�¤at /tmp/tmpfile:1â�¤------> [32msay (1, 2) >>Z<[33mâ��[31m< (3)[0mâ�¤    expecting any of:â�¤        postfixâ�¤        infix…»
10:22 Ven r: say (1, 2) <<-<< (3)
10:22 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«-2␤»
10:22 * Ven is not sure what's the difference between Z and >> <</
10:25 Ven (execution order ?)
10:28 denis_boyun_ joined #perl6
10:29 Ven r: say so '0'; say so '0.0'; say so '0foo';
10:29 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«False␤True␤True␤»
10:29 * Ven is sad now :(
10:30 Ven use strict-if;
10:30 a3gis joined #perl6
10:31 Ven r: say '0'.Bool;
10:31 colomon Ven: Zop is lazy and in-order.  >>op<< is hyper and unordered
10:31 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«False␤»
10:31 Ven colomon: wouldn't S>>op<< be like Zop ?
10:32 Ven r: use MONKEY_TYPING; augment class Int { method Bool { !!! } }; augment class Str { method Bool { !!! } }; if '0' { say 'hello' }
10:32 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Package 'Int' already has a Method 'Bool' (did you mean to declare a multi-method?)�at /tmp/tmpfile:1�------> �»
10:32 colomon Ven: I don't know.
10:38 kurahaupo joined #perl6
11:08 rindolf joined #perl6
11:21 masak Ven: as far as I know, S has nothing to do with iterators. Z is lazy.
11:21 masak Ven: and even if S>>op<< *could* emulate Zop, I wouldn't want to keep writing the former. bad huffmanization.
11:21 sjn joined #perl6
11:27 masak r: say +'0.0'; say +'0foo'
11:27 camelia rakudo-moar 9ff0bc: OUTPUT«0␤===SORRY!===␤Cannot convert string to number: trailing characters after number in '0⏏foo' (indicated by ⏏)␤»
11:27 camelia ..rakudo-jvm 9ff0bc: OUTPUT«0␤Cannot convert string to number: trailing characters after number in '0⏏foo' (indicated by ⏏)␤  in method gist at gen/jvm/CORE.setting:12504␤  in method gist at gen/jvm/CORE.setting:1053␤  in sub say at gen/jvm/CORE.setting:13417␤  in block …»
11:27 camelia ..rakudo-parrot 9ff0bc: OUTPUT«0␤Cannot convert string to number: trailing characters after number in '0⏏foo' (indicated by ⏏)␤  in method gist at gen/parrot/CORE.setting:12525␤  in method gist at gen/parrot/CORE.setting:1056␤  in sub say at gen/parrot/CORE.setting:13459…»
11:28 masak Ven: numification is already strict in the way you describe. interestingly, boolification doesn't appear to have been given the same treatment. (maybe for good reasons, I dunno.)
11:29 Ven masak: I'd really like Boolification to be strict :_
11:35 masak Ven: I can think of at least one reason I wouldn't like that.
11:35 masak Ven: namely, I want to be able to write `if ($var) { ... }` on any value without fearing I'll get an exception.
11:35 Ven masak: I can think of a lot of reasons I wouldn't like that
11:36 Ven but I can think of a hundred more of why I'd want that
11:37 Ven also, that could be made to error early on
11:38 masak I'm all for that, but the use case I mentioned doesn't feel like something I'd want to error, ever. that's kind of the beauty of it.
11:39 masak at which point you're faced with splitting things up into, um, .Bool and .permissive-Bool, and having `if` statements use the latter.
11:40 masak personally, I think Perl 6 already has too much of that kind of internals fragmentation cluttering up the model.
11:40 masak it's easy to add complexity, difficult to remove it :)
11:41 pdcawley joined #perl6
11:44 Ven masak: ... which is why I'd like a "use strict-if" of some sorts, that overrides Int and Str's .Bool to throw
11:45 masak good news: anyone can write and publish a module. :)
11:46 Ven masak: and that good news is why I tried to use MONKEY_TYPING to fix that
11:48 AW3i joined #perl6
11:48 masak ah.
11:48 Ven I must be missing something. though :)
11:49 arnsholt Monkey-patching the Bool methods can cause some terrible action-at-a-distance bugs down the line, though
11:49 Ven I know
11:50 masak seems like a risk Ven is willing to take.
11:50 tadzik I read that in Sisko's voice
11:51 tadzik "that's a chance we'll have to take"
11:51 Ven I'd say I "value correctness", but I'm sure y'all disagree :p
11:52 masak no, that seems to be what you value :>
11:52 masak in this instance, I value convenience.
11:53 Ven which is fine, really ! that's a script language, after all
11:53 Ven that's just one of the thing I've put in the bucket of "looks convenient but bites you after the fact". Like parentless function call
11:54 masak r: say "Perl 6 is a script language".trans('cp' => 'tc')
11:54 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«Perl 6 is a strict language␤»
11:54 masak \o/
11:54 tadzik :P
11:55 masak Ven: you can have my parentless function calls after you pry them from my cold, dead hands. :P
11:55 arnsholt I think this is a case that actually wants to be a macro. Not sure if our macro facilities can handle this yet, though
11:55 Ven (unless you can't mix them up)
11:55 tadzik r: say "I think not!".trans('k ' => ' k')
11:55 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«Ikthin knot!␤»
11:55 tadzik :o
11:55 masak tadzik: go and read up on .trans :)
11:55 tadzik yeah, I should :)
11:56 masak tadzik: it's Perl 6's version of tr///
11:56 tadzik r: say "I think not!".subst('k ', ' k')
11:56 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«I thin knot!␤»
11:56 tadzik yyyeeah
11:56 Ven masak: like, if `a b c` is invalid, I'm mostly okay with them. That's why I'm okay with them in haskell
11:57 Ven but whenever I do coffee and such, I find it to read pretty poorly
11:57 Ven I get you can go overboard with mostly anything, esp. in a language such as perl6
11:57 Ven s/6//
11:58 Ven (as opposed to languages like python, when a reduce function is considered to hard to understand to be added to the language ..)
11:59 masak Ven: everything in moderation. of course you can abuse listop syntax to produce something horribly unreadable. most of the time I feel it reduces parenthesis clutter, though.
12:00 masak Ven: ...and I must say you bring a refreshing "users should be punished" attitude to the channel :)
12:02 Ven masak: ha, you seem to kinda like it though ? I really think we ought to do better with our tools. You shouldn't be allowed to shoot yourself in other's people foot
12:02 Ven ("our tools" applies to ALL programming, no exception)
12:04 masak Ven: there's a State of the Onion somewhere that you really should read.
12:04 Ven http://www.perlfoundation.org/perl6/index.cgi?state_of_the_onion ?
12:05 masak Ven: one of its points is that if we make our tools so safe that it's no longer possible to make serious mistakes, the tools will also not be powerful enough to do interesting things. and an analogy to free will, because it's TimToady :)
12:05 Ven "Perl is humble. It doesn't try to tell the programmer how to program. It lets the programmer decide what rules today, and what sucks. It doesn't have any theoretical axes to grind. And where it has theoretical axes, it doesn't grind them." ?
12:05 rurban joined #perl6
12:05 masak right. and things like that.
12:06 Ven masak: but that's really a strawman imho
12:06 Ven you can make the tools "safer" while not going overboard with them too :)
12:07 masak yes, of course.
12:07 masak and that's a lot of what we're doing with Perl 6 compared to Perl 5, IMO.
12:07 Ven Never did perl 5, so I couldn't tell.
12:07 Ven I certainly heard it's nuts before, though
12:08 masak it's nuts in that crunchy, tasty way.
12:09 Ven I'll take your words on that one ! And I really must look like a narrow-minded one, but tools like haskell reduce your ability to shoot yourself in the foot, in a good way
12:10 masak please don't take my responses as rebukes. I (and many others here, I'm sure) will gladly listen to suggestins for improvements.
12:10 masak suggestions*
12:12 Ven There's a quote from runarorama that I particularly like "functional programming is a restriction on how we write programs, but not on what programs we can express."
12:12 masak what you can't expect is a group of people who haven't already thought about these design considerations a lot, and who just accept your suggestions without balancing counterarguments :)
12:12 masak that point about axes to grind is quite central, for example.
12:12 Ven I don't expect it !
12:13 masak Perl 6 is a lot more functional/FP than Perl 5. but it's still not am FP language in the way Haskell is.
12:13 masak Perl 6 is multi-paradigm.
12:14 Ven That much is obvious
12:14 Ven I don't think there's a language that is not "multi-paradigm"
12:15 Ven (and a lot of people strongly believe haskell is the best imperative language, which I could very well agree with)
12:17 masak :P
12:18 Ven masak: I know I do that, though. I take a lot of responses as rebukes, a lot of that is because I'm not a native speaker, another big part is because it's hard to "read" emotions going with one's sentence -- is it a reproach ? is it a compliment ? etc
12:19 tadzik that's a problem with internet indirect communication
12:19 tadzik s/internet//
12:20 Ven and that makes it even harder to argue
12:24 Ven state of the onion 200[89] seem to be down, though
12:27 * Ven will try to stay constructed while "freshly punishing users" here
12:38 xenoterracide joined #perl6
12:46 anaeem1 joined #perl6
12:50 Woodi so what 'language is FP' means, by definition ? gc, immutable, no side effects, ((( syntax ?  probably Haskell have more features then just FP ones
12:52 Woodi and if someone say ((( syntax is essential then.. I do not know what... :)
12:53 Ven joined #perl6
12:55 Ven well, that was a pretty rough cut in the conversation. Good thing that's a programming school, or I'd be pretty angry to get a power cutoff right in the middle of class
12:55 Ven Woodi: functional usually refers to referential transparency
12:58 Woodi right, func results can be substituted. but is inlining the same ? :)
13:01 guru joined #perl6
13:02 Ven Woodi: that's what inlining is
13:03 Woodi actually every sub/procedure/function call should have that feature + controlled side effects...
13:03 Ven GHC inlines very agressively. If you have an unsafe function (using unsafePerformIO, for example). you have to mark it yourself as noinline
13:04 [particle] joined #perl6
13:04 Rix joined #perl6
13:04 Woodi so just defaults are more strictly :)
13:05 Ven I think you'll find out you usually don't need "unsafe" functions ;-)
13:05 Woodi I forget 'map' it's functional thing too :)
13:05 Ven I mean, "unsafeCoerce" has "unsafe" it its name. What would you except ?
13:06 Ven I think that's just misleadingly thinking "higher-order functions == functional programming"' which I certainly don't agree with =)
13:06 Woodi Ven: I bet moust functions in Cfamily/Paskal/Basic etc are safe :)
13:06 Ven How so ?
13:07 Ven I bet most functions in Cfamily/Pascal/Basic are some of the unsafest that exist
13:07 Ven The sole fact that these languages have a "null" and no Maybe/Option type makes them pretty bad for functional programming.
13:07 Ven I mean, even java8 has lambdas and Optional.
13:08 Woodi it's potential unsafenest... but usually you pass arguments and get result, that's all...
13:08 Ven "print" is unsafe.
13:08 Woodi ok, probably I am wrong, as usual :)
13:09 Woodi but that FP distinction is a bit artificial
13:09 Ven I'd really recommend to read on Haskell and the IO monad
13:10 * jnthn back
13:10 Ven You basically have 2 ways to deal with side-effects in referentially transparent languages : unique type system or monads (kinda cps)
13:11 Ven I think Clean and Mercury have a unique type system, and you can express monads in most languages (enforce them, not so much)
13:11 Woodi I know about IO monads. but many functions are just helpers, without side effects, just factored some common code...
13:11 Ven And that's fine. They don't have side-effects. They could be memoized and the program would still work the same
13:12 kbaker_ joined #perl6
13:12 Ven (a common mistake is that haskellers don't like side-effects, but some say that's wrong : they like it so much they gave it a dedicated type !)
13:14 Woodi code need to do something, not disappear after calculation is finished :)
13:14 Ven which is why you need an entry point. In haskell, that's your "main"
13:15 Ven In scala (with scalaz), you usually wrap your pureMain in an impure one that calls .run
13:15 Ven (though scala doesn't enforce many things)
13:15 Ven Ah, but I'll get scolded for promoting languages :P
13:16 Woodi I bought lastly Cloujure book, but it's a slooow language...
13:17 cognominal Ven, the problem is that eventually everything gets bundled in it and its difficult to take apart. At least idris has conventions to act on or extract part of the state.
13:17 moritz in #perl6 you're not allowed to complain about slow languages :-)
13:17 Ven I think you mean the JVM is slow ? Didn't you try `lein repl` to test stuff ?
13:17 Woodi moritz: no way !
13:17 cognominal ... as explained here :  http://eb.host.cs.st-andrews.ac.uk/drafts/eff-tutorial.pdf
13:18 Ven cognominal: yeah, I agree, that's usually the main problem. Idris still has some rough edges, though.
13:18 Ven yeah, read that :)
13:18 Woodi Ven: just results from alioth game
13:18 Ven Woodi: mostly jvm startup time
13:19 Ven It's like in rakudo benchmarks : once the JIT has run for a while, it gets really really fast
13:19 JimmyZ rakudo has jit :P
13:20 Ven i think the jvm's jit is a bit more powerful than rakudo's jit, though :P
13:20 Ven for now, at least :p
13:20 JimmyZ rakudo use jvm's jit ;)
13:20 cognominal rakudo has jit, meaning moarbm?  jnthn has worked overnight?  :)
13:20 jnthn Rakudo doesn't have a JIT :)
13:20 Ven uuh, moarvm
13:21 jnthn Taht's a VM's job. :)
13:21 JimmyZ :)
13:21 Ven jvm's JIT is (still) better than moarvm's
13:21 Ven once it reaches full speed, though, cause I've heard moarvm starts up far faster :p
13:21 Woodi do we need JITs at all ? just compile them all...
13:21 jnthn MoarVM's spesh branch JITs to specialized bytecode at the moment. To machine code (which is what folks classically mean by JIT) is to come. :)
13:22 Ven jnthn++ # lots of perf. improvements these days
13:22 jnthn But the "produce machine code" aspect is really just one part of what any modern JIT is doing.
13:23 cognominal that's the visible effect, that's what people see or have heard of.
13:24 JimmyZ what's the difference between tracing jit and method-at-runtime jit ?
13:24 Woodi probably JIT 2nd gen :)
13:24 moritz well, most people just have heard that JIT make stuff fast
13:25 Ven well, in dynamically typed languages, JITs do a lot of what AOT compilers can do in other languages
13:26 JimmyZ http://www.codeproject.com/Articles/34148/JIT-methods-at-runtime
13:26 jnthn JimmyZ: A tracing JIT records the code-path taken through an interpreter, including what conditions hold for that code-path to be valid.
13:27 jnthn JimmyZ: It then produces code for that code path, which may span many methods, with guards to trigger de-opt if the conditions are broken at some point.
13:27 jnthn JimmyZ: Method-JITs tend to JIT methods as a whole.
13:28 jnthn However, trace JIT vs method JIT isn't a binary choice.
13:28 jnthn I see it as more of a scale.
13:28 Woodi ...except JIT do not put that data to some database and must to recalculate with every run :) and not all paths depends on data probably...
13:29 Woodi hmm, feature request !
13:29 Woodi db for jits data, per program :)
13:29 JimmyZ We can have these two sometimes?
13:30 jnthn Woodi: You need to prove the stuff in the database is safe to apply. That may not be a great deal cheaper than calculating it again. Or maybe it can be. But I don't think it's immediately obvious.
13:30 jnthn Woodi: Not to mention fixups mean you can't just read/run.
13:31 Woodi I hoped I can...
13:31 timotimo tadzik: http://www.getdigital.de/Star-Wars-Fan.html - shipping from here should be much less pricey and i like the design more
13:31 Woodi ok, so what JIT do what compilation is missing ?
13:32 tadzik timotimo: the price difference is quite striking, I'm not sure if it will indeed be cheaper
13:33 timotimo wow holy shit i didn't even look at the price there
13:33 jnthn Woodi: Not sure I follow the quesiton...
13:34 rurban joined #perl6
13:35 Woodi jnthn: JIT do something usefull + making native code on demand. what lacks in compilation process in comparision to perfect JIT ?
13:35 jnthn Woodi: Ability to make decisions based on information discovered at runtime.
13:35 jnthn Woodi: And then back out of those decisions if the things they rely on get broken.
13:36 jnthn Woodi: For example, a JVM may inline stuff on the assumption a certain type has no subclasses. But if a new subclass is dynamically loaded at runtime, it has to know to back out of that optimization.
13:36 jnthn Woodi: If you have something eval-like, you can't know when compiling a given unit of code whether that will happen.
13:36 pmurias joined #perl6
13:36 pmurias jnthn: have you seen the graal jvm stuff?
13:37 Woodi pmurias: no
13:37 Woodi jnthn: right, eval is not-compilable :)
13:38 jnthn pmurias: Aware of it, not had chance to dig into the details.
13:38 JimmyZ A Trace-based Java JIT Compiler Retrofitted from a Method-based Compiler: http://researcher.watson.ibm.com/researcher/files/us-pengwu/CGO2011_TraceJIT.pdf
13:39 JimmyZ if someone is interested
13:41 jnthn JimmyZ++ # looks nice
13:42 JimmyZ thanks
13:43 jnthn ugh, headache. :/ Going to lie down for a bit. bbl.
13:47 bluescreen10 joined #perl6
13:48 pdcawley joined #perl6
13:58 btyler joined #perl6
14:09 logie_ joined #perl6
14:11 Woodi pmurias: graal is interesting, seems kind like MOP functionality :)
14:14 thou joined #perl6
14:19 zacts joined #perl6
14:28 guru joined #perl6
14:30 hoverboard joined #perl6
14:40 Ven http://www.jnthn.net/papers/2011-nlpw-classes.pdf  slide 14, shouldn't that `if !%.attributes..` be `if %.attributes...` ? same for methods
14:40 Ven oh I'm blind -.- my bad
14:41 * Ven is not quite used to twigils yet
14:45 Ven r: class Golf { has $!player; has $!tee; method play { $!player.go($!pee) } |; 1
14:45 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Bogus statementâ�¤at /tmp/tmpfile:1â�¤------> [32mee; method play { $!player.go($!pee) } |[33mâ��[31m; 1[0mâ�¤    expecting any of:â�¤        p…»
14:45 Ven r: class Golf { has $!player; has $!tee; method play { $!player.go($!pee) } }; 1
14:45 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Attribute $!pee not declared in class Golfâ�¤at /tmp/tmpfile:1â�¤------> [32mee; method play { $!player.go($!pee) } }[33mâ��[31m; 1[0mâ�¤    ex…»
14:46 Ven r: class Golf { has $!player; has $!tee; method play { $self.'pee' = 1; $!player.go($!pee) } }; 1
14:46 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Quoted method name requires parenthesized arguments. If you meant to concatenate two strings, use '~'.�at /tmp/tmpfile:1�------> [32mer; has $…»
14:47 [Coke] Still no dalek? pushed the daily updates from yesterday
14:49 REPLeffect joined #perl6
14:49 Ven r: { sub postfix:<!>($n) { [*] 1..$n } say 10!; }; say 5!;
14:50 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfileâ�¤Two terms in a rowâ�¤at /tmp/tmpfile:1â�¤------> [32m{ sub postfix:<!>($n) { [*] 1..$n } [33mâ��[31msay 10!; }; say 5!;[0mâ�¤    expecting any …»
14:50 Ven r: { sub postfix:<!>($n) { [*] 1..$n }; say 10!; }; say 5!;
14:50 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«[31m===[0mSORRY![31m===[0m Error while compiling /tmp/tmpfile�Negation metaoperator not followed by valid infix�at /tmp/tmpfile:1�------> [32m!>($n) { [*] 1..$n }; say 10!; }; say 5![33m�[31m;[0m� …»
14:52 * TimToady_ is back home now
14:52 Ven good *, TimToady_
14:53 * TimToady is also back home now
14:53 klapperl joined #perl6
14:57 frettled Amazong!
15:00 frettled After going to one of Damian's Perl masterclasses, and hearing him say that he had regained his enthusiasm for P6, I felt more like doing P6 again, too.
15:00 FOAD joined #perl6
15:01 frettled TimToady: and Damian mentioned that you were working on a Perl 6 book (like Programming Perl?), do you require any external enthusiasm for that? :)
15:01 jnthn TimToady: Glad you made it back safely :)
15:03 kaare_ joined #perl6
15:06 bluescreen100 joined #perl6
15:06 TimToady frettled: I probably need more internal enthusiasm :)
15:07 TimToady or more likely, less enthusiasm for everything else I'm interested in... :)
15:07 treehug88 joined #perl6
15:09 Ven multi sub MAIN('save', $name, :$delete!) { } # can I just get `--delete` as a boolean flag ?
15:10 Ven `Bool :$delete!`, I guess...
15:11 frettled TimToady: ah, well, that's probably beyond even my awesome powers. :)
15:14 benabik Infernal enthusiasm?
15:18 virtualsue joined #perl6
15:23 IllvilJa joined #perl6
15:26 klapperl joined #perl6
15:27 IllvilJa Modules for perl 5 (or at least some of them) can be installed using the package management system (apt-get and friends) on ubuntu.  Am I right that something like that is not in place for perl 6?
15:28 geekosaur I doubt many distributions have any perl 6 modules packaged as yet
15:28 geekosaur it's up to the distributions to do so, not to anyone here
15:29 geekosaur (unless of course someone who has say in someone's distribution packaging is hanging out here...)
15:30 IllvilJa Ok.  If I want to install "panda" on Ubuntu 13.10, what is the best practice there?  I got the package 'rakudo' installed, but 'panda' seem to not have been included with it and there is no separate package with that name.  I assume the best thing is to install panda by hand?
15:30 * IllvilJa is horrified by the length of his own chatlines
15:31 geekosaur meh. sometimes my responses are short; sometimes they're long enough that my client has to break them up to avoid IRC's 512 byte message limit. this ain't twitter
15:32 tadzik IllvilJa: hey
15:32 tadzik IllvilJa: there are basically 3 ways
15:32 tadzik 1) get a Rakudo Star which includes panda and a handful of other modules
15:32 tadzik 2) install panda by hand as described on https://github.com/tadzik/panda
15:32 tadzik 3) use rakudobrew (https://github.com/tadzik/rakudobrew) which installs a specified rakudo and panda for you
15:32 frettled 1) Rakudo Star: http://rakudo.org/downloads/star/
15:32 tadzik frettled++
15:33 IllvilJa tadzik: thanks!  Alternative 2 seem to be the best for me, as i alrady got ubuntu's packaged rakudo installed.
15:34 frettled tadzik++ more! :)
15:34 IllvilJa One of those days someone will create a package for rakudo panda on Ubuntu :-).
15:34 tadzik IllvilJa: you're welcome :) Let me know if it gives you any trouble
15:34 tadzik IllvilJa: btw, which version of rakudo is that?
15:34 frettled IllvilJa: Ubuntu's Rakudo is most likely a few months behind, just so you're aware of that.
15:34 tadzik sometimes, sadly, the versions in linux distros are *quite* old
15:34 tadzik and you may need to checkout and older panda
15:34 tadzik I can help with that too
15:34 IllvilJa frettled, tadzik: that's fine, I don't need bleeding edge.  I'll lookup the version...
15:34 frettled In Trusty, they're on 2013-12
15:35 frettled In Saucy, they're a year behind.
15:35 tadzik it's 2013.03 in my 13.10
15:35 tadzik that's pretty ancient :/
15:35 tadzik IllvilJa: I'll strongly recommend building rakudo yourself
15:35 tadzik it's not much hassle really
15:35 tadzik and will give you a *much* better experience
15:35 IllvilJa Hm.  2013.02.1 is my version, but I think I'll try that one anyway.
15:36 tadzik it's just a matter of 'rakudobrew build moar', and it just takes a couple of minutes
15:36 IllvilJa Hm.  Could be an option.
15:36 tadzik I should make a proper install script for it too
15:36 beastd joined #perl6
15:36 tadzik in fact, I'll do that right away
15:36 IllvilJa I'll give 2013.02.01 already installed a spin though.
15:37 tadzik sure :)
15:37 pmurias Woodi: how does graal seems like a MOP?
15:37 pmurias Woodi: graal/truffle is used to generate a jit from a description of an ast interpreter
15:37 tadzik you may need to checkout panda b7b966b9f3fbd52ee1f4f6 or something
15:37 tadzik it's from one year ago, so that should work
15:38 tadzik rakudo is a bit of a moving target, and I have to keep panda updated constantly :)
15:38 tadzik recent panda is most likely incompatible with 2013.03
15:38 tadzik I didn't even tag it back then :)
15:38 tadzik now I do, when there are breaking changes
15:39 IllvilJa Hm.  It is the need for installing panda in a special way that might defeat the convenience of using the rakudo packaged for ubuntu.
15:39 tadzik I'm afraid so :/
15:39 tadzik so, the alternative: git clone git://github.com/tadzik/rakudobrew.git ~/.rakudobrew && export PATH="$HOME/.rakudobrew/bin:$PATH" && rakudobrew build moar
15:40 tadzik it should work :)
15:40 IllvilJa Maybe I should do that rakudobrew thing... and bug ubuntu package maintainers to update rakudo package and add a compatible panda package to follow along with it.
15:40 anaeem1 joined #perl6
15:40 IllvilJa The reason I run into the need to use panda is that the third line in my intended Perl 6 code looks like 'use JSON::Tiny' ;-).
15:41 IllvilJa But still, 'sudo apt-get  install rakudo' giving a barebones Perl 6 install is a good step forward!
15:41 tadzik :)
15:42 tadzik it odes :)
15:42 tadzik er, it is
15:42 IllvilJa Now we need to get the eco system along as well using apt-get ;-).
15:42 IllvilJa But one step at a time!
15:42 tadzik in a perfect world, we'd have a dedicated ubuntu maintainer in our crew :)
15:43 IllvilJa Y.p
15:43 IllvilJa s/Y\.p/Yep/
15:43 IllvilJa Apologies for the perl FIVE regexp ;-).
15:44 IllvilJa I'm still a n00b at perl 6 regexes.
15:44 tadzik that looks compatible :)
15:44 tadzik r:
15:44 tadzik r: "Y.p".subst(/Y\.p/, "Yep").say
15:44 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«Yep␤»
15:45 IllvilJa Fascinating!
15:47 Ven R: "Y.p".subst(/ 'Y' . 'p' /, 'Yep').say # does it have sigspace by default ?
15:47 [Coke] "we call this a "use mention error"", and I thought of masak.
15:47 Ven r: "Y.p".subst(/ 'Y' . 'p' /, 'Yep').say # does it have sigspace by default ?
15:47 camelia rakudo-parrot 9ff0bc, rakudo-jvm 9ff0bc, rakudo-moar 9ff0bc: OUTPUT«Yep␤»
15:47 Ven \o/
15:52 fridim_ joined #perl6
15:54 jnap joined #perl6
15:58 moritz [Coke]: autoerror? :-)
15:59 denis_boyun joined #perl6
16:04 telex joined #perl6
16:12 Rotwang joined #perl6
16:20 jnthn In p6bench, I suspect Forest Fire would go faster if we removed the use of the deprecated * in bless... :)
16:22 rurban_ joined #perl6
16:30 guru joined #perl6
16:32 falk0n joined #perl6
16:41 jnthn Pushed some more bits :)
16:48 virtualsue joined #perl6
16:49 moritz is dalek dead?
16:50 JimmyZ yeah
16:50 moritz p6eval@feather3:~$ tmux attach
16:50 moritz protocol version mismatch (client 8, server 7)
16:51 hoelzro =(
16:51 dalek joined #perl6
16:51 hoelzro try ps aux | grep tmux to find the pid, and /proc/$TMUX_PID/exe attach
16:51 moritz nah, I've just killed thing thing
16:52 moritz and started again
16:52 jnthn omg you killed thing thing!
16:52 benabik hoelzro++
16:52 jnthn moritz++ # dealek
16:52 jnthn *dalek
16:52 benabik hoelzro: I’d wondered about a good way to do it.  Last time I just reinstalled the old version.
16:52 hoelzro benabik: that works too =)
16:53 hoelzro I can't take the credit for that trick
16:53 hoelzro someone else (on Twitter?) told me about it
16:53 hoelzro but that doesn't make it any less cool
16:53 benabik I’m sure they heard it from someone else too.  :-)
16:58 dalek nqp/multispec: 9c92365 | jnthn++ | src/vm/moar/QAST/QASTOperationsMAST.nqp:
16:58 dalek nqp/multispec: Map setmultispec op for MoarVM.
16:58 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/9c923657ba
16:58 xinming__ joined #perl6
17:00 kaleem joined #perl6
17:04 xinming joined #perl6
17:08 dalek rakudo/multispec: dcd156a | jnthn++ | src/Perl6/Metamodel/ (2 files):
17:08 dalek rakudo/multispec: Start using setmultispec on MoarVM.
17:08 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/dcd156a771
17:08 dalek rakudo/multispec: eca0594 | jnthn++ | src/Perl6/Actions.nqp:
17:08 dalek rakudo/multispec: Auto-gen'd protos don't need special vars.
17:08 dalek rakudo/multispec:
17:08 dalek rakudo/multispec: We will never look at them or use them, so don't waste time/space on
17:08 dalek rakudo/multispec: having them.
17:08 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/eca0594b9f
17:08 vendethiel in perl6, when you do something like `sub foo(Str $a = '')`, does it allocates a `str` everytime ??
17:08 dalek rakudo/multispec: e2cd785 | jnthn++ | src/core/Regex.pm:
17:08 dalek rakudo/multispec: Partial fix to regressions from setmultispec work.
17:08 dalek rakudo/multispec:
17:08 dalek rakudo/multispec: We need to make onlystar protos consistently not show up in caller
17:08 dalek rakudo/multispec: introspection to make this reliable. We need that for not getting
17:08 dalek rakudo/multispec: CALLER:: wrong in thunks anyway, so might as well implement it.
17:08 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/e2cd785916
17:08 vendethiel not getting kicked?
17:09 jnthn vendethiel: No, a '' will come from the constant pool
17:09 jnthn vendethiel: Same for all literal Str, Int, Num...
17:09 ajr_ joined #perl6
17:09 hoverboard joined #perl6
17:10 vendethiel jnthn: cool :). Reading your slides from 2011 is like starting a serie that's over already : you don't have to wait :)
17:12 MayDaniel joined #perl6
17:24 anaeem1_ joined #perl6
17:26 rurban joined #perl6
17:27 kurahaupo joined #perl6
17:34 kurahaupo left #perl6
17:39 rurban_ joined #perl6
17:50 kurahaupo joined #perl6
18:06 kurahaupo_mobile joined #perl6
18:08 FROGGS joined #perl6
18:09 SamuraiJack_ joined #perl6
18:14 kurahaupo joined #perl6
18:16 rurban joined #perl6
18:18 kurahaupo_mobile joined #perl6
18:47 spider-mario joined #perl6
19:01 dwarring joined #perl6
19:02 Ulti https://launchpad.net/ubuntu/+source/rakudo/2013.12-1 this is surprisingly up to date!
19:03 FROGGS nice!
19:09 nebuchadnezzar joined #perl6
19:12 denis_boyun_ joined #perl6
19:14 bluescreen__ joined #perl6
19:17 dalek nqp/multispec: b6ff62f | jnthn++ | src/QAST/Block.nqp:
19:17 dalek nqp/multispec: Add is_thunk to QAST::Block.
19:17 dalek nqp/multispec:
19:17 dalek nqp/multispec: For now just as another attribute; there's now 3 of these that could
19:17 dalek nqp/multispec: flatten into a single attribute of flag bits.
19:17 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/b6ff62fcff
19:17 dalek nqp/multispec: 3b9d36e | jnthn++ | src/vm/moar/QAST/QASTCompilerMAST.nqp:
19:17 dalek nqp/multispec: Pass is_thunk on down to Moar backend.
19:17 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/3b9d36e288
19:17 dalek nqp/multispec: 92536f6 | jnthn++ | src/vm/moar/QAST/QASTOperationsMAST.nqp:
19:17 dalek nqp/multispec: Map ctx[caller|outer]skipthunks for MoarVM.
19:17 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/92536f6225
19:17 rurban joined #perl6
19:31 dalek rakudo/multispec: d54d2b3 | jnthn++ | src/Perl6/Actions.nqp:
19:31 dalek rakudo/multispec: Mark onlystar protos as thunks.
19:31 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/d54d2b3d84
19:31 dalek rakudo/multispec: 83adc48 | jnthn++ | src/core/ (4 files):
19:31 dalek rakudo/multispec: Assorted updates now that onlystars are thunks.
19:31 dalek rakudo/multispec:
19:31 dalek rakudo/multispec: This fixes many long-standing inconsistencies when we skip over any
19:31 dalek rakudo/multispec: onlystar protos. The multispec optimization forced the issue, but it
19:31 dalek rakudo/multispec: has existed for a couple of years, since we started inlining or doing
19:31 dalek rakudo/multispec: multi-sub compile time call optimization. Note, updates will be needed
19:31 dalek rakudo/multispec: for the JVM and Parrot backends to cope with these changes.
19:31 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/83adc48d46
19:34 virtualsue joined #perl6
19:34 jnthn multispec is looking good on Moar now, spectest wise.
19:35 rurban joined #perl6
19:35 timotimo i'm kind of getting the feeling that "thunk" may be overused now
19:36 molaf joined #perl6
19:36 jnthn It's consistent enough with other uses of it.
19:37 cooper joined #perl6
19:37 timotimo OK
19:37 dalek nqp/multispec: d8f9b63 | jnthn++ | tools/build/MOAR_REVISION:
19:37 dalek nqp/multispec: Bump MOAR_REVISION to one with multispec.
19:37 dalek nqp/multispec:
19:37 dalek nqp/multispec: This also happens to get spesh.
19:37 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/d8f9b637f8
19:37 jnthn (including the one already in Actions.pm)
19:43 jnthn So, now to update things for Parrot...
19:43 jnthn Then JVM
19:43 arnsholt jnthn: Is there much to be gained from merging boolean attributes into flag bits, in your estimation?
19:44 rindolf joined #perl6
19:44 jnthn arnsholt: 16 bytes per QAST::Block
19:44 arnsholt Might relieve GC pressure a bit I guess, but I'm guessing maybe not terribly much in terms of setting compile time?
19:45 arnsholt Oh, that'll turn into quite a bit for something like the setting, won't it
19:45 spider-mario_ joined #perl6
19:45 jnthn Dunno exaclty how much. It own't be a huge saving, but it'll probably be measurable.
19:46 jnthn There must easily be a few thousands blocks in there
19:46 benabik Less GC pressure is less GC runs.  Probably not a big difference though.
19:47 jnthn "Every little helps" :)
19:51 btyler gs
19:51 btyler whoops, wrong window, this isn't git :)
19:52 moritz btyler: it's called "bs" :-)
19:54 * jnthn guesses that's a short alias for git status :)
19:54 btyler bingo
19:56 jnthn I get tempted to do myself more aliases.
19:56 jnthn But I teach Git these days, and switching away from the aliases is kinda argh. I'd end up using them in class 'cus they'd get hard-wired into my fingers. :)
19:57 anocelot btyler: Once I did that with the wrong keyboard and polluted an IRC channel to the tune of 6+ commands.  >.>
19:57 btyler for sure. the downside to 'gs' is that when I'm on a system where my .*rcs aren't present, I invoke ghostscript quite frequently
19:57 geekosaur that kind of thing is why I don't use such aliases
19:58 geekosaur I have to use other systems quite frequently, on some of them my aliases are neither present nor appropriate
19:58 * vendethiel always loses time when "ne" is not available as an "emacs" alias
20:05 treehug88 joined #perl6
20:07 [Coke] https://github.com/perl6/specs/blob/master/S99-glossary.pod should include thunk.
20:17 * moritz thinks he can do that
20:21 dalek specs: f705069 | moritz++ | S99-glossary.pod:
20:21 dalek specs: [glossary] explain thunk
20:21 dalek specs: review: https://github.com/perl6/specs/commit/f7050694e1
20:21 jnthn I'm glad you thunk to...
20:22 timotimo thunks
20:36 rurban joined #perl6
20:37 effbiai joined #perl6
20:38 moritz r: say MY.^name
20:38 camelia rakudo-parrot 1fe14b, rakudo-jvm 1fe14b, rakudo-moar 1fe14b: OUTPUT«MY␤»
20:38 moritz r: say MY::.^name
20:39 camelia rakudo-parrot 1fe14b, rakudo-jvm 1fe14b, rakudo-moar 1fe14b: OUTPUT«PseudoStash␤»
20:40 jnap1 joined #perl6
20:40 benabik r: say MY::.^name.perl
20:41 camelia rakudo-parrot 1fe14b, rakudo-jvm 1fe14b, rakudo-moar 1fe14b: OUTPUT«"PseudoStash"␤»
20:41 benabik Nope, it’s benabik.  Nice try though.
20:42 dalek specs: 749198b | moritz++ | S99-glossary.pod:
20:42 dalek specs: Add some more glossary terms
20:42 dalek specs: review: https://github.com/perl6/specs/commit/749198b7f2
20:50 * [Coke] sees moritz favors british plurals!
20:51 [Coke] moritz: s/oppositise/opposites/
20:51 [Coke] s/belogns/belongs/
20:52 geekosaur does that make it belogna?
20:59 dalek specs: f39d20e | moritz++ | S99-glossary.pod:
20:59 dalek specs: typos, [Coke]++
20:59 dalek specs: review: https://github.com/perl6/specs/commit/f39d20eb21
21:00 segomos timotimo: are you supernovous?
21:01 timotimo no, that's the other timo
21:05 itz joined #perl6
21:05 sjn_ joined #perl6
21:05 itz_ joined #perl6
21:11 btyler joined #perl6
21:17 dayangkun joined #perl6
21:17 virtualsue joined #perl6
21:18 anaeem1__ joined #perl6
21:22 dalek nqp/multispec: 55feaad | jnthn++ | src/vm/parrot/QAST/ (2 files):
21:22 dalek nqp/multispec: is_thunk and ctx[caller|outer]skipthunks on Parrot
21:22 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/55feaad8a1
21:22 dalek rakudo/multispec: edccc49 | jnthn++ | src/core/Backtrace.pm:
21:22 dalek rakudo/multispec: A cheat for Parrot to fix failing tests.
21:22 dalek rakudo/multispec:
21:22 dalek rakudo/multispec: This along with the NQP patch gets this branch fuctioning well on
21:22 dalek rakudo/multispec: Parrot; the multispec itself isn't used, but the improvements to proto
21:22 dalek rakudo/multispec: and CALLER::/OUTER:: pseudo-package interaction now work out on Parrot,
21:22 dalek rakudo/multispec: and future fixes to OUTER:: with regard to thunks should work too.
21:22 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/edccc49559
21:22 jnthn 2 down, 1 to go... :)
21:23 timotimo glad to hear it
21:30 dalek roast: a97910a | (David Warring david.warring@gmail.com)++ | integration/advent2012-day0 (2 files):
21:30 dalek roast: adding advent 2012 days 2 and 3
21:30 dalek roast: review: https://github.com/perl6/roast/commit/a97910aef2
21:30 dalek roast: e7d8def | (David Warring david.warring@gmail.com)++ | integration/advent2012-day04.t:
21:30 dalek roast: adding 2012 day 4
21:30 dalek roast:
21:30 dalek roast: This is reasonably expensive (20sec @moar - 1min @jvm). Should maybe be a stress test.
21:30 dalek roast: review: https://github.com/perl6/roast/commit/e7d8deff76
21:34 jnthn Should really be one, yes... :)
21:34 cxreg jnthn: not to be an ingrate but it's been like 2.5 months since your last 6guts post, it'd be nice to get an update :)
21:35 jnthn cxreg: 2.5 months? o.O
21:35 jnthn Doesn't time fly... :)
21:36 cxreg it really does
21:36 jnthn I've been meaning to write one about the optimization stuff I've been working on. I should get to that. :)
21:36 cxreg jnthn++
21:38 jnthn Thanks for the reminder. Had my head down in the code for quite a while I guess...but it's useful to talk about what I'm doing a bit too :)
21:39 timotimo cxreg: if you need a "what's new and cool in perl6" fix, you can look at p6weekly.wordpress.com to find my ramblings :)
21:39 cxreg timotimo++ awesome
21:55 treehug88 joined #perl6
22:06 Exodist joined #perl6
22:06 JimmyZ joined #perl6
22:06 risou joined #perl6
22:06 larks joined #perl6
22:06 jercos_ joined #perl6
22:07 woosley joined #perl6
22:07 Alula joined #perl6
22:11 corecatcher timotimo++ thanks for your p6weekly summary
22:14 timotimo yw :)
22:15 timotimo early bedtime today
22:15 dalek nqp/multispec: 46d1e20 | jnthn++ | src/vm/jvm/ (8 files):
22:15 dalek nqp/multispec: is_thunk and ctx[caller|outer]skipthunks on JVM
22:15 dalek nqp/multispec: review: https://github.com/perl6/nqp/commit/46d1e2006f
22:15 timotimo gnite
22:15 timotimo hooray!
22:16 jnthn 'night, timotimo :)
22:16 jnthn Hopefully you might be able to run us a bench tomorrow :)
22:16 timotimo jnthn: did you have time yet to measure if this offsets the overhead added by adding the multi methods for assign and stuff?
22:16 timotimo ah
22:16 timotimo yeah, i can do that
22:16 jnthn timotimo: Oh, on Moar we're doing hash and array assignments in under half the time we used to.
22:17 timotimo oh crap!
22:17 timotimo that's excellent!
22:18 jnthn I think we can get spesh to do a PIC-ish thing and get better still too
22:19 colomon joined #perl6
22:19 timotimo position independent code?
22:20 jnthn polymorphic inline cache
22:20 jnthn Like what we do for methods
22:21 timotimo what exactly would be cached there?
22:21 jnthn Two types.
22:21 jnthn Or one.
22:21 jnthn Depends on the call arity
22:21 jnthn And the candidate
22:22 timotimo and that's not already happening 'cuz it's a method call anyway?
22:22 jnthn So we can very quickly right there in the interp go to the typical case.
22:22 timotimo even though*
22:22 jnthn Well, this is about invoke rather than lookup
22:22 jnthn Of course, if we can statically work out what multi candidate we're gonna hit in spesh thanks to the caching...that's even better. :)
22:22 timotimo oh
22:22 timotimo yeah, it would
22:22 timotimo okay, bedtimes for now, benchtimes for tomorrow
22:23 jnthn :)
22:23 jnthn sleep well
22:23 timotimo hopefully better than last night :S
22:23 jnthn oh, you're sleeping badly this week too? :S
22:24 * TimToady is just sleeping at the wrong time of day for some reason :)
22:32 jnthn TimToady: I just can't guess why... :)
22:36 TimToady for a moment I was blaming the backlog for putting me to sleep...
22:37 TimToady but that doesn't seem so likely now
22:38 rurban joined #perl6
22:41 dalek rakudo/multispec: 2b99556 | jnthn++ | src/Perl6/Actions.nqp:
22:41 dalek rakudo/multispec: Unbust build on JVM.
22:41 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/2b99556a00
22:41 dalek rakudo/multispec: 1a61362 | jnthn++ | tools/build/Makefile-JVM.in:
22:41 dalek rakudo/multispec: Don't try running Parrot test on JVM.
22:41 dalek rakudo/multispec:
22:41 dalek rakudo/multispec: It skips rather than blows up, but it's still pointless to try.
22:41 dalek rakudo/multispec: review: https://github.com/rakudo/rakudo/commit/1a61362861
22:46 jnthn OK, seems multispec is good on the various backends...
22:46 dalek nqp: 9c92365 | jnthn++ | src/vm/moar/QAST/QASTOperationsMAST.nqp:
22:46 dalek nqp: Map setmultispec op for MoarVM.
22:46 dalek nqp: review: https://github.com/perl6/nqp/commit/9c923657ba
22:46 dalek nqp: b6ff62f | jnthn++ | src/QAST/Block.nqp:
22:46 dalek nqp: Add is_thunk to QAST::Block.
22:47 dalek joined #perl6
22:49 dalek rakudo/nom: dcd156a | jnthn++ | src/Perl6/Metamodel/ (2 files):
22:49 dalek rakudo/nom: Start using setmultispec on MoarVM.
22:49 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/dcd156a771
22:49 dalek rakudo/nom: eca0594 | jnthn++ | src/Perl6/Actions.nqp:
22:49 dalek rakudo/nom: Auto-gen'd protos don't need special vars.
22:49 dalek joined #perl6
23:05 lizmat joined #perl6
23:06 jnthn o/ lizmat
23:06 jnthn heh :)
23:08 lizmat joined #perl6
23:08 lizmat o/ jnthn
23:08 dalek nqp: fcae3c9 | (Andrew Egeler)++ | src/HLL/Compiler.nqp:
23:08 dalek nqp: Fix REPL ctx-saving bug
23:08 dalek nqp:
23:08 dalek nqp: This fixes a REPL bug: If a command had no output, $*MAIN_CTX wasn't
23:08 dalek nqp: being saved. This means, for example, 'use Test' (no output), followed
23:08 dalek nqp: by 'ok True' on the next line would throw an error (as if 'use Test' was
23:08 dalek nqp: never run).
23:08 dalek nqp: review: https://github.com/perl6/nqp/commit/fcae3c900e
23:10 woolfy joined #perl6
23:11 jnthn lizmat: You might have a slightly faster spectest with today's work :)
23:11 lizmat well, for now I can't build after a Configure  :-(
23:11 jnthn Oh.
23:12 jnthn Why?
23:12 lizmat MoarVM op 'setmultispec' is unknown as a core or extension op
23:12 lizmat at gen/moar/stage1/QAST.nqp:1435  (gen/moar/stage1/QAST.moarvm::53)
23:12 lizmat from gen/moar/stage1/QAST.nqp:1419  (gen/moar/stage1/QAST.moarvm:moarop_mapper:31)
23:12 jnthn huh
23:12 jnthn I bumped MOAR_REVISIOn and NQP_REVISION, I thought...
23:12 lizmat after doing a perl Configure.pl --gen-moar --gen-nqp --backends=moar
23:12 TimToady do we still need =master
23:12 TimToady ?
23:13 jnthn Shoudln't
23:13 jnthn oh, wait
23:13 jnthn yeah, I screwed up the bump
23:13 jnthn Sorry
23:14 dalek nqp: 28688ac | jnthn++ | tools/build/MOAR_REVISION:
23:14 dalek nqp: Fix MoarVM revision bump.
23:14 dalek nqp: review: https://github.com/perl6/nqp/commit/28688ac909
23:14 dalek rakudo/nom: f85ac4e | jnthn++ | tools/build/NQP_REVISION:
23:14 dalek rakudo/nom: Get correct Moar version, REPL fix.
23:14 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f85ac4e4fa
23:15 bluescreen10 joined #perl6
23:15 jnthn lizmat: That should work out better.
23:15 lizmat already pulled, building now
23:20 * jnthn hopes it works out better :)
23:20 lizmat builds ok, spectesting now
23:21 lizmat some errors in depreciations
23:22 jnthn huh...I got those cleaned up, I thought...
23:22 jnthn uh
23:22 jnthn no, I didn't push that patch
23:22 jnthn gah
23:24 lizmat Files=801, Tests=31033, 195 wallclock secs ( 8.39 usr  3.75 sys + 1282.07 cusr 94.43 csys = 1388.64 CPU)
23:24 dalek nqp: 80fcbf7 | jnthn++ | tools/build/MOAR_REVISION:
23:24 dalek nqp: Get Moar with backtrace generation thunk fixes.
23:24 dalek nqp: review: https://github.com/perl6/nqp/commit/80fcbf7438
23:24 lizmat not much difference, I'm afraind  :-(
23:24 jnthn lizmat: Uh, it was above 200 yesterday, no?
23:24 lizmat no, it was already at ~193 or so
23:24 jnthn Ah
23:25 jnthn Got a little faster for me.
23:25 jnthn But only by a few seconds.
23:25 lizmat Files=801, Tests=31033, 195 wallclock secs ( 8.40 usr  3.95 sys + 1281.41 cusr 100.53 csys = 1394.29 CPU)
23:25 lizmat was one from yesterday
23:26 jnthn hm, k
23:26 jnthn Oh...
23:26 jnthn But guess you also got the spesh merge now.
23:27 jnthn And it's a little over-eager to specialize at the moment, which means we slowed startup a small amount.
23:27 jnthn I was comparing with that yesterday vs. today
23:27 lizmat ack
23:27 jnthn Anyway, that means your spectest looks good with spesh :)
23:28 TimToady is multispec merged now?
23:28 jnthn TimToady: Yeah.
23:28 dalek rakudo/nom: e498597 | jnthn++ | tools/build/NQP_REVISION:
23:28 dalek rakudo/nom: Get Moar backtrace/thunk interaction fix.
23:28 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e498597947
23:28 jnthn TimToady: And the assign_pos work.
23:29 TimToady \o/
23:29 jnthn while_array_set from p6bench is running in under half the time it used to take.
23:30 TimToady does @foo[$bar][$baz] = $blech; use assign_pos?
23:30 jnthn should
23:30 jnthn lemme check
23:31 jnthn uh, it is but with a vaveat
23:31 jnthn *caveat
23:31 jnthn That is, it relies on a WHENCE for the auto-viv aspect of it.
23:32 jnthn So it's one WHENCE, not 2.
23:32 TimToady 1st level is still auto..what you said
23:32 jnthn Where is the -1 check meant to go, ooc?
23:32 jnthn Or negative indexing generally
23:33 jnthn At present, Rakudo has it in postcircumfix:<[ ]>
23:33 TimToady I'd think you can report it as soon as you notice it
23:33 TimToady standard semantics never allow -1 for a .[]
23:33 jnthn Well, at present we do:
23:34 jnthn multi sub postcircumfix:<[ ]>( \SELF, \pos ) is rw { fail "Cannot use negative index $(pos) on $(SELF.WHAT.perl)" if pos < 0; SELF.at_pos(pos);
23:34 jnthn }
23:34 jnthn gah, paste fail
23:34 jnthn That fail, with current stuff, frustrates inlining the postcircumfix
23:34 TimToady well, it's really just a lower bounds check
23:35 TimToady and you'll still want bounds checks after inlining
23:35 jnthn Yeah; it's the fail call that we can't inline.
23:35 TimToady (modulo proofs of unneededness)
23:35 TimToady why not?
23:36 TimToady it was never really the intent that fail be implemented mandatorily via "return"
23:37 jnthn The fixable reason is that we never inline anything that makes a sub call 'cus we don't do the scoping analysis to ensure the inline won't lead to a different answer.
23:37 jnthn That is, the "I know how to fix it" reason
23:37 TimToady well, fail was envisioned more as an alternate return
23:37 jnthn The fact fail ends up needing a return handler installing is the trickier bit.
23:37 TimToady can you inline something with a normal return yet?
23:38 lizmat joined #perl6
23:38 jnthn No, unless the return is vanished.
23:38 jnthn I suspect that wants fixing, though.
23:38 TimToady well, if it vanised by turning into a goto END instead...
23:38 TimToady *sh
23:38 jnthn Yeah, quite...
23:38 TimToady and fail can do the same
23:38 woolfy joined #perl6
23:38 TimToady at top level
23:38 jnthn It's all do-able, it's just in the "more than a few hours work" category :)
23:39 rurban joined #perl6
23:39 TimToady well, you almost have more than a few hours till dawn...
23:39 jnthn :P
23:39 jnthn I also slept awfully earlier in the week, so I should probably sleep :)
23:40 * TimToady wishes you sweet (or absent) dreams
23:40 jnthn Anyway, was just seeing if it was in the right place before I went worrying over if I need to work out how to get that inline blocker dealt with... :)
23:40 TimToady well, can't know index till runtime mostly
23:40 jnthn Right.
23:41 jnthn I wasn't sure if the answer was going to be "at_pos should be checking it"
23:41 TimToady though could probably notice that you're using an index over a known range
23:41 jnthn (on the basis that some array types should allow negative indexes and so we want to leave it up to the type)
23:41 TimToady well, you'll just run into the same issue when you go to inline at_pos :)
23:41 jnthn Well, that's different though
23:42 jnthn That's a method. The compile-time inliner doesn't go for those; they're left for the VM.
23:42 BenGoldberg joined #perl6
23:42 jnthn Whereas postcircumfixes are subs so we could inline them.
23:42 TimToady the intent is that .[] be limited to non-negatives by design, and you use .{} for other stuff
23:42 jnthn OK. Then it's in the right place and I'll just need to fathom the inline. :)
23:43 jnthn oh...the other question on that...
23:43 TimToady or forcing people to use .() for fancy stuff isn't so bad
23:43 jnthn Should we be promising at_pos that we give it an Int index?
23:43 jnthn Oh, wait
23:43 jnthn oh, hm
23:43 jnthn I was gonna say @a[Inf]
23:44 jnthn But all it does is whine about that :)
23:44 jnthn It may be more efficient if at_pos can expect an Int and the postcircumfix is meant to provide it with one.
23:44 jnthn But not enough to make it worth doing if it's a pain language-design wise.
23:44 * TimToady is all in favor of efficiency these days
23:44 * lizmat is too tired to follow what is going on here...
23:45 TimToady at_pos is only sort of user-facing
23:45 jnthn Yeah
23:45 lizmat seems it is more efficient to get some sleep
23:45 jnthn lizmat: Probably ;)
23:45 TimToady it's fine to limit to Int
23:45 jnthn OK, I'll play with that tomorrow then.
23:45 jnthn I think we can get it to work out better than way.
23:45 TimToady seems likely to me too
23:46 jnthn The other thing I can do if I really feel like cheating is just have the optimizer spot that the postcircumfix candidate list matches the CORE.setting one exactly and cheat.
23:46 jnthn Rather than making it fall out of the general inlining mechanism.
23:47 jnthn The latter is what I want eventually, of course.
23:47 TimToady the autoviv on non-last dimension only happens if you didn't preallocate anyway
23:47 jnthn *nod*
23:47 jnthn And you only pay the cost the first time anyway.
23:48 jnthn After that it's viv'd and it's just an at_pos access
23:48 TimToady 'course, forest copies the array each time through
23:48 jnthn Yeah
23:48 jnthn The other thing that's really costing us, looking at Moar traces, is creating scalar containers.
23:48 TimToady yes, cheating on the builtin types doesn't feel much like cheating to me
23:49 TimToady assign_pos to natives should help a lot there
23:49 jnthn I'm wondering just how much Moar can escape analyze them away too.
23:50 * TimToady has no feelings about that
23:50 jnthn I think it can make a decent shot at it, but it's not entirely trivial to implement.
23:50 jnthn Probably worth it though.
23:50 TimToady anyway, Perl has always separated array access from hash access so that arrays could be fast
23:50 jnthn *nod*
23:50 TimToady so you can still bank on that
23:51 jnthn Mebbe I'll work on teaching the optimizer to do some better analysis on variables tomorrow.
23:51 jnthn (Perl6::Optimizer that is)
23:52 jnthn The other thing is that since WHENCE is a less common case, we might be able to make every scalar 8 bytes smaller.
23:52 jnthn If we can have a way of using a mixin-y thing for those that want it.
23:53 jnthn Or subtype...
23:53 TimToady or even a bit in the header, worst case
23:53 jnthn Well, lots to ponder...
23:54 jnthn *sigh* I need to deal with Moar's strings at some point too...
23:54 TimToady might be able to help some with that, since that's one of my passions
23:55 jnthn ooh :)
23:55 jnthn NFG? ;)
23:56 TimToady that's how they've labeled my code at times :)
23:56 jnthn Could do with some more general cleanups/opts first, though.
23:56 jnthn haha :D
23:56 jnthn Anyways, I should rest... :)
23:56 jnthn 'night
23:56 TimToady o/
23:56 rurban joined #perl6
23:58 segomos joined #perl6

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

Perl 6 | Reference Documentation | Rakudo