Re: Cola update

2002-03-21 Thread Dan Sugalski
At 5:15 AM -0500 3/21/02, Melvin Smith wrote: >Well you can now write neato string code with Parrot with standard >array notation. I mapped it onto the substr w/replace op. > >// copy a string >int i = 0; >while(str[i] != "") >newstr[i] = str[i++]; Shares of Atari Basic... Cool. ;) --

Re: Old Warnock's Dilemma for 'make quicktest'

2002-03-21 Thread Dan Sugalski
At 10:37 PM -0500 3/20/02, Michel J Lambert wrote: >Heya, > >I submitted a bunch of patches awhile back, all of which were committed >except for one, which dealt with adding a 'make quicktest'. Information on >it can be found here: > >http:[EMAIL PROTECTED]/msg07834.html > >It did provide for a si

Old Warnock's Dilemma for 'make quicktest'

2002-03-21 Thread Michel J Lambert
Heya, I submitted a bunch of patches awhile back, all of which were committed except for one, which dealt with adding a 'make quicktest'. Information on it can be found here: http:[EMAIL PROTECTED]/msg07834.html It did provide for a significant speedup, from 170 seconds using 'make test' to 24

licensing fun

2002-03-21 Thread Josh Wilmes
Thought this was interesting reading.. this is what's going on over in mozilla-land with regard to licensing. http://www.mozilla.org/MPL/relicensing-faq.html --Josh -- Josh Wilmes ([EMAIL PROTECTED]) | http://www.hitchhiker.org

Re: licensing fun

2002-03-21 Thread Simon Cozens
Josh Wilmes: > Thought this was interesting reading.. This too: http://tmn.dyndns.org/~dcormier/tilly.html If you're contributing code, please make sure it's yours to contribute. -- I wish my keyboard had a SMITE key -- J-P Stacey

Cola update

2002-03-21 Thread Melvin Smith
Well you can now write neato string code with Parrot with standard array notation. I mapped it onto the substr w/replace op. // copy a string int i = 0; while(str[i] != "") newstr[i] = str[i++]; -Melvin

C# and Perl article on perl.com

2002-03-21 Thread Simon Cozens
In case people haven't seen it yet, my article on .NET is on www.perl.com; it covers C# and highlights some things that I think Perl 6 can learn from it. -- Dames lie about anything - just for practice. -Raymond Chandler

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

2002-03-21 Thread Allison Randal
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 topic, you'd have to use the > same mechanism we'll

Problems with strings on the stack (small, concise example)

