Dan Sugalski <[EMAIL PROTECTED]> wrote:

> Pads shouldn't really be stacks, they should be plain linked lists.

A plain linked list is lacking the chunk allocation scheme. I'm not sure
if allocating a buffer_like and Parrot_allocate the memory for the pads
is better, then the current stack based implementation.

But I still don't know, how control stack, exception objects located
there, and scopes are playing together.

> Pads and namespaces are singly-linked lists, which we need to deal
> with separately.

WRT namespaces: pdd06 has named global tables and indexed access for
globals in such a table. This is similar to the indexed access in
lexical pads. The implementation of both is totally different though.

First we should know, if $HL is likely to access lexicals/globals by
name or by index or mixed ...
Then such a pad or namespace table probably should be a separate PMC
class with a hash and an array inside. So manipulation of these could be
done with normal opcodes + some special shortcut ops for common
operations.

leo

Reply via email to