[PATCH] Stomp a warning in pybuiltin.pmc

2004-12-21 Thread Simon Glover
The attached patch fixes this warning in pybuiltin.pmc: pybuiltin.pmc: In function `make_type': pybuiltin.pmc:76: warning: declaration of `nameprop' shadows previous local Simon --- dynclasses/pybuiltin.pmc.oldTue Dec 21 15:30:01 2004 +++ dynclasses/pybuiltin.pmcTue Dec 21 15:3

Re: cvs commit: parrot/dynclasses pybuiltin.pmc pyclass.pmc pyfunc.pmc pylist.pmc pynone.pmc

2004-12-21 Thread Sam Ruby
Leopold Toetsch wrote: Sam Ruby wrote: Leopold Toetsch wrote: What is the rational for this pythonism in Parrot core? +The line of code in test case t/pie/b3 that motivates this is: + + print "using", cmp.__name__ + +Where cmp may be a NCI subroutine. Python's builtin "cmp" is basially a Sub PMC.

Re: MMD and VTABLE_find_method

2004-12-21 Thread Sam Ruby
Leopold Toetsch wrote: Sam Ruby wrote: Leopold Toetsch wrote: A few things to note: "foo" is a PMC. It therefore is an object. It can have state (properties, attributes, etc). It can "know" how many arguments are involved in multiple dispatch. The MMD information can't hang off the Sub PMCs.

Re: [perl #33129] N registers get whacked in odd circumstances

2004-12-21 Thread Leopold Toetsch
Dan Sugalski wrote: At 10:56 AM +0100 12/21/04, Leopold Toetsch wrote: The program below shows exactly the same behavior WRT __set_number_native. The call comes from inside of the mmd_fallback function, so I presume that in the part before the shown trace you are having some kind of mathematica

Re: [perl #33129] N registers get whacked in odd circumstances

2004-12-21 Thread Dan Sugalski
At 10:56 AM +0100 12/21/04, Leopold Toetsch wrote: Dan Sugalski (via RT) wrote: You'll note that N5 is set to 22253 when the returncc's done, but after the return the value is -21814.6. Looks like something's stomping the N registers. The program below shows exactly the same behavior WRT __set_n

Re: cvs commit: parrot/dynclasses pybuiltin.pmc pyclass.pmc pyfunc.pmc pylist.pmc pynone.pmc

2004-12-21 Thread Leopold Toetsch
Sam Ruby wrote: Leopold Toetsch wrote: What is the rational for this pythonism in Parrot core? +The line of code in test case t/pie/b3 that motivates this is: + + print "using", cmp.__name__ + +Where cmp may be a NCI subroutine. Python's builtin "cmp" is basially a Sub PMC. Parrot Sub's have alre

Re: MMD and VTABLE_find_method

2004-12-21 Thread Leopold Toetsch
Sam Ruby wrote: Leopold Toetsch wrote: A few things to note: "foo" is a PMC. It therefore is an object. It can have state (properties, attributes, etc). It can "know" how many arguments are involved in multiple dispatch. The MMD information can't hang off the Sub PMCs. How do you find the co

Re: cvs commit: parrot/dynclasses pybuiltin.pmc pyclass.pmc pyfunc.pmc pylist.pmc pynone.pmc

2004-12-21 Thread Sam Ruby
Leopold Toetsch wrote: Sam Ruby <[EMAIL PROTECTED]> wrote: --- nci.pmc7 May 2004 10:33:26 - 1.27 +++ nci.pmc20 Dec 2004 22:27:11 - 1.28 +=item C + +Return attribute named C. + +=cut + +*/ + +PMC* get_attr_str(STRING* idx) { +return VTABLE_getprop(

Re: cvs commit: parrot/dynclasses pybuiltin.pmc pyclass.pmc pyfunc.pmc pylist.pmc pynone.pmc

2004-12-21 Thread Leopold Toetsch
Sam Ruby <[EMAIL PROTECTED]> wrote: > --- nci.pmc 7 May 2004 10:33:26 - 1.27 > +++ nci.pmc 20 Dec 2004 22:27:11 - 1.28 > +=item C > + > +Return attribute named C. > + > +=cut > + > +*/ > + > +PMC* get_attr_str(STRING* idx) { > +return VTABLE_g

Re: MMD and VTABLE_find_method

2004-12-21 Thread Sam Ruby
Leopold Toetsch wrote: Sam Ruby wrote: Leopold Toetsch wrote: However, from : Whenever you make a call using subroutine call syntax, it's a candidate for multiple dispatch. I read this to mean that the *caller* does nothing to distingu

Re: P5 is the new P2

2004-12-21 Thread Sam Ruby
Matt Fowles wrote: P5 is the new P2 Sam and Leo came to the conclusion that the current object should be passed in P5 as well as P2. Currently they are waiting for Dan... Nudge, Nudge... I've implemented this, but I am near the point of recanting. Examples

Re: MMD and VTABLE_find_method

2004-12-21 Thread Leopold Toetsch
Sam Ruby wrote: Leopold Toetsch wrote: However, from : Whenever you make a call using subroutine call syntax, it's a candidate for multiple dispatch. I read this to mean that the *caller* does nothing to distinguish between calls to si

Re: [perl #33129] N registers get whacked in odd circumstances

2004-12-21 Thread Leopold Toetsch
Dan Sugalski (via RT) wrote: You'll note that N5 is set to 22253 when the returncc's done, but after the return the value is -21814.6. Looks like something's stomping the N registers. The program below shows exactly the same behavior WRT __set_number_native. The call comes from inside of the mmd