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
Gwenaël Samain
cython
Commits
e8a9ab94
Commit
e8a9ab94
authored
Mar 03, 2019
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix nogil status for error handling in line tracing code of with/try-finally statements.
See #2879.
parent
d6341966
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
Cython/Compiler/Nodes.py
Cython/Compiler/Nodes.py
+3
-1
No files found.
Cython/Compiler/Nodes.py
View file @
e8a9ab94
...
@@ -7539,12 +7539,14 @@ class TryFinallyStatNode(StatNode):
...
@@ -7539,12 +7539,14 @@ class TryFinallyStatNode(StatNode):
code
.
funcstate
.
in_try_finally
=
was_in_try_finally
code
.
funcstate
.
in_try_finally
=
was_in_try_finally
code
.
putln
(
"}"
)
code
.
putln
(
"}"
)
code
.
set_all_labels
(
old_labels
)
temps_to_clean_up
=
code
.
funcstate
.
all_free_managed_temps
()
temps_to_clean_up
=
code
.
funcstate
.
all_free_managed_temps
()
code
.
mark_pos
(
self
.
finally_clause
.
pos
)
code
.
mark_pos
(
self
.
finally_clause
.
pos
)
code
.
putln
(
"/*finally:*/ {"
)
code
.
putln
(
"/*finally:*/ {"
)
# Reset labels only after writing out a potential line trace call for correct nogil error handling.
code
.
set_all_labels
(
old_labels
)
def
fresh_finally_clause
(
_next
=
[
self
.
finally_clause
]):
def
fresh_finally_clause
(
_next
=
[
self
.
finally_clause
]):
# generate the original subtree once and always keep a fresh copy
# generate the original subtree once and always keep a fresh copy
node
=
_next
[
0
]
node
=
_next
[
0
]
...
...
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