Re: parrot bug: continuations/multiple return

2003-08-09 Thread Leopold Toetsch
Michal Wallace wrote: def f(x): if x: return 1 else: return 0 print f(1), f(0) Nice coincidence. S. Togos' bug report too. Anyway, its already fixed. leo

Re: [perl #23025] [PATCH] env.t doesn't test the env ops on solaris (and others)

2003-08-09 Thread Leopold Toetsch
Lars Balker Rasmussen [EMAIL PROTECTED] wrote: We'll postpone deciding on this one until later - I've attached a patch to env.t that tests the env-implementation on all platforms, and doesn't fail on Solaris. Thanks, applied. leo

Re: pcc_return problem

2003-08-09 Thread Leopold Toetsch
Togos [EMAIL PROTECTED] wrote: If I have more than one .pcc_begin_return Fixed. Thanks again for the bug report. (Return conventions are still missing) leo

why new_pad *INT*?

2003-08-09 Thread Michal Wallace
Hey all, I'm just starting to get into using pads, and I'm not sure I understand new_pad. Specifically, why does it take an int? It seems to me, that 9 times out of 10, you're going to want to create a new pad at the next lower depth than the one before. So, two questions: 1. Should there

Re: Re[2]: parrot, win32, stand-alone distribution, separate Parrot maillist

2003-08-09 Thread Jonathan Worthington
- Original Message - From: Vladimir Lipskiy [EMAIL PROTECTED] To: perl6-internals [EMAIL PROTECTED]; Jonathan Worthington [EMAIL PROTECTED] Sent: Wednesday, August 06, 2003 1:47 AM Subject: Re: Re[2]: parrot, win32, stand-alone distribution, separate Parrot maillist Is it as simple as

Re: Set vs. Assign..?

2003-08-09 Thread Benjamin Goldberg
Leopold Toetsch wrote: Benjamin Goldberg [EMAIL PROTECTED] wrote: I would suggest the opnames/categories mutate, alias, and create. IMHO, we could leave PASM syntax as it is and create opcode aliases inside the assembler ... You mean leave the old ops with their names, but merely

Re: Perl 6's for() signature

2003-08-09 Thread Luke Palmer
Abhijit A. Mahabal [EMAIL PROTECTED] writes: There is another problem beyond efficiency: the P6 list semantics is lazy. The following is valid P6, AFAIK: for 1 .. Inf { print $_; last when 10; } Yeah, but that's a foreach loop, despite the fact that foreach is spelled

Re: Perl 6's for() signature

2003-08-09 Thread Jonadab the Unsightly One
Abhijit A. Mahabal [EMAIL PROTECTED] writes: There is another problem beyond efficiency: the P6 list semantics is lazy. The following is valid P6, AFAIK: for 1 .. Inf { print $_; last when 10; } Yeah, but that's a foreach loop, despite the fact that foreach is spelled for in your

Re: calling conventions, variable-length parameter lists

2003-08-09 Thread TOGoS
Luke said: Plus, parameters to functions are likely to be used in the code of the function (and likewise with return values), so we're just skipping unloading the array into registers. OK. That makes sense, but my problem is: in the case that the called function *does* treat its parameter

Re: calling conventions, variable-length parameter lists

2003-08-09 Thread Leopold Toetsch
Michal Wallace [EMAIL PROTECTED] wrote: On Fri, 8 Aug 2003, TOGoS wrote: Unprototyped :-) I guess I didn't make that quite clear, enough. Setup a param array, that's all. Hmm. That would be easy if there were an easy way to loop through the registers... reg = 5 for x = 1 to numparams:

Re: calling conventions, variable-length parameter lists

2003-08-09 Thread Luke Palmer
I want to be able to have a function with this kind of signature: func ($param1, *$otherparams) Uh. What kind of signature? What does that mean? If it's Perl 6, sub ($param1, *$otherparams) Is nothing special: it takes two parameters. Did you mean sub ($param1, [EMAIL

