»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
masak is November early enough to be before the Parrot IO debac^Wrefactor? 00:02
jnthn masak: I remember having to work around the stdin bug for my London Perl Workshop talk.
masak ...which was in November... 00:04
meaning I should probably look towards October.
jnthn sleep, 'night & 00:05
00:05 lue left
flussence b: .get; my $s = .slurp; $s ~~ /\x00/ 00:05
p6eval b 922500: OUTPUT«Method 'get' not found for invocant of class ''␤ in main program body at line 22:/tmp/FgoRUgx0YO␤» 00:06
flussence b: given $*IN { .get; my $s = .slurp; say $s ~~ /\x00/ }
p6eval b 922500: OUTPUT«␤»
flussence there, a working version :P
masak good ol' b. 00:07
00:09 lue joined
masak November release of Rakudo seems to be working better, knock on wood. 00:11
flussence ponders writing a Date class for niecza that uses terrifying amounts of qx[] internally
.oO( class Date { method today { qx[rakudo -e 'say Date.today'] }; ... } )
00:13
masak lue: strangelyconsistent.org/blog/feed.atom should now be readable again. sorry for the inconvenience. 00:14
lue masak: it's fine, just thought I'd let you know (and apparently a really good reason I did)
masak lue: yeah, keep up the good reporting. 00:16
lue: anyway, I hope it worksforyou again.
00:17 Khisanth joined
lue yep, wfm again :) 00:17
masak \o/ 00:18
lue++
Parrot--
diakopter rurban: how does p2 "support dynamic typing" more than jvm? are you simply saying that "variables" (registers? stack?) can store different types? 00:21
rurban: in both places, you have to build a type system
so I don't see the big distinction
00:22 Khisanth left
masak if anyone asks, I'll be over here on Rakudo #58 Walnut, where IO works. 00:23
'night, #perl6 00:24
diakopter 'nite
00:27 [Coke] joined 00:30 Khisanth joined 00:32 lue left 00:39 palakas_ left 00:42 palakas_ joined, lue joined 00:44 Khisanth left 00:50 benabik left 00:54 benabik joined 00:59 Khisanth joined 01:03 Khisanth left 01:06 imarcusthis left
benabik appears to have fixed the NULL bug. 01:08
01:08 Khisanth joined, anuby joined 01:09 imarcusthis joined
benabik If anyone wants to try with parrot master, I'd be appreciative. :-) 01:14
01:19 raiph left 01:20 Util left, Util joined, hypolin joined 01:25 raiph joined 01:42 balders_dod joined 01:45 balders_1od left 01:51 nnunley joined 01:56 kst` joined 01:57 Targen left 01:58 Targen joined 02:00 kst left 02:23 baest_ joined 02:27 Khisanth left
[Coke] Sure. give me a few moments. 02:27
02:39 FROGGS left 02:40 Khisanth joined, dayangkun left
[Coke] build fails: gist.github.com/4688763 02:43
02:52 FROGGS joined 02:55 Khisanth left
colomon benabik++ 02:59
03:04 colomon left 03:12 colomon joined 03:18 Khisanth joined 03:33 [pp]sromanov left 03:45 [pp]sromanov joined
benabik got pulled away by kiddo, back. 03:45
[Coke]: That one's surprising to me, but looks unrelated to I/O issues... 03:46
03:48 Khisanth left
benabik Hm. compilation is much faster without that runaway process from my research. :-D 03:50
03:52 DarthGandalf joined 03:53 dayangkun joined 03:56 ohrmazd left 03:59 alec__ joined 04:04 Khisanth joined 04:05 alec__1 joined, alec__ left 04:09 preflex left 04:11 s1n joined, alec__1 left 04:12 preflex joined 04:16 Khisanth left 04:23 hulu joined
hulu map({say $^a},(1..6)) 04:25
helo
why this no responce
is anyone here? 04:28
japhb hulu, There are some people about, 04:30
but not all of us are watching the channel at the moment.
Were you looking for p6eval?
r: map({say $^a},(1..6))
p6eval rakudo 9ec0a5: OUTPUT«1␤2␤3␤4␤5␤6␤»
hulu thx 04:32
map(->$a,$b {say $a},(1..6)) 04:33
what means of ->$a,$b
japhb That means $a and $b are the names of the parameters of the following block 04:34
The arrow is meant to indicate "inputs are going here" 04:35
or even "input arguments are bound to these variables"
04:35 Khisanth joined
japhb hulu, BTW, it is idiomatic (and sometimes required) to put whitespace in more places than you have. 04:36
You may find that trying to avoid spaces will cause parsing errors. :-)
hulu japhb: thx 04:46
map({say $^a; say @^others;},(a..e)) 04:49
why this can't run
timotimo r: 34 \ 5 04:50
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/4DxqPTB8wv:1␤------> 34 ⏏\ 5␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ statement end␤ statement modifier␤ statement modi…
timotimo r: 34 ± 5
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/gHqmmRKC5Q:1␤------> 34 ⏏± 5␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ statement end␤ statement modifier␤ statement modi…
timotimo r: 34 ~~~ 5 04:51
p6eval rakudo 9ec0a5: ( no output )
timotimo oh, that exists? probably multiple prefix:<~>
colomon r: 34~~~5 04:52
p6eval rakudo 9ec0a5: ( no output )
colomon r: 34~~ ~5
p6eval rakudo 9ec0a5: ( no output )
colomon r: say 34~~ ~5
p6eval rakudo 9ec0a5: OUTPUT«False␤»
colomon r: say 34~~~5
p6eval rakudo 9ec0a5: OUTPUT«False␤»
colomon r: say "5"~~~5
p6eval rakudo 9ec0a5: OUTPUT«True␤»
hulu r: map({say $^a; say @^others;},(a..e))
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Undeclared routine:␤ a used at line 1␤␤»
colomon r: say "5" ~~~ 5
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/Ry7NNWZT9y:1␤------> say "5" ~⏏~~ 5␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ prefix or term␤ prefix or meta-prefix␤»…
colomon r: say "5" ~~~5
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/qduyrLgH79:1␤------> say "5" ~⏏~~5␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ prefix or term␤ prefix or meta-prefix␤»… 04:53
colomon r: say "5"~~~5
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/0OwHFbpeFF:1␤------> say "5"~⏏~~5␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ prefix or term␤ prefix or meta-prefix␤»…
colomon r: say "5" ~~~ 5
p6eval rakudo 9ec0a5: OUTPUT«True␤»
colomon stupid extra characters my irc client throws in sometimes...
hulu japhb: hi, why map({say $^a; say @^others;},(a..e)) can't run
japhb r: map({say $^a; say *@^others;},(a..e)) 04:54
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/xAkRoyN1G6:1␤------> map({say $^a; say *⏏@^others;},(a..e))␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ statement end␤ statement …
timotimo was just trying to see if rakudo is going ot suggest routines if a infix/prefix/postfix doesn't exist
seems okay, the way it is now. good.
japhb r: map {say $^a; say *@^others}, a..e 04:55
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/kIOBkyyQwu:1␤------> map {say $^a; say *⏏@^others}, a..e␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ statement end␤ statement mod…
japhb r: map -> $a, *@others {say $a; say @others}, 'a'..'e' 04:57
p6eval rakudo 9ec0a5: OUTPUT«a␤␤b␤␤c␤␤d␤␤e␤␤»
japhb hulu: ^
hulu japhb: why 04:58
japhb hulu, two things: you forgot to quote the letters in the range, and slurpy doesn't work with implicit arguments
Oh, and silly me, I forgot that slurpy is ignored when figuring out how many arguments map should supply to the block. 05:00
So it's only ever filling $a, heh
But:
r: (-> $a, *@others {say $a; say @others})('a'..'e') 05:01
p6eval rakudo 9ec0a5: OUTPUT«"a".."e"␤␤»
japhb r: (-> $a, *@others {say $a; say @others})(('a'..'e').list)
p6eval rakudo 9ec0a5: OUTPUT«a b c d e␤␤»
05:01 alec__ joined
japhb Interesting! 05:01
r: (sub ($a, *@others) {say $a; say @others})(('a'..'e').list) 05:02
p6eval rakudo 9ec0a5: OUTPUT«a b c d e␤␤»
japhb r: (-> $a, *@others {say $a; say @others})(|'a'..'e')
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&prefix:<|>' called (lines 1, 1)␤»
japhb r: (sub ($a, *@others) {say $a; say @others})(|('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«a␤b c d e␤»
japhb Wow, I'm really tired tonight, clearly
r: (-> $a, *@others {say $a; say @others})(|('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«a␤b c d e␤»
05:03 kaleem joined
japhb Yeah, there we go, that's what I was trying to say 05:03
hulu japhb: thx 05:06
05:08 Khisanth left
hulu r:map -> $a, *@others {say $a; say @others}, 'a'..'e' 05:12
r: map -> $a, *@others {say $a; say @others}, 'a'..'e' 05:13
p6eval rakudo 9ec0a5: OUTPUT«a␤␤b␤␤c␤␤d␤␤e␤␤»
hulu r: map (-> $a, *@others {say $a; say @others})('a'..'e') 05:17
p6eval rakudo 9ec0a5: OUTPUT«"a".."e"␤␤Cannot call 'map'; none of these signatures match:␤:(&code, *@values)␤␤ in block at /tmp/N2rjr3JNJJ:1␤␤»
hulu r: (-> $a, *@others {say $a; say @others})('a'..'e')
p6eval rakudo 9ec0a5: OUTPUT«"a".."e"␤␤»
05:22 Khisanth joined
hulu japhb: why map({ [ $x, @^others ] }, ('a'..'e')) can with @^others 05:23
geekosaur not even sure what was asked there 05:27
hulu r: $x='v';map({ [ $x, @^others ] }, ('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Variable '$x' is not declared␤at /tmp/NKeM1gZzVM:1␤------> $x⏏='v';map({ [ $x, @^others ] }, ('a'..'e'␤ expecting any of:␤ postfix␤»
05:27 Khisanth left
hulu r: my $x='v';map({ [ $x, @^others ] }, ('a'..'e')) 05:27
p6eval rakudo 9ec0a5: ( no output ) 05:28
geekosaur r: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
hulu geekosaur: why @^others 05:30
geekosaur er, "others"is just a random name, nothing magical
hulu r: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 05:31
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
geekosaur in the pointy block example (which the above is *not*), what made it special was not the name "others" but the specification "*@name" which in a signature is a slurpy argument (i.e. eats everything else available into the list)
hulu r: my $x='v';say map({ [ $x, @^kkk ] }, ('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
geekosaur note that you do not have a signature in the stuff you;re playing with so it won't work there 05:32
hulu r:my $x='v'; say map({[$x,@^a]},('a'..'e')) 05:36
geekosaur need the space after the colon. "r: ..." 05:37
hulu r:my $x='v'; say map({[$x,@^a]}, ('a'..'e'))
geekosaur don't want the bot to trigger because someone started talking about r::myfunc or something
colon, not comma. "r: ..." 05:38
hulu r: my $x='v'; say map({[$x,@^a]},('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
hulu geekosaur: ths 05:39
geekosaur: thx
05:45 Khisanth joined
hulu r: map(->$a,$b {say $a},(1..6)) 05:48
p6eval rakudo 9ec0a5: OUTPUT«1␤3␤5␤»
hulu r: map -> $a, *@others {say @others}, 'a'..'e' 05:49
p6eval rakudo 9ec0a5: OUTPUT«␤␤␤␤␤»
TimToady huh
r: map -> $a, *@others {say @others}, ('a'...'e') 05:50
p6eval rakudo 9ec0a5: OUTPUT«␤␤␤␤␤»
05:50 Khisanth left
TimToady I suspect this might be a rakudobug 05:51
it's probably using introspection to determine the arity, and ignoring the slurpy arg
eventually we'd like to get to more of a partial-binding model, and then it would work right
geekosaur n: map -> $a, *@others {say @others}, ('a'...'e') 05:52
p6eval niecza v24-18-gaf64300: OUTPUT«Potential difficulties:␤ $a is declared but not used at /tmp/SfBpTtDpus line 1:␤------> map -> ⏏$a, *@others {say @others}, ('a'...'e')␤␤»
TimToady r: say -> $a, *@others {say @others}.arity
p6eval rakudo 9ec0a5: OUTPUT«1␤»
TimToady in cases like these there should be a backchannel from the binder that says "I matched N args, save the rest for next time" 05:53
or more likely, no N involved, just returns a list tail for the next iteration's use 05:54
moritz \o 05:55
TimToady the ability to reference a list's tail is slightly more problematic when lists aren't represented as pure cons lists as they are in Lisp
so it's one of those hard things we haven't quite got nailed down
moritz: I don't quite understand why / can't be pure even if it's creating Rats 05:58
moritz TimToady: me neither, TBH
TimToady: I think it could be, but the optimizer tries its hand on the setting, and runs into something bootstrappy, I think 05:59
TimToady still thinks we'll probably end up with another level of bootstrap for such reasons... 06:00
it's kinda like trying to construct a single-stage-to-orbit rocket otherwise
moritz maybe a bit experimenting with it that's not past my biological bed time might reveal what#s going on :-)
s/'#'/\'/ 06:01
TimToady it seems to be that it's probably of biological origin that you are up :)
moritz no, that's just the usual $work and $daughter's-daycare routine 06:03
TimToady your daughter is not biological? :)
moritz she is, her daycare facility is... well, a facility :-) 06:04
TimToady perhaps they should think about employing some...humanoids...there...
anyway, guten morgen 06:05
moritz :-)
06:06 Khisanth joined 06:08 nnunley left 06:16 Khisanth left
hulu my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 06:17
r: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 06:18
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
TimToady say ('a'..'e')[0] ~~ Positional
hulu geekosaur: why my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) with @^others '@'
TimToady r: say ('a'..'e')[0] ~~ Positional 06:19
p6eval rakudo 9ec0a5: OUTPUT«False␤»
TimToady I guess it's not checking the @ on binding
so, a different rakudobug
geekosaur hulu, I'm not sure, are you asking why the @? it indicates a list 06:20
and it should probably be failing because it's getting a scalar
(hence, rakudobug) 06:21
06:21 dayangkun left
geekosaur n: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 06:21
p6eval niecza v24-18-gaf64300: OUTPUT«Unhandled exception: Nominal type check failed in binding '@others' in 'ANON'; got Str, needed Positional␤ at /tmp/jZN5BNkA8m line 0 (ANON @ 1) ␤ at <unknown> line 0 (KERNEL map @ 2) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2425 (GatherIterator.re…
geekosaur right
06:21 Khisanth joined
hulu n: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 06:22
06:22 dayangkun joined
p6eval niecza v24-18-gaf64300: OUTPUT«Unhandled exception: Nominal type check failed in binding '@others' in 'ANON'; got Str, needed Positional␤ at /tmp/ww7mNz245f line 0 (ANON @ 1) ␤ at <unknown> line 0 (KERNEL map @ 2) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2425 (GatherIterator.re… 06:22
TimToady that's the sort of error rakudo should be giving, but isn't
geekosaur hulu, I think you may still be confused about what japhb was doing with the pointy block (-> $a, *@others {BLOCK}); it was declaring that the block takes a fixed scalar parameter to be referred to as "$a" and an indefinitely sized list that sucks up everything else available, to be called "@others". 06:23
it's a kind of anonymous subroutine 06:24
or function if you prefer
TimToady which shows a different bug
hulu geekosaur: why use @^others ,not $^others
geekosaur the names aren't special; what is special is $ is scalar, @ is list, and *@ in a signature is a slurpy list (= take everything available) 06:25
and as niecza is teling you and rakudo isn't, you do NOT want a list there
TimToady well, but what if hulu *does* want a list there, hence "others"?
geekosaur that said, I think $^others would fail as well because map wants a single parameter 06:26
TimToady yes, you can't get the slurpy semantics of "others" without the *
hulu n: my $x='v';say map({ [ $x, $^others ] }, ('a'..'e'))
p6eval niecza v24-18-gaf64300: OUTPUT«v a v b v c v d v e␤»
hulu why $^others same as @^others
TimToady and you can only put the slurpy * in an official signature
geekosaur hulu, because rakudo has a bug 06:27
TimToady all things are scalars by default in Perl 6, including containers
you have to do something special to get them to act like containers
geekosaur niecza is doing the right thing and cpomplaining if you use @^others (which means it wants a list, but map is passing each scalar in the list separately)
rakudo is for some reason letting it go... 06:28
TimToady I guess my question is, if you really want to bind all of the elements of the list, why are you using map, and not just a normal call to a function with a signature? 06:29
06:31 dayangkun left
moritz three errors in the constant-folding branch 06:31
TimToady three is a constant, so you can fold that too
moritz that is, three spectest files aborting
one is a construct that uses 1 div 0 to generate an exception 06:34
the others seems to be something where a named argument accidentally becomes positional 06:35
ah, might be easy to fix 06:37
named arguments aren't constructed a Pairs, but as ordinary QAST node with .named($name) in addition 06:38
so it's hopefully just a matter of adding the .named to the generated value
hulu r: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e')) 06:39
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
hulu r: my $x='v';say map({ [ $x, $^others ] }, ('a'..'e'))
p6eval rakudo 9ec0a5: OUTPUT«v a v b v c v d v e␤»
hulu n: my $x='v';say map({ [ $x, $^others ] }, ('a'..'e'))
p6eval niecza v24-18-gaf64300: OUTPUT«v a v b v c v d v e␤»
hulu n: my $x='v';say map({ [ $x, @^others ] }, ('a'..'e'))
p6eval niecza v24-18-gaf64300: OUTPUT«Unhandled exception: Nominal type check failed in binding '@others' in 'ANON'; got Str, needed Positional␤ at /tmp/sEqT81Wwoy line 0 (ANON @ 1) ␤ at <unknown> line 0 (KERNEL map @ 2) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2425 (GatherIterator.re…
TimToady in most compilers, something like 1 div 0 will just be replaced by code that throws that exception if it's actually executed 06:40
whether it should warn about that at compile time might depend on whether we can show that it is unreachable code 06:41
or if we delay the warning till after unreachable code is deleted, then if 0 { 1 dif 0 } just kind of disappears before the pass that looks for "will throw exception" warnings 06:43
or we could just make people write "eval '1 div 0'" if they mean that 06:44
geekosaur plus.google.com/u/0/10220845651992...ZsZ6mvA4T6
06:48 dayangkun joined
TimToady or just 1 div ($*PID - $*PID) or so 06:53
hulu geekosaur: why my $t = Net::Twitter->new() use -> why not . 06:54
geekosaur er? perl6 doesn't use -> that way any more
TimToady hulu, you must be looking at some Perl 5 code 06:55
hulu github.com/perl6/perl6-examples/bl...ter2irc.pl
look at 72 row
TimToady yes, that is Perl 5 coe
*code
geekosaur why use a 2-character operator for something common? so concatenation was moved to ~ and . was reclaimed for method calls
geekosaur running a bit behind, still loading... 06:56
I don';t think we have POE on perl 6 yet :)
so that's plain old perl5 code 06:57
diakopter r: my \foo 06:58
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Method 'ast' not found for invocant of class 'NQPMu'␤»
diakopter _._.
hulu TimToady geekosaur : thex 07:00
TimToady geekosaur : thx
TimToady hulu: as a linguist, I am wondering what your native language is 07:01
hulu chinese
TimToady cool
hulu my english is poor
thx a lot 07:02
TimToady well, happy new year in a few days
hulu yes chunjie
TimToady you should speak 中文 with masak when he is on 07:03
hulu 你好 masak
TimToady 睡着, probably 07:04
or 睡眠 maybe 07:05
hulu 睡觉
TimToady okay, thanks 07:06
谢谢, I should say :)
hulu hehe
TimToady 哈哈 07:08
hulu bye bye 07:09
TimToady only really knows some 日本語...
07:10 hulu left 07:11 user joined
user std: say helo 07:12
p6eval std 7deb9d7: OUTPUT«===SORRY!===␤Undeclared routine:␤ 'helo' used at line 1␤Check failed␤FAILED 00:00 41m␤»
user std: say 'helo'
p6eval std 7deb9d7: OUTPUT«ok 00:00 42m␤»
FROGGS TimToady: short question, if -e '$( 1 )' and -e '"$( 1 )"' bot call circumfix:sym<sigil>($( 1 )), why does -e '/$( 1 )/' calls postcircumfix:sym<( )>(( 1 )) instead?
07:12 user left
FROGGS TimToady: I would expect to see circumfix:sym<sigil> for all three, when running ./viv -e ... for example 07:13
TimToady probably a bug 07:14
FROGGS cool, okay, thanks
diakopter std: \my &my ^my ::my $my /my %my *my @my >my (my ).my =my ::My \MY :=my ::mY (my [My ]).my +my $mY -MY
p6eval std 7deb9d7: OUTPUT«ok 00:00 47m␤»
FROGGS TimToady: maybe I'll supply a fix later today 07:15
diakopter TimToady: ^^
TimToady well, it said it was okay, so what's the problem? :) 07:16
diakopter std: \my &my ^my ::my $my /my %my *my @my >my (my ).my =my ::My \MY :=my ::mY (my [My ]).my +my $mY -MY -my-<my &my >.MY 07:17
p6eval std 7deb9d7: OUTPUT«ok 00:00 48m␤»
TimToady FROGGS: see the note that says: # Note: $() can also parse as contextualizer in an expression; should have same effect 07:19
diakopter rn: \my &my ^my ::my $my /my %my *my @my >my (my ).my =my ::My \MY :=my ::mY (my [My ]).my +my $mY -MY -my-<my &my >.MY
p6eval niecza v24-18-gaf64300: OUTPUT«===SORRY!===␤␤GLOBAL::my does not name any package at /tmp/MdkJT2jnsU line 1:␤------> \my &my ^my ::my⏏ $my /my %my *my @my >my (my ).my =my ::␤␤A type must be provided at /tmp/MdkJT2jnsU line 1:␤------> \my &my ^m…
..rakudo 9ec0a5: OUTPUT«===SORRY!===␤Cannot type check against type variable my␤»
TimToady it's possible we should do it all through <variable>, and throw out the circumfix versions
rather than having two code paths 07:20
07:21 dayangkun left 07:25 quester joined
FROGGS TimToady: that sounds reasonable, will try to do that in STD and nom 07:27
07:27 FROGGS left
diakopter std: \my &my ^my ::my $my /my %my *my @my >my (my ).my =my ::My \MY :=my ::mY (my [My ]).my +my $mY -MY -my-<my &my >.MY ^^My +&MY |mY <MY ??My !!mY Z?@my += My &&MY ,mY ;MY 07:30
p6eval std 7deb9d7: OUTPUT«ok 00:01 49m␤»
diakopter no clue what (my ) means 07:32
can't fit a single colon 07:36
07:43 dayangkun joined
moritz std: my: 42 07:47
p6eval std 7deb9d7: OUTPUT«ok 00:00 41m␤»
moritz diakopter: as a label :-)
std: :my
p6eval std 7deb9d7: OUTPUT«ok 00:00 41m␤»
moritz or as a colonpair 07:48
diakopter oh heh
I guess I could've tried
instead of merely imagining with my solid lack of Perl 6 knowledge
:) 07:49
moritz std: /:my $ = :my;/
p6eval std 7deb9d7: OUTPUT«ok 00:00 43m␤»
07:50 dayangkun left 07:55 balders_dod left 08:02 [pp]sromanov left 08:06 baest_ is now known as baest 08:07 brrt joined 08:09 FROGGS joined 08:13 erkan left 08:23 domidumont joined 08:34 hoelzro|away is now known as hoelzro 08:41 dayangkun joined 08:42 quester left 08:44 domidumont left, domidumont joined 08:50 lizmat left 08:52 Liz joined 08:53 Liz is now known as Guest94713 09:00 dayangkun left 09:04 erkan joined, erkan left, erkan joined
hoelzro morning #perl6 09:06
sjn o/ 09:11
09:11 Guest94713 is now known as lizmat 09:13 dayangkun joined 09:19 dakkar joined 09:30 hulu joined
hulu helo mazak 09:31
helo masak
09:34 fhelmberger joined
moritz \o 09:36
FROGGS o/ 09:39
09:44 Psyche^ joined 09:48 Patterner left, Psyche^ is now known as Patterner
jnthn morning o/ 10:00
diakopter o/
FROGGS hi all you happy perl 6 people :o) 10:01
jnthn TimToady: Maybe you could spec or define the partial binding in some more detail. Every time I've thought about it, it seems that it leads to making an already complex bit of code on a hot path even more complex (the binder), and is likely to make performance of map worse. 10:03
brrt is sorry to have missed part of that discussiong 10:05
jnthn TimToady: Things like, if you're doing this kind of bind, can we say you're only allowed to have a signature with positional things and no named things? Does a non-matched type check on an optional parameter cause a bind failure, or just to stop swallowing elements? etc.
10:05 cognominal joined 10:06 hypolin left
jnthn TimToady: And also how it looks. Maybe the answer is that it doesn't tell you how much it ate but just calls munch BUT that means we can't do the "we munched a vlaue but didn't meet they type constraint" thing as there's probably not a way to un-munch... 10:06
10:09 anuby left 10:10 cognominal left 10:11 risou left, yeltzooo left, masak left, odoacre left, TimToady left, prammer left, patspam left, jtpalmer left
jnthn [Coke]: The error you got looks like a very new NQP used with a less-new Rakudo 10:11
10:14 risou joined, yeltzooo joined, masak joined, odoacre joined, TimToady joined, prammer joined, patspam joined, jtpalmer joined
masak good forenoon, #perl6 10:14
diakopter masak: hoydw 10:15
masak lleoh.
diakopter is there a tool to search a whole git history for source code snippets? 10:16
brrt hi masak
moritz diakopter: I usually just do a git log -p and then use less' search
masak diakopter: I would... what moritz said. :) 10:17
diakopter: theoretically, you should also be able to filter out all blobs, and then list their contents.
by the way, "humanoids at the daycare facility" would make a great name for a rock band. 10:19
diakopter yikes, 30MB 10:22
dalek rakudo/constant-folding: 92c30bc | moritz++ | src/core/terms.pm: 10:23
rakudo/constant-folding: reverse order of <perl vendor site> dirs in @*INC
rakudo/constant-folding:
rakudo/constant-folding: we do not have to repeat all of the mistakes Perl 5 has made.
rakudo/constant-folding: nwc10++
10:23 dalek left
moritz that's the branch nom -> constant-folding merge 10:23
10:23 dalek joined, ChanServ sets mode: +v dalek
moritz you might be interested in github.com/rakudo/rakudo/commit/14...1bc72f710a 10:25
:-)
masak hulu: 你好 :) 10:26
diakopter moritz: I'll see your say and raise you a printf 10:27
jnthn moritz: oooh :)
moritz++
diakopter moritz: could you do?: if try { stuff; 1 } { $*W.add_object($ret_value); etc.} 10:31
nqp: say((try { die }).HOW) 10:32
p6eval nqp: OUTPUT«get_string() not implemented in class 'NQPClassHOW'␤current instr.: '' pc 825 (src/stage2/gen/NQPCORE.setting.pir:376) (src/stage2/NQPCORE.setting:404)␤»
diakopter nqp: say((try { die }).WHAT)
p6eval nqp: OUTPUT«␤»
diakopter hmm 10:33
masak: a few fun possible bugs in teh backlog
jnthn nqp doesn't do a Str/gist distinction so .WHAT will produce the empty string. 10:34
diakopter nqp: say((try { die }) ?? "success" !! "fail")
jnthn I'm not planning to change that.
p6eval nqp: OUTPUT«fail␤»
diakopter ... did I suggest you change it? 10:35
jnthn diakopter: Well, reporting a bug would suggest you expect it to ;-)
nwc10 the docs might need to change? 10:36
diakopter what made you think I was reporting a bug?
jnthn diakopter: Well, you suggested masak submit some. I was more writing it for his consideration than yours.
diakopter "masak: a few fun possible bugs in teh backlog" was referring to the backlog. when masak wasn't here.
jnthn diakopter: oh.
diakopter: I'm...not sure I was gonna figure that given the immediate context :) 10:37
diakopter ok, sry
masak I skimmed the backlog, but didn't find any fun bugs. 10:39
maybe I'll look again.
diakopter r: my \foo 10:40
p6eval rakudo 9ec0a5: OUTPUT«===SORRY!===␤Method 'ast' not found for invocant of class 'NQPMu'␤»
moritz jnthn: what do you think about merging the constant folding stuff?
jnthn r: my \foo = 42
p6eval rakudo 9ec0a5: ( no output ) 10:41
jnthn std: my \foo
p6eval std 7deb9d7: OUTPUT«===SORRY!===␤Term definition requires an initializer at /tmp/3lhUolBHoz line 1 (EOF):␤------> my \foo⏏<EOL>␤Check failed␤FAILED 00:00 41m␤»
jnthn Hm, wonder if it's a missing check
diakopter also, LTA error message on my tons-of-mys line noise art. (kidding) 10:42
masak: I guess it was just that one 10:43
jnthn moritz: Just read over the complete additions to Optimizer and it looks sane to me.
moritz so, merging? 10:44
jnthn moritz: +1 from me
nwc10 curious - can the speedup be measured?
moritz I haven't tried it 10:45
nwc10 :-)
moritz but since it inlines all routines marked as 'is pure' with constant-known argument lists, it's easy to construct a benchmark that'll show it
nwc10 that would be cool
moritz sub heavy() is pure { # do something slow }; heavy() for 1..1000; 10:46
nwc10 'cos like many of these things, there's a benefit to some use cases, and a small cost to everyone else (at compile time)
diakopter but of course, if you want your whole pure program to run at compile time... and it's long-running....
might be pessimized a lot 10:47
masak submits diakopter's rakudobug
diakopter oh yeah, there were some TimToady mentioned 10:48
when chatting with hulu
jnthn Well, if the program is *so* pure that the optimizer can reduce it to a single value... :)
10:48 PZt left
diakopter sure, like fib 10:48
jnthn moritz: Did .. get marked as pure, ooc? 10:49
moritz jnthn: no
jnthn moritz: May be appropriate...maybe :)
moritz: Given Range is immutable.
moritz jnthn: so far I've only marked a few random ops as pure
jnthn OK 10:50
masak r: my $range = 4..5; say $range; $range.shift; say $range
p6eval rakudo 9ec0a5: OUTPUT«4..5␤No such method 'shift' for invocant of type 'Range'␤ in block at /tmp/z8OP1yFU6q:1␤␤»
masak :) 10:51
b: my $range = 4..5; say $range; $range.shift; say $range
p6eval b 922500: OUTPUT«4 5␤Method 'shift' not found for invocant of class 'Range'␤ in main program body at line 22:/tmp/Gmpf_SLsfP␤»
masak alpha: my $range = 4..5; say $range; $range.shift; say $range
ENOALPHA
10:54 dayangkun left
masak enjoys TimToady trying to derive the Chinese word for "asleep" from his knowledge of Japanese in the backlog :) 10:54
moritz nwc10: perlpunks.de/paste/show/510b9ec1.7dbb.2c4
dalek p: 5233c6d | jnthn++ | src/ (2 files):
Make nqp::clone use repr_clone.

This means it will work with 6model objects. Also note that repr_clone has also been taught to deal with Parrot objects, but in a fully 6model implementation (like we have on JVM) such a code path is not needed.
10:55
p: aaf85c3 | jnthn++ | src/core/NQPRoutine.pm:
Some pir:: => nqp:: replacements.
moritz not quite the benchmark you wanted, because I was too lazy to recompile a rakudo without constant folding
jnthn moritz: Wait, it took longer with "is pure"? 10:56
nwc10 that's showing that it's slower with 'is pure'?
hulu helo
jnthn moritz: Or was "with" a typo for "without"? :)
moritz dammit, that should have been 'without "is pure"'
sorry for the confusion
nwc10 ah OK
hulu what's means my(@_classData)=('aaa','bbb','ccc');
jnthn It means you're calling the function my, which is probably not what you wish to do... 10:57
10:57 SmokeMachine joined
moritz it declares a variable called @_classData and assigns a list of trhee values to it 10:57
oh :-)
listen to jnthn, not me
jnthn It also means you're typing a lot of parens ;-)
r: my @c = 'aaa','bbb','ccc'; say @c 10:58
p6eval rakudo 9ec0a5: OUTPUT«aaa bbb ccc␤»
masak hulu: helo, helo! 很高兴终于见到你了。 10:59
hulu masak: 你好
10:59 stevan_ left
masak :D 10:59
hulu jnthn: what's means @_classData 11:00
masak hulu: 我不能写。我使用谷歌翻译。
hulu: that's just an array.
hulu: like @foo
hulu why use _classData
masak that's just a name.
hulu thx 11:01
masak maybe someone meant the underscore to mean 'for internal use'.
but that's convention, not specification.
hulu thx
masak: 我去吃点饭
masak have fun :) 11:02
om nom nom
arnsholt o/
masak it's only lunchtime here ;)
11:06 Su-Shee_ joined, Su-Shee left, Su-Shee_ is now known as Su-Shee
arnsholt jnthn: Since Rakudo's NativeHOW is used both for ints and floats, I guess the nativesize parameter should just be passed as both an integer and float bit size? 11:10
diakopter I take it pure also assumes deterministic, as in no usage of PRNG or other reading IO (that's not really a side-effect)
arnsholt Or would you prefer something else?
moritz diakopter: correct 11:11
jnthn arnsholt: No, "number of bits" was how I'd imagined it.
11:11 snobby joined, snobby left, snobby joined
jnthn arnsholt: Oh, I see what you mean...how does it know what to put in compose... 11:11
Hm. :)
lizmat is "pure" comparable to "memoizable" ? 11:12
jnthn I guess filling both kinda works...
arnsholt The quick hack solution is to pass both <integer><bits> and <float><bits>
11:12 Targen left
moritz lizmat: yes 11:12
11:13 cognominal joined
lizmat me wonders whether "is memoizable" wouldn't be a better phrase than "is pure" 11:14
masak depending on how strictly you apply "pure". do private updates (such as caching) count? memoization itself is memoizable but not (strictly) pure. :)
lizmat especially for people coming from p5 :-)
masak lizmat: "is memoizable" feels a bit long. and hard-ish to spell.
lizmat "is memo" ?
masak lizmat: maybe "is memable" would do. but I don't know if that's too cute.
hoelzro memorable? ;) 11:15
11:15 snobbo left
tadzik didn't we already have that? 11:15
memoization
masak in fact, I dunno if "-able" conveys a strong enough instruction, from the viewpoint of the reader.
flussence we could just steal postgres' terminology - "is immutable" 11:16
lizmat but that is not correct, is it? 11:17
flussence probably not :)
lizmat we just want to express that on a given set of inputs, only one output is to be expected, no?
jnthn lizmat:I think you're thinking of "is cached"
hoelzro ah, that's it. 11:18
jnthn "is cached" keeps track of a hash mapping the incoming capture to the results.
Which is different from "is pure" which means "if we know the args statically it's safe to assume we can call this statically"
That is, at compile time. 11:19
masak oh!
yes, then they're really different.
jnthn "is cached" is free to have side-effects so long as you can cope with them only happening once per incoming capture :)
lizmat ah, so it only applies at compile time? "is pure" only has an effect at compile time?
jnthn lizmat: It's a hint to the optimizer that it can constant fold the operation.
And that if it does, the user can't complain about it doing so :)
(And yes, the optimizer runs at compile time, just after CHECK time and before code-gen) 11:20
lizmat ok, gotcha:
so "is cached" is run time only, or also at compile time
jnthn Run time only (unless you somehow manage to call the thing at compile time, like doing so explicitly in a BEGIN) 11:21
I guess you could also mark something as "is pure" *and* "is cached" but I can't think of a use case right off.
masak likes the nomenclature, having understood it
11:22 kresike joined
kresike hello all you happy perl6 people 11:22
brrt hi kresike
hoelzro md5sum would be pure, and could be cached as well
tadzik hello kresike
hoelzro (that's the best example I can think of at the moment) 11:23
flussence is-prime?
tadzik grumbles
hoelzro is-prime is good
tadzik I don't like this is-prime
hoelzro fib(n)?
kresike brrt, tadzik, o/
arnsholt Are there any standard C types that are floating point analogues of int32_t and friends?
jnthn arnsholt: Are float/double not standard? 11:24
FROGGS double, ya
jnthn arnsholt: Or you mean, with the number of bits explicit int he name?
*in the
arnsholt Hmm. Maybe float and double are standard enough?
I sort of assumed they were underspecified for width 11:25
FROGGS well, this is a bit platform and/or compiler specific 11:26
see the output of configure.sh scripts, they query the size of these types
11:32 cognominal_ joined 11:34 cognominal left 11:36 not_gerd joined
not_gerd hello, #perl6 11:36
11:36 bbkr joined
not_gerd arnsholt: float and double are the standard types 11:37
bbkr "so far it does nothing, but also breaks nothing" - added to my favorite it quotes :)
not_gerd there's float_t and double_t for non-standard types of at least equal precision
11:37 brrt left
dalek kudo/nom: a1bcaa6 | moritz++ | src/core/ (2 files):
mark some numeric operators as pure
11:46
kudo/nom: 622595b | moritz++ | src/Perl6/Optimizer.pm:
first shot at constant folding

so far it does nothing, but also breaks nothing. It seems that the multi dispatch call optimization comes first, and interferes with this one
kudo/nom: cd64560 | moritz++ | src/ (2 files):
move constant folding code to the correct location; some small fixes
kudo/nom: 03cce4d | moritz++ | / (5 files):
Merge remote branch 'origin/nom' into constant-folding
kudo/nom: 14c9305 | moritz++ | src/Perl6/Optimizer.pm:
constant folding cleanup

  * catch it when the routine to be folded errors out
  * make sure to preseve namedness of named arguments
  * remove debug output
  => all spectests pass!
kudo/nom: 33d8dd0 | moritz++ | docs/ChangeLog:
update ChangeLog
moritz that was fun. 11:47
tadzik moritz++
masak \o/ 11:49
felher moritz: pure? as in 'without side effects'? 11:55
nwc10 at lower optimisation levels, it might be helpful to delay constant folding until the code is run for the first time 11:56
moritz felher: yes 11:57
nwc10 jnthn: code is first class? but, I presume, the section in the middle of a routine that does something constant is not easily chop-out-able?
so this might be a stupid suggestion, unless one is running with a JIT
moritz nwc10: so, memoization instead of constant folding, really? 11:58
jnthn nwc10: yeah, that sounds in the realm of what a JIT might do
nwc10 yes, but if you're memoizing the result of calling with a known constant, you can throw away the call site
arnsholt not_gerd: The sticking point is the sizes of the types. It's for writing NativeCall tests
But they're 4 and 8 bytes on 64-bit Intel, so it's standard enough for the time being I think 11:59
nwc10 in Perl 5 terms, you'd need to change the optree. But it's a tree, so splicing it is in theory possible. (ithreads becomes your practial problem)
not_gerd arnsholt: most implementations follow IEEE semantics to some extent (and thus 32bit float and 64bit double), but do you actually need to hardcode the values? 12:03
FROGGS not_gerd: if you want to (de)serialize structs from/to perl, then it matters 12:04
not_gerd: from your perl code you want to say: class A { has float $.a; has double $.b ), and later you will use this definition to map a memory area to this class, to access its attributes 12:05
if the float is guessed as 4 bytes, but is infact 8 bytes long, you have a problem 12:06
12:06 brrt joined
not_gerd FROGGS: sure - however, a float is always sizeof (float) bytes long as long as you serialize and de-serialize on the same architecture 12:06
if not, you need to specify an exchange format 12:07
FROGGS right, so you might have to query the compiler
not_gerd and sizeof (float) is every bit a compile-time value as 4
FROGGS to be cross-plattform-arch safe
not_gerd (except for preprocessing)
masak plane &
moritz masak: good travel 12:08
dalek p: 6005a68 | jnthn++ | src/ (4 files):
Add invocation spec.

This is a (porting friendly) way to specify how an object handles being invoked if it's not directly a code-ref.
12:13
p: 86d5182 | jnthn++ | src/stage0/ (9 files):
Update bootstrap.
p: f544686 | jnthn++ | src/core/NQPRoutine.pm:
Replace some v-table use with the invocation spec.
p: f7f8eb6 | jnthn++ | src/core/NQPRoutine.pm:
More pir:: -> nqp:: and add 'name' methods.
lizmat van & 12:18
sjn is off to Brussels to o/
moritz lizmat, sjn: good travels!
sjn "bon voyage", as they say :) 12:19
12:19 lizmat left 12:26 domidumont1 joined 12:27 domidumont left 12:30 [particle]1 joined, [particle] left
diakopter WHEE 12:31
er, ww
hulu masak: helo
12:32 Liz joined, Liz is now known as Guest24938 12:33 Guest24938 left
not_gerd r: gist.github.com/4691050 12:34
p6eval rakudo 33d8dd: OUTPUT«Attempt to return outside of any Routine␤ in block at src/gen/CORE.setting:488␤ in block at /tmp/StqydeDoHN:7␤ in method reify at src/gen/CORE.setting:5587␤ in method reify at src/gen/CORE.setting:5488␤ in method reify at src/gen/CORE.setting:5488␤ in metho…
not_gerd n: gist.github.com/4691050
p6eval niecza v24-18-gaf64300: OUTPUT«5␤»
not_gerd ^^^ rakudobug 12:35
FROGGS rn: gist.github.com/4691058 12:37
p6eval rakudo 33d8dd, niecza v24-18-gaf64300: OUTPUT«5␤»
not_gerd ooh - sink context strikes again
FROGGS looks like
not_gerd no bug, then
jnthn It's sink context, yes 12:38
Not a bug, but a NYI warning should be given.
moritz erm, for what? 12:40
jnthn moritz: I thought TimToady spec'd a warning in such situations. 12:41
"Declare a return type" or so...
I may be forgetting
dalek p-jvm-prep: 18e278b | jnthn++ | / (4 files):
Implement setting invocation spec.

It's not actually used yet, however.
12:43
p-jvm-prep: 78376f6 | jnthn++ | / (3 files):
Implement getcodeobj/setcodeobj.
p-jvm-prep: cf03bd9 | jnthn++ | src/org/perl6/nqp/runtime/Ops.java:
Make invoke handling the invocation protocol.
p-jvm-prep: fa58117 | jnthn++ | nqp-src/NQPCORE.setting:
Stub in NQPRoutine code object.

This is enough for it to work, but still need to fix clone (or more) to be able to uncomment the rest.
not_gerd adding a return type does not seem to help, wheras prefixing `sink` does 12:45
jnthn not_gerd: Yes, that bit of spec landed recently enough to be unimplemented so far.
not_gerd Rakudo apparently has gotten slower since Dec 4th, btw 12:46
psrsing speed is not as bad as it used to be, though 12:47
^parsing
12:48 hulu left
not_gerd problem 29 from my advent posting also runs faster than it used to 12:49
jnthn not_gerd: What got slower, out of curiosity? 12:55
not_gerd: sink context was a bit of a trade-off; the sinking makes some things cheaper, but has its own overhead.
not_gerd: We lost a little on parsing due to the high watermark stuff, but the far better parse errors are worth it... 12:56
12:58 nyuszika7h left
not_gerd jnthn: I don't really see a pattern as to what causes the slowdown 13:00
jnthn not_gerd: OK. How much are we talking?
13:03 nyuszika7h joined 13:04 kaleem_ joined
not_gerd jnthn: some random samples: 2.6s -> 3.1s for problem 3, 5.2s -> 6.3s for problem 53, 11s -> 9.6s for problem 29a, 1.5s -> 0.8s for problem 29c 13:05
13:07 kaleem left 13:10 kivutar joined
dalek p-jvm-prep: 0c369f7 | jnthn++ | / (3 files):
Basic nqp::clone implementation.
13:24
p-jvm-prep: ce11ca6 | jnthn++ | nqp-src/NQPCORE.setting:
Uncomment a bunch more of NQPRoutine code.
p-jvm-prep: 2cd759d | jnthn++ | lib/QAST/JASTCompiler.nqp:
Implement nqp::curlexpad.
kudo/nom: 5e5a76f | jnthn++ | / (2 files):
Updates to work with latest NQP additions.
13:31
volaj: ee261c5 | (Arne Skjærholt)++ | t/06-struct. (2 files):
Add tests for sized floats, and use is_approx instead of is for comparisons.
13:38
Heuristic branch merge: pushed 44 commits to rakudo/dyncall-sized-num by arnsholt 13:39
p/dyncall-sized-num: e50b1c2 | (Arne Skjærholt)++ | src/6model/reprs/P6num. (2 files):
Teach P6num about different sizes.
13:40
13:42 stopbit joined 13:44 pat_js joined
arnsholt jnthn: Rakudo has int{1,2,4}, which isn't going to work well with CStruct and P6opaque in the current state of affairs. I was going to just round sizes that aren't whole bytes up to the nearest byte, but if you've got other ideas I'm all ears 13:44
And for setting/reading them in P6int I'd treat them as bytes, but mask values we read/write with 0x1, 0x3, 0xf 13:45
moritz (it would be great if, at some point, an Array of 256 int1 objects would require just 8 byte storage; no idea if that's feasible with any of the current approaches) 13:47
arnsholt I'm not sure yet. But the thought of implementing it has crossed my mind ;)
After I do some cleanup after this get_attribute refactor, positionals are next on my list 13:49
jnthn arnsholt: For now, just round up. Yes, we can optimize later :) 13:50
arnsholt: Maybe Zavolaj should spot those cases and point out that they don't map to native land in a sane way. 13:52
r: use NativeCall; sub foo(int1 $x) is native { * } 13:53
p6eval rakudo 33d8dd: OUTPUT«===SORRY!===␤Could not find NativeCall in any of: /home/p6eval/nom-inst/lib/parrot/4.10.0-devel/languages/perl6/site/lib, /home/p6eval/nom-inst/lib/parrot/4.10.0-devel/languages/perl6/vendor/lib, /home/p6eval/nom-inst/lib/parrot/4.10.0-devel/languages/perl6/lib, /h…
jnthn star: use NativeCall; sub foo(int1 $x) is native { * }
p6eval star 2012.12: ( no output )
13:56 vividsnow left
arnsholt Yeah, complaining about weird sizes sounds like a good idea 13:58
13:59 GlitchMr left 14:15 PacoAir joined 14:17 benabik left 14:22 PacoAir left, PacoAir joined
pat_js hey is this "nesting of operators" section already implemented somewhere? (have some older versions of perl6es lying around here and updating takes probably about more than an hour) 14:22
nesting of metaops → perlcabal.org/syn/S03.html#Nesting_...aoperators
moritz r: my @a = 1, 2; my @b = 5; @a X[+=] @b; say @a.perl 14:24
p6eval rakudo 5e5a76: OUTPUT«Array.new(1, 2)␤»
moritz seems it's parsed, but rakudo doesn't like the variants that modify a variable
14:24 not_gerd left
pat_js ah okay 14:24
14:25 benabik joined
pat_js so it probably work on my computer, too. 14:25
i tried [R~]=
14:25 skids left
moritz r: my $a = 'a'; $b [R~]= 'b'; say $a 14:26
p6eval rakudo 5e5a76: OUTPUT«===SORRY!===␤Variable '$b' is not declared␤at /tmp/0Psk9dDoyG:1␤------> my $a = 'a'; $b⏏ [R~]= 'b'; say $a␤ expecting any of:␤ postfix␤»
moritz r: my $a = 'a'; $a [R~]= 'b'; say $a
p6eval rakudo 5e5a76: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix = instead␤at /tmp/PbvyKg9puK:1␤------> my $a = 'a'; $a [R~]=⏏ 'b'; say $a␤»
pat_js r: "foo" R= my $what; say $what; 14:27
p6eval rakudo 5e5a76: OUTPUT«foo␤»
pat_js p6: my $a = 'a'; $b [R~]= 'b'; say $a 14:31
p6eval niecza v24-18-gaf64300: OUTPUT«===SORRY!===␤␤Variable $b is not predeclared at /tmp/0YdTeWAViJ line 1:␤------> my $a = 'a'; ⏏$b [R~]= 'b'; say $a␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 1443 (die @ 5) ␤…
..rakudo 5e5a76: OUTPUT«===SORRY!===␤Variable '$b' is not declared␤at /tmp/C8k09zSn0f:1␤------> my $a = 'a'; $b⏏ [R~]= 'b'; say $a␤ expecting any of:␤ postfix␤»
moritz n: my $a = 'a'; $a [R~]= 'b'; say $a 14:32
p6eval niecza v24-18-gaf64300: OUTPUT«ba␤»
FROGGS reverse concat? 14:33
pat_js jup
FROGGS interesting
pat_js good for building strings 14:34
14:34 benabik left
pat_js n: my $a="world"; $a [R~]= " hello"; say $a; 14:36
p6eval niecza v24-18-gaf64300: OUTPUT« helloworld␤»
pat_js n: my $a="world"; $a [R~]= "hello "; say $a; 14:38
p6eval niecza v24-18-gaf64300: OUTPUT«hello world␤»
dalek p-jvm-prep: 22b32c8 | jnthn++ | src/org/perl6/nqp/runtime/ (3 files):
Oops, a coderef's object is not static.
14:39
p-jvm-prep: a4857d5 | jnthn++ | src/org/perl6/nqp/sixmodel/SerializationReader.java:
Closure and context deserialization/fixup.
p-jvm-prep: ea04fec | jnthn++ | t/nqp/56-role.t:
We now pass 56-role.t.
jnthn arnsholt: How far do you think you are from merging the NQP branch?
nwc10 jnthn: 56-role.t wasn't an easy win? as in, most of a day's thinking/hacking, just to get to one more? And they only get harder from here on in? 14:42
jnthn nwc10: Well, it blocked on a fairly large number of pieces. 14:44
nwc10: Some of which other things blocked on too.
The clsoure/context deserialization being one of them, and teasing out the way we handle invocation from Parrot's grasp into something that was portable being another. 14:45
Also, getting clone in place...which no doubt plenty of other things will want. 14:46
Roles are non-trivial 'cus they are instantiated per use, meaning that to do them right needs (de)serializing closures. 14:47
Since lexpad = type environment
arnsholt jnthn: Not terribly far I think 14:48
I'd like to refactor the at_pos stuff as well, but that should be relatively quick
14:48 FROGGS left
arnsholt Most of the thinking was done for the attribute stuff and reworking P6{int,num}. The positionals should be mostly a matter of copying that stuff over 14:49
jnthn arnsholt: OK. It's just that one of my upcoming tasks will need me to make a change to P6opaque's REPR data. 14:50
arnsholt Oh, right. What kind of time perspective do you have on that task?
jnthn arnsholt: And thus bump serialization version. Though I guess I can base my branch off yours if I block on that... :)
Well, it's one of the things I could work on Very Soon, but there's other things I can do too... :) 14:51
arnsholt Right. Hold off on it until over the weekend, and I'll try to get the branch mergable pretty soon, that work? 14:54
jnthn Works for me. 14:56
arnsholt Excellent
[Coke] jnthn: there's some drift between t/nqp in the 2 repos, aye? 14:58
14:59 lizmat joined
[Coke] New tests in either repo should get copied back to the other? 14:59
jnthn [Coke]: I'm trying to keep them in sync... 15:00
[Coke]: In t/nqp in nqp-jvm repo I'm only adding ones we pass so far.
[Coke]: But those files in both should be the same. If I've missed making that happen, it's a fail on my part.
15:02 kaare_ joined
[Coke] ok, I'll keep an eye out. 15:02
jnthn starts taking a look at mixins 15:03
Mixins. Multi dispatch. Exception handlers. After that I really have go nowhere to run besides the regex engine. :D 15:04
*got
arnsholt You can run, but you can't hide =D
lizmat is looking on in awe
tadzik weekend! \o/ 15:05
arnsholt lizmat: I went to a hackathon and suddenly I started hacking on the NQP guts. Not at all what I expected =D
lizmat has arrived in Brussels at the hotel 15:06
nwc10 wonders how this parallelises up from Jnthn
lizmat arnsholt: tried that as well, but had to bail after a while :-(
nwc10 take the repository, and try to build it in more and more places
to refine the build system 15:07
?
arnsholt lizmat: It was my second hackathon, actually. So all is not lost =)
jnthn tries to track down a fun bit of infinite recursion...please let it not be in the role composer. 15:10
nwc10 you say that like there is also non-fun infinite recursion 15:12
15:15 nnunley joined
jnthn Hm, happens in c3 MRO compuation. 15:16
15:18 benabik joined 15:21 lizmat left
arnsholt jnthn: Ordinary Perl 6 arrays don't use the at_pos_* REPR stuff? 15:25
jnthn arnsholt: No
arnsholt Thanks. Just making sure there wasn't a code I was missing =) 15:26
jnthn arnsholt: Nothing does besides the nativecall stuff *at the moment*. I'm expecting to change that in the not too distant future.
15:26 Liz joined
arnsholt Right'o 15:26
15:26 Liz is now known as lizmat
[Coke] www.smbc-comics.com/index.php?db=co...mp;id=2874 - Fourier transforms. 15:26
r: say :8(1160)
p6eval rakudo 5e5a76: OUTPUT«Nominal type check failed for parameter '$str'; expected Str but got Int instead␤ in sub unbase at src/gen/CORE.setting:4923␤ in block at /tmp/q3tciZTfBK:1␤␤»
[Coke] r: say :8<1160> 15:27
p6eval rakudo 5e5a76: OUTPUT«624␤»
[Coke] r: say :8<1160>, :12<440>, :5<4444>
p6eval rakudo 5e5a76: OUTPUT«624624624␤»
15:28 decasm left 15:30 stevan_ joined 15:31 decasm joined
nwc10 jnthn: you're not going to FOSDEM, are you? 15:32
15:32 claes_ joined, PZt joined
lizmat alas, I don't think jnthn will be there. masak *will* 15:32
claes_ jnthn: how come you settled on BCEL for JVM bc generation? 15:33
15:34 SmokeMac_ joined, xinming left
jnthn nwc10: No, gotta travel around middle of Sunday off to somewhere for $dayjob 15:34
claes_: I found the documentation decent and got something up and running pretty quickly. It also has no dependencies besides a JVM. 15:35
claes_: Is there an Obviously Better Alternative?
15:35 xinming joined
claes_ jnthn: dunno. I'm looking at cglib, objectweb asm and javassist 15:36
jnthn Ah, k.
claes_ jnthn: cglib uses bcel but I think provides some more stuff. But the docs are quite limited from what I've seen
jnthn It's worked reliably so far.
claes_ jnthn: I haven't used BCEL so I wanted a opinion on it from someone I trust
jnthn I wish its handling of branches was a bit less awkward to work with. 15:37
otoh, maybe I missed something important...
15:37 SmokeMachine left, domidumont1 left
claes_ heh =) 15:38
I'll have a look at how you use it in the nqp jvm backend for guidance =) 15:39
jnthn Anyway, I didn't couple too tightly to it for the code-gen. I currently dump the JAST (JVM AST) into a text file and then read that in and build JAST from it. 15:40
BooK_ jnthn, masak: starting a project at work where I might be able to do some DDD and CQRS (maybe)
jnthn Where JAST is a thingy I build to let me work slightly above the level BCEL does, and from NQP :)
*built
claes_ jnthn: neat 15:41
jnthn Once things are bootstrapped the intermediate text thing can go away.
And I'll just do straight from the AST down to bytecode.
The thing that turns the text file into Java bytecode is only 800 or so lines anyway... 15:42
BooK_: Nice :)
bah, seems my fail is that I messed up unshift somehow... 15:43
claes_ jnthn: how about parsing nqp? what do you use there? 15:44
nwc10 claes_: nqp is self hosting. It's using (I believe) Perl 6 regular expressions 15:45
now called "Rules", because, well, they aren't regular :-)
moritz yes, nqp can parse itself 15:46
and compile itself
claes_ oh I see, and that just outputs JAST then?
nwc10 for a small value of "just"
claes_ details =P 15:47
jnthn nwc10: I set it up as a cross-compiler
oops, claes_ :)
So, it uses the same parser/actions to produce an AST from the NQP source.
then instead of feeding into into the backend for producing Parrot bytecode, it gets given to a stage to make JAST, then JVM bytecode. 15:48
claes_ I see
jnthn And yes, NQP parses itself.
The nice thing being that we should be able to get NQP to cross-compile itself to the JVM eventually :) 15:49
nwc10 is still wondering if NQP on the JVM will be able to cross-compile to Parrot
15:50 johnjohn101 joined
claes_ jnthn: thanks. I'm mostly interested in the BCEL parts since I'm playing around with ANTRL4 for parsing 15:51
15:56 fhelmberger left 15:57 stopbit left 16:01 lizmat left 16:05 skids joined 16:06 breinbaas left 16:16 GlitchMr joined
moritz I cannot compile nqp/master 16:18
./nqp --target=pir --output=src/stage2/gen/NQPP5QRegex.pir \ src/stage2/gen/NQPP5QRegex.pm
too few positional arguments: 0 passed, 1 (or more) expected
jnthn hm, it builds here and I've no local diffs 16:19
Or unpushed commits
jnthn does make clean and tries again 16:20
16:20 claes_ left
moritz die "Repossession conflicts occurred during deserialization" 16:20
that's the line it complains about
wtf?
that's not even a call, it's an op
maybe the line numbers are off 16:21
jnthn Right
PerlJam Is that two spirits trying to occupy the same body?
moritz tries a git clean -xdf
jnthn PerlJam: Something like...
[Coke] I mention the work on the jvm to a geek crowd I know. I hesitate to do so, as they've been giving me crap about parrot for 10 years. The first (and so far only) responses. "the JVM? the one that's being disabled on everyone's desktop due to security issues?" 16:22
jnthn yeah, jsut did make clean; make test and it's running the test.
[Coke] moritz: note that parrot/ will persist after that.
[Coke] finds git clean -Xdf, which is nice if you have a local TODO file lying about. 16:23
moritz [Coke]: my parrot/ dir is below the rakudo/ dir, not below the nqp/ dir (where I clean now)
but yes, the installation remains in place 16:24
dalek p-jvm-prep: 9b42430 | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/P6OpaqueBaseInstance.java:
Make P6opaque clone actually work.
p-jvm-prep: b56b607 | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/VMArrayInstance.java:
Fix translate-o in unshift.
p-jvm-prep: 8f5a622 | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/P6Opaque.java:
Cope with null attribute type in P6opaque.
moritz still the same error :(
ok, time to nuke parrot and the install dir too 16:25
jnthn moritz: That's really odd. I did change sixmodelobject.h but...stuff rebuilt OK here.
16:26 SunilJoshi joined
moritz jnthn: I might have had a newer-than-recommended parrot 16:26
16:27 hoelzro is now known as hoelzro|away
jnthn [Coke]: heh...'cus building Java applets for the browser is so the main use case for the JVM these days! 16:27
16:29 kst` is now known as kst
nwc10 thought that the main use case was pwnage :-) 16:29
jnthn :P
nwc10 flash is so last year
16:32 brrt left
moritz ok, worked now 16:33
16:34 sftp left
tadzik yep, I can't compile nqp either 16:34
the solution is to degrade parrot?
moritz seems like
16:35 kaleem_ left
kresike bye folks 16:36
16:36 kresike left, sftp joined
jnthn tadzik: I...think downgrade is the word you wanted :P 16:38
tadzik yeah, right ;)
moritz small linguistic details :-)
16:39 PacoAir left
[Coke] tadzik-- 16:39
tadzik uh, I'm downgraded now 16:40
16:43 johnjohn101 left, johnjohn101 joined 16:49 sftp left 16:51 sftp joined
moritz jnthn: how can I catch Perl 6 warnings from NQP land? 16:53
basically I want to avoid inlining stuff that warns, but for that I need to catch warning in Optimizer.pm 16:54
but if I execlude anything that could potentially warn from inlining, there's not much left 16:55
and try { } doesn't catch 'em 16:57
jnthn moritz: Does a CONTROL block work? 16:58
nqp: try { CONTROL { } }
p6eval nqp: ( no output )
jnthn Parses at least.
moritz jnthn: I'll try
jnthn: does it auto-resume the warning at the end? 16:59
jnthn moritz: Don't think so 17:00
moritz good 17:01
dalek p-jvm-prep: 3ef0749 | jnthn++ | nqp-src/nqp-mo.pm:
Missing nqp::elems(...).
p-jvm-prep: 9202f07 | jnthn++ | / (2 files):
Add nqp::rebless, though P6opaque not updated yet.
p-jvm-prep: 9c45812 | jnthn++ | nqp-src/nqp-mo.pm:
Uncomment code in .mixin, now it compiles.
p-jvm-prep: bc07c18 | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/P6Opaque.java:
Basic mixins that just add methods.

Case of adding extra attributes is still to do.
17:02 DarthGandalf left
dalek p: 670bb6f | jnthn++ | src/how/NQPClassHOW.pm:
Keep MOP in sync with JVM port.
17:02
17:05 DarthGandalf joined, benabik left
colomon jnthn++ 17:06
tadzik jnthn: I think you can save an if in github.com/perl6/nqp/blob/670bb6f8...OW.pm#L349 17:07
if nqp::elems(@immediate_parents) == 1 { } elsif nqp::elems(@immediate_parents) {} or so
or maybe not
yeah, that'd only save an indentation level :) nvm 17:08
jnthn hm, could rearrange it to save an indentation level but not much more...
tadzik right
17:08 benabik joined
tadzik for some reason I thought there are 3 ifs there now 17:08
17:13 MayDaniel joined 17:15 DarthGandalf left 17:18 DarthGandalf joined, PacoAir joined 17:19 PacoAir left 17:21 stevan_ left 17:24 cognominal_ left
dalek kudo/nom: 8f39611 | moritz++ | src/Perl6/Optimizer.pm:
Do not inline stuff that warns
17:24
kudo/nom: 6d5dc67 | moritz++ | src/core/ (7 files):
mark more subs and ops as pure
timotimo moritz: have you done any benchmarking yet? 17:25
moritz timotimo: no, just one very artifical one 17:26
timotimo: now it inlines infix:<,> too :-) 17:29
timotimo cool :)
timotimo boots up his VM 17:30
moritz and there are 54 calls in the setting inlined
mostly infix:<,> and prefix:<-> 17:31
17:32 cognominal joined 17:35 domidumont joined 17:37 Chillance joined 17:38 spider-mario joined
tadzik awesome 17:41
timotimo that sounds good :) 17:47
those are used all over the place, i bet!
17:47 FROGGS joined
FROGGS good evening 17:47
17:53 dakkar left, cognominal left
masak hiya peeps and bots. 17:55
I made it safely to Bruxelles.
now to find the pre-conf meetup :) & 17:56
moritz \o masak
17:57 sevin joined
moritz jnthn: how would I check in NQP if something is invokable? 17:57
timotimo moritz: do you think there should be something like stagestats for the optimizer? a flag that makes the optimizer output some stats? 17:58
moritz timotimo: if it doesn't make it slower to any discernible degree, yes
jnthn moritz: In theory, nqp::isinvokable
moritz: In practice, that may not be reliable. 17:59
moritz: However, the invocation protocol changes I'm half way through will let me fix that...
moritz jnthn: I want to be able to pass callbacks to QAST::Want
so my code would be something like if $best !~~ QAST::Node && nqp::isinvokable($best) { $best := $best($node) } 18:00
jnthn moritz: Hm, what a curious idea... :)
moritz: That's the instruction that *should* cut it. Experiment a bit and let me know if it doesn't and I can try fixing it.
moritz jnthn: that way I can easily (I hope) implement warnings for stuff in sink context
jnthn moritz: But hopefully it Just Works. 18:01
moritz the "Useless use of variable in sink context" kind of warning
jnthn Man, that was a serious amount of typing...
moritz but first, I'm off to play table tennis
&
18:02 PacoAir joined
jnthn enjoy o/ 18:02
dalek p-jvm-prep: 2d29fc4 | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/P6Opaque.java:
Extend mixin support to cover attributes.
18:03
p-jvm-prep: 3fdbbd0 | jnthn++ | t/nqp/61-mixin.t:
We now pass 61-mixin.t.
18:05 cognominal joined, cognominal__ joined
timotimo moritz: oh, yeah, prefix:<-> is a strange thing to have calls for :) 18:06
18:07 kivutar left 18:08 SunilJoshi left
TimToady masak: actually, I was grepping my Mandarin dictionary for those 18:12
these days I know a lot more Chinese characters than Japanese, since there *are* a lot more of 'em
I just Japanese is what I know how to speak, and sometimes understand
s/I/it's/ 18:13
18:14 xinming_ joined 18:15 cognominal__ left, cognominal left 18:17 vividsnow joined 18:18 xinming left 18:22 cognominal__ joined 18:24 SmokeMac_ left 18:27 cognominal__ left 18:28 SmokeMachine joined 18:30 cognominal__ joined 18:31 stevan_ joined
cognominal__ la presse française se réjouit d'un accord avec Google. Il se rendent pas compte que Google s'apprête à être un broker de contenu (you tube payant) et que demain il seront peut-être obligé de se vendre via Google 18:35
article content-free : Rémunération des médias : Google et la France signent un accord 18:36
jnthn cognominal__: oui, je deteste la presse :P
cognominal__ oops
jnthn :)
dalek p: fd4f51a | jnthn++ | src/core/Hash.pm:
A slurpy is around a fresh hash, so this is silly.
18:38
cognominal__ jnthn: kudo btw for the recent work, I am waiting to read your next blog entry
jnthn cognominal__: :) 18:39
Yes, plan to post one this evening.
dalek p-jvm-prep: 5621514 | jnthn++ | nqp-src/NQPCORE.setting:
Pull in a few more bits of the NQP setting.
18:43 cognominal__ left, SmokeMac_ joined 18:47 spider-mario left, SmokeMachine left 18:48 cognominal__ joined 18:51 sevin left, johnjohn101 left 18:52 johnjohn101 joined
FROGGS TimToady: might this be the right approach? gist.github.com/c41d6fa169557a17e798 18:55
will try to do that in nqp and rakudo too 18:56
18:56 cognominal__ left 18:57 SmokeMachine joined 18:59 johnjohn101 left 19:00 stevan_ left 19:01 johnjohn101 joined, SmokeMac_ left 19:03 cognominal__ joined 19:05 pat_js left 19:06 johnjohn101 left 19:07 johnjohn101 joined 19:13 cognominal__ left 19:18 quester joined 19:19 cognominal__ joined 19:20 SmokeMachine left 19:21 cognominal__ left, SmokeMachine joined 19:23 SmokeMac_ joined 19:25 japhb_ joined 19:26 benabik_ joined, johnjohn101 left, benabik left, benabik_ is now known as benabik, SmokeMachine left 19:28 johnjohn101 joined
johnjohn101 what is the perl 6 for that is implemented in .net? are there any examples of creating simple guis on windows? 19:29
timotimo niecza 19:30
there's the mandelbrot example in the advent calendar which uses GTK# from perl6
johnjohn101 i'll have to look. gtk# is from mono, right? 19:31
19:31 cognominal joined
timotimo er, i see no reason why you wouldn't be able to use it on mircosoft .net 19:32
johnjohn101 i see the project page. just really need a bunch more hand holding to get started.
[Coke] colomon & sorear are the main niecza folks, but we might be able to help out. 19:33
colomon someone called?
I think I've got niecza running on .NET on one of my Windows boxes. I do usually use Mono for it. 19:34
johnjohn101 wanted to know if niecza was useful for simple guis on a windows 7 / server 2008 box
colomon johnjohn101: it's worked for me on a windows Vista box. don't know why it wouldn't also work on windows 7 19:35
johnjohn101 have have a server that can give me some json info and need to display
how far along is it? meaning how close is it ready for production code?
PerlJam johnjohn101: What's "production code"? :) 19:36
19:36 SmokeMachine joined, johnjohn101 left 19:38 johnjohn101 joined
johnjohn101 perljam: meaning someone else has to use what I write! 19:39
colomon johnjohn101: sorry for disappearing there, got distracted by real life.
johnjohn101: it's worked well enough for me as a simple GUI, though I've certainly not stress-tested it.
19:40 SmokeMac_ left
johnjohn101 just curious. my interest is that i was doing some ironpython ( and some ironruby) and wanted to see if the same functionality was for perl as I have more perl stuff 19:40
timotimo coming from python and ruby, you ought to love the gradual typing. i came from python and it makes me so happy! 19:41
i'm not really "all the way here" yet, though 19:42
colomon johnjohn101: github.com/colomon/TuneReminder is my most complicated script using Gtk#
johnjohn101 i've been doing perl for a while but it's tough to create win32 guis with it exclusively
colomon johnjohn101: github.com/colomon/TuneReminder/bl...ractice.pl is where most (all?) of the GUI action takes place.It's mostly pretty straightforward Gtk# calls, I think. 19:44
19:44 UberFoX joined
UberFoX hello there 19:45
[Coke] Hola, UberFoX.
colomon johnjohn101: it's been a year or more since I wrote it, so I'm a bit fuzzy on the details.
johnjohn101 colomon: i was just reviewing. looks pretty straightforward.
is niecza being actively worked on 19:46
colomon johnjohn101: only very slightly
timotimo colomon: this is for piano?
[Coke] colomon: ReportPraticed
colomon johnjohn101: three or four commits a month.
UberFoX So hows perl6 coming along?
[Coke] Well. You should totally grab the latest Rakudo Star distro and play with it.
PerlJam UberFoX: Quite well I think. I'm mostly happy with it anyway. 19:47
colomon timotimo: mostly I'm tracking my whistle practice there, though the general point is remembering how the tunes go, so I'd count flute and accordion in there as well.
UberFoX I had a slight look at it i never used 6 before though just 5
Almost anything that *works* in 5 doesnt seem to work in 6 lol
PerlJam UberFoX: like what? 19:48
[Coke] six is a new language, so you can't run the same code.
"unchanged", I should add. 19:49
19:49 b1rkh0ff joined
UberFoX It takes a lot of getting used to for sure 19:49
johnjohn101 rakudo perl is the most active perl 6 for now?
PerlJam johnjohn101: yes 19:50
UberFoX Last time i tried Rakudo it was not fun to get working but i tried it today and it had a nice msi file
I have been making my own macro/scripting language for fun i tried to model it similar to a mix of perl/php/autoit 19:51
result are not bad lol
johnjohn101 where is the .msi file? does it run will on win32?
UberFoX Yea it installs and works nicely
gives you perl6 ready to go 19:52
github.com/downloads/rakudo/star/r...012.10.msi
PerlJam That's an older one. 19:53
See rakudo.org/downloads/star/rakudo-st...012.12.msi
UberFoX Well its on top of the page ;/ 19:54
PerlJam Ah ... we need to update the "how to get rakudo" page to no longer point to github.
johnjohn101 or update github! 19:55
19:55 SmokeMachine left, cognominal left 19:56 SmokeMachine joined
UberFoX Whats perls6 standing in comparison to other modern languages of today? (considering perl6 has been indev for so long its hard to believe it will ever be finished) 19:57
19:58 domidumont left
flussence define "finished" 19:58
UberFoX well stable final
19:59 SmokeMac_ joined
UberFoX wether thats 1.0 or 2.0 doesnt really matter 19:59
flussence I guess ruby, python and perl5 aren't finished then, since they have no final release.
PerlJam UberFoX: the concept you're trying to express isn't very clear-cut.
[Coke] johnjohn101: github is no longer providing hosting of builds.
PerlJam UberFoX: Perl 6 is usable today. but it's not usable for some things that you would want. 20:00
20:00 fgomez left, eiro left
johnjohn101 i would like to see odbc added but that's me 20:00
UberFoX So its just lacking a large library and more optimized./complete core?
johnjohn101 perl dbi is what I live on
20:01 eiro joined, not_gerd joined, SmokeMachine left
flussence once nqp-jvm is ready, you can use Java's ODBC equivalent. 20:02
20:02 johnjohn101 left
timotimo some parts of the specification are still not 100% fleshed out. i belieie there's not terribly much on threading yet? 20:02
flussence oh yeah, threading sucks
timotimo wow, what cool new word did i just make up? belieie? that's kind of cute
not_gerd jnthn: github.com/perl6/nqp/issues/74
20:02 johnjohn101 joined
not_gerd re Perl6 taking a long time: Rakudo got started in 2005, Rust in 2006 20:03
flussence (I'm optimistic that jnthn++'s current side project is going to be some sort of magic bullet for these in the long run)
not_gerd some things just take time to get right
20:03 Patterner left
timotimo flussence: the performance increase we probably will get almost for free will be worth a lot by itself, i think 20:04
20:04 Psyche^ joined, Psyche^ is now known as Patterner
not_gerd the difference between Rust and Perl6 is just perception: Perl6 got announced in 2000 (before design had even started), wheread Rust got announced after years of work in 2010 20:04
UberFoX is it possible to use the new perl6 self modification stuff to allow arrays and hashes to be combined into the $ like php?
(or will it be)
timotimo "into the $"?
flussence ?
rn: my $array = 1..3; say $array.perl; $array = { a => 1 }; say $array.WHAT 20:05
UberFoX for example in PHP the $variable is the array and the string , int etc
p6eval rakudo 6d5dc6, niecza v24-18-gaf64300: OUTPUT«1..3␤Hash()␤»
PerlJam UberFoX: Perl 6 has Parcels which may have an array component and may have a hash component.
20:05 johnjohn101 left
UberFoX oh thats nice 20:05
20:06 SmokeMachine joined
PerlJam UberFoX: you can also store your arrays and hashes inside of scalars so that you rarely (never?) have to see a @ or % if you don't want to. 20:08
20:08 cognominal joined
flussence r: sub htmlspecialchars(Str $s) { $s.trans(qw[< > & "] => qw[&lt; &gt; &amp; &quot;]) }; sub prefix:<=>(Str $s) { htmlspecialchars($s) }; say ='<a href="#">'; 20:08
p6eval rakudo 6d5dc6: OUTPUT«&lt;a href=&quot;#&quot;&gt;␤»
20:09 SmokeMac_ left
PerlJam UberFoX: you should check out the Perl 6 code on rosettacode. rosettacode.org/wiki/Category:Perl_6 20:10
jnthn not_gerd: Only on latest Parrot?
not_gerd: Works on the recommended one?
flussence r: sub prefix:<=>(Str $s) { $s.trans(qw[< > & "] => qw[&lt; &gt; &amp; &quot;]) }; my $shady-uri = '"\'&1=1--'; say qq[<a href="{=$shady_uri}">]; 20:11
p6eval rakudo 6d5dc6: OUTPUT«===SORRY!===␤Variable '$shady_uri' is not declared. Did you mean '$shady-uri'?␤at /tmp/9pSnC2Ep9L:1␤------> "\'&1=1--'; say qq[<a href="{=$shady_uri⏏}">];␤ expecting any of:␤ postfix␤»
flussence r: sub prefix:<=>(Str $s) { $s.trans(qw[< > & "] => qw[&lt; &gt; &amp; &quot;]) }; my $shady-uri = '"\'&1=1--'; say qq[<a href="{=$shady-uri}">]; # why yes, yes I did mean that...
p6eval rakudo 6d5dc6: OUTPUT«<a href="&quot;'&amp;1=1--">␤»
not_gerd jnthn: it's the same error moritz reported, so apparently yes
jnthn Hm. Oddness. OK. 20:12
20:12 SmokeMachine left
jnthn Maybe I can reproduce it. 20:12
20:12 SmokeMachine joined 20:13 eiro left 20:14 eiro joined 20:15 fgomez joined
UberFoX I have been making a simple programming language while waiting for perl6 to be ready uberfox.no-ip.org/Sputnik/wiki/index.php its pretty much just for simple win32 scripting but i tried to add a lot of stuff from perl to make it feel homely lol its windows only however what i want to do make all this stuff in perl6 (i dont see point doing it in 5...... havent done anything in 5 for a long long time) 20:15
20:16 SmokeMachine left
dalek p: ed7e829 | jnthn++ | src/pmc/stable.pmc:
A couple of missing bits of marking.
20:22
jnthn not_gerd: maybe that helps 20:24
20:28 raiph left
not_gerd jnthn: testing 20:30
[Coke] UberFoX: when you say you want to "make all this stuff in perl6" do you mean that "things you build on sputnik, you'd like to build on perl6 instead" or "it would be nice if these features from sputnik were available in perl6" or something else? 20:31
UberFoX I want to be able to do all that in perl6 yes 20:32
right now it seems a bit too limiting?
[Coke] I think all the p6's currently provide the features you document in the language reference, though they might be spelled differently.
I don't see anything you're doing there that isn't already doable for some time in perl6, no. 20:33
UberFoX really?
:O
20:33 spider-mario joined
[Coke] sure. I'm looking at uberfox.no-ip.org/Sputnik/wiki/inde...Reference, btw. 20:33
UberFoX erm thats just ref
thats not important
uberfox.no-ip.org/Sputnik/wiki/ind..._Reference
thats the important one
[Coke] ok. I can only work with what you give me. 20:34
not_gerd jnthn: didn't help
(tries again with a clean checkout just to be sure)
UberFoX language reference is just like Operators etc
perl has all that stuff :)
perl6 even lets you make ur own operators 20:35
which is pretty awesome
PerlJam UberFoX: youre type checking is weird.
UberFoX wel theres 2 ways to typecheck
not_gerd jnthn: could you reproduce the problem?
UberFoX $a is Int IsVarInt( $a ) or well $a ~~ int 20:36
not_gerd jnthn: I'm building with cygwin, ie a 32bit architecture
PerlJam UberFoX: that middle one seems problematic. Makes me think of the myriad ways PHP has to do things.
UberFoX well that one doesnt really check the variables type 20:37
PerlJam UberFoX: better to have a few good primitives that you can combine and use in various ways.
UberFoX it just checks what the variable equates to
$a = "100"; will work TRUE on isvarint 20:38
because it can be...
PerlJam UberFoX: in any case ... Perl 6 can do most of this stuff too looks like.
not_gerd jnthn: the problem didn't go away after a git clean
[Coke] pretty sure there are analogues for nearly everything except: GUI items (those aren't core, but you can get at the windows stuff from either rakudo or niecza, I believe.), and the types. (rakudo's support of the spec'd native types is not complete)
(oh, and the db connectivity) 20:39
UberFoX I make a lot of macros/scripts/trainers i used to do that in perl5 but ended up making my own to do it but would like to have all this stuff in perl6 since overall it is a more solid professional language
my stuff is just dabbling ;p
[Coke] though that's probably doable via nativecall today.
UberFoX im not an expert ;/
PerlJam UberFoX: btw, good job making your own language. I think every CS-oriented person should create their own language and compiler at least once :)
UberFoX Yea
i gave it my best shot lol
is it possible to call win APIS in current perl6? 20:41
i cant seem to locate such a function ;/
PerlJam you can use NAtiveCall 20:42
UberFoX that a module?
arnsholt Windows APIs aren't part of the core language (since it's supposed to be platform agnostic), but you might be able to call the C APIs using Zavolaj
UberFoX calling APIs is pretty important for kind of scripting i do 20:43
(dlls)
arnsholt NativeCall/Zavolaj lets you do that
UberFoX github.com/jnthn/zavolaj/? 20:44
is there a binary download?
arnsholt It's a bit limited in some aspects ATM, but some serious improvements should land in the next week I think
Yeah, that's the one
timotimo next week? oh yeah! :)
arnsholt No binary, but it comes with Rakudo star I think
UberFoX i use windows for the moment (unless windows 9 is same as windows 8 then im gonna need to find something else) 20:45
timotimo something is stopping me from going on with the iperl6kernel work. i don't know what yet :|
arnsholt timotimo: That's no fun. What's the problem? 20:47
UberFoX Know of any great from Perl5 to Perl6 guides? i got this one perlgeek.de/en/article/5-to-6 but its only so-so 20:48
timotimo arnsholt: i don't know how the pieces are supposed to go together - the connection between the perl6 kernel part, the nqp REPL replacement and the python zmq wrapper
jnthn not_gerd: No, didn't manage to... Will look a bit deeper.
UberFoX many things that guide shows actually dont even work in perl6 20:49
so its a bit....erm ;p
arnsholt timotimo: Right, right. Architecture is always hard
timotimo the current code reads length + json-as-string from one IO object and writes length + json-as-string to another IO object and those IO objects are currently cargo-culted from the nqp part
PerlJam UberFoX: which ones don't work?
UberFoX like the garmmar one 20:50
if you copy and paste it it will spit off xxx errors but not run
i was trying to make a parser in perl6 that operators similar to: uberfox.no-ip.org/Sputnik/wiki/ind...ser_Engine 20:51
but the ones in guide arent working well ;/
"Regexes (also called "rules")"
thats the one
PerlJam UberFoX: "A grammar for (pseudo) XML" ?
oh
UberFoX yea
no
not the xml one
the xml one works fine
Regexes (also called "rules")
PerlJam yeah, I got it. :)
arnsholt timotimo: If you want to, you could start a Gist or repo or something, and I could see if I have any suggestions 20:52
timotimo there is a repo. i'm not sure if the latest code is on there yet, though 20:53
[Coke] UberFoX: remove the {} wrapping the 1..3
no doubt a spec change that occurred sometime in the last 4 years.
timotimo yeah, it is. see this repo: github.com/timo/iperl6kernel
UberFoX lol
[Coke] perlgeek is ... moritz? masak?
arnsholt moritz
FROGGS right
PerlJam [Coke]: though I still have it in my head that a block returning a range should work there.
[Coke] phenny: tell moritz to change **{1..3} to **1..3 in this code: perlgeek.de/en/article/5-to-6#post_07 20:54
phenny [Coke]: I'll pass that on when moritz is around.
UberFoX can this parse a document and create classes so i can easily go through them?
or is it just a regex tokenizer?
PerlJam [Coke]: S05:1019 looks like it should work, but doesn't yet (possibly a regression) 20:55
[Coke] UberFoX: .parse() takes an optional "actions" parameter that lets you act on those various rules when they hit, yes. 20:56
arnsholt UberFoX: You can connect actions to the rules, and use those to build up an AST
UberFoX I see so how would i go about doing something like this: pastebin.com/Jf8m4aTC
in perl6 20:57
PerlJam UberFoX: use.perl.org/use.perl.org/_pmichaud...38580.html
:-)
UberFoX cool :) 20:58
20:58 fgomez left
PerlJam It sometimes boggles my mind how much functionality we had back in 2009 20:59
UberFoX i havent really heard anything about perl6 until a few days i thought it was dead years ago O_o
timotimo pmichaud: not sure if it has been around back then, but you could totally rewrite '-' => { my $s = .pop; .push(.pop - $s) }, in that RPN using R- :)) 21:00
same for the / operator
UberFoX because activeperl etc is all 5.xx
PerlJam timotimo: see the bottom of that post
timotimo oh, yes, it already says so in there
i feel dumb now.
21:00 rindolf joined
UberFoX the RPN sample is interesting 21:01
shows perl doesnt need vast amounts of code to do this stuff 21:02
[Coke] r: gist.github.com/4694121 21:03
p6eval rakudo 6d5dc6: OUTPUT«GOT NUMBER: 123␤GOT NUMBER: 456␤GOT NUMBER: 789␤»
PerlJam UberFoX: the key thing to remember is that Perl 5 and Perl 6 are different languages. They share some heritage, but they are radically different.
[Coke] there's a basic example of how to plugin an action.
timotimo when did perl ever need vast amounts of code to do anything? i thought that was the essence of even the *bad* reputation perl has :)
UberFoX hehe
back in the day i made a lot of huge projects in perl5 21:04
its a shame php took the web though 21:05
21:05 benabik left
UberFoX php is a mess 21:05
[Coke] UberFoX: check out that gist for an example of actions.
UberFoX Yes im collecting samples to study 21:06
PerlJam UberFoX: modules.perl6.org/ might also be some good code to read.
UberFoX i will be happy once i get apis, parser etc etc working fine 21:08
hehe some acme modules
PerlJam UberFoX: github.com/moritz/json/ is another relatively small, yet complete example of using grammars + actions
timotimo moritz: i want to suggest you replace say "One lonely sheep"; with say "One lonely shoop";
r: loop (my $x = 1; $x < 100; $x = $x**2) { say $x; } 21:09
p6eval rakudo 6d5dc6: OUTPUT«(timeout)1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤1␤
timotimo this doesn't work as shown in that 5to6 document
... what are those "���" in the middle?
jnthn I'm pretty sure 1 to the power 2 is always 1 :) 21:10
UberFoX when you use int $a = 100 does it actually become a proper int and run faster in loops?
or does it make no difference in speed?
timotimo er, yeah
UberFoX one issue with php is it uses strings for everything
damn slow
timotimo classes are just strings! 21:11
UberFoX O_O
timotimo yeah, the string begins with class $name { and ends with }
spider-mario Tcl likes strings too
jnthn UberFoX: It tends to generate better code thanks to that, BUT there are some holes in the implementation of the natives.
spider-mario they’re even nested
timotimo instantiating the class should really just be evaling that string!
21:12 fgomez joined
jnthn UberFoX: We use them in various of the built-ins and in the compiler to optimize some things. 21:12
spider-mario I have used Tcl, a little
PerlJam UberFoX: Rakudo is still fairly slow compared with other language implementations, but it is getting optimized over time.
spider-mario the use of strings everywhere means that syntax errors other than non-balanced {} are not detected until runtime 21:13
à la bash
and it is so slow…
21:14 rindolf left
UberFoX I saw a video on youtube where one of the Rakudo devs said it took like 37 seconds to do this loop but they fixed it to 0.2 second :) 21:15
timotimo yeah, that was pmichaud and that talk was great :)
UberFoX From everything ive seen they say Rakudo is the perl6 and the other ones are just nowhere near as good 21:16
timotimo niecza is faster and still closer to STD, but rakudo has more features
UberFoX which one does larry support as perl6?
PerlJam UberFoX: all of them!
timotimo both
UberFoX :O
timotimo well, all three, no?
jnthn UberFoX: Perl 6 is a language spec + suite of tests. That it's open to more than one implementation is intentional. 21:17
UberFoX it seems a bit odd to have many perls but yet look at C++ and how many there are
PerlJam UberFoX: aye, Perl 5 is the unique one in that it has essentially one implementation. 21:18
Most other languages have a spec (even if informal) and possibly multiple implementations.
UberFoX ive seen perl5 source its crazy lol
jnthn UberFoX: I don't promise Rakudo source isn't crazy, but it is at least largely written in Perl 6 or a subset of it :) 21:19
UberFoX as long as its not endless spaghetti code like perl5 ;/
arnsholt timotimo: I think your general plan is a good one. Figure out how to hijack the REPL from jnthn++'s debugger, and get that to talk to a python shim that talks to the ipython/rakudo kernel 21:20
timotimo arnsholt: thanks. i'm pretty satisfied with that part as well 21:23
one thing that trips me up *so* much is input/output redirection
when something asks to read from stdin, say prompt() or $*IN.get or anything, the shim has to broadcast a request and some kernel has to answer with an input. how do i do that properly?
and when something outputs to stdout some different way from $*OUT.write, like maybe q:x{echo "hello perl!"}, i have to pick that up as well, but then the executed code has a way to just mumble right into the middle of my protocol 21:24
[Coke] partcl: puts {Tcl still work here?}
arnsholt Yeah, it's a bit complex
But we can probably hack around most of it 21:25
21:25 cognominal left
arnsholt Like replacing $*IN with a magical filehandle that captures input 21:25
jnthn Yes, if you can replace $*IN and $*OUT with such you should be able to make it work 21:26
masak is back from pre-conf meetup 21:27
turns out FOSDEM is so huge that the number of people at the pre-conf meetup along means that you cannot hear yourself think :) 21:28
(but it was really nice to meet liz/wendy, eiro, and sjn already tonight)
21:30 domidumont joined
masak UberFoX: hi. welcome. 21:30
timotimo jnthn: but how does it cooperate with things like executing shell commands that would inherit stdout or stdin?
jnthn timotimo: Probably not entirely well..hmm. 21:31
masak UberFoX: Perl 6 and its implementations are less limiting than you seem to think -- at least that's my many-year impression of them. but what's lacking is *polish*, so you're bound to sometimes run into errors or cases where there's no easy solution. 21:32
UberFoX: people here are very good at helping and improving things, though.
colomon well said, masak
timotimo jnthn: actually, there could be a way to do that. 21:33
jnthn: after an eval command, the shim would listen to stdout and just gobble up everything and when some special marker comes, it'd ask the perl6 code "did that just come from you?" 21:34
"if so, repeat "foo bar baz" to me, please"
oh, but what if i q:x{cat}
dangit :|
i think i'll need to mkfifo and do communication that way 21:35
masak colomon: short history of Perl 6: 2008 -- this is very unstable, but at least it runs. 2010 -- this is quite buggy, but at least it doesn't crash. 2012 -- this is still fairly slow, but at least it's stable and featureful. to be continued.
(that's mostly Rakudo, by the way)
timotimo mid 2013 -- why didn't we think of going to the jvm before?! 21:38
swarley I've decided to force myself to learn perl 6 regular expressions better. 21:39
PerlJam swarley: good deal! Maybe you could blog about your experiences?
swarley By writing a parser for them in ruby, using syn/S05 21:40
masak swarley: I once did this. it's a great learning experience.
swarley: maybe you should look into borrowing an existing test suite?
swarley: like, nqp's?
swarley I am actually
masak \o/
swarley I'm looking at QRegex/P6Regex/Grammar.pm right now
PerlJam next thing you know, we'll accidentally obtain a ruby backend for NQP ;) 21:41
not_gerd timotimo: www.ebb.org/bkuhn/articles/thesis/
swarley This line looks scary to implement
not_gerd " It is hoped that the Perl6 effort (which seeks to reimplement perl from the ground up) can make use of the lesson learned here, so that future versions of perl will ease the burden of porting to architectures like the JVM. "
swarley or duplicate
:my $OLDRX := nqp::getlexdyn('%*RX');
masak swarley: well, sometimes you have to take a step back and look at the intent. 21:42
timotimo not_gerd: wow, this was 2001?
masak swarley: at bottom, everything is Turing machines.
swarley: or, alternatively, lambda expressions. 21:43
21:43 domidumont left
swarley Also 21:43
I'm assuming <quote_EXPR: ':q'> and <quote_EXPR: ':qq'> are just mappings to '' and "" strings?
| <?[']> <quote_EXPR: ':q'> 21:44
| <?["]> <quote_EXPR: ':qq'>
Because I keep coming across things like that
In many different examples
jnthn Yes.
sorear ...everything is interacting quantized fields?
masak sorear: huh? come again? 21:45
lue Is it rakudo or panda that creates the ~/.perl6/<version> directory?
skids Everything's a tree. Until you get sick of going up/down 8 branches of traversal just to get to that acorn right next to you. 21:46
swarley ^ Now that I agree with 21:47
PerlJam lue: panda
masak sorear: oh, it was a physics comment.
sorear: I was still thinking about grammars ;)
timotimo skids: is that the reason why they came up with the World comcept in perl6? 21:48
masak timotimo: no.
masak <-- proud inventor of the name "World" :)
timotimo: basically, grammars are for syntax; actions are for code that *executes* stuff; World is for code that *declares* stuff. 21:49
timotimo: the distinction between the latter two became apparent the more Rakudo evolved.
timotimo mhm, right. that does make sense 21:50
where do acorns fit in, though?
masak I guess they were a poetic metaphor for .ast values. 21:51
timotimo ok :)
skids Because squirrels are smarter than programmers when it comes to getting around trees. :-)
swarley Editors should have method hyperlinks built in :( 21:52
masak they do, nowadays. 21:53
swarley would make understanding source code a hell of a lot easier
I've yet to use one that does
Well
I just dont have the right vim plugin i suppose
but then again it is harder for scripted languages.. 21:54
masak well, Perl 6 has enough proper OO in it for it to be at least possible much of the time. 21:55
timotimo right, i was musing about writing something that outputs the ctags format, because there's ctags readers for almost all editors out there 21:59
i wonder if ctags would have trouble with perl6 identifiers that have - in them
vim omni completion totally does, it stops after every -
but i like using - in names so much :(
masak betcha there's an override somewhere. 22:00
timotimo even if it's a bit in the binary that i'd have to flip with a hex editor :D
22:00 atrodo left 22:02 quester left 22:03 skids left
timotimo with a somewhat more intelligent format and typed variables, one could even disambiguate methods from different classes, but that's 10x more advanced than i care to consider on a boring sunday afternoon :) 22:04
this kind of thing might be what one would want to put into padre, though
is there a big difference between method foo { ... } and proto method foo { * }? 22:07
masak yes. next question!
:P
timotimo oh you ;) 22:09
so, what is that big difference? also, is the $object.method: $foo, $bar syntax meant to mirror the way you define your own name for the invocant, or if not, what's it for? 22:10
er, not "what's it for"; "why does it look like that?"
and maybe the answer to that question will also explain why i can't just sub: 1, 2, 3. 22:11
masak timotimo: to the latter unquestion, because it only works for method syntax.
timotimo moritz: q{The my SomeClass $x .= new is actually a shorthand for my SomeClass $x .= SomeClass.new} - that seems like the second .= should be = instead 22:12
22:12 vividsnow left
masak what's it for: it's so that you don't have to surround a big set of method parameters with parentheses. 22:12
or sometimes to make method calls look a little "lighter".
timotimo okay. why only method calls, though?
masak because subs already have the listop syntax. 22:13
don't need a colon.
timotimo oh, that was kind of obvious. thanks!
masak r: class Greeter { method greet($person) { say "Why hello, $person!" } }; given Greeter.new { .greet: "timotimo" }
p6eval rakudo 6d5dc6: OUTPUT«Why hello, timotimo!␤»
timotimo the next question then is, what's the reason to not let method calls have listop syntax without a :, too? :) 22:14
masak good question. 22:17
because you can't have two terms in a row. that's fundamental to Perl 6 parsing.
though when I say it like that, it doesn't feel like a sufficient explanation. 22:18
why *do* we have listop subs but not listop methods?
timotimo yeah, it sounded a little bit circular in a way
masak yeah.
I think it's because we like $obj.foo to mean $obj.foo() 22:19
sorear $obj.attr += 1
masak but with 'foo 1, 2, 3' we like it to mean 'foo(1, 2, 3)'.
sorear $o1.attr + $o2.attr
masak sorear: yeah, good one.
good two :)
they are terms on their own, moreso than subs are.
but even with subs, people fall into gobbling-related traps sometimes :) 22:20
the 'for lines {' one is a classic.
std: for lines { .say }
p6eval std 7deb9d7: OUTPUT«===SORRY!===␤Function 'lines' needs parens to avoid gobbling block at /tmp/BLa5p86n6r line 1:␤------> for lines⏏ { .say }␤Missing block (apparently gobbled by 'lines') at /tmp/BLa5p86n6r line 1:␤------> for lines { .say }[33…
sorear at least $o.attr = 2 isn't ambiguous anymore :D
22:21 bbkr_ joined
masak yeah, good riddance with the prefix:<=> :P 22:21
timotimo oh, mhm
bbkr_ how can I force { 'a' => $_} to be interpreted as hash after 2012.12 changes? old P5 trick +{ 􏿽x85 } does not work
timotimo (...).hash? 22:22
jnthn Maybe consider using hash('a' => $_) instead
masak bbkr_: prefix:<+> means 'numify' in Perl 6. it doesn't mean 'no-op' as in Perl 5. 22:25
bbkr_ my previous syntax was @documents.push( { 'foo' => $_ } ) , when I change it to @documents.push( hash( 'foo' => $_ ) ) all pairs are flatten so I get array of pairs but I need array of hashes
flattened* 22:26
r: my @t; @t.push( hash("a"=>$_) ) for ^4; @t.perl.say 22:28
p6eval rakudo 6d5dc6: OUTPUT«Array.new("a" => 0, "a" => 1, "a" => 2, "a" => 3)␤»
bbkr_ r: my @t; @t.push( {hash("a"=>$_)} ) for ^4; @t.perl.say 22:29
p6eval rakudo 6d5dc6: OUTPUT«Array.new(Block.new(), Block.new(), Block.new(), Block.new())␤»
bbkr_ r: my @t; @t.push( %("a"=>$_) ) for ^4; @t.perl.say 22:30
p6eval rakudo 6d5dc6: OUTPUT«Array.new("a" => 0, "a" => 1, "a" => 2, "a" => 3)␤»
jnthn r: my @t; @t.push( $(hash("a"=>$_)) ) for ^4; @t.perl.say
p6eval rakudo 6d5dc6: OUTPUT«Array.new({"a" => 0}, {"a" => 1}, {"a" => 2}, {"a" => 3})␤»
jnthn That's not attractive but works... 22:31
bbkr_ \o/ thanks!
bbkr_ is back to fixing MongoDB driver
jnthn Feels there should be a slightly better way but I don't immediately see it.
The change was to fix the longstanding map { $_ => 0 }, @x style thing
masak I also got the feeling that there should be a slightly better way :) 22:33
r: my @t; @t.push( {{"a"=>$_}} ) for ^4; @t.perl.say 22:34
p6eval rakudo 6d5dc6: OUTPUT«Array.new(Block.new(), Block.new(), Block.new(), Block.new())␤»
masak yes. 'course.
'night, #perl6
jnthn 'night, masak 22:35
diakopter o/
22:36 Liz joined 22:37 Liz is now known as lizmat
not_gerd r: my @t; @t.push( (a => $_).hash.item ) for ^4; @t.perl.say 22:42
p6eval rakudo 6d5dc6: OUTPUT«Array.new({"a" => 0}, {"a" => 1}, {"a" => 2}, {"a" => 3})␤»
lizmat wonders whether masak made it back to the hotel ok 22:43
22:43 lue left
not_gerd bye, #perl6 22:46
22:46 not_gerd left
jnthn lizmat: Yes, he was here just before you arrived. 22:46
lizmat okidoki, good to hear. Beer Night at FOSDEM has taken its toll with me, so sleep & for me 22:47
22:50 MayDaniel left 22:51 lizmat left 22:57 nnunley left 23:07 spider-mario left 23:12 lue joined 23:24 kaare_ left 23:31 skids joined 23:40 gfldex left 23:41 gfldex joined 23:50 proller joined, proller_ joined, benabik joined
jnthn blaught: 6guts.wordpress.com/2013/02/02/a-lo...ss-update/ 23:51
23:51 proller_ left
jnthn er, ^has :) 23:51