How to override invoke?

Will Coleda will at coleda.com
Mon Dec 29 22:35:16 UTC 2008


On Mon, Dec 29, 2008 at 5:30 PM, Andrew Whitworth <wknight8111 at gmail.com> wrote:
> The attached code works and does what you would think it should.
> However, there is one snag:
>
> $P0($P0)
>
> This is because when you override the invoke vtable method from PIR,
> you don't have access to the "self" pmc by default. You have to pass
> it explicitly.

That's a pretty big snag, as it forces me to change every instance
where a procedure is invoked in my code. (If I'm doing that anyway, I
don't need a vtable override.)

Thanks for fleshing out this idea, though: I think it reinforces that
'self' is not acting as expected for this particular override, and we
can probably convert this thread into a ticket with a failing test to
demonstrate it.

-- 
Will "Coke" Coleda


More information about the parrot-dev mailing list