diff options
author | Jason Merrill <jason@redhat.com> | 2012-03-03 19:55:44 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2012-03-03 19:55:44 -0500 |
commit | 743af85b75560f64ae14845f3889b7b18cba22a7 (patch) | |
tree | 8f22a14efe384a57398c117ace7f9749ab014175 /gcc/cp/call.c | |
parent | dd94dde78316a27e0028759abbca126fb0fd037f (diff) | |
download | gcc-743af85b75560f64ae14845f3889b7b18cba22a7.zip gcc-743af85b75560f64ae14845f3889b7b18cba22a7.tar.gz gcc-743af85b75560f64ae14845f3889b7b18cba22a7.tar.bz2 |
Core 1270
Core 1270
* call.c (build_aggr_conv): Call reshape_init.
(convert_like_real): Likewise.
* typeck2.c (process_init_constructor): Clear TREE_CONSTANT if
not all constant.
From-SVN: r184876
Diffstat (limited to 'gcc/cp/call.c')
-rw-r--r-- | gcc/cp/call.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/cp/call.c b/gcc/cp/call.c index c962ca0..8baad82 100644 --- a/gcc/cp/call.c +++ b/gcc/cp/call.c @@ -886,6 +886,10 @@ build_aggr_conv (tree type, tree ctor, int flags) tree field = next_initializable_field (TYPE_FIELDS (type)); tree empty_ctor = NULL_TREE; + ctor = reshape_init (type, ctor, tf_none); + if (ctor == error_mark_node) + return NULL; + for (; field; field = next_initializable_field (DECL_CHAIN (field))) { tree ftype = TREE_TYPE (field); @@ -5795,6 +5799,7 @@ convert_like_real (conversion *convs, tree expr, tree fn, int argnum, expr = build2 (COMPLEX_EXPR, totype, real, imag); return fold_if_not_in_template (expr); } + expr = reshape_init (totype, expr, complain); return get_target_expr (digest_init (totype, expr, complain)); default: |