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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
cython
Commits
807d2939
Commit
807d2939
authored
Apr 18, 2012
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove the now redundant None check in __Pyx_GetItemInt_[List|Tuple]_Fast() utility functions
parent
c8f61a66
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
13 deletions
+9
-13
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+9
-13
No files found.
Cython/Compiler/ExprNodes.py
View file @
807d2939
...
@@ -9801,17 +9801,15 @@ static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j
...
@@ -9801,17 +9801,15 @@ static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j
__Pyx_GetItemInt_Generic(o, to_py_func(i)))
__Pyx_GetItemInt_Generic(o, to_py_func(i)))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_%(type)s_Fast(PyObject *o, Py_ssize_t i) {
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_%(type)s_Fast(PyObject *o, Py_ssize_t i) {
if (likely(o != Py_None)) {
if (likely((0 <= i) & (i < Py%(type)s_GET_SIZE(o)))) {
if (likely((0 <= i) & (i < Py%(type)s_GET_SIZE(o)))) {
PyObject *r = Py%(type)s_GET_ITEM(o, i);
PyObject *r = Py%(type)s_GET_ITEM(o, i);
Py_INCREF(r);
Py_INCREF(r);
return r;
return r;
}
}
else if ((-Py%(type)s_GET_SIZE(o) <= i) & (i < 0)) {
else if ((-Py%(type)s_GET_SIZE(o) <= i) & (i < 0)) {
PyObject *r = Py%(type)s_GET_ITEM(o, Py%(type)s_GET_SIZE(o) + i);
PyObject *r = Py%(type)s_GET_ITEM(o, Py%(type)s_GET_SIZE(o) + i);
Py_INCREF(r);
Py_INCREF(r);
return r;
return r;
}
}
}
return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
}
}
...
@@ -9847,8 +9845,6 @@ static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i)
...
@@ -9847,8 +9845,6 @@ static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i)
}
}
return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
}
}
"""
,
impl
=
"""
"""
)
"""
)
...
...
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