diff options
author | Jason Merrill <jason@redhat.com> | 2016-01-08 11:01:12 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2016-01-08 11:01:12 -0500 |
commit | 451773378f6808ce2b1e1d4eaed40b164ad590da (patch) | |
tree | a6a87fb093cb967de90353ff866ccad75a8602eb /gcc/function.c | |
parent | 0795b6f262e37218e80ee03d9c4c2f63541b149b (diff) | |
download | gcc-451773378f6808ce2b1e1d4eaed40b164ad590da.zip gcc-451773378f6808ce2b1e1d4eaed40b164ad590da.tar.gz gcc-451773378f6808ce2b1e1d4eaed40b164ad590da.tar.bz2 |
PR c++/68983 (BE)
PR c++/67557
gcc/
* function.c (assign_temp): Guard against TREE_ADDRESSABLE types here.
* expr.c (store_field): Not here.
* tree-cfgcleanup.c (fixup_noreturn_call): Don't clear LHS of a
call with TREE_ADDRESSABLE type.
* tree-cfg.c (verify_gimple_call): Adjust.
gcc/cp/
* cvt.c (convert_to_void): Don't strip a TARGET_EXPR of
TREE_ADDRESSABLE type.
From-SVN: r232167
Diffstat (limited to 'gcc/function.c')
-rw-r--r-- | gcc/function.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/function.c b/gcc/function.c index 603ea80..1ac8e26 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -956,6 +956,10 @@ assign_temp (tree type_or_decl, int memory_required, unsignedp = TYPE_UNSIGNED (type); #endif + /* Allocating temporaries of TREE_ADDRESSABLE type must be done in the front + end. See also create_tmp_var for the gimplification-time check. */ + gcc_assert (!TREE_ADDRESSABLE (type) && COMPLETE_TYPE_P (type)); + if (mode == BLKmode || memory_required) { HOST_WIDE_INT size = int_size_in_bytes (type); |