Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
c4675e5e
Commit
c4675e5e
authored
Jun 14, 2012
by
Ian Lance Taylor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
compiler: Avoid unnecessary interface conversions.
From-SVN: r188545
parent
f7a70512
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
gcc/go/gofrontend/expressions.cc
+4
-2
No files found.
gcc/go/gofrontend/expressions.cc
View file @
c4675e5e
...
...
@@ -168,7 +168,8 @@ Expression::convert_for_assignment(Translate_context* context, Type* lhs_type,
if
(
lhs_type_tree
==
error_mark_node
)
return
error_mark_node
;
if
(
lhs_type
!=
rhs_type
&&
lhs_type
->
interface_type
()
!=
NULL
)
if
(
lhs_type
->
forwarded
()
!=
rhs_type
->
forwarded
()
&&
lhs_type
->
interface_type
()
!=
NULL
)
{
if
(
rhs_type
->
interface_type
()
==
NULL
)
return
Expression
::
convert_type_to_interface
(
context
,
lhs_type
,
...
...
@@ -179,7 +180,8 @@ Expression::convert_for_assignment(Translate_context* context, Type* lhs_type,
rhs_type
,
rhs_tree
,
false
,
location
);
}
else
if
(
lhs_type
!=
rhs_type
&&
rhs_type
->
interface_type
()
!=
NULL
)
else
if
(
lhs_type
->
forwarded
()
!=
rhs_type
->
forwarded
()
&&
rhs_type
->
interface_type
()
!=
NULL
)
return
Expression
::
convert_interface_to_type
(
context
,
lhs_type
,
rhs_type
,
rhs_tree
,
location
);
else
if
(
lhs_type
->
is_slice_type
()
&&
rhs_type
->
is_nil_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