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
61ce9ded
Commit
61ce9ded
authored
Oct 15, 2009
by
Dag Sverre Seljebotn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove use of TempNode in FromImportStatNode
parent
f6d0993b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
Cython/Compiler/Nodes.py
Cython/Compiler/Nodes.py
+8
-8
No files found.
Cython/Compiler/Nodes.py
View file @
61ce9ded
...
@@ -4677,7 +4677,7 @@ class FromImportStatNode(StatNode):
...
@@ -4677,7 +4677,7 @@ class FromImportStatNode(StatNode):
def
analyse_expressions
(
self
,
env
):
def
analyse_expressions
(
self
,
env
):
import
ExprNodes
import
ExprNodes
self
.
module
.
analyse_expressions
(
env
)
self
.
module
.
analyse_expressions
(
env
)
self
.
item
=
ExprNodes
.
PyTempNode
(
self
.
pos
,
env
)
self
.
item
=
ExprNodes
.
RawCNameExprNode
(
self
.
pos
,
py_object_type
)
self
.
interned_items
=
[]
self
.
interned_items
=
[]
for
name
,
target
in
self
.
items
:
for
name
,
target
in
self
.
items
:
if
name
==
'*'
:
if
name
==
'*'
:
...
@@ -4705,25 +4705,25 @@ class FromImportStatNode(StatNode):
...
@@ -4705,25 +4705,25 @@ class FromImportStatNode(StatNode):
Naming
.
import_star
,
Naming
.
import_star
,
self
.
module
.
py_result
(),
self
.
module
.
py_result
(),
code
.
error_goto
(
self
.
pos
)))
code
.
error_goto
(
self
.
pos
)))
self
.
item
.
allocate
(
code
)
item_temp
=
code
.
funcstate
.
allocate_temp
(
py_object_type
,
manage_ref
=
True
)
self
.
item
.
set_cname
(
item_temp
)
for
name
,
target
,
coerced_item
in
self
.
interned_items
:
for
name
,
target
,
coerced_item
in
self
.
interned_items
:
cname
=
code
.
intern_identifier
(
name
)
cname
=
code
.
intern_identifier
(
name
)
code
.
putln
(
code
.
putln
(
'%s = PyObject_GetAttr(%s, %s); %s'
%
(
'%s = PyObject_GetAttr(%s, %s); %s'
%
(
self
.
item
.
result
(),
item_temp
,
self
.
module
.
py_result
(),
self
.
module
.
py_result
(),
cname
,
cname
,
code
.
error_goto_if_null
(
self
.
item
.
result
()
,
self
.
pos
)))
code
.
error_goto_if_null
(
item_temp
,
self
.
pos
)))
code
.
put_gotref
(
self
.
item
.
py_result
()
)
code
.
put_gotref
(
item_temp
)
if
coerced_item
is
None
:
if
coerced_item
is
None
:
target
.
generate_assignment_code
(
self
.
item
,
code
)
target
.
generate_assignment_code
(
self
.
item
,
code
)
else
:
else
:
coerced_item
.
allocate_temp_result
(
code
)
coerced_item
.
allocate_temp_result
(
code
)
coerced_item
.
generate_result_code
(
code
)
coerced_item
.
generate_result_code
(
code
)
target
.
generate_assignment_code
(
coerced_item
,
code
)
target
.
generate_assignment_code
(
coerced_item
,
code
)
if
self
.
item
.
result
()
!=
coerced_item
.
result
():
code
.
put_decref_clear
(
item_temp
,
py_object_type
)
code
.
put_decref_clear
(
self
.
item
.
result
(),
self
.
item
.
type
)
code
.
funcstate
.
release_temp
(
item_temp
)
self
.
item
.
release
(
code
)
self
.
module
.
generate_disposal_code
(
code
)
self
.
module
.
generate_disposal_code
(
code
)
self
.
module
.
free_temps
(
code
)
self
.
module
.
free_temps
(
code
)
...
...
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