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
5cfaca9c
Commit
5cfaca9c
authored
May 20, 2011
by
Mark Florisson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reintroduce accidentally removed line
parent
d1465de3
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
7 deletions
+12
-7
Cython/Compiler/Nodes.py
Cython/Compiler/Nodes.py
+9
-5
Cython/Compiler/ParseTreeTransforms.py
Cython/Compiler/ParseTreeTransforms.py
+1
-0
tests/run/parallel.pyx
tests/run/parallel.pyx
+1
-1
tests/run/sequential_parallel.pyx
tests/run/sequential_parallel.pyx
+1
-1
No files found.
Cython/Compiler/Nodes.py
View file @
5cfaca9c
...
...
@@ -5498,7 +5498,8 @@ class TryFinallyStatNode(StatNode):
code
.
error_label
=
old_error_label
if
cases_used
:
code
.
putln
(
"switch (__pyx_why) {"
)
code
.
putln
(
"switch (__pyx_why) {"
)
for
i
in
cases_used
:
old_label
=
old_labels
[
i
]
if
old_label
==
old_error_label
and
self
.
preserve_exception
:
...
...
@@ -5507,8 +5508,13 @@ class TryFinallyStatNode(StatNode):
code
.
use_label
(
old_label
)
code
.
putln
(
"case %s: goto %s;"
%
(
i
+
1
,
old_label
))
code
.
putln
(
"}"
)
code
.
putln
(
"}"
)
# End the switch
code
.
putln
(
"}"
)
# End finally
code
.
putln
(
"}"
)
def
generate_function_definitions
(
self
,
env
,
code
):
self
.
body
.
generate_function_definitions
(
env
,
code
)
...
...
@@ -5573,8 +5579,6 @@ class GILStatNode(NogilTryFinallyStatNode):
#
# state string 'gil' or 'nogil'
# child_attrs = []
def
__init__
(
self
,
pos
,
state
,
body
):
self
.
state
=
state
TryFinallyStatNode
.
__init__
(
self
,
pos
,
...
...
Cython/Compiler/ParseTreeTransforms.py
View file @
5cfaca9c
...
...
@@ -2031,6 +2031,7 @@ class GilCheck(VisitorTransform):
node
.
nogil_check
(
self
.
env_stack
[
-
1
])
self
.
visitchildren
(
node
)
return
node
def
visit_TryFinallyStatNode
(
self
,
node
):
"""
...
...
tests/run/parallel.pyx
View file @
5cfaca9c
...
...
@@ -24,4 +24,4 @@ def test_parallel():
free
(
buf
)
#
include "sequential_parallel.pyx"
include
"sequential_parallel.pyx"
tests/run/sequential_parallel.pyx
View file @
5cfaca9c
...
...
@@ -50,7 +50,7 @@ def test_propagation():
>>> test_propagation()
(9, 9, 9, 9, 450, 450)
"""
cdef
int
i
,
j
,
x
,
y
cdef
int
i
=
0
,
j
=
0
,
x
=
0
,
y
=
0
cdef
int
sum1
=
0
,
sum2
=
0
for
i
in
prange
(
10
,
nogil
=
True
):
...
...
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