Oops...
Just finished sending my earlier response and realize that I overlooked an
issue.
The code from http://viner.tv/go?set is potentially errant. When
invoking the base class constructor, self should have been explcitly
sent as a parameter, using the syntax
class Set(list):
Tom wrote:
> I am trying to understand what happens in the following scenario:
>
> class Sub_class(Base_class):
> def __init__(self, data):
> Base_class.__init__(self, data)
>
> as in:
>
> # snippet from http://viner.tv/go?set
> class Set(list):
> def __init__(self, value = []):
On Thursday November 15, 2007, Tom wrote:
>I am trying to understand what happens in the following scenario:
>
>class Sub_class(Base_class):
>def __init__(self, data):
>Base_class.__init__(self, data)
>
>as in:
>
># snippet from http://viner.tv/go?
I am trying to understand what happens in the following scenario:
class Sub_class(Base_class):
def __init__(self, data):
Base_class.__init__(self, data)
as in:
# snippet from http://viner.tv/go?set
class Set(list):
def __init__(self, value = []):
list.__init__([])
The l