Scope of instantiated class

Michael Hudson mwh at python.net
Wed Jul 24 07:25:16 EDT 2002


Peter Hansen <peter at engcorp.com> writes:

> Aahz wrote:
> > 
> > In article <3D3B4F80.B0D6BE07 at engcorp.com>,
> > Peter Hansen  <peter at engcorp.com> wrote:
> > >I'm trying to follow Aahz' advice and avoid "reference" in favour of
> > >"binding" etc, but I guess I carried it too far! :)
> > 
> > <grin>  Your problem wasn't in your use of "binding", but in your use of
> > "name; I use "target" to refer to the general case of thingy that can
> > contain a binding, of which names are a subset.  "Names" are words
> > attached to a namespace (i.e. function local, module global, builtin, or
> > object attribute).  Another target is an index/key for container
> > objects.
> 
> Hmmm... "target" sounds like the wrong direction.  Shouldn't it
> be a "source" for the binding?  Or maybe another term which doesn't
> have what seems to me the potential for confusion would be better.

Common Lisp calls them "places", which is a reasonable name.  It's not
that much of an issue in Python as there aren't that many of them
(names, attributes, subscripts, slices).  In CL, you can define your
own (tho' it's a bit tricky).

Cheers,
M.

-- 
  MARVIN:  Oh dear, I think you'll find reality's on the blink again.
                   -- The Hitch-Hikers Guide to the Galaxy, Episode 12



More information about the Python-list mailing list