On Wed, Jul 23, 2008 at 8:53 AM, David Kaplan <[EMAIL PROTECTED]> wrote:
> That should be an "and" not an "or"
OK, I'll leave the final fix to you.
JDH
-
This SF.Net email is sponsored by the Moblin Your Move Developer'
Hi,
Almost:
In [3]: cbook.is_scalar((0,1))
Out[3]: True
That should be an "and" not an "or".
Cheers,
David
On Wed, 2008-07-23 at 08:16 -0500, John Hunter wrote:
> On Wed, Jul 23, 2008 at 4:04 AM, David Kaplan <[EMAIL PROTECTED]> wrote:
> > Hi,
> >
> > I believe that the cbook.is_scalar functio
On Wed, Jul 23, 2008 at 4:04 AM, David Kaplan <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I believe that the cbook.is_scalar function has a bug:
>
> In [19]: cbook.is_scalar('abc')
> Out[19]: 1
>
> I believe it should be:
>
> def is_scalar(obj):
>'return true if *obj* is not string like and is not ite
Hi,
I believe that the cbook.is_scalar function has a bug:
In [19]: cbook.is_scalar('abc')
Out[19]: 1
I believe it should be:
def is_scalar(obj):
'return true if *obj* is not string like and is not iterable'
return not is_string_like(obj) and not iterable(obj)
Cheers,
David
--
**