2002-03-21 Thread Clinton A. Pierce
(p6i cc'd) Okay, I've got this down to a dozen lines. I'm using a build pulled from CVS two hours ago. In case what's going on here isn't obvious, I'm shifting the first character off of S2 and putting it on the stack until S2 is finally exhausted. It's a boiled down version of my tokenizer

Some updates

2002-03-21 Thread Dan Sugalski
Folks, I've added or enabled the following ops: clone Sx, sy savec Sx set Ix, sy set Nx, sy which clone the string in Y and put it in X, push a clone of string register X, turn the string in Y into an integer in X, and turn the string in Y into a float in X, respectively. We

MSVC Warnings

2002-03-21 Thread Michel J Lambert
We take in const params, and set them into non-const members of STRING: string.c(51) : warning C4090: '=' : different 'const' qualifiers string.c(55) : warning C4090: '=' : different 'const' qualifiers Due to MAKE_KEY in set_keyed setting keys[0] on an uninitialized pointer. But I hear this isn'

Re: MSVC Warnings

2002-03-21 Thread Simon Glover
On Thu, 21 Mar 2002, Michel J Lambert wrote: > +//KEY_PAIR src_key_p, dest_key_p; > +//KEY src_key, dest_key; [etc.] These need to be C-style comments; not every compiler will accept the C++ style ones. Simon

Re: Cola update

2002-03-21 Thread Melvin Smith
Dan Sugalski <[EMAIL PROTECTED]> To:

RE: Some updates

2002-03-21 Thread Brent Dax
Dan Sugalski: # I've added or enabled the following ops: # # clone Sx, sy # savec Sx # set Ix, sy # set Nx, sy # # which clone the string in Y and put it in X, push a clone of string # register X, turn the string in Y into an integer in X, and turn the # string in Y into a float in

Re: MSVC Warnings

2002-03-21 Thread Michel J Lambert
Ooops. I originally did the /**/, but thought that was way too easy to be C code, and so changed them to //. :) Below is a proper patch. Mike Lambert Index: core.ops === RCS file: /cvs/public/parrot/core.ops,v retrieving revision 1

Re: Old Warnock's Dilemma for 'make quicktest'

2002-03-21 Thread Michel J Lambert
Times are: make quicktest, after caching output: 23 seconds make test: 175 seconds make quicktest could screw up if: - you ctrl-c it, or make test (although I haven't had problems with that yet) during the compilation process at just the right time - you do anything to invalidate existing .pbc fi

Re: MSVC Warnings

2002-03-21 Thread Josh Wilmes
I've applied the classes/intqueue.pmc patch. The other needs adjustment. FWIW, your change doesn't cure the errors on TCC: "string.c", line 51: Error: [ISO 6.3.16.1]: Conversion casts away 'const'-ness. [ISO 6.3.16]: Can't perform this conversion by assignment. "string.c", line 55: Error

Re: Cola update

2002-03-21 Thread David M. Lloyd
On Thu, 21 Mar 2002, Melvin Smith wrote: > Ahhh, those simpler days > > Hmm you have just given me an evil idea... I must have had the same idea in the same instant. :-) - D <[EMAIL PROTECTED]>

Re: Some updates

2002-03-21 Thread Melvin Smith
At 05:13 PM 3/21/2002 -0500, Dan Sugalski wrote: >Folks, > >I've added or enabled the following ops: > >clone Sx, sy I'm not seeing the difference between clone Sx, sy and set Sx, sy When I do: set S30, "PARROT" set S31, S30 chopn S30, 2 print S30 print "\n" print S31 print "\n" end I stil

Re: Some updates

2002-03-21 Thread Dan Sugalski
On Thu, 21 Mar 2002, Melvin Smith wrote: > At 05:13 PM 3/21/2002 -0500, Dan Sugalski wrote: > >Folks, > > > >I've added or enabled the following ops: > > > >clone Sx, sy > > I'm not seeing the difference between clone Sx, sy and set Sx, sy > > When I do: > > set S30, "PARROT" > set S31, S3

Re: Problems with strings on the stack (small, concise example)

2002-03-21 Thread Dan Sugalski
At 8:52 PM -0500 3/21/02, Clinton A. Pierce wrote: >Sorry it took me so long to get this down to something concise. I >wish it were smaller, not so critical to me, and a little more >consistent. Don't sweat it--I think that the issue is stack corruption, so I'll go poke around in the stack co

Re: Some updates

2002-03-21 Thread Melvin Smith
At 07:41 PM 3/21/2002 -0500, Dan Sugalski wrote: >On Thu, 21 Mar 2002, Melvin Smith wrote: > > > >clone Sx, sy > > > > I'm not seeing the difference between clone Sx, sy and set Sx, sy > > > > When I do: > > > > set S30, "PARROT" > > set S31, S30 > >Change this to > > clone S31, S30 > >and s

Re: Old Warnock's Dilemma for 'make quicktest'

2002-03-21 Thread Robert Spier
> make quicktest could screw up if: > - you ctrl-c it, or make test (although I haven't had problems with that > yet) during the compilation process at just the right time > - you do anything to invalidate existing .pbc files, such as rearranging > ops. not sure what else could trigger this. > >

set Sx, iy

2002-03-21 Thread Melvin Smith
Just committed the set Sx, iy op. Patch at end. Cheers, -Melvin Tested with following: # Cola (0.0.1) generated # _START: bsr __Main __END: end __Main: set I31, -123456789 LBL1: ge I31, 123456789, LBL2 set S0, I31 p

RE: set Sx, iy

2002-03-21 Thread Brent Dax
Melvin Smith: # Just committed the set Sx, iy op. # # Patch at end. # diff -u -r1.60 string.c # --- string.c 21 Mar 2002 09:56:41 - 1.60 # +++ string.c 22 Mar 2002 04:09:34 - # @@ -774,6 +774,35 @@ # return f; # } # # +STRING * # +string_from_int(struct Parrot_Interp *

Re: Some updates

2002-03-21 Thread Dan Sugalski
At 6:53 PM -0500 3/21/02, Melvin Smith wrote: >At 05:13 PM 3/21/2002 -0500, Dan Sugalski wrote: >>Folks, >> >>I've added or enabled the following ops: >> >>clone Sx, sy > >I'm not seeing the difference between clone Sx, sy and set Sx, sy > >When I do: > >set S30, "PARROT" >set S31, S30 >chopn

Re: Some updates

2002-03-21 Thread Bryan C. Warnock
On Thursday 21 March 2002 23:51, Dan Sugalski wrote: > > Okay, I see what's happening. We changed set Sx, Sy to do a copy. I'm > not sure who or when--I'll go look, not that it makes much difference. Pre-GC, if that helps narrow it down. It was the constant flag on the clone that was a cause

[PATCH] resources.c

2002-03-21 Thread Bryan C. Warnock
Fixes some UMRs, and makes GC a smidgen zippier. Index: resources.c === RCS file: /home/perlcvs/parrot/resources.c,v retrieving revision 1.31 diff -u -r1.31 resources.c --- resources.c 18 Mar 2002 20:15:02 - 1.31 +++ resourc

RE: set Sx, iy

2002-03-21 Thread Melvin Smith
At 08:53 PM 3/21/2002 -0800, Brent Dax wrote: >Just do "$1=Parrot_sprintf_c(interpreter, "%Vd", $2);". I've already >implemented this logic there; there's no sense having it in the core >twice. Calling the sprintf routine is kind of expensive if the op is only to convert an int to a base10 stri

RE: set Sx, iy

2002-03-21 Thread Melvin Smith
At 12:25 AM 3/22/2002 -0500, Melvin Smith wrote: >At 08:53 PM 3/21/2002 -0800, Brent Dax wrote: >>Just do "$1=Parrot_sprintf_c(interpreter, "%Vd", $2);". I've already >>implemented this logic there; there's no sense having it in the core >>twice. > >Calling the sprintf routine is kind of expensiv

Re: Problems with strings on the stack (small, concise example)

2002-03-21 Thread Bryan C. Warnock
It's not the stack. Addresses are being reused. (I'm watching the stack on entry to stack_push. Pop is probably working okay, too. I don't know why the old contents aren't being clobbered, though. Since I know when it happens, I'll try to narrow it down there.) `parrot`stacks.c`stack_push`

Retracted: [PATCH] resources.c

2002-03-21 Thread Bryan C. Warnock
Rolled into stack fix patch. -- Bryan C. Warnock [EMAIL PROTECTED]

[PATCH] resources.c (was Re: Problems with strings on the stack (small, concise example))

2002-03-21 Thread Bryan C. Warnock
Fixes a couple GC problems. Index: resources.c === RCS file: /home/perlcvs/parrot/resources.c,v retrieving revision 1.31 diff -u -r1.31 resources.c --- resources.c 18 Mar 2002 20:15:02 - 1.31 +++ resources.c 22 Mar 2002 06:2

(Reformatted Resend) [PATCH] resources.c

2002-03-21 Thread Bryan C. Warnock
Fixes a couple GC problems. Index: resources.c === RCS file: /home/perlcvs/parrot/resources.c,v retrieving revision 1.31 diff -u -r1.31 resources.c --- resources.c 18 Mar 2002 20:15:02 - 1.31 +++ resources.c 22 Mar 2002 06:2

[PATCH] stacks.c

2002-03-21 Thread Bryan C. Warnock
Defer allocation as long as possible. Make logic parallel. Index: stacks.c === RCS file: /home/perlcvs/parrot/stacks.c,v retrieving revision 1.23 diff -u -r1.23 stacks.c --- stacks.c8 Mar 2002 03:04:03 - 1.23 +++ stack