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
5707c854
Commit
5707c854
authored
Dec 09, 2010
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
typing fixes in compiled Code.py
parent
d7d16c4c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
3 deletions
+12
-3
Cython/Compiler/Code.pxd
Cython/Compiler/Code.pxd
+10
-3
Cython/Compiler/Code.py
Cython/Compiler/Code.py
+2
-0
No files found.
Cython/Compiler/Code.pxd
View file @
5707c854
cimport
cython
cdef
class
UtilityCode
:
cdef
public
object
proto
cdef
public
object
impl
...
...
@@ -9,14 +11,14 @@ cdef class UtilityCode:
cdef
public
list
specialize_list
cdef
public
object
proto_block
cpdef
put_code
(
self
,
dict
output
)
cpdef
put_code
(
self
,
output
)
cdef
class
FunctionState
:
cdef
public
set
names_taken
cdef
public
object
owner
cdef
public
object
error_label
cdef
public
Py_s
size_t
label_counter
cdef
public
size_t
label_counter
cdef
public
set
labels_used
cdef
public
object
return_label
cdef
public
object
continue_label
...
...
@@ -30,8 +32,10 @@ cdef class FunctionState:
cdef
public
list
temps_allocated
cdef
public
dict
temps_free
cdef
public
dict
temps_used_type
cdef
public
Py_s
size_t
temp_counter
cdef
public
size_t
temp_counter
@
cython
.
locals
(
n
=
size_t
)
cpdef
new_label
(
self
,
name
=*
)
cpdef
tuple
get_loop_labels
(
self
)
cpdef
set_loop_labels
(
self
,
labels
)
cpdef
tuple
get_all_labels
(
self
)
...
...
@@ -54,6 +58,9 @@ cdef class StringConst:
cdef
public
object
escaped_value
cdef
public
dict
py_strings
@
cython
.
locals
(
intern
=
bint
,
is_str
=
bint
,
is_unicode
=
bint
)
cpdef
get_py_string_const
(
self
,
encoding
,
identifier
=*
,
is_str
=*
)
## cdef class PyStringConst:
## cdef public object cname
## cdef public object encoding
...
...
Cython/Compiler/Code.py
View file @
5707c854
...
...
@@ -293,6 +293,8 @@ class PyObjectConst(object):
self
.
cname
=
cname
self
.
type
=
type
cython
.
declare
(
possible_unicode_identifier
=
object
,
possible_bytes_identifier
=
object
,
nice_identifier
=
object
,
find_alphanums
=
object
)
possible_unicode_identifier
=
re
.
compile
(
ur"(?![0-9])\
w+$
", re.U).match
possible_bytes_identifier = re.compile(r"
(
?!
[
0
-
9
])
\
w
+
$
".encode('ASCII')).match
nice_identifier = re.compile(r'
\
A[
a
-zA-Z0-9_]+
\
Z
'
).match
...
...
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