projects
/
platform
/
upstream
/
python-cython.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3bd0ad9
)
move exception class into shadow function as we may not want to export it under the...
author
Stefan Behnel
<stefan_ml@behnel.de>
Sun, 20 Jan 2013 07:08:15 +0000
(08:08 +0100)
committer
Stefan Behnel
<stefan_ml@behnel.de>
Sun, 20 Jan 2013 07:08:15 +0000
(08:08 +0100)
Cython/Shadow.py
patch
|
blob
|
history
diff --git
a/Cython/Shadow.py
b/Cython/Shadow.py
index
c6f8018
..
5ee857b
100644
(file)
--- a/
Cython/Shadow.py
+++ b/
Cython/Shadow.py
@@
-28,10
+28,6
@@
class _ArrayType(object):
return "%s[%s]" % (self.dtype, ", ".join(axes))
-class InvalidTypeSpecification(Exception):
- pass
-
-
def index_type(base_type, item):
"""
Support array type creation by slicing, e.g. double[:, :] specifies
@@
-40,6
+36,9
@@
def index_type(base_type, item):
"""
assert isinstance(item, (tuple, slice))
+ class InvalidTypeSpecification(Exception):
+ pass
+
def verify_slice(s):
if s.start or s.stop or s.step not in (None, 1):
raise InvalidTypeSpecification(