projects
/
platform
/
upstream
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
302485a
)
fold: fix use of protected_set_expr_location_unshare
author
Jason Merrill
<jason@redhat.com>
Wed, 21 Dec 2022 02:06:09 +0000
(21:06 -0500)
committer
Jason Merrill
<jason@redhat.com>
Wed, 21 Dec 2022 02:07:31 +0000
(21:07 -0500)
Unlike protected_set_expr_location, this variant can return
a different tree.
gcc/ChangeLog:
* fold-const.cc (fold_convert_loc): Check return value of
protected_set_expr_location_unshare.
gcc/fold-const.cc
patch
|
blob
|
history
diff --git
a/gcc/fold-const.cc
b/gcc/fold-const.cc
index
42547f4
..
00e2af0
100644
(file)
--- a/
gcc/fold-const.cc
+++ b/
gcc/fold-const.cc
@@
-2618,7
+2618,7
@@
fold_convert_loc (location_t loc, tree type, tree arg)
gcc_unreachable ();
}
fold_convert_exit:
- protected_set_expr_location_unshare (tem, loc);
+
tem =
protected_set_expr_location_unshare (tem, loc);
return tem;
}
\f