»ö« 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. |
|||
diakopter | japhb: ^ that's a long time from now | 00:00 | |
japhb | timotimo: Yeah, that's an irssi fail. xchat-gnome was smart enough to highlight any fallback variant of your nick. | ||
00:00
japhb is now known as japhb_
|
|||
japhb_ | botsnack | 00:00 | |
yoleaux | 2 Sep 2014 00:34Z <timotimo> japhb_: I'm still wondering why the benchmark plots don't disappear when there is 0 data at all, like the non-nqp-implemented benchmarks in a pure-nqp-comparison | ||
2 Sep 2014 00:37Z <timotimo> japhb_: i wonder when it'll be time to re-implement the perl5 portions of p6bench in pure perl6 :) | |||
2 Sep 2014 14:45Z <brrt> japhb_: i'm back (for 45 minutes or so) | |||
timotimo | .in 5d ermergerd blergperst! | 00:01 | |
yoleaux | timotimo: I'll remind you on 8 Sep 2014 00:01Z | ||
japhb_ | Gah, 3 missed messages. | ||
timotimo | maybe yoleaux can be taught some nicks belong to the same person? | ||
japhb_ wonders if yoleaux can be taught how to detect nicks owned by the same human, since registering a nick allows that. | |||
heh | 00:02 | ||
timotimo | %) | ||
diakopter | .wa japhb | 00:03 | |
timotimo | japhb_: have you thought about where a functionality to run a single scale of all benchmarks in a row, perhaps without swallowing the output? | ||
yoleaux | diakopter: Sorry, that command (.wa) crashed. | ||
timotimo | so that i can a) verify nothing crashes, b) extract spesh and/or jit logs and/or profiles | ||
diakopter | .wa timotimo | 00:04 | |
yoleaux | Timothy (male given name): Information for US births: rank: 125th; fraction: 1 in 663 people (0.15%); number: 3016 people per year (US data based on 2013 births and other SSA registrations in the US); Estimates for current US population: expected total number alive today: 980815 people; expected population fraction: 1 in 245 people (0.41%); expected rank: 32nd; most common age: 51 years; (using standard US mortality data) | ||
diakopter | .wa TimToady | ||
japhb_ | OK, second question first: It'll be time to do the reimplementation of timeall when I trust timing results from Rakudo as much as I do from perl5. Which will be a while, I think. And reimplementing analyze will basically wait until parsing JSON is as fast in Rakudo as it is in perl5. | ||
yoleaux | Timothy (male given name): Information for US births: rank: 125th; fraction: 1 in 663 people (0.15%); number: 3016 people per year (US data based on 2013 births and other SSA registrations in the US); Estimates for current US population: expected total number alive today: 980815 people; expected population fraction: 1 in 245 people (0.41%); expected rank: 32nd; most common age: 51 years; (using standard US mortality data) | ||
00:05
chenryn joined
|
|||
timotimo | .tell brrt i wonder why i didn't get any inlines at all in the previous instance i tried it, but now i do see inlines show up in the jitlog. maybe it only shows inlines if it has deopt points nearby? | 00:05 | |
yoleaux | timotimo: I'll pass your message to brrt. | ||
japhb_ | timotimo: I'm not sure what you mean about the single scale of all benchmarks in a row. (The first interpretation of that question that comes to mind makes no sense, so clearly I'm reading it wrong.) | ||
00:06
japhb_ is now known as japhb
|
|||
timotimo | aye, phrasing that wasn't easy %) | 00:06 | |
i'd like for the bench utility to run every benchmark a single time, but not start at the lowest scaling | |||
japhb | As for empty plots not disappearing, --skip-incomplete may get you what you want | 00:08 | |
timotimo | didn't last time i tried it :( | ||
japhb | timotimo: Given how widely varying the scaling starting points are, how do you propose to choose the scaling they run at? A fixed number of increments above the starting scale? (E.g. running at 3 increments above would make a test with scale => 1 << 7 start at 1 << 10) | 00:09 | |
timotimo: Hmmm, that's odd. | |||
timotimo | i thought so, too :) | ||
let me retry that | |||
00:09
bjz_ left
00:10
bjz joined
|
|||
japhb | TBH, I may not have tested it with 'bench --format=html_plot compare' but rather with 'bench --format=html_plot history' | 00:10 | |
So it may never have worked for standard comparison plots. :-( | 00:11 | ||
Or to be more precise, bench --format=html_plot --skip-incomplete compare' | |||
GAH, you know what I mean. | 00:12 | ||
diakopter | .gcs "japhb" "TimToady" | 00:13 | |
yoleaux | [site] "japhb" (121,000), "TimToady" (50,200) | ||
timotimo | :) | ||
00:13
mberends joined
|
|||
timotimo | i just found out what i've been doing wrong with bindattrs_* and getattrs_* | 00:13 | |
diakopter | .gc mberends | ||
timotimo | one of these "how could that ever have worked?!" pieces | ||
yoleaux | 13,200 (site), 1,420 (api) | ||
japhb wonders how the heck he ended up with a higher gcs than TimToady, and suspects complete the results are complete BS | 00:16 | ||
s:1st/complete // | 00:17 | ||
timotimo | gcs? | ||
japhb | timotimo: diakopter's query from a few minutes ago | ||
timotimo | yeah, but what is "gcs"? | 00:19 | |
japhb | dpk.io/yoleaux, upper left section (Google) | 00:20 | |
00:20
chenryn left
|
|||
timotimo | aah, it's like "google fight" | 00:21 | |
00:26
ajr_ left
|
|||
timotimo | .chars box | 00:29 | |
yoleaux | ⌧ ⍽ ⎸ ⎹ ␣ ─ ━ │ ┃ ┄ ┅ ┆ ┇ ┈ ┉ ┊ ┋ ┌ ┍ ┎ ┏ ┐ ┑ ┒ ┓ └ ┕ ┖ ┗ ┘ ┙ ┚ ┛ ├ ┝ ┞ ┟ ┠ ┡ ┢ ┣ ┤ ┥ ┦ ┧ ┨ ┩ ┪ ┫ ┬ ┭ ┮ ┯ ┰ ┱ ┲ ┳ ┴ ┵ ┶ ┷ ┸ ┹ ┺ ┻ ┼ ┽ ┾ ┿ ╀ ╁ ╂ ╃ ╄ ╅ ╆ ╇ ╈ ╉ ╊ ╋ ╌ ╍ ╎ ╏ ═ ║ ╒ ╓ ╔ ╕ ╖ ╗ ╘ ╙ ╚ ╛ ╜ ╝ ╞ ╟ ╠ ╡ ╢ ╣ ╤ ╥ … | ||
╦ ╧ ╨ ╩ ╪ ╫ | |||
timotimo | i didn't know this command and it's definitely useful! | ||
00:32
PZt left
00:35
chenryn joined
00:42
bjz left
00:50
chenryn left
00:59
_thou left
|
|||
nick_____ | so otter i believe that it would be an nice mascot speakerdeck.com/stevan_little/perl...a-dead-end | 01:00 | |
01:01
dolmen left
01:02
FROGGS_ joined,
nick_____ left
01:05
FROGGS left
01:10
avuserow joined
01:13
dayangkun joined
01:14
avuserow left
01:20
bcode is now known as we
01:27
avuserow joined
|
|||
dj_goku_ | ggoebel1111112: kind of reminds me of: www.nand2tetris.org | 01:38 | |
01:50
grondilu joined
01:51
nbrown__ joined
|
|||
grondilu | so normally we can define a class in its own file by starting with 'class Foo;' but if Foo is supposed to derive from an other role/class, how can we declare it? where to put the 'use Bar'? | 01:55 | |
oh I can just write 'use Bar; class Foo is Bar;' apparently | |||
(it's a bit redundant if you ask me) | 01:57 | ||
01:59
chenryn joined
02:02
nbrown__ left
02:03
noganex_ joined
02:06
noganex left
02:18
Alula_ left,
Alula_ joined
02:22
nbrown__ joined
|
|||
grondilu | m: class A { method WHICH { rand } }; my %h{A} of Real; # this works fine | 02:25 | |
camelia | ( no output ) | ||
grondilu | m: class A { method WHICH { rand } }; class B { has %h{A} of Real } # this doesn't | ||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/IhKV4fk0YxCannot call 'trait_mod:<of>'; none of these signatures match::(Mu:U $target, Mu:U $type):(Routine:D $target, Mu:U $type):(Variable:D $v, Any |c):(Variable:D $v, Mu:U $of)…» | ||
BenGoldberg | m: class A { method WHICH { rand } }; class B { has (%h{A} of Real) }; | 02:26 | |
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/FD3amJLb68Unable to parse expression in declarator; couldn't find final ')' at /tmp/FD3amJLb68:1------> thod WHICH { rand } }; class B { has (%h⏏{A} of Real) }; e…» | ||
02:26
nbrown__ left
02:27
raiph left
|
|||
TimToady | m: class A { method WHICH { rand } }; class B { has Real %h{A} } | 02:33 | |
camelia | ( no output ) | ||
TimToady | just doesn't like the 'of' form for some reason | ||
02:34
BenGoldberg left
|
|||
TimToady | mind you, you'll have a hard time looking up any number in that hash | 02:34 | |
m: m: class A { method WHICH { rand } }; my Real %h{A}; %h{42} = "hi there"; say %h{42}; # maybe this works | 02:37 | ||
camelia | rakudo-moar 41d7f7: OUTPUT«cannot stringify this in method assign_key at src/gen/m-CORE.setting:10054 in sub postcircumfix:<{ }> at src/gen/m-CORE.setting:2799 in block <unit> at /tmp/38DGe8Yq30:1» | ||
TimToady | m: m: class A { method WHICH { ~rand } }; my Real %h{A}; %h{42} = "hi there"; say %h{42}; # maybe this works | ||
camelia | rakudo-moar 41d7f7: OUTPUT«cannot stringify this in method assign_key at src/gen/m-CORE.setting:10054 in sub postcircumfix:<{ }> at src/gen/m-CORE.setting:2799 in block <unit> at /tmp/5XMdiswfEv:1» | ||
02:41
dayangkun left
|
|||
grondilu | "hard time looking up any number" because of the rand? I put it just for an example. Since A has to be a custom class to produce the bug. | 02:43 | |
02:43
_thou joined
|
|||
grondilu | m: class B { has %h{Int} of Real } | 02:43 | |
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/MyaxutE6_UCannot call 'trait_mod:<of>'; none of these signatures match::(Mu:U $target, Mu:U $type):(Routine:D $target, Mu:U $type):(Variable:D $v, Any |c):(Variable:D $v, Mu:U $of)…» | ||
grondilu | ah no. My bad | ||
grondilu has to admit he does not fully understand the difference between 'my Real %h{Foo}' and 'my %h{Foo} of Real' | 02:44 | ||
02:47
_thou left
03:02
telex left
03:04
telex joined
|
|||
xenoterracide | how do I print to stderr | 03:41 | |
TimToady | note is the simplest | 03:44 | |
$*ERR.print and such | 03:46 | ||
xenoterracide | TimToady: ty | 03:50 | |
04:04
rindolf joined,
[Sno] left
04:06
dayangkun joined
04:08
kaare_ joined
|
|||
grondilu | std: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A != A;' | 04:08 | |
camelia | std 53b3ca6: OUTPUT«===SORRY!===Unable to parse single quotes at /tmp/Gi_UUCAOyL line 1:------> ix:<==>(A $, A $) { False }; say A != A;⏏'Couldn't find final "'"; gave up at /tmp/Gi_UUCAOyL line 1 (EOF):------> x:<==>(A $, A $)…» | ||
grondilu | std: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A != A; | ||
camelia | std 53b3ca6: OUTPUT«ok 00:01 130m» | ||
grondilu | m: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A != A; | ||
camelia | rakudo-moar 41d7f7: OUTPUT«use of uninitialized value of type A in numeric context in block <unit> at /tmp/KuWR6fbevG:1use of uninitialized value of type A in numeric context in block <unit> at /tmp/KuWR6fbevG:1False» | ||
grondilu | n: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A != A; | ||
camelia | niecza v24-109-g48a8de3: OUTPUT«Potential difficulties: &infix:<==> is declared but not used at /tmp/dIKGt1pz8D line 1:------> ass A does Numeric { }; multi infix:<==>⏏(A $, A $) { False }; say A != A;Use of uninitialized value in numeric context…» | ||
grondilu | n: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A.new != A.new; | 04:09 | |
camelia | niecza v24-109-g48a8de3: OUTPUT«Potential difficulties: &infix:<==> is declared but not used at /tmp/TOiCjjkPDl line 1:------> ass A does Numeric { }; multi infix:<==>⏏(A $, A $) { False }; say A.new != A.newUnhandled exception: Cannot use value lik…» | ||
grondilu | m: class A does Numeric { }; multi infix:<==>(A $, A $) { False }; say A.new != A.new; | 04:10 | |
camelia | rakudo-moar 41d7f7: OUTPUT«(signal )» | ||
04:10
sidewinder27 joined
|
|||
grondilu | for &infix:<!=>, isn't there a fallback to &infix:<==> in Numeric? | 04:11 | |
(line 301 in Numeric.pm) | 04:12 | ||
04:17
raiph joined
|
|||
xenoterracide | class Logger does LoggerDebug does LoggerInfo (what's the shorter version of this?) | 04:28 | |
04:32
_thou joined,
chenryn left
04:36
_thou left
|
|||
xenoterracide | gist.github.com/xenoterracide/7cf9...3a7226b929 is my use of requires correct here? also private works like this right? | 04:36 | |
grondilu thinks it's 'require' not 'requires' | 04:40 | ||
std: require Foo; | 04:41 | ||
camelia | std 53b3ca6: OUTPUT«ok 00:01 121m» | ||
grondilu | std: requires Foo; | ||
camelia | std 53b3ca6: OUTPUT«===SORRY!===Undeclared name: 'Foo' used at line 1Undeclared routine: 'requires' used at line 1Check failedFAILED 00:01 121m» | ||
xenoterracide | so no need for the quotes either? | 04:44 | |
std: require log(); | 04:45 | ||
camelia | std 53b3ca6: OUTPUT«ok 00:01 123m» | ||
xenoterracide | std: require log( Str:D $message ); | 04:46 | |
camelia | std 53b3ca6: OUTPUT«===SORRY!===Two terms in a row at /tmp/sXItFxOqCw line 1:------> require log( Str:D ⏏$message ); expecting any of: infix or meta-infix infixed function statement modifier loopParse failedFAILED 00:…» | ||
04:49
chenryn joined
|
|||
grondilu | if you want to assert that your role "requires a method", you just stub it. | 04:58 | |
role Logger { method log {...} } | |||
or something like that | |||
'require' is a variant of 'use', it has little to do with role, mixins and stuff. It's about module importation. | 05:00 | ||
S11:323 | |||
synopsebot | Link: perlcabal.org/syn/S11.html#line_323 | ||
grondilu | m: role A { method foo {...} }; class B does A { }; | 05:02 | |
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!===Method 'foo' must be implemented by B because it is required by a role» | ||
grondilu | ^see? rakudo tells you that B *must* implement foo | ||
xenoterracide | grondilu: oh right | 05:03 | |
05:06
raiph left
05:13
mr-foobar left
05:16
SamuraiJack joined
05:27
[Sno] joined
05:38
xenoterracide left,
dayangkun left
05:49
xenoterracide joined
|
|||
grondilu | n: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2;' | 05:50 | |
camelia | niecza v24-109-g48a8de3: OUTPUT«===SORRY!===Bogus statement at /tmp/inUYvtSlYk line 1:------> ix:<*>(A $, A $) { rand }; say A.new**2;⏏'Parse failed» | ||
grondilu | std: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2;' | ||
camelia | std 53b3ca6: OUTPUT«===SORRY!===Unable to parse single quotes at /tmp/UALGYOzhoh line 1:------> ix:<*>(A $, A $) { rand }; say A.new**2;⏏'Couldn't find final "'"; gave up at /tmp/UALGYOzhoh line 1 (EOF):------> x:<*>(A $, A $) …» | ||
05:50
gfldex joined
|
|||
grondilu | std: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2; | 05:50 | |
camelia | std 53b3ca6: OUTPUT«ok 00:01 130m» | ||
grondilu | n: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2; | ||
camelia | niecza v24-109-g48a8de3: OUTPUT«Potential difficulties: &infix:<*> is declared but not used at /tmp/mpEeGO8whv line 1:------> class A does Numeric {}; multi infix:<*>⏏(A $, A $) { rand }; say A.new**2;Unhandled exception: Cannot use value like A as …» | ||
05:51
dolmen joined
|
|||
grondilu | p: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2; | 05:52 | |
camelia | rakudo-parrot 41d7f7: OUTPUT«maximum recursion depth exceededcurrent instr.: 'print_exception' pc 142790 (src/gen/p-CORE.setting.pir:61593) (gen/parrot/CORE.setting:11857)called from Sub 'Numeric' pc 232640 (src/gen/p-CORE.setting.pir:96683) (gen/parrot/CORE.setting:1058)ca…» | ||
grondilu | j: class A does Numeric {}; multi infix:<*>(A $, A $) { rand }; say A.new**2; | 05:53 | |
camelia | rakudo-jvm 41d7f7: OUTPUT«(timeout)» | ||
05:57
chenryn left,
anaeem1_ joined
06:00
anaeem1_ left
06:01
gfldex left
06:06
xenoterracide left
06:09
chenryn joined
06:11
mr-foobar joined
06:16
PZt joined
06:20
dolmen left
06:21
_thou joined
06:25
_thou left
06:27
domidumont joined
06:32
dayangkun joined
06:35
darutoko joined
06:37
sidewinder27 left,
dayangkun left
06:46
aindilis` left,
aindilis joined
06:48
sorear left
06:49
dayangkun joined
06:51
sorear joined
06:55
dayangkun left
06:57
kaleem joined,
virtualsue joined
07:03
dayangkun joined
07:04
eternaleye left
07:05
jaffa4 joined
|
|||
jaffa4 | hi | 07:05 | |
I have question concerning native call. Are callbacks supported? | 07:06 | ||
moritz | I think so, yes | ||
jaffa4: there's even a test file for callbacks in the NativeCall repo | 07:07 | ||
jaffa4 | The doc says they are going to be supporteed in the future | ||
The doc says they are going to be supported in the future | |||
moritz | then probably the docs are out of date | 07:09 | |
jaffa4 | zavolaj? | 07:10 | |
07:10
eternaleye joined
|
|||
moritz | zavolaj! | 07:12 | |
grondilu | m: role A {}; class B does A {}; multi f(A $a, $x) { f($x, $a) }; multi f($x, B $b) { $x }; say f B, pi;' | 07:13 | |
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/JZFqesm2LNUnable to parse expression in single quotes; couldn't find final "'" at /tmp/JZFqesm2LN:1------> multi f($x, B $b) { $x }; say f B, pi;'⏏<EOL> expectin…» | ||
grondilu | m: role A {}; class B does A {}; multi f(A $a, $x) { f($x, $a) }; multi f($x, B $b) { $x }; say f B, pi; | ||
camelia | rakudo-moar 41d7f7: OUTPUT«3.14159265358979» | ||
grondilu | role A { multi f(A $a, $x) is export { f($x, $a) } }; import A; class B does A {}; multi f($x, B $b) { $x }; say f B, pi;' | 07:14 | |
m: role A { multi f(A $a, $x) is export { f($x, $a) } }; import A; class B does A {}; multi f($x, B $b) { $x }; say f B, pi;' | |||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/j3jE0PGySPUnable to parse expression in single quotes; couldn't find final "'" at /tmp/j3jE0PGySP:1------> multi f($x, B $b) { $x }; say f B, pi;'⏏<EOL> expectin…» | ||
grondilu | m: role A { multi f(A $a, $x) is export { f($x, $a) } }; import A; class B does A {}; multi f($x, B $b) { $x }; say f B, pi; | ||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/lZLRwlWz5rCalling 'f' will never work with argument types (B, Num) Expected any of:  :(Any $x, B $b)at /tmp/lZLRwlWz5r:1------> es A {}; multi f($x, B $b) { $x }; say [33…» | ||
07:15
fdd__ joined
|
|||
grondilu | n: role A { multi f(A $a, $x) is export { f($x, $a) } }; import A; class B does A {}; multi f($x, B $b) { $x }; say f B, pi; | 07:15 | |
camelia | niecza v24-109-g48a8de3: OUTPUT«===SORRY!===Action method statement_control:import not yet implemented at /tmp/vMeb9Tv6vp line 1:------> $x) is export { f($x, $a) } }; import A⏏; class B does A {}; multi f($x, B $b) {Unhandled e…» | ||
fdd__ | hi could some one help me please I have no idea what I doing but I need to read a file x amount of pages long but I need to view page at a time. This code just makes it scroll off the screen in one go using putty justpaste.it/gxtw | 07:18 | |
thnaks | |||
07:19
we is now known as u
|
|||
grondilu | what do you mean by "page"? | 07:19 | |
I guess it's a constant number of lines, right? | 07:20 | ||
fdd__ | well i dont want the whole file to scroll by in one go | ||
i want to hit enter and read it by page at a time | 07:21 | ||
so yes a number of lines would be good | |||
as long as I can move on to the next number when i press enter | |||
grondilu | then make a counter and do a prompt every n lines | ||
07:23
virtualsue left
|
|||
fdd__ | ok thank you that gives me some thing google | 07:23 | |
grondilu | m: role A { multi f(A $a, $x) is export { $x } }; import A; class B does A {}; f B, pi;' | 07:24 | |
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/KWa__n0GBxUnable to parse expression in single quotes; couldn't find final "'" at /tmp/KWa__n0GBx:1------> ; import A; class B does A {}; f B, pi;'⏏<EOL> expectin…» | ||
grondilu | damn it I always forget to remove the quote at the end | ||
m: role A { multi f(A $a, $x) is export { $x } }; import A; class B does A {}; f B, pi; | |||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/X__lDE61n6Undeclared routine: f used at line 1» | ||
grondilu | so, can't I import a multi?? | ||
m: role A { sub f(A $a, $x) is export { $x } }; import A; f A, pi;' | 07:25 | ||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/Qh9INtECEZUnable to parse expression in single quotes; couldn't find final "'" at /tmp/Qh9INtECEZ:1------> is export { $x } }; import A; f A, pi;'⏏<EOL> expectin…» | ||
grondilu | m: role A { sub f(A $a, $x) is export { $x } }; import A; f A, pi; | ||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/ufK4QLtBtzUndeclared routine: f used at line 1» | ||
grondilu | m: class A { sub f(A $a, $x) is export { $x } }; import A; f A, pi; | 07:26 | |
camelia | ( no output ) | ||
grondilu | m: class A { sub f(A $a, $x) is export { $x } }; import A; say f A, pi; | ||
camelia | rakudo-moar 41d7f7: OUTPUT«3.14159265358979» | ||
grondilu | so importation works from a class but not from a role. Isn't that a bug? | ||
m: import (role { sub duh is export { "duh" } }) <duh>; say duh; | 07:31 | ||
camelia | rakudo-moar 41d7f7: OUTPUT«===SORRY!=== Error while compiling /tmp/Texobmqx5tA symbol '&duh' has already been exportedat /tmp/Texobmqx5t:1------> » | ||
07:40
jack_rabbit left
07:41
zakharyas joined
|
|||
moritz | grondilu: roles are rather special/complicated | 07:49 | |
does to roles actually being some sort of multi | |||
and a role not doing much until it's punned or applied | |||
grondilu | ok | 07:52 | |
07:54
virtualsue joined
07:55
yeahnoob joined
|
|||
yeahnoob | Someone can help with it? Please see stackoverflow.com/q/25638528/3132217 | 07:57 | |
Processing a large text file with Perl6 , but it's running very slow. And I don't know why... | 07:58 | ||
grondilu | well for one, the idiomatic way to read a file line by line is 'for lines open "file" {...}' | 08:03 | |
08:03
dayangkun left
|
|||
grondilu | $line.split(' ') is better written $line.words | 08:03 | |
08:04
u is now known as bcode
|
|||
grondilu | it does not make sense to write "{%dict{$p1}} {$p2}".words; You're concatenating and the split again?! | 08:04 | |
just write %dict{$p1} = (%dict{$p1}, $p2) | 08:05 | ||
yeahnoob | the code just make a dictionary from a text file | 08:06 | |
08:07
kjs_ joined
|
|||
grondilu | well: my %dict; for lines open "file" { my ($a, $b) = .words; %dict{$a} //= $b } | 08:07 | |
yeahnoob | for example abc.txt = " a b \n c d\n a e\n a cc\n", it get a dictionary like "a-> b e cc" | 08:08 | |
grondilu | oh | 08:09 | |
08:09
dayangkun joined
|
|||
grondilu | well: my %dict; for lines open "file" { my ($a, $b) = .words; push %dict{$a}, $b } | 08:09 | |
08:09
dakkar joined,
_thou joined
|
|||
yeahnoob | OK. i would try your code modification:) | 08:10 | |
08:10
FROGGS_ is now known as FROGGS
08:14
_thou left,
fdd__ left
08:17
kjs_ left
|
|||
yeahnoob | Still running two slow...even after the modification. | 08:20 | |
grondilu | open("file").lines.classify(*.words[0]) | ||
also: perl6 --version | |||
yeahnoob | perl6 --version | 08:21 | |
This is perl6 version 2014.08 built on MoarVM version 2014.08 | |||
i have tried the 2014.04 / 2013.12 versions | |||
the 2013.12 version coming from Ubuntu's package, and 2014.04 from the rakudo-star | 08:22 | ||
08:24
domidumont left
|
|||
yeahnoob | confused... | 08:25 | |
grondilu | 2014.08 on MoarVM is not far from the best there is. | 08:26 | |
08:27
anaeem1_ joined
|
|||
sergot | hi o/ | 08:30 | |
08:31
jaffa4 left
|
|||
yeahnoob | Perl 5 code deal with it about 200ms...I have tried in the past day. Really don't know why V6 running 20+sec, and still no finish. | 08:37 | |
tadzik | Because it's slower in many cases | 08:38 | |
dalek | rl6-most-wanted: 024137c | (Kamil Kułaga)++ | most-wanted/modules.md: HTML documentation like htmlify.p6 |
08:41 | |
08:41
kjs_ joined
08:42
yeahnoob left
08:47
anaeem1_ left,
anaeem1_ joined
08:50
ribasushi left
08:54
ribasushi joined
08:58
fhelmberger joined
08:59
mr-foobar left,
yeahnoob joined
09:09
virtualsue left
09:11
pecastro joined
|
|||
timotimo | o/ | 09:15 | |
FROGGS | o/ | 09:17 | |
yeahnoob | o/ | ||
09:17
aindilis` joined
09:18
aindilis left
09:19
dolmen joined
09:21
domidumont joined
09:29
mr-foobar joined
09:33
denis_boyun joined
09:37
dayangkun left
09:42
yeahnoob left
09:50
SamuraiJack left
09:51
SamuraiJack joined,
xinming_ joined
09:54
rindolf left,
xinming left
09:58
_thou joined
10:03
_thou left,
dayangkun joined
10:08
kjs_ left
10:15
dayangkun left
10:16
virtualsue joined
10:19
kjs_ joined,
dolmen left
|
|||
colomon | wo\ah, 20+ new module fails overnight | 10:20 | |
just tested, NativeCall is failing | 10:26 | ||
t/09-nativecast.t ...... 1/10 | |||
# Failed test 'casting int * to CArray[uint32] works' | |||
# at t/09-nativecast.t line 12 | |||
# expected: '1 2 3' | |||
# got: '1' | |||
10:27
dayangkun joined
|
|||
mathw_ | at least nativecall failing is a good reason for lots of other things to fail... | 10:27 | |
10:27
mathw_ is now known as mathw
|
|||
colomon | mathw: NativeCall is pretty important these days! | 10:28 | |
mathw | yes, still can't quite believe how easy it is too | ||
I need some ideas, my local perl mongers group are finally having a technical talks meeting and they want me to talk about Perl 6. I'm struggling to find the right sort of way in which shows them things which are beneficial to them instead of just different | 10:29 | ||
sergot | afaik it's because of this: github.com/rakudo/rakudo/commit/bf...6560f7ecba | 10:30 | |
or... | |||
is it? | 10:31 | ||
colomon | Migfht be because of the reason that patch was needed? | ||
I'd be really surprised if that patch was the cause | |||
10:31
kjs_ left
|
|||
timotimo | what colomon said | 10:32 | |
sergot | irclog.perlgeek.de/perl6/2014-09-02#i_9283186 | 10:33 | |
colomon: yes, I was wrong | 10:34 | ||
colomon | sergot: good catch | ||
sergot | github.com/rakudo/rakudo/commit/ef380d29f9 maybe? | 10:35 | |
10:38
bjz joined
10:44
chenryn left
10:45
kjs_ joined
|
|||
carlin | panda's projects.json still not updating? :( | 10:47 | |
tadzik | isn't it? | ||
oh, starman was being stupid for some reason | 10:48 | ||
carlin | hasn't updated since August 27, according to the HTTP headers | ||
tadzik | :o | ||
I poked the indexer | 10:49 | ||
10:50
kaleem left
|
|||
tadzik | carlin: should be better now | 10:51 | |
carlin | tadzik++ thanks | ||
tadzik | no idea what caused it though, I'll monitor if it breaks again | ||
10:51
FROGGS[mobile] joined
10:52
kaleem joined
11:03
oetiker left
11:06
chenryn joined
11:14
dayangkun left
|
|||
jnthn | .oO( wo\ah is a pretty alarm-ing exclamation... ) |
11:15 | |
11:18
oetiker joined
|
|||
jnthn | mathw: What kind of audience is it aimed at? | 11:19 | |
mathw: Dunno if any of my recentish talks can be of some inspiration... | |||
Does anybody know what happened to DESTROY in S12? | 11:20 | ||
I went to familiarize myself with the API it wanted so I can help out nine++'s work, and found it seems to have vanished... :S | |||
And the only recent history I could see was removing fossils related to it whihc suggests it somehow got removed long ago. | 11:21 | ||
I guess somebody conflated "not timely" with "useless" :P | 11:22 | ||
moritz | jnthn: it looks to me that they were only specified as method DESTROYALL / submethod DESTROY | ||
jnthn: and then (more or less accidentally) removed | 11:23 | ||
jnthn | Oh... | ||
So accidental. OK. | |||
That makes me worry a bit less ) | |||
11:24
pmurias joined
|
|||
pmurias | won't the moment DESTROY is called be very implementation dependent? | 11:24 | |
jnthn | pmurias: Yes. | 11:25 | |
pmurias: And it may not be called at all. | |||
But that's likely 'cus the VM is shutting down, in which case anyting you're holding on to is about to go away also :) | |||
Or at least, anything you're planning to do last-gasp cleanup of with DESTROY | 11:26 | ||
lizmat wonders it should be called DESTROY | 11:31 | ||
as the semantics are different from P5 | 11:32 | ||
maybe CLEANUP would be better ? | |||
nine | What's the difference in semantics? | 11:33 | |
jnthn | I think cleanup has the wrong nuance | 11:37 | |
It's more like an event, really | 11:38 | ||
COLLECT or so | |||
I dunno :) | |||
I do know it's dinner time, though. :) | |||
& | |||
11:40
pmurias left
|
|||
lizmat | REAP ? | 11:40 | |
moritz | REAPer, grim | 11:43 | |
carlin | class Reaper is Grim does Reap | 11:44 | |
11:46
labster left
11:47
_thou joined,
labster joined
11:52
_thou left
|
|||
flussence | I see this DESTROY thing as more of an advisory hook into the GC - if something's important enough that it *needs* to always run at a specific time, you'd just write it as normal code. | 12:00 | |
12:04
yeahnoob joined
|
|||
flussence | otoh, a separate CLEANUP might be useful to have, so the GC can politely ask things like caching classes to trim themselves a bit... | 12:04 | |
yeahnoob | Need Help Please..stackoverflow.com/q/25638528/3132217 | 12:09 | |
Processing a large text file using Perl6. And it's running Very Very Slow. | |||
flussence | what does "perl6 -e 'say $*VM'" print on your system? | 12:11 | |
yeahnoob | But it only cost less than 200ms with Perl 5, almost the same code. | ||
i have tried JVM/MoarVM/Parrot | 12:12 | ||
now its ouput is jvm(1.7) | |||
output | 12:13 | ||
ing a large text file using Perl6. And it's running Very Very Slow. | |||
perl6 -e 'say $*VM' | |||
jvm (1.7) | |||
flussence | what about perl6-m -e 'say $*VM' ? | ||
yeahnoob | i don't build MoarVM on my PC. | 12:14 | |
So no perl6-m now. But i have tried MoarVM with perl6-m | 12:15 | ||
FROGGS[mobile] | yeahnoob: .get is very very slow, a grammar might be better there | ||
colomon | yeahnoob: %dict{$p1} = "{%dict{$p1}} {$p2}".words; strikes me as a VERY inefficient way to do that | 12:16 | |
yeahnoob | i know its not a efficient code | ||
i have modified it with some suggestion. | |||
But no better result | 12:17 | ||
Such as: | |||
use v6; | |||
my %dict; | |||
for open('wordpairs.txt',:r).lines { | |||
my ($key, $words) = .words; | |||
push %dict{$key}, $words; | |||
} | |||
## Test | |||
Or: | 12:18 | ||
... | |||
use v6; | |||
my %dict; | |||
my $a; | |||
my $b; | |||
for lines open "wordpairs.txt" { | |||
($a, $b) = .words; | |||
push %dict{$a}, $b; | |||
} | |||
## Test | |||
FROGGS[mobile] | dont paste here | ||
please use a paste service | |||
colomon | yeahnoob: can you upload the wordpairs file somewhere so we can try wit hthat? | 12:19 | |
yeahnoob | Sorry | ||
mathw | jnthn: competent, active Perl 5 developers. Most of them seem to do nothing but websites in it, so I'm not sure how enthused they'd be by your brilliant ones about asynchronous programming. | ||
yeahnoob | I host the whole thing at my github | ||
FROGGS[mobile] | I can reply to your stackoverflow question later when I'm at my pc... then I can propose a grammar | ||
yeahnoob | github.com/yeahnoob/perl6-perf | ||
colomon | yeahnoob: brill | 12:20 | |
yeahnoob | Pre-Thanks for any answer:) | ||
mathw | jnthn: I might throw in something about NativeCall though, because last I checked you couldn't do it that easily in 5... | 12:21 | |
12:21
chenryn left
|
|||
colomon | yeahnoob: it's entirely possible the answer (at the moment) is just rakudo is slow. but we can at least learn more about it…. | 12:23 | |
12:23
dwarring left
|
|||
yeahnoob | Yes, it's maybe the rakudo's. The code work no problem with a small test.txt file | 12:25 | |
colomon | yeahnoob: it takes almost two minutes to run on my Mac | 12:28 | |
profiling now | 12:30 | ||
yeahnoob | en..it's not a reasonable time cost, which is 160ms with the same function Perl 5 test code on my PC. | 12:32 | |
colomon | Hmm, just got it down to 51 seconds. | 12:36 | |
FROGGS[mobile] | colomon: I bet I get it down to <5s | 12:37 | |
:p | 12:38 | ||
colomon | FROGGS[mobile]: with a grammar? | 12:39 | |
12:40
FROGGS[mobile] left
12:43
dayangkun joined
12:46
FROGGS[mobile] joined
|
|||
FROGGS[mobile] | colomon: aye | 12:47 | |
colomon | FROGGS[mobile]: Trying now... | ||
I dunno, my first stab at a grammar seems painfully slow | 12:53 | ||
oooo, maybe not | 12:54 | ||
12:55
PZt left
|
|||
FROGGS[mobile] | it should be a pretty easy grammar (with actions) | 12:56 | |
I mean, lines and words... right? | 12:57 | ||
colomon | FROGGS[mobile]: pretty sure it wasn't the grammar that was painfully slow, it was the call to Match.gist | ||
My grammar can succesfully scan the file in 21 seconds. | 12:58 | ||
FROGGS[mobile] | ohh, true :o) | ||
hmmm, how big is the file? | |||
colomon | 1.5 meg | 12:59 | |
no, waitr, that was the profile output! | |||
1,474,282 bytes | |||
FROGGS[mobile] | how many lines? | ||
colomon | 138,523 | 13:00 | |
FROGGS[mobile] | because we can 20k lines Perl 6 with a much more complex grammar in 35s on my box | ||
colomon | okay, that was 46 seconds to parse and count | ||
13:00
_thou joined
|
|||
colomon should maybe start $working at some point.... | 13:02 | ||
FROGGS[mobile] | please put it in a gist, I try to improve it in abit | 13:03 | |
13:03
telex left
|
|||
colomon | heh, 97% of the running time is the my <word-pair> rule. | 13:04 | |
13:04
telex joined,
kaleem left
|
|||
colomon | www.harmonyware.com/files/profile-1....0399.html | 13:05 | |
half the running time is in prefix:<~> | |||
FROGGS[mobile] | where is the code? :o) | 13:06 | |
13:06
kaleem joined
|
|||
colomon | WHAT | 13:07 | |
13:07
guru joined,
guru is now known as Guest39660
13:08
Guest39660 is now known as ajr_
|
|||
colomon | one-third of the running time is going to join?! | 13:09 | |
FROGGS[mobile] | can I see the grammar? | ||
colomon | got it down to 37 seconds | ||
gist.github.com/colomon/ce21bb3f199637814f00 | 13:10 | ||
profiling that one now | |||
13:11
salv0 left
|
|||
colomon | profile: www.harmonyware.com/files/profile-1...50828.html | 13:11 | |
hmmm | 13:13 | ||
13:13
Akagi201 left
|
|||
colomon | 33 seconds | 13:15 | |
dalek | kudo/pod-fixes: 6ac67de | (Rob Hoelz)++ | src/Perl6/Grammar.nqp: Convert two more END-related things in POD parsing It's finish now |
||
kudo/pod-fixes: 74fd61d | (Rob Hoelz)++ | src/Perl6/Grammar.nqp: Fix paragraph and abbreviated comments Except for table comments, that is |
|||
13:15
Akagi201 joined
|
|||
colomon | new one gist.github.com/colomon/c2d2c1940b92d8d9df01, profile www.harmonyware.com/files/profile-1...18343.html | 13:16 | |
colomon is trying to build moar jit to see what that does to the timings | 13:22 | ||
13:23
raiph joined
13:24
kaleem left,
prevost joined
|
|||
colomon | hmmm, JIT doesn't help at all | 13:25 | |
13:25
rindolf joined
|
|||
timotimo | ah, caphash is the top time-user there. some time soon MATCH will be rewritten in rakudo to include the stuff CAPHASH used to do and that'll make stuff faster, because it won't build an intermediate data structure just to throw it away again | 13:27 | |
colomon | profile of the last with JIT is www.harmonyware.com/files/profile-1...51175.html | 13:28 | |
timotimo | ah, 73.8% jitted frames isn't terribly bad | ||
5% deoptimizations seems to be quite a lot | |||
huh, using the jit makes it slower, but the time spent doing dynamic optimization is basically zero ... | 13:29 | ||
13:32
smash_ is now known as smash
|
|||
timotimo | doesn't FROGGS[mobile] want to implement the proper MATCH for rakudo? :P | 13:32 | |
13:35
chenryn joined
|
|||
FROGGS[mobile] | timotimo: not that I know :o) | 13:36 | |
timotimo | do i remember correctly that you did that for NQP already? | ||
FROGGS[mobile] | timotimo: also, I am implementing C globals just fo you already :p | 13:37 | |
timotimo | ooooh! | ||
for me? :D | |||
FROGGS[mobile] | jnthn did | ||
surprise /o/ | |||
timotimo | i'm not sure if i even need c globals for any project i have going on at the moment | 13:38 | |
FROGGS[mobile] | you said that yoz'd need that for OpenGL IIRC | ||
timotimo | oh | ||
i hope you won't expect me to build an opengl binding immediately now :) | 13:39 | ||
FROGGS[mobile] | much disappointment *g* | ||
timotimo | what i needed for opengl was casting the return value of functions to invocables | ||
FROGGS[mobile] | ahh, true | ||
timotimo | and having mutable bufs would be very interesting for opengl | 13:40 | |
FROGGS[mobile] | that should be doable too, since we have nativecast and callbacks | ||
Buf is not mutable? | |||
timotimo | buf or blob or whichever | 13:41 | |
not yet, needs the native array thingie jnthn has somewhere near the top on his todo list | |||
FROGGS[mobile] | we have that now me thinks | ||
ahh | |||
I see | |||
[Coke] | mathw: I did a presentation on six for a bunch of fivers a few months ago, you can reuse that if you like. | ||
13:43
mr-foobar left
13:46
yoleaux joined,
ChanServ sets mode: +v yoleaux
|
|||
[Coke] | (though you'd need to familiarize yourself with the slides before using it; I was trying to hit all the highlights for "neat stuff fivers mights want". (and didn't have enough time to touch grammars, unfortunately) | 13:48 | |
timotimo | oh, that's the one where i manually colored syntax in the slides, right? :D | ||
[Coke] | m: sub postfix:<!> { [*] 2..$^a }; say 0!, 1!, 2! | 13:49 | |
camelia | rakudo-moar 41d7f7: OUTPUT«112» | ||
[Coke] | timotimo++ yes, I think so! | ||
timotimo | that was fun | ||
except it was stupid work ;) | |||
jnthn | oh wow, timotimo provides Slide Highlighting as a Service? :D | 13:51 | |
timotimo | i really want to find a better way to do that for the next time. | ||
jnthn | :) | 13:52 | |
timotimo | it was also a very last-minute decision | ||
14:02
slavik left,
dalek left
14:03
dalek joined,
ChanServ sets mode: +v dalek
|
|||
jnthn | Yay. Startup time is lower than last time I was looking at it... | 14:06 | |
14:07
salv0 joined
14:13
Ven joined
|
|||
Ven | o/, #perl6 | 14:13 | |
timotimo: slides.com highlighted my p6 correctly | |||
timotimo | oh, neato | ||
Ven | timotimo: i.e. slides.com/namidoc/road2p6#/9 | 14:14 | |
[coke]: I'd be very interested in your material too :-) | 14:15 | ||
timotimo | that presentation was on google docs | ||
14:15
slavik joined
|
|||
Ven | timotimo: which one? [coke]'s one? | 14:16 | |
[Coke] | ven, mathw : docs.google.com/presentation/d/1ls...sp=sharing | ||
timotimo | yes | ||
Ven | thanks! [coke]++ | ||
[Coke] | Happy to to allow folks edit access if they're up for it. (timotimo, looks like we ended up with a white copy and a black copy) | 14:17 | |
timotimo | ah | ||
yes, i think so | |||
[Coke] | I should go through and delete one of those. | 14:19 | |
(and make sure everything is up to date in teh other) | |||
Ven | well, cognome++ asked me to talk about 6 a bit too, but I really don't want to explain the internals | 14:20 | |
"who cares" :-) | |||
[Coke]: no hard feeling if I skip the opening slides :p? | |||
[Coke] | Ven: of course not, share and enjoy. | 14:22 | |
if you have improvements, let me know. :) | |||
colomon is very glad he is listening to some nice fiddling and so not tempted to sing the share and enjoy song | |||
[Coke] | definitely need updated moar benchmark shots! | 14:24 | |
I see anonymous ibex and anonymous liger are reading the doc. :P | |||
Ven | I'll read through it later. | 14:29 | |
I also don't really know what 5ers want, since I'm not a 5er, but I'm gonna use that :p | |||
moritz | perl 5 programmer, presumably | 14:30 | |
Ven | moritz: wut? | 14:31 | |
timotimo | i think he misread your "want" as "are" | ||
Ven | Oh, I think you read my "want" as "are" | ||
timotimo | %) | ||
Ven | timotimo++ # 2spooky | ||
moritz | Ven: sorry for the confusion | 14:32 | |
dalek | kudo/nom: 358c749 | jonathan++ | src/Perl6/Metamodel/BOOTSTRAP.nqp: Avoid around 6,000 allocations at startup. These chewed through around a 16th of a nursery. |
14:35 | |
jnthn | Also is a small win for the initial run through every multi dispatch. | ||
14:35
dj_goku_ left
|
|||
timotimo | huh. | 14:41 | |
interesting | |||
14:42
mr-foobar joined
14:43
anaeem1_ left
|
|||
timotimo | Ven: "rakudo-js, unfortunately abandoned" - not actually true, but you may know that by now already | 14:43 | |
Ven | timotimo: it was when I wrote this | 14:44 | |
this is the talk I gave at the fpw2014 | |||
timotimo | yeah, i saw the "3 month ago" | ||
14:45
itz joined
|
|||
timotimo | (i'm using google translate to read your slides | 14:45 | |
) | |||
sub postfix ($ N) {<!> [*] 2 .. $ N ; } <- that's very well translated, google! | 14:46 | ||
m) | |||
14:46
itz_ left
|
|||
Ven | timotimo: not sure what that gives %) | 14:48 | |
timotimo: think about woolfy++ and lizmat++, they sat through it without translators %) | |||
14:49
pmurias joined
|
|||
hoelzro | morning #perl6 | 14:49 | |
pmurias | masak: I have thought a bit about your take an example and refactor it into a grammar thing | 14:50 | |
masak: what I think would be most usefull instead of having it as standalone web things would be to integrate it into an editor | 14:51 | ||
masak | pmurias: yes, quite probably | ||
yoleaux | 1 Sep 2014 19:45Z <Ven_> masak: you might think my "Map[K, V]" naming is unfortunate, but we can't type hashes. | ||
2 Sep 2014 00:28Z <jepeway> masak: hey, I'm poking at RT 122319; would you have time to peek at clog around irclog.perlgeek.de/perl6/2014-09-01#i_9282046? | |||
Ven | actually, maybe my Foo %Bar{Baz} works but no clue what it does | 14:52 | |
pmurias | masak: we could even do something like automatically find a rule that matches a given block of selected text | 14:53 | |
[Coke] | someone was looking for things to do recently: here's a boring list of work that is a good way for folks to contribute: gist.github.com/coke/ac078396e8f216b83e9a | 14:54 | |
pmurias | masak: so you could select {"foo":123} and have it "refactored" into <json> | ||
[Coke] | happy to have that go somewhere more easily editable. | 14:55 | |
timotimo | Ven: i live so close to the french border, maybe i'll swallow my pride and learn some french at some point ... | 14:56 | |
Ven | timotimo: well, if you want to drop by at some point, n'hésite pas %) | ||
timotimo | is nancy very far from you? that's the closest big town i think | ||
Ven | timotimo: almost 400km between those, yes – I'm in paris. | 14:57 | |
14:58
itz_ joined
|
|||
Ven | *(that's where the french mongueurs are) | 14:58 | |
timotimo | mhm | ||
that's pretty far :\ | |||
Ven | indeed | 14:59 | |
15:00
itz left
|
|||
pmurias | masak: the biggest problem with integrating it into an editor is choosing the editor we want to integrate into ;) | 15:01 | |
masak kinds of doubts that's the biggest problem :) | |||
kind* | 15:02 | ||
Ven: `my Foo %Bar{Baz}` works, AFAIK. generally when I have no clue what something does, I read the spec. | |||
15:03
itz joined
|
|||
Ven | masak: I don't know, I just read that syntax 30min ago :P | 15:03 | |
15:04
itz_ left
|
|||
masak | anyway, your flippant ignorance of the actual way to write a typed hash does not inspire in me confidence about your choice of the name `Map`. | 15:04 | |
nwc10 | jnthn: Rakudo startup seems to be 3% less than "last time I measured it" | 15:08 | |
15:08
ajr_ left,
guru joined,
guru is now known as Guest31904
15:09
Guest31904 is now known as ajr_
15:10
chenryn left
15:11
denis_boyun left
|
|||
Ven | masak: what was that about? | 15:11 | |
15:12
kaleem joined
|
|||
Ven | masak: as I said - this is barely pseudo code anyway. | 15:12 | |
no apparently-flippant compiler is capable of handle `has`'s `where`s | 15:13 | ||
masak | Rakudo parses them but ignores them at present. | ||
as deficiencies go, there are worse :) | |||
Ven | handling* | 15:14 | |
15:14
chenryn joined
|
|||
jnthn | m: my Int %h; %h<a> = 'omg' | 15:14 | |
camelia | rakudo-moar 41d7f7: OUTPUT«Type check failed in assignment to '%h'; expected 'Int' but got 'Str' in method assign_key at src/gen/m-CORE.setting:9716 in sub postcircumfix:<{ }> at src/gen/m-CORE.setting:2799 in block <unit> at /tmp/V93rnBru1J:1» | ||
jnthn | Doesn't look very ignored to me ;-) | ||
masak | that part works. | ||
Ven | m: my %h{Str}; %h{1} = 5; | 15:15 | |
camelia | rakudo-moar 41d7f7: OUTPUT«cannot stringify this in method assign_key at src/gen/m-CORE.setting:10054 in sub postcircumfix:<{ }> at src/gen/m-CORE.setting:2799 in block <unit> at /tmp/Ngws364YOd:1» | ||
Ven | well, at least it's not as terrible a syntax as go's. | ||
masak .oO( hammer time! ) | |||
jnthn | nwc10: I'll take 3% :) | 15:16 | |
nwc10 | me too | 15:17 | |
15:17
Ven left
15:22
firefish5000 left
|
|||
[Coke] | .words is slooow. | 15:33 | |
15:37
PhilH joined
|
|||
colomon | [Coke]: yeeeeessssssss | 15:40 | |
[Coke] | looking at the SE code that came through here a day or 2 ago | 15:41 | |
stackoverflow.com/questions/2563852...ow-2014-09 | |||
[Coke] updates to latest moar JIC. | 15:42 | ||
colomon | [Coke]: irclog.perlgeek.de/perl6/2014-09-03#i_9290176 and beyond | ||
irclog.perlgeek.de/perl6/2014-09-03#i_9290559 is good. ;) | 15:43 | ||
but not great | |||
jnthn | 'night o/ | 15:45 | |
15:46
virtualsue left
|
|||
timotimo | aaw, jnthn is already gone again :S | 15:47 | |
15:48
itz_ joined
|
|||
tadzik | which timezone is jnthn in? :o | 15:48 | |
timotimo | +7 or +8 i think | ||
15:50
zakharyas left,
itz left
15:52
itz_ left,
fhelmberger left
15:53
itz joined
|
|||
yeahnoob | +8 zone, me too. Sleeping time now. | 15:56 | |
15:57
yeahnoob left
|
|||
[Coke] | colomon: looks like 23% of the time is spent in reify (... using my local unpublished version of his code which uses .IO.lines and then calls ".words" 138K times. | 15:59 | |
16:02
kjs_ left
|
|||
colomon | [Coke]: pretty sure using .words is a bad idea for performance | 16:03 | |
16:04
mattp__ joined
16:05
prevost_ joined
|
|||
colomon doesn't mean to say we shouldn't work on optimizing .words performance, mind you | 16:05 | ||
16:05
hoelzro_ joined
16:06
mads-_ joined,
[Coke]_ joined,
Juerd_ joined
16:07
arnsholt_ joined
|
|||
masak | 'night, #perl6 | 16:07 | |
moritz | \o | ||
timotimo | gnite masak! | ||
16:07
yukko_ joined
16:08
clkaoud left,
ClarusCogitatio_ left,
prevost left,
hoelzro left,
mads- left,
Celelibi left,
ggherdov left,
arnsholt left,
Juerd left,
mtj_ left,
[Coke] left,
skarn left,
mattp_ left,
Juerd_ is now known as Juerd,
yogan joined,
camelia joined
16:09
mtj_- joined,
hoelzro_ is now known as hoelzro,
ClarusCogitatio joined,
clkaoud_ joined,
Celelibi joined
16:10
ChanServ sets mode: +v camelia,
vukcrni joined
16:11
skarn joined,
skarn is now known as Guest10538
16:12
ggherdov joined
16:17
pecastro left
16:27
MilkmanDan left
16:29
raiph left,
raiph joined
16:32
MilkmanDan joined
16:33
spider-mario joined,
spider-mario left
16:35
spider-mario joined
16:38
dj_goku joined
16:41
SamuraiJack left,
SamuraiJack joined
16:42
dakkar left
16:43
ajr_ left
16:45
dayangkun left
16:47
guru joined,
guru is now known as ajr_,
pmurias left
16:49
raiph left
16:50
SamuraiJack left
16:57
mads-_ is now known as mads-
|
|||
FROGGS | colomon: I was just able to make it about 20% faster: github.com/yeahnoob/perl6-perf/pull/1 | 16:57 | |
PerlJam | Is RT #118755 still valid? (i.e. should first return the mutable containers?) | 16:59 | |
synopsebot | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=118755 | ||
17:04
anaeem1_ joined
17:05
chenryn left
|
|||
TimToady | on a 3300 word file, .words creates 16000 hashes | 17:07 | |
well, BOOTHashes | |||
9900 BOOTIters | |||
FROGGS | we are quite fast at allocating all these things /o\ | 17:08 | |
TimToady | 10000 BOOTCodes, 39000 BOOTInts, and 86000 BOOTArrays | ||
FROGGS | ohh dear | 17:09 | |
TimToady | well, .words is defined as .comb(/\S+/) but it's stupid to implement it that way | 17:10 | |
FROGGS | I know of somebody who has a commit bit *g* | 17:11 | |
TimToady just needs to complain a little first | |||
FROGGS | sure | ||
I'd like to fix rakudo's MATCH which should help here too, the problem is that I don't know what to fix :o( | 17:12 | ||
I think jnthn++ said that we could get rid of three allocations | |||
TimToady | obviously we're paying a very high price for the abstraction here | 17:13 | |
17:14
bjz left
|
|||
FROGGS | well, the machines have to pay that price... not the devs :o) | 17:14 | |
17:14
bjz joined
|
|||
TimToady | we pay a price in time | 17:14 | |
FROGGS | intel should give us some money, because we indirectly sell CPUs :o) | 17:15 | |
TimToady | then they should be paying us to *not* work :P | 17:17 | |
since we're trying to sell fewer CPUs | |||
dalek | kudo/nom: 07ef21e | duff++ | src/core/Any.pm: Fixes RT #118755 |
||
synopsebot | Link: rt.perl.org/rt3//Public/Bug/Displa...?id=118755 | ||
17:28
jack_rabbit joined
|
|||
vendethiel | "computational expressions" is what happened when f# realized it wanted haskell's do-notation but didn't have hindley-milner. | 17:30 | |
at least it's cute... | |||
17:33
ajr_ left
17:34
zakharyas joined
|
|||
dalek | kudo/nom: 03b9a09 | moritz++ | src/Perl6/Metamodel/BOOTSTRAP.nqp: [Bootstrap] natively-type a variable |
17:39 | |
kudo/nom: 4d18460 | moritz++ | src/Perl6/Metamodel/BOOTSTRAP.nqp: [Bootstrap] remove an unused variable |
|||
kudo/nom: 962a993 | moritz++ | src/Perl6/Actions.nqp: Cache a constant expressions |
|||
kudo/nom: 8ef5c55 | moritz++ | src/Perl6/Grammar.nqp: [grammar] use some more native types |
|||
17:41
cognome left
|
|||
lizmat | moritz: maybe those fixed need a Moar or NQP revision bump?? | 17:43 | |
*fixes | |||
moritz | lizmat: what makes you think so? | ||
lizmat | Stage parse : moar(47427,0x7fff74dba310) malloc: *** error for object 0x7f85024f8290: pointer being freed was not allocated | ||
*** set a breakpoint in malloc_error_break to debug | |||
make: *** [CORE.setting.moarvm] Abort trap: 6 | |||
is what makes me suspect :-) | 17:44 | ||
moritz | lizmat: I have tested it with moarvm master, but there's nothing in there the looks like it needs a new MoarVM | ||
lizmat | just before your commits, I had just built without any problems | ||
17:44
cognome joined
|
|||
lizmat | retrying with moar master | 17:45 | |
nope, same failure | 17:48 | ||
retrying with nqp=master | |||
17:49
kjs_ joined
17:50
itz left
|
|||
lizmat | nope, still same problem :-( | 17:52 | |
going back in commits now | |||
nine | (git bisect)++ | ||
lizmat | moritz: seems 8ef5c5564c is the reason | 17:53 | |
if I remove all the native str typing, it builds | 17:56 | ||
further refining now | |||
17:56
itz joined
|
|||
woolfy | Hi all. Remark from a friend from outside Perl 6: "I am interested in Perl6 but until there is an easy way to install it on a Windows machine, my interest is expressed from a safe distance only." | 18:01 | |
So I went looking for a MSi and found this: rakudo.org/downloads/star/ | |||
vendethiel | woolfy: a new pal :P ! | ||
a windows user | |||
woolfy | There's a MSI file for Rakudo Star 2014.03. Not yet for 2014.08. | ||
Any idea when? | |||
vendethiel: actually, this is regarding a Perl-friend of mine that I know for 10+ years... | 18:02 | ||
lizmat | moritz: is it legal to do a eq 'f' on a str in nqp ? | ||
woolfy | And next question: how "easy" (I know, many definitions of what easy is) is it to install Rakudo Star with this MSI file? | 18:03 | |
vendethiel | woolfy: it's a one-click installer | ||
woolfy | (I am not on Windows, so I cannot try it myself and I really would hate myself going back to Windows again) | ||
vendethiel | it's very well packaged. | ||
it's just unsuitable for prod because it's so slow | 18:04 | ||
(it's on parrot :P) | |||
lizmat | moritz: it appears that this line is causing the problem: | ||
woolfy | vendethiel: Really that simple? So, at the end, my friend would have what, Parrot and MoarVM and JVM and NQP and Rakudo and could just go ahead? | ||
lizmat | my str $last := nqp::substr($str, nqp::chars($check) - 1, 1); | ||
woolfy | Oh. Just parrot. | ||
vendethiel | woolfy: well, 2014.03 only had parrot | ||
lizmat | it feels like it is causing a problem on the next line (3449) | ||
$last eq ')' || $last eq '}' || $last eq ']' || $last eq '>' | |||
woolfy | Hm. I'm not going to advice him to work on Parrot. No way. | 18:05 | |
vendethiel | because every rakudo star was only-parrot, not just the windows one | ||
so, technically, this new R*for 2014.08 could definitely use moarvm :-) | |||
woolfy | vendethiel: OK, so it would be in the 2014.08 release? | ||
vendethiel | I hope so! But no reason not to, we know moar works on windows -- jnthn++'s on it | ||
woolfy | So, back to my first question... Any idea when? (I mean: "when is rakudo-star-2014.08.msi going to be available?"). Days, weeks, or wait for 2014.09 or 2014.10 or so... ballpark figure would be nice. | 18:07 | |
18:08
BizarreCake joined
|
|||
lizmat | I think the main problem is that there are few people with MSI-building fu :-( | 18:09 | |
18:10
MilkmanDan left
|
|||
woolfy | fu? | 18:10 | |
nine | woolfy: knowledge | 18:11 | |
18:11
SamuraiJack joined
|
|||
woolfy | Ah. That went way over my head. | 18:11 | |
18:12
kaleem left,
molaf_ joined
|
|||
FROGGS | woolfy: "when is rakudo-star-2014.08.msi going to be available?" - hours | 18:13 | |
lizmat | Suffix[edit] | ||
-fu | |||
(slang) Expertise; mastery. | |||
My Google-fu is weak! | |||
Aragorn uses Ranger-fu to figure out that Sam and Frodo have taken a boat. | |||
woolfy: from en.wiktionary.org/wiki/-fu | 18:14 | ||
timotimo | FROGGS: pretty awesome! :) | ||
18:14
MilkmanDan joined
|
|||
FROGGS | timotimo: I also did a 2014.04-moar.msi and -parrot.msi | 18:14 | |
woolfy | Yeah yeah... as said, it went way over my head. First time that I saw somebody use this lingo outside the "kung fu" area of expertise. | 18:15 | |
18:15
zakharyas left
|
|||
FROGGS | but I did not upload it because I did not have a single tester... | 18:15 | |
huf | "expert in kung" | ||
i wonder what that is.. | |||
FROGGS | but now I just upload anyway | ||
woolfy | FROGGS++ | ||
18:16
molaf__ left
|
|||
dalek | kudo/nom: 0be2374 | (Elizabeth Mattijsen)++ | src/Perl6/Grammar.nqp: Unbust on (at least) OSX, caused by 8ef5c5564c No idea why this makes a difference, but suspect the eq on the next line to have some influence in this. Error seen was: Stage start : 0.000 Stage parse : moar(51746,0x7fff74dba310) malloc: *** error for object 0x7faa4c7aad90: pointer being freed was not allocated *** set a breakpoint in malloc_error_break to debug make: *** [CORE.setting.moarvm] Abort trap: 6 |
18:16 | |
18:17
SamuraiJack left
|
|||
woolfy | OK, FROGGS, thanks. I just mentioned it to my Perl5-friend (who I leave to be anonymous for now). I guess he did not expect this. I hope he likes it. | 18:18 | |
FROGGS | I already started to make the msi's, so another funny coincident :o) | ||
PerlJam | FROGGS++ the best way to get testers is to make a release and tell everyone where to get it :) | 18:19 | |
FROGGS | *g* | ||
yeah, that might work too :o) | |||
18:21
molaf_ left
|
|||
moritz | lizmat++ # fixing up my mess | 18:23 | |
lizmat | moritz: is that supposed to work in nqp? eq on a native str ? | ||
FROGGS | nqp-m: my str 'foo'; say($foo eq 'foo') | ||
camelia | nqp-moarvm: OUTPUT«Confused at line 2, near "my str 'fo" at gen/moar/stage2/NQPHLL.nqp:481 (/home/p6eval/rakudo-inst-2/languages/nqp/lib/NQPHLL.moarvm:panic:105) from gen/moar/stage2/NQP.nqp:913 (/home/p6eval/rakudo-inst-2/languages/nqp/lib/nqp.moarvm:comp_unit:872) fro…» | ||
FROGGS | nqp-m: my 'foo'; say($foo eq 'foo') | 18:24 | |
camelia | nqp-moarvm: OUTPUT«Confused at line 2, near "my 'foo'; " at gen/moar/stage2/NQPHLL.nqp:481 (/home/p6eval/rakudo-inst-2/languages/nqp/lib/NQPHLL.moarvm:panic:105) from gen/moar/stage2/NQP.nqp:913 (/home/p6eval/rakudo-inst-2/languages/nqp/lib/nqp.moarvm:comp_unit:872) fro…» | ||
FROGGS | nqp-m: my str $foo := 'foo'; say($foo eq 'foo') | ||
camelia | nqp-moarvm: OUTPUT«1» | ||
FROGGS | yes | ||
moritz | lizmat: I dearly hope so :-) | ||
lizmat | hmmm... well... then I have no idea... | ||
moritz | Cursor.INTERPOLATE has lots of vars that could become native | ||
lizmat | but undoing the "str" typing unbusted the build for me | ||
moritz | but when I tried to make it that way, core compilation hangs | 18:25 | |
lizmat | so, definitely something fishy goin on there | ||
vendethiel reads some "go sucks post" again and chuckles | |||
FROGGS++ thanks for taking care of us windows users | |||
well, I don't really code on windows anymore, but I know I have an incredible luck | 18:26 | ||
dalek | kudo/nom: c524e7d | (Elizabeth Mattijsen)++ | src/core/Parcel.pm: Simplify Parcel.WHICH, now that we don't flatten |
||
ar: 0644ed9 | (Tobias Leich)++ | / (2 files): pass --backends option to rakudo's configure |
18:30 | ||
18:32
gfldex joined
18:35
telex left
18:36
guru joined,
guru is now known as ajr_,
telex joined
|
|||
vendethiel | can I encode church's numbers in P6's type system? | 18:38 | |
probably not :( | |||
TimToady | m: say set(set()) | 18:39 | |
camelia | rakudo-moar 8ef5c5: OUTPUT«set(set())» | ||
TimToady | interesting datapoint: I rewrite .comb(/S+/,$limit) in very raw nqp using nqp::findcclass and nqp::findnotcclass, and it runs twice as slow... | 18:48 | |
FROGGS | hehe | 18:49 | |
TimToady | despite the fact that .words is entirely jitted | ||
FROGGS | the funny thing here was that my window size made the line break after the 'as'... so the 'slow' was kinda unexpected *g* | 18:50 | |
TimToady | would be lovely to have a statement-by-statement profiler... | ||
PerlJam | TimToady: Seems like it wasn't so stupid to implement .words with .comb(/S+/) after all ;) | ||
TimToady thinks findcclass must be doing something stupid now, like reloading the Unicode database each time | 18:52 | ||
[Coke]_ | TimToady: you using moar, I assume? | 18:53 | |
PerlJam | If you make findcclass and findnotcclass faster, that will have broad, positive impact | 18:54 | |
18:54
[Coke]_ is now known as [Coke]
|
|||
PerlJam crosses his fingers that TimToady's changes have a happy ending. | 18:54 | ||
18:57
sjohnson left
|
|||
diakopter | istr writing findcclass | 19:00 | |
19:00
darutoko left,
itz left,
itz joined
|
|||
TimToady | oh, gee, the first thing findcclass does is length = MVM_string_graphs(tc, s); | 19:03 | |
diakopter | I thought graphs was cached | 19:04 | |
on the string | |||
object | |||
TimToady | maybe it is, though strings have changed somewhat since then | ||
timotimo | PerlJam: did you nqp::unbox_s the target string once? | 19:05 | |
if the string is utf8, it may have to scan through the string to get to the $start-index (byte vs codepoint) | 19:06 | ||
diakopter | it never stores as utf8 | ||
19:07
rindolf left
|
|||
timotimo | oh, right, we have 32bit storage for codepoints anyway | 19:07 | |
19:07
rindolf joined
|
|||
TimToady | findcclass does appear to cache the grapheme count, but it does create a new iterator every time; dunno whether that's expensive or not | 19:16 | |
diakopter | I'd guess so | 19:17 | |
TimToady | the regex engine at least knows it's gonna look for the same thing again, so it naturally saves the previous cursor to start from; maybe that's the difference... | 19:18 | |
19:19
_thou left
|
|||
TimToady | I suppose we could cache the iterator, as long as the string doesn't change, and start from where we left off before, if appropriate | 19:19 | |
or add some kind of simplecomb instruction that knows it's going to alternate on some boolean test | 19:20 | ||
diakopter | that wouldn't be threadsafe, unless you laboriously made it so | 19:22 | |
(the cached iterator) | |||
PerlJam | depends on where the cache lives :) | ||
diakopter | true | ||
19:23
zakharyas joined
|
|||
timotimo | right, the threadcontext could hold it and it'd be fine | 19:24 | |
TimToady | well, this is probably too micro of an optimization to be looking at it right now | 19:25 | |
FROGGS | woolfy: | 19:26 | |
rakudo.org/downloads/star/rakudo-st...8-moar.msi | |||
rakudo.org/downloads/star/rakudo-st...parrot.msi | |||
vendethiel | woolfy: FROGGS++ just updated the msi :-) | ||
uploaded* | |||
TimToady | especially since it's lunch time | ||
vendethiel | sorry FROGGS, I'm too fast for you ;-) | ||
FROGGS | O.o | ||
timotimo | in the compilation process of rakudo-parrot, there was one file where updating the line position cache took much longer because the file was utf8 and it was re-doing the iterator from the beginning each and every time | ||
FROGGS | how on earth... | ||
vendethiel | did I know you pushed those? | ||
FROGGS | vendethiel: yeah | ||
vendethiel | I wonder :-) | ||
timotimo | he sat on the f5 button | ||
FROGGS | or he just pulled the internet and saw it in the diff | 19:27 | |
woolfy | :-) | ||
timotimo | %) | ||
vendethiel | actually I just saw the github notifications | ||
cause I see those instantly | |||
19:28
itz_ joined
|
|||
timotimo | .. github notifications? | 19:28 | |
vendethiel | timotimo: FROGGS++ posted something on github about that *before* noticing woolfy++ here. | ||
FROGGS | I replied to a panda issue | 19:29 | |
vendethiel | and I basically saw it insta | ||
(I spend far too much time on github :/) | |||
FROGGS | but we <3 github! | 19:30 | |
I'd work for them if they'd need Perl ppl | |||
19:30
itz left
|
|||
vendethiel | FROGGS: well, I do too. But still, I reached 531 days of streak -- that's far too much time spent on that | 19:30 | |
woolfy | OK, I told my friend and he is happy. Now he needs some tuits (well, hours) to start playing with it. But I am sure (meaning "I really really really hope) he is not the only one that will use it. | 19:31 | |
timotimo | FROGGS: after installing it, the windows start menu shortcut wouldn't work | 19:32 | |
vendethiel | woolfy: trust me, he's not. even if only with the people I introduced to p6 ;-) | ||
and I introduced *a lot* of them and they're mostly using windows | |||
timotimo | it'd say "missing file" or "broken shortcut" or something and tells me to look for "perl6-m.exe", but there's only perl6-m.bat | ||
FROGGS | timotimo: there is one? O.o | 19:33 | |
woolfy | I am NOT on Windows so there is no way I am going to try that! | ||
timotimo | yes. | ||
FROGGS | timotimo: I see, that seems to be a relict of parrot-ish days, when we had .exe files only | 19:34 | |
timotimo | :) | ||
would be neat if you fixed it anyway :) | |||
FROGGS | yeah... | ||
19:35
itz_ left,
itz joined
19:37
domidumont left
|
|||
moritz | 19:40 | ||
19:40
BizarreCake left,
beastd joined
|
|||
moritz | t/spec/integration/99problems-51-to-60.t segfaults for me | 19:41 | |
Ulti | one issue with the MSI is it's not signed so modern Windows platforms complain a lot | 19:42 | |
vendethiel | nothing's signed, these days :/ | ||
Ulti | well that's the first time I have ever seen both a browser warning and a full windows 8.1 prompt refusing to run an installer | 19:43 | |
FROGGS | Ulti: if someone would help me to accomplish that... | 19:44 | |
Ulti | yeah if I could I would, I have the means but not the know how to do rakudo builds on windows | ||
TimToady | okay, now I have a .words that is six times faster than the .comb :) | ||
diakopter | I think pmichaud has a keypair for it or somethingg | ||
Ulti | I use this machine just for games ;P | ||
moritz | I'll happily sign any Star .msi | ||
... with GPG :) | |||
FROGGS | :o) | ||
PerlJam | TimToady++ | 19:45 | |
Ulti | FROGGS++ well it runs >:3 | 19:46 | |
on windows 8.1 | |||
FROGGS | built on WinXP :P | ||
Ulti | using panda wasn't so easy fatal: could not create work tree dir 'C:\Users\Matthew\.panda-work\1409773602_1'.: No such file or directory | 19:47 | |
FROGGS | yes, that's github.com/tadzik/panda/issues/98 | 19:48 | |
Ulti | oh ok | ||
FROGGS | that seems easy to fix... dunno why it isnt already | ||
dalek | line-Perl5: e8a8e57 | nine++ | / (2 files): Fix all sorts of strange errors on exit caused by double free'd string. SvPV returns a pointer to the string buffer in an SV. NativeCall seems to free strings passed to it, so both Perl 5 and NativeCall were freeing the same string leading to different error messages. Pass a copy of the string instead. |
19:49 | |
nine | YES! | ||
This one took hours to track down... | |||
FROGGS | I can imagine :/ | ||
nine++ | |||
timotimo | there's a trait for string management | ||
nine | timotimo: is it documented somewhere? | 19:51 | |
timotimo | not sure | 19:53 | |
github.com/jnthn/zavolaj/blob/mast...l.pm6#L323 | |||
19:55
lastofthe joined
|
|||
nine | timotimo: thanks. | 19:56 | |
hoelzro | timotimo: how are you even supposed to use that? | 19:59 | |
it doesn't look like a trait to me | |||
dalek | ar: cbe310b | (Tobias Leich)++ | tools/build/star-product.wxs: install windows start menu shortcut compatible with moar |
20:02 | |
20:02
prevost_ left
|
|||
FROGGS | timotimo: I updated the msi so that the shortcut works | 20:02 | |
20:02
colomon left
|
|||
timotimo | cool, thanks | 20:03 | |
why you no timotimo++ in your commit message? :P | |||
FROGGS | hehe, sorry timotimo++ :P | ||
vendethiel | FROGGS++ # thanks! | 20:13 | |
20:14
opendevnet joined
20:15
gtodd joined
20:18
opendevnet left
20:20
spider-mario left
20:22
denis_boyun joined
|
|||
tadzik | nine: hmm, maybe you can bump the refcount and avoid copying? | 20:22 | |
nine++ # tracking down rough stuff | 20:23 | ||
20:24
[Sno] left
|
|||
nine | tadzik: I probably could if I find out how to keep NativeCall from freeing the string. | 20:25 | |
20:25
[Sno] joined,
[Sno] left
|
|||
tadzik | nine: or tell it to decrease the refcount instead | 20:25 | |
maybe Nativecall should have something like "call this instead of free()" | |||
nine | Oh! I just figured that since callbacks reference the objects, that means the GC still knows that they are in use and I don't have to do anything :) | 20:26 | |
20:26
spider-mario joined
|
|||
tadzik | it'd probably also help things like gtk | 20:26 | |
glib in general | |||
nine | But this brings me to the question: when are NativeCall callbacks actually freed? | ||
I probably have to do that myself. Can I just free() them? in my Perl6::Object destructor? | 20:27 | ||
20:27
spider-mario left
|
|||
tadzik | FROGGS: as for the issue: I don't really know why it doesn't work | 20:27 | |
so it's not easy to fix to me :) | |||
FROGGS | coward! :P | 20:28 | |
dalek | kudo/nom: 39ee9fa | TimToady++ | src/core/Str.pm: don't implement .words with .comb Runs about six times faster now. |
20:29 | |
tadzik | TimToady++ | ||
FROGGS | TimToady++ | 20:30 | |
timotimo | is it also still faster for short strings? | 20:31 | |
20:33
denis_boyun left,
mr-foobar left
|
|||
TimToady | probably | 20:40 | |
dalek | kudo-star-daily: f10f88a | coke++ | log/ (14 files): today (automated commit) |
20:43 | |
rl6-roast-data: efe0fe5 | coke++ | / (6 files): today (automated commit) |
|||
[Coke] | lots of failures across platforms in S32-temporal/local.t | 20:44 | |
parrot still dying after the 1/0 update (and fix) | 20:45 | ||
kjs_ | TimToady: Just wondering (as a lurker): the original code was 2 lines, which I would say is impressive, compared to the new 20-line implementation. Is this just a temporary replacement until .comb gets faster? | ||
20:45
spider-mario joined
|
|||
TimToady | well, if .comb gets considerably faster, we can consider it :) | 20:45 | |
timotimo | right | ||
20:46
colomon joined
|
|||
TimToady | there are probably a general class of .comb patterns that reduce to what .words is doing, and could be optimized the same way | 20:46 | |
kjs_ | ok. just hard to imagine that so much code is 6 times faster than the 2-line implementation :-) | 20:47 | |
20:47
Ven joined
|
|||
[Coke] | bulding rakudo behind a firewall. using --git-protocol to rakudo's configure. can't build moar because of the submodules using their own protocol. | 20:47 | |
sjn | algorithmic complexity ftl | ||
[Coke] | kjs_: take a look at .comb | ||
TimToady | you probably don't realize how hard P5 works to avoid calling the regex engine :) | ||
[Coke] | it's shorter now than it was. | ||
lizmat | TimToady: I wonder whether pack/unpack would benefit from such a treatment | 20:48 | |
TimToady | what is pack/unpack doing that you would like to avoid? | 20:49 | |
20:49
FROGGS[mobile] left,
kaare_ left
|
|||
kjs_ | [Coke]: oh right - you mean when you consider match as well. | 20:52 | |
TimToady | regex has a lot of setup/teardown at the best of times | ||
20:54
rindolf left
20:56
kurahaupo joined
20:58
treehug88 joined
|
|||
lizmat | TimToady: for $template.comb(/<[a..zA..Z]>[\d+|'*']?/) -> $unit { | 20:58 | |
hmm... that's really just set up | 20:59 | ||
21:03
zakharyas left,
_thou joined
21:08
anaeem1_ left,
_thou left
21:10
dwarring joined
21:11
colomon left
21:12
Ven left
21:13
Rotwang joined,
ab5tract joined,
Rotwang left
|
|||
dalek | p: f6ceab6 | (David Warring [email@hidden.address] | examples/rubyish/ (3 files): [examples/rubyish] disable interpolation in single quoted strings etc |
21:15 | |
ab5tract | m: my @greetings = '\o\', '\o/', '/o/' | 21:17 | |
camelia | rakudo-moar c524e7: OUTPUT«===SORRY!=== Error while compiling /tmp/k1DP__aMpBMissing semicolon.at /tmp/k1DP__aMpB:1------> my @greetings = '\o\', '\⏏o/', '/o/' expecting any of: postfix» | ||
ab5tract | m: my @greetings = '\o\', '\o/', '/o/'; | ||
camelia | rakudo-moar c524e7: OUTPUT«===SORRY!=== Error while compiling /tmp/6FQeQZCvfBMissing semicolon.at /tmp/6FQeQZCvfB:1------> my @greetings = '\o\', '\⏏o/', '/o/'; expecting any of: postfix» | ||
ab5tract | m: my @greetings = '\o\', '\\o/', '/o/'; | 21:18 | |
camelia | rakudo-moar c524e7: OUTPUT«===SORRY!=== Error while compiling /tmp/Mdzspluk1bMissing semicolon.at /tmp/Mdzspluk1b:1------> my @greetings = '\o\', '\⏏\o/', '/o/'; expecting any of: postfix» | ||
ab5tract | seems a bit odd | 21:19 | |
anyway, greetings! | |||
dg | m: my @greetings = '\o\\', '\o/', '/o/'; | ||
camelia | ( no output ) | ||
ab5tract | m:'\o\', '\\o/', '/o/'.roll(6); | 21:20 | |
21:20
gfldex left
|
|||
ab5tract | m: '\o\\', '\o/', '/o/'.roll(6); | 21:20 | |
camelia | ( no output ) | ||
lizmat | m: < \o/ o/ /o >.roll(6).say | 21:21 | |
camelia | rakudo-moar c524e7: OUTPUT«o/ o/ /o /o /o \o/» | ||
lizmat | m: < \o/ o/ /o >.pick(*).say | ||
camelia | rakudo-moar c524e7: OUTPUT«\o/ o/ /o» | ||
lizmat | m: < \o/ o/ /o >.pick(*).say | 21:22 | |
camelia | rakudo-moar c524e7: OUTPUT«/o o/ \o/» | ||
lizmat | *phew* | ||
ab5tract | m: < \o/ /o/ \o\ >.pick(*).say | 21:24 | |
camelia | rakudo-moar c524e7: OUTPUT«\o\ \o/ /o/» | ||
ab5tract | ok | ||
so just stick to < > for lists of single quoted text :) | |||
i think i can do that | |||
i had a different question in mind though | 21:25 | ||
m: use MONKEY_TYPING; augment class Cool { method como { say "{$.name}.perl is perl" } }; "this".como; | 21:27 | ||
camelia | rakudo-moar c524e7: OUTPUT«No such method 'como' for invocant of type 'Str' in block <unit> at /tmp/EHFbbmDbDD:1» | ||
ab5tract | m: use MONKEY_TYPING; augment class Str { method como { say "{$.name}.perl is perl" } }; "this".como; | ||
camelia | rakudo-moar c524e7: OUTPUT«No such method 'name' for invocant of type 'Str' in method como at /tmp/2RgrTdEHnI:1 in block <unit> at /tmp/2RgrTdEHnI:1» | ||
ab5tract | m: use MONKEY_TYPING; augment class Str { method como { say "{$..perl is perl" } }; "this".como; | 21:28 | |
camelia | rakudo-moar c524e7: OUTPUT«===SORRY!=== Error while compiling /tmp/vnSt0brP6lTwo terms in a rowat /tmp/vnSt0brP6l:1------> tr { method como { say "{$..perl is perl⏏" } }; "this".como; expecting any of: argument list …» | ||
ab5tract | m: use MONKEY_TYPING; augment class Str { method como { say "{$.perl is perl" } }; "this".como; | ||
camelia | rakudo-moar c524e7: OUTPUT«===SORRY!=== Error while compiling /tmp/RqDAej_z1ETwo terms in a rowat /tmp/RqDAej_z1E:1------> class Str { method como { say "{$.perl ⏏is perl" } }; "this".como; expecting any of: statement …» | ||
ab5tract | ok sorry guys | ||
lizmat | at the moment, class are closed by default | 21:29 | |
with MONKEY_TYPING you *can* augment a class with a method | |||
ab5tract | m: use MONKEY_TYPING; augment class Str { method como { say "{$.perl} is perl" } }; "this".como; | ||
camelia | rakudo-moar c524e7: OUTPUT«"this" is perl» | ||
lizmat | however, and this is a known bug, that method is *only* visible in the class it is made in | ||
ab5tract | ok | ||
lizmat | it is *not* known in any of its subclasses | ||
ab5tract | makes sense, but also kind of puts a damper on a project i had in mind | 21:30 | |
lizmat | m: use MONKEY_TYPING; augment class Str { method foo { say "foo" } }; "bar".foo | 21:31 | |
camelia | rakudo-moar c524e7: OUTPUT«foo» | ||
ab5tract | which was to create an .explore method and mix it in at the Mu level :) | ||
lizmat | m: use MONKEY_TYPING; augment class Cool { method foo { say "foo" } }; "bar".foo # not seen on Str | ||
camelia | rakudo-moar c524e7: OUTPUT«No such method 'foo' for invocant of type 'Str' in block <unit> at /tmp/C_jCxP68Cn:1» | ||
ab5tract | yeah, that was my question :) | ||
it didn't seem very perl 6-y to have it work in the first case but not in the second | 21:32 | ||
lizmat | not sure if this helps: | ||
use MONKEY_TYPING; augment class Cool { method foo { say "foo" } }; augment class Str { }; "bar".foo | |||
m: use MONKEY_TYPING; augment class Cool { method foo { say "foo" } }; augment class Str { }; "bar".foo | |||
camelia | rakudo-moar 39ee9f: OUTPUT«foo» | ||
lizmat | the main reason for this issue, is that classes currently are very bad parents: | 21:33 | |
ab5tract | so the it just sort of needs a bit of a jump start, eh? | ||
lizmat | children know who their parents are, but parents do not know who their children are | ||
ab5tract | ohh | ||
how very Perl ;) | |||
lizmat | so, when augmenting Cool, it doesn't know who to notify of the changes made | ||
this *will* be fixed at one point, but is not high on the list atm | 21:34 | ||
ab5tract | that would also put a barrier on the .explore idea | ||
on what layer would it need to be addressed? is it an issue in the rakudo nqp code or is it on a vm level? | 21:35 | ||
lizmat | what would such an .explore method do? | ||
I think it would be at the nqp level, with maybe some VM hooks involved | 21:36 | ||
jnthn would know better... | |||
ab5tract | list available methods, documentation on said methods, and explore inter-relationships between the various classes and roles | ||
lizmat | m: say Str.^methods | 21:37 | |
camelia | rakudo-moar 39ee9f: OUTPUT«WHY BUILD Int Num chomp chop substr pred succ match ords lines samecase samespace trim-leading trim-trailing trim words encode wordcase trans indent codes path unival univals WHICH Bool Str Stringy DUMP ACCEPTS Numeric gist perl comb subst split» | ||
lizmat | m: say Str.^methods>>.WHY | ||
camelia | rakudo-moar 39ee9f: OUTPUT«(Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any) (Any)» | ||
ab5tract | and -- the most important part -- leave bits of wisdom and even code examples by also mixing in some methods for adding text | ||
lizmat | no explanation yet :-( | ||
ab5tract | then synchronizing those somehow (optional) | 21:38 | |
so .WHY would explain where the method come from, i gather? | 21:39 | ||
21:39
virtualsue joined
|
|||
ab5tract | *came | 21:39 | |
lizmat | yes, that's the idea | 21:40 | |
look at S26:01 | |||
synopsebot | Link: perlcabal.org/syn/S26.html#line_01 | ||
lizmat | hoelzro has recently done a lot in that area... | ||
hoelzro looks | 21:41 | ||
ab5tract | so yeah .explore would rely on this stuff | ||
hoelzro | lizmat: I'd like to start documenting the core methods, but I don't want to kill parse time =/ | 21:42 | |
lizmat | FWIW, it feels like .explore would be a development tool, so it will probably never live in core | ||
hoelzro | jnthn had the idea of having docs stored elsewhere, perhaps even generated from doc.perl6.org stuff | ||
agreed | |||
there's nothing that says that WHY must come exclusively from #|/#= comments | 21:43 | ||
ab5tract | m: Str.trim.WHEREFORE | ||
camelia | rakudo-moar 39ee9f: OUTPUT«Invocant requires an instance, but a type object was passed in method trim at src/gen/m-CORE.setting:6744 in block <unit> at /tmp/uvwJYpY7n3:1» | ||
lizmat | hoelzro: indeed... | ||
m: "foo".trim.WHEREFORE | 21:44 | ||
camelia | rakudo-moar 39ee9f: OUTPUT«No such method 'WHEREFORE' for invocant of type 'Str' in block <unit> at /tmp/I11mU1sobl:1» | ||
hoelzro | WHEREFORE is on POD objects | ||
lizmat | m: "foo".trim.WHY.WHEREFORE | ||
camelia | rakudo-moar 39ee9f: OUTPUT«No such method 'WHEREFORE' for invocant of type 'Any' in block <unit> at /tmp/HGhegGE04_:1» | ||
21:44
colomon joined
|
|||
ab5tract | gotcha | 21:44 | |
hoelzro | m: #|(hello) sub foo {} ; say(&foo.WHY.WHEREFORE) | ||
camelia | rakudo-moar 39ee9f: OUTPUT«sub foo () { #`(Sub|53068504) ... }» | ||
lizmat | m: #|(hello) sub foo {} ; say &foo.WHY # pod at runtime! | 21:48 | |
camelia | rakudo-moar 39ee9f: OUTPUT«hello» | ||
ab5tract | oh snap! | ||
i like the look of this synopsis | |||
21:50
erkan left
|
|||
ab5tract | and i am definitely into this built in introspection | 21:51 | |
hoelzro | ab5tract: you might also be interested in the meta object API | ||
21:51
erkan joined
|
|||
hoelzro | ex: | 21:51 | |
ab5tract | like so much of my experience with perl 6 so far, the feature is just there already | ||
hoelzro | m: .say for Str.^methods | 21:52 | |
camelia | rakudo-moar 39ee9f: OUTPUT«WHYBUILDIntNumchompchopsubstrpredsuccmatchordslinessamecasesamespacetrim-leadingtrim-trailingtrimwordsencodewordcasetransindentcodespathunivalunivalsWHICHBoolStrStringy…» | ||
hoelzro | eh | ||
m: say Str.^methods | |||
camelia | rakudo-moar 39ee9f: OUTPUT«WHY BUILD Int Num chomp chop substr pred succ match ords lines samecase samespace trim-leading trim-trailing trim words encode wordcase trans indent codes path unival univals WHICH Bool Str Stringy DUMP ACCEPTS Numeric gist perl comb subst split» | ||
hoelzro | that's better. | ||
ab5tract | yeah, i want to make an interface for this. maybe even render it to HTML and serve it on a local port | 21:53 | |
lizmat | m: say Str.^methods.sort | ||
camelia | rakudo-moar 39ee9f: OUTPUT«Code object coerced to string (please use .gist or .perl to do that) in any p6sort at src/vm/moar/Perl6/Ops.nqp:346Code object coerced to string (please use .gist or .perl to do that) in any p6sort at src/vm/moar/Perl6/Ops.nqp:346Code object …» | ||
ab5tract | though something in ncurses could be cool as well ;) | ||
lizmat | m: say Str.^methods>>.gist.sort | ||
camelia | rakudo-moar 39ee9f: OUTPUT«ACCEPTS BUILD Bool DUMP Int Num Numeric Str Stringy WHICH WHY chomp chop codes comb encode gist indent lines match ords path perl pred samecase samespace split subst substr succ trans trim trim-leading trim-trailing unival univals wordcase words» | ||
hoelzro | m: Str.^methods.grep(*.name ne '<anon>').sort(*.name) | ||
camelia | ( no output ) | ||
hoelzro | m: say Str.^methods.grep(*.name ne '<anon>').sort(*.name) | ||
camelia | rakudo-moar 39ee9f: OUTPUT«ACCEPTS BUILD Bool DUMP Int Num Numeric Str Stringy WHICH WHY chomp chop codes comb encode gist indent lines match ords path perl pred samecase samespace split subst substr succ trans trim trim-leading trim-trailing unival univals wordcase words» | ||
ab5tract | m: say Str.^methods.grep(*.name eq '<anon>').sort(*.name) | 21:55 | |
camelia | rakudo-moar 39ee9f: OUTPUT«» | ||
hoelzro | there happen to be none on Str =) | ||
ab5tract | so what's the metamagic to insert some pod onto those methods | 21:56 | |
hoelzro | well, there's nothing spec'd | 21:57 | |
but I happen to know the secret incantations to do so ;) | 21:58 | ||
actually, since we could stick that "incantation" on the end of CORE.setting... | 22:01 | ||
we might be able to easily document core classes/methods without imposing too much extra parse time | |||
it could even be a Configure.pl option | 22:02 | ||
dalek | kudo/nom: cf69d8b | (Elizabeth Mattijsen)++ | src/core/List.pm: Use int in List.ACCEPTS For 1000 element identical lists, this is 14% faster. Benchmark: my @a = ^1000; my @b = ^1000; my $a=0; for ^1000 { $a++ if @a ~~ @b }; say $a From 20 CPU secs to 17.3. |
22:03 | |
lizmat | sleep& so good night, #perl6! | ||
22:04
ajr_ left
|
|||
ab5tract | m: my $ex = "trim"; for Str.^methods -> $m { "$ex.$m = '|#(where) $m.perl'".EVAL } | 22:04 | |
camelia | rakudo-moar 39ee9f: OUTPUT«Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/E5wz6xDqRj:1Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/E5wz6xDqRj:1Not enough positional parameters…» | ||
hoelzro | night lizmat | ||
ab5tract | o/ lizmat ! | ||
22:04
_thou joined
|
|||
ab5tract | i'm pretty sure that road leads to evil | 22:05 | |
hoelzro | ab5tract: which one? | ||
ab5tract | m: for Str.^methods -> $m { "Str.$m = '|#(where) $m.perl'".EVAL }; say Str.^methods>>.WHY; | 22:06 | |
camelia | rakudo-moar 39ee9f: OUTPUT«Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/Dyy6Qxn6Ze:1Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/Dyy6Qxn6Ze:1Invocant requires an instance, b…» | ||
ab5tract | m: for Str.^methods -> $m { "Str.$m.perl = '|#(where) $m.perl'".EVAL }; say Str.^methods>>.WHY; | ||
camelia | rakudo-moar 39ee9f: OUTPUT«Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/fXAwQK1rRy:1Code object coerced to string (please use .gist or .perl to do that) in block <unit> at /tmp/fXAwQK1rRy:1Invocant requires an instance, b…» | ||
hoelzro | ab5tract: you probably want "$m.perl()" | 22:07 | |
ab5tract | m: for Str.^methods -> $m { Str.$m = "'|#(where) $m.perl'".EVAL }; say Str.^methods>>.WHY; | ||
camelia | rakudo-moar 39ee9f: OUTPUT«Invocant requires an instance, but a type object was passed in method WHY at src/gen/m-CORE.setting:5960 in block <unit> at /tmp/EGZbE1lWcV:1» | ||
hoelzro | m: my $m = 'foo' ; say "$m.perl" | ||
camelia | rakudo-moar 39ee9f: OUTPUT«foo.perl» | ||
hoelzro | m: my $m = 'foo' ; say "$m.perl()" | ||
camelia | rakudo-moar 39ee9f: OUTPUT«"foo"» | ||
ab5tract | anyway, as i said, evil :) | ||
hoelzro | very >:) | ||
ab5tract | m: for Str.^methods -> $m { Str.$m = "'|#(where) $m.perl()'".EVAL }; say Str.^methods>>.WHY; | ||
camelia | rakudo-moar 39ee9f: OUTPUT«Invocant requires an instance, but a type object was passed in method WHY at src/gen/m-CORE.setting:5960 in block <unit> at /tmp/UAq2FHbrTb:1» | ||
ab5tract | so what's the magic, doc? | 22:09 | |
:D | |||
m: for Str.^methods -> $m { "Str.$m.perl() = '|#(where) $m.perl()'".EVAL }; say Str.^methods>>.WHY; | |||
camelia | rakudo-moar 39ee9f: OUTPUT«===SORRY!=== Error while compiling EVAL_0Two terms in a rowat EVAL_0:1------> Str.method ⏏WHY (Str:D: *%_) { #`(Method|63575496) . expecting any of: method arguments postfix …» | ||
hoelzro | m: Str.^find_method('trim').set_why('trims the whitespace off of a string') | 22:10 | |
camelia | ( no output ) | ||
hoelzro | m: Str.^find_method('trim').set_why('trims the whitespace off of a string') ; say Str.^find_method('trim').WHY | ||
camelia | rakudo-moar 39ee9f: OUTPUT«No such method 'set_docee' for invocant of type 'Str' in method WHY at src/gen/m-CORE.setting:3501 in block <unit> at /tmp/_4OUQlLWJC:1» | ||
ab5tract | hoelzro: now that's more like it! | ||
hoelzro | interesting | ||
ab5tract: that method may disappear any day now | |||
ab5tract | yeah it should be spec'd | 22:11 | |
hoelzro | so don't get too comfortable with it! | ||
ab5tract | (the solution i mean) | ||
hoelzro | well, I'd rather something like Str.^find_method('trim').WHY = 'trims a string' | ||
agreed | |||
ab5tract | yeah, .WHY should have a .= | 22:12 | |
hoelzro | I tried doing that, but my NQP fu was weak at the time | ||
22:12
lastofthe left
|
|||
hoelzro | I still might not be able to do it | 22:12 | |
someone like jnthn probably could | |||
ab5tract | i think some process of making it even easier could be a good idea too | 22:13 | |
it wouldn't even need to interact directly with the Pod looked up by .WHY | 22:14 | ||
(though the .WHY explanation could be derived from the larger Pod) | |||
22:14
firefish5000 joined
22:15
virtualsue left
|
|||
hoelzro | ab5tract: what exactly do you mean? | 22:15 | |
ab5tract | i'm envisioning a way of making it very easy to add documentation around Perl 6 | 22:17 | |
something like a small web application backed up by a git repository | 22:18 | ||
by backed up i mean the it would source it's content from the git repository | |||
and serve it to your browser over a local port | |||
(or a cool CLI interface, though I think the HTML is easier short term) | 22:19 | ||
kind of like a distributed perlmonks, i guess | |||
hoelzro | ab5tract: so the WHYs of libraries could be populated by such a Git repo? | 22:20 | |
ab5tract | theoretically, yes, but not necessary either | ||
if it were in Rakudo * then it could be the substrate of the shipped docs | 22:21 | ||
hoelzro | ab5tract: that's an interesting idea | 22:22 | |
we'll have to see what TimToady thinks | 22:23 | ||
ab5tract | hoelzro: glad you think so! | ||
i'm curious to hear what he will say | 22:24 | ||
basically i've been spending a lot of time blowing my own mind in the moar repl | |||
and thinking "i wish i had somewhere useful to stash that example" | 22:25 | ||
other than just a flat text file growing in perl 6 examples | 22:26 | ||
22:27
jack_rabbit left
|
|||
hoelzro | like an image? | 22:27 | |
ab5tract | i'd say more like a network | ||
hoelzro | ah ha | 22:28 | |
sorry, I have to go for now | |||
I have class in a bit! | |||
ab5tract | okay, cheers hoelzro ! | ||
hoelzro | later! | 22:29 | |
22:31
Psyche^ joined
22:35
Psyche^_ left
22:38
treehug88 left
|
|||
firefish5000 | How do you extract rules from captures? something like { $_<rule>.say } for $/[*]; ? | 22:40 | |
22:44
sivoais left
22:46
ren1us joined
|
|||
ren1us | anyone know if there's p6 syntax highlighting available for sublime? | 22:46 | |
timotimo | i don't think so :( | 22:53 | |
ren1us | i found this last night, but it doesn't seem to actually do anything: github.com/cognominal/sublime-perl6 | 22:55 | |
22:57
pippo joined,
spider-mario left
22:58
Guest10538 left,
Guest10538 joined
22:59
Guest10538 is now known as skarn
23:00
xragnar_ joined,
xragnar left,
xragnar_ is now known as xragnar
|
|||
japhb | .ask lizmat I saw your benchmark in the comments for the List.ACCEPTS optimization. Care for a perl6-bench commit bit? :-) | 23:01 | |
yoleaux | japhb: I'll pass your message to lizmat. | ||
23:02
kjs_ left
23:12
lastofthe joined
23:16
avuserow left
23:17
beastd left
|
|||
pippo | m: grammar G { rule TOP {<line>}; rule line {\N+}}; G.parse('Hello World'); say $<line>; | 23:18 | |
camelia | rakudo-moar cf69d8: OUTPUT«「Hello World」» | ||
pippo | m: grammar G { rule TOP {<line>}; rule line {\N+}}; G.parse('Hello World'); say A ~ $<line>; | 23:19 | |
camelia | rakudo-moar cf69d8: OUTPUT«===SORRY!=== Error while compiling /tmp/BkZ3UBIcMoUndeclared name: A used at line 1» | ||
23:19
BenGoldberg joined
|
|||
pippo | m: grammar G { rule TOP {<line>}; rule line {\N+}}; G.parse('Hello World'); say ~A ~ $<line>; | 23:19 | |
camelia | rakudo-moar cf69d8: OUTPUT«===SORRY!=== Error while compiling /tmp/kudVtopjseUndeclared name: A used at line 1» | ||
pippo | m: grammar G { rule TOP {<line>}; rule line {\N+}}; G.parse('Hello World'); say 'A' ~ $<line>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«AHello World» | ||
pippo | m: grammar G { rule TOP {<line>}; rule line {\N+}}; G.parse('Hello World'); say $<line>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«「Hello World」» | 23:20 | |
pippo | firefish5000: ^^ does this help? | ||
firefish5000 | Unfortunatly no. My case is something like... | 23:23 | |
m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); for $/[*] { say $_<word>;} | |||
camelia | ( no output ) | ||
firefish5000 | m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); for $/[0..*] { say $_<word>;} | ||
camelia | ( no output ) | ||
firefish5000 | m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); say $/[0]<word>; | 23:24 | |
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
pippo | m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); say $<word>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | But I keep getting (Any) or 'postcircumfix:<{ }> not defined for type' Any/Array | 23:25 | |
23:25
mberends left,
BenGoldberg left
|
|||
pippo | m: grammar G { rule TOP { <word>+ }; rule word {\S+}}; G.parse('Hello World'); say $<word>; | 23:25 | |
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); say $/.perl; | 23:26 | |
camelia | rakudo-moar cf69d8: OUTPUT«Any» | ||
pippo | m: grammar G { rule TOP { <word>+ }; rule word {\S+}}; my $result = G.parse('Hello World'); say $result<word>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
23:26
BenGoldberg joined
|
|||
firefish5000 | m: grammar G { rule TOP { (<word>)+ }; rule word {\S+}}; G.parse('Hello World'); say $/; | 23:26 | |
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | mayby I mistyped something this time | ||
pippo | m: grammar G { rule TOP { <word>+ }; rule word {\w+}}; my $result = G.parse('Hello World'); say $result<word>; | 23:27 | |
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
pippo | m: grammar G { rule TOP { <word>+ }; rule word {\w+}}; my $result = G.parse('Hello World'); say $/; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | m: grammar G { rule TOP { (<word>)+ }; token word {\S+}}; G.parse('Hello World'); say $/; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | m: grammar G { rule TOP { <word>+ }; token word {\S+}}; G.parse('Hello World'); say $/; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
firefish5000 | m: grammar G { rule TOP { <word>+ }; token word {\S+}}; my $res = G.parse('Hello World'); say $res.perl; | 23:28 | |
camelia | rakudo-moar cf69d8: OUTPUT«Any» | ||
firefish5000 | Ahh, stupid mistak here... I never match the space | 23:30 | |
m: grammar G { rule TOP { (<word>+\s+) }; token word {\S+}}; my $res = G.parse('Hello World'); say $res.perl; | |||
camelia | rakudo-moar cf69d8: OUTPUT«Any» | ||
firefish5000 | m: grammar G { rule TOP { (<word>\s*)+ }; token word {\S+}}; my $res = G.parse('Hello World'); say $res.perl; | ||
camelia | rakudo-moar cf69d8: OUTPUT«Match.new(orig => "Hello World", from => 0, to => 11, ast => Any, list => ([Match.new(orig => "Hello World", from => 0, to => 6, ast => Any, list => ().list, hash => EnumMap.new("word", Match.new(orig => "Hello World", from => 0, to => 5, ast => Any, list …» | ||
firefish5000 | m: grammar G { rule TOP { (<word> \s+)+ }; rule word {\S+}}; G.parse('Hello World'); for $/[0..*] { say $_<word>;} | 23:31 | |
camelia | ( no output ) | ||
firefish5000 | m: grammar G { rule TOP { (<word> \s+)+ }; rule word {\S+}}; G.parse('Hello World'); say $/.perl;} | ||
camelia | rakudo-moar cf69d8: OUTPUT«===SORRY!=== Error while compiling /tmp/H_36zwMLktUnexpected closing bracketat /tmp/H_36zwMLkt:1------> }}; G.parse('Hello World'); say $/.perl;⏏}» | ||
firefish5000 | m: grammar G { rule TOP { (<word> \s+)+ }; rule word {\S+}}; G.parse('Hello World'); say $/.perl; | 23:32 | |
camelia | rakudo-moar cf69d8: OUTPUT«Any» | ||
TimToady | that can't match | ||
\s+ requires a space after World | 23:33 | ||
firefish5000 | m: grammar G { rule TOP { (<word> \s*)+ }; rule word {\S+}}; G.parse('Hello World'); say $/.perl; | ||
camelia | rakudo-moar cf69d8: OUTPUT«Match.new(orig => "Hello World", from => 0, to => 11, ast => Any, list => ([Match.new(orig => "Hello World", from => 0, to => 6, ast => Any, list => ().list, hash => EnumMap.new("word", Match.new(orig => "Hello World", from => 0, to => 5, ast => Any, list …» | ||
firefish5000 | Ahh, Thanks TimeToady. | ||
TimToady | and you don't really need it there anyway | 23:34 | |
firefish5000 | *TimToady. | ||
pippo | m: grammar G { rule TOP { (<word> \s*)+ }; rule word {\S+}}; G.parse('Hello World'); say $<word>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Any)» | ||
TimToady | m: grammar G { rule TOP { (<word> )+ }; rule word {\S+}}; G.parse('Hello World'); say $/.perl; | ||
camelia | rakudo-moar cf69d8: OUTPUT«Match.new(orig => "Hello World", from => 0, to => 11, ast => Any, list => ([Match.new(orig => "Hello World", from => 0, to => 6, ast => Any, list => ().list, hash => EnumMap.new("word", Match.new(orig => "Hello World", from => 0, to => 5, ast => Any, list …» | ||
TimToady | since 'rule' already implies that whitespace matches \s* | ||
I wouldn't use rule for word though, it's obviously just a token | 23:35 | ||
m: grammar G { rule TOP { (<word> )+ }; token word { \S+ }}; G.parse('Hello World'); say $/.perl; | |||
camelia | rakudo-moar cf69d8: OUTPUT«Match.new(orig => "Hello World", from => 0, to => 11, ast => Any, list => ([Match.new(orig => "Hello World", from => 0, to => 6, ast => Any, list => ().list, hash => EnumMap.new("word", Match.new(orig => "Hello World", from => 0, to => 5, ast => Any, list …» | ||
TimToady | m: grammar G { rule TOP { <word> + }; token word { \S+ }}; G.parse('Hello World'); say $/.perl; | 23:36 | |
pippo | m: grammar G { rule TOP { (<word> )+ }; token word { \S+ }}; my $result = G.parse('Hello World'); say $result<word>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«Match.new(orig => "Hello World", from => 0, to => 11, ast => Any, list => ().list, hash => EnumMap.new("word", [Match.new(orig => "Hello World", from => 0, to => 5, ast => Any, list => ().list, hash => EnumMap.new()), Match.new(orig => "Hello World", from …» | ||
rakudo-moar cf69d8: OUTPUT«(Any)» | |||
TimToady | m: grammar G { rule TOP { <word> + }; token word { \S+ }}; G.parse('Hello World'); say $/<word>; | ||
camelia | rakudo-moar cf69d8: OUTPUT«「Hello」 「World」» | ||
firefish5000 | Well, its just a test case, so rule should work | ||
m: grammar G { rule TOP { (<word> )+ }; rule word {\S+}}; G.parse('Hello World'); for $/[*] { say $_<word> ; } ; | |||
camelia | rakudo-moar cf69d8: OUTPUT«postcircumfix:<{ }> not defined for type Array in method gist at src/gen/m-CORE.setting:13326 in sub say at src/gen/m-CORE.setting:14281 in block <unit> at /tmp/44w8QIaKf6:1» | ||
TimToady | see what I did | 23:37 | |
<word> + | |||
m: grammar G { rule TOP { [<word> ]+ }; token word { \S+ }}; G.parse('Hello World'); say $/<word>; | 23:38 | ||
camelia | rakudo-moar cf69d8: OUTPUT«「Hello」 「World」» | ||
TimToady | there's another way | ||
if you don't like the ws before the + | |||
pippo | m: grammar G { rule TOP { [<word> ]+ }; token word { \S+ }}; G.parse('Hello World'); say $/<word>.WHAT; | ||
camelia | rakudo-moar cf69d8: OUTPUT«(Array)» | ||
pippo | m: grammar G { rule TOP { [<word> ]+ }; token word { \S+ }}; G.parse('Hello World'); .say for $/<word>; | 23:39 | |
camelia | rakudo-moar cf69d8: OUTPUT«「Hello」 「World」» | ||
firefish5000 | But, in the case of [(<rule1>||<rule2>)\h*\n?]+, is there a way to keep the order? | ||
pippo | I learned a new thing. Thank you TimToady. | 23:40 | |
23:40
xenoterracide joined
|
|||
TimToady | [$<rule>=(<rule1>||<rule2>)\h*\n?]+ or so | 23:40 | |
or just write a rule that does rule1||rule2 | 23:41 | ||
don't try to pack too much into one regex | |||
firefish5000 | hmm, I suppose that would work.. but it makes the last 2hr of struggling seem so pointless. | 23:42 | |
TimToady | you have to enjoy struggling if you're to make it in this line of work :) | 23:43 | |
timotimo | i decided to do a btrfs relocation across devices and not have a backup before starting it ... this will be ... interesting | 23:45 | |
firefish5000 | I enjoy it well. It's just that when the simple answer is given by someone else, I cannot help but feel defeated. | 23:46 | |
firefish5000 guesses that asking for help would be pointless if he doesn't want the answer | |||
TimToady | you are allowed to feel bemused, but you are not allowed to feel defeated :) | 23:47 | |
lastofthe | firefish5000: the path to simple is long and winding :) | ||
TimToady | indeed, it's taken me several decades to get here :) | 23:48 | |
you kind of have to expect to try a thousand ways not to invent the light bulb, and then when you do invent the light bulb, you'll be wrong after another century or so :) | 23:50 | ||
23:50
leont joined
|
|||
TimToady | the only true defeat is one that you learn nothing from | 23:51 | |
that's why it sucks to be dead after one :) | 23:52 | ||
leont | What's the equivalent of perldoc for rakudo? | ||
BenGoldberg | Nicola Tesla invented the flourescent lamp a century ago, but it took until a decade ago for someone to think of twisting it into a helix for more compactness. | 23:53 | |
leont | It seems I'm doing something wrong with spurt, that I think used to work a year ago, but I don't know how I should use it | ||
firefish5000 | well, i'll do my best. although my light bulb usualy needs a centurys worth of refinement. | ||
TimToady: lol | |||
pippo | night #perl6! | ||
leave | |||
23:54
pippo left
|