Perl6 Macros

2002-03-26 Thread Michel J Lambert
I searched the archives with Google (what, no internal search engine??), and found the thread on perl6 macros, which I did read. From what I saw, it mostly concentrated on using macros for speed. That should be a minor argument, especially considering this is perl. :) Common Lisp macros are

Potential Memory Leaks

2002-03-26 Thread Michel J Lambert
Hey, After going through and hopefully learning the GC system yesterday, today I went through looking for problems in the code that uses it (or doesn't use it, as the case may be). Below are what I believe to be potential problems in Parrot's memory use. I may very well be mistaken on many of

Re: Minor GC Patch, and Some Questions

2002-03-26 Thread Dan Sugalski
At 3:21 AM -0500 3/25/02, Michel J Lambert wrote: Below is a cleanup patch for a comment or two, some flags missing, that I did while reading through it all in an attempt to figure it all out. Thanks for the code review--you've found a number of bugs and missing bits. We ought to see about

Stack sorting

2002-03-26 Thread Clinton A. Pierce
I took one of the smaller problems from the BASIC interpreter, sorting the stack, and posed it as a question on PerlMonks to see how a Mongolian Horde would handle the problem. The results are at: http://www.perlmonks.org/index.pl?node_id=153974 Summary: the only apparent way to do

Re: Topicalizers: Why does when's EXPR pay attention to topicalizer r egardless of associated variable?

2002-03-26 Thread Aaron Sherman
On Thu, 2002-03-21 at 12:52, Allison Randal wrote: On Wed, Mar 20, 2002 at 09:59:35AM -0800, Larry Wall wrote: I should update y'all to my current thinking, which is that $_ is always identical to the current topic, even if the topic is aliased to some other variable. To get at an outer

[Applied] tabs-spaces fix

2002-03-26 Thread Josh Wilmes
That worked, thanks! --Josh At 3:15 on 03/26/2002 EST, Michel J Lambert [EMAIL PROTECTED] wrote: Sorry. It's easier to c+p into Pine than it is to upload+attach. I have a feeling a few other patches I've submitted might be screwed up as well. If this happens for anyone, please let me know.

Re: Topicalizers: Why does when's EXPR pay attention to topicaliz er r egardless of associated variable?

2002-03-26 Thread Larry Wall
Aaron Sherman writes: : On Thu, 2002-03-21 at 12:52, Allison Randal wrote: : On Wed, Mar 20, 2002 at 09:59:35AM -0800, Larry Wall wrote: : : I should update y'all to my current thinking, which is that $_ is : always identical to the current topic, even if the topic is aliased to : some

Re: Perl6 Macros

2002-03-26 Thread Michel J Lambert
macro foo($a,$b) { return( $c // $a+$b ); } print foo(1,2), \n; my $c=100; print foo(1,2) \n; Yeah, your example provided is correct. It's called variable capture, and there's some work required by common lisp macros to ensure that unwanted variable capture does not occur. I don't

[PATCH] Reg stacks keep allocated segments

2002-03-26 Thread Melvin Smith
Simple patch, it looks larger than it should because I renamed new_chunk to next_chunk. Rather than free the stack chunks as we pop back down the stack, just leave it at its high-water mark so we don't reallocate every time it grows. -Melvin Index: register.c

Re: [PATCH] Stack bugfix

2002-03-26 Thread Peter Gibbs
- Original Message - From: Melvin Smith [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: dan Sugalski [EMAIL PROTECTED] Sent: 26 March 2002 09:39 Subject: [PATCH] Stack bugfix Afterwards the test program ran with larger file sizes, eventually crashing again, but this time in the GC.

Computed-goto Patch

2002-03-26 Thread Michel J Lambert
Attached is a patch to implement computed-goto on gcc, taken from the original post by Daniel Grunblatt: http:[EMAIL PROTECTED]/msg06255.html Changes since his original patch: + works with the current codebase + handles all jumps properly, and passes all tests (I'm not sure, but I don't believe

[PATCH] t/pmc/.cvsignore

2002-03-26 Thread Michel J Lambert
The introduction make quicktest made this missing .cvsignore more apparent. Mike Lambert *.pasm *.pbc *.out

Re: Computed-goto Patch

2002-03-26 Thread Melvin Smith
At 02:55 AM 3/27/2002 -0500, Michel J Lambert wrote: Attached is a patch to implement computed-goto on gcc, taken from the Wow, talk about timing, I was up late working on computed goto core just now, and had hacked ops2c.pl and CGoto.pm. I had to remove prederef stuff until I could look at it.

RE: Computed-goto Patch

2002-03-26 Thread Brent Dax
Melvin Smith: # At 02:55 AM 3/27/2002 -0500, Michel J Lambert wrote: # Attached is a patch to implement computed-goto on gcc, taken from the # # Wow, talk about timing, I was up late working on computed goto core # just now, and had hacked ops2c.pl and CGoto.pm. I had to remove # prederef stuff

Re: Computed-goto Patch

2002-03-26 Thread Michel J Lambert
Doh, sorry about that. If it makes you feel any better (or worse), I was in the midst of writing up the email for fixing the pushp bug you mentioned, when up pops '[PATCH] Stack fix' in my email inbox, turning my local bug fix into a nice learning exercise. :) I think you bring up a good point

RE: Computed-goto Patch

2002-03-26 Thread Melvin Smith
At 12:16 AM 3/27/2002 -0800, Brent Dax wrote: Melvin Smith: # At 02:55 AM 3/27/2002 -0500, Michel J Lambert wrote: # Attached is a patch to implement computed-goto on gcc, taken from the # Right now most of us have no clue whos doing what anymore besides Dan # doing GC, Jeff doing unicode, Simon