[Zope-dev] Recursion
Phil Harris
phil.harris@zope.co.uk
Fri, 26 May 2000 09:54:55 +0100
I'd imagine self would be missing.
There would seem to be two ways to 'fix' this, I'll leave it as an exercise
for the reader to discuss which is best.
Option 1:
def foo(self,counter=None):
some code
if bar == somewhat:
self.foo(counter=some_int)
Option 2:
def foo(self,counter=None):
some code
if bar == somewhat:
foo(self,counter=some_int)
hth
Phil
phil.harris@zope.co.uk
----- Original Message -----
From: "Andre Schubert" <andre.schubert@geyer.kabeljournal.de>
To: <zope-dev@zope.org>
Sent: Friday, May 26, 2000 9:02 AM
Subject: [Zope-dev] Recursion
> Hi,
>
> I'm writing a python Extension, which searches in any folder
> recursively.
>
> This means the code:
>
> def foo(self,counter=None):
> some code
> if bar == somewhat:
> foo(counter=some_int)
>
> When i run this through zope a error occours. Zope says expected 1
> argument got 0.
> My question is what argument is missing.
>
> mfg as
>
>
> _______________________________________________
> Zope-Dev maillist - Zope-Dev@zope.org
> http://lists.zope.org/mailman/listinfo/zope-dev
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope )