Commit 4d6503ab by Marc Glisse Committed by Marc Glisse

fold-const.c (fold_unary_loc): Disable conversion optimization for void type.

2012-11-05  Marc Glisse  <marc.glisse@inria.fr>

	* fold-const.c (fold_unary_loc): Disable conversion optimization
	for void type.

From-SVN: r193146
parent 40448151
2012-11-05 Marc Glisse <marc.glisse@inria.fr>
* fold-const.c (fold_unary_loc): Disable conversion optimization
for void type.
2012-11-04 Thomas Schwinge <thomas@codesourcery.com> 2012-11-04 Thomas Schwinge <thomas@codesourcery.com>
* configure: Regenerate. * configure: Regenerate.
...@@ -7749,7 +7749,8 @@ fold_unary_loc (location_t loc, enum tree_code code, tree type, tree op0) ...@@ -7749,7 +7749,8 @@ fold_unary_loc (location_t loc, enum tree_code code, tree type, tree op0)
return build2_loc (loc, TREE_CODE (op0), type, return build2_loc (loc, TREE_CODE (op0), type,
TREE_OPERAND (op0, 0), TREE_OPERAND (op0, 0),
TREE_OPERAND (op0, 1)); TREE_OPERAND (op0, 1));
else if (!INTEGRAL_TYPE_P (type) && TREE_CODE (type) != VECTOR_TYPE) else if (!INTEGRAL_TYPE_P (type) && !VOID_TYPE_P (type)
&& TREE_CODE (type) != VECTOR_TYPE)
return build3_loc (loc, COND_EXPR, type, op0, return build3_loc (loc, COND_EXPR, type, op0,
constant_boolean_node (true, type), constant_boolean_node (true, type),
constant_boolean_node (false, type)); constant_boolean_node (false, type));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment