»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg camelia perl6: ... | irclog: irc.perl6.org | UTF-8 is our friend! Set by sorear on 25 June 2013. |
|||
TimToady | r: say 1 + + | 00:00 | |
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/qlPxFjHzNiTwo terms in a rowat /tmp/qlPxFjHzNi:1------> say 1 + +⏏<EOL> expecting any of: postfix infix stopper infix or meta-infix prefix or ter…» | ||
TimToady | I guess it figures if there's a prefix, there must be a term there that it can't see :) | ||
r: say 1 + | |||
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/9fEbUlQIUZTwo terms in a rowat /tmp/9fEbUlQIUZ:1------> say 1 +⏏<EOL> expecting any of: postfix infix stopper infix or meta-infix» | ||
TimToady | doesn't even need the prefix | ||
TimToady seems to recall this was recently rakudobugged already | 00:01 | ||
00:12
Psyche^_ joined
00:16
Psyche^ left
00:21
ajr_ left
00:26
raiph left,
raiph joined
|
|||
japhb__ | r: class X::Attribute::Required is Exception { has $.attribute; has $.class; method message() { "{$.class.^name} requires a value for attribute '{$.attribute.name.substr(2)}'" } }; multi trait_mod:<is>(Attribute:D $a, :$required!) { $a.set_build(method (|) { die X::Attribute::Required.new(:attribute($a), :class(self)) }) }; class Foo { has $.foo is required; }; Foo.new() | 00:49 | |
camelia | rakudo 61580f: OUTPUT«Foo requires a value for attribute 'foo' in method <anon> at /tmp/nrsmeFCfpn:1 in block at src/gen/CORE.setting:871 in method BUILDALL at src/gen/CORE.setting:826 in method bless at src/gen/CORE.setting:815 in method new at src/gen/CORE.setting:800 …» | ||
TimToady | nr: $_ = 'cooper'; $_ [R~]= 'mini'; .say | 00:50 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«minicooper» | ||
..rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/siLWaxuTN_Preceding context expects a term, but found infix = insteadat /tmp/siLWaxuTN_:1------> $_ = 'cooper'; $_ [R~]=⏏ 'mini'; .say» | |||
TimToady | rakudobug | ||
japhb__ | TimToady: Were you serious about wanting a trait name other than 'is required', or would that be good enough for now? | ||
TimToady | I would make a trait that long if I wanted to discourage its use :) | ||
japhb__ | I think the only serious suggestion people had that was shorter was 'is needed' | 00:51 | |
Of course, our collective lack of imagination doesn't mean there isn't a better word out ther. | 00:52 | ||
*there | |||
r: class X::Attribute::Needed is Exception { has $.attribute; has $.class; method message() { "{$.class.^name} needs a value for attribute '{$.attribute.name.substr(2)}'" } }; multi trait_mod:<is>(Attribute:D $a, :$needed!) { $a.set_build(method (|) { die X::Attribute::Needed.new(:attribute($a), :class(self)) }) }; class Foo { has $.foo is needed; }; Foo.new() | 00:53 | ||
camelia | rakudo 61580f: OUTPUT«Foo needs a value for attribute 'foo' in method <anon> at /tmp/do0tff_7YN:1 in block at src/gen/CORE.setting:871 in method BUILDALL at src/gen/CORE.setting:826 in method bless at src/gen/CORE.setting:815 in method new at src/gen/CORE.setting:800 in…» | ||
japhb__ | Shortens the error message, even ... | ||
Although perhaps X::Attribute::Value::Needed, hmmm | 00:54 | ||
'is needed' feels so ... wimpy? | 00:55 | ||
But it is accurate. | |||
diakopter | is want | ||
is DOIT | |||
japhb__ | my $chocolate is want; | 00:56 | |
is used | |||
is undefaulted # Uh ... no. | 00:57 | ||
diakopter | is lack; | ||
japhb__ | It's too bad we can't just say 'has $.foo!' | 00:59 | |
Because really, that has consistency with params quite nicely. | |||
BenGoldberg | r: my $foo!; | 01:00 | |
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/7fOC0Wq13_Negation metaoperator not followed by valid infixat /tmp/7fOC0Wq13_:1------> my $foo!⏏; expecting any of: scoped declarator constraint postfix…» | ||
japhb__ | TimToady: Actually, why didn't you want 'has $.foo!' ? | 01:01 | |
Too confusing in the 'has $!foo!' case? | |||
Because that seems not a terribly strong issue, since new() wouldn't expose that attribute. | |||
*default new() | 01:02 | ||
diakopter | or instead of has... | 01:03 | |
needs | |||
that's kinda cutesy | 01:04 | ||
requires? | 01:05 | ||
demands? | |||
lacks? | |||
hasnt? | |||
that's it. | |||
hasn't Int $!foo; | 01:06 | ||
japhb__ | .oO( Oh, it hasn't, hasn't it? ) |
01:07 | |
geekosaur | "hasn't" sounds like a candidate for perl6tercal | 01:12 | |
TimToady | nr: .oO(rename 'Perl 6', 'OUTERCAL') | 01:19 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«===SORRY!===Undeclared routine: 'rename' used at line 1Unhandled exception: Check failed at /home/p6eval/niecza/boot/lib/CORE.setting line 1502 (die @ 5)  at /home/p6eval/niecza/src/STD.pm6 line 1147 (P6.comp_unit @ 36)  a…» | ||
..rakudo 61580f: OUTPUT«rename is disallowed in restricted setting in sub restricted at src/RESTRICTED.setting:2 in sub rename at src/RESTRICTED.setting:12 in block at /tmp/JkOENPpZWu:1» | |||
diakopter | INTRACAL | ||
TimToady | EXTERCAL | 01:20 | |
INTERSTANFORD | |||
diakopter | EXTRACAL | ||
japhb__ | CALSTANFORD | ||
TimToady | nr: $_ = 'fortnight'; s[^] = 'micro'; .say; | 01:21 | |
japhb__ | Comes with a free axe head | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
..rakudo 61580f: OUTPUT«microfortnight» | |||
TimToady | nieczabug | ||
nr: $_ = 'fortnight'; s/^/micro/; .say; | 01:22 | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
..rakudo 61580f: OUTPUT«microfortnight» | |||
TimToady | interesting | ||
diakopter | n: $_ = 'fortnight'; s[^] .= 'micro'(); .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«Potential difficulties: Useless use of quotes at /tmp/ngAksri_b6 line 1:------> $_ = 'fortnight'; s[^] .= 'micro'⏏(); .say;fortnight» | ||
TimToady | hah | 01:23 | |
diakopter | n: $_ = 'fortnight'; $_ = s[^] = 'micro'; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«False» | ||
TimToady | n: $_ = 'fortnight'; $_ ~~ s[^] = 'micro'; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
diakopter | n: $_ = 'fortnight'; $_ = s[^] = '$0micro'; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«False» | ||
diakopter | n: $_ = 'fortnight'; s[^] = '$0micro'; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
TimToady | n: $_ = 'fortnight'; .=subst(/^/,'micro'); .say; | 01:24 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
TimToady | r: $_ = 'fortnight'; .=subst(/^/,'micro'); .say; | ||
camelia | rakudo 61580f: OUTPUT«microfortnight» | ||
diakopter | n: $_ = 'fortnight'; s/^/micro/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
TimToady | r: $_ = 'fortnight'; .=subst(/^..../,'micro'); .say; | ||
diakopter | n: $_ = 'fortnight'; $_ =~ s/^/micro/; .say; | ||
camelia | rakudo 61580f: OUTPUT«micronight» | ||
niecza v24-95-ga6d4c5f: OUTPUT«===SORRY!===Unsupported use of =~ to do pattern matching; in Perl 6 please use ~~ at /tmp/A0VDhzM5Hz line 1:------> $_ = 'fortnight'; $_ =~⏏ s/^/micro/; .say;Parse failed» | |||
diakopter | *facepalm* | ||
TimToady | it just fails on 0 width | ||
diakopter | n: $_ = 'fortnight'; $_ +~ s/^/micro/; .say; | 01:25 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«Unhandled exception: Cannot parse number: fortnight at /home/p6eval/niecza/lib/CORE.setting line 1536 (die @ 5)  at /home/p6eval/niecza/lib/CORE.setting line 3745 (ANON @ 10)  at /home/p6eval/niecza/lib/CORE.setting line 3747 (NumSyntax.str2num @…» | ||
TimToady | must be testing the width as success | ||
diakopter | n: $_ = 'fortnight'; $_ ~~ s/^/micro/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
diakopter | n: $_ = 'fortnight'; $_ ~~ s/^.*/micro/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«micro» | ||
diakopter | n: $_ = 'fortnight'; $_ ~~ s/^(.*)/$0micro/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnightmicro» | ||
TimToady | r: $_ = 'fortnight'; .=subst(/^<?before ....>/,'micro'); .say; | ||
camelia | rakudo 61580f: OUTPUT«microfortnight» | ||
TimToady | duh | ||
diakopter | n: $_ = 'fortnight'; $_ ~~ s/^(.*)/micro$0/; .say; | 01:26 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«microfortnight» | ||
TimToady | n: $_ = 'fortnight'; .=subst(/^<?before ....>/,'micro'); .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«fortnight» | ||
diakopter | n: $_ = 'fortnight'; $_ ~~ s/^./micro$0/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«Use of uninitialized value in string context at /home/p6eval/niecza/lib/CORE.setting line 1389 (warn @ 5)  at /home/p6eval/niecza/lib/CORE.setting line 269 (Mu.Str @ 15)  at <unknown> line 0 (ExitRunloop @ 0)  at /tmp/IC8Hi0hxZ9 line 0 (ANON @ …» | ||
diakopter | n: $_ = 'fortnight'; s/^./micro$0/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«Use of uninitialized value in string context at /home/p6eval/niecza/lib/CORE.setting line 1389 (warn @ 5)  at /home/p6eval/niecza/lib/CORE.setting line 269 (Mu.Str @ 15)  at <unknown> line 0 (ExitRunloop @ 0)  at /tmp/3yeiSuMQp8 line 0 (ANON @ …» | ||
diakopter | n: $_ = 'fortnight'; s/^.*/micro$0/; .say; | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«Use of uninitialized value in string context at /home/p6eval/niecza/lib/CORE.setting line 1389 (warn @ 5)  at /home/p6eval/niecza/lib/CORE.setting line 269 (Mu.Str @ 15)  at <unknown> line 0 (ExitRunloop @ 0)  at /tmp/v_GYeqkiLz line 0 (ANON @ …» | ||
diakopter | n: $_ = 'fortnight'; s/^(.*)/micro$0/; .say; | 01:27 | |
camelia | niecza v24-95-ga6d4c5f: OUTPUT«microfortnight» | ||
diakopter | n: $_ = 'fortnight'; s/^(.*)/micro$0/.say; | ||
TimToady | </spam> | ||
camelia | niecza v24-95-ga6d4c5f: OUTPUT«True» | ||
diakopter | hey, I'm learning. again. | 01:30 | |
irclog.perlgeek.de/perl6/2007-08-06#i_76100 | 01:31 | ||
TimToady: ^ | |||
my first fuzz attempt | 01:32 | ||
erm. | |||
irclog.perlgeek.de/perl6/2006-08-11#i_-188291 | 01:34 | ||
^ me joining #perl6 first time I think | |||
01:35
fridim_ joined
|
|||
diakopter | no, it was the day before | 01:36 | |
no | |||
01:37
jnap left
|
|||
diakopter | this appears to have been my first utterance irclog.perlgeek.de/perl6/2006-08-08#i_-193391 | 01:38 | |
TimToady | wow, it's the red-letter edition... | 01:39 | |
diakopter | LOLOLOLOL irclog.perlgeek.de/perl6/2006-08-08#i_-193245 | ||
(and TreyHarris' reply) | |||
and thus the pseudo-mock-trolling began.. | 01:40 | ||
7 years flies by.. or something. | 01:41 | ||
TimToady | how fun flies when you're having time | 01:42 | |
01:42
FROGGS_ joined
|
|||
diakopter | I want a very wide graph showing the arcs of every nick's presence and vocalizations on the channel over the years | 01:44 | |
TimToady | maybe you should implement a computer language that would be good at that :P | 01:45 | |
01:46
FROGGS left
|
|||
diakopter | nothing's super-awesome at mysql db processing except mysql | 01:46 | |
er, maybe he moved it to pg | |||
wow, I actually have vague memories of backlogging this... at the time. | 01:47 | ||
TimToady | hmm, JVM compile blew up, trying a reconfig | ||
diakopter | ot of memory? | ||
*ut | 01:48 | ||
*out | |||
japhb__ | r: say True !?^ False | 01:49 | |
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/MZ5LBLRXVwCannot negate ?^ because it is not iffy enoughat /tmp/MZ5LBLRXVw:1------> say True !?^⏏ False» | ||
japhb__ | Say what? | ||
diakopter | yeah that error is pretty iffy | 01:50 | |
because it is not THIRTY_THIRD_DEGREE_GNOSTIC_FREEMASON_INNER_CIRCLE_INITIATION_CODEWORD enough | 01:51 | ||
Perl 6, where even the errors coin you | 01:52 | ||
TimToady | gnostic-in, gnostic out | ||
01:55
grondilu joined
|
|||
grondilu | r: constant fact = 1, [\*] 1 .. *; say fact[4] | 01:57 | |
camelia | rakudo 61580f: OUTPUT«24» | ||
japhb__ | I can see where iffy is used in Grammar.nqp and in precedence.pm. But why is ?^ not iffy? | ||
grondilu | TimToady: constant fact = 1, [\*] 1 .. *; say fact[4] # is probably simpler for rosettacode.org/wiki/Factorial#via_Sequence | ||
avuserow | r: $_ = "abacab"; s:g[(.)] = ord($/[0]); .say; | 01:58 | |
camelia | rakudo 61580f: OUTPUT«979897999798» | ||
avuserow | how could I write the above with, say, $a? | ||
diakopter | japhb__: if I had to guess [again], I'd conjecture iffiness has something to do with boolifiability | ||
japhb__ | My assumption is that 'iffy' roughly means 'produces a boolean result', in which case, just about any ? op should be iffy, neh? | 01:59 | |
r: $a = "abacab"; $a .=subst(/(.)/, ord($0)); $a.say; | 02:01 | ||
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/oqdeeAGkGdVariable '$a' is not declaredat /tmp/oqdeeAGkGd:1------> $a⏏ = "abacab"; $a .=subst(/(.)/, ord($0)); expecting any of: postfix» | ||
avuserow | r: my $a = "abacab"; $a ~~ s:g/(.)/{ord $0}/; | ||
camelia | ( no output ) | ||
avuserow | r: my $a = "abacab"; $a ~~ s:g/(.)/{ord $0}/; $a.say | ||
camelia | rakudo 61580f: OUTPUT«979897999798» | ||
japhb__ | r: my $a = "abacab"; $a .=subst(/(.)/, {ord($0)}, :g); $a.say; | ||
camelia | rakudo 61580f: OUTPUT«Nominal type check failed for parameter '$s'; expected Cool but got Any instead in sub ord at src/gen/CORE.setting:3438 in block at /tmp/DeNoQrtafk:1» | ||
japhb__ | r: my $a = "abacab"; $a .=subst(/(.)/, *.ord, :g); $a.say; | 02:02 | |
camelia | rakudo 61580f: OUTPUT«979897999798» | ||
avuserow | r: my $a = "abacab"; say $a.comb(/./).map: ord | ||
camelia | rakudo 61580f: OUTPUT«===SORRY!===CHECK FAILED:Calling 'ord' will never work with no arguments (lines 1, 1) Expected: :(Cool $s)» | ||
avuserow | r: my $a = "abacab"; say $a.comb(/./).map:. ord | ||
camelia | rakudo 61580f: OUTPUT«===SORRY!=== Error while compiling /tmp/wHY5q93qeuTwo terms in a rowat /tmp/wHY5q93qeu:1------> my $a = "abacab"; say $a.comb(/./).map⏏:. ord expecting any of: method arguments postfix infix st…» | ||
avuserow | r: my $a = "abacab"; say $a.comb(/./).map: .ord | ||
camelia | rakudo 61580f: OUTPUT«No such method 'count' for invocant of type 'Int' in method reify at src/gen/CORE.setting:7104 in method reify at src/gen/CORE.setting:7021 in method reify at src/gen/CORE.setting:7021 in method reify at src/gen/CORE.setting:7021 in method reify at sr…» | ||
japhb__ | avuserow: *.ord | ||
avuserow | okay, </spam> for me. :) | ||
ohh | |||
thanks japhb__++ :) | |||
japhb__ | np | 02:03 | |
So ... I'm still confused by iffy. diakopter and I seem to be thinking along the same lines, but Rakudo disagrees. Hmmm, what about std ... | |||
avuserow | comb is awesome :) | ||
japhb__ | std: say True !?^ False | 02:04 | |
camelia | std 4cde04e: OUTPUT«===SORRY!===Cannot negate ?^ because additive operators are not iffy enough at /tmp/3gFX66L7_k line 1:------> say True !?^⏏ FalseParse failedFAILED 00:00 42m» | ||
japhb__ | OK, at least Rakudo and STD agree. But I'm still confused. | ||
avuserow: that it is. :-) | |||
lue | [backlog] I was thinking of a has-like keyword for required attributes too. (something like needs $.this; or wants $.attr;) I still have a sneaking suspicion that "this is a required attribute!" enters the realm of non-default constructors. | ||
japhb__ | lue: needs and wants sound like role/interface requirements | 02:06 | |
avuserow | though I still don't see how (or if it is possible) to do s[foo] = "bar" on something other than $_ | ||
japhb__ | lue: it just seems really common to want to know that (some subset of) your attributes are guaranteed initialized. | ||
(By the caller, not by a default value) | 02:07 | ||
lue | yeah. If only english had a verb meaning "in possession of something on which additional information is needed by the possessor." | ||
japhb__ | r: my $a = "foo"; $a ~~ s[foo] = "bar"; say $a; | ||
camelia | rakudo 61580f: OUTPUT«bar» | ||
japhb__ | avuserow: like that ^^ | ||
avuserow | huh. thought I tried that. | ||
lue | japhb__: the "it's a common desire" is why I'm middle-of-the-road on its necessity. On the one hand, people need it often. OTOH, is it really that much harder to write your own constructor :) ? | ||
TimToady | huh, parse went back up from 85 seconds to 91 | 02:08 | |
japhb__ | lue: Not hard, no. Just boilerplate. That's why we have a default new(), after all, to git rid of pointless boilerplate. | ||
diakopter | TimToady: we got 7% more features? | ||
japhb__ | diakopter: \o/ | ||
colomon | \o/ | 02:09 | |
lue | but I do like the consistency of C<has $.attr!> for this feature. | ||
diakopter | ..just play along.... | ||
japhb__ | lue: Yeah, I'm still thinking that's the best idea yet. | ||
(And it wasn't mine, someone else came up with it long ago.) | |||
lue | (and I think has $!attr! is the same as marking $a as read-write after using ::=. That is to say, pointless and wrong.) | ||
japhb__ | yeah. | 02:10 | |
lue | After all, you can't set private attrs by default in the first place, so any concern with $!attr! is a non-issue, from where I stand. | ||
japhb__ | Hmmm, 'has $.foo!' implies you can Nil it either ... | ||
lue: right | |||
er, *can't Nil it | 02:11 | ||
I kinda like that. | |||
TimToady | grondilu++ | 02:13 | |
lue | I take it grondilu invented $.attr! ? | 02:14 | |
dalek | d: a0bcfb1 | larry++ | STD.pm6: ?^ should be marked iffy |
02:16 | |
lue | If we go with has $.foo! , we should definitely allow has $.foo? too. | 02:17 | |
japhb__ | \o/ # ?^ officially iffy | ||
02:27
grondilu left
02:32
chano left
02:35
odoacre joined
02:39
odoacre_ left
02:41
benabik joined
02:45
odoacre left
02:53
xinming left
02:58
odoacre joined
03:00
xinming joined
03:06
raiph left
03:12
xinming left
03:14
xinming joined
03:18
xinming left
03:21
raiph joined
03:22
skids joined
03:24
xinming joined
|
|||
TimToady | lue: I was ++ing grondilu for [\*] 1..* to get factorial | 03:27 | |
BenGoldberg | r: say [\*] 1..25; | 03:33 | |
camelia | rakudo 61580f: OUTPUT«1 2 6 24 120 720 5040 40320 362880 3628800 39916800 479001600 6227020800 87178291200 1307674368000 20922789888000 355687428096000 6402373705728000 121645100408832000 2432902008176640000 51090942171709440000 1124000727777607680000 25852016738884976640000 6204484…» | ||
BenGoldberg | :) | ||
So I've got a silly question: Why are the Set infix operators defined using names such as "\x2208", instead of "\c[element of]" | 03:35 | ||
geekosaur | because \c[] is only available with icu? | 03:36 | |
which is an optional dependency? | |||
BenGoldberg | Oh, ok. | ||
TimToady | icu is not really a dependency we want to keep | 03:39 | |
we've got to have our own unicode definitions anyway for portability to various platforms, so we might as well use that everywhere | 03:41 | ||
plus ours will be optmized for NFG | 03:42 | ||
std: say True !?^ False | 03:43 | ||
camelia | std a0bcfb1: OUTPUT«ok 00:00 42m» | ||
TimToady | afk & | ||
03:45
eternaleye left
03:49
gattscha1do joined
03:52
gattschardo left
03:54
BenGoldberg left
03:58
prevost joined,
eternaleye joined
04:00
preflex left
04:02
preflex joined,
ChanServ sets mode: +v preflex,
btyler joined
04:07
SamuraiJack__ joined
04:17
prevost left
04:23
fridim_ left
04:29
btyler left
04:52
japhb_ left
|
|||
lue | BenGoldberg: the \x form may be more cryptic, but it takes less characters to type. | 05:02 | |
:) | |||
05:03
japhb_ joined
05:39
xinming_ joined
05:42
xinming left
05:47
xenoterracide left
05:59
FROGGS[mobile] joined
06:09
darutoko joined
06:19
japhb_ left
|
|||
[Coke] yawns | 06:27 | ||
06:30
japhb_ joined
|
|||
dalek | rl6-roast-data: 090c37b | coke++ | / (5 files): today (automated commit) |
06:32 | |
06:33
denis_boyun_ joined
|
|||
[Coke] | niecza back up to 844 fails | 06:34 | |
06:41
japhb_ left
06:45
raiph left,
dmol joined
06:47
rindolf joined,
GlitchMr left
06:48
GlitchMr joined
06:49
denis_boyun__ joined
06:50
FROGGS_ left,
kaleem joined
06:51
denis_boyun_ left
06:53
japhb_ joined
06:55
rindolf left
07:08
iSlug joined
07:11
sciurius joined
07:12
rindolf joined
07:14
zakharyas joined
07:36
camelia joined
|
|||
moritz | r: say 42 | 07:36 | |
07:36
ChanServ sets mode: +v camelia
|
|||
camelia | rakudo 61580f: OUTPUT«42» | 07:36 | |
diakopter | r: "i'm slow".say | 07:37 | |
camelia | rakudo 61580f: OUTPUT«i'm slow» | ||
diakopter | n: "i'm fast".say | ||
moritz | diakopter: the first execution with camelia is *always* slow | ||
camelia | niecza v24-98-g473bd20: OUTPUT«i'm fast» | ||
moritz | diakopter: I have no idea why | ||
diakopter | me neither :) | ||
07:39
rindolf left
|
|||
dalek | albot/host07: cb218d7 | moritz++ | evalbot.pl: nqp-moarvm |
07:41 | |
07:41
camelia left
|
|||
FROGGS[mobile] | uhh | 07:42 | |
diakopter | hee hee | ||
FROGGS[mobile] | moritz++ | ||
dalek | albot/host07: e9922ec | moritz++ | evalbot.pl: missing comma |
||
diakopter | moritz++ indeed | ||
07:42
camelia joined
|
|||
diakopter | moritz: did you see my note about pugs path | 07:42 | |
tadzik: ping | 07:43 | ||
moritz | diakopter: yes. There's also a ~p6eval/.cabal/bin/pugs | ||
07:43
ChanServ sets mode: +v camelia
|
|||
diakopter | oh | 07:43 | |
moritz | diakopter: which I kinda prefer, because it means we can make /root/ permissions more restrictive again | ||
nqp-moarvm: say(42) | |||
camelia | nqp-moarvm: OUTPUT«42» | ||
moritz | rnp: print 42 | ||
camelia | rakudo 61580f, niecza v24-98-g473bd20: OUTPUT«42» | 07:44 | |
..pugs: OUTPUT«perl: warning: Setting locale failed.perl: warning: Please check that your locale settings: LANGUAGE = "en_US:en", LC_ALL = "en_US.ISO-8859-1", LANG = "en_US.UTF-8" are supported and installed on your system.perl: warning: Falling back to the standa…» | |||
diakopter | nqp-m: my $a := 1000000; while $a-- { } | ||
camelia | ( no output ) | ||
diakopter | nqp-m: my $t := nqp::now; my $a := 1000000; while $a-- { }; say(nqp::now - $t); | ||
camelia | nqp-moarvm: OUTPUT«No registered operation handler for 'now'compile_op» | ||
diakopter | nqp-m: my $t := nqp::time_i; my $a := 1000000; while $a-- { }; say(nqp::time_i - $t); | ||
camelia | nqp-moarvm: OUTPUT«0» | ||
diakopter | whaa | ||
nqp-m: my $t := nqp::time_i; my $a := 10000000; while $a-- { }; say(nqp::time_i - $t); | 07:45 | ||
camelia | nqp-moarvm: OUTPUT«5» | ||
JimmyZ | nqp-m: my $t := nqp::time_i; my $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | ||
camelia | nqp-moarvm: OUTPUT«1.059592» | ||
moritz | nqp-m: my $t := nqp::time_n; my $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | ||
camelia | nqp-moarvm: OUTPUT«0.728743» | ||
diakopter | ok | ||
moritz | p: 42 | 07:46 | |
camelia | pugs: OUTPUT«perl: warning: Setting locale failed.perl: warning: Please check that your locale settings: LANGUAGE = "en_US:en", LC_ALL = "en_US.ISO-8859-1", LANG = "en_US.UTF-8" are supported and installed on your system.perl: warning: Falling back to the standa…» | ||
07:46
camelia left,
camelia joined
|
|||
JimmyZ | MoarVM's not built with --optimize | 07:46 | |
I think | |||
07:47
ChanServ sets mode: +v camelia
|
|||
diakopter | actually that machine's cpu isn't amazingly fast | 07:47 | |
but yes, it should be built with optimize :) | |||
(if it's not) | |||
yay; we can decrement integers... | 07:48 | ||
07:48
denis_boyun__ left
|
|||
diakopter | nqp-j: my $t := nqp::time_n; my $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 07:48 | |
nqp-jvm: my $t := nqp::time_n; my $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 07:49 | ||
camelia | nqp-jvm: OUTPUT«0.09299993515014648» | ||
diakopter | heh. | ||
moritz | p: say 42 | ||
camelia | pugs: OUTPUT«perl: warning: Setting locale failed.perl: warning: Please check that your locale settings: LANGUAGE = "en_US:en", LC_ALL = "en_US.ISO-8859-1", LANG = "en_US.UTF-8" are supported and installed on your system.perl: warning: Falling back to the standa…» | ||
moritz | grml | ||
diakopter | moritz: I remember fixing this on feather3 or wherever | ||
07:49
fhelmberger joined
|
|||
diakopter | nqp-m: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 07:51 | |
camelia | nqp-moarvm: OUTPUT«0.739564» | ||
diakopter | nqp-jvm: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | ||
camelia | nqp-jvm: OUTPUT«0.0709998607635498» | ||
diakopter | meh | ||
nqp: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | |||
FROGGS[mobile] | can we have a nqp-* command? | ||
camelia | nqp: OUTPUT«0.53498911857605» | ||
moritz | I can cope with the Debian locale system, but Ubuntu's freaks me out | 07:52 | |
diakopter | they're that different? | ||
moritz | yes | ||
JimmyZ | the best one should be perl Configure.pl && make CGOTO=1 | ||
diakopter | JimmyZ: well we need to tell it clang too | ||
moritz | FROGGS[mobile]: if somebody patches it in, yes | ||
diakopter looks at the rebuild scdript on host07 | 07:53 | ||
JimmyZ | I meant perl Configure.pl --optimize | ||
07:53
ribasushi left
|
|||
moritz | p: say 42 | 07:53 | |
camelia | pugs: OUTPUT«42» | ||
moritz | \o/ | ||
diakopter | moritz++ | 07:54 | |
p: say /3/ | |||
moritz | ftr: added line "en_US.ISO-8859-1 ISO-8859-1" to /var/lib/locales/supported.d/local and then dpkg-reconfigure locales | ||
camelia | pugs: OUTPUT«<Regex>» | ||
diakopter | p: say 3~~/3/ | ||
camelia | pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) { unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.20120717/blib6/pugs/perl5/lib'; eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;}'Pugs::Runtime::Match::HsBridge'"**…» | ||
diakopter | poo | ||
moritz: that one might be solvable | 07:55 | ||
moritz: I don't see a rebuild-moarvm.pl do you want me to make one? | |||
moritz | rakudo-jvm: say 42 | ||
diakopter: yes please | |||
camelia | rakudo-jvm: OUTPUT«(signal XCPU)» | 07:56 | |
diakopter | whee | ||
*giggle* | |||
07:56
ribasushi joined
|
|||
moritz | yes, needs evalserver | 07:56 | |
07:58
xinming_ left
08:00
xinming joined
|
|||
diakopter | r: ; | 08:06 | |
camelia | ( no output ) | ||
diakopter | JimmyZ: does clang take a very long time to do CGOTO=1 on interp.c? | 08:07 | |
apparently so... | 08:08 | ||
JimmyZ | I thought clang supports CGOTO well enought... | 08:10 | |
diakopter | nqp-m: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 08:15 | |
camelia | nqp-moarvm: OUTPUT«0.452568» | ||
diakopter | better, anyway | ||
still 5x slower than jvm :) | |||
jnthn: ^ | |||
jnthn | Well, of course. | 08:16 | |
JimmyZ | diakopter: with CGOTO and --optimize? | ||
moritz | nqp-jvm: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | ||
camelia | nqp-jvm: OUTPUT«0.06500005722045898» | ||
diakopter | JimmyZ: yes, and clang | ||
jnthn | That's exactly the sort of thing a JIT makes a hot job of. | ||
diakopter | I'll try with gcc | ||
08:17
Timbus|Away joined
|
|||
diakopter | nqp-m: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 08:18 | |
08:18
Timbus left
|
|||
camelia | nqp-moarvm: OUTPUT«0.232732» | 08:18 | |
08:18
Timbus|Away is now known as Timbus
|
|||
diakopter | ^ with gcc | 08:18 | |
JimmyZ | gcc is better than clang? | ||
diakopter | apparently at that benchmark ;) | ||
micromicromicromicromicrobenchmark | 08:19 | ||
jnthn | nqp: my $t := nqp::time_n; my int $a := 1000000; while $a-- { }; say(nqp::time_n - $t); | 08:20 | |
camelia | nqp: OUTPUT«0.495544195175171» | ||
diakopter | well, that's something | ||
jnthn | yeah, but it's all op dispatch overhead here. | 08:21 | |
diakopter | yeah, but that's still something | ||
jnthn | aye; apparently Moar dispatches ops faster :) | 08:22 | |
diakopter wonders how the jvm would do if we disabled its JIT entirely.... ;) | 08:23 | ||
nwc10 | presumably that is acutally possible with an open source JVM. Does Sun's let you do it? | 08:24 | |
jnthn | Probably "ok" given the bytecode was designed to be interpretable... | ||
diakopter | nwc10: we're using Sun's on that box | 08:25 | |
jnthn | I think tehe's sa flag | ||
diakopter | p6eval@host07:~/MoarVM$ java -version | ||
java version "1.7.0_40" | |||
Java(TM) SE Runtime Environment (build 1.7.0_40-b43) | |||
Java HotSpot(TM) 64-Bit Server VM (build 24.0-b56, mixed mode) | |||
jnthn | *there's, a | ||
nwc10 | bytecode *has* to be interpretable, else it would be stupid, because it would be slower than regular ahead-of-time compiling | 08:26 | |
diakopter | yep, things run berry berry slowly | ||
08:26
odoacre_ joined
|
|||
diakopter | but startup time is hella fasta! | 08:28 | |
jnthn | diakopter: really? hm | ||
08:30
odoacre left
08:34
kivutar left
08:35
iSlug left,
FROGGS[mobile] left
08:55
iSlug joined
09:02
mathw_ is now known as mathw
|
|||
mathw | Good morning o/ | 09:02 | |
moritz | good morning mathw | 09:03 | |
mathw | hey moritz | ||
jnthn | o/ | 09:04 | |
09:11
iSlug left
09:14
daniel-s joined
09:16
dmol left
09:21
FROGGS[mobile] joined
|
|||
mathw | jnthn! | 09:21 | |
I wrote a little Perl 6 at the weekend | 09:23 | ||
it was... nice | |||
hyphens in variable names | 09:24 | ||
so good. That's one of the things I like about Lisps as well | |||
jnthn | yeah, it looks kinda nice | 09:25 | |
09:25
gfldex left
|
|||
jnthn | I guess reading AMOP was the first time I'd read any significant amount of Lisp... :) | 09:25 | |
09:27
gfldex joined
09:28
daniel-s left
|
|||
moritz | uh, rakudo-parrot spectest looks quite dirty | 09:28 | |
lots of fallout in set/bag tests, but also S32-io/note.t and S02-types/declare.t | 09:29 | ||
and one in S05-metasyntax/delimiters.t | |||
jnthn | The note one aside, I'm guessing fallout from the set/bag renaming stuff | ||
moritz | ah, my t/spec got stuck :/ | 09:30 | |
never mind then | |||
09:31
daniel-s joined
|
|||
moritz | but my desktop froze during the spectest run for a while, so I guess there's still something wrong | 09:34 | |
09:39
daniel-s left
|
|||
tadzik | diakopter: pong | 09:45 | |
09:46
gfldex left
|
|||
moritz | t/spec/S02-types/array.t uses excessive amounts of memory after test 81 | 10:02 | |
I set a ulimit to 2GB, and it runs into that limit | |||
ah, it's dies_ok { Mu.[0] }, 'but Mu has no .[]'; | 10:03 | ||
.to lizmat it seems that Mu.[0] causes infinite recursion; maybe related to the postcircumfix rework? | |||
yoleaux | moritz: I'll pass your message to lizmat. | ||
10:06
rjbs- left,
rjbs joined
10:10
daxim joined
|
|||
moritz | r: Mu.[0] | 10:11 | |
camelia | rakudo 61580f: OUTPUT«Cannot call 'postcircumfix:<[ ]>'; none of these signatures match::(\SELF, int $pos):(\SELF, int $pos, Mu \$BIND):(\SELF, int $pos, :delete(:$delete)!, *%other):(\SELF, int $pos, :exists(:$exists)!, *%other):(\SELF, int $pos, :kv(:$kv)!, *%other)…» | ||
moritz hopes the resource limits work on the new box | 10:12 | ||
huh. | |||
moritz gets spam with "dispose of that old mop", and thinks "what's wrong with our MOP?" | 10:14 | ||
jnthn | oh, I'm getting loads of mop spam too | 10:15 | |
Apparently MOPs can spread bacteria too | 10:16 | ||
.oO( Who on earth is going to buy a new mop 'cus they get spam about it???! ) |
|||
10:16
kivutar joined
|
|||
moritz | who on earth is going to buy anything because they get spam about it? | 10:17 | |
tadzik | enough people so it makes sense to send spam | 10:18 | |
moritz | and that's really the heart of the problem | 10:19 | |
jnthn | I know, it's just the choice of mops as a thing to spam about... :) | 10:20 | |
mathw | yeah maybe the market for genital enlargement products has peaked | 10:24 | |
moritz | .oO( peak oil was yesterday. Today it's peak ... ) |
10:26 | |
10:27
rindolf joined
10:30
denis_boyun joined
10:31
dmol joined
10:33
denis_boyun left
10:34
denisboyun joined,
gfldex joined
|
|||
JimmyZ saw jnthn++'s comments to AMOP in google book | 10:47 | ||
10:51
camelia left
10:52
camelia joined,
ChanServ sets mode: +v camelia
10:55
kivutar left
|
|||
moritz | ok, camelia now runs inside a tmux session on host07.perl6.com | 10:56 | |
you can get to it as user p6eval with tmux attach -t 2 | 10:57 | ||
nwc10 | how do I ask camelia which backends she has? | ||
moritz | camelia: help | ||
camelia | moritz: Usage: <(rakudo-jvm|nqp-jvm|star|pugs|nqp|std|niecza|rakudo|b|nqp-moarvm|nom|r|nqp-m|nqp-mvm|pnr|p6|nr|n|npr|perl6|prn|rn|r-j|r-jvm|p|rnp|nrp|rpn)(?^::\s) $perl6_program> | ||
10:57
daxim left
|
|||
moritz | nwc10: it also lists all aliases, which is why it's a bit messy :-) | 10:57 | |
jnthn | r-j: say('hi from jvm') | 10:58 | |
camelia | rakudo-jvm: OUTPUT«(signal XCPU)» | 10:59 | |
jnthn | aww | ||
moritz | I didn't say they all *work* :-) | ||
10:59
kivutar joined
|
|||
nwc10 | moritz: feature request - could they all work please? :-) | 10:59 | |
jnthn | :P | ||
moritz | jnthn: just decrease startup time of rakudo-jvm enough to be usable with the existing CPU limits, and then that wouldn't happen anymore :-) | ||
nwc10 | nice answer | 11:00 | |
moritz | though in the short term we'll likely use an evalserver | ||
does the evalserver mix with --setting=RESTRICTED? | |||
jnthn | I think so | ||
11:01
kivutar left
|
|||
colomon | woah | 11:02 | |
stage parse went from 108 two nights ago to 135 last night. :( | |||
11:03
daxim joined
|
|||
jnthn | huh | 11:03 | |
We merged stuff yesterday that got rid of almost a million Cursor allocations and it was generally reported as a win. What changed since then? | 11:04 | ||
colomon | hmm…. oh, it's possible I had a $work test running to slow things down? | 11:05 | |
jnthn | Dunno | ||
colomon | oh, that's looking like a real possibility. | ||
jnthn | I know if I build multiple things at once then they get slower, though :) | ||
colomon | give me a moment. | 11:06 | |
jnthn | k | ||
moritz | some of those modern CPUs have dynamic overclocking, which only works if just a single core is active (due to thermal restraints) | ||
colomon | My $work tests generally run on four cores at once | 11:07 | |
(nothing fancy, I just have 4 instances of the test going.) | 11:08 | ||
jnthn | I suspect that the real bottleneck ends up being not cores, but memory access | ||
11:11
denisboyun left
|
|||
colomon | will have another number for you in a moment | 11:11 | |
nwc10 | jnthn: is this a bug in the JVM, or just running out of memory? | 11:17 | |
java.lang.ArrayStoreException: <unknown> in finish_code_object (src/Perl6/World.nqp:1070) | |||
(etc) | |||
jnthn | nwc10: That's a "huh wtf" | 11:19 | |
nwc10 | OK, quite possibly a JVM bug | 11:20 | |
jnthn | docs.oracle.com/javase/7/docs/api/j...ption.html # docs for it | ||
nwc10 | that's the first run in a while that didn't coredump the JVM and issue an "if you want to report a bug" report | ||
jnthn | JVM bugs aside, it's a little hard to imagine a scenario where that arises on one machine but not another... | 11:21 | |
moritz | ok, I have now twice reverse-engineered how the JVM evalserver works | 11:30 | |
(in the past) | |||
I swear that if I do it a third time (for camelia), I'll actually document it | 11:31 | ||
11:31
gattscha1do left
|
|||
colomon | parse time on this trial 97 seconds, so that's a 10% shaved off since two days ago. jnthn++ | 11:35 | |
timotimo | so, are we going to reduce the initial size of ListIter's internal counter thingie down from 100_000? | 11:49 | |
i'm still in favor of giving qrpa a very big factor for downsizing; something like "reduce to 1/2 the size if less than 1/16 of the slots are in use" | 11:50 | ||
cool, my rakudo-parrot parse time is down to 106 seconds from about 120s | 11:51 | ||
timotimo should pull in the newest changes as well | 11:52 | ||
11:52
iSlug joined
|
|||
moritz | ListIter stores a list of slots? | 11:53 | |
either that sounds confused, or I am confused | |||
timotimo | it has a $rpa that stores things | ||
if $eager is true, it gets pre-sized to 100_000 | |||
donaldh found out yesterday evening, that even before the first line in the evalserver is run, 15 of those 100_000 element big arrays get allocated (and not yet freed) | 11:55 | ||
lizmat | good *, #perl6! | 11:58 | |
yoleaux | 10:03Z <moritz> lizmat: it seems that Mu.[0] causes infinite recursion; maybe related to the postcircumfix rework? | ||
lizmat | moritz: All tests successful. | ||
Files=1, Tests=99, 8 wallclock secs ( 0.03 usr 0.01 sys + 7.17 cusr 1.21 csys = 8.42 CPU) | |||
this is on parakudo, are you using jakudo? | |||
moritz | lizmat: parakudo | 11:59 | |
lizmat | weird, lemme check | ||
jnthn | r: Mu.[0] | ||
camelia | rakudo 61580f: OUTPUT«Cannot call 'postcircumfix:<[ ]>'; none of these signatures match::(\SELF, int $pos):(\SELF, int $pos, Mu \$BIND):(\SELF, int $pos, :delete(:$delete)!, *%other):(\SELF, int $pos, :exists(:$exists)!, *%other):(\SELF, int $pos, :kv(:$kv)!, *%other)…» | ||
moritz | Files=1, Tests=99 that's not a full spectest run, no? | ||
lizmat | nope, just that file | 12:00 | |
moritz | oh | 12:01 | |
hm, weird | |||
I also did a 'git clean -xdf' in all the repos involved | |||
lizmat | it *does* take about 3 seconds to fail | 12:02 | |
moritz | lizmat: locally start a shell with a ulimit -v 1048576 | ||
lizmat | and all CPU, so maybe you're just seeing it more | ||
moritz | lizmat: and then try ./perl6 -e 'Mu.[0]' | ||
lizmat | it seems to grow about 250 MB for that | 12:03 | |
moritz | so there's something wrong with that | ||
lizmat | $ ulimit -v 1048576 | ||
$ perl6 -e 'Mu.[0]' | |||
Cannot call 'postcircumfix:<[ ]>'; none of these signatures match: | |||
and a long list of signatures | 12:04 | ||
moritz doesn't understand this at all | |||
lizmat | ICU related maybe ? | 12:05 | |
moritz | dunno, would surprise me | ||
given that it's not related to string handling at all, afaict | |||
12:05
iSlug left
|
|||
lizmat | maybe ulimit doesn't work on OS X | 12:05 | |
moritz wipes clean everything, and rebuilds | |||
lizmat | $ ulimit -v 1048576 | ||
$ ulimit | |||
unlimited | |||
timotimo | that's correct, you'd need to ulimit -a to see the actual limit | 12:06 | |
moritz | or ulimit -v | 12:07 | |
lizmat | max memory size (kbytes, -m) 1048576 # so it did work | ||
errands& | 12:10 | ||
12:14
skids left
12:15
rindolf left
12:17
iSlug joined
12:24
bluescreen10 left
12:38
grondilu joined
12:42
mtk left
12:43
colomon left
|
|||
masak | good afternoon, #perl6 | 12:44 | |
12:44
rindolf joined
|
|||
moritz | \o masak | 12:44 | |
12:49
ribasushi left
12:54
ribasushi joined
12:55
ajr joined
12:56
ajr is now known as Guest69469,
Guest69469 is now known as ajr_
13:07
mtk joined
13:10
PacoAir joined
|
|||
moritz | after removing everything and rebuilding from scratch, I still get that error from S02-types/array.t :/ | 13:17 | |
and Any.[0] takes 0.4s (including startup time), Mu.[0] takes 2.2s | 13:18 | ||
I don't think that it takes 2s to list all the candidates in that error message | |||
13:18
denis_boyun joined
13:19
kay joined
|
|||
moritz | /usr/bin/time ./perl6 -e 'try Mu.[0]' | 13:19 | |
1.02user 0.34system 0:01.38elapsed 99%CPU (0avgtext+0avgdata 1499688maxresident)k | |||
0inputs+0outputs (0major+379426minor)pagefaults 0swaps | |||
/usr/bin/time ./perl6 -e 'try Any.[0]' | |||
0.33user 0.08system 0:00.42elapsed 97%CPU (0avgtext+0avgdata 300788maxresident)k | |||
0inputs+0outputs (0major+79697minor)pagefaults 0swaps | |||
13:19
kay is now known as Guest51551
|
|||
masak .oO( slow as the bellow of a cow ) | 13:19 | ||
timotimo | wow, so much more memory used | 13:20 | |
moritz | aye | ||
timotimo | r: 1499688 / 300788 | ||
camelia | ( no output ) | ||
timotimo | r: say 1499688 / 300788 | ||
camelia | rakudo 61580f: OUTPUT«4.985864» | ||
moritz | so I'm pretty sure there's something seriously wrong here, but I don't know what it could be, because everything I could think of would fatally die on all setups, not just mine | ||
13:21
kaleem left
13:23
bbkr_ joined
|
|||
masak | moritz: maybe submit a rakudobug? | 13:23 | |
the problem sounds palpable enough to be an observable. | 13:24 | ||
bbkr_ | hi, how can I do quotemeta() in P6? | ||
moritz | bbkr_: it's the default for regex interpolation | ||
r: my $str = '$str'; say '$str' ~~ /$str/ | |||
camelia | rakudo 61580f: OUTPUT«「$str」» | ||
moritz | which is why there's no special method or sub for it | 13:25 | |
13:26
kbaker joined
|
|||
bbkr_ | I need it for qx{}. to pass password param from MAIN safely to system command | 13:29 | |
qx:s{something --password=$pass } does not quote meta characters by default | 13:30 | ||
moritz | right. But for that you don't need quotemeta, but shellquote (don't think that exists either, but it's not the same) | 13:31 | |
geekosaur shudders at passing passwords on command line | |||
bbkr_ | thanks | 13:32 | |
GlitchMr | run "command", "something", "-password=$pass"; | ||
But I don't think it's good idea to pass passwords on command line. | |||
13:32
ribasushi left
|
|||
moritz | GlitchMr: but that doesn't capture standard output | 13:33 | |
which qx does | |||
GlitchMr | oh, right | ||
Escaping is possible, but probably error prone, and OS specific. | 13:34 | ||
Replace ' with '\'', and put everything in single quotes. | |||
timotimo | quoting is simply ugly :( | ||
GlitchMr | Still, Perl 6 needs something like IPC::Run. | ||
bbkr_ | indeed, perl6 -e 'run "echo", "a b\"c"' works as expected. I do not need to capture output and password is not sensitive at all in my case so this solution solves my question. thanks again | 13:35 | |
moritz | GlitchMr: agreed | 13:36 | |
GlitchMr | Also, it would be fun if code like run("echo", "something") ==> run("some", "other", "command") would just work (the command doesn't have to be run). | 13:38 | |
13:38
rindolf left
|
|||
bbkr_ | does run set any status variable like $! in P5? | 13:38 | |
GlitchMr | Run gives status as return code. | ||
13:38
ribasushi joined
|
|||
GlitchMr | When used as boolean, it's true when return code is 0. When used as number, it returns return code. | 13:39 | |
13:39
skids joined
|
|||
timotimo | .o(still b0rked in loops, i believe) | 13:40 | |
cannot show it in the evalbot, though | |||
bbkr_ | GlitchMr: works, thanks | ||
timotimo | r: for ^1000 { 1 but False } | ||
camelia | ( no output ) | ||
timotimo | r: for ^1000 { my $i = 1 but False; 1 } | ||
camelia | rakudo 61580f: OUTPUT«(signal ABRT)» | ||
timotimo | there we go | ||
masak | lovely. | 13:42 | |
timotimo | p6bench is hit by that :( | ||
GlitchMr | I still have no idea why run() likes to fail. | ||
Something is broken with "but Boolean", but I've no idea why. | 13:43 | ||
masak | GlitchMr: um... it's not &run that fails, as evidenced by the above? | ||
GlitchMr | Yeah, I know. | ||
timotimo | r: class ProcessResult is Int is Bool { has $.rval; method Bool { not $.rval }; method Int { $.rval } }; given ProcessResult.new(:rval(1)) { say +$_; say so $_ } | ||
camelia | rakudo 61580f: OUTPUT«===SORRY!===Duplicate box_target for native int» | ||
GlitchMr | I know the problem is with "but Boolean", but, I don't know why it fails. | ||
timotimo | whoops? | ||
GlitchMr | Something about double free(), but... | 13:44 | |
gist.github.com/GlitchMr/6826186 | 13:46 | ||
Not really useful | |||
13:47
btyler joined
|
|||
GlitchMr | "Address 0x8 is not stack'd, malloc'd or (recently) free'd" | 13:47 | |
huh? | |||
0x8 doesn't look like an address. | |||
moritz | it looks like a NULL-Pointer that's been incremented by 64 bit | 13:48 | |
GlitchMr | hm, makes sense. | ||
timotimo | so trying to access a null pointer with an offset of 1 int | 13:49 | |
somewhere in the bigint ops | |||
GlitchMr | What does bigint have with "but"? | ||
moritz | GlitchMr: maybe it's not the "but", but the boolification protocol | 13:50 | |
GlitchMr | That would make sense. | ||
I don't know much about Perl 6 internals. | 13:51 | ||
I wonder how JVM reacts to that. | |||
Nothing, no crashes, no anything. | 13:53 | ||
But that makes sense, it's JVM, not Parrot. Entire lowlevel codebase is different. | |||
(I was hoping JVM version of NQP would throw an exception) | 13:54 | ||
13:57
jnap joined
14:05
bruges_ left
14:06
bruges joined
14:08
iSlug left,
benabik left
14:10
xenoterracide joined,
SmokeMachine joined,
kivutar joined
14:12
bruges left,
bruges joined
14:13
bluescreen10 joined
14:19
fhelmberger left
14:20
SamuraiJack__ left
14:33
lizmat left,
lizmat joined
14:34
bluescreen10 left
14:41
risou_awy_ is now known as risou
14:48
fhelmberger joined
14:49
benabik joined
14:52
hummeleB1 joined,
fhelmberger left
14:56
ajr joined,
ajr_ left
14:57
ajr is now known as Guest16641
14:58
Guest16641 is now known as ajr_
15:10
raiph joined
15:16
rindolf joined
15:23
daxim left,
dmol left
|
|||
dalek | rlito: ed1912f | (Flavio S. Glock)++ | misc/pretty_print.pl: Perlito5 - pretty-printer stub |
15:29 | |
moritz | abstrusegoose++ # "Big data just means increasing the font size" | 15:33 | |
15:33
zakharyas left
15:34
kivutar left
15:39
daxim joined,
daxim left
15:41
donaldh joined
|
|||
donaldh | moritz: is it a coincidence that this xkcd.com/ mouseover is the converse? | 15:43 | |
I should say xkcd.com/1273/ for future proofing | 15:44 | ||
If nobody else gets to 100_000 eager ListIter before the end of UTC day, I'll take a look. | 15:47 | ||
timotimo is currently in "use keyboard as little as possible to get out of RSI mode ASAP" mode | 15:48 | ||
donaldh | FWIW, it looks like MapIter is doing it righter. | ||
TimToady wonders if this is a result of trying to say "well, if if a list of unknown finity has 100_000 elements, maybe we'd better think of it as infinite anyway" | 15:51 | ||
*finitude, I guess | 15:52 | ||
15:52
Guest51551 left
|
|||
TimToady | but even if we make such a guess and stop evaluating a mostly-eager list, that doesn't mean we should allocate 100_000 right off the bat | 15:53 | |
timotimo | agreed, 100_000 seems really excessive | ||
15:53
bbkr__ joined
|
|||
TimToady | unless we plan to always copy it to something shorter when we find the end | 15:54 | |
donaldh | Well MapIter just maxxes out at 100_000 for the $rpa | ||
So if it is infinite, we don't need infinite memory. | 15:55 | ||
japhb__ | "maxes out"? | ||
donaldh | $count = 100_000 if $count > 100_000 | ||
won't allocate an array bigger than 100_000 when eager. | 15:56 | ||
timotimo | so ... will only the first 100_000 elements ever be stored? | ||
donaldh | dunno about that. | ||
15:56
bbkr left
|
|||
moritz | fwiw the 100_000 is how many elements are reified *at once* | 15:57 | |
not how many are reified at all | |||
timotimo | ah, ok | ||
donaldh | what moritz said | ||
That seems like more sane logic for ListIter too right ? | 15:58 | ||
TimToady | how does ListIter differ? | ||
donaldh | When eager, it presizes its $rpa to 100_000 regardless | 16:00 | |
Not reify up to 100_000 *at once* | |||
TimToady | yeah, I see that | 16:03 | |
to me that seems unlikely to be the right balance point for an initial guess | 16:04 | ||
the 'r' stands for "resizeable" doesn't it? | 16:05 | ||
donaldh hadn't got around to asking what rpa stands for | 16:07 | ||
geekosaur | resizable parrot-m(something)-code array? | 16:08 | |
originally at least | |||
TimToady | but that's only for reify(*), so maybe it's the fault of the callers | 16:09 | |
(partly) | 16:10 | ||
arnsholt | geekosaur: ResizablePMCArray, where PMC is what Parrot calls an object | 16:11 | |
TimToady | $!listiter.reify(*) appears to be called only from MapIter | ||
geekosaur | yeh, I was trying to expand PMC at the same time | 16:12 | |
arnsholt | Parrot Magic Cookie initially, later retconned to PolyMorphic Container, IIRC | ||
[Coke] | let me know if you fix the pugs issue on camelia, as that is making the daily runs about 20x as painful as they need to be. | ||
geekosaur | since replacing one indigestible initialism with another is less than helpful | ||
16:14
dmol joined
|
|||
TimToady | MapIter calls ListIter.reify(*) if count is *, so it's also allocating 100_000 in that case | 16:17 | |
1000 might be much saner | 16:18 | ||
donaldh will experiment with it later. | 16:19 | ||
TimToady | 4 might be even saner than that--see Perl 5 | ||
donaldh | decommute& | ||
16:19
donaldh left
|
|||
[Coke] | nqp: nqp:say(1,2,3); | 16:20 | |
camelia | nqp: OUTPUT«Confused at line 2, near "nqp:say(1,"current instr.: 'panic' pc 14748 (src/stage2/gen/NQPHLL.pir:5229) (src/stage2/gen/NQPHLL.nqp:279)» | ||
TimToady | of course, Perl 5 was partly assuming a powers-of-two allocator, so growing the array by 5/4 each time only copies when crossing 2**n boundaries | ||
[Coke] | nqp: nqp:deb(1,"hi"); | ||
camelia | nqp: OUTPUT«Confused at line 2, near "nqp:deb(1,"current instr.: 'panic' pc 14748 (src/stage2/gen/NQPHLL.pir:5229) (src/stage2/gen/NQPHLL.nqp:279)» | ||
[Coke] | nqp: nqp::deb(1,"hi"); #whoops | 16:21 | |
camelia | nqp: OUTPUT«Error while compiling block : Error while compiling op deb (source text: "nqp::deb(1,\"hi\")"): No registered operation handler for 'deb'current instr.: '' pc 55082 (src/stage2/QAST.pir:20123) (src/stage2/QAST.nqp:3316)» | ||
[Coke] | shame, there was a lot of documentation for that opcode in the old doc file. | ||
japhb__ | TimToady: if Perl 5 was assuming a powers-of-two allocator would be used anyway, why bother to only grow the array by 5/4? Why not always grow by 2? | 16:22 | |
moritz | list vs. hash? | ||
TimToady | hashes always grow by 2 | 16:23 | |
(in p5) | |||
moritz | it's much more costly to rehash a hash than to to grow a list | ||
TimToady | though p5 does tricks to make that fairly cheap too | ||
it's obvious from the masked hash value which entries to copy and which to leave | |||
since doubling the hash table merely means you're paying attention to one more already-existing bit | 16:24 | ||
japhb__ | No, my point is, what does it actually *gain* to use 5/4 as the array growth ratio? I can see that 5 is relatively prime to 2, but what magical property does that bring? | ||
TimToady | we don't actually ever "rehash" | ||
it guarantees growth if you start at 4 :) | |||
and is still quite parsimonious with memory on systems where you're rather copy than overallocate | 16:25 | ||
japhb__ | Okay ... but why not 2 as the growth ratio, if that's the allocation ratio? | ||
TimToady | it doesn't try to guess which malloc is in use | ||
japhb__ | Were the small-object pools not power-of-two? | ||
Ah! | |||
TimToady | I think it was powers of two up to some value | 16:26 | |
then it was ad hoc | |||
japhb__ | gotcha. | ||
TimToady | well, the BSD allocator I stole :) | ||
SysV malloc was stingier | |||
japhb__ | The great thing about BSD is how very hard it is to steal from them. :-) | ||
TimToady | people on SysV with sufficient memory tended to pick Perl's malloc over the system malloc anyway | 16:27 | |
but the other reason p5 could be relatively stingy and biased towards copying was that it did a lot more to remember what happened last time | 16:29 | ||
calling the same subroutine would tend to reuse the storage from last time | |||
at least, calling the same subroutine at the same recursion level would | 16:30 | ||
that was another reason to bias in favor of assuming small initial sizes | 16:31 | ||
one would not really have to keep around the actual data structure like p5 did, just remember how big it got last time in similar situations | 16:32 | ||
though keeping it around does save the cost of reallocating | |||
might not be practical with the way frames are handled now though | 16:33 | ||
though if we made frames by cloning a protoframe, the protoframe could probably be tweaked with that info | 16:34 | ||
slava | does perl6 have 'thunks' ? | 16:37 | |
TimToady | not as first class items yet | ||
we use thunks all the time though | |||
$a || $b <- RHS is a thunk | 16:38 | ||
has $.foo = stuff; # stuff is a thunk | |||
dalek | p: c659ef3 | coke++ | docs/nqp-opcode.txt: Remove old nqp op list. We now have a test (t/docs/*) that provides a list of codes from the vms. Other comments in here are design considerations that are now resolved, and docs for an obsolete opcode. See docs/ops.markdown going forward. |
||
p: 18f113a | coke++ | docs/ops.markdown: document most exceptional ops |
|||
TimToady | thunks are mentioned in S's 3, 4, 5, and 6 | 16:39 | |
[Coke] | 3 ops now that are in the docs, but don't exist in parrot: writefh, isfilelink, openasync | 16:41 | |
TimToady | arguments to macros are thunks, more or less | ||
except you can't call ASTs as code directly, afaik | 16:42 | ||
r: macro runlater ($a) { macro runnow { $a }; runnow }; runlater(say hi) | 16:49 | ||
camelia | rakudo 61580f: OUTPUT«===SORRY!===too few positional arguments: 2 passed, 3 (or more) expected» | ||
16:50
colomon joined
|
|||
TimToady | r: macro runlater ($a) { macro runnow() { $a }; runnow() }; runlater(say hi) | 16:50 | |
camelia | rakudo 61580f: OUTPUT«===SORRY!===too few positional arguments: 2 passed, 3 (or more) expected» | ||
TimToady | hmm | ||
16:51
stevan_ joined
16:55
ajr_ left
|
|||
TimToady | r: macro runlater ($a) { $a }; runlater(say 'hi') | 16:55 | |
camelia | rakudo 61580f: OUTPUT«hi» | ||
slava | what about my $a := somecode(); | ||
not a thunk? | |||
TimToady | that's just calling somecode and binding the results | 16:56 | |
the question is, how do you get something called 'somecode' that isn't a block or routine | 16:57 | ||
slava | TimToady: I am not smart enough to answer that :P | 16:58 | |
moritz | eval! | ||
TimToady wonders if adding more exclamation marks will make it more sensical... | 17:00 | ||
17:01
colomon left
|
|||
TimToady | how does the compiler turn an AST into a thunk, for || and such? | 17:01 | |
and should we spec that? | 17:02 | ||
or provide a first-class API to thunks? | |||
slava | TimToady: I hope those questions are not intended for me ... | ||
TimToady | no, they're aimed more at everyone :) | ||
diakopter | nqp-m: my int $i := 200_000_000; while --$i { nqp::iscclass(pir::const::CCLASS_ALPHABETIC, "«", 0); } | 17:03 | |
camelia | nqp-moarvm: OUTPUT«To compile on the MoarVM backend, QAST::VM must have an alternative 'moar' or 'moarop'as_mast» | ||
slava | ahh, good, then I will just stay quiet and read. :) | ||
moritz | TimToady: I guess I just missed some context | ||
TimToady: and IMHO it would be helpful to have some API to turn an AST into a code object | |||
TimToady hands moritz some more excalamation marks | 17:04 | ||
*excl | |||
moritz | preferably with a mechanism to provide the context in which it is compiled | ||
r: !!! | |||
camelia | rakudo 61580f: OUTPUT«Stub code executed in block at /tmp/Q7QcyE5TCo:1» | ||
TimToady | well, a macro is the natural place to gather that info, if we can type the argument to Thunk as well as AST | 17:05 | |
we'll probably end up with mixed macros that can return any of AST, Thunk, or already-evaluted data | |||
(for each parameter) | 17:06 | ||
17:07
broquain1 is now known as broquaint
|
|||
TimToady | alternately, always supply ASTs, but make it obvious and easy how to compile and/or run bits of AST | 17:14 | |
diakopter | nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { if ($k <= 0) { return $x4() + $x5() }; my $B := sub () { $k:=$k-1; A($k, $B, $x1, $x2, $x3, $x4) }; $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )) | ||
[Coke] | can someone explain why pow_I needs 2 types? (what do each of them do?) looks like the first one is result type... | ||
camelia | nqp-moarvm: OUTPUT«-35602» | ||
diakopter | jnthn: ^ that result is wrong O_O | ||
moritz | [Coke]: pow_I with negative power boxes into a Num | 17:15 | |
[Coke]: and with a postive power returns Int | 17:18 | ||
but since nqp doesn't know anything about Int and Num, we have provide those type objects so that nqp knows what to return | |||
[Coke] | moritz: danke. | 17:19 | |
timotimo | diakopter: how come you can just --$i on nqp on moar? | 17:21 | |
oh. was that not working a limitation of rakudo only? | 17:22 | ||
dalek | p: e0bc2b7 | coke++ | docs/ops.markdown: Fixup docs for some _I ops moritz++ |
17:26 | |
[Coke] | .to pmurias - fixed the existing _I opcodes i the docs. | ||
yoleaux | [Coke]: I'll pass your message to pmurias. | ||
17:30
FROGGS[mobile] left
17:34
rindolf left
17:36
FROGGS[mobile] joined
17:37
nine_ left
17:38
nine joined
17:39
jnap left
|
|||
diakopter | timotimo: someone (jnthn?) added it to all the NQPs a few months ago | 17:42 | |
17:42
nine left
17:43
nine joined
17:44
ajr joined,
ajr is now known as Guest42820
17:45
Guest42820 is now known as ajr_
|
|||
timotimo | oh nice | 17:54 | |
diakopter | nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { --$k; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )); | 18:01 | |
camelia | nqp-moarvm: OUTPUT«-35600» | 18:02 | |
diakopter | jnthn: !!!!! another wrong (and different) result... | ||
18:02
SmokeMachine left
|
|||
diakopter | nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )); | 18:02 | |
camelia | nqp-moarvm: OUTPUT«-35601» | 18:03 | |
diakopter | *sigh* | ||
arnsholt | That's the man or boy test, isn't it? | ||
diakopter | timotimo: well there you go, problem with the -- | ||
yep | |||
-35,601 is the correct answer | |||
jnthn: bug: $k-- doesn't do the same thing as $k := $k - 1 | 18:04 | ||
er, --$k | |||
if I had to guess, it does decrement the local, but not the lexical or something | 18:05 | ||
timotimo | .o( my lexical to local optimisation hasn't hit master, right? ) | 18:13 | |
.o( of course it hasn't! ) | |||
ajr_ | If you have a little spare time, and/or care about Unicode, you might wander over to The Register for a look at this: www.theregister.co.uk/2013/10/04/ve...b_unicode/ For all the levity, there's some meat there and in the comments. | 18:17 | |
diakopter | ajr_: yeah, but Perl 6 has dynamic per-string and/or per-interpreter codepages, with mappings to hopefully fit entirely in 8-bits | 18:23 | |
ajr_ | Maybe that's a marketing slogan, for some definitions of "market"? :-)* | 18:24 | |
diakopter | ... fsdo "has" | 18:27 | |
bbl | |||
timotimo | hehe. | ||
18:28
FROGGS[mobile] left
|
|||
arnsholt | ajr_: Whee! That was a fun rant =D | 18:32 | |
ajr_ | Verity is usually good for that. | ||
geekosaur tempted to say right but for the wrong reasons | 18:34 | ||
utf16/ucs2 is kinda the worst of both worlds | 18:35 | ||
since if you're doing significant CJK you will probably find yourself wishing for UTF32, and if not you probably prefer UTF8 :) | |||
dalek | kudo/nom: 01c2e2a | (Elizabeth Mattijsen)++ | src/core/ (6 files): Initial implementation of .grab for Set/Bag/Mix |
18:36 | |
geekosaur thinks about a string representation that can use utf32 or utf8 as appropriate | 18:37 | ||
lue | hello world o/ | ||
timotimo | grab is for when you want to change a random element out of the bag? | ||
lue | geekosaur: utf16 would be so much better if it worked like utf8 | ||
timotimo | er, "a bunch of random elements" rather | 18:38 | |
geekosaur | indeed | ||
lizmat | timotimo: yes | ||
timotimo | mhm, interesting | ||
lizmat | well, not change, | ||
remove from | |||
timotimo | there's a "BIND" involved... so i thought it's for changing stuff | ||
but okay | |||
18:38
kbaker left
|
|||
timotimo | ah, i see how it works | 18:39 | |
lizmat | well, I just called it BIND because .pick and .grab are *very* similar | ||
lue | .oO(We would also get characters past 0x10_FFFF) |
||
18:40
darutoko left
|
|||
timotimo | did the fixes to make the classfile/jast writing faster hit yet? are they in some branch i could try out? | 18:44 | |
currently takes 22s for the jast stage and 5.8s for the classfile stage | |||
slava | is there any prediction on when moarvm will be distributed with rakudo star? | 18:48 | |
grondilu | slava: hopefully next month, IIRC | 18:50 | |
PerlJam | slava: I predict that the 2014-06 release of R* will have moarvm. :-) | ||
PerlJam makes an upper bound, but not a least upper-bound | |||
lue | Where is MoarVM right now? Can NQP self-compile on it yet? | 18:51 | |
grondilu | not yet | ||
lizmat | but pretty damn near, is my impression | 18:52 | |
grondilu | nqp runs on moarvm and passed all nqp tests. Now the team is working on bootstraping | ||
(that is compiling itself, not with the cross-compiler) | |||
dalek | kudo/nom: 0a2efdb | (Elizabeth Mattijsen)++ | src/core/Baggy.pm: For some reason, one must specify $_ here? Otherwise: No such method 'key' for invocant of type 'Nil' in method pick at src/gen/CORE.setting:15268 in block at t/spec/S02-types/bag.rakudo.parrot:281 |
18:54 | |
lue can't wait to replace the norewegian blue with MoarVM for his rakudo-ing | |||
lizmat too | |||
18:55
bluescreen10 joined
|
|||
lue | s/nore/nor/ | 18:56 | |
grondilu | there hasn't been any commit on MoarVM lately. What's up? | ||
'norwegian blue' ? | 18:57 | ||
grondilu doesn't get the reference | |||
timotimo | lizmat: seems like it would be parsed as a hash rather than a code block if you don't use $_ | ||
r: { .key => .value }.WHAT.say | |||
camelia | rakudo 61580f: OUTPUT«No such method 'key' for invocant of type 'Nil' in block at /tmp/e67ZvmRSKz:1» | ||
PerlJam | grondilu: I thought it was a parrot. | ||
timotimo | r: $_ = (a=>1); { .key => .value }.WHAT.say | ||
camelia | rakudo 61580f: OUTPUT«(Hash)» | ||
timotimo | r: $_ = (a=>1); { $_.key => $_.value }.WHAT.say | 18:58 | |
camelia | rakudo 61580f: OUTPUT«(Block)» | ||
btyler | monty python joke: en.wikipedia.org/wiki/Dead_Parrot_sketch | ||
lizmat | they stun easily | ||
timotimo: ah, indeed, timotimo++ | |||
lue | grondilu: see btyler's message a couple lines up. | 19:01 | |
btyler | (although, really, reading the wiki article about it is a sure way to kill the joke...it's on youtube and worth the few minutes :) | 19:03 | |
lue thinks he's using the phrase "norwegian blue" similar to how people use "the scottish play". For some reason he has the silly notion saying "Parrot" is likely to cause trouble. | 19:05 | ||
19:05
lesshaste joined
|
|||
lesshaste | hi | 19:05 | |
what's the main aim of perl 6 ? | |||
grondilu | lue: btyler: yup got it | 19:06 | |
lesshaste: the same as perl 5, only in a more modern way. As I understand it, anyway. | 19:07 | ||
lesshaste | grondilu, in what way modern ? :) | 19:08 | |
I think you just moved my question to the word modern :) | |||
grondilu | rather "postmodern", as once explained by TimToady | ||
PerlJam | lesshaste: have you seen perl6.org yet? | ||
lesshaste | yes | ||
it is short on the "why?" | |||
slava | lesshaste: because perl6 is better | 19:09 | |
PerlJam | lesshaste: Perl5 had some warts; Perl6 was a way to fix them in a backwards incompatible way. | ||
grondilu | wall.org/~larry/pm.html | ||
19:10
SamuraiJack__ joined
|
|||
PerlJam | lesshaste: for instance, Perl 6 has pervasive laziness. You can't get that in Perl 5 without some deep changes to the language. | 19:10 | |
lesshaste: same thing for the re-imagining of regular expressions as "grammars" | |||
lesshaste | oh dear | ||
that makes the author look insane | |||
PerlJam | lesshaste: same thing for the object model. | ||
(though p5-mop is an excellent start at giving p5 a real, built-in object model) | 19:11 | ||
timotimo | lesshaste: where have i seen your nickname before? o_O | ||
lesshaste | moresped? | 19:12 | |
19:13
lesshaste left
|
|||
timotimo | o_O | 19:13 | |
geekosaur | they were just asking about timing in #haskell earlier today | 19:16 | |
19:17
FROGGS joined
|
|||
geekosaur | also that last exchange... "less haste more speed" which I think I first encountered in LOtR (the innkeeper at Bree, I think) | 19:18 | |
dalek | kudo/nom: 4fd3721 | (Elizabeth Mattijsen)++ | src/core/Setty.pm: We need Set.grab to return a List, rather than a Parcel |
19:32 | |
19:32
kaare_ joined,
SamuraiJack__ left
|
|||
tipdbmp | How can I pretty print something (array, hash, etc.), what's Perl 6's Data::Dumper or even better Data::Printer? | 19:36 | |
PerlJam | tipdbmp: $thingy.perl | 19:37 | |
r: my @a = <foo bar baz>; say @a.perl; | |||
camelia | rakudo 0a2efd: OUTPUT«Array.new("foo", "bar", "baz")» | ||
tipdbmp | Yes, I knew that but I wouldn't call that pretty. | ||
PerlJam | r: my @a = <foo bar baz>; say @a.gist; | ||
camelia | rakudo 0a2efd: OUTPUT«foo bar baz» | ||
PerlJam | better? | ||
PerlJam doesn't know what sort of "pretty" you're looking for. | |||
or ... I wouldn't call Data::Dumper pretty either | 19:38 | ||
19:39
risou is now known as risou_awy
|
|||
FROGGS | o/ | 19:39 | |
tipdbmp | PerlJam, maybe in indent mode 2 or 3, but what I mean by pretty is to have \n and ' ' indentation, .perl is a single line? | 19:40 | |
lizmat | TimToady: just wondering, since we have an .Array coercer, shouldn't .list also be .List ? | ||
PerlJam | tipdbmp: I think you'll have to write a module to get that version of "pretty" | 19:41 | |
19:42
raiph left
|
|||
tipdbmp | Hm, okay =). | 19:43 | |
19:45
jnap joined
19:46
japhb_ left
19:47
kaare_ left
|
|||
benabik | Hm. Does { .foo } not imply a $_ in the block? Should it? | 19:57 | |
19:57
not_gerd joined
19:58
japhb_ joined
|
|||
timotimo | well, how do you do { .key => .value } if you actually want the outer $_'s .key and the outer $_'s value? | 19:58 | |
TimToady | S04:1637 | ||
synopsebot | Link: perlcabal.org/syn/S04.html#line_1637 | ||
TimToady | you use a temporary in that case | ||
benabik | So judging from 0a2efdb, it's a Rakudobug? | 19:59 | |
timotimo | huh? | ||
TimToady | I believe it's been reported, but I could be wrong... | ||
not_gerd | tipdbmp: see gist.github.com/gerdr/6831810 for some code that indents .perl output | ||
dalek | ast: adcc1c7 | (Elizabeth Mattijsen)++ | S02-types/ (4 files): Add Set/Bag tests for .grab and .total |
20:01 | |
ast: 57a3771 | (Elizabeth Mattijsen)++ | S02-types/ (4 files): Fudging for niecza / pugs for .total and .grab tests |
|||
TimToady | lizmat: you really don't want me to make design decisions while I have a migraine... | 20:02 | |
even if it's the relatively painless sort | |||
lizmat hopes the migraine will soon go away, not just because of design decisions | 20:03 | ||
:-) | |||
timotimo | not_gerd: your code doesn't handle smileys in quoted text well, it seems to me | 20:04 | |
not_gerd | timotimo: what's your input data | 20:05 | |
20:08
raiph joined
|
|||
timotimo | sorry, i was just running the code in my head ;) | 20:09 | |
tipdbmp | not_gerd, thanks, it's something. | 20:15 | |
20:17
ssutch left
|
|||
TimToady | lizmat: but I'd say offhand that .list only requires that it return something that can act like a list, not necessarily a List | 20:19 | |
woolfy | We got a devroom at Fosdem 2014, Saturday, February 1, in Brussels: fosdem.org/2014/news/2013-10-02-ac...-devrooms/ (see also wendyga.wordpress.com/2013/09/23/fo...-speakers/ ) | ||
diakopter | woolfy: hi! | 20:20 | |
woolfy | I hope some people here want to come to Brussels and speak about Perl 6 in our Perl-devroom. I really hope Perl 6 will be represented. | ||
We got a devroom!!! | |||
diakopter: hi! | |||
diakopter | okay, so no particular group got more than 1 day | ||
TimToady | .oO(why would we want to de-vroom?) |
20:21 | |
woolfy | diakopter: indeed. Well, they have a limited number of rooms. They might add some more later on. But I am happy as it is that we got a devroom. | 20:22 | |
lue | .oO(I thought we were talking about d eVroom) |
||
woolfy | TimToady: because we have too much Vroom | ||
Vroom Vroom Vrooooooooom..... | |||
diakopter | woolfy: are you still accepting talk proposals for the Perl broom? | ||
woolfy | And since Perl is the solution to everything, Perl will also assist in this difficult matter. | ||
20:23
hummeleB1 left
|
|||
woolfy | diakopter: ehm, I just asked for proposals... :-) | 20:23 | |
"(10:19:55 PM) woolfy: I hope some people here want to come to Brussels and speak about Perl 6 in our Perl-devroom. I really hope Perl 6 will be represented." | |||
diakopter | oh, it says it was published 9/23 | ||
lizmat | TimToady: ok, whereas .Array would be a true coercer | ||
diakopter | oh, I issed hat essage | 20:24 | |
woolfy | Oh, my blog... well, yes, that blog was both about the main room (for which the deadline is passed) and our devroom (for which the deadline lays far into the future). | ||
TimToady | plus lists are sort of an honorary built-in native type, though not so much as in Perl 5... | ||
and lists are more about data flow, not data structure, in Perl | 20:26 | ||
lizmat | on that note: is there a reason why {} and [] slices return a Parcel, rather than a list ? | ||
TimToady | because they're generally more like tuplies of known arity | ||
20:26
stevan_ left
|
|||
TimToady | *tuples | 20:27 | |
lizmat | so shouldn't .pick / .roll / .grab not return Parcels as well ? | ||
TimToady | now you're asking for design again :) | 20:28 | |
there should be a smiley for "half my head feels like it's missing" | |||
.) | |||
lue | .oO( \c[RIGHT PARENTHESIS BOTTOM HALF] ) |
20:29 | |
lizmat | TimToady: sorry :-( I know I'm a pain in any normal kind of situation already :-) | 20:32 | |
TimToady | on camelia aliases, I suspect at some point we should retire pugs to not have a p alias, and instead have p, j, and m aliases for parrot, jvm, and moar, with r racing all three against each other | 20:36 | |
moritz | eventually, yes | 20:38 | |
TimToady | maybe with capitals for nqp | ||
or a modifier that just applies across the board | 20:39 | ||
just ideas from my right brane, which is happy it's not the side that makes decisions .) | 20:40 | ||
dalek | kudo/nom: c962e51 | (Elizabeth Mattijsen)++ | src/core/ (3 files): Make .total constant attribute for Set/Bag/Mix |
||
TimToady | does it even need to be an attribute? | 20:42 | |
if the total method just closes over the role parameter? | |||
well, or over something calculated by the role, if not a parameter | 20:43 | ||
lizmat is stupid, a state var will do the trick nicely and be cheaper if not used | |||
TimToady | I suppose there's not much harm in storing one number with the rest of the data | ||
partly why I was thinking the immutable form was a different role than the mutable | 20:44 | ||
20:45
BenGoldberg joined
20:46
konundra joined
|
|||
lizmat | submethod total { state $total = [+] self.values } # would also do the trick, and be without burden to the object if not used | 20:48 | |
hmmm… perhaps not | 20:56 | ||
moritz | nah, state isn't scoped per instance | 20:57 | |
but rather per closure clone | 20:58 | ||
lizmat | indeed :-( | ||
20:58
skids left
21:03
konundra left
|
|||
lizmat | ok leaving that idea for future optimizers :-) | 21:04 | |
21:05
denis_boyun left
21:08
donaldh joined
|
|||
dalek | kudo/nom: 9f6f443 | (Elizabeth Mattijsen)++ | src/core/ (2 files): Burdening all Set/Bag objects with .total calculation, doesn't make sense |
21:10 | |
21:12
ssutch joined
21:18
not_gerd left
|
|||
donaldh | jnthn: does eliminating priorInvocation on JVM require jnthn-fu ? | 21:25 | |
21:25
Mouq joined
|
|||
Mouq | #perl6++ | 21:25 | |
diakopter | donaldh: O | 21:27 | |
donaldh: I'd guess if you studied the relevant commits in moarvm, you could figure it out | |||
donaldh | diakopter: yes, I'm thinking the same. | 21:28 | |
diakopter | they're pretty small/few iirc | 21:29 | |
donaldh | Oh, it was just at the weekend. | ||
Mouq | nqp-m: nqp::say('hi') # :D | 21:31 | |
camelia | nqp-moarvm: OUTPUT«hi» | ||
dalek | rlito: a204083 | (Flavio S. Glock)++ | misc/pretty_print.pl: Perlito5 - pretty-printer AST |
21:32 | |
rlito: 913bc28 | (Flavio S. Glock)++ | misc/pretty_print.pl: Perlito5 - pretty-printer precedence |
|||
rlito: e1b541e | (Flavio S. Glock)++ | misc/pretty_print.pl: Perlito5 - pretty-printer precedence, special cases |
|||
donaldh | Okay, so closure changes in nqp then codegen changes required to make use of it in backend. | 21:36 | |
21:40
bruges left
21:43
bruges joined
21:46
benabik left
21:52
Ben_Goldberg joined
21:53
BenGoldberg left
|
|||
dalek | kudo/nom: be96b97 | (Elizabeth Mattijsen)++ | src/core/Mixy.pm: Make sure that Mixy allows for negative values when building |
21:58 | |
kudo/nom: 560b416 | (Elizabeth Mattijsen)++ | src/core/Baggy.pm: Make sure we coerce multiplication factors to Int for Baggy |
22:02 | ||
kudo/nom: 4b41c01 | (Elizabeth Mattijsen)++ | src/core/ (4 files): Make sure Mixy / Baggy coerce correctly to each other |
22:12 | ||
22:21
skids joined
22:28
btyler left
|
|||
TimToady | we should probably add an optional key type to those roles at some point | 22:31 | |
lizmat | hmmm… why not now ? | 22:33 | |
TimToady | now is a point...oh wait, now it's in the past :) | ||
lizmat | well, maybe not today, trying to finish up Mix/MixHash tests before sleep | 22:34 | |
diakopter reads MixMaster | 22:35 | ||
lizmat | r: my $m=MixHash.new; $m<d>--; say $m # should we allow decrementing on non-existent elements in a MixHash ? | 22:36 | |
camelia | rakudo 560b41: OUTPUT«MixHash.new(d(-1))» | ||
lizmat | I guess it makes sense since we allow negative values | 22:37 | |
22:37
REPLeffect left
|
|||
lizmat | only 0 makes elements disappear | 22:37 | |
TimToady | make sense to me | ||
(design brane is starting to wake up a little) | |||
diakopter | nqp: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )); | ||
camelia | nqp: OUTPUT«maximum recursion depth exceededcurrent instr.: '' pc 262 ((file unknown):60546898) (/tmp/5Sshcl1doW:1)» | ||
diakopter | mwahaha | 22:38 | |
nqp-jvm: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(18, K(1), K(-1), K(-1), K(1), K(0) )); | |||
22:38
REPLeffect joined
|
|||
camelia | nqp-jvm: OUTPUT«Unhandled exception: java.lang.StackOverflowError in  in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A i…» | 22:38 | |
diakopter | mwahaha | ||
there's the benefit of moarvm | |||
well, one of them | |||
(yes, I know you can turn off the recursion limit on parrot) | |||
(but that's not how its distributed) ;) | 22:39 | ||
*it's | |||
donaldh | and increase the stack on JVM | ||
diakopter | true. | ||
dalek | p: bb33397 | (Donald Hunter)++ | src/vm/jvm/runtime/org/perl6/nqp/runtime/CompilationUnit.java: Avoid allocating zero length arrays in CodeRef. |
22:41 | |
p: 5ef6bcc | (Donald Hunter)++ | src/vm/jvm/runtime/org/perl6/nqp/sixmodel/reprs/VMArray.java: Presize arrays when deserializing. |
|||
p: 5cab6ef | (Donald Hunter)++ | src/vm/jvm/runtime/org/perl6/nqp/sixmodel/reprs/VMArrayInstance.java: Allow min size of VMArrayInstance to be 4 elems. |
|||
diakopter | nqp-jvm: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(12, K(1), K(-1), K(-1), K(1), K(0) )); | 22:42 | |
camelia | nqp-jvm: OUTPUT«Unhandled exception: java.lang.StackOverflowError in  in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A in  in A i…» | ||
diakopter | nqp-jvm: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(8, K(1), K(-1), K(-1), K(1), K(0) )); | 22:43 | |
camelia | nqp-jvm: OUTPUT«0» | ||
diakopter | wrong; the correct answer is -10 | ||
nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(8, K(1), K(-1), K(-1), K(1), K(0) )); | |||
camelia | nqp-moarvm: OUTPUT«-10» | ||
diakopter | whoa that was fast | ||
nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(8, K(1), K(-1), K(-1), K(1), K(0) )); | |||
camelia | nqp-moarvm: OUTPUT«-10» | ||
diakopter | nqp-m: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(8, K(1), K(-1), K(-1), K(1), K(0) )); | ||
camelia | nqp-moarvm: OUTPUT«-10» | ||
diakopter | bleh | ||
well ok | 22:44 | ||
nqp: sub A($k, $x1, $x2, $x3, $x4, $x5) { return $x4() + $x5() if $k <= 0; my $B := sub () { $k := $k - 1; return A($k, $B, $x1, $x2, $x3, $x4) }; return $B() }; sub K($n) { sub () { $n } }; say(A(8, K(1), K(-1), K(-1), K(1), K(0) )); | |||
camelia | nqp: OUTPUT«0» | ||
diakopter | ha; nqp on rakudo gets it wrong too | ||
er. | |||
nqp on parrot. | |||
donaldh | :) | ||
diakopter | .oO( you know someone is performance obsessed when the regression suite of the vm included the man-or-boy benchmark from the earliest days... ) |
22:45 | |
jnthn | diakopter: Oh, I was mostly happy to see it from the point of view of testing closure semantics. | 22:46 | |
donaldh: You can probably make quite some headway from the moar patches | |||
diakopter | jnthn: see nqp on parrot and jvm get the answer wrong | ||
dalek | ast: a33884d | (Elizabeth Mattijsen)++ | S02-types/ (4 files): Added tests for Mix/MixHash and fixed some Bag/BagHash tests |
||
donaldh | jnthn: yeah, needs more time to grok the moar patches than I have this weekend. | ||
jnthn | donaldh: OK, no hurry :) | 22:47 | |
lizmat | that's 300+ more tests | ||
diakopter hopes that leads donaldh to start contributing to moar.. | |||
donaldh is happy in jvm land for now. | |||
diakopter | lizmat: whoa | ||
lizmat | mostly cat-licensing | 22:48 | |
diakopter | say "We do get here, right?"; | ||
jnthn | lizmat: Nice! Glad we're adding test coverage :) | ||
ingy | sorear: pings | 22:51 | |
donaldh | can I push directly from the same git branch to master more than once? | ||
ingy | sorear: could you drop by freenode #yaml | 22:52 | |
donaldh | i.e. using git push origin mybranch:master ? | ||
dalek | p: 464b5d4 | (Donald Hunter)++ | src/vm/jvm/runtime/org/perl6/nqp/runtime/StaticCodeInfo.java: Avoid allocating HashMaps when lexical vars are null. |
22:54 | |
donaldh realised it was a kinda silly question | 22:55 | ||
goodnight o/ | 22:57 | ||
22:57
donaldh left
|
|||
dalek | kudo/nom: 93c6271 | (Elizabeth Mattijsen)++ | t/spectest.data: Make sure we run the Mix/MixHash tests as well |
22:58 | |
lizmat | and on that thought, I wish everybody a good * | 22:59 | |
and get some shuteye& | |||
jnthn | 'night, lizmat++ | ||
23:01
raiph left
23:02
bbkr__ left
23:06
bbkr__ joined
23:11
raiph joined
|
|||
dalek | rlito: 24620a5 | (Flavio S. Glock)++ | / (6 files): Perlito5 - perl5 - new pretty-printer backend |
23:11 | |
ingy | anyone here use Mono? | 23:31 | |
23:34
ajr_ left
|
|||
TimToady | n: say "Hi, Ingy, from mono." | 23:34 | |
camelia | niecza v24-98-g473bd20: OUTPUT«Hi, Ingy, from mono.» | ||
ingy | TimToady++ | 23:35 | |
I am trying to figure out how to run csharp 1liners from commandline | 23:36 | ||
it has a repl | |||
TimToady | csharp would be more jnthn++'s bailiwick | 23:37 | |
ingy | well I think it's more mono than c# | ||
thus my pining for sorear | 23:38 | ||
jnthn | Hm, wasn't aware of a repl, but I'm almost always using the MS toolchain rather than Mono. | ||
TimToady | sorear++ has been kinda heads down at his job lately | 23:39 | |
ingy | echo 'Console.WriteLine ("hello");' | csharp | ||
# FTW! | |||
jnthn | That works? :) | ||
ingy | :D | ||
jnthn | Nice :) | ||
ingy | it was just a guess but it works | 23:40 | |
jnthn | afaik, csc always wants the boring boilerplate... :) | ||
ingy | I made this: gist.github.com/ingydotnet/6833981 | 23:41 | |
script for multi-loading yaml | |||
ingy has climbed back into the helm of the yaml ship this week | |||
and pushing forward with YAML2 | 23:42 | ||
one thought is to write a reference y2 implementation in p6 | |||
diakopter | jnthn: any ideas why that man-or-boy one-liner fails in nqp parrot & jvm? | 23:43 | |
ingy | there are a few reasons why I want to do that | ||
jnthn | diakopter: no | ||
diakopter: No idea if it's closure related or not | 23:44 | ||
diakopter: If it is, JVM is having changes there soon anyway | |||
diakopter: So can revisit it then. | |||
23:47
raiph left
|
|||
jnthn | time for some rest...'night o/ | 23:47 | |
[Coke] | nqp-moar: say(3); # where is this coming from? | 23:56 | |
nqp-moarvm: say(3); # where is this coming from? | |||
camelia | nqp-moarvm: OUTPUT«3» | ||
[Coke] | it's not in nqp yet... | 23:57 |