On Fri, Jan 16, 2004 at 12:49:09PM +0100, Leopold Toetsch wrote: > Tim Bunce <[EMAIL PROTECTED]> wrote: > > Here's my proposal: > > > * Basics: > > > Parrot uses nested hashes for namespaces (like perl does). > > > > * Relative roots: > > > Namespace lookup starts from a 'root' namespace (think root directory). > > Here the P2 argument holds the root namespace to start the lookup from: > > > find_global P1, P2, ['global', 'namespace', 'hierarchy'], "thingname" > > I like that except: *again* above syntax sucks. > > find_global P1, P2 ['global'; 'namespace'; 'hierarchy'; "thingname" ] > > P2 can be a namespace PMC or the interpreter itself. > > find_global P3, P2 ['global'; 'namespace'; 'hierarchy' ] > > returns another namespace, and ... > > find_global P1, P3 [ "thingname" ] > > is the same, as the first. > > The original syntax would need heavy modifications in the assembler, the > latter fits nicely.
Sure. Sounds good. (I'm not well placed to talk about syntax as I've not yet written any parrot code, though than may be about to change, it's the principles of a unified hierarchy, chroot, and backlinks that's important.) Tim.