How should the PerlScalar PMC behave in the following situation? new P0, .PerlScalar new P1, .PerlArray assign P0, P1
The assign opcode will call PerlScalar's set_pmc function, which needs to get a value from P1, so it calls PerlArray's XXXXX function?? The two obvious options seem to be: vtable method get_scalar(pmc) vtable method get_value(pmc, context) I would prefer the latter, because it is less Perl-centric, and keeps the sizeof the vtable smaller once other contexts are introduced; however, this is slightly slower, as get_value will need to check its context and act accordingly. If context was an enumeration, a simple switch statement would suffice. In this case, it might be interesting to benchmark the consequences of replacing some of the other get_X vtable functions. e.g. get_integer(pmc) -> get_value(pmc, CONTEXT_INTEGER) Comments, anyone? -- Peter Gibbs EmKel Systems