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
ae10b574
Commit
ae10b574
authored
May 15, 2012
by
Ian Lance Taylor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
compiler: Don't try to take the address of a constant.
From-SVN: r187553
parent
f2437399
Hide 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 @
ae10b574
...
@@ -4044,7 +4044,7 @@ Unary_expression::do_get_tree(Translate_context* context)
...
@@ -4044,7 +4044,7 @@ Unary_expression::do_get_tree(Translate_context* context)
if
(
this
->
create_temp_
if
(
this
->
create_temp_
&&
!
TREE_ADDRESSABLE
(
TREE_TYPE
(
expr
))
&&
!
TREE_ADDRESSABLE
(
TREE_TYPE
(
expr
))
&&
!
DECL_P
(
expr
)
&&
(
TREE_CODE
(
expr
)
==
CONST_DECL
||
!
DECL_P
(
expr
)
)
&&
TREE_CODE
(
expr
)
!=
INDIRECT_REF
&&
TREE_CODE
(
expr
)
!=
INDIRECT_REF
&&
TREE_CODE
(
expr
)
!=
COMPONENT_REF
)
&&
TREE_CODE
(
expr
)
!=
COMPONENT_REF
)
{
{
...
@@ -6194,7 +6194,9 @@ Expression::comparison_tree(Translate_context* context, Operator op,
...
@@ -6194,7 +6194,9 @@ Expression::comparison_tree(Translate_context* context, Operator op,
make_tmp
=
NULL_TREE
;
make_tmp
=
NULL_TREE
;
arg
=
right_tree
;
arg
=
right_tree
;
}
}
else
if
(
TREE_ADDRESSABLE
(
TREE_TYPE
(
right_tree
))
||
DECL_P
(
right_tree
))
else
if
(
TREE_ADDRESSABLE
(
TREE_TYPE
(
right_tree
))
||
(
TREE_CODE
(
right_tree
)
!=
CONST_DECL
&&
DECL_P
(
right_tree
)))
{
{
make_tmp
=
NULL_TREE
;
make_tmp
=
NULL_TREE
;
arg
=
build_fold_addr_expr_loc
(
location
.
gcc_location
(),
right_tree
);
arg
=
build_fold_addr_expr_loc
(
location
.
gcc_location
(),
right_tree
);
...
...
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