On Mon, Jul 17, 2006 at 09:52:35AM -0700, Allison Randal wrote:
> >: =item get_global
> >: 
> >:     $P1 = $P2.get_global($S3)
> >: 
> >: Retrieve a global variable $P1 from the namespace $P2, with the name
> >: $S3.
> >
> >What's the meaning of "global" in this context?  Some part of me
> >wants this to be simply "get_symbol".  Or are we contrasting "global"
> >with "lexical" or "private"?  See also the get*_global and set*_global
> >opcodes below, which I think should be "get_symbol" and "set_symbol".
> 
> I was also leaning in that direction, but the problem is that "symbol" 
> can also be a lexical symbol. Here we're specifically accessing symbols 
> from the global symbol table (the global tree of namespaces), so 
> "global" is the simplest way to identify it.

Another possibility is to take a cue from the "find_name" opcode
(which searches lexically, in namespaces, and global) and use "get_name"
and "set_name".  But now I think I'm bikeshedding this one, so I'll
be quiet.  

(It would be easier to avoid bikeshedding on opcode names if Parrot 
didn't already have so many naming systems to choose from.  :-)

> >Since we have slurpy named parameters in Parrot, why not simply leave $P3
> >off and use (optional) named parameters here to specify options?
> 
> Chip/Leo, do the various named parameter passing techniques work on 
> low-level PMC's defined in C?

Oh, I had forgotten that little detail.  Well, never mind.  :-)

Pm

Reply via email to