On Wed, 27 Oct 2004, Leopold Toetsch wrote:
E.g. when you have a sub that ends with:
set P5, 100 # ret value set I0, 0 # non-prototyped set I3, 0 # no return value invoke P1 # return
then P5 will not be passed to the caller.
right. but i'm explicitly using .pcc_begin_return/.return/.pcc_end_return to return values from subs run with Parrot_call. my C code then retrieves the return value from I5, which is where the return integer value would be copied. your changes would save me from having to fetch directly from I5, but until those changes are made, is this the "right way" to be doing this?
Yep that's ok. If the sub indicates an return value it is and will be availabe, in your case as REG_INT(5) in C.
-jeff
leo