Re: function call problem in class?

2007-11-14 Thread Davy
On Nov 14, 4:10 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Wed, 14 Nov 2007 04:51:57 -0300, Davy <[EMAIL PROTECTED]> escribió: > > > I have write a simple class, I want the function two() to call private > > function __one(), but there is an error : > > NameError: global name '_simple_

Re: function call problem in class?

2007-11-14 Thread Gabriel Genellina
En Wed, 14 Nov 2007 04:51:57 -0300, Davy <[EMAIL PROTECTED]> escribió: > I have write a simple class, I want the function two() to call private > function __one(), but there is an error : > NameError: global name '_simple__one' is not defined, how to work > around it > > class simple: > def __

function call problem in class?

2007-11-13 Thread Davy
Hi all, I have write a simple class, I want the function two() to call private function __one(), but there is an error : NameError: global name '_simple__one' is not defined, how to work around it class simple: def __one(self): print "Hello" def two(self): __one()