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
96e2964e
Commit
96e2964e
authored
Jul 02, 2009
by
Danilo Freitas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new operator
parent
f54ccdb2
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
35 deletions
+1
-35
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+1
-11
Cython/Compiler/PyrexTypes.py
Cython/Compiler/PyrexTypes.py
+0
-24
No files found.
Cython/Compiler/ExprNodes.py
100644 → 100755
View file @
96e2964e
...
@@ -2377,16 +2377,6 @@ class SimpleCallNode(CallNode):
...
@@ -2377,16 +2377,6 @@ class SimpleCallNode(CallNode):
self
.
type
=
py_object_type
self
.
type
=
py_object_type
self
.
gil_check
(
env
)
self
.
gil_check
(
env
)
self
.
is_temp
=
1
self
.
is_temp
=
1
if
func_type
.
is_cpp_class
:
for
arg
in
self
.
args
:
arg
.
analyse_types
(
env
)
entry
=
env
.
lookup
(
self
.
function
.
cppclass
)
print
entry
.
name
self
.
type
=
entry
.
type
self
.
function
.
type
=
PyrexTypes
.
CppMethodType
(
self
.
function
.
cppclass
,
PyrexTypes
.
CppClassType
(
self
.
function
.
cppclass
,
"cppclass"
,
entry
.
scope
,
0
,
entry
.
cname
,
[]),
self
.
args
)
self
.
analyse_c_function_call
(
env
)
else
:
else
:
for
arg
in
self
.
args
:
for
arg
in
self
.
args
:
arg
.
analyse_types
(
env
)
arg
.
analyse_types
(
env
)
...
@@ -2410,7 +2400,7 @@ class SimpleCallNode(CallNode):
...
@@ -2410,7 +2400,7 @@ class SimpleCallNode(CallNode):
def
analyse_c_function_call
(
self
,
env
):
def
analyse_c_function_call
(
self
,
env
):
func_type
=
self
.
function_type
()
func_type
=
self
.
function_type
()
# Check function type
# Check function type
if
not
func_type
.
is_cfunction
and
not
func_type
.
is_cpp_method
:
if
not
func_type
.
is_cfunction
:
if
not
func_type
.
is_error
:
if
not
func_type
.
is_error
:
error
(
self
.
pos
,
"Calling non-function type '%s'"
%
error
(
self
.
pos
,
"Calling non-function type '%s'"
%
func_type
)
func_type
)
...
...
Cython/Compiler/PyrexTypes.py
100644 → 100755
View file @
96e2964e
...
@@ -39,7 +39,6 @@ class PyrexType(BaseType):
...
@@ -39,7 +39,6 @@ class PyrexType(BaseType):
# is_ptr boolean Is a C pointer type
# is_ptr boolean Is a C pointer type
# is_null_ptr boolean Is the type of NULL
# is_null_ptr boolean Is the type of NULL
# is_cfunction boolean Is a C function type
# is_cfunction boolean Is a C function type
# is_cpp_method boolean Is a C++ method type
# is_struct_or_union boolean Is a C struct or union type
# is_struct_or_union boolean Is a C struct or union type
# is_struct boolean Is a C struct type
# is_struct boolean Is a C struct type
# is_enum boolean Is a C enum type
# is_enum boolean Is a C enum type
...
@@ -91,7 +90,6 @@ class PyrexType(BaseType):
...
@@ -91,7 +90,6 @@ class PyrexType(BaseType):
is_ptr
=
0
is_ptr
=
0
is_null_ptr
=
0
is_null_ptr
=
0
is_cfunction
=
0
is_cfunction
=
0
is_cpp_method
=
0
is_struct_or_union
=
0
is_struct_or_union
=
0
is_cpp_class
=
0
is_cpp_class
=
0
is_struct
=
0
is_struct
=
0
...
@@ -1230,28 +1228,6 @@ class CFuncType(CType):
...
@@ -1230,28 +1228,6 @@ class CFuncType(CType):
s
=
self
.
declaration_code
(
"(*)"
,
with_calling_convention
=
False
)
s
=
self
.
declaration_code
(
"(*)"
,
with_calling_convention
=
False
)
return
'(%s)'
%
s
return
'(%s)'
%
s
class
CppMethodType
(
CFuncType
):
# return_type CppClassType
is_cpp_method
=
1
def
__init__
(
self
,
class_name
,
return_type
,
args
,
has_varargs
=
0
,
exception_value
=
None
,
exception_check
=
0
,
calling_convention
=
""
,
nogil
=
0
,
with_gil
=
0
,
is_overridable
=
0
,
optional_arg_count
=
0
):
self
.
class_name
=
class_name
self
.
return_type
=
return_type
self
.
args
=
args
self
.
has_varargs
=
has_varargs
self
.
exception_value
=
exception_value
self
.
exception_check
=
exception_check
self
.
calling_convention
=
calling_convention
self
.
nogil
=
nogil
self
.
with_gil
=
with_gil
self
.
is_overridable
=
is_overridable
self
.
optional_arg_count
=
optional_arg_count
class
CFuncTypeArg
(
object
):
class
CFuncTypeArg
(
object
):
# name string
# name string
...
...
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