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
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
22111321
Commit
22111321
authored
Nov 02, 2010
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
prevent 'file' from being recognised as a builtin type - it's no longer available in Py3
parent
f5e3ddee
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
Cython/Compiler/Builtin.py
Cython/Compiler/Builtin.py
+3
-2
Cython/Compiler/Symtab.py
Cython/Compiler/Symtab.py
+1
-1
No files found.
Cython/Compiler/Builtin.py
View file @
22111321
...
@@ -115,7 +115,7 @@ builtin_types_table = [
...
@@ -115,7 +115,7 @@ builtin_types_table = [
(
"copy"
,
"O"
,
"O"
,
"PyDict_Copy"
)]),
(
"copy"
,
"O"
,
"O"
,
"PyDict_Copy"
)]),
(
"slice"
,
"PySlice_Type"
,
[]),
(
"slice"
,
"PySlice_Type"
,
[]),
(
"file"
,
"PyFile_Type"
,
[]),
# ("file", "PyFile_Type", []), # not in Py3
(
"set"
,
"PySet_Type"
,
[(
"clear"
,
"O"
,
"i"
,
"PySet_Clear"
),
(
"set"
,
"PySet_Type"
,
[(
"clear"
,
"O"
,
"i"
,
"PySet_Clear"
),
(
"discard"
,
"OO"
,
"i"
,
"PySet_Discard"
),
(
"discard"
,
"OO"
,
"i"
,
"PySet_Discard"
),
...
@@ -128,8 +128,9 @@ types_that_construct_their_instance = (
...
@@ -128,8 +128,9 @@ types_that_construct_their_instance = (
# some builtin types do not always return an instance of
# some builtin types do not always return an instance of
# themselves - these do:
# themselves - these do:
'type'
,
'bool'
,
'long'
,
'float'
,
'bytes'
,
'unicode'
,
'tuple'
,
'list'
,
'type'
,
'bool'
,
'long'
,
'float'
,
'bytes'
,
'unicode'
,
'tuple'
,
'list'
,
'dict'
,
'
file'
,
'
set'
,
'frozenset'
'dict'
,
'set'
,
'frozenset'
# 'str', # only in Py3.x
# 'str', # only in Py3.x
# 'file', # only in Py2.x
)
)
...
...
Cython/Compiler/Symtab.py
View file @
22111321
...
@@ -772,7 +772,7 @@ class BuiltinScope(Scope):
...
@@ -772,7 +772,7 @@ class BuiltinScope(Scope):
"
frozenset
": ["
((
PyObject
*
)
&
PyFrozenSet_Type
)
", py_object_type],
"
frozenset
": ["
((
PyObject
*
)
&
PyFrozenSet_Type
)
", py_object_type],
"
slice
": ["
((
PyObject
*
)
&
PySlice_Type
)
", py_object_type],
"
slice
": ["
((
PyObject
*
)
&
PySlice_Type
)
", py_object_type],
"
file
": ["
((
PyObject
*
)
&
PyFile_Type
)
", py_object_type],
# "
file
": ["
((
PyObject
*
)
&
PyFile_Type
)
", py_object_type], # not in Py3
"
None
": ["
Py_None
", py_object_type],
"
None
": ["
Py_None
", py_object_type],
"
False
": ["
Py_False
", py_object_type],
"
False
": ["
Py_False
", py_object_type],
...
...
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