PR c++/49418
* typeck2.c (build_functional_cast): Strip cv-quals for value init.
* init.c (build_zero_init_1): Not here.
From-SVN: r175368
2011-06-23 Jason Merrill <jason@redhat.com>
+ PR c++/49519
+ * typeck2.c (build_functional_cast): Strip cv-quals for value init.
+ * init.c (build_zero_init_1): Not here.
+
PR c++/35255
* pt.c (resolve_overloaded_unification): Fix DR 115 handling.
initialized are initialized to zero. */
;
else if (SCALAR_TYPE_P (type))
- init = convert (cv_unqualified (type), integer_zero_node);
+ init = convert (type, integer_zero_node);
else if (CLASS_TYPE_P (type))
{
tree field;
{
if (VOID_TYPE_P (type))
return void_zero_node;
- return build_value_init (type, complain);
+ return build_value_init (cv_unqualified (type), complain);
}
/* This must build a C cast. */