Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
429796f0
Commit
429796f0
authored
Aug 02, 2017
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add test that len(memoryview) works
parent
1befcd38
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
tests/memoryview/memoryviewattrs.pyx
tests/memoryview/memoryviewattrs.pyx
+7
-0
No files found.
tests/memoryview/memoryviewattrs.pyx
View file @
429796f0
...
...
@@ -260,6 +260,11 @@ def call():
print
(
<
int
*>
mv3
.
_data
)[
0
]
,
(
<
int
*>
mv2
.
_data
)[
0
]
,
(
<
int
*>
mv1
.
_data
)[
0
]
assert
len
(
mv1
)
==
3
assert
len
(
mv2
)
==
3
assert
len
(
mv3
)
==
3
@
testcase
def
two_dee
():
u'''
...
...
@@ -272,6 +277,8 @@ def two_dee():
cdef
long
[:,::
1
]
mv1
,
mv2
,
mv3
cdef
array
arr
=
array
((
2
,
2
),
sizeof
(
long
),
'l'
)
assert
len
(
arr
)
==
2
cdef
long
*
arr_data
arr_data
=
<
long
*>
arr
.
data
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment