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
6689e031
Commit
6689e031
authored
Jan 18, 2011
by
Mark Florisson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Debugger: fix is_initialized to avoid segfaults with cy exec
parent
d6027cb2
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
13 deletions
+12
-13
Cython/Debugger/libcython.py
Cython/Debugger/libcython.py
+12
-13
No files found.
Cython/Debugger/libcython.py
View file @
6689e031
...
...
@@ -389,20 +389,19 @@ class CythonBase(object):
value
)
def
is_initialized
(
self
,
cython_func
,
local_name
):
islocal
=
local_name
in
cython_func
.
locals
if
islocal
:
cyvar
=
cython_func
.
locals
[
local_name
]
cur_lineno
=
self
.
get_cython_lineno
()
if
'->'
in
cyvar
.
cname
:
# Closed over free variable
if
self
.
get_cython_lineno
()
>=
cython_func
.
lineno
+
1
:
if
cur_lineno
>
cython_func
.
lineno
:
if
cyvar
.
type
==
PythonObject
:
return
long
(
gdb
.
parse_and_eval
(
cyvar
.
cname
))
return
True
return
False
cur_lineno
=
self
.
get_cython_lineno
()
return
(
local_name
in
cython_func
.
arguments
or
(
islocal
and
cur_lineno
>
cyvar
.
lineno
))
return
cur_lineno
>
cyvar
.
lineno
class
SourceFileDescriptor
(
object
):
def
__init__
(
self
,
filename
,
lexer
,
formatter
=
None
):
...
...
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