Re: Perlarray internals

2003-08-09 Thread Dan Sugalski
At 7:55 PM -0400 8/7/03, Simon Glover wrote: In the get_integer_keyed_int method in perlarray.pmc, we're cuurently doing: [Snip] (with similar code for get_number_keyed_int and get_string_keyed_int). In other words, if we're referencing an element outside the current array bounds, then we

Re: assign opcodes

2003-08-09 Thread Benjamin Goldberg
Togos wrote: Anyway: assign Px, {Iy,Sy,Ny} are not needed IMHO, these end up as set_type_native and are identical to set Px, {Iy,Sy,Ny}. Yes, but as we were discussing in the Set vs. Assign thread, it makes more sense to call them 'assign', as it morphs the existing value

Re: assign opcodes

2003-08-09 Thread Benjamin Goldberg
Leopold Toetsch wrote: I hopefully got the semantics of assign Px,Py right now. The LHS gets the value of RHS, eventually morphing itself to the source type. Anyway: assign Px, {Iy,Sy,Ny} are not needed IMHO, these end up as set_type_native and are identical to set Px,

set_pmc vs clone?

2003-08-09 Thread Benjamin Goldberg
What's the difference between VTABLE_set_pmc and VTABLE_clone? -- $a=24;split//,240513;s/\B/ = /for@@=qw(ac ab bc ba cb ca );{push(@b,$a),($a-=6)^=1 for 2..$a/6x--$|;print [EMAIL PROTECTED] ]\n;((6=($a-=6))?$a+=$_[$a%6]-$a%6:($a=pop @b))redo;}

Re: [CVS ci] bitwise string vtables; ands, ors opcodes

2003-08-09 Thread Leopold Toetsch
Vladimir Lipskiy [EMAIL PROTECTED] wrote: The third attempt, here it is: Applied finally, thanks for the patch. Some minor notes: please send patches as attachments (some lines got wrapped). And as already mentioned please try to figure out, how to get a unified diff: cvs diff -u There

IMCC warning cascade

2003-08-09 Thread Vladimir Lipskiy
D:\build\parrotnmake [snip] imcparser.c imcparser.c imcc.y(527) : warning C4761: integral size mismatch in argument; conversion supplied imcc.y(590) : warning C4761: integral size mismatch in argument; conversion supplied imcc.y(666) : warning C4761: integral size mismatch in argument;

Re: [CVS ci] bitwise string vtables; ands, ors opcodes

2003-08-09 Thread Dan Sugalski
At 1:35 AM +0300 8/8/03, Vladimir Lipskiy wrote: What in $DEITY's name is *that*? It sure isn't a context diff. A context diff is what you get from diff -u or diff -c. What you saw was the context diff I provided myself (~: I doubt it's possible to provide a context diff WinCVS. Though, I

Re: [RfC] disable unused vtable entries

2003-08-09 Thread Dan Sugalski
At 8:53 PM +0100 8/6/03, Nicholas Clark wrote: On Tue, May 20, 2003 at 04:33:31PM +0200, Leopold Toetsch wrote: In perl.perl6.internals, I wrote: When looking at classes/*.c struct _vtable temp_base_vtable {} by far the most vtable methods are unused or uncovered by opcodes: Some more

Re: Set vs. Assign..?

2003-08-09 Thread Leopold Toetsch
Benjamin Goldberg [EMAIL PROTECTED] wrote: Leopold Toetsch wrote: Benjamin Goldberg [EMAIL PROTECTED] wrote: I would suggest the opnames/categories mutate, alias, and create. IMHO, we could leave PASM syntax as it is and create opcode aliases inside the assembler ... I would rather

Re: struct Parrot_Lexicals; ArrayHash

2003-08-09 Thread Leopold Toetsch
Matt Fowles [EMAIL PROTECTED] wrote: Leo~ Why not just use a hash and ditch the array then? Because $HL may emit code to access lexicals by numeric index. Matt leo