Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2010-06-26

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:04 dalek rakudo: ea8f2bb | chromatic++ | src/binder/bind.c:
00:04 dalek rakudo: [src] Hoisted more STRINGs to constants in binder.
00:04 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/ea8f2bb1f03ca0c29c912f65f848257608cf29c7
00:04 dalek rakudo: aa66397 | chromatic++ | src/binder/bind.c:
00:04 dalek rakudo: [src] Hoisted more binder STRINGs to constants.
00:04 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/aa663972014def7136a50bda281ece017735c55f
00:04 dalek rakudo: 4e3a1a1 | chromatic++ | src/pmc/objectref_pmc.template:
00:04 dalek rakudo: [PMC] Promoted a frequent STRING to a CONST_STRING.
00:04 dalek rakudo: ObjectRef's string "$!OBJECTREF" can safely be a constant.  This is a minor
00:04 dalek rakudo: optimization.
00:04 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/4e3a1a1724eb15aabadabc81193b102a123658b9
00:11 [Coke] joined #perl6
00:12 colomon TimToady: re slurp.words versus lines.words, in Rakudo slurp is not lazy, and lines is.  That makes slurp vs lines very important...
00:12 colomon afk # bathing
00:17 [Coke] is there a way in NQP to get a ref to a named sub, or do you have to use pir to do that?
00:23 sorear just use the name of the sub
00:23 sorear nqp: sub foo() {}; say(foo)
00:23 p6eval nqp: OUTPUT«foo␤»
00:23 sorear nqp: sub foo() {}; say(pir::typeof(foo))
00:23 p6eval nqp: OUTPUT«The opcode 'typeof_p' (typeof<1>) was not found. Check the type and number of the arguments␤current instr.: 'parrot;PCT;HLLCompiler;evalpmc' pc 1047 (compilers/pct/src/PCT/HLLCompiler.pir:554)␤»
00:23 sorear nqp: sub foo() {}; say(pir::typeof__sp(foo))
00:23 p6eval nqp: OUTPUT«Sub␤»
00:23 [Coke] ah, had tried &foo
00:25 [Coke] ... and my failure was due to a missing ; before that anyway. arg.
00:27 lue afk
00:33 ash_ ping moritz_?
00:41 masonkramer joined #perl6
00:45 TimToady colomon: but .words is not defined on a list currently
00:46 TimToady so you'd have to use lines».words
00:47 TimToady or we define $*IN.words, or make words also default to argfiles
00:47 Visitor99 joined #perl6
00:48 TimToady but a "double split" by both lines and words really bugs me for some reason
00:50 plobsing joined #perl6
01:16 Guest1208 joined #perl6
01:36 colomon joined #perl6
02:09 spinclad joined #perl6
02:30 TiMBuS joined #perl6
02:46 Solarion joined #perl6
02:51 ash_ std: 0b0001010;
02:51 p6eval std 31449: OUTPUT«ok 00:01 109m␤»
02:51 ash_ std: 0x123
02:51 p6eval std 31449: OUTPUT«ok 00:01 107m␤»
02:51 fridim joined #perl6
02:51 ash_ std: 0xdeadbeef;
02:51 p6eval std 31449: OUTPUT«ok 00:01 106m␤»
02:52 ash_ std: 0xg
02:52 p6eval std 31449: OUTPUT«[31m===[0mSORRY![31m===[0m␤Whitespace is required between alphanumeric tokens at /tmp/8hYbX5DbXP line 1:␤------> [32m0[33m⏏[31mxg[0m␤Whitespace is required between alphanumeric tokens at /tmp/8hYbX5DbXP line 1:␤------> [32m0x[33m⏏[31mg[0m␤Undeclared routine:␤      'g'
02:52 p6eval ..used a…
02:52 ash_ std: 0o09
02:52 p6eval std 31449: OUTPUT«[31m===[0mSORRY![31m===[0m␤Whitespace is required between alphanumeric tokens at /tmp/xSYBzEd0HH line 1:␤------> [32m0o0[33m⏏[31m9[0m␤Two terms in a row at /tmp/xSYBzEd0HH line 1:␤------> [32m0o0[33m⏏[31m9[0m␤    expecting any of:␤  POST␤   bracketed infix␤   infix or
02:52 p6eval ..meta-i…
02:53 ash_ std: 0x07
02:54 p6eval std 31449: OUTPUT«ok 00:01 107m␤»
02:54 ash_ std: 0o77
02:54 p6eval std 31449: OUTPUT«ok 00:01 107m␤»
02:55 redicaps joined #perl6
03:01 meppel joined #perl6
03:07 * colomon is in your compilerz, programming in PIR
03:10 lue ohai i brok PIR bai
03:17 patspam joined #perl6
03:19 colomon pmichaud: new version of number interpreting code is still a bit slower than the old version (22 sec versus 15 sec to execute my all number test) but as far as I can tell (spectest still in progress) it is correct.  I think this version is a winner.
03:33 envi^home joined #perl6
03:36 hercynium joined #perl6
03:48 jrtayloriv joined #perl6
03:59 mepplock joined #perl6
04:06 jaldhar joined #perl6
04:11 JimmyZ joined #perl6
04:12 Guest23195 joined #perl6
04:13 redicaps left #perl6
04:19 ash_ anyone home?
04:19 ash_ anyone have any comments on http://greaterthaninfinity.com/shell/ (its not functional yet, it's only pretending for now)
04:20 ash_ you can try doing things like putting in "my $a = 'Hello World';"
04:20 ash_ it syntax highlights (sorta)
04:21 sorear are you using the STD highighter?
04:21 ash_ when your typing in the text-area box and press enter, it sends the current contents
04:21 ash_ no, i just made it up in the last hour
04:21 ash_ its very incomplete, but its a start
04:22 ash_ shift + enter lets you put a new line in the textarea box
04:22 ash_ so if you want to write multiple lines before you return, you can
04:22 ash_ the textbox grows too, if you do more than 1 line
04:22 ash_ clear
04:22 ash_ will clear the screen
04:22 sorear Q:PIR { exit }
04:23 sorear →Confused at line 1, near "a * 3\n"
04:23 ash_ oh thats a fake error code
04:23 ash_ its not actually executing anything
04:23 ash_ every 3 lines it puts that out
04:23 sorear so you put in random fake errors?
04:23 ash_ so i could test what an error might look like
04:23 sorear har har
04:23 ash_ its not executing it at all currently, so yup...
04:24 sorear ok, I'll stop trying to crack your webserver
04:24 ash_ sorear: does it look semi-okay so far to you?
04:24 ash_ lol, its all static so far so good luck
04:24 sorear yes
04:24 * sorear jokes
04:25 ash_ it can do number literals too, (with the 0x 0o 0d 0b variants)
04:26 ash_ oops, i forgot to allow $_ as a variable
04:27 ash_ well, just wanted to show someone else that
04:33 ash_ msg moritz_ I got a basic interface started, http://greaterthaninfinity.com/shell/ if you want to see it, it doesn't execute anything yet, it just is a front end. You can try out the console, it does some basic syntax highlighting too
04:33 ash_ hmm
04:34 ash_ is the message bot down?
04:34 sorear no
04:34 sorear you're just on a different network
04:34 sorear you used purl syntax
04:34 sorear phenny: tell ash_ this is how we do messages here.
04:34 phenny sorear: I'll pass that on when ash_ is around.
04:35 ash_ ah, oops
04:35 phenny ash_: 04:34Z <sorear> tell ash_ this is how we do messages here.
04:35 ash_ phenny: tell moritz_ I got a basic interface started, http://greaterthaninfinity.com/shell/ if you want to see it, it doesn't execute anything yet, it just is a front end. You can try out the console, it does some basic syntax highlighting too, comments or questions are welcome
04:35 phenny ash_: I'll pass that on when moritz_ is around.
04:35 ash_ heading to bed &
05:07 ciphertext colomon: ping
05:42 orafu joined #perl6
05:48 ciphertext left #perl6
06:00 moritz_ ash_: shell looks very good, thank you
06:00 phenny moritz_: 04:35Z <ash_> tell moritz_ I got a basic interface started, http://greaterthaninfinity.com/shell/ if you want to see it, it doesn't execute anything yet, it just is a front end. You can try out the console, it does some basic syntax highlighting too, comments or questions are welcome
06:01 ashleydev joined #perl6
06:16 diakopter moritz_: to answer your question, I don't know
06:17 diakopter it's currently at a crossroads while sorear explores many design options.
06:17 diakopter my tuits aren't so round lately
06:25 mberends joined #perl6
06:26 mberends im in ur belgianperlworkshop, drinkin ur coffee
06:26 moritz_ mberends: fakedbi them!
06:27 mberends heh, morning moritz_ :)
06:27 moritz_ good morning
06:34 mberends overnight I got about half of HTTP::Server::Simple::PSGI ported and working
06:35 moritz_ wow - sever case of insomnia? :-)
06:35 moritz_ *severe
06:36 mberends during coach journey from London :)
06:36 moritz_ :-)
06:36 mberends had a nice day teaching P5 to noobs in a company
06:37 mberends yesterday
06:48 Su-Shee joined #perl6
06:50 Visitor99 left #perl6
06:55 zkw joined #perl6
06:58 cls_bsd joined #perl6
07:20 xinming joined #perl6
07:22 dalek csmeta: r344 | stefa...@cox.net++ | trunk/vicil/ (2 files):
07:22 dalek csmeta: [vicil] Rationalize separation of Scope/CallFrame and Body/Code
07:22 dalek csmeta: review: http://code.google.com/p/csmeta/source/detail?r=344
07:22 pugssvn r31450 | moritz++ | fudge series tests for Rakudo
07:24 xenor joined #perl6
07:24 dalek rakudo: 6769e19 | moritz++ | t/spectest.data:
07:24 dalek rakudo: series-simple.t is gone, series-nonnueric.t works now
07:24 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/6769e197b23515e06f0566fdb28024afe6c2e989
07:26 xenor left #perl6
07:27 sjohnson joined #perl6
07:28 tylercurtis joined #perl6
07:33 tylercurtis rakudo: say [\+] [\+] 1 xx 5
07:33 p6eval rakudo ea8f2b:  ( no output )
07:33 tylercurtis pugs: say [\+] [\+] 1 xx 5
07:33 p6eval pugs: OUTPUT«1361015␤»
07:34 mberends joined #perl6
07:35 moritz_ rakudo: say ([\+] 1 xx 5).perl
07:35 p6eval rakudo ea8f2b: OUTPUT«(1, 2, 3, 4, 5)␤»
07:35 moritz_ rakudo: say ([\+] ([\+] 1 xx 5)).perl
07:35 p6eval rakudo ea8f2b: OUTPUT«()␤»
07:35 moritz_ wow, that's a weird bug
07:35 moritz_ tylercurtis: do you want to submit it? or should I?
07:36 tylercurtis rakudo: say ([\+] [[\+] 1 xx 5])
07:36 p6eval rakudo ea8f2b: OUTPUT«1361015␤»
07:36 moritz_ rakudo: say ([\+] [[\+] 1 xx 5]).perl
07:36 p6eval rakudo ea8f2b: OUTPUT«(1, 3, 6, 10, 15)␤»
07:37 tylercurtis moritz_: I'm not particularly familiar with RT, so I'd be grateful if you would.
07:37 moritz_ rakudo: say ([\+] (1, 2, 3, 4 5)).perl
07:37 p6eval rakudo ea8f2b: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 11␤»
07:37 moritz_ rakudo: say ([\+] (1, 2, 3, 4, 5)).perl
07:37 p6eval rakudo ea8f2b: OUTPUT«(1, 3, 6, 10, 15)␤»
07:37 moritz_ tylercurtis: sure, will do
07:38 Mowah joined #perl6
07:40 tylercurtis moritz_: Thanks.
07:41 moritz_ rakudo: say [\+] [\+] 1, 1
07:41 p6eval rakudo ea8f2b:  ( no output )
07:45 sorear rakudo: say ([\+] 1, 1).WHAT
07:45 p6eval rakudo ea8f2b: OUTPUT«List()␤»
07:45 sorear rakudo: say (1, 1).WHAT
07:45 p6eval rakudo ea8f2b: OUTPUT«Parcel()␤»
07:45 mmcleric joined #perl6
07:46 sorear rakudo: say (1, 2 ... 5).WHAT
07:46 p6eval rakudo ea8f2b: OUTPUT«List()␤»
07:46 sorear rakudo: say [\+] (1, 2 ... 5)
07:46 moritz_ rakudo: say (1 xx 5).WHAT
07:46 p6eval rakudo ea8f2b: OUTPUT«1361015␤»
07:46 p6eval rakudo ea8f2b: OUTPUT«List()␤»
07:46 moritz_ sorear: the curious thing is that [\+] [ [\+] @list ]  works
07:47 moritz_ erm, "works"
07:47 sorear it shouldnt'...
07:47 moritz_ I know
07:48 tadzik joined #perl6
07:49 Mowah joined #perl6
07:55 moritz_ funny thing is, when I add a pir::printerr__vs($list.perl);
07:55 moritz_ after line 161 in src/core/metaops.pm
07:55 moritz_ it works
08:00 perl7 joined #perl6
08:03 Ross joined #perl6
08:07 jnthn oh lol I'm at a Perl event
08:11 moritz_ jnthn: which one? .be?
08:12 jnthn moritz_: Indeed.
08:13 * jnthn thinks it'll .be a good one :-)
08:19 jnthn hmmm
08:20 jnthn rakudo: my @squares = (0..*).map: { $^x * $^y };
08:20 jnthn rakudo: my @squares = (0..*).map: { $^x * $^y }; say "ok";
08:20 jnthn Is that not lazy yet?
08:20 p6eval rakudo ea8f2b:  ( no output )
08:20 p6eval rakudo ea8f2b:  ( no output )
08:22 sorear jnthn: correct, map isn't lazy
08:22 synth joined #perl6
08:22 sorear rakudo thinks that map == for
08:23 TiMBuS but what about mapiter?
08:24 jnthn that's...odd.
08:24 moritz_ no
08:24 moritz_ it's the = that's not lazy
08:24 jnthn I think it's array storage
08:24 moritz_ map itself is
08:24 TiMBuS that makes more sense
08:24 jnthn moritz_: ah.
08:24 jnthn :-(
08:25 jnthn rakudo: for 1..* -> $n { say $n * $n; last if $n > 10; }
08:25 p6eval rakudo ea8f2b: OUTPUT«1␤4␤9␤16␤25␤36␤49␤64␤81␤100␤121␤»
08:25 jnthn heh, for is lazy now, huh. :-)
08:26 moritz_ well
08:27 moritz_ only the evaluation of its argument
08:27 TiMBuS rakudo: my $squares = (0..*).map: { $^x * $^y }; $squares[4];
08:27 p6eval rakudo ea8f2b:  ( no output )
08:27 moritz_ if it were lazy itself, it wouldn't do anything
08:27 TiMBuS wuh
08:27 jnthn moritz_: *NOD8
08:27 jnthn doh, keyboard fail
08:35 sorear I feel like there was something in one of the Synopses that explained "class" in terms of a sequence of calls to ClassHOW, but I can't find it with grep
08:38 sorear Am I only imagining this?
08:41 jnthn sorear: I think S12 has language along those lines
08:41 jnthn sorear: Though ClassHOW is not explicitly mentioned.
08:44 envi^home joined #perl6
08:54 prz_ joined #perl6
08:54 sorear I'm also kinda interested to know about knowhow
08:54 sorear std: augment knowhow class { ... }
08:54 p6eval std 31450: OUTPUT«[31m===[0mSORRY![31m===[0m␤Can't augment knowhow class without MONKEY_TYPING at /tmp/xPTP3RbneW line 1:␤------> [32maugment knowhow class [33m⏏[31m{ ... }[0m␤Potential difficulties:␤  Can't augment knowhow class because it doesn't exist at /tmp/xPTP3RbneW line 1:␤------>
08:54 p6eval ..[…
09:01 jnthn sorear: I'm interested too - I want to gradually take Rakduo's metamodel to have that primitive as a foundation.
09:01 jnthn And write our ClassHOW and RoleHOW in terms of it.
09:23 sorear jnthn: what *is* the primitive, though?
09:23 jnthn sorear: afaik, it's a "pure prototype"
09:23 sorear It's not mentioned in the synopses and it has no tests
09:23 jnthn sorear: Indeed, it's not spec yet.
09:23 sorear This will be something to discuss in the meeting, I guess
09:23 jnthn sorear: Nor is the metamodel API.
09:24 jnthn sorear: It's one of those things where I expect the implementations will need to decide what is agreeable accross them to be spec, and what will be implementation specific.
09:24 sorear Under what conditions are you allowed to augment a class by adding a new attribute
09:24 sorear ?
09:24 jnthn sorear: At the end of the day, the decision is taken by the metaclass.
09:24 sorear I mean, for the default metaclass
09:24 jnthn e.g. it can throw an exception from add_attribute if the class was already composed
09:25 jnthn For ClassHOW, I'm not sure.
09:25 sorear Obviously JoeHOW can decide however it wants
09:25 jnthn My impression is that you are meant to be allowed to.
09:25 jnthn But it's...ugh...to implement. :-S
09:26 jnthn The spec doesn't say "certainly yes" or "certainly no" either.
09:26 sorear What does it mean to compose a class, and when does it happen?
09:27 jnthn Composition time is when we do things like compose in the roles, detect missing required methods and conflicts, produce a type object...
09:27 jnthn It happens after the class has been fully defined
09:28 sorear At the closing brace?  Or CHECK?
09:28 jnthn I believe it's meant to happen at the closing brace.
09:28 jnthn So in theory
09:28 jnthn class C { method foo() { say 42 } }; BEGIN { C.foo } # should work
09:29 * moritz_ has a case of totally wrong line number
09:29 jnthn OH NOES
09:29 jnthn moritz_: How rong is rong?
09:29 moritz_ jnthn: line 67 for a 30 line file
09:29 jnthn lol
09:30 moritz_ rakudo: class A { has $.x is rw }; A.new.x(5)
09:30 p6eval rakudo 6769e1: OUTPUT«too many positional arguments: 2 passed, 1 expected␤  in main program body at line 67␤»
09:30 moritz_ you see, line 67
09:30 jnthn ..
09:30 jnthn wtf.
09:30 jnthn Epic fail!
09:30 * moritz_ submits rakudobug
09:30 jnthn plz to file ... yes that :-)
09:33 moritz_ rakudo: class A { has $.x  }; A.new.x(5)
09:33 p6eval rakudo 6769e1: OUTPUT«too many positional arguments: 2 passed, 1 expected␤  in main program body at line 65␤»
09:33 moritz_ hey, not quite so rong :-)
09:33 jnthn ooooooh!
09:33 * sorear .o( sub die($exn) { my $f = callframe; while $f { if $f.exception-skip-to -> $nf { $f = $nf; next }; if $f.exception-handler -> $h { return $h($exn); }; $f = $f.caller; }; note("Internal error: exception handling ran off end"); exit(1); } )
09:34 jnthn moritz_: Look at src/metamodel/attribute.nqp line 67 ;-)
09:34 moritz_ I guess the accessor is somewhere... right
09:34 jnthn lol
09:34 sorear (this is what I'm planning to use in sprixel)
09:35 jnthn It's one of those accuracy wins that's a fail too. :-)
09:35 sorear (implementing die in Perl feels so good)
09:35 moritz_ sorear: that looks cute
09:36 agentzh joined #perl6
09:39 sorear that handles Perl 6's weird unwind rules, including rethrows and restartable exceptions
09:40 sorear it relies on an outermost CATCH to handle backtraces, though
09:41 sorear also won't work in any implementation where return is powered by die
09:42 Ambiguity joined #perl6
09:45 moritz_ sorear: you can control the outermost CATCH by providing it in your setting
09:45 moritz_ I think it's reasonable to expect people to handle such cases when they write their own setting
09:54 M_o_C joined #perl6
09:55 Miles8 joined #perl6
09:56 Miles8 Anyone seen this perl 6 logo? http://kraih.com/camelia-sri.png
09:56 tadzik yep
09:56 sorear _sri told us first
09:57 * sorear ponders the nature of inline NQ-C#
09:57 tadzik oh, and by the way, just out of curiosity, why is it CATCH not catch?
09:57 jnthn tadzik: All of the phaser-ish blocks are uppercase.
09:57 jnthn So just consistency.
09:57 tadzik phaser-ish?
09:57 jnthn e.g. FIRST, LAST, etc.
09:57 tadzik ah
09:58 moritz_ BEGIN, END, INIT, CHECK, PRE, POST
09:58 jnthn tadzik: Things that run at certain "special" times rather than just where they are placed in your code.
09:58 tadzik I see
09:58 sorear there's a big list of them at S04:1225
09:58 Miles8 any input on why he seems to been shoot down for making  a logo that isn't actually repulsive like the one vurrently used?
09:59 sorear "shoot down"?
09:59 sorear where?
09:59 moritz_ Miles8: afaict nobody shot him down
09:59 moritz_ Miles8: it's only that there's not the one person who tells him to shape his logo so it becomes the official one
09:59 moritz_ that's just not how the Perl 6 community works
10:00 nadim joined #perl6
10:00 moritz_ I really liked his suggestions, and I know others did too
10:00 Miles8 true but from what I read he has given up hope of getting his  suggestions accepted in any way
10:01 moritz_ Miles8: yes, that's unfortunate
10:01 huf it's the best perl logo i've seen so far
10:01 huf but then, who am i to call this ;)
10:01 moritz_ but what do you expect from us, truely? that we magically create a person how answers his questions?
10:01 sorear Miles8: read where?
10:02 Miles8 I quote him "The Perl 6 decision makers are sadly not interested in the logos, so i'm not finishing them."
10:02 Miles8 on the Mojolicious mailinglist
10:02 jnthn On the logo it's probably "person" :-)
10:02 jnthn That said, the implementations can pick what they want for a logo. :-)
10:02 jnthn Rakudo has its own, for example.
10:04 * sorear doesn't think he's seen Rakudo's logo
10:04 huf is it the japanese wooden gate thing?
10:04 moritz_ http://rakudo.org/
10:04 jnthn sorear: it's on rakudo.org
10:04 moritz_ http://rakudo.org/sites/default/files/logo.png
10:05 * jnthn figures the writing actually says Rakudo :-)
10:08 sorear oh yes I have seen that.
10:08 dalek csmeta: r345 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
10:08 dalek csmeta: [vicil] Expand scope of KERNEL a bit
10:08 dalek csmeta: review: http://code.google.com/p/csmeta/source/detail?r=345
10:09 * sorear out
10:09 jnthn o/
10:12 Miles8 I hope perl6.org gets a new logo cause even if implementations can choose there on perl6.org is still gonna be the first thing a lot of new perl6 users will see and rigth now those are either repulsted by the logo or go in to epileptic shock
10:13 Miles8 *on=own.
10:14 Miles8 or they thinks it some kindergarden drawing page an they are on the wrong website
10:15 jnthn I love how some people take their own dislike of it to mean everybody will feel that way.
10:17 TiMBuS did he just leave in fear of some backlash from his last comment?
10:17 TiMBuS jeez..
10:18 jnthn Heh
10:18 jnthn I got bored of such discussions long ago.
10:18 jnthn Design is muchly a subjective thing.
10:19 Su-Shee left #perl6
10:19 jnthn I know some people don't like Camelia, but I'm not convinced we could come up with a logo that everyone would like.
10:20 sjohnson jnthn: http://eppy7890.files.wordpress.com/2009/06/joe_camel.jpg
10:20 sjohnson :)
10:21 sjohnson bed time &
10:21 jnthn :-)
10:21 jnthn night
10:24 azert0x joined #perl6
10:24 tadzik joined #perl6
10:24 meppl joined #perl6
10:26 azert0x joined #perl6
10:28 azert0x joined #perl6
10:32 azert0x joined #perl6
10:34 azert0x joined #perl6
10:37 azert0x joined #perl6
10:48 moritz_ rakudo: my $x = given 4 { when Int { $_ } }; say $x
10:48 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Confused at line 11, near "my $x = gi"␤»
10:49 moritz_ std: my $x = given 4 { when Int { $_ } }; say $x
10:49 p6eval std 31450: OUTPUT«[31m===[0mSORRY![31m===[0m␤Word 'given' interpreted as a listop; please use 'do given' to introduce the statement control word at /tmp/gCRzHsPXEq line 1:␤------> [32mmy $x = [33m⏏[31mgiven 4 { when Int { $_ } }; say $x[0m␤Unexpected block in infix position (two terms in a
10:49 p6eval ..r…
10:49 moritz_ rakudo: my $x = do given 4 { when Int { $_ } }; say $x
10:49 p6eval rakudo 6769e1: OUTPUT«4␤»
11:01 tadzik joined #perl6
11:02 felliott joined #perl6
11:13 whiteknight joined #perl6
11:16 [Coke] joined #perl6
11:22 pmurias joined #perl6
11:31 cognominal (1, $b, 2) == (1, 2)  # Is there a $b value that could satisfy that predicate? It would be so convenient.
11:35 cognominal Nil is not what I want here.
11:35 cognominal or at least it does no beheva that way in rakudo.
11:36 cognominal rakudo: say (1, Nil, 2).perl
11:36 p6eval rakudo 6769e1: OUTPUT«(1, (), 2)␤»
11:36 cognominal rakudo: say [1, Nil, 2].perl
11:36 p6eval rakudo 6769e1: OUTPUT«[1, 2]␤»
11:36 cognominal ha!!
11:37 jnthn rakudo:  rakudo: say (1, Nil, 2).flat.perl
11:37 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Confused at line 11, near "rakudo: sa"␤»
11:37 jnthn grrrr
11:37 jnthn rakudo: say (1, Nil, 2).flat.perl
11:37 p6eval rakudo 6769e1: OUTPUT«(1, 2)␤»
11:37 cognominal I should remember that parcel are no arrays...
11:37 xinming say (1, (), 2).perl
11:38 xinming rakudo: (1, (), 2).perl
11:38 p6eval rakudo 6769e1:  ( no output )
11:38 xinming rakudo: say (1, (), 2).perl
11:38 p6eval rakudo 6769e1: OUTPUT«(1, (), 2)␤»
11:39 cognominal jnthn++
11:41 timbunce joined #perl6
11:41 jnthn yayitstimbunce!
11:41 moritz_ rakudo: say (1, (), 2) == (1, 2)
11:41 p6eval rakudo 6769e1: OUTPUT«0␤»
11:41 jnthn I suspect numifying a parcel doesn't first flatten
11:42 timbunce jnthn: Hi. I'm adding #perl6 to the list of channels I join automatically. I guess that means something.
11:43 colomon moritz_: [\+] [\+] isn't a weird bug at all, it's a perfectly expected closure issue.
11:44 pugssvn r31451 | pmurias++ | [smop] [mildew] smop supplies the correct gcc flags to mildew at test time so that the .m0ld tests run
11:45 mberends hi timbunce, we're both talking about Perl 6 and databases at YAPC::EU :) it would be good to compare notes/plans to make sure we don't contradict each other ;-)
11:46 moritz_ colomon: well, I didn't perfectly expect it
11:46 timbunce mberends: great - please join #dbdi
11:46 mberends ok
11:46 colomon moritz_: when closures finally get fixed, a lot of stuff is going to magically start working.  :)
11:48 jnthn :-)
11:57 jnthn std: for 0 { when ARRAY {} }
11:57 p6eval std 31450: OUTPUT«[31m===[0mSORRY![31m===[0m␤Function 'ARRAY' needs parens to avoid gobbling block at /tmp/2olCsm5nex line 1:␤------> [32mfor 0 { when ARRAY[33m⏏[31m {} }[0m␤Missing block (apparently gobbled by 'ARRAY') at /tmp/2olCsm5nex line 1:␤------> [32mfor 0 { when ARRAY
11:57 p6eval ..{}[33m⏏[31m…
12:00 synth joined #perl6
12:03 mberends hugme: add timbunce to fakedbi
12:03 * hugme hugs timbunce. Welcome to fakedbi!
12:13 pnate joined #perl6
12:14 sykes_ joined #perl6
12:14 constant joined #perl6
12:14 mberends joined #perl6
12:15 nadim joined #perl6
12:26 envi^home joined #perl6
12:26 orafu joined #perl6
12:26 TiMBuS joined #perl6
12:26 stepnem joined #perl6
12:26 Lorn joined #perl6
12:26 japhb joined #perl6
12:26 slavik joined #perl6
12:26 dmpk2k_ joined #perl6
12:27 stepnem joined #perl6
12:33 timbunce Running an uninstalled perl6 from a diferent directory gets a far less than awesome error message ("Null PMC access in find_method('new_class')". I know the docs say this'll happen but it's a likely newbie error and seems worth a better message.
12:37 timbunce (In my case I had a perl6 symlink in my ~/bin directory to the perl6 binary. That was handy for running the latest build without needing to install. Used to work fine. I've updated the symlink now.)
12:40 colomon rakudo: say "THis is a test".words
12:40 p6eval rakudo 6769e1: OUTPUT«THisisatest␤»
12:40 colomon rakudo: say "THis is a test".words.perl
12:40 p6eval rakudo 6769e1: OUTPUT«("THis", "is", "a", "test")␤»
12:41 masonkramer joined #perl6
12:43 jnthn timbunce: Aye, we had a nicer one in alpha but I forget how we did it. Should really check...
12:44 Rohaq joined #perl6
12:45 mikehh joined #perl6
12:46 timbunce is there are pastebin for the channel?
12:48 timbunce rakudo: class java::io::Writer { multi method append( Str $v1, Int $v2, Int $v3, --> Object) { ... } }
12:48 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Malformed method at line 11, near "append( St"␤»
12:49 timbunce That used to work (months ago). Has the syntax changed?
12:51 timbunce rakudo: role java::sql::RowId { multi method equals(  Object $v1, --> Bool ) { ... } }
12:51 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Invalid typename in parameter declaration at line 11, near " $v1, --> "␤»
12:51 jnthn That , before the --> looks odd
12:51 mberends timbunce: http://paste.lisp.org/new/perl6 used to announce on #perl6, but lately we got spammed, so now we must announce manually
12:52 jnthn std:  role java::sql::RowId { multi method equals(  Object$v1 --> Bool ) { ... } }
12:52 p6eval std 31451: OUTPUT«[31m===[0mSORRY![31m===[0m␤In parameter declaration, typename 'Object' must be predeclared (or marked as declarative with :: prefix) at /tmp/B3cPNYRnv6 line 1:␤------> [32mql::RowId { multi method equals(  Object[33m⏏[31m$v1 --> Bool ) { ... } }[0m␤Parse failed␤FAILED
12:52 p6eval ..00:01…
12:52 jnthn std:  role java::sql::RowId { multi method equals(  Object $v1 --> Bool ) { ... } }
12:52 p6eval std 31451: OUTPUT«[31m===[0mSORRY![31m===[0m␤In parameter declaration, typename 'Object' must be predeclared (or marked as declarative with :: prefix) at /tmp/xY6ZUPxjTB line 1:␤------> [32mql::RowId { multi method equals(  Object[33m⏏[31m $v1 --> Bool ) { ... } }[0m␤Parse failed␤FAILED
12:52 p6eval ..00:0…
12:52 jnthn std:  role java::sql::RowId { multi method equals(  Mu $v1 --> Bool ) { ... } }
12:52 p6eval std 31451: OUTPUT«ok 00:01 111m␤»
12:52 jnthn std:  role java::sql::RowId { multi method equals(  Mu $v1, --> Bool ) { ... } }
12:52 p6eval std 31451: OUTPUT«ok 00:01 111m␤»
12:52 jnthn hmm, std is OK wiht the comma. Surprises me a little.
12:52 timbunce but Object -> Mu is the main fix. ok
12:53 TimToady it's just the principle that you can have an extra comma on the end of a list
12:53 timbunce TimToady: makes the code generation a little easier
12:57 pmichaud good morning, #perl6
12:57 M_o_C joined #perl6
12:58 mberends pmichaud, o/ from Belgium
13:08 colomon rakudo:  say 0.707106781186547
13:08 p6eval rakudo 6769e1: OUTPUT«0.707106781186547␤»
13:09 colomon rakudo:  say 707106781186547
13:09 p6eval rakudo 6769e1: OUTPUT«707106781186547␤»
13:15 jnthn o/ pmichaud
13:15 hugme joined #perl6
13:15 TimToady ohio
13:15 timbunce Is there a way to ask rakudo for the list of builtin types and roles?
13:15 moritz_ hugme: show java2perl
13:15 hugme moritz_: the following people have power over 'java2perl': P⁣erlJam, T⁣imToady, [⁣particle], c⁣olomon, j⁣nthn, m⁣asak, m⁣berends, m⁣oritz_, p⁣michaud, t⁣imbunce. URL: http://github.com/timbunce/java2perl/
13:16 moritz_ hugme: add moritz to java2perl
13:16 hugme moritz_: ERROR: Can't add moritz to java2perl:  HTTP/1.1 401 Unauthorized
13:16 moritz_ urg
13:17 TimToady rakudo: say CORE::.keys
13:17 p6eval rakudo 6769e1: OUTPUT«Could not find sub &CORE␤  in main program body at line 11:/tmp/9tC8BMMJdE␤»
13:17 whiteknight joined #perl6
13:17 jnthn ENOTYET
13:17 TimToady std: say CORE::.keys
13:17 p6eval std 31451: OUTPUT«ok 00:01 111m␤»
13:18 timbunce ok, thanks
13:19 timbunce rakudo: role java::sql::Ref { multi method getObject(  KeyHash $v1 --> Mu ) { ... } }
13:19 jnthn timbunce: Though if you don't need a programatic solution, grep through src/gen/core.pm for class and role
13:19 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Invalid typename in parameter declaration at line 11, near " $v1 --> M"␤»
13:20 TimToady or just keep trying random names till you probabalistically get them all  :)
13:21 colomon TimToady: wouldn't it be much more efficient to use Str.succ to systematically go through all possible names?  ;)
13:21 timbunce jnthn: I don't see KeyHash, for example, in there. TimToady: shouldn't take tooo long!
13:21 colomon lazily, I mean, of course.
13:21 TimToady pugs/src/perl6/CORE.setting has a more concise list, but doesn't necessarily match rakudos
13:22 timbunce It's not that important for now, after all the spec's not changing all that often :)
13:22 timbunce rakudo: role java::sql::Ref { multi method getObject(  KeyHash $v1 --> Mu ) { ... } }
13:22 p6eval rakudo 6769e1: OUTPUT«===SORRY!===␤Invalid typename in parameter declaration at line 11, near " $v1 --> M"␤»
13:22 timbunce std: rakudo: role java::sql::Ref { multi method getObject(  KeyHash $v1 --> Mu ) { ... } }
13:22 p6eval std 31451: OUTPUT«ok 00:01 111m␤»
13:22 pmichaud (KeyHash NYI in rakudo)
13:22 TimToady STD's setting will be closer to spec, and rakudo's will be closer to what's actually implemented :)
13:23 dalek rakudo: 1424333 | (Solomon Foster)++ | src/ (2 files):
13:23 dalek rakudo: Rewrite the Actions handling of dec_number (ie Rat and Num constants) to work
13:23 dalek rakudo: properly if the various components of the number are too long to hold in an Int.
13:23 dalek rakudo: Still needed:
13:23 dalek rakudo: Cleanup.
13:23 dalek rakudo: Porting this solution to Int constants.
13:23 dalek rakudo: Making prefix:<+>(Str) use these methods.
13:23 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/14243332367952f66a101291e35b4e0af85e2cb5
13:23 timbunce Anyone suggest a reasonable mapping for java.util.Map in rakudo?
13:25 moritz_ hugme: add mberends to java2perl
13:25 hugme moritz_: ERROR: Can't add mberends to java2perl:  HTTP/1.1 401 Unauthorized
13:26 timbunce I'll use just Hash for now.
13:26 moritz_ hash stringies its key
13:26 moritz_ is that OK?
13:26 TimToady by default, which is all rakudo implements
13:27 TimToady seems like it would be pretty trivial to hash on $key.WHICH to get object hashes
13:28 TimToady though you'd have to be careful to include the WHAT as well for value types
13:29 TimToady or 2 and "2" might hash the same
13:29 timbunce moritz_: at this stage I'm happy if the thousands of lines of perl6 (that java2perl6 generates for the JDBC API) just compiles :)
13:42 nimiezko joined #perl6
13:56 TimToady colomon: Str.succ won't work, unless you seed it with patterns like AaaaaAAA
14:06 TimToady <sorear> In light of the existance of the \|$foo parameter form, is a Perl 6 implementation obliged to handle $*foo(:a, :b) differently from $*foo(:b, :a)  ?
14:06 TimToady yes, capturization must be JIT in that case, since there's no proto
14:07 TimToady (and you can see how far back I've fallen on backlogging...)
14:09 timbunce The DateTime type is 'built-in" in the sense that you don't need a 'use', yet it's not listed in the "Built-In Data Types" section in S02. That seems like a doc bug.
14:09 colomon TimToady: do it all lowercase, and map the results through a transform that gets all the possible case variations -- that's just like counting in binary.  :)
14:10 TimToady it won't find ACME::Don't either
14:11 colomon errr... actually, that's a good series question.  what should 'a' ... * do?
14:11 pmichaud 'a', 'b', 'c', ... 'z', 'aa', 'ab', 'ac', ...
14:11 colomon that's current spec, I believe.
14:12 TimToady that seems more useful than ... "\x10ffff"
14:12 pmurias joined #perl6
14:12 pmichaud > my @a = 1..*;  say @a[4];
14:12 pmichaud 5
14:12 pmichaud (we can haz array laziness)
14:12 colomon but it seems a bit inconsistent that 'a' ... some single character high in unicode will go all single chars, but 'a' ... * wraps at 'z'.
14:12 colomon \o/
14:13 pmichaud colomon: I don't see that as being inconsistent at all, really
14:13 TimToady but * isn't a single character, and has "maximize" semantics
14:13 colomon pmichaud: we weren't even sure if that was spec or not.  :)
14:13 TimToady the single char rule only comes into effect if both ends are single
14:13 pmichaud to me,  'a' ... *   says "increment forever"
14:13 pmichaud or, more accurately,   .succ forever
14:13 colomon TimToady: okay, works for me, and already works.
14:14 TimToady pmichaud: what does it do about lists that it doesn't know are finite/infinite?
14:14 TimToady like the result of a gather?
14:14 colomon afk # "hoop!"
14:14 pmichaud at the moment it continues to eagerly evaluate them.
14:15 pmichaud I've added a .infinite() method to iterators, it returns zero for "known finite", one for "known infinite", and Mu for "not known"
14:15 pmichaud (actually, False, True, Mu)
14:15 TimToady do we need a method for pushing to the imaginary part of an array?
14:15 TimToady .pushlist or some such
14:16 pmichaud I haven't looked at that part yet.
14:16 pmichaud istr we decided that we did.
14:16 TimToady how does it add to its imaginary part internally?
14:16 Trashlord joined #perl6
14:16 TimToady I think we bikeshedded names, but I don't recall settling on one
14:17 pmichaud internally, List  (and thus Array)   has two attributes, @!items and @!rest
14:17 pmichaud both are low-level VM arrays
14:17 TimToady .schedule .imagine .suggest etc
14:17 pmichaud @!items contains the "already reified" elements, @!rest contains the yet-to-be-reified elements
14:17 TimToady I think the original apocalypse had .specs
14:20 TimToady .pushmore .pileon .append .notyet ...
14:20 jnthn pmichaud: (array laziness) yay!
14:20 moritz_ .project .plan
14:21 TimToady .plan is pretty good
14:21 jnthn pmichaud: I tried that this morning to demonstrate today ;-)
14:21 moritz_ TimToady: might be confusing if we offer a sub form
14:21 moritz_ TimToady: because of use Test; plan 1;
14:21 TimToady right
14:23 TimToady extend @array, list()  reads well
14:24 TimToady but is semantically a bit too concrete
14:24 TimToady abstrude :)
14:24 TimToady no way, that would extrude abstractly
14:24 TimToady hmm
14:24 moritz_ schedule is just like plan, but without the colllision
14:25 pmichaud hmmm, I'm getting spectest failz though
14:25 TimToady perhaps a bit too time oriented
14:25 TimToady queue is more the idea
14:25 TimToady oh, I remember
14:25 TimToady we had .feed
14:25 pmichaud oh, I know why.
14:25 TimToady feed @array, 1 ... *
14:25 colomon Is the issue that we're pushing to the @rest, or that we're pushing something that might itself be infinite?
14:26 moritz_ TimToady: I like feed
14:26 TimToady the idea is that we're taking whatever we have and putting it into @rest, regardless
14:26 pmichaud colomon: one piece of the puzzle is figuring out the laziness of whatever we're pushing, though
14:26 simcop2387 joined #perl6
14:26 colomon shouldn't push always add to @rest if there is something there?
14:26 pmichaud when doing     push @a, $b;   we really want to make sure we get the value of $b now and not the value of $b "whenver we get to it"
14:27 TimToady I think feed forces it into the lazy part, or possibly pulls known-finite off the front if @!rest starts out empty
14:27 pmichaud and if @a has something infinite in it already, we might not reify it "right away"
14:27 pmichaud for example:
14:27 TimToady colomon: I think push is eager, so reifies everything
14:27 colomon I guess part of my problem is it feels to me like we are too eager to make arrays unlazy, and are making ourselves a lot of work in the progress.
14:28 pmichaud colomon: eagerness is the natural expectation
14:28 jnthn I thought push would always put onto the @!rest
14:28 pmichaud jnthn/colomon:  *it does*
14:28 pmichaud that's not the issue.
14:28 jnthn Oh
14:28 jnthn ah
14:28 jnthn @foo.push: $a, $b, $c; # we want the $a, $b, $c at this time?
14:28 TimToady the point is the expected semantics, and p5 programmers at least will expect push to behave eagerly
14:28 pmichaud if @!rest has something lazy in it already, then whatever we push gets lazily evaluated, even if someone expects it to be eager
14:28 pmichaud for example:
14:29 jnthn @foo.plan: $a, $b, $c; # reify later
14:29 pmichaud my @b = <a b c>;   push @a, @b;  @b[1] = 'x';
14:29 pmichaud does @a  "see" the 'x' or no?
14:29 pmichaud if we just stick @b onto @a's lazy part, then we might not have gotten around to reifying it yet
14:30 jnthn *nod*
14:31 pmichaud (yes, we can turn the arguments to 'push' into a Seq and push those... which is effectively what we're doing, but still some 'lazy' parts might hide the evaluation of some non-lazy parts
14:31 pmichaud however, since we're also speculating about a method to de-containerize parcels, we could potentially do that to the slurpy parts of push/unshift
14:31 colomon it seems like what we should be doing is somehow cloning the array at the point of copy.  or some sort of COW arrangement.
14:31 pmichaud then laziness isn't such a big issue
14:32 pmichaud colomon: errr.... what copy?  ;-)
14:32 colomon point of push.
14:32 pmichaud there's no copy inherent in push
14:32 pmichaud at least, not yet.  :-)
14:32 TimToady I think @array.push(1..*) should probably say "You can't push an infinite list; please use feed instead"
14:34 TimToady and I think we should try to keep the eager method separate from the lazy method so people get used to thinking about it, instead of mysteriously having it guess wrong on the unknowns
14:34 pmichaud TimToady: I agree fully.
14:34 pmichaud that's certainly the conservative approach for now
14:34 pmichaud we have enough to fix in Rakudo in the next four weeks without also trying to explore every avenue of laziness :)
14:35 TimToady if at some point we say, well push and feed are really the same thing, then they're just good documentation :)
14:35 TimToady and (...) ==> my @foo is naturally mapped to .feed
14:36 colomon and feed will work properly for ....
14:36 TimToady hmm, actually, .feed is then really <<==
14:36 colomon errr....
14:36 colomon my @b = <a b c>;  feed @a, @b;  @b[1] = 'x';
14:36 TimToady since it appends
14:36 colomon does that get the 'x' in @a?
14:36 araujo joined #perl6
14:37 pmichaud my guess is that falls in the realm of "depending on lazy evaluation"
14:37 TimToady that would depend on whether it does the "pull in concrete values"
14:37 moritz_ colomon: yes
14:37 colomon that still seems really icky to me.
14:38 colomon really, really icky.
14:38 pmichaud ...which is why .push is eager :)
14:38 TimToady feed should not be taking side effects into account
14:38 TimToady and yes, we know where to find push
14:38 pmichaud > my @a = 1..*;  say @a.elems
14:38 pmichaud Inf
14:39 TimToady however, one more thing to think about.  What about my @a = 1,2,3; feed @a, @a
14:39 colomon wait, shouldn't some sort of COW be easy with lazy arrays?
14:40 rv2733 joined #perl6
14:40 moritz_ MU! (SCNR :)
14:40 colomon you copy @items eagerly, then attach the iterator for @rest.
14:41 colomon if you change the source array later, it has to iterate to the point of the change.
14:41 pmichaud colomon: you're assuming that all of the things in @!rest are immutable
14:41 colomon the copied @rest stays the same.
14:41 colomon isn't that the point of the new iterator arrangement?
14:41 pmichaud no.
14:41 pmichaud you're assuming that @rest contains only iterators
14:42 pmichaud what @!rest really contains is iterables
14:42 colomon oh
14:42 TimToady perhaps we're going to have long term confusion as long as iterators and iterables have such similar names
14:43 pmichaud we could potentially change it to contain iterators, but we've already said that if you change an underlying iterable while it has active iterators that the results are undefined
14:43 colomon afk # off to nom-grower's nomstore
14:43 TimToady chow
14:43 pmichaud TimToady: so far "Iterable" and "Iterator" have worked really well for me.  I'd like them to remain.
14:43 TimToady was just wonderin'
14:44 TimToady I know that wasn't the confusion point here
14:45 TimToady packing &
14:46 ciphertext joined #perl6
14:51 colomon the confusion point here is that (from the naive point of view), we've got two different functions to do the same thing, neither of which actually does what the user actually expects... # gone for real now...
14:53 ash_ moritz_: ping
14:53 moritz_ ash_: pong
14:53 moritz_ ash_: I've seen your web shell demonstration
14:53 moritz_ It's really great
14:53 ash_ any comments?
14:54 ash_ i need to do some work with the colors
14:54 ash_ but that shouldn't be to difficult to fix
14:54 * moritz_ has only very little aesthetic judgement when it comes to colors
14:55 moritz_ ash_: have you committed it to the repo?
14:55 ash_ no, i don't think i have permissions
14:55 moritz_ ash_: my fault... what's your github ID?
14:55 ash_ ashgti
14:56 moritz_ hugme: add ashgti to try.rakudo.org
14:56 * hugme hugs ashgti. Welcome to try.rakudo.org!
14:56 moritz_ there you go
14:56 ash_ thanks
14:59 ash_ should the default be that Return sends the command you have written? or should I make that so return adds a newline and say Shift + Return sends the command?
15:00 pmichaud web shell demonstration url plz?
15:00 moritz_ ash_: return should send by default
15:00 ash_ http://greaterthaninfinity.com/shell/ its not actually evaluating anything yet
15:01 moritz_ ash_: Mathematica evaluates when you press Shift + Return. It confuses the heck out of each newbie
15:01 ash_ ah, kk, i'll leave it the way it is then
15:01 jnthn It looks nice :-)
15:02 moritz_ it even autoextends the input box if you hit Shift + Enter
15:02 moritz_ ash_++
15:02 ash_ i still haven't done much for the tutorial part, the area under the textarea box will be where the tutorial comes up, I was planning on basing it off of the rakudo book
15:02 jaldhar joined #perl6
15:03 jnthn On firefox, the top of camelia is just off the page top, btw
15:03 ash_ yup
15:03 moritz_ ash_: well, the book isn't optimized for things to fit onto one line
15:03 moritz_ ash_: so you might need some adoptions
15:03 ash_ well, i don't have to use the books specific examples, i could simply them
15:03 moritz_ right
15:08 * ash_ wonders if i can capture tabs in all browsers...
15:12 moritz_ rakudo: class A { method b { } }; say A.new.cando(b)».name
15:12 p6eval rakudo 142433: OUTPUT«Could not find sub &b␤  in main program body at line 11:/tmp/0TqiMuzvdF␤»
15:12 moritz_ rakudo: class A { method b { } }; say A.new.cando('b')».name
15:12 p6eval rakudo 142433: OUTPUT«Method 'cando' not found for invocant of class 'A'␤  in main program body at line 11:/tmp/7EqrerSqU7␤»
15:13 moritz_ rakudo: class A { method b { } }; say A.new.can('b')».name
15:13 p6eval rakudo 142433: OUTPUT«Method 'flat' not found for invocant of class 'P6Invocation'␤  in main program body at line 11:/tmp/SckOH78TVr␤»
15:13 moritz_ rakudo: class A { method b { } }; say A.new.can('b').name
15:13 p6eval rakudo 142433: OUTPUT«Method 'name' not found for invocant of class 'P6Invocation'␤  in main program body at line 11:/tmp/Ohxzwo41qe␤»
15:13 moritz_ rakudo: class A { method b { } }; say A.new.can('b').WHAT
15:13 p6eval rakudo 142433: OUTPUT«Method 'WHAT' not found for invocant of class 'P6Invocation'␤  in main program body at line 11:/tmp/5HLwOFFfBW␤»
15:13 moritz_ rakudo: class A { method b { } }; say A.new.can('b') ~~ Routine
15:13 p6eval rakudo 142433: OUTPUT«0␤»
15:13 moritz_ that's pretty suspicious, isn't it?
15:14 ash_ i thought it was ^can
15:14 ash_ or does .can forward to .^can?
15:15 TimToady colomon: yes, the PDLish view that you can define an array as a slice into another array is a third view, but I wouldn't call it the "naive" view...
15:15 jnthn .can is a bit awkward
15:15 jnthn Because it's meant to also be an iterator over the possibilities
15:16 jnthn It probably forwards to .^can
15:16 jnthn Or probably should anyway
15:16 pmichaud .can should probably return a List, then.
15:16 jnthn pmichaud: Yeah, but the tests seem to also call for it to be directly callable too
15:16 pmichaud jnthn: oh, ouch.
15:16 jnthn pmichaud: Yeah, quite
15:16 jnthn pmichaud: I'm wondering if we want a spec tweak there.
15:17 pmichaud so, whatever .can returns should be subclassed from List, then :)
15:17 pmichaud (and be invokable :-)
15:17 jnthn Yeah
15:17 jnthn Should be workable.
15:17 pmichaud oh, it doesn't have to subclass from List
15:17 pmichaud it just needs to be Iterable.
15:17 jnthn ah, yes
15:17 pmichaud (and have a .iterator)
15:17 jnthn I didn't get to putting it back in mater yet
15:17 jnthn *master
15:18 jnthn Mostly because I wanted to see how lists would pan out. :-)
15:18 pmichaud I think they're pretty well panned out.  :-)
15:18 jnthn Aye
15:18 jnthn Now I just need to stop traveling all over Europe. ;-)
15:18 pmichaud once I get "mostly eager" in place I'll be prepared to say "okay, this is likely the right configuration"
15:18 jnthn \o/
15:19 pmichaud After seeing so many people do    my @a = 1..*;   I woke up this morning thinking I had better go ahead and get that implemented.
15:19 jnthn Just a little too late for my talk ;-)
15:19 pmichaud My timing seems to be very off that way.
15:19 jnthn 'tis fine, I had too much other cool stuff to show for the time I had anyway. :-)
15:20 pmichaud that was the experience in my talk as well.  :-)
15:20 jnthn Was a little overtime.
15:20 pmichaud I was a little overtime, -and- I didn't get to cover about 50% of what I had available.
15:20 pmichaud (but I designed the talk knowing that I had far more than I could cover, so there were several natural "stop points" built in :-)
15:20 jnthn Yeah, I had more that I cculd have done.
15:21 jnthn urgh, I just worked out why using |$c in a method signature runs into issues.
15:21 jnthn (Related to the *%_ that gets added
15:21 jnthn )
15:22 PZt joined #perl6
15:22 moritz_ |$c and *%_ don't like each other?
15:22 jnthn |$c says "is there anything that follows me? if so, there are more args"
15:23 jnthn since
15:23 jnthn :(|$c1, $a, |$c2, $b) # should work
15:23 jnthn You get snapshots of what is bound so far.
15:24 jnthn But when it's
15:24 jnthn :(|$c, *%_)
15:24 jnthn Then it says "ah, there's more paramters, continue binding as usual"
15:24 jnthn *parameters
15:24 moritz_ so *%_ tries to bind a positional argument?
15:25 jnthn Yeah, and thus the exploshun. :-)
15:25 * jnthn ponders the best fix
15:25 moritz_ so no automatically added *%_ for signatures that end with a |-param?
15:25 jnthn It becomes
15:25 jnthn :(self, |$c, *%_)
15:26 moritz_ rakudo: sub f(|$c) { }; say &f.signature.perl
15:26 p6eval rakudo 142433: OUTPUT«:(Any $c)␤»
15:26 jnthn ...
15:27 * moritz_ submits rakudobug
15:27 jnthn .signature.perl appears not to know about |
15:27 moritz_ right
15:27 moritz_ so TODObug
15:27 jnthn aye
15:27 jnthn LHF :-)
15:27 synth joined #perl6
15:28 moritz_ sorry for the distruction
15:28 moritz_ erm
15:28 moritz_ distraction :-)
15:28 jnthn ;-)
15:28 jnthn It's good to track it.
15:28 mmcleric jnthn: hi
15:28 jnthn Anyway, am pondering if we just say "don't whine about arity after |$c".
15:28 jnthn mmcleric: oh hai
15:29 mmcleric i think i'm on right track today, but i've got more stupid questions
15:29 jnthn :-)
15:29 mmcleric error:imcc:syntax error, unexpected COMMA (',')
15:29 mmcleric now do i track errors like this one?
15:30 mmcleric i it may be related to the fact that my PAST::Op don't have pos and source, and this is second question - why is that?
15:30 mmcleric because it looks like most other nodes have pos and source automatically
15:31 moritz_ you need :node($/) to set pos and source
15:31 moritz_ but a missing :node doesn't usually cause an IMCC syntax error
15:31 mmcleric thanks
15:31 jnthn No, quite
15:31 jnthn --target=pir
15:31 jnthn Use that
15:31 mmcleric o!
15:31 jnthn It'll show you the generated PIR
15:32 jnthn Which may give more clues
15:33 mmcleric ok, lots of code in unknown language :)
15:33 mmcleric imcc says it's line 97, should it be the same line in pir code?
15:34 moritz_ it should, but IMCC line numbers are somtimes off
15:34 ash_ moritz_: do you know a good list of pseudo keywords i can use to highlight in the shell? right now i use: ['class', 'my', 'our', 'has', 'sub', 'method', 'submethod', 'module', 'role', 'package', 'token', 'grammar', 'augment', 'use']
15:34 pmichaud 'is' ?
15:34 pmichaud 'does' ?
15:35 moritz_ ash_: you can look into the perl6.vim hilightiing file
15:35 moritz_ http://github.com/petdance/vim-perl/blob/master/syntax/perl6.vim
15:35 ash_ ah, good point, i'll check there, thanks pmichaud++
15:35 ash_ moritz_++
15:36 ash_ lol, i don't even do if, or else yet i forgot about those some how
15:36 * moritz_ wrote some very neat code with given/when today
15:39 [particle] Missing test file: t/spec/S03-operators/series-simple.t
15:39 [particle] noticed in make spectest
15:40 moritz_ [particle]: git pull
15:43 tedv joined #perl6
15:43 [particle] i thought of that afterwards... thanks!
15:43 [particle] pmichaud: rblackwe is looking for you
15:43 [particle] about ppw in october
15:46 synth_ joined #perl6
15:46 mmcleric error [...] in file 'EVAL_1' line 25877908
15:47 mmcleric that's strange.. .am i doing something horribly wrong? or could it be imcc bug?
15:47 jnthn mmcleric: Unlikely
15:47 mmcleric line numbers are completely random... sigh
15:47 [particle] 25M lines, nice
15:47 jnthn oh
15:47 jnthn wtf
15:47 jnthn I missed the number
15:48 jnthn Yes, IMCC's line numbers are a tad less accurate than Rakudo's :-)
15:48 mmcleric ok, i have an idea... can i hack generated pir file and rerun it again?
15:48 jnthn mmcleric: The error you got generally means you have some weird PAST though
15:49 jnthn and it generates wrong PIR from it
15:49 jnthn Can you nopaste the PIR?
15:49 mmcleric maybe, but all my pir::say prints are working, and PAST tree looks good too
15:49 jnthn Oh :S
15:49 pmichaud series-nonumeric.t seems to be caught in an infinite loop on my box now :-(
15:49 moritz_ pmichaud: did you svn up the spectests?
15:50 pmichaud I did "make spectest", yes.
15:50 moritz_ I fudged it today
15:50 pmichaud oh, it's locked.
15:50 pmichaud just a sec
15:50 pmichaud yes, that was it.
15:50 pmichaud thank you.
15:51 moritz_ np
15:51 * moritz_ got basic dispatch in CGI::Application working
15:51 mmcleric jnthn: http://gist.github.com/454146
15:52 ash_ moritz_: for perl6? sweet!
15:52 moritz_ ash_: aye
15:52 jnthn $P69 = "&infix:<+>"(, , $P51, $P68)
15:52 jnthn That's the line that's wrong
15:53 ash_ i added tabs to the shell, and updated the highlighting, going for a walk with the dogs then i might work on some of the other features of, like the tutorial
15:53 ash_ (tabs as in \t not as in window tabs)
15:53 moritz_ ash_++
15:54 mmcleric jnthn: oh, thanks
15:54 mmcleric i see it in past now too, empty Stmts nodes
15:54 jnthn mmcleric: That'd do it.
15:58 moritz_ the simplest extension possible atm is probably to get chained methods on Whatever working
15:58 moritz_ *.lc.ucfirst
15:58 moritz_ or is that handled in the dispatcher at run time?
15:59 pmichaud it's syntactic
15:59 moritz_ rakudo: my $x = *; say $x.uc
15:59 p6eval rakudo 142433: OUTPUT«!whatever_dispatch_helper␤»
15:59 pmichaud I mean as far as the spec goes, it's syntactic.
15:59 pmichaud I don't know what rakudo does atm.
15:59 moritz_ yes, I know that :-)
15:59 * pmichaud puts his head back into his compiling windows :)
16:00 jnthn It doesn't at the moment :-)
16:00 jnthn but what mmcleric++ is working on should probably also fix it
16:01 mmcleric ./perl6 -e 'say ((* + 5) + (* + 6)).(2,3)'
16:01 mmcleric 16
16:01 mmcleric yay, it's working :)
16:01 jnthn \o/
16:02 mmcleric now i'll just have to figure out how to get all other cases to work without too much copypasting
16:02 mmcleric (now it's only WC <op> WC)
16:03 mmcleric jnthn: btw, how do i get last element of array in NQP?
16:03 mmcleric or number of elements
16:04 moritz_ +@a
16:05 moritz_ nqp: my @a; @a[0] := 1; @a[1] := 2; say(+@a)
16:05 p6eval nqp: OUTPUT«2␤»
16:05 moritz_ nqp: my @a := [1, 2, 8]; say(+@a)
16:05 p6eval nqp: OUTPUT«3␤»
16:05 mmcleric er... by "array" i meant node, sorry :)
16:06 mmcleric also, where can i get my own nqp binary to try it for myself?
16:07 Chillance joined #perl6
16:08 moritz_ mmcleric: ./parrot_install/bin/parrot-nqp
16:08 whiteknight joined #perl6
16:08 mmcleric thanks
16:08 moritz_ nqp: my $x = PAST::Stmts.new(1, 2, 3); say(+$x)
16:08 p6eval nqp: OUTPUT«Assignment ("=") not supported in NQP, use ":=" instead at line 1, near " PAST::Stm"␤current instr.: 'parrot;HLL;Grammar;panic' pc 552 (src/cheats/hll-grammar.pir:205)␤»
16:09 moritz_ nqp: my $x := PAST::Stmts.new(1, 2, 3); say(+$x)
16:09 p6eval nqp: OUTPUT«get_number() not implemented in class 'Capture'␤current instr.: '_block11' pc 37 (EVAL_1:1494965501)␤»
16:09 moritz_ nqp: my $x := PAST::Stmts.new(1, 2, 3); say($x.elems)
16:09 p6eval nqp: OUTPUT«Method 'elems' not found for invocant of class 'PAST;Stmts'␤current instr.: '_block11' pc 52 (EVAL_1:1376632416)␤»
16:09 moritz_ nqp: my $x := PAST::Stmts.new(1, 2, 3); say(?$x)
16:09 p6eval nqp: OUTPUT«1␤»
16:09 moritz_ nqp: my $x := PAST::Stmts.new(); say(?$x)
16:09 p6eval nqp: OUTPUT«1␤»
16:11 pmichaud $x.list.elems
16:11 pmichaud nqp: my $x := PAST::Stmts.new(1,2,3);  say ($x.list.elems);
16:11 p6eval nqp: OUTPUT«Confused at line 1, near "say ($x.li"␤current instr.: 'parrot;HLL;Grammar;panic' pc 552 (src/cheats/hll-grammar.pir:205)␤»
16:11 pmichaud nqp: my $x := PAST::Stmts.new(1,2,3);  say($x.list.elems);
16:11 p6eval nqp: OUTPUT«Method 'elems' not found for invocant of class 'ResizablePMCArray'␤current instr.: '_block11' pc 61 (EVAL_1:17)␤»
16:11 moritz_ +$x.list
16:11 pmichaud nqp: my $x := PAST::Stmts.new(1,2,3);  say(+$x.list);
16:11 p6eval nqp: OUTPUT«3␤»
16:11 pmichaud right.
16:12 justatheory joined #perl6
16:12 mmcleric great :) thanks
16:12 TimToady re running a little over on your talk: TheDamian++ talked all day about Perl 6 and still ran over.  :)
16:13 * moritz_ sings "we shall overrun, we shall overrun, some daaaaaaay"
16:13 jnthn > class A { method foo(|$c) { say $c.perl } }; A.foo(1)
16:13 jnthn \(1)
16:13 jnthn \o/
16:13 moritz_ jnthn: does that automagically fix 'handles' for methods with arguments?
16:14 jnthn should
16:14 jnthn since it was the underlying bug
16:16 * TimToady sings "Mañana, mañana, I love you, mañana!  You're always a day away!"
16:16 dalek rakudo: 77a3501 | pmichaud++ | src/ (5 files):
16:16 dalek rakudo: Allow infinity laziness in arrays, array assignment.
16:16 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/77a3501998ae3aa0a3c73434a4aa0bed9d98bf07
16:16 dalek rakudo: b5bd660 | pmichaud++ | src/ (2 files):
16:16 dalek rakudo: Merge branch 'master' of github.com:rakudo/rakudo
16:16 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/b5bd6606f0cd53aff088d9081a1acace99a2c74a
16:17 pmichaud "When it's siesta time.... in Akron O-HI-O...."  </tom_lehrer>
16:18 moritz_ TimToady: what do you think about :foo"string here" colonpair syntax?
16:18 moritz_ I often miss it, and sometimes abuse :foo<string here> stringification to DTRT with spaces
16:18 moritz_ which is... an abuse, really
16:18 pmichaud I suggest   :foo("string here")   :-P
16:19 moritz_ I know that exists
16:19 pmichaud the challenging part would be handling    :foo'string here'
16:19 moritz_ why?
16:19 TimToady is :foo("string here") that bad?
16:19 pmichaud because   foo'string  is a valid identifier.
16:19 moritz_ oh, right
16:19 pmichaud I agree with TimToady++
16:19 pmichaud visually  I find that  :foo"string here"  doesn't look right to me
16:20 moritz_ TimToady: it's not that bad really, but I dislike (...) where the parens could be avoided somehow
16:20 moritz_ anyway, if the majority disagrees, I'll rest my case
16:20 jnthn moritz_: all tests pass in handles.t
16:20 pmichaud jnthn: \o/
16:20 TimToady rakudo: say :foo<string\ here>.perl
16:20 moritz_ jnthn: did you unfudge some?
16:20 p6eval rakudo 142433: OUTPUT«"foo" => ("string\\", "here")␤»
16:21 TimToady alpha: say :foo<string\ here>.perl
16:21 p6eval alpha 30e0ed: OUTPUT«"foo" => ["string\\", "here"]␤»
16:21 moritz_ rakudo: say :foo<<string\ here>>.perl
16:21 p6eval rakudo 142433: OUTPUT«"foo" => ("string\\", "here")␤»
16:21 moritz_ alpha: say :foo<<string\ here>>.perl
16:21 p6eval alpha 30e0ed: OUTPUT«"foo" => "string here"␤»
16:21 moritz_ rakudobug!
16:21 jnthn moritz_: I just ran the .t
16:21 jnthn ;-)
16:21 TimToady one outa four ain't bad...
16:21 moritz_ jnthn: \o/
16:21 jnthn moritz_: will unfudge and spectest
16:21 jnthn Just in case
16:22 moritz_ rakudo: say «a\ b».perl
16:23 p6eval rakudo 142433: OUTPUT«("a", "b")␤»
16:23 mberends joined #perl6
16:23 TimToady that's kinda wrong any way you look at it
16:23 moritz_ right
16:23 moritz_ attached to the same ticket
16:24 TimToady but I think <> should respect \
16:24 TimToady rakudo: say <foo\>\>\>bar>
16:24 p6eval rakudo 142433: OUTPUT«foo>>>bar␤»
16:24 moritz_ .oO( this is what it must feel like to be masak :-) )
16:24 TimToady works there
16:25 TimToady space is arguably either way
16:25 patspam joined #perl6
16:25 TimToady but I'd argue that it's more like a metachar than like a '\ '
16:25 TimToady rakudo: say '\ '
16:25 p6eval rakudo 142433: OUTPUT«\ ␤»
16:26 TimToady that's correct, but I think <foo\ bar> should probably not split on that space
16:26 TimToady since the clear intent is to de-meta it
16:26 moritz_ I kinda thought that < were more like ' + split
16:26 moritz_ and << where more like " + split
16:26 moritz_ s/h//
16:27 pmichaud << is quite complex.
16:27 moritz_ pmichaud: I know, I know
16:27 TimToady well, << is not really like " complete either
16:27 TimToady since it allows internal shell quoting
16:27 moritz_ but I'm not strongly attached to that notion
16:27 pmichaud TimToady: so, inside of single-angles the \  would escape any sort of delimiter?
16:27 TimToady I think "clear intent" trumps "A is just a B" here
16:28 pmichaud where whitespace is a delimiter in the single-angle case?
16:28 pmichaud (normally \ only escapes the closing bracket)
16:28 TimToady I'll bet it also escapes \  :)
16:28 TimToady rakudo: say <\\>
16:28 pmichaud I'll take that bet.  Oh wait, I lose.
16:28 p6eval rakudo 142433: OUTPUT«\␤»
16:28 pmichaud yes, it also escapes \ .
16:29 TimToady I think just add whitespace to that
16:30 jnthn .u U+1F489
16:30 phenny jnthn: Sorry, no results
16:40 synth joined #perl6
16:54 colomon loliblogged: http://justrakudoit.wordpress.com/2010/06/26/99/
16:55 * TimToady wonders if { ... } ==> @result implies an "async" on the {}
16:55 colomon ciphertext: ping-pong?
16:56 TimToady so that just putting {} around the source of a feed would naturally be a (non-)sharing boundary
16:58 TimToady that is, my @result <<== { stuff() } turns into (my @result).feed: gather async { take {...}() } or some such
16:58 pmichaud jnthn: ping
16:58 TimToady s/\.\.\./stuff()/
16:59 jnthn pmichaud: pong :-)
16:59 pmichaud jnthn: I'm working on this one....
16:59 pmichaud rakudo:  say ({ a => 42 }).isa(Hash);
16:59 p6eval rakudo b5bd66: OUTPUT«0␤»
16:59 pmichaud the problem seems to be that Hash is a Perl6Role
16:59 jnthn rakudo: say ({ a => 42 }).does(Hash)
16:59 p6eval rakudo b5bd66: OUTPUT«1␤»
16:59 jnthn pmichaud: Yeah, long story ;-)
17:00 alester joined #perl6
17:00 jnthn pmichaud: We had quite a few things as roles at one time.
17:00 pmichaud so, what's the answer/punch-line ?
17:00 jnthn pmichaud: Then switched them to classes.
17:00 pmichaud should I switch Hash to be a class?
17:00 jnthn Apart from we got collisions with Parrot Hash when switching it to a class.
17:00 jnthn I cleared up some of them
17:00 jnthn But then it was still broken. :-/
17:00 pmichaud it might not be so broken after my refactors
17:00 jnthn Anyway, yes, feel free to change and triage.
17:00 pmichaud okay, I'll try it and see what happens. tnx
17:01 masonkramer are there any syntax highlighting editors available for p6?
17:01 ash_ phenny tell cygx I have a sample of the frontend up at http://greaterthaninfinity.com/shell/ if you want to take a look and give me any comments, suggestions, feedback
17:01 jnthn cd t\spec
17:01 jnthn oops
17:01 ash_ masonkramer: vim, http://github.com/petdance/vim-perl
17:02 pmichaud masonkramer: http://perl6.org/whatever/
17:02 alester Some day I'll have a proper installer for it, masonkramer
17:02 alester for now, just do a "make install"
17:02 pugssvn r31452 | jnthn++ | [t/spec] Corret one test and fully unfudge delegation.t.
17:02 ash_ ah, even better, i'll have to remember that link
17:02 masonkramer excellent, I use vim anyway
17:03 jnthn http://rt.perl.org/rt3/Ticket/Display.html?id=75966 is done but I gotta go afk right now
17:05 dalek rakudo: cbf03ac | jonathan++ | src/binder/bind.c:
17:05 dalek rakudo: Fix |$c in method signatures and various other cases; it wasn't quite slurpy
17:05 dalek rakudo: enough. In turn fixes delegation bits, which are implemented in terms of it.
17:05 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/cbf03ac823f1439c7dfaa98be5700ccbf108c0b0
17:05 ash_ there is an old emacs one too i found once, in pugscode somewhere... i think its out of date, but some people do use emacs
17:06 cognominal is there an predefined operator to see if arrays are equal? == apparently compares their length
17:07 pmichaud cognominal: eqv, I think.
17:07 TimToady eqv should work, as should ~~
17:07 pmichaud cognominal: I don't know if that's implemented in Rakudo yet (for arrays)
17:07 cognominal S02 indeed says == is for Nums
17:08 moritz_ ~~ DWIMs wrt *
17:08 moritz_ rakudo: say [1, 2, 3, 4, 5] ~~ [1, *, 5]
17:08 p6eval rakudo b5bd66: OUTPUT«1␤»
17:08 pmichaud rakudo:  my @a = <a b c>;  my @b = <a b c>;  say @a eqv @b;
17:08 p6eval rakudo b5bd66: OUTPUT«1␤»
17:08 pmichaud rakudo:  my @a = <a b c>;  my @b = <a b d>;  say @a eqv @b;
17:08 p6eval rakudo b5bd66: OUTPUT«0␤»
17:08 pmichaud looks like rakudo might have it already.
17:09 cognominal rakudo++
17:09 cognominal perl6++
17:09 ash_ rakudo: my @a = 1, 2; my @b = 1, 2; my @c = 2, 1; my @d = 1, 3; say @a ~~ @b, @a ~~ @c, @a ~~ @d;
17:09 p6eval rakudo b5bd66: OUTPUT«100␤»
17:09 moritz_ is_deeply is implemented in terms of eqv
17:09 TimToady don't try to backport the ~~ solution to P5 though, since it will auto-any the array, methinks
17:09 pmichaud +1 to that
17:09 pmichaud (is_deeply)
17:10 ash_ so apparently ~~ on 2 array's order matters, interesting, but it does seem right
17:10 ash_ is there a comparison that doesn't care about order? i suppose you could sort...
17:10 sorear good morning #perl6
17:10 moritz_ all(@a) eqv any(@b) shouldn't care about order
17:11 moritz_ but it's not quite the same
17:11 TimToady you might have to test it both ways
17:11 moritz_ mornin' sorear
17:11 TimToady eventually Set(@a) eqv Set(@b)
17:11 ash_ rakduo: my @a = 1, 2; my @b= 2, 1; say @a.sort ~~ @b.sort; # seems the simplest, or what TimToady wrote
17:12 TimToady I don't think rakudo has sets though
17:12 ash_ well, when its implemented
17:12 moritz_ it kinda has them, but... weirdly
17:12 jnthn rakudo: say Set;
17:12 ash_ helps if i spell rakudo right too
17:12 cognominal rakudo:  1 neqv 1
17:12 p6eval rakudo b5bd66: OUTPUT«Set()␤»
17:12 p6eval rakudo b5bd66: OUTPUT«===SORRY!===␤Confused at line 11, near "1 neqv 1"␤»
17:12 moritz_ rakudo: say Set.new(1, 2, 3)
17:12 p6eval rakudo b5bd66: OUTPUT«Set()<0x4a0cb40>␤»
17:12 moritz_ cognominal: !eqv
17:12 ash_ rakudo: my @a = 1, 2; my @b= 2, 1; say @a.sort ~~ @b.sort;
17:12 p6eval rakudo b5bd66: OUTPUT«1␤»
17:13 cognominal there is a !eq as well?
17:13 moritz_ yes
17:13 TimToady there's a !op for any boolean op
17:13 cognominal makes sense
17:13 cognominal I should read S03 thouroughly
17:14 ash_ rakudo: say 1 !+ 2; # just curious....
17:14 p6eval rakudo b5bd66: OUTPUT«0␤»
17:14 pmichaud s/boolean/binary?
17:14 TimToady no
17:14 colomon !+ shouldn't work
17:14 pmichaud okay, good.
17:14 TimToady std: 1 !+ 2
17:14 p6eval std 31452: OUTPUT«[31m===[0mSORRY![31m===[0m␤Can't negate + because additive operators are not iffy enough at /tmp/rwD0bAUQxQ line 1:␤------> [32m1 !+[33m⏏[31m 2[0m␤Confused at /tmp/rwD0bAUQxQ line 1:␤------> [32m1 ![33m⏏[31m+ 2[0m␤    expecting infix or meta-infix␤Parse failed␤FAILED
17:14 p6eval ..00…
17:14 colomon it's just extra logic to stop it from working, which we haven't implemented yet.
17:14 cognominal rakudo sometimes DWHM
17:15 ash_ std: 1 !% 2 # neat
17:15 p6eval std 31452: OUTPUT«ok 00:01 109m␤»
17:15 TimToady I think I'm going to make !% a specific operator rather than a meta %
17:15 TimToady so that it doesn't do NOT-raising
17:15 TimToady but if I do that, maybe it should really be ?%
17:15 synth__ joined #perl6
17:16 pmichaud maybe it really should be ?div  :-P
17:17 TimToady thought about that
17:17 TimToady confusion with existing div though...
17:17 pmichaud agreed.
17:17 ash_ $x !?% 3 # for all the times $x isn't divisible by 3
17:17 pmichaud but even ?% and !% have the potential to be confusing
17:18 moritz_ wouldn't that be !?% then :-)
17:19 TimToady std: say 1 !?& 2
17:19 p6eval std 31452: OUTPUT«ok 00:01 109m␤»
17:19 ash_ ?% = boolean, + a ! for not-ing the boolean?
17:19 TimToady heh
17:19 TimToady ?& is iffy enough, so maybe ?% can be too
17:20 ash_ http://svn.pugscode.org/pugs/util/cperl-mode.el has the emacs perl6 cperl mode, but its a bit dated and doesn't have all the stuff the modern cperl module has, as a warning, but it could be linked on the page of text editor support since its kinda right
17:20 TimToady I think I could get to like ?%
17:20 colomon I think I'd vote for !%
17:21 TimToady but it's confusing if you expect/don't expect NOT-raising
17:21 TimToady and I can see people expecting both sides of that
17:21 jferrero joined #perl6
17:22 ash_ rakudo: say 1 !?+ 2
17:22 p6eval rakudo b5bd66: OUTPUT«===SORRY!===␤Confused at line 11, near "say 1 !?+ "␤»
17:22 TimToady std: say 1 ?+ 2
17:22 ash_ std: 1 !?+ 2
17:23 p6eval std 31452: OUTPUT«[31m===[0mSORRY![31m===[0m␤Confused at /tmp/w11VCCceKy line 1:␤------> [32msay 1 [33m⏏[31m?+ 2[0m␤    expecting any of:␤       bracketed infix␤  infix␤  infix or meta-infix␤        statement modifier loop␤Parse failed␤FAILED 00:02 109m␤»
17:23 p6eval std 31452: OUTPUT«[31m===[0mSORRY![31m===[0m␤Negation metaoperator not followed by valid infix at /tmp/tNGNolvzBI line 1:␤------> [32m1 ![33m⏏[31m?+ 2[0m␤    expecting any of:␤ bracketed infix␤  infix␤  infix or meta-infix␤Parse failed␤FAILED 00:01 108m␤»
17:23 ash_ just curious
17:23 TimToady ? does not generalize like !
17:23 colomon but the usual way operators are constructed with a ? prefix implies it's the normal sense of the operator, only boolean-y, which seems to imply to me that logically ?% should be the not-divisible-by operator.
17:24 ash_ % is only special because people use it to check things like "are we on the 3rd row?" which is a boolean assumption, correct?
17:24 TimToady how 'bout %%
17:24 ciphertext colomon: pong
17:24 colomon TimToady: I could live with %%
17:25 colomon it doesn't mean anything obvious to me, so it can be whatever we want!  ;)
17:25 pmichaud %% doesn't scream "boolean" to me, though.
17:25 TimToady it really needs to use % in it somehow, since people are used to seeing $a % 4 == 0
17:25 pmichaud %=%  or =%=  or %==
17:26 pmichaud (just throwing out ideas)
17:26 colomon ciphertext: I should be able to look at series stuff all afternoon.  Do need to get some $work done (starting a big test run soon is most important) and probably take a nap.
17:26 TimToady there's \% too
17:26 pmichaud \ reminds me too much of unspace
17:27 ash_ $a ?% 4;   vs $a % 4 == 0; vs $a ?% 4;   vs $a %% 4;  vs $a =%= 4;
17:27 ash_ oops ?% is in there twice
17:27 TimToady %% probably looks the least cluttered
17:28 TimToady and the = ones look like assignment
17:28 ash_ ?% is still kinda nice since it implies boolean-ness like it does in other places
17:28 TimToady yah
17:28 ash_ (in regards to ?)
17:28 pmichaud yes, but unfortunately  $a ?% $b   wouldn't be the same as  ?($a % b)
17:28 pmichaud *$b
17:29 ash_ good point
17:29 pmichaud that's where I think people might get confused.
17:29 TimToady well, it's not like == has a ? on the front of it either
17:29 TimToady so I'm leaning toward %%
17:30 pmichaud how about   o//o    :-P
17:30 pmichaud it's a percentage sign with a double-slash :-P
17:30 TimToady
17:30 pmichaud or even   °//o
17:30 TimToady ٪
17:31 sorear TimToady: What about methods?  $object.foo(1, a => 2, 3) isn't lexically bound to a single proto either
17:31 TimToady ÷
17:31 ash_ $a modulo 4
17:31 pmichaud anyway, %% isn't too bad, so I could live with that.
17:31 colomon could be implemented in a couple of minutes.... ;)
17:32 pmichaud "gozinta"
17:32 TimToady sorear: it might be sufficient to be able to reconstruct the original parcel from the capture if needed
17:32 colomon gozinta!
17:32 TimToady gozinta is backwards
17:32 colomon atnizog!
17:32 TimToady bless you
17:35 pmichaud hmmmm, getting \ to work in <...> is a bit nasty.  Can no longer just do 'split' on the result.
17:35 pmichaud I'll wait on that one for when we redo «...»  again.
17:35 ash_ phenny: tell cygx I have a sample of the frontend up at http://greaterthaninfinity.com/shell/ if you want to take a look and give me any comments, suggestions, feedback
17:35 phenny ash_: I'll pass that on when cygx is around.
17:35 ash_ yay it worked this time
17:37 TimToady
17:37 TimToady
17:38 ciphertext colomon: i made a sort of checklist for series last night: http://nopaste.snit.ch/21593
17:40 moritz_ jnthn: btw you also seem to have fixed RT #74336 along the way :-)
17:41 moritz_ rakudo: my @a = 1,2,3; my (@c) = @a; say @c.perl
17:41 p6eval rakudo b5bd66: OUTPUT«[[1, 2, 3]]␤»
17:42 moritz_ gives just [1, 2, 3] locally
17:43 pugssvn r31453 | moritz++ | rakudo unfudges and refudges
17:43 colomon ciphertext: great list
17:44 ciphertext thanks
17:45 colomon okay, I see to have started my $work test successfully.
17:46 pugssvn r31454 | lwall++ | [S03] change !% to %% to avoid metaconfusion
17:46 colomon ciphertext: gimme a minute to fix that last change...
17:47 * sorear finish backlog
17:47 Ross joined #perl6
17:47 colomon TimToady: I don't think we ever actually implemented !%
17:48 moritz_ huh
17:48 colomon just picked it up from !op and %
17:48 moritz_ ok 13 - gather with nested while # TODO broken gather/take with while (RT #62178)
17:48 moritz_ ok 14 - gather with nested loop # TODO broken gather/take with loop (RT #62178)
17:48 moritz_ huh? jnthn++ accidentally the bug?
17:49 moritz_ or pmichaud++?
17:49 colomon :\
17:49 sorear autounfudge!
17:49 moritz_ rakudo: my @a = gather loop (my $i = 1; $i < 10; $i++) { take $i }; @a.perl.say;
17:49 p6eval rakudo b5bd66: OUTPUT«[10, 10, 10, 10, 10, 10, 10, 10, 10]␤»
17:50 TimToady autounfudge needs a "don't unfudge
17:50 moritz_ it has
17:50 moritz_ it recognizes 'noauto'
17:51 TimToady good
17:51 moritz_ and also 'unspecced'
17:51 colomon rakudo: say ('A' ... *).munch(100)
17:51 TimToady bad  :)
17:51 p6eval rakudo b5bd66: OUTPUT«ABCDEFGHIJKLMNOPQRSTUVWXYZAAABACADAEAFAGAHAIAJAKALAMANAOAPAQARASATAUAVAWAXAYAZBABBBCBDBEBFBGBHBIBJBKBLBMBNBOBPBQBRBSBTBUBVBWBXBYBZCACBCCCDCECFCGCHCICJCKCLCMCNCOCPCQCRCSCTCUCV␤»
17:53 colomon > say (1 ... 20) >>%%>> 4
17:53 colomon 00010001000100010001
17:53 moritz_ evil.
17:53 pugssvn r31455 | moritz++ | [t/spec] more rakudo unfudges
17:54 ash_ nice
17:54 ash_ colomon: that was fast
17:54 colomon ash_: now it will take 20 minutes to spectest.  :)
17:54 ash_ moritz_: was that right? the above gather/take ?
17:54 moritz_ ash_: nope
17:54 ash_ okay, just curious
17:54 moritz_ but here with latest rakudo it just works[tm]
17:55 pugssvn r31456 | moritz++ | [t/spec] more rakudo unfudges
17:56 Transformer joined #perl6
17:58 colomon ciphertext: the closure on the RHS caveat is because the original series operator spec had the generating closure on the RHS instead of the LHS.
17:58 colomon But that's the main reason I haven't gotten around to implementing that.
17:58 colomon probably no real reason not to at this point.
17:58 ciphertext i've got rhs closures on my local version
17:59 TimToady colomon: are you changing the !% spectests to %%?
17:59 colomon TimToady: I haven't done so, no.
17:59 ciphertext right now, i'm merging with the current version (by hand)
17:59 TimToady I can change 'em, if you'll be checking in the %% fix soon
18:00 colomon ciphertext: this is maybe one area of the spec that still needs work, however.  one minute.
18:00 colomon TimToady: I'm going to check it is as soon as I spectest, so changes would be timely and appreciated.
18:04 pugssvn r31457 | lwall++ | [t/spec] change !% to %%
18:04 sorear TimToady: Is there a good way to use STD to parse a slightly extended Perl 6?  (Like some kind of Q:CIL block)
18:05 TimToady probably
18:05 colomon ciphertext: It looks to me like the section describing closures on the RHS thinks you call it on the current list, whereas the explicit examples for string functions seem to imply it is called on the current list plus the potential next value of the list.
18:05 colomon that is, I can see three ways of doing it:
18:06 colomon 1. Check closure, terminate if false, otherwise generate next value and "take" it.
18:06 lue ohai
18:07 colomon 2. Generate next value, check closure with list and next value, terminate if false, otherwise take new value.
18:07 sftp joined #perl6
18:07 TimToady ohio
18:07 lue OH :)
18:08 colomon 3. .... guess this is just a variant on #1, though it might make a difference at the beginning of the series?
18:08 colomon 3. generate next, take it, check closure with list so far, terminate if false.
18:08 colomon I suspect the clean way to implement this is that internally, we always have a closure.
18:08 TimToady sorear: you ought to be able to derive from Q and then locally use that for the %*LANG<Q> braid
18:09 moritz_ autounfudge finds several new items, Tene++, pmichaud++, colomon++, jnthn++
18:09 TimToady just be sure to temp %*LANG at the right spot
18:11 colomon ciphertext: "what exactly does a signature mis-match imply?"   Looks to me like the intent is that if you cannot call the generating function, then the series ends.  Don't know how to cleanly implement that, however.
18:11 TimToady sorear: where you aren't actually modifying the base Q language, other than to add a role that can be mixed in with :CIL
18:12 colomon rakudo: say (2, 3, 5 ... *).much(20).perl
18:12 p6eval rakudo b5bd66: OUTPUT«Method 'much' not found for invocant of class 'Failure'␤  in main program body at line 11:/tmp/0kHLSNjBQf␤»
18:12 colomon rakudo: say (2, 3, 5 ... *).munch(20).perl
18:12 p6eval rakudo b5bd66: OUTPUT«Method 'munch' not found for invocant of class 'Failure'␤  in main program body at line 11:/tmp/ke9le3hOtC␤»
18:13 M_o_C joined #perl6
18:13 colomon ciphertext: I guess the STD may not explicitly specify failure there, but I don't know what else we could sensibly do.
18:14 colomon except now that I think about it, what about the 2, 3, 5 ... 3 case?  That should work.  :(
18:15 colomon seems to imply correct behavior is to output the LHS case (with appropriate termination checks), and only then try to figure out the implied generating function (if needed).
18:15 ciphertext colomon: re. rhs closures, i like #2; i think it's the most consistent with my understanding of the spec
18:15 sorear TimToady: I see
18:16 TimToady you usually do :)
18:17 sorear I'd need to somehow hook in code after comp_unit for that, though
18:17 colomon ciphertext: "the spec says 'numeric'..." I suspect this is an oversight.  really, it seems like we need three categories:  Numeric (ie we can find arithmetic or geometric); Ordered (ie cmp is defined, like Strs); No-nothing (all we can do is call .succ)
18:17 sorear anyways this is for a bit in the future
18:17 TimToady sorear: that's just 'use STD; grammar MyQ is STD::Q { etc }'
18:17 colomon ciphertext: I like #2 as well, but I think it's the furtherest from what the spec says, even if it's what the spec means.  We should probably change the spec in this case.  :)
18:18 ciphertext colomon: re. (2,3,5...3): terminating early should be fairly simple: we already loop through the values on the lhs and 'take' them.  adding a 'return if...' to check for limit values.  then, it would never get to the code that looks for patterns.
18:18 colomon ciphertext: the mostly eager stuff is very much still in flux, I vote we don't worry about it yet.
18:19 TimToady the compiler can probably complain at compile time on the basis of the unrecognized sequence; it's only the RHS that is not known till run time
18:19 ciphertext not worrying yet sounds good :-)
18:19 colomon ciphertext: right, that's what I was trying to say back there.  :)
18:19 colomon (that's right as in never getting to the code that looks for patterns.)
18:21 colomon ciphertext: the other thing we should do is take that list of yours and try to make sure we have tests for all the cases.
18:22 ciphertext consider (2,3,5...$n)   i'm not sure this should even compile, regardless of the value of $n... it seems kind of dangerous
18:23 TimToady I just saidthat
18:23 ciphertext TimToady: i was just agreeing with you :-)
18:23 envi^home joined #perl6
18:23 pugssvn r31458 | moritz++ | [helpnow] another idea: Match.new
18:23 TimToady but were you doing it consciously? :)
18:24 pugssvn r31459 | lwall++ | [STD] change !% to %%
18:26 Mark____ joined #perl6
18:28 ciphertext hmmm... my $a = 2; my $b = 3; my $c = 5; my $n = 3;   say ($a,$b,$c...$n);   #  this can't really complain at compile time.
18:29 Mark____ joined #perl6
18:30 MarkSenn joined #perl6
18:30 TimToady no, but that doesn't prevent the compiler from checking when it does know what's there
18:31 TimToady which will be almost always
18:31 lue afk
18:33 dalek rakudo: a579f8e | pmichaud++ | build/PARROT_REVISION:
18:33 dalek rakudo: Bump PARROT_REVISION, fixes RT #71462.
18:33 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/a579f8ebbb3b75c2a02ce930fefbe4ac38804faf
18:44 pugssvn r31460 | pmichaud++ | [t/spec]:  Unfudge passing test for RT #71462.
18:47 Tene "By studying children who learned NSL at various stages of its development, Pyers has shown that the vocabulary they pick up affects the way they think. Specifically, those who learned NSL before it developed specific gestures for left and right perform more poorly on a spatial awareness test than children who grew up knowing how to sign those terms." -- ...
18:47 Tene ... http://blogs.discovermagazine.com/notrocketscience/2010/06/22/new-nicaraguan-sign-language-shows-how-language-affects-thought/
18:49 pugssvn r31461 | lwall++ | [STD] change 'not iffy enough' from .sorry to .panic
18:50 ash_ so, if i think i am going to start working on the tutorials for the try.rakudo.org shell, and the first example in the rakudo book is incredibly complicated if you don't know perl...
19:02 dalek rakudo: 7102d7c | (Solomon Foster)++ | src/ (2 files):
19:02 dalek rakudo: Implement infix:<%%> "is divisible by" operator.
19:02 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/7102d7c4a747603b3a1f6295ad8cac80c2062285
19:04 ash_ moritz_: hey, i have a question about try.rakudo.org (and perl6 documentation)
19:04 moritz_ ash_: sure
19:04 tylercurtis joined #perl6
19:05 cono joined #perl6
19:05 ash_ is there anywhere you can look up perl6 related terms? I wanted to have a: "help <term>" so you could get more information on a term that you might not know, like if we say "This operation is iffy" they could say help iffy and get a definition for how we use it in perl6
19:07 moritz_ ash_: 'grok' tried to implement such a function, I think
19:07 ash_ if there is one thats started, that would be cool, if not we can always start fresh
19:07 moritz_ http://github.com/hinrik/grok
19:09 hmmm joined #perl6
19:09 hmmm hello
19:10 hmmm does perl6 have filehandle arrays?  Seems perl5 does not for some very strange reason...
19:11 TimToady filehandles aren't special in Perl 6; they're just normal objects, so a normal array of filehandles will work
19:12 hmmm Sounds great, why do you think perl5 does not have for example FH[$i]?
19:14 ingy greetings
19:14 TimToady there are ways to get the same effect in Perl 5
19:14 pugssvn r31462 | pmichaud++ | [t/spec]:  Fix and unfudge test for RT #67218 in pair.t .
19:14 ingy seen patch
19:15 TimToady open(my $newhandle, "file"); $FH[$i] = $newhandle
19:15 patch ingy: hi
19:15 ingy patch!
19:16 ingy i was wondering if you would like to set aside a few hours to hack on testml tomorrow?
19:17 ingy as in pairing...
19:17 masak joined #perl6
19:17 masak oh hai, #perl6!
19:17 ingy greetings masak
19:17 patch sure.  in the afternoon or night.  anytime after lunch really.
19:17 TimToady ohio
19:17 hmmm That's elightening, did not know that'd  work (use strict/warnings), but that may get me where i want to go.  How does Perl6 plan to do the FH arrays?
19:18 TimToady hmmm: it doesn't need to do anything special
19:18 masak ingy: how's YAML-in-Perl-6 coming along?
19:18 sorear hmmm: FH in Perl 5 is quasi-deprecated; all the cool people store filehandles in scalar variables (new feature in 5.6)
19:18 ingy masak: patch and I are currently porting testml to p6
19:18 ingy masak: then we will port jsync
19:18 masak what's jsync?
19:18 ingy which is a poor man's yaml
19:19 masak aha.
19:19 ingy masak: http://www.jsync.org/spec/
19:19 * masak peruses
19:19 hmmm using 5.12, not looking back, guess i learned something old and got stuck...
19:19 ingy masak: http://search.cpan.org/dist/JSYNC/
19:20 masak doesn't look so poor-man's. looks quite powerful to me.
19:20 ingy masak: so we will definitely have jsync done for rakudo star
19:20 ingy masak: :)
19:20 sorear Think of JSYNC as "YAML, but without the 200 page specification"
19:21 masak right.
19:21 ingy masak: it doesn't afford the human niceness
19:21 sorear (seriously, how did they make yaml so complicated?)
19:21 ingy sorear: well the jsync spec simply points to the yaml spec for tags and stuff
19:21 ingy sorear: you mean me?
19:22 ingy :)
19:22 ingy I think it was the TimToady in us :)
19:23 * ingy <3 the YAML spec.
19:23 sorear it's been a while; I forgot who all was on the author list
19:23 ingy :)
19:24 * sorear wanders off to reread it
19:24 ingy masak: after that we can talk about binding libyaml into rakudo
19:24 tylercurtis rakudo: ([&&] 1, 3, 5, 0, 1).perl.say
19:24 p6eval rakudo a579f8: OUTPUT«===SORRY!===␤Could not find sub &infix:<&&>␤»
19:25 tylercurtis rakudo: ([||] 0, 0, 0, 1).perl.say
19:25 pmichaud what part of the spec describes the assignment of Nil to variables?
19:25 p6eval rakudo a579f8: OUTPUT«1␤»
19:25 tylercurtis Why is it that [||] works in Rakudo but && does not?
19:26 pmichaud I'm thinking that [||] must be specially defined as an operator, while [&&] is not.
19:26 TimToady S02:2162
19:26 pmichaud TimToady: thanks
19:26 masak ingy: I had faked YAML enough in proto to be able to use it for simple config-like files. really only one level hashes, very predictable. for pls I decided to use JSON::Tiny by moritz_++. it's not faked, but I think it imposes quite a speed hit.
19:27 ingy nod
19:27 ash_ moritz_: http://github.com/moritz/try.rakudo.org/blob/master/frontend/data/chapters/index.js does that outline look alright for chapter progression
19:28 ingy patch: our grammar didn't work for quoted strings...
19:28 ingy patch: I'll commit a failing test...
19:28 tylercurtis pmichaud: that looks to be the case.
19:28 patch ingy: when is good for you tomorrow?
19:29 quietfanatic joined #perl6
19:29 alester joined #perl6
19:31 ingy patch: when is after lunch?
19:34 masak ooh, a spec change.
19:34 masak I guess the clues for why are to be found in the backlog.
19:35 ingy patch: let's start at 1PM EST
19:37 pugssvn r31463 | pmichaud++ | [t/spec]:  Unfudge infinite range tests in range.t .
19:38 patch ingy: was just checking my lunch plans. let's push it to 2pm. ok?
19:38 patch ingy: well, EDT, not EST. 18:00 UTC, that is.
19:39 moritz_ ash_: outline looks great
19:39 cygx joined #perl6
19:39 hmmm Will Perl6 will support this syntax for example?   open($FHA[$i], "$filename[$i]",); { do some things; } close ($FHA[$i]);
19:39 moritz_ ash_: I would have put strings before lists, but it works either way
19:39 cygx hi
19:39 phenny cygx: 17:35Z <ash_> tell cygx I have a sample of the frontend up at http://greaterthaninfinity.com/shell/ if you want to take a look and give me any comments, suggestions, feedback
19:40 sorear hmmm: no
19:40 moritz_ hmmm: nearly; $FHA[$i] = open $filename[$i]; ...
19:40 sorear hmmm: filehandles in perl 6 aren't special. at all.
19:40 TimToady not syntactically special, anyway
19:40 tylercurtis pmichaud: I made a patch to add infix:&& and infix:and, I'll submit it once I make sure it doesn't somehow break anything(or, at least, nothing that is tested by "make test" or "make spectest").
19:41 sorear alternatively, my $FHA = $filename.map(&open)
19:41 ingy patch: sounds good
19:41 ash_ moritz_: i was thinking of starting with basic stuff, like math, and moving from there, and a list of numbers seemed pretty basic, (strings are lists of numbers in a lot of languages :P) but i could move them sooner
19:41 TimToady sorear: um, why the map for a single filename?
19:42 cygx what's the status of Sockets, DBI and non-blocking IO in Rakudo?
19:42 sorear TimToady: $filename is an array
19:42 TimToady then it should be named $filenames :P
19:42 sorear unless by $filename[$i] earlier he meant @filename[$i]
19:42 TimToady he probably did
19:43 ash_ moritz_: anyway, i'll work on that some more tonight, going to spend some time with my girlfreind &
19:43 TimToady hmmm: so more like: my @FHA = @filename.map(*.open)
19:43 moritz_ ash_: the main motivation is that if you introduce strings first, it's easier to explain that lists can hold any types
19:43 moritz_ ash_: have fun
19:45 sorear TimToady: Why does Str care enough about files to have an .open?
19:45 hmmm $filename[$i] is an indexed element of array @filename  and  $FHA[$i] is an indexed element of my filehandle array @FHA
19:46 TimToady hmmm: only in Perl 5
19:46 sorear hmmm: in Perl 6, an element of @filename is @filename[$i]
19:46 TimToady those are spelled @filename[$i] in P6
19:46 pugssvn r31464 | moritz++ | [t/spec] more rakudo unfudges
19:46 pugssvn r31465 | moritz++ | [t/spec] more rakudo unfudges
19:47 TimToady well, *.IO will probably work, if *.open doesn't...
19:47 hmmm P6 is using better syntax perhaps ;)
19:47 sorear @filenames».IO».open?
19:48 TimToady IO probably defaults to readonly open anyway, if you do anything to read from it
19:48 TimToady ingy would approve
19:48 sorear ++ to whoever thought to put Camelia in the topic, btw
19:48 sorear What is "IO" semantically?
19:49 Trashlord joined #perl6
19:49 TimToady an abstract handle that can do a few dwimmy things
19:50 TimToady the idea is something of ingy's from P5
19:50 sorear How is it not a File?  Or a Path?
19:50 TimToady so IO("in") ==> IO("out") would copy a file
19:50 TimToady though in P5 he did it with overloading existing operators
19:52 TimToady but it's representing the file in the abstract until you do something with it, so "foo".IO.e just tells you if the file exists, and doesn't necessarily have to open it, unless we decide to do so to avoid races
19:53 ingy :)
19:53 TimToady and .IO workds because it's a coercion
19:53 TimToady ingy: that's why I keep trying to get you to rewrite the IO pod :)
19:54 TimToady so there's no IO method in Str
19:54 ingy TimToady: it's on my stack :)
19:54 TimToady yes, but since it got pushed some time ago, it just keeps getting deeper, since that's how stacks work
19:54 TimToady maybe you need a fifo
19:55 plobsing joined #perl6
19:55 ingy it's just below <replace pod> ;)
19:56 TimToady Aw, kwid it!
19:56 TimToady in theory you can just say =use kwid and off you go...
19:56 ingy I would gladly review and comment on a document describing IO ala IO::All
19:57 ingy but I can't drive it at the moment
19:57 ingy it would Bind me ;)
19:57 TimToady we can't just assign it to you?
19:58 TimToady std: say 1 !% 2
19:58 p6eval std 31462: OUTPUT«[31m===[0mSORRY![31m===[0m␤Can't negate % because multiplicative operators are not iffy enough at /tmp/IOOocy67do line 1:␤------> [32msay 1 !%[33m⏏[31m 2[0m␤Parse failed␤FAILED 00:01 112m␤»
19:58 ingy I'm a python guy, ya know...
19:58 TimToady std: say 1 %% 2
19:58 p6eval std 31462: OUTPUT«ok 00:01 109m␤»
19:58 ingy crap
19:58 TimToady we all have our faults
19:59 ingy every time p6eval prints french quotes it borks my screen session
19:59 TimToady how 'bout you get into the 21st century and enable UTF-8
19:59 Juerd Do you want help fixing your screen?
19:59 ciphertext colomon: updated series feature list w/test information: http://nopaste.snit.ch/21594
20:00 ingy anyway, YAPC events made me switch a new project from python to p5
20:00 Juerd Does it blow up everytime someone writes "döt Net" too?
20:00 ingy Juerd: please
20:00 hmmm Borked here too w/ FF 3.6 & UTF-8...
20:00 ingy TimToady: I have utf-8 enabled everywhere
20:00 TimToady apparently not
20:00 moritz_ ingy: does it work without screen on that console?
20:00 ingy except the some unknown place, yah
20:01 moritz_ Ctrl+A :ut8 on
20:01 Juerd If it's linux, it's a broken locale :)
20:01 Juerd Is it linux?
20:01 moritz_ s/ut8/utf8/
20:01 ingy yes
20:01 Juerd ingy: In screen, what does locale output?
20:01 TimToady is LANG=en_US.UTF-8 ?
20:01 sorear TimToady: How is .IO not a method on Str?
20:01 pugssvn r31466 | pmichaud++ | [t/spec]:  Refactor/refudge some tests in sigils-and-types.t
20:02 TimToady any coercion may be defined on either end
20:02 TimToady so it could be a method on string, but it's supposed to know that *.IO fails over to IO()
20:03 TimToady because IO is a type
20:03 ingy evidently utf8 on was not in my .screenrc
20:03 ingy added and rejoined
20:03 TimToady std: say "hi to ingy"
20:03 ingy std: say 1 !% 2
20:04 p6eval std 31466: OUTPUT«ok 00:01 111m␤»
20:04 p6eval std 31466: OUTPUT«[31m===[0mSORRY![31m===[0m␤Can't negate % because multiplicative operators are not iffy enough at /tmp/Jk_lnpcL7a line 1:␤------> [32msay 1 !%[33m⏏[31m 2[0m␤Parse failed␤FAILED 00:01 109m␤»
20:04 Juerd ingy: It doesn't have to be on.
20:04 Juerd ingy: That is, screen enables it automatically if you use the right locale.
20:04 ingy Juerd: it seems to work now
20:04 Juerd ingy: That's good enough :)
20:04 TimToady you sure it was the utf-8 and not the colors?
20:04 Juerd Still you may want to look at your locales (locally, remote, and remote+screen) if you encounter more utf8 breakage.
20:04 ingy Hiragana (平仮名, ひらがな or ヒラガナ?)  is a Japanese syllabary,
20:05 ingy hmm, that didn't work
20:05 TimToady hmm, that was mojibake here
20:05 Juerd That looks lovely. http://juerd.nl/i/1de78c205cf7750f4017734309ddc798.png
20:05 ingy maybe irssi
20:05 TimToady copied from a Big-5 window maybe?
20:05 Juerd Irssi too Just Works if the locale is correct
20:05 ingy http://en.wikipedia.org/wiki/Hiragana
20:05 Juerd But you may force it with /set term_charset UTF-8
20:05 ingy utf8
20:06 TimToady 平仮名, ひらがな or ヒラガナ
20:06 TimToady works fine for my paste
20:06 ingy <@TimToady> ??????, ???????? or ????????
20:06 masak ok, I think I've learned to like %% now. TimToady++ :)
20:06 masak TimToady: does this change mean that the concept 'iffy' isn't needed any more?
20:06 TimToady on the OUTPUT lines above, is there and extra ^A before the « and such
20:07 TimToady masak: no, it doesn't
20:07 * Juerd just looked up %%. I thought !% did that.
20:07 TimToady it dide
20:07 TimToady *did
20:07 TimToady now it doesn't
20:08 Juerd Because % isn't a comparing op?
20:08 masak Juerd: there was a deja vu, er, spec change today.
20:08 ingy I have term_charset = "utf-8"; in my irssi conf
20:08 ingy under settings
20:08 Juerd ingy: But how about your locale? :)
20:08 ingy Juerd: checking
20:08 TimToady because it was confusing people about NOT-raising, and we could agree one whether it was better with ?%
20:08 TimToady *couldn't
20:08 Juerd ingy: Check everywhere: local terminal, remote terminal, remote screen
20:08 molaf joined #perl6
20:09 Juerd TimToady: I see
20:09 TimToady what the heck is the matter with my "n't" key these days?
20:09 Juerd I wonder what your keyboard looks like
20:10 TimToady it's that extra red key between n and t that comes on thinkpads
20:10 TimToady when I press it, it does work
20:10 TimToady *n't
20:10 moritz_ lol
20:11 Juerd My thinkpad must be broken
20:11 ingy Juerd: http://nopaste.snit.ch/21595
20:11 masak I was always a fan of that extra red key on ThinkPads.
20:11 Juerd "Problem desciption: n't key broken" I'm sure they'll understand and send me a new one.
20:11 ingy Juerd: looks like my linux server needs locale fix
20:12 Juerd ingy: Yes. One option is to allow ssh to copy the environment variables. The other option is to hard-code it in your profile/bashrc/whatever
20:12 TimToady and your Mac is LANG=C
20:12 TimToady which might be a problem
20:12 Juerd Ah, that too
20:13 TimToady I *only* set LANG
20:13 * sorear ponders that %% should maybe be spelled |
20:13 TimToady well, I set *only* LANG
20:13 sorear with the arguments flipped, ofcource
20:13 cygx moritz_: I think the 'Controller' part of try.rakudo.org can actually be implemented in Perl6
20:14 Juerd ingy: You'll have to restart screen to really fix things.
20:14 ingy export LC_ALL=en_US.UTF-8
20:14 ingy ?
20:14 Juerd ingy: After you've fixed the locale itself, that is
20:14 Juerd ingy: Like TimToady, I just set LANG
20:14 Juerd export LANG=en_US.UTF-8
20:14 ingy ok
20:14 moritz_ cygx: yes, works for me
20:14 Juerd Then, check with locale if it picked it up
20:14 ingy I share my dot files anyways
20:14 Juerd If it doesn't, you're probably running Debian :)
20:14 masak sorear: infix:<|> is... taken... :)
20:14 TimToady sorear: um, I think | is taken
20:14 ingy ubuntu
20:15 Juerd In which case the fix is to add en_US.UTF-8 to /etc/locales and running update-locales)
20:15 Juerd s/\)//
20:18 * TimToady ==> $mt_vernon_OH;
20:18 TimToady &
20:18 pugssvn r31467 | pmichaud++ | [t/spec]:  Update fudging, mark test as possibly bogus.
20:21 hmmm Has Perl6 made array of arrays (AoA) simple to index?  perl5 was not so simple imho...
20:21 tadzik yep
20:21 cygx moritz_: we'd have to use POSIX:from<perl5> for non-blocking IO and MySQL, since that's what FakeDBI currently supports, but it seems workable
20:21 sorear Uh, the Perl6 way is the same as the Perl5 way
20:21 tadzik arrays do not flatten like in Perl 5, so you can just use 2-dimensional arrays, not array of arrayrefs
20:21 sorear @AoA[2][3]
20:21 cygx moritz_: it also might be a good idea to use a global controller instead of spawning a new one for each session...
20:22 pmichaud is "sink" specced to return Nil?
20:24 mmcleric joined #perl6
20:27 hmmm Perl5 AoA were not so simple to code/use, so i hope it is better in Perl6.  =)
20:28 * ingy restarts screen and irssi
20:29 ilogger2 joined #perl6
20:29 masak hmmm: you should check out S09, and see if it is to your liking.
20:29 hmmm Thxs All!  =)  gotta run...
20:30 hmmm Huh, S09?
20:30 masak http://spec.pugscode.org/
20:31 masak http://perlcabal.org/syn/S09.html
20:31 hmmm thxs, gotit.
20:31 masak enjoy.
20:33 ingy joined #perl6
20:33 sorear «
20:33 ingy agana (平仮名, ひらがな or ヒラガナ) is a
20:33 sorear loud and clear.
20:33 ingy seems nice!
20:33 ingy :)
20:34 ingy screen flashed a msg saying something about utf8 on and window
20:34 ingy when I started it
20:36 ilogger2 joined #perl6
20:36 ingy it flashed: /home/ingy/.screenrc: utf8: window required
20:36 masak the section "Autosorted hashes" by the end of S09 seems to raise more questions than it answers. is there really a pressing need to keep that section.
20:37 masak at the risk of repeating myself, the solution it proposes sounds like an excellent job for a (non-core) module.
20:37 masak :)
20:40 jnthn o/
20:40 masak lolitsjnthn!
20:40 masak how's the workshop?
20:40 jnthn Workshop has been nice
20:41 jnthn mberends++ gave a nice talk :-)
20:42 jnthn And I've drunk some nice Belgian beer.
20:42 jnthn So, all around, pretty good. :-)
20:44 ingy Juerd: now I have http://nopaste.snit.ch/21596
20:45 ingy Juerd: which is why I prolly set LANG=C in the first place
20:45 ingy :\
20:45 pmichaud rakudo:  say (&infix:<cmp>).count
20:45 p6eval rakudo a579f8: OUTPUT«Method 'count' not found for invocant of class 'Perl6MultiSub'␤  in main program body at line 11:/tmp/nQ1mO92fSP␤»
20:46 jnthn :(
20:46 jnthn Not that I'm sure that that'd do at the moment
20:46 jnthn Probably the proto should decide the answer.
20:47 moritz_ [max] &multi.candidates».count ?
20:47 pmichaud rakudo:  say (&infix:<cmp>).?count.WHAT
20:47 p6eval rakudo a579f8: OUTPUT«Parcel()␤»
20:47 moritz_ erm
20:47 pmichaud that's the problem.
20:48 moritz_ Nil
20:48 moritz_ isn't that supposed to be the outcome
20:48 jnthn Yeah, I think so.
20:48 pmichaud yes, but iirc,  Nil is defined
20:48 pmichaud which means that  &infix:<cmp>.?count   is defined if .count isn't available.
20:49 jnthn oh sh...
20:49 jnthn :|
20:49 jnthn I'm sure I had .? doing something different in the past.
20:49 * pmichaud looks a bit
20:49 jnthn And then changed it to Nil to match spec or something.
20:49 Juerd ingy: Do what the message says. Please check, etc.
20:49 jnthn .? should certainly return something undefined when there's no method found, anyway.
20:50 jnthn I had it as a Failure once but apparently that was "too hard" :-)
20:50 ingy Juerd: I did
20:50 ingy no worky
20:50 pmichaud $object.?meth(@args)  # calls method if there is one, otherwise Nil
20:50 pmichaud S12:849
20:50 Juerd ingy: Is this on the Apple or on the Linux box?
20:50 ingy that Perl on my linux box seems to want LANG=C
20:51 jnthn pmichaud: I think we were in line with spec there.
20:51 jnthn pmichaud: I'm surprised that Nil is defined.
20:51 ingy 5.8.8
20:51 Juerd ingy: Is your locale listed in /etc/locale.gen?
20:51 jnthn s/think/thought/
20:51 pmichaud jnthn: since Nil is just  ()   it's an empty container
20:51 pmichaud there are quite a few spectests (that we fail) that expect Nil to be defined
20:51 jnthn :S
20:52 pmichaud I was fixing those when I ran into this failure :)
20:52 jnthn OK, so maybe .? should not return Nil then :-)
20:52 jnthn Which is what I said before. ;-)
20:52 jnthn If it's not Nil and it's not Failure though, I'm at a loss as to what it should be.
20:52 pmichaud Since method calls are performed directly on
20:52 pmichaud any object, C<Nil.defined> returns C<True> just as C<().defined> does.
20:53 pmichaud (S02:2159)
20:53 ingy Juerd: http://nopaste.snit.ch/21597
20:53 jnthn Aye, I'm not disputing the spec says that Nil is defined and .? returns Nil.
20:53 jnthn I'm just saying I think that's the wrong decision.
20:53 jnthn (for .?)
20:53 pmichaud jnthn: right, I'm just verifying that something is inconsistent somewhere.  :)
20:53 jnthn Yeah, it is.
20:54 jnthn I'm not sure what the right answer is. Personally I'd say it's a Failure object.
20:54 ingy Juerd: seems like the same string as LANG
20:54 jnthn Which is how we once had it, but apparently that was too explodey.
20:55 pmichaud it's probably not Failure, because the method itself could've returned Failure
20:55 pmichaud there's "failure to dispatch" and "dispatched and method returned failure"
20:56 pmichaud although having    $foo.?xyz   return Failure seems like it loses less information if it returns a failure
20:56 jnthn Well, the "method could have returned it" probably holds up for just about any return value we could choose?
20:56 pmichaud if it just returns Nil, we don't ...   right
20:57 pmichaud (we don't know if it was unable to dispatch or dispatched and got Nil back)
20:57 jnthn Right, Nil is the "obvious" answer in that sense, just that it's defined.
20:57 jnthn Oh, yes...
20:57 jnthn It could return Nil
20:57 jnthn Heh :-)
21:00 Juerd ingy: Yes. Run locale-gen
21:00 Juerd ingy: Might fix things.
21:00 moritz_ masak: the tests in the pls branch of proto seem build out
21:00 moritz_ *bail out
21:00 * masak checks
21:01 moritz_ t/subcommands/build.t ............... 1/31 No such project: fetched in 'App::Pls::Ecosystem::Hash::project-info' at line 59:lib/App/Pls.pm
21:01 masak hm.
21:02 masak did I destroy something while creating the proof of concept?
21:02 pmichaud I think I can work around the .? issue for the moment.
21:02 ingy Juerd: with what options?
21:02 ingy I ran locale-gen;perl and got the same thing...
21:04 masak moritz_: confirmed. thanks for reporting.
21:06 ilogger2 joined #perl6
21:06 timbunce joined #perl6
21:07 ingy Juerd: for now I'll start screen/irssi with utf8 and then go back to C
21:07 ingy until I figure it out I guess
21:07 ingy at least everything works now... :\
21:08 ingy Juerd (and the rest of you): many thanks
21:08 masak moritz_: fixed, pushed. moritz_++
21:08 ingy so much nicer
21:08 ingy oooo
21:09 ingy Camelia has an ö
21:09 masak :)
21:09 ingy I feel so close to P6 now
21:09 moritz_ masak: confirmed
21:10 moritz_ masak: if you saw my last commit to proto/pls, you also know what I've been working on today
21:10 ingy »ö« döt Net
21:10 masak moritz_: saw it, and retroactively give my permission :) keep up the good work.
21:10 ingy My little sis
21:10 masak (permission to push to that branch, I mean. probably good to keep that file up-to-date)
21:11 masak ingy: it's so fascinating seeing the range of reactions to Camelia.
21:11 masak ingy: I think I mostly prefer the company of your side of the spectrum. :P
21:13 ingy :D
21:15 Juerd ingy: I wish I understood what is wrong.
21:17 tylercurtis moritz: how's the PAST::Pattern usage coming, any more bugs I need to fix(other than PCT::Pattern.new_subtype which I'm pretty sure is broken(I have a better and less flawed solution in the works, though))?
21:17 ilogger2 joined #perl6
21:17 tylercurtis moritz_, rather.
21:21 tylercurtis moritz_: I'll be disconnected for the next few minutes. Feel free to respond via purl or wait until I return.
21:24 pmichaud sub xyz() { return; };   say xyz().defined;
21:24 pmichaud rakudo: sub xyz() { return; };   say xyz().defined;
21:24 p6eval rakudo 7102d7: OUTPUT«0␤»
21:25 pmichaud empty return() returns Nil, yes?
21:25 ingy Juerd: it seems like it's /usr/bin/perl being picky...
21:26 ingy Juerd: I've seen that error from Perl a zillion times
21:26 ingy Juerd: try LANG=x perl
21:29 ingy Juerd: when I try 'LANG=x perl' on OSX perl doesn't care, but on linux it does
21:30 ingy maybe TimToady knows...
21:30 jnthn pmichaud: Yeah, should just  be an empty Parcel
21:30 masak http://www.audreyt.org/rakudo-camelia-sri.png # _sri++ audreyt++
21:31 * pmichaud fixes spectests for empty return.
21:32 pmichaud I just _know_ that I'm going to switch everything around based on Nil being defined, and then we'll have to switch it all back.  :-|
21:32 pmichaud rakudo:  my @array;   say @array ~~ Nil;
21:32 p6eval rakudo 7102d7: OUTPUT«1␤»
21:33 ingy Perl's moaning about locale problems can be silenced by setting the environment variable PERL_BADLANG="0"
21:34 * ingy tries
21:35 ingy Juerd: PERL_BADLANG="0" worked...
21:43 MarkSenn joined #perl6
21:44 Guest23195 left #perl6
21:46 Juerd Impressive
21:54 tylercurtis joined #perl6
22:00 Ross joined #perl6
22:05 FardadJalili joined #perl6
22:11 sorear Why is there so much hate for Camelia?
22:12 colomon considering that Perl's traditional mascots are camels and onions, that's a real good question.  :)
22:13 sorear Who uses the onion?
22:13 colomon the perl foundation, maybe?
22:13 colomon they were all over the yapc::na stuff
22:14 colomon (onions, I mean)
22:14 masak sorear: Camelia is provocative. those whose criticism includes the keywords "7-year old girls", "kindergarten" or "epillepsy" have simply taken the bait. :)
22:15 sbp yeah, I don't understand either
22:15 sbp I think Camelia is extremely good
22:15 sbp maybe that's the problem though
22:19 ciphertext solomon: updated series list: http://nopaste.snit.ch/21598  (i'm debugging/testing the items marked 'K' right now)
22:19 ciphertext *colomon
22:20 colomon got it.
22:20 Ross joined #perl6
22:32 M_o_C joined #perl6
22:48 eternaleye joined #perl6
22:49 pugssvn r31468 | pmichaud++ | [t/spec]:  Clean up (and unfudge) some tests involving Nil, sink, and undef.
22:53 dalek rakudo: 92d0c1c | pmichaud++ | src/Perl6/Actions.pm:
22:53 dalek rakudo: Empty statement list should return Nil.
22:53 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/92d0c1c4556c636370a242257f54f3422981af4a
22:53 dalek rakudo: ac1c280 | pmichaud++ | src/builtins/assign.pir:
22:53 dalek rakudo: Assigning Nil to a container resets it to type.
22:53 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/ac1c2809f8925b389e1ab153ad15398424955d3f
22:53 dalek rakudo: fd5e2e7 | pmichaud++ | src/builtins/Parcel.pir:
22:53 dalek rakudo: Parcels are always defined (even Nil).
22:53 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/fd5e2e7f0ed0aeabeb01e3114240002299cfe6cf
22:53 dalek rakudo: d401972 | pmichaud++ | src/core/List.pm:
22:53 dalek rakudo: $obj.?method returns Nil, not undef.
22:53 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/d401972ef7054607b5a7ca1163d74c21ef856a2e
22:53 dalek rakudo: 2334011 | pmichaud++ | src/Perl6/ (2 files):
22:53 dalek rakudo: Add statement_prefix:sym<sink>.
22:53 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/233401137e161f878b63044e7a1f371fd06817f3
22:54 diakopter sorear: re: camelia, imho people don't like it b/c of the maximally-saturated colors, many adjacent high-contrast boundaries (line drawing), lack of Web 2.0 gradients/sheens, and lack of 3D/perspective/shadow.  I'm not saying I don't like it for those reasons.
22:54 colomon sink!
22:59 ashleydev joined #perl6
23:00 diakopter sorear: personally, I like the shapes and attitude portrayed in Camelia, but not the flattening. If someone were to make a 3d model and render it with lighting and shadows and atmosphere :)..... well, then, ...
23:24 cotto joined #perl6
23:24 sftp joined #perl6
23:26 ciphertext ok... this is weird:  when i run "make  t/spec/S03-operators/series-arity2ormore.t" or "make spectest", i get a bunch of failures, but if i run "perl6  t/spec/S03-operators/series-arity2ormore.rakudo" or run the failing tests by hand (in REPL or in a file), they pass...
23:29 mmcleric joined #perl6
23:36 Transformer joined #perl6
23:45 ciphertext (d'oh... i forgot 'make spectest' doesn't do  'make install' for you )
23:53 Psyche^ joined #perl6
23:59 Kodi joined #perl6
23:59 justatheory joined #perl6

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

Perl 6 | Reference Documentation | Rakudo