summaryrefslogtreecommitdiff
path: root/numpy/core
diff options
context:
space:
mode:
authorTravis Oliphant <oliphant@enthought.com>2006-08-03 20:19:30 +0000
committerTravis Oliphant <oliphant@enthought.com>2006-08-03 20:19:30 +0000
commit63c8a61a6e7eca823b34b65b0a23cd6ea40623c8 (patch)
tree17dcc32e4de957345827d27b77f5556399160964 /numpy/core
parent668950285c407593a368336ff2e737c5da84af7d (diff)
downloadnumpy-63c8a61a6e7eca823b34b65b0a23cd6ea40623c8.tar.gz
A few corrections to scalar-type tests
Diffstat (limited to 'numpy/core')
-rw-r--r--numpy/core/numeric.py2
-rw-r--r--numpy/core/numerictypes.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/numpy/core/numeric.py b/numpy/core/numeric.py
index 0d1b69ae9..166a2d5cc 100644
--- a/numpy/core/numeric.py
+++ b/numpy/core/numeric.py
@@ -354,7 +354,7 @@ def isscalar(num):
if isinstance(num, generic):
return True
else:
- return issctype(type(num))
+ return type(num) in ScalarType
_lkup = {
'0':'0000',
diff --git a/numpy/core/numerictypes.py b/numpy/core/numerictypes.py
index ddb87294e..89d3a6d9d 100644
--- a/numpy/core/numerictypes.py
+++ b/numpy/core/numerictypes.py
@@ -346,7 +346,7 @@ def issctype(rep):
return False
try:
res = obj2sctype(rep)
- if res:
+ if res and res != object_:
return True
return False
except: