[Python-Dev] Re: [Python-checkins] CVS: python/dist/src/Include rangeobject.h,2.16,2.17
Fredrik Lundh
fredrik@pythonware.com
Mon, 9 Jul 2001 10:11:02 +0200
barry wrote:
> As you say, this has always been flaky, inconsistent, underspecified,
> and unpredictable
>>> class C: pass
...
>>> c = C()
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
>>> len(c)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'C' instance has no attribute '__len__'
looks pretty predictable to me...
</F>