»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend! Set by lichtkind on 5 March 2010. |
|||
jnthn | Don't make me break out the ASCII YMCA dance. | 00:00 | |
diakopter refrains from making you | 00:01 | ||
00:01
c1sung left,
c1sung joined
00:06
crythias1 joined
00:08
crythias left
00:22
crythias joined
00:25
crythias1 left
|
|||
mberends | colomon: monitor updated with sampling and display options: gist.github.com/369869 | 00:25 | |
colomon | mberends: would change, but in the middle of a run with it right now. ;) | ||
mberends | o/ # going to sleep | 00:26 | |
colomon | mberends: actually, for my taste the nicest change would be to switch it to using stderr instead of stdout. | ||
mberends++ | |||
mberends | colomon: thanks for the feedback, can make that another option | 00:27 | |
jnthn | o/, mberends++ | 00:28 | |
00:35
dual left
|
|||
colomon | jnthn: hmmm. mberends++ tool is not showing an unexpected increase in memory consumption in mandelbrot. (yet, still at smallish numbers.) | 00:37 | |
oh, except I'm not factoring it correctly. | 00:38 | ||
hmmm.... | |||
oh, there we go. | 00:39 | ||
looked at properly, it suggests doubling the edge size a bit more than doubles the memory usage. | |||
but it's nothing crazy yet. | 00:40 | ||
jnthn | OK. | ||
colomon | or maybe it is. | 00:41 | |
okay, here's what's crazy. | |||
jnthn | At the moment, a Complex is heavy. It's IIRC 2 PMCs at a Parrot level per Perl 6 object. A Complex is the Complex object itself + a Num for real part + a Num for imaginary part = 6 PMCs. | ||
colomon | it looks to me like it's doubling like it should be, more or less. | ||
BUT... it's doubling from a HUGE base. | 00:42 | ||
00:42
dual joined
|
|||
jnthn | I may try and patch Parrot pre-R* to get it down to 3. After R* when I do the native types work I should be able to get it down to 1. | 00:43 | |
colomon | actually, Complex might be two Rats in this case. | ||
jnthn | Oh | ||
Then wow. :-) | |||
Rat = Rat object + the two parts = 6 PMCs. | 00:44 | ||
So your total Complex number of two Rats is 14 PMCs. | |||
.oO( no damm wonder it's slow ) |
|||
colomon | hold a sec | 00:45 | |
jnthn | I suspect I may need to try writing that Parrot patch. :-) | ||
colomon | looks to me like it's taking about 4 MB per unit of edge size. | 00:46 | |
ack, it's hard to figure out what units we should be talking about. | |||
If you think switching Rat to Num will make a noticeable, that's an easy enough test to do. | 00:47 | ||
jnthn | I'd be interested to know. | ||
colomon | anyway, 4 MB is insanely high for this. | 00:48 | |
jnthn | What does a "unit of edge size" actually mean? | 00:49 | |
colomon | well, you give it the width / height (ie edge size) on the command line. | 00:51 | |
doubling that quadruples the number of pixels calculated (because the image is square) | |||
that affects the overall timing, and what I'm seeing is right in line with that. | |||
double that also doubles the memory usage. | 00:52 | ||
that sort of makes sense, because since for does not lazily handle its arguments, the entire list of complex values for each row of pixels must be in memory at once. | 00:53 | ||
but at the same time, that implies that 161 Complex numbers requires 1.3 GB to store (according to the numbers I just got), which is insane. | 00:54 | ||
If I'm figuring correctly (based on earlier numbers, too, not those) that's 4MB for each Complex number. | 00:56 | ||
jnthn | erm. | 00:58 | |
That...can't be right. | |||
colomon | I hope not. | ||
jnthn | Or at least, can't be the whole story. | ||
colomon | sure. | 01:01 | |
if you look at the code, it's a nested loop. | 01:02 | ||
diakopter | maybe parrot is allocating more memory unnecessarily (before it actually needs it)? | 01:03 | |
colomon | all results are dumped each time through the outer loop, so that shouldn't be accumulating memory. | ||
and the results suggest it isn't -- if it was, we'd be seeing the memory go up by 4 rather than by 2. | |||
jnthn | diakopter: Not sure. Allocation stratergy tweaks have in the past made notable differences though. | 01:04 | |
colomon | my @line = subdivide($re + ($upper-right.im)i, $re + 0i, ($width + 1) / 2).map({ mandel($_) }); | ||
my $middle = @line.pop; | |||
(@line, $middle, @line.reverse).map({ @color_map[$_] }).join(' ').say; | |||
diakopter | maybe more tweak possibilities exist | ||
jnthn | Undoubtably. | 01:05 | |
colomon | is the inner loop, and increasing $width by 1 increases the memory usage by about 4MB. | ||
diakopter | in the meantime, strategery abound | ||
01:07
rv2733 left
|
|||
colomon | going to run load the dishwasher, will check back in a few minutes to see how the Numified version is doing. | 01:08 | |
01:16
Chillance joined
01:19
wknight8111 left
01:20
ob1 joined
01:22
ob1 left
|
|||
colomon | jnthn: if mberends++' script is accurate, switching to Num shaves 17 seconds off the execution time, and | 01:23 | |
rakudo: say 1520201728 - 1516560384 | |||
p6eval | rakudo 78faa0: OUTPUT«3641344» | ||
colomon | 3.6 MB off the memory usage. | 01:24 | |
jnthn | :/ | 01:25 | |
Which is a tiny fraction of the whole. | 01:26 | ||
colomon | yup | ||
jnthn | Which would seem to suggest we're blowing our memory on something other than the storage. | ||
colomon | other than storage of Complex components anyway, yes. | 01:27 | |
jnthn | Yes, that's what I meant. | ||
diakopter guesses scopes & frames | |||
jnthn | The thing is, we seem to be back to while 1 { 1 } leaking again. | 01:28 | |
Which is really shit. | |||
colomon | could somehow be storage of the Arrays, I suppose... | ||
jnthn | Well, what diakopter said makes some sense too I fear. | 01:29 | |
I guess we're leaking those somehow. | |||
diakopter | maybe they're not being GCd | ||
colomon | even when memory usage gets up into the GBs? | 01:30 | |
jnthn | The bigger problem is why. | ||
diakopter | (even if all references to them are being nulled) | ||
jnthn | Is it a GC mis-configuration. | ||
Or is it lost pointers | |||
Or something else. | |||
diakopter | GC mis-configuration or GC mis-implementation | 01:31 | |
01:31
sorear left
|
|||
jnthn | nod | 01:31 | |
01:31
sorear joined
|
|||
diakopter | try this | 01:32 | |
just do a nested loop of the same structure, but with no storage, just Int counters | |||
and empty arrays though | 01:33 | ||
so map is still called | |||
jnthn | nod | ||
That'd be revealing. | |||
01:34
drbean_ is now known as drbean
|
|||
colomon | I've just noticed that the inner loop is actually map, so in theory.... arrrgh. | 01:34 | |
diakopter | that would tell you whether the problem is in the routine passed to map or in all teh corntol fowl around it | ||
the control flow, even | 01:35 | ||
colomon likes the idea of corntol fowl. | |||
diakopter fights the downwards funargs problem for yet another hour | 01:36 | ||
I should yearn to write in anagrams all the mite | 01:37 | ||
at lates, where I see meth | |||
colomon | I really don't know how to coherently modify the algorithm to not use storage. | ||
oh hey, though, one thing we could easily do is change max_iterations on the inner mandelbrot calculation. | 01:38 | ||
increasing that (say) would cause additional inner loops / calculations without any difference to the longer term storage in the script. | 01:39 | ||
so if just looping is using memory, it would show up that way. | 01:40 | ||
diakopter | apparently ye olde volcano will put Europe back into the Dark Sage | ||
if cable news has anything to say about it. | 01:41 | ||
colomon | Dark Sage! oh no! I prefer rosemary! | ||
my wife just discovered our insurance covers cleanup from volcanic ash! | 01:44 | ||
01:44
meppl left
|
|||
diakopter | but not damage from it? | 01:44 | |
diakopter hides the garage door openers | |||
colomon | she's in the debris removal section, so we don't know. | 01:45 | |
our shrubs are covered against aircraft, too. | 01:46 | ||
jnthn | Better than having your shrubs covered in aircraft, I guess. | ||
diakopter looks around for the punkings | 01:47 | ||
colomon | web search suggests it's been 2.5 billion years since there were active volcanos in Michigan, so they must be worried about the supervolcanos out west.... | ||
diakopter | yeah but big enough eruption can have global effect | ||
spaceship-wide, I should say. | 01:48 | ||
jnthn | Cable news is probably full of crap. | ||
Some airlines are even doing test flights to see what happens to their aircraft if they fly them in the closed airspace. | |||
Apparently, nothing much yet. | 01:49 | ||
colomon | diakopter: sure, but is there likely to be a worldwide volcano eruption which: 1) causes measurable amounts of ask damage to my house and 2) doesn't end civilization in the process? | ||
*ash | |||
diakopter | I guess not. :'( | ||
someone should use bombs to convert the volcanic cone to something that just oozes magma | 01:54 | ||
01:57
Psyche^ joined
|
|||
jnthn | What could possibly go wrong? :-) | 01:58 | |
01:58
nihiliad left
02:01
Patterner left,
Psyche^ is now known as Patterner
|
|||
colomon | just started a size 1001 run for overnight. by my reckoning it should take about 5 hours to run... | 02:01 | |
02:03
rgrau left
02:05
envi^home joined
|
|||
jnthn -> sleep now | 02:07 | ||
o/ | |||
diakopter | o/ | 02:08 | |
colomon | o/ | ||
sorear | colomon: Why? Stress testing? | 02:15 | |
02:18
PZt joined
|
|||
diakopter | .. start with some tomahawks, if that doesn't work, maybe a trident. | 02:19 | |
02:21
meppl joined
02:28
crythias left
02:34
_jaldhar joined
02:35
eternaleye joined
|
|||
diakopter | hm. | 02:38 | |
sorear | also, you do not need volcanos to have fun with ash | ||
diakopter | sorear: you might be interested: | 02:41 | |
I'm trying to solve the downward funargs problem for perlesque | |||
sorear | funargs problem? ick | ||
diakopter | er | ||
yes | |||
downwards funarg, I mean. :| | |||
en.wikipedia.org/wiki/Funarg_proble...rg_problem | 02:42 | ||
The second paragraph under "Practical Limitations" is exactly what perlesque does. | 02:43 | ||
diakopter keeps at it | 02:44 | ||
03:06
cledu left
03:13
jaldhar_ joined
03:14
_jaldhar left
03:35
fridim joined
03:36
jaldhar_ left,
jaldhar_ joined
03:43
meppel joined
03:46
meppl left,
meppel is now known as meppl
|
|||
sorear | diakopter: the Wikipedia Funarg Problem is ... not at all the same as the funarg problem I know | 03:47 | |
diakopter | oh | 03:52 | |
sorear: which one do you know | 03:53 | ||
the one described in terms of free variables and their binding and activation environments? | |||
03:58
Chillance left
|
|||
diakopter figured it out. | 04:01 | ||
diakopter can't decide which is more fun: having cake or eating cake. | 04:05 | ||
sorear | diakopter: yes, the free variable binding problem in Lisp-2 | 04:07 | |
the one which was solved by the invention of lexical scope | |||
diakopter | oh :) | 04:09 | |
you're saying "lexical scope" makes the binding environment synonymous with the declaration environment. | 04:11 | ||
there could have been other ways to do it | |||
since there are a couple levels of "bind" there | |||
sorear | the original funarg problem was a semantic problem, not an implementation one | 04:13 | |
so it could be fixed by conceptual leaps | |||
diakopter | I can imagine a "bind_free_vars" function that is a compile-time instruction to "curry" free variables to particular scopes... | ||
(treating a function declaration like a function template) | |||
(so it doesn't actually curry the values, just the slots) | 04:14 | ||
now _that_ would be metaprogramming. | |||
04:16
jaldhar_ left
|
|||
diakopter | kindof a generalization of 'compose' and 'curry' | 04:16 | |
04:17
jaldhar_ joined
04:19
XaeroOne joined
|
|||
sorear | sooooo.... the CLR uses dynamic scoping? | 04:36 | |
I had no idea Microsoft was /that/ crazy | |||
diakopter | nope | ||
sorear | so why are you having a funarg problem? | ||
diakopter | CIL (its assembly language) doesn't have scoping | ||
at all | |||
b/c perlesque has lexical and dynamic scoping (and closures, and continuations for that matter), and I'm compiling perlesque to CIL | 04:37 | ||
so all closures must be strongly typed on each's full signature | |||
so I need variables of particular closure-types to be able to store closures with identical signatures. | 04:38 | ||
(but different function bodies, obviously) | |||
.. and I'm ignoring co- and contra-variance on signatures entirely. | 04:39 | ||
stackframes are reified as CIL objects on the heap, and codegen to resolve all lexical slots is done at compiletime | 04:40 | ||
sorear | sounds like perlesque is a real exercise in Turing completeness | 04:47 | |
TimToady | oddly, Perl 5 gets around the whole issue without putting the activation stack on the heap | 04:48 | |
at the expense of having to clone closures, basically | |||
diakopter | sorear: Guy Steele explains the definition drift/specification of the funarg problem: people.csail.mit.edu/gregs/ll1-disc...03278.html | ||
TimToady: but that's the same thing.. | 04:49 | ||
aren't the cloned closures activation records themselves? | |||
TimToady | yes, well, you might say it's using indirection to solve the problem :) | 04:50 | |
sorear | TimToady: essentially, Perl 5 does keep activation records on the heap; the pad is only an index, lexicals are 'struct sv' in the arena | ||
diakopter | ok. perlesque does the same thing in an OO way; a closure class is created for each subroutine, and instances of that closure class hold links to their proper parent scopes | 04:51 | |
TimToady | yeah, I suppose, depending on whether you consider the lexpads to be part of the activation record :) | ||
diakopter | each perlesque subroutine also has a 'frame' class, from which its activation records are spawned; those are the lexpads themselves, and also hold links to each's Caller frame | 04:52 | |
04:53
jaldhar_ left,
jaldhar_ joined
|
|||
diakopter | sigh. there's also a 'bind' interface created for each unique subroutine interface, and a 'return' interface created for each unique return type. *sigh* so that it's all still strongly-typed. | 04:54 | |
Yes, OOdles of casting. | |||
04:55
jaldhar_ left
|
|||
diakopter | s/subroutine interface/subroutine signature/ | 04:55 | |
04:55
jaldhar_ joined
|
|||
sorear | TimToady: That reminds me of another question I've had for a long time. Why does Perl 5 have one stack per CV, instead of the more traditional approach of intermixing all activation records on a common stack? | 04:55 | |
diakopter | someone help the n00b; what's a CV | ||
sorear | the perl 5 data structure which represents a sub or closure instance (or format, but let's not go there) | 04:57 | |
diakopter | ok | ||
sorear | the target of CODE references | ||
04:57
gfx joined
|
|||
sorear | s/Perl/perl/ | 04:58 | |
04:59
ReiniUrban joined
|
|||
diakopter | sorear: that's an interesting question. actually I considered a model something like that | 04:59 | |
diakopter waits for TimToady comment | 05:00 | ||
sorear: I guess that's one way of tracking recursion depth | |||
05:00
justatheory left
05:01
rurban left,
ReiniUrban is now known as rurban
|
|||
diakopter | oh, I see. the caller link on the last frame must point to the CV itself and not to the top record on that CV's stack. | 05:01 | |
(I'm not saying I know *why* it was done that way) | 05:02 | ||
oh | 05:03 | ||
sorear | um, why would anyone want to track recursion depth | ||
diakopter | sorear: another benefit is that it separates the code from the lexpads, so that code can be changed | ||
after a frame has been entered | |||
I dunno; warnings tracks it, doesn't it? | 05:04 | ||
sorear | activations and code are separated in every model | ||
TimToady | well, last I looked, the CVs themselves were all on their own stack separate from the lexpads, but that might have changed since then | ||
sorear | I'm not asking about CVs | 05:05 | |
I'm asking why there are so many padlists | |||
Why isn't there a single global PL_padstack? | |||
05:06
c1sung left
|
|||
TimToady | actually, the CX statck | 05:06 | |
*stack | |||
one reason for tracking recursion level (besides warning on deep recursion) is that we cache a lexpad at each level | |||
sorear | or, for that matter, the lexicals /could/ have been stored on PL_stack | ||
TimToady | so it's only allocated from the heap the first time we want one at that level | ||
Perl 5 keeps a lot of stacks that most other implementations combine | 05:08 | ||
you might think of the various stacks as having a rudimentary form of typing | 05:09 | ||
diakopter | hee | 05:10 | |
YA typing layer | |||
TimToady | I don't recommend you do it that way | ||
it was mostly driven by trying to fake out C macros to do the right thing | |||
diakopter | me? | ||
diakopter wonders if there are "compile Perl successfully" test cases in C compilers' regression suites | 05:11 | ||
TimToady | that was a major test in gcc, at least at one time | ||
diakopter not surprised | |||
seems it would be difficult to break down the tests... | 05:12 | ||
TimToady | at the time, perl put more stress on the compiler than many other open source projects could | ||
this was before the big projects we know and love today | 05:13 | ||
diakopter | I guess that's one way to out-lock-in the vendors | ||
05:14
Xaero joined
05:16
molaf joined
|
|||
sorear | reminds me of the way we used to smoke new DIMMs using gcc before memtest86+ came out | 05:16 | |
typically on Linux or Xfree86 | |||
05:17
c1sung joined,
XaeroOne left
|
|||
sorear | "run make World; make realclean in a loop for 24 hours. Check for cores." | 05:17 | |
05:25
justatheory joined
05:33
phenny left
05:34
nsh left,
sbp left
05:35
Sarten-X joined
05:37
Maxt0r joined,
nsh joined
|
|||
Maxt0r | hi | 05:37 | |
05:37
sbp joined
|
|||
diakopter | Maxt0r: hi | 05:38 | |
Maxt0r | i have a problem with a split function am using can anyone hepl plz | ||
i have a file i open it n read form it as follows :open (FH, $filename) || die ("Could not open $filename!"); | |||
then i pass info to an array : my @xxx =<FH>; | 05:39 | ||
diakopter | TimToady: you still around? | ||
Maxt0r: this is a Perl 6 channel | |||
Maxt0r | foreach $line (<FH>) | ||
perl 6?^ | |||
whats the dif | |||
can u help me out? | |||
diakopter | a lot of differences. :) see perl6.org | ||
Maxt0r | can u help me | 05:40 | |
with this quiestion is simple | |||
my split function is not spliting lols | |||
diakopter | probably #perl can help you out more | ||
Maxt0r | ok | ||
nvm ty | |||
diakopter | yw | ||
sorear | Where did all the vowels go? | 05:44 | |
diakopter | gn wth th wnd | ||
sorear: check this out :) | 05:45 | ||
perlesque: my $last = 4; my $sub_a = sub int foo (int $arg0) { say(my $b = $arg0 + 5); $last = $b; return $b; }; my $sub_b = $sub_a; $sub_b(4); $sub_b = sub int bar (int $arg0) { say(my $b = $arg0 + 4); if ($b>19) { $sub_b = $sub_a; }; $last = $b; return $b; }; while ($last < 100) { $sub_b($last); }; | |||
p6eval | perlesque: OUTPUT«9131721263136414651566166717681869196101» | ||
05:45
fridim left
|
|||
diakopter | full type inference for expressions | 05:45 | |
(as long as you like either ints or closures) :D (but yes, it'll work for any CLR type) | 05:46 | ||
and those $sub_a and $sub_b variables can store each other's routines, since they have identical signatures. | |||
(as you can see, the output series increments by 4 until it's > 19, when it starts incrementing by 5) | 05:47 | ||
sorear: cool or what? :) | |||
sorear | I've implemented Damas-Milner | ||
it's going to take more than /that/ to impress me | 05:48 | ||
05:48
fridim joined
|
|||
diakopter | it's the closures-as-variables I'm pointing at | 05:48 | |
as soon as I can get type-prototyping working, closures can be arguments and return values, too | 05:50 | ||
TimToady: actually that presents a problem for me. | |||
I mean, I have an idea to work around it in perlesque, but it'll make it no longer a Perl 6 subset | 05:51 | ||
how to represent the types of closures in signatures. | |||
in C#, it would be Func<param0_type, param1_type, param2_type, ... , return_type> and Action<param0_type, param1_type, param2_type, ...> for routines that return Void | 05:53 | ||
sorear | I think GRIN might be relevant to you | ||
diakopter | GRIN? | 05:54 | |
05:54
XaeroOne joined
|
|||
sorear | the Graph Reduction Intermediate Notation | 05:54 | |
a very interesting body of work concerning strongly-typed implementation formulations for higher-order languages | 05:55 | ||
not /directly/ relevant, you aren't implementing a global superoptimizer for Haskell, but ... has parallels | |||
05:56
Xaero left
|
|||
diakopter | heh | 05:56 | |
in this case, I just need a notation | |||
jql | hmm... I guess you can't just steal parentheses as function type description notation | 05:57 | |
diakopter | TimToady will reply sometime... | 05:59 | |
my idea was to use other existing closure variables as prototypes | |||
so in the example above, I worked around it by assigning $sub_a a dummy empty routine | 06:00 | ||
jql | hmm, there is a syntax for closure parameter declarations already. spiffy | 06:01 | |
diakopter | but instead of a typename, if there was some sig_of($other_strongly_typed_closure_with_signature) operator, I could put that in place of the typename in the function signature | ||
orly? | |||
do tell | |||
jql | my sub testit (&testcode:(Int)) {testcode(12)} | ||
diakopter | oh hah | ||
where'd you find that | |||
jql: thanks! :) | 06:02 | ||
jql | multi sub t1 (&code:(Str --> Bool)) { 'Str --> Bool' }; | ||
return types, too | |||
diakopter | ahh, I see | ||
ok, now what if &code and t1 there have types that are mutually recursive | 06:03 | ||
jql whips out the handy book of combinators | |||
I believe.... $math | |||
diakopter waits | 06:05 | ||
diakopter goes to get a drink | 06:07 | ||
jql | hmm... perhaps multi sub t1 (::T, &code:(::T --> ::U)) or some such nonsense | ||
with a --> U at the end | 06:08 | ||
multi sub t1(::T, &code:(T, ::U)) --> U, if that was a valid thing to do. *shrug* | 06:09 | ||
multi sub t1(::T, &code:(T --> ::U)) --> U # comma is *so* tempting | 06:10 | ||
06:17
Maxt0r left
|
|||
diakopter | ok | 06:31 | |
cognominal | nqp: say(<a b c>) | 06:32 | |
p6eval | nqp: OUTPUT«3» | ||
cognominal | nqp: my @a := <a b c>; say(@a) | 06:33 | |
p6eval | nqp: OUTPUT«3» | ||
diakopter | nqp: (<a b c>).say | 06:34 | |
p6eval | nqp: OUTPUT«Method 'say' not found for invocant of class 'ResizablePMCArray'current instr.: '_block11' pc 0 (EVAL_1:6)» | ||
diakopter | /o/ | 06:35 | |
cognominal | nqp: my @a := ('a', 'b', 'c'); say(@a) | 06:38 | |
p6eval | nqp: OUTPUT«3» | ||
cognominal | nqp: my @a := ('a', 'b', 'c'); say(@a[0]) | 06:39 | |
p6eval | nqp: OUTPUT«a» | ||
06:41
rv2733 joined,
Exodist_ is now known as Exodist
06:52
rv2733 left,
phenny joined
07:07
gfx left
07:10
finanalyst joined
07:14
Kyril left
|
|||
finanalyst | perl6: role A { has $.att}; my $x .=new(:att<$y>); say $x.att | 07:19 | |
p6eval | elf 30402: OUTPUT«Can't call method "att" on an undefined value at (eval 123) line 9. at ./elf_h line 5881» | ||
..pugs: OUTPUT«*** No such method in class Item: "&att" at /tmp/Gy8CVyuj6W line 1, column 49 - line 2, column 1» | |||
..rakudo 78faa0: OUTPUT«Method 'att' not found for invocant of class 'Any'current instr.: '_block14' pc 29 (EVAL_1:0)» | |||
sorear | is perl6: just an alias for elf: pugs: rakudo: ? | 07:20 | |
finanalyst | rakudo: role A {has $.col}; my A $x .= new(:col<$y>); $x.col.say | 07:21 | |
p6eval | rakudo 78faa0: OUTPUT«$y» | ||
07:21
XaeroOne left
|
|||
sorear | and if so, why no alpha: ? | 07:21 | |
07:21
XaeroOne joined
|
|||
finanalyst | it seems to me that $y should be flagged as not having been declared | 07:22 | |
07:22
cotto_w0rk joined
|
|||
finanalyst | any one able to comment? | 07:24 | |
07:32
nsh left,
nsh joined
|
|||
mberends | finanalyst: the <$y> is equivalent to ('$y'), therefore $y are two literal characters | 07:34 | |
finanalyst | mberends: thanx, i just realised that too. just as i was writing a rakudobug! | 07:36 | |
but didnt send it | |||
mberends re-boots to Windows to try process memory monitoring there too | 07:39 | ||
07:39
mberends left
07:45
hicx174 left
07:52
mberends joined
07:54
yahooooo7 joined
07:55
gabiruh_ joined,
cookys_ joined
07:56
diakopte1 joined,
phenny left,
yahooooo left,
cotto left,
cookys left,
Helios left,
diakopter left,
pmurias joined,
frettled_ joined
07:59
Helios joined
08:00
iblechbot joined
08:11
justatheory left
08:15
justatheory joined
08:17
ejs joined
08:22
ejs left,
ejs joined
08:38
pmurias left
08:48
hicx174 joined
08:49
_jaldhar_ joined
08:50
jaldhar_ left,
ejs left
08:52
M_o_C joined
08:55
ejs joined,
ejs left
|
|||
moritz_ | good morning | 08:55 | |
mberends | good morning moritz_ | 08:56 | |
09:06
justatheory left
09:17
XaeroOne left
|
|||
finanalyst | rakudo: role A { has $.x = 2; method doit($y) { return $.x * $y } }; my A $z; say $z.doit(1.5) | 09:19 | |
p6eval | rakudo 78faa0: OUTPUT«Type objects are abstract and have no attributes, but you tried to access current instr.: 'perl6;Attribute;accessor_helper_ro' pc 3554 (src/gen/Attribute.pir:400)» | ||
finanalyst | can anyone tell me what I am doing wrong here? | 09:20 | |
moritz_ | finanalyst: you are not creating a new instance of A | ||
and still you access $.x, which in turn relies on $!x | |||
which is an attributte | |||
finanalyst | isnt the 'my A $z' doing that | 09:21 | |
moritz_ | which you can't access outside of an instance | ||
finanalyst: no, that's merely a type constraint | |||
finanalyst | so how does a role become a class? | ||
moritz_ | automatically, if you want it | ||
finanalyst | rakudo: role A { has $.x = 2; method doit($y) { return $.x * $y } }; my A $z = .new; say $z.doit(1.5) | 09:22 | |
p6eval | rakudo 78faa0: OUTPUT«Type check failed for assignmentcurrent instr.: '&die' pc 17293 (src/builtins/Junction.pir:404)» | ||
moritz_ | rakudo: role A { has $.x = 2; method doit($y) { return $.x * $y } }; my $z = A.new; say $z.doit(1.5) | ||
p6eval | rakudo 78faa0: OUTPUT«3» | ||
finanalyst | yep. beat me to it | ||
moritz_ | I suspect that's a bug in rakudo | 09:23 | |
rakudo: role A { }; my A $x .= new() | |||
finanalyst | rakudo: role A { has $.x = 2; method doit($y) { return $.x * $y } }; my A $z .= new; say $z.doit(1.5) | ||
p6eval | rakudo 78faa0: ( no output ) | ||
rakudo 78faa0: OUTPUT«3» | |||
finanalyst | why a bug? | 09:24 | |
moritz_ | I don't see where the type check failure is coming from | ||
but I'm not quite awake yet | |||
09:32
jaldhar joined
09:33
_jaldhar_ left
09:53
frettled_ is now known as frettled
|
|||
moritz_ | sorear: (backloggin) yes, perl6: just runs different Perl 6 compilers | 09:57 | |
perl6: say "foo"; # one without differences, I hope | 09:58 | ||
p6eval | elf 30402, pugs, rakudo 78faa0: OUTPUT«foo» | ||
10:06
masak joined
|
|||
masak | oh hai, #perl6 | 10:07 | |
mberends | good masak, morning | ||
masak is having a good morning | |||
GGE now runs all tests under master. \o/ | 10:08 | ||
it passes almost half of them, too :) | |||
(as opposed to 100% on alpha) | |||
(well, except for TODOs, of course) | |||
rakudo: role A { has $.x = 2; method doit($y) { return $.x * $y } }; my A $z = .new; say $z.doit(1.5) | 10:09 | ||
p6eval | rakudo 78faa0: OUTPUT«Type check failed for assignmentcurrent instr.: '&die' pc 17293 (src/builtins/Junction.pir:404)» | ||
masak | rakudo: class A { has $.x = 2; method doit($y) { return $.x * $y } }; my A $z = .new; say $z.doit(1.5) | 10:10 | |
p6eval | rakudo 78faa0: OUTPUT«Type check failed for assignmentcurrent instr.: '&die' pc 17293 (src/builtins/Junction.pir:404)» | ||
masak | rakudo: class A {}; my A $x .= new | ||
p6eval | rakudo 78faa0: ( no output ) | ||
masak | interesting. | ||
rakudo: class A { has $.x }; my A $x .= new | |||
p6eval | rakudo 78faa0: ( no output ) | ||
masak | rakudo: class A { has $.x = 2 }; my A $x .= new | ||
p6eval | rakudo 78faa0: ( no output ) | ||
masak | oh! | 10:11 | |
.new | |||
never mind :) | |||
sorear | GGE? | ||
masak | it's a port of PGE to Perl 6. | 10:12 | |
PGE is pmichaud++'s Perl 6 grammar engine, written in PIT. | |||
*PIR | 10:13 | ||
10:13
snarkyboojum joined
|
|||
masak | snarkyboojum! \o/ | 10:13 | |
snarkyboojum | masak: hello! o/ | ||
masak | snarkyboojum: I might start that 'immediate blocks' branch today in Yapsi. | ||
snarkyboojum | masak: just having fun wasting time getting my new macbook pro up and running - rakudo builds quickly on an i7 :) | 10:14 | |
masak | ooh, nice. | ||
snarkyboojum | masak: sounds awesome - I'll have to follow along | 10:15 | |
masak | I'm hoping to keep that branch fairly short-lived. | ||
snarkyboojum | sure | 10:16 | |
masak | basically just add tests like 'my $a; { ++$a }; say $a', and implement the bare minumum to get it working. | ||
snarkyboojum | would be interesting to watch it in progress however short lived :) | ||
masak | I see it as the big step Yapsi will take this month. | 10:18 | |
snarkyboojum | masak: feel free to let me know if there is anything I can add or think about | ||
masak | it'll enable a lot of other nice things, including ifs, loops and subs. | ||
snarkyboojum: how's it going with Tardis? | 10:19 | ||
snarkyboojum | masak: ah - looked at it, I'll probably have to bounce stuff of you, as I haven't gotten my hands dirty yet | ||
masak | ah, ok. | ||
snarkyboojum | looked like a rewrite of Tardis.pm | 10:20 | |
etc | |||
masak | aye, seems likely. | ||
and it'll need yet another one when we have nested scopes... | |||
snarkyboojum | excellent - perhaps I can forge ahead and see what I can accomplish/break :) | ||
masak | \o/ | 10:22 | |
10:31
Alias joined
10:36
_jaldhar joined,
jaldhar left
10:37
IllvilJa left
|
|||
masak | continuing the 'our'/'my' discussion from yesterday: what default scoping do 'regex' et al. have, such that one is now required to add 'our' or 'my' to it to make it stick in an appropriate lexpad? | 10:38 | |
moritz_ | masak: 'has' | 10:39 | |
sorear | I thought 'regex' could only appear in classes? | ||
masak | moritz_: thought so. | ||
moritz_ | sorear: that restricted was lifted for convenience | 10:40 | |
masak | moritz_: and I suppose that is because they're really methods in sheep's clothing. | ||
moritz_ | masak: aye | 10:41 | |
sorear | moritz_: wasn't you or masak complaining about language bigotry last week on not allowing regex outside grammar | ||
masak | that was I. | ||
it works now, if you do 'my'/'our'. | 10:42 | ||
moritz_ | in rakudo? | ||
10:42
iblechbot left
|
|||
masak | aye. | 10:42 | |
moritz_ | rakudo: our regex foo { '.' }; say '.' ~~ /<foo>/; | ||
p6eval | rakudo 78faa0: OUTPUT«Method 'foo' not found for invocant of class 'Regex;Cursor'current instr.: '_block61' pc 613 (EVAL_1:239)» | 10:43 | |
moritz_ | rakudo: my regex foo { '.' }; say '.' ~~ /<foo>/; | ||
p6eval | rakudo 78faa0: OUTPUT«Method 'foo' not found for invocant of class 'Regex;Cursor'current instr.: '_block65' pc 601 (EVAL_1:229)» | ||
masak | hm. | ||
or not. | |||
moritz_ | what am I doing wrong? :-) | ||
masak | just too early, I guess. :/ | ||
I guess what I'm asking -- and this can be seen as the last throe of my 'bigotry' claim -- is why 'regex' et al. don't default to 'my' scope, and things would work just like they did in alpha. | 10:44 | ||
or, if that helps, they could default to 'my' scope outside of classes and roles, and have 'has' scope inside. | 10:45 | ||
moritz_ | because then they couldn't be called as methods, and thus benefit from inheritance | 10:46 | |
masak | I won't press it. maybe the consistency is important somehow. 'my' is not that hard to remember to add outside of a class, grammar or role. | 10:48 | |
moritz_ | well | ||
there are two things where context sensitive defaults would be benefitial | |||
1) multi foo could default to 'method' inside classes, roles and grammars | |||
and default to subs elsewhere | 10:49 | ||
masak | I've had that same thought. | ||
moritz_ | 2) regex foo could default to 'has' inside classes, roles and grammars, and to 'my' everywhere else | ||
masak | it seems we are in violent agreement. | ||
moritz_ | that goes against the "list of arbitrary things to remember" rule | ||
masak | I guess so. | 10:50 | |
one could put those context-sensitive defaults in a module, I guess. | |||
moritz_ | use magic::default; | 10:51 | |
on a totally unrelated note I've taken care that Date objects are immutable | 10:53 | ||
I guess DateTime objects are not, right? | |||
masak | no, and I thought quite a bit about that. | 10:54 | |
CPAN's DateTime objects are mutable, and make quite good use of it. | |||
moritz_ | aye, I think it makes sense | ||
masak | if you look at the IRC logs, you'll see that my goal was to produce a fairly unchanged subset of CPAN's DateTime :) | ||
I didn't want to break that rule by introducing immutability. | 10:55 | ||
moritz_ | Perl 6 has this tendency to keep simple objects immutable, and more complex objects mutable | ||
so it kind of fits | |||
masak | also, it was fun to make use of intelligent rw accessors (not yet impl in Rakudo) | ||
moritz_ | Mark J. Reed on p6l: | 10:57 | |
my $bday = new Date.new(1968, 5, 5); | |||
my $specifically = DateTime.new(:date($bday), :hour(20), :minute(47)); | |||
or at least, Date should have a method that returns it's value as | |||
pairs suitable for passing to DateTime.new. | |||
another syntax I thought about was | 10:58 | ||
$bday.DateTime(:hour(20), :minute(47)) | |||
masak | I think I prefer the DateTime.new version. | 10:59 | |
moritz_ | currently I lean towards DateTime.new(:date($bday), :hour(20), :minute(47)) - but since DateTime is your domain, I want your opinions... right | ||
mberends | this discussion interests me, but I'll be out for a few hours. Happy bikeshedding! | ||
11:00
mberends left
|
|||
masak | seems the bikeshedding is done already :) | 11:00 | |
moritz_ | mberends: so far we kept the bikeshedding low by having just masak and me discussing it :-) | ||
masak: do we still need DateTime.today() then? | 11:01 | ||
masak | oh! | ||
no, we don't. we'll just force people to use .Date :) | 11:02 | ||
or, I suppose Date.new(...) | |||
I wouldn't mind seeing both in that case. | |||
moritz_ | what's the ...? | ||
masak | Date.new( $dt ), perhaps. | 11:04 | |
or some aptly named named :) | |||
moritz_ | ok | ||
masak | rakudo: say "foo".subst( /(o)/, { $0.uc } ) | 11:07 | |
p6eval | rakudo 78faa0: OUTPUT«Method 'postcircumfix:<[ ]>' not found for invocant of class ''current instr.: '!postcircumfix:<[ ]>' pc 10733 (src/builtins/Role.pir:90)» | 11:08 | |
masak | I'd really like for the above to work again by Rakudo Star. | ||
moritz_ | again? never did | ||
afaict | |||
masak | alpha: say "foo".subst( /(o)/, { $0.uc } ) | ||
p6eval | alpha 30e0ed: OUTPUT«fOo» | ||
moritz_ | huh? | ||
masak | I use it all over the place in my code. | 11:09 | |
moritz_ | rakudo: say "foo".subst( /(o)/, -> $/ { $0.uc } ) | ||
p6eval | rakudo 78faa0: OUTPUT«Method 'uc' not found for invocant of class 'Regex;Match'current instr.: '_block58' pc 757 (EVAL_1:257)» | ||
masak | not cool... | ||
moritz_ | aye | ||
masak | but that's not what I meant. | ||
I meant the closure having the correct $/ | |||
moritz_ | I know | 11:10 | |
11:10
rgrau joined
|
|||
lisppaste3 | moritz_ pasted "DateTime <-> Date integration" at paste.lisp.org/display/97950 | 11:14 | |
masak looks | |||
s/aboved/above/ | 11:15 | ||
moritz_ is glad for git rebase -i | 11:16 | ||
masak | it rocks. | ||
moritz_ | masak: for a moment I was thinking you meant by patch :-) | ||
masak | :) | 11:17 | |
moritz_: looks fine. I'm glad Date and DateTime start talking to each other. | |||
Trashlord | hello, friends | ||
masak | moritz_: do you think that it makes sense to keep DateTime mutable but Date immutable? | ||
Trashlord: hi! | 11:18 | ||
moritz_ | masak: yes | ||
pugssvn | r30403 | moritz++ | [S32::Temporal] Date <-> DateTime integration | ||
r30403 | | |||
r30403 | * DateTime constructor which takes a Date object, as suggested by Mark J. Reed | |||
r30403 | * DateTime.Date coercion method | |||
r30403 | * Remove DateTime.today, since date-only calculations are meant be done by the | |||
Trashlord | what's up? | ||
pugssvn | r30403 | Date class | ||
r30403 | * Date.new() constructor taking a DateTime object | |||
moritz_ | the sun is up | ||
masak | Trashlord: GGE is back up. | ||
(but still fails tests) | |||
Trashlord | I like the sun | ||
masak | I hear the sun is coming back to this hemisphere this summer. | 11:19 | |
heh, github.com/masak/gge/commits/ng-compat | 11:21 | ||
(you can see where my focus has been this month) | 11:22 | ||
pugssvn | r30404 | moritz++ | [t/spec] initial tests for Date, taken from my Date module | ||
11:26
fridim left,
baisong joined
|
|||
Trashlord | hey, is there a significant difference between rakudo and pugs? | 11:27 | |
sorear | yes | 11:28 | |
masak | both are Perl 6 implementations. | ||
one stopped being in active development three years ago. | |||
sorear | pugs has been undeveloped for several years | ||
masak | even at that point, it was due for a major refactor. | 11:29 | |
I don't think it ever landed :/ | |||
Trashlord | oh | ||
sorear | that's the most common time for software to die | ||
right when an overhaul is needed | |||
masak | Pugs had a bus number of 1, and though the main dev wasn't hit by a bus, the effect was pretty much that :/ | 11:30 | |
Trashlord | haha | 11:31 | |
sorear | as compared with Parrot, which has a bus number of 0 | 11:32 | |
masak | Trashlord: no, not much haha at all :/ | ||
sorear | the developers are all still here but we don't have a clue what we're working on | ||
replacing the entire Parrot development team today would have no significant effect | 11:33 | ||
Trashlord | heh | 11:39 | |
dalek | kudo: 83650e0 | moritz++ | (2 files): first shot at Date |
11:48 | |
masak | I just had an idea, tried to implement it in Rakudo master, and it worked! \o/ | 11:54 | |
1. implement a custom data structure, e.g. Tree | |||
2. implement &map on that data structure | |||
3. ??? | |||
4. profit! | |||
gist.github.com/370183 | |||
11:54
wknight8111 joined
|
|||
moritz_ | you know that ??? fail()s? :-) | 11:55 | |
masak | it didn't in this case :) | ||
I'm thinking whether an example such as this belongs in the book. | |||
it's very self-contained, and it shows something which you can definitely not do easily in Perl 5. | |||
colomon | I think the spec expects you to implement an iterator for the tree, BTW. :) | 11:56 | |
masak | colomon: could you produce code that shows how to do that? | ||
I'd be much obliged. | |||
11:57
clintongormley joined
|
|||
colomon | masak: I don't think I have time at the moment, but if no one has by afternoon I'll give it a try. | 11:57 | |
masak | nodnod, no rush. | ||
moritz_ | rakudo: say 0 cmp 1 | ||
jnthn | o/ | ||
p6eval | rakudo 78faa0: OUTPUT«-1» | ||
masak | anytime before 2038 would be good :) | ||
jnthn | masak: Yes, regexes are has scoped | ||
colomon | though in that case, at least with current code, you wouldn't get a tree back. | ||
masak | jnthn: \o | 11:58 | |
jnthn | masak: The reason <foo> doesn't work yet is that it always goes looking for a method, rather than checking out the lexical scopes first. | ||
colomon | masak++ for picking a good simple project to be exploring at this time. | ||
moritz_ | jnthn: so NYI, right? | ||
jnthn | Well, the compiler can go look I guess... | ||
moritz_: Correct. | |||
masak | colomon: but wouldn't the resulting &map give you back a Tree? | ||
jnthn | moritz_: I did the first half of the work (making our and my work on regexes). | 11:59 | |
colomon | masak: no, if it takes a normal iterator, it will give you back a MapIterator, not a Tree. | ||
jnthn | moritz_: Still need to do the next bit. | ||
masak | colomon: I have simple ideas all the time. it's just that some of them turn out to be very difficult in practice :P | ||
colomon | automatically getting back a Tree is something we discussed WRT the hypers, but none of that is implemented yet afaik. | ||
11:59
Trashlord left
|
|||
masak | colomon: I confess I don't grok MapIterators. do they have to do with laziness? | 12:00 | |
colomon | yes. | ||
gotta run now. more later | |||
masak | anyway, my point was that with a few lines of code I can do map over a Tree, and that's pretty useful. | 12:02 | |
jnthn | heh, once for === map, that means you'd be able to do a for loop over the tree too. ;-) | 12:03 | |
masak | o.O | ||
jnthn | Maybe. | ||
:-) | |||
masak didn't even think of that | 12:04 | ||
moritz_ | ohh | 12:05 | |
I forgot to actually add Date.pm to the repo | |||
bad moritz_--, no cookie | |||
done that now | 12:06 | ||
dalek | kudo: 5ab1c03 | moritz++ | src/core/Date.pm: actually add Date.pm, moritz-- |
12:11 | |
moritz_ | 82 new tests due to Date.pm | 12:12 | |
12:15
rv2733 joined
|
|||
masak uses the slowness of Rakudo to his advantage by starting a script, modifying it, and starting a second, modified version of it | 12:15 | ||
12:15
Trashlord joined
12:16
Trashlord is now known as Guest61693
|
|||
arnsholt | masak: I'm not entirely sure that counts as an advantage =p | 12:17 | |
masak | it's one of those conditional advantages, you know :P | 12:18 | |
at the very least, it helps me find bugs faster than if I weren't doing it. | |||
arnsholt | Heh | ||
masak | hm. it seems I've finally arrived at a test failure which requires me to think about the semantics of the program, as opposed to consmetics-level stuff. | 12:20 | |
jnthn | oh noes! ;-) | 12:24 | |
masak | for some reason, the *: quantifier is backtracking. bad, bad quantifier. | 12:25 | |
moritz_ | in GGE, or in nqp? | 12:27 | |
masak | in GGE. | ||
wknight8111 | How do I run the test t/spec/S06-signature/introspection.t? | 12:37 | |
masak | perl6 t/spec/S06-signature/introspection.t | ||
moritz_ | make t/spec/S06-signature/introspection. | ||
masak | but that's a weird use of make | 12:38 | |
moritz_ | masak: not at all | ||
masak: it runs fudge if necessary | |||
masak | make specifies the target, not they source. | ||
s/they/the/ | |||
moritz_ | well, the target is to run that test file | 12:39 | |
s/target/goal/ perhaps | |||
masak | yes, that's the weird bit. | ||
make makes things. | |||
and side effects don't count, usually :) | |||
moritz_ | it's only an implementation detail that sometimes there's a .rakudo file involved | ||
wknight8111 | build...takes....too.....long..... | ||
moritz_ | wknight8111: then speed up parrot :-) | ||
12:42
jaldhar_ joined
|
|||
wknight8111 | Speedups to Parrot aren't going to cut down this build time by too much | 12:43 | |
12:43
_jaldhar left
|
|||
jnthn | Why not? The compilers are Parrot programs. | 12:43 | |
That's like saying speedups to Parrot aren't going to cut down any times by too much. | 12:44 | ||
Which may be true...but... :-/ | |||
wknight8111 | how do I jnthn: Speeding up parrot by 50% will speed up the build by at most 50% | 12:45 | |
to really cut time in that build process, we need to reduce the algorithmic complexity of it | |||
moritz_ | well | ||
one step is to split the compilation of these .pm files | |||
which is non-trivial | |||
jnthn | wknight8111: I think we'd all very happily take a 50% speedup in the build! | 12:46 | |
masak | moritz_: 'split' in what sense? | ||
moritz_ | masak: compile each of them separately | ||
masak | ah, ok. | ||
moritz_ | I don't know if it's really going to be faster in sum, but it's much easier to parallelize | ||
12:46
finanalyst left
|
|||
masak | moritz_: I was thinking along those lines the other day. | 12:47 | |
12:47
finanalyst joined
|
|||
masak | moritz_: one things that one could already parallelize quite easily would be compilation of 'leaves', or more exactly, clades in the tree which don't depend on other things. | 12:47 | |
moritz_ | masak: well, they would be all independent, more or less | 12:48 | |
jnthn | wknight8111: We can surely get the parse time's complexity down, but the grammar action methods I'd be less sure on. I mean, most of them just build ASTs. Stages after that walk said AST to make POST, which is walked to make PIR. Beyond that it's IMCC, which I guess could be sped up some by algorithmic improvements. | ||
moritz_ | one thing we could improve is memory footprint by not keeping those $/ around for every node of the parse tree | 12:49 | |
I mean it's enough to store the position inside the string, and the string once | |||
jnthn | Yes, that is certainly true. | ||
(I guess you mean "every node of the PAST tree") | 12:51 | ||
moritz_ | yes | 12:54 | |
otoh the parse tree still keeps references to those same Match objects | |||
so not much gain at all | |||
unless we implement parse tree pruning... do we? :-) | 12:55 | ||
jnthn | The trouble is knowing when could you prune. | ||
I mean, what if an action method wants to dig a few levels down, etc. | 12:56 | ||
moritz_ kinda hoped that EXPR would be such a boundary | |||
jnthn | That could be a good one. | 12:57 | |
jnthn afk for a bit | 12:58 | ||
12:58
meppl left
12:59
ReiniUrban joined
|
|||
masak | sushi & | 13:00 | |
13:01
rurban left,
ReiniUrban is now known as rurban
|
|||
wknight8111 | mmmm...sushi | 13:02 | |
13:03
wknight8111 left,
fridim joined
13:04
M_o_C left
13:06
xinming_ joined
13:08
fridim left
13:19
dual left
13:24
iblechbot joined
|
|||
masak relishes the sushi | 13:29 | ||
moritz_++ # trac.parrot.org/parrot/ticket/1560 | 13:33 | ||
that's why you were talking about t/spec/S06-signature/introspection.t | |||
13:38
M_o_C joined,
M_o_C left,
M_o_C joined
13:40
M_o_C left
13:52
xinming_ left
13:54
xinming joined
14:04
kfo_ joined
14:06
xinming left
14:07
kfo_ is now known as kfo
14:12
xinming joined
14:27
pmurias joined
|
|||
pmurias | diakopte1: hi | 14:27 | |
14:27
dual joined
14:37
snarkyboojum left
14:59
mikehh left
15:01
pmurias left
15:04
iblechbot left
|
|||
colomon seems to have found the setting on mandelbrot-color.pl that makes it swap even on his big 64-bit Linux box... | 15:11 | ||
15:12
finanalyst left,
finanalyst joined
|
|||
colomon | It's using up 5.7 GB at the moment. | 15:15 | |
15:15
justatheory joined
|
|||
colomon | masak: ping? | 15:30 | |
15:30
mberends joined
|
|||
colomon | mberends++ # I think we learned a good bit using your script last night. | 15:31 | |
mberends | :) current trying to port it to Windows | ||
masak | colomon: pong | ||
colomon | masak: trying to take a quick look at Tree before lunch (while watching the boy). | 15:32 | |
masak | awesome. | ||
colomon | weirdly, adding does Iterable to Tree breaks everything. | ||
15:32
mikehh joined
|
|||
masak is in the middle of hunting down a very elusive but possibly disastrous rakudobug | 15:32 | ||
colomon | masak++ | 15:33 | |
masak | the kind I didn't think we had anymore. | ||
colomon | rakudo-- | ||
masak | of course, at this stage it might just be masak who deserves that -- | ||
we'll see :) | |||
colomon | rakudo++ # iterator works! | 15:35 | |
gist.github.com/370287 | 15:36 | ||
first time I've ever used a local sub in Perl 6, worked like a charm on the first try. | |||
:D | |||
of course, the does Iterable crash seems worrisome. | 15:39 | ||
masak | colomon++ # nice local sub :) | ||
colomon | attempting to get grep to work, but having difficulties. time for lunch, alas. | 15:40 | |
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^3 { @x[$_] .= new(:a($_*2), :b($_+3))}; for @x {.perl.say | 15:43 | |
p6eval | rakudo 5ab1c0: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 11current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)» | ||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^3 { @x[$_] .= new(:a($_ * 2), :b($_ + 3))}; for @x {.perl.say} | 15:44 | |
p6eval | rakudo 5ab1c0: OUTPUT«get_pmc_keyed() not implemented in class ''current instr.: 'perl6;Positional[::T];postcircumfix:<[ ]>' pc 10553 (src/metamodel/GrammarHOW.pir:44)» | ||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^3 { @x[$_] .= new(:a($_ * 2), :b($_ + 3))}; for @x {.perl.say} | ||
p6eval | rakudo 5ab1c0: OUTPUT«get_pmc_keyed() not implemented in class ''current instr.: 'perl6;Positional[::T];postcircumfix:<[ ]>' pc 10553 (src/metamodel/GrammarHOW.pir:44)» | ||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^3 { @x[$_] .= new(:a($_ * 2), :b($_ + 3))}; for @x {$_.b.say} | 15:47 | |
p6eval | rakudo 5ab1c0: OUTPUT«get_pmc_keyed() not implemented in class ''current instr.: 'perl6;Positional[::T];postcircumfix:<[ ]>' pc 10553 (src/metamodel/GrammarHOW.pir:44)» | ||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x; for ^3 { @x[$_] .= A.new(:a($_ * 2), :b($_ + 3))}; for @x {$_.b.say} | ||
p6eval | rakudo 5ab1c0: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 11current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)» | 15:48 | |
15:48
_jaldhar_ joined,
jaldhar_ left
|
|||
finanalyst | role A {has $.a; has $.b}; my @x; for ^3 { @x.push: A.new(:a($_ * 2), :b($_ + 3)) }; for @x {$_.b.say} | 15:49 | |
rakudo: role A {has $.a; has $.b}; my @x; for ^3 { @x.push: A.new(:a($_ * 2), :b($_ + 3)) }; for @x {$_.b.say} | 15:50 | ||
p6eval | rakudo 5ab1c0: OUTPUT«345» | ||
15:50
justatheory left
|
|||
finanalyst | Hi anyone. Is there a neater way to instantiate an array of objects other than pushing? | 15:52 | |
masak | rakudo: my @x = 1, 2, 3; say @x.perl | 15:53 | |
p6eval | rakudo 5ab1c0: OUTPUT«[1, 2, 3]» | ||
15:53
diakopte1 is now known as diakopter
|
|||
slavik | rakudo: my @arr = "blah" ** 5; say @arr.perl | 15:54 | |
15:54
baisong left
|
|||
masak | rakudo: class A {}; my @x = A.new, A.new, A.new; say @x.perl | 15:54 | |
p6eval | rakudo 5ab1c0: OUTPUT«[0]» | ||
rakudo 5ab1c0: OUTPUT«[A.new(), A.new(), A.new()]» | |||
slavik | rakudo: my @arr = "blah" x 5; say @arr.perl | ||
p6eval | rakudo 5ab1c0: OUTPUT«["blahblahblahblahblah"]» | ||
slavik | that way | ||
finanalyst | slavik: see my previous code. Suppose the objects have typed structure | 15:55 | |
15:55
sorear left
15:57
Kyril joined
|
|||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^4 { @x[$_] .= new(:a($_ *3), :b($_ + 2)}; say @x.perl | 15:57 | |
p6eval | rakudo 5ab1c0: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 11current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)» | ||
finanalyst | rakudo: role A {has $.a; has $.b}; my @x of A; for ^4 { @x[$_] .= new(:a($_ *3), :b($_ + 2))}; say @x.perl | ||
p6eval | rakudo 5ab1c0: OUTPUT«get_pmc_keyed() not implemented in class ''current instr.: 'perl6;Positional[::T];postcircumfix:<[ ]>' pc 10553 (src/metamodel/GrammarHOW.pir:44)» | ||
diakopter | g'morn #perl6 | 15:58 | |
15:58
eternaleye left
|
|||
masak | diakopter: \i | 16:00 | |
diakopter | p/ | ||
masak | :-w | ||
*shudder* -- I think I just got a glimpse into what combination of circumstances cause this bug to happen. | 16:01 | ||
diakopter | do tell | ||
masak | and why no-one has discovered it until now. :( | ||
diakopter | your theory | ||
masak | my current theory involves references to lexical subs, anonymous subs, reentrancy, and deep nesting. | ||
16:01
sorear joined
|
|||
masak | I'm minimizing very carefully, but the thing I started from is GGE, so it will probably take all evening or more. | 16:02 | |
diakopter | ah | ||
diakopter dealt a lot with those things last night perlesque | |||
in perlesque | |||
masak | yeah, I saw. | ||
heady stuff :) | |||
diakopter | is it reproducible | 16:05 | |
with a particular pattern in your gge | |||
masak | it is. | ||
want me to push the debug branch? | |||
diakopter | what's the pattern that manifests it | 16:07 | |
or is it every pattern | |||
masak | a+ ** b | ||
diakopter | remind me what ** means plz | ||
masak | in this case, it repeats 'a+' with 'b' as a separator. | 16:08 | |
but that doesn't matter; the error occurs in the parsing of the regex. | |||
to parse 'b', the regex parser has to call itself. | |||
that seems to be essential to the bug. | |||
diakopter | how does it call itself | 16:10 | |
dalek | kudo: 842d2b0 | pmichaud++ | docs/spectest-progress.csv: spectest-progress.csv update: 391 files, 30643 (79.4% of 38606) pass, 2 fail S06-multi/syntax.rakudo 21 - use multi method to override builtin lives S06-multi/syntax.rakudo 22 - use multi method to override builtin |
||
masak | ok, so the optable parser works through callbacks, right? | ||
diakopter misses phenny b/c I want to msg pmurias | |||
masak | for example, a sub parse_quantifier that can parse '**' and such. | ||
now, parse_quantifier needs to know where 'b' ends, because it might be a parenthesized expression or something. | 16:11 | ||
so it simply calls the whole regex expression parser with a caveat to stop parsing at the term: level. | 16:12 | ||
diakopter | oh | ||
masak | so, when we're parsing 'b', we're in the p6regex parser calling the optable parser calling parse_quantifier calling the p6regex parser calling the optable parser calling parse_term. | ||
masak exhales | |||
s/ex/in/ | 16:13 | ||
and somewhere there, an array that should have contained one element turns out to be empty. | |||
diakopter | any chance it's a parrotbug? | 16:14 | |
masak | and this under mysterious circumstances, such as it containing the element before a call, and being empty right after the call. | ||
diakopter: dunno, might be. | |||
16:14
takadonet joined
|
|||
takadonet | morning all | 16:15 | |
masak | hm, explaining this might actually help me write a minimal example from scratch :) | ||
takadonet: \o | |||
takadonet | I see commit are happening! | ||
takadonet does a git pull | |||
masak: what editor do you use for creating Perl6 code? | 16:19 | ||
16:19
rv2733 left
|
|||
masak | takadonet: vim 7.2 | 16:19 | |
16:19
IllvilJa joined
|
|||
masak | and I write most prose in Emacs. :) | 16:19 | |
takadonet | <--- emacser here | 16:20 | |
diakopter | <--- Notepad++ | ||
takadonet | I been installing Padre so at least I will have syntax highlighting | 16:21 | |
masak | well, I have it too; it's just that it breaks sometimes. | 16:22 | |
diakopter | referring to www.cs.chalmers.se/~boquist/phd/ does anyone know what he means by "forcing of closures"? | 16:28 | |
masak | something that causes the call target to be unknown at compile time? :) | 16:30 | |
wouldn't that be more or less all of OO method calls out there? | |||
all polymorphic dispatch, at least. | 16:31 | ||
16:36
masak left
16:37
justatheory joined
|
|||
diakopter | jql: howdy | 16:38 | |
16:49
lichtkind joined
|
|||
lichtkind | cheers | 16:51 | |
diakopter | hi | 16:52 | |
16:52
Guest61693 is now known as Trashlord,
Trashlord left,
Trashlord joined
16:55
levengli joined
|
|||
levengli | is there a library of pm for perl6 in the dist/ | 17:01 | |
17:05
envi^home left,
levengli left
|
|||
diakopter | I admit: I don't know what dist/ levengli was asking about | 17:09 | |
17:18
hercynium joined
17:21
wknight8111 joined
17:23
Chillance joined
|
|||
jnthn looks over the NPW email and is highly amused by the restaurant description "Prikið (burgery-fusion, greasygood, hangover killer meal incl. painkillers)" | 17:30 | ||
Including painkillers?! | |||
:-) | |||
colomon | jnthn: why does class Tree is Iterable blow up my code? :) | 17:32 | |
(or rather, masak++'s code that I have copied) | 17:33 | ||
jnthn | 'cus Iterable in Rakudo is a class last I checked. | ||
17:34
lichtkind_ joined
|
|||
colomon | errr... is "is Iterable" not the proper syntax for class derivation? | 17:34 | |
17:34
lichtkind left,
lichtkind_ is now known as lichtkind
|
|||
colomon | www.harmonyware.com/pictures/big.png | 17:37 | |
1001 x 1001 completed while we were at lunch. | 17:38 | ||
took 6.4 GB of memory to compute. | 17:39 | ||
17:39
rv2733 joined
|
|||
wknight8111 | I've learned a lesson today: If I have only 10 minutes to hack, I can't even run a failing Rakudo test case | 17:57 | |
much less figure out why it fails | |||
18:06
Alias left,
Alias joined
|
|||
jnthn | colomon: Well, it's certainly pretty. :-) | 18:06 | |
colomon | FK | 18:08 | |
afk | |||
back. | 18:14 | ||
I'm quite pleased by the picture, actually. :) | 18:15 | ||
with Tree $t: ($t.iterator Z~ 'a'...*).eager.perl.say; | 18:21 | ||
("H2Oa", "Hb", "Oc", "Od") | |||
:) | |||
If I could just make Tree Iterable, that would be cleaner... ;) | 18:22 | ||
18:23
meppl joined
18:28
iblechbot joined
18:30
hercynium left
18:34
_jaldhar_ left
18:35
_jaldhar_ joined
18:42
_jaldhar_ left
18:43
_jaldhar_ joined
18:46
Kyril left
|
|||
slavik | colomon: mandebrot ... perl6? | 18:49 | |
finanalyst | alpha: my @a = 1,2,3,4; for @a[ 1 .. *-1 ] { .say } | 18:50 | |
p6eval | alpha 30e0ed: OUTPUT«234» | ||
finanalyst | rakudo: my @a = 1,2,3,4; for @a[ 1 .. *-1 ] { .say } | 18:51 | |
p6eval | rakudo 842d2b: ( no output ) | ||
finanalyst | jnthn: is it known that rakudo has stopped liking * in arrays? | 18:52 | |
arnsholt | Regression from alpha, IIRC | 18:54 | |
19:00
[synth] joined
19:02
synth left
|
|||
colomon | slavik: mandelbrot, in perl 6: github.com/colomon/mandelbrot | 19:03 | |
It is slower than a very slow thing, but it works and is stable. | 19:04 | ||
slavik | colomon: nice :) | ||
colomon | (errr, the color version works, the b&w version probably still needs a tiny bit of work to be ported to the current Rakudo.) | ||
slavik | err | ||
it's like 20 lines of code ... | 19:05 | ||
.map is paralell? | |||
colomon | slavik: no. | ||
slavik | :( | ||
colomon | perl6advent.wordpress.com/2009/12/1...g-snowmen/ | ||
slavik | colomon: use opengl to draw it? | 19:06 | |
colomon | that post describes the code, and also the changes needed to make it parallel when Rakudo supports that. | ||
nope, it just dumps a PPM file to standard output. | |||
slavik | aww | ||
colomon | Hmmm, actually >>☃ might work now. I probably need to revisit the code more carefully at some point. But for this weekend, it's been a great timing / stability / memory usage test. | 19:08 | |
slavik | colomon: cool stuff :) | 19:09 | |
colomon | :) | 19:10 | |
19:22
[synth] is now known as synth
19:32
finanalyst left
19:37
ejs joined
|
|||
sorear | colomon: 6 GB? Why? Memory leak? | 19:46 | |
colomon | sorear: either that or Parrot / Rakudo is immensely piggy. | 19:47 | |
That was actually what I predicted it would take after my tests yesterday, the script seems to need 4MB additional memory every time you increase the edge length of the fractal by 1. | 19:48 | ||
sorear | last time I studied the mandelbrot set, it could be computed in constant space | ||
my favorite definition of a memory leak is "any bug which increases asymptotic space complexity" | 19:49 | ||
(never-freed memory was nice until they invented GC) | |||
19:50
nihiliad joined
19:53
molaf left
19:57
pmurias joined
|
|||
pmurias | diakopter: ping | 19:57 | |
diakopter: how do i submit failing test cases for perlesque? can i get a commit bit? ;) | 19:58 | ||
20:16
eternaleye joined
|
|||
colomon | sorear: yes, constant space is right. for this algorithm, each pixel is buffered until a line is done, and then the entire thing is dumped. its memory usage should be minimal. definitely should not take 6GB. | 20:29 | |
20:32
justatheory left
20:49
_buno_ joined
20:54
_buno_ left
20:55
_buno_ joined
20:56
_buno_ left
|
|||
lichtkind | mberends: hai | 20:56 | |
mberends | hai lichtkind | 20:57 | |
lichtkind | mberends: howsetging meen | ||
mberends | lichtkind: it's going on Windows today, spelunking the mysterious corridors of the Win32::PerfLib class | 20:59 | |
21:00
ReiniUrban joined
|
|||
lichtkind | hm, my new system runs well, im sort of back trying go over 500 today | 21:00 | |
21:00
wknight8111 left
21:01
rurban left,
ReiniUrban is now known as rurban
21:04
rv2733 left
|
|||
lichtkind | whats the differens between the bit and bool type? | 21:06 | |
21:11
buno_ joined
|
|||
mberends | probably bit is 1 or 0, bool is true or false (this is splitting hairs). numeric versus logical. | 21:12 | |
lichtkind | i suppose your right | 21:13 | |
and that some conversion might also be easy | |||
Juerd | Which right? :) | ||
lichtkind: s/your/you're/ | |||
lichtkind | Juerd: right as in Bool::True | ||
mberends | Juerd: my right ;) | 21:14 | |
Juerd | I hope you have multiple. :) | 21:16 | |
21:16
buno_ left
21:17
_buno_ joined
|
|||
lichtkind | Juerd: i know it you're im just lazy now | 21:17 | |
mberends | lichtkind: s/it/it's/ s/im/I'm/ ;) | 21:18 | |
Juerd | s/<after you're>/;/ | ||
s/$/./ # nit | |||
colomon | I believe Bool is numerical in theory. | ||
say True | 21:19 | ||
rakudo: say True # works better with rakudo: | |||
p6eval | rakudo 842d2b: OUTPUT«1» | ||
colomon | "numerical", ugh, should be "numeric". | ||
21:25
_buno_ left
21:26
_buno_ joined,
_buno_ left
|
|||
IllvilJa | Is 'gitpan' the future CPAN? | 21:29 | |
mberends | no, CPAN will continue in the future, with additions for Perl 6 | 21:30 | |
IllvilJa | ok, so CPAN for released packages and gitpan for development snapshots of them? | 21:31 | |
21:31
_buno_ joined
|
|||
mberends | yes. predictions are hard though, particularly those about the future ;) | 21:32 | |
21:32
_buno_ left
|
|||
IllvilJa | Yes. Predictions are overrated, wild speculations will do fine :-D. | 21:33 | |
21:37
PacoLinux left,
_buno_ joined
21:38
iblechbot left,
_buno_ left
21:39
_buno_ joined
21:50
hercynium joined
21:54
_buno_ left,
_buno_ joined
|
|||
diakopter | pmurias: hi :) | 21:54 | |
pmurias: yeah; what's your google id | |||
21:56
_buno_ left,
_buno_ joined
|
|||
sorear | mberends: you beleive in CPAN6? | 21:57 | |
mberends | sorear: I'll believe it when I see it. | ||
diakopter finally today finished the SF heptary Saga of Seven Suns | |||
21:58
justatheory joined
|
|||
sorear | ok, we're in agreement there. | 21:58 | |
diakopter | CPAN is plenty fine good | 21:59 | |
sorear | IllvilJa: if you ask me, the future lies with metadata-only systems like proto and plumage | 22:01 | |
diakopter | sorear: I'm staring blankly at the disassembly of ActiveState's perl-clr bridge. | 22:02 | |
sorear | ooooh | 22:04 | |
someone has a reverse engineering project for me? | |||
22:09
cosimo left
22:12
_buno_ left
22:13
_buno_ joined
|
|||
lue | why hello there | 22:15 | |
mberends | welcome to our century | 22:16 | |
diakopter | it's a dark one. | ||
lue | 21st, right? | ||
the DW premiere was awesome. Epic title sequence, epic remodel, and awesome h2g2 reference :) | 22:19 | ||
diakopter | pmurias: you around? | 22:20 | |
pmurias | diakopter: yes | 22:21 | |
diakopter | pmurias: should I add your google email address? | 22:23 | |
mberends discovers he has been asleep for a few minutes. Goodnight o/ | 22:24 | ||
pmurias | [email@hidden.address] | ||
that's my google id right? | |||
diakopter | I guess :) | 22:25 | |
mberends: :) | |||
pmurias | diakopter: does perlesque have a test suit? | ||
diakopter | no | ||
it's only recently attained verifiable input/output status | 22:26 | ||
external interaction, I mean | |||
as opposed to hosting the tests itself | |||
which I hate | |||
pmurias | hosting the tests itself? | ||
that means hardcoding ok(...)? | 22:27 | ||
diakopter | I mean, internal tests | ||
I think all the tests should be "black box" | 22:28 | ||
to spec | |||
what's your failing test | 22:29 | ||
it's probably just NYI | |||
pmurias | reproducing... | ||
sub int foo(int $arg0) {return 4;} fails to parse with a bizare error message | 22:30 | ||
diakopter: the parser is hand coded recursive descent? | 22:31 | ||
diakopter | no | ||
heh | |||
LOL, in fact. | |||
you obviously haven't looked at the code :P | |||
it's got its own parser generator (which does generate a recursive descent parser, yes) | 22:32 | ||
std: sub int foo(int $arg0) {return 4;} | 22:33 | ||
p6eval | std 30404: OUTPUT«===SORRY!===Malformed block at /tmp/dN6EcgZRmy line 1:------> sub int ⏏foo(int $arg0) {return 4;} expecting any of: block routine_def traitParse failedFAILED 00:01 107m» | ||
pmurias | diakopter: the problem is with the lack of the whitespace after foo | ||
diakopter | I know, but I'm curious why std doesn't like it either | ||
std: my $a = sub Int foo (int $arg0) {return 4;} | 22:34 | ||
p6eval | std 30404: OUTPUT«===SORRY!===Malformed block at /tmp/srPya0uZAn line 1:------> my $a = sub Int ⏏foo (int $arg0) {return 4;} expecting any of: block routine_def traitParse failedFAILED 00:01 108m» | ||
pmurias | std: sub foo(int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«ok 00:01 109m» | ||
pmurias | std: int sub foo(int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«===SORRY!===Two terms in a row at /tmp/w6p6WacmR2 line 1:------> int ⏏sub foo(int $arg0) {return 4;} expecting any of: bracketed infix infix or meta-infix statement modifier loopParse failedFAILED 00:01 110m» | ||
pmurias | std: sub int foo(int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«===SORRY!===Malformed block at /tmp/1T5ySTq2vW line 1:------> sub int ⏏foo(int $arg0) {return 4;} expecting any of: block routine_def traitParse failedFAILED 00:01 107m» | ||
diakopter | TimToady: consider yourself summoned | ||
ok; it's a bug in the grammar, yeah | 22:35 | ||
I thought return type went between 'sub' and subname | |||
diakopter goes to look at the Synopsis again | 22:36 | ||
22:36
clintongormley left
|
|||
pmurias | diakopter: why is a sub name require in a sub declaration? | 22:37 | |
s/declaration/literal/ | |||
diakopter | b/c anonymous ones are still NYI | ||
:P | |||
22:37
_buno_ left
|
|||
pmurias | named ones seem a bit unnessesary | 22:39 | |
good night | 22:42 | ||
lue | gnight o/ | ||
diakopter | o / | ||
22:42
pmurias left
|
|||
lue | afk | 22:46 | |
22:48
cosimo joined
22:53
mberends_ joined,
mberends left
23:00
Kyril joined
23:09
orafu left,
orafu joined
23:21
astrojp joined
|
|||
diakopter | got anonymous subs working. | 23:21 | |
heh | |||
colomon | std: my int sub foo(int $arg0) {return 4;} | 23:22 | |
p6eval | std 30404: OUTPUT«ok 00:01 111m» | ||
diakopter | ahhh.... | ||
23:22
wknight8111 joined
|
|||
colomon | std: our int sub foo(int $arg0) {return 4;} | 23:23 | |
diakopter | std: my $a = my int sub foo(int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«ok 00:01 109m» | ||
std 30404: OUTPUT«ok 00:01 110m» | |||
diakopter | std: my $a = my int sub (int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«ok 00:01 110m» | ||
diakopter | std: my $a = my int sub(int $arg0) {return 4;} | ||
p6eval | std 30404: OUTPUT«===SORRY!===Malformed my at /tmp/B6ZEE25DRq line 1:------> my $a = my int ⏏sub(int $arg0) {return 4;} expecting any of: declarator multi_declarator routine_declarator typenameParse failedFAILED 00:01 108m» | ||
diakopter | whew | ||
perlesque: my $a = sub (int $b) { say($b); say($b); return 1; }; $a(9); say(10); | 23:24 | ||
p6eval | perlesque: OUTPUT«9910» | ||
diakopter | o_O | ||
I, um, um, | 23:25 | ||
it's supposed to require the sub return type | |||
wait | |||
23:25
Grrrr joined
|
|||
diakopter | perlesque: my $a = sub (int $b) { say($b); say($b); }; $a(9); say(10); | 23:25 | |
p6eval | perlesque: OUTPUT«99» | ||
diakopter | O_O | ||
weird. | |||
perlesque: my $a = sub (int $b) { say($b); say($b); }; $a(9); say(10); | 23:26 | ||
p6eval | perlesque: OUTPUT«99» | ||
diakopter | strange. | ||
ooooooo I have an idea | |||
oh, interesting; it was infinitely looping b/c it never returned. | 23:29 | ||
will fi l8r | |||
fix l8r | |||
23:30
p6eval left,
p6eval joined
|
|||
diakopter | perlesque: my $last = 4; my $sub_a = sub int foo (int $arg0) { say(my $b = $arg0 + 5); $last = $b; return $b; }; my $sub_b = $sub_a; $sub_b(4); $sub_b = sub int bar (int $arg0) { say(my $b = $arg0 + 4); if ($b>19) { $sub_b = $sub_a; }; $last = $b; return $b; }; while ($last < 100) { $sub_b($last); }; | 23:30 | |
p6eval | perlesque: OUTPUT«9131721263136414651566166717681869196101» | ||
diakopter | perlesquel: runlast | ||
p6eval | perlesquel: OUTPUT«9131721263136414651566166717681869196101» | ||
diakopter | hee | ||
perlesquel: runlast | 23:31 | ||
p6eval | perlesquel: OUTPUT«9131721263136414651566166717681869196101» | ||
diakopter | there you see the difference two compilation stages makes. | ||
lichtkind | good night your brave ones | ||
23:33
lichtkind left
|
|||
sorear | what's perlesquel? | 23:33 | |
diakopter | :D it just runs the last image perlesque compiled from p6eval input | ||
perlesque: loop (my $x=0;$x<100000000;$x+=1) { }; say(939391); | 23:35 | ||
p6eval | perlesque: OUTPUT«939391» | ||
diakopter | perlesquel: runlast | ||
p6eval | perlesquel: OUTPUT«939391» | ||
diakopter | mmmmm raw speed | ||
23:46
p6eval left,
p6eval joined
|
|||
diakopter | perlesque: loop (my $x=0;$x<100000000;$x+=1) { }; say(939391); | 23:47 | |
p6eval | perlesque: OUTPUT«939391» | ||
diakopter | perlesquel: runlast | ||
p6eval | perlesquel: OUTPUT«939391» | ||
diakopter | hm | ||
23:54
p6eval left,
p6eval joined
|
|||
diakopter | perlesquel: runlast | 23:55 | |
:/ | |||
p6eval | perlesquel: OUTPUT«939391real 0.39user 0.39sys 0.00» | ||
diakopter | perlesquel: runlast | ||
p6eval | perlesquel: OUTPUT«939391real 0.40user 0.37sys 0.02» | ||
diakopter | oh ok | ||
pugssvn | r30405 | diakopter++ | [evalbot] add perlesquel pseudo-backend (it times the execution and displays the output of the last perlesque p6eval input | 23:58 | |
diakopter | ) | ||
perlesquel: runlast | 23:59 | ||
p6eval | perlesquel: OUTPUT«4real 0.05user 0.04sys 0.00» |