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
Kirill Smelkov
cython
Commits
452c6516
Commit
452c6516
authored
Nov 18, 2012
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use type.as_argument_type() when adapting temp types, include C function types in special cases
parent
c3c2401c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+1
-1
Cython/Compiler/PyrexTypes.py
Cython/Compiler/PyrexTypes.py
+4
-1
No files found.
Cython/Compiler/ExprNodes.py
View file @
452c6516
...
@@ -9705,7 +9705,7 @@ class CoerceToTempNode(CoercionNode):
...
@@ -9705,7 +9705,7 @@ class CoerceToTempNode(CoercionNode):
def
__init__
(
self
,
arg
,
env
):
def
__init__
(
self
,
arg
,
env
):
CoercionNode
.
__init__
(
self
,
arg
)
CoercionNode
.
__init__
(
self
,
arg
)
self
.
type
=
self
.
arg
.
type
self
.
type
=
self
.
arg
.
type
.
as_argument_type
()
self
.
constant_result
=
self
.
arg
.
constant_result
self
.
constant_result
=
self
.
arg
.
constant_result
self
.
is_temp
=
1
self
.
is_temp
=
1
if
self
.
type
.
is_pyobject
:
if
self
.
type
.
is_pyobject
:
...
...
Cython/Compiler/PyrexTypes.py
View file @
452c6516
...
@@ -175,7 +175,7 @@ class PyrexType(BaseType):
...
@@ -175,7 +175,7 @@ class PyrexType(BaseType):
# as other_type.
# as other_type.
#
#
# as_argument_type():
# as_argument_type():
# Coerces array
type
into pointer type for use as
# Coerces array
and C function types
into pointer type for use as
# a formal argument type.
# a formal argument type.
#
#
...
@@ -2520,6 +2520,9 @@ class CFuncType(CType):
...
@@ -2520,6 +2520,9 @@ class CFuncType(CType):
else
:
else
:
return
""
return
""
def
as_argument_type
(
self
):
return
c_ptr_type
(
self
)
def
same_c_signature_as
(
self
,
other_type
,
as_cmethod
=
0
):
def
same_c_signature_as
(
self
,
other_type
,
as_cmethod
=
0
):
return
self
.
same_c_signature_as_resolved_type
(
return
self
.
same_c_signature_as_resolved_type
(
other_type
.
resolve
(),
as_cmethod
)
other_type
.
resolve
(),
as_cmethod
)
...
...
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