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
Xavier Thompson
cython
Commits
94d982d8
Commit
94d982d8
authored
Jul 31, 2017
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
repair "except" on tuples
parent
0a8a04af
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
Cython/Utility/Exceptions.c
Cython/Utility/Exceptions.c
+11
-0
No files found.
Cython/Utility/Exceptions.c
View file @
94d982d8
...
...
@@ -35,6 +35,17 @@ static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tsta
PyObject
*
exc_type
=
tstate
->
curexc_type
;
if
(
exc_type
==
err
)
return
1
;
if
(
unlikely
(
!
exc_type
))
return
0
;
if
(
unlikely
(
PyTuple_Check
(
err
)))
{
Py_ssize_t
i
,
n
;
n
=
PyTuple_GET_SIZE
(
err
);
for
(
i
=
0
;
i
<
n
;
i
++
)
{
if
(
exc_type
==
PyTuple_GET_ITEM
(
err
,
i
))
return
1
;
}
for
(
i
=
0
;
i
<
n
;
i
++
)
{
if
(
__Pyx_PyErr_GivenExceptionMatches
(
exc_type
,
PyTuple_GET_ITEM
(
err
,
i
)))
return
1
;
}
return
0
;
}
return
__Pyx_PyErr_GivenExceptionMatches
(
exc_type
,
err
);
}
#endif
...
...
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