On Jan 8, 1:45 am, Steven D'Aprano <ste...@remove.this.cybersource.com.au> wrote: > On Wed, 07 Jan 2009 10:17:55 +0000, Mark Wooding wrote: snip > > The `they're just objects' model is very simple, but gets tied up in > > knots explaining things. The `it's all references' model is only a > > little more complicated, but explains everything. > > But it *over* explains, because it implies things that "everybody knows" > about references in other languages that aren't true for Python. > > Of course it's not literally true that "everybody knows" that you can use > references to implement a swap(x, y) procedure. But people coming from a > C or Pascal background tend to assume that everything is like C/Pascal, > and there are a lot of them. If C was a rare, unfamiliar language, my > opposition to using the term "reference" would be a lot milder. Maybe in > another five years? > > > No, indeed. Python is a language for talking about paperweights. And > > it's because of the paperweights that the duck-typing works: all the > > paperweights are the same shape and size, so they're physically > > interchangeable. > > Okay, the abstraction has leaked again... are the paperweights references > to the objects, or the names we've bound objects to? I'm confused... > > How do we deal with anonymous objects in your model? > > -- > Steven
Mark, hi, Steven, pleasure as always. Neither side is perfect or wild; (Do admit it); How do we decide what is best for newcomers to Python, depending on background? -- http://mail.python.org/mailman/listinfo/python-list