Rainer Orth <r...@cebitec.uni-bielefeld.de> writes: > "Iyer, Balaji V" <balaji.v.i...@intel.com> writes: [...] >> This patch is committed to trunk at revision 199389. > > ... and immediately broke Solaris bootstrap, cf. PR bootstrap/57450.
Fixed implementing Richard's suggestion from the PR. Bootstrapped without regressions on i386-pc-solaris2.10 and x86_64-unknown-linux-gnu, installed as obvious. Rainer 2013-05-29 Rainer Orth <r...@cebitec.uni-bielefeld.de> PR bootstrap/57450 * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi. (build_array_notation_expr): Likewise.
# HG changeset patch # Parent 22d5dfeeb2006caf8be6803106b454a19cfe6513 Fix c/c-array-notation.c compilation failure (PR bootstrap/57450) diff --git a/gcc/c/c-array-notation.c b/gcc/c/c-array-notation.c --- a/gcc/c/c-array-notation.c +++ b/gcc/c/c-array-notation.c @@ -116,7 +116,7 @@ length_mismatch_in_expr_p (location_t lo { l_node = int_cst_value (list[ii][jj]); l_start = int_cst_value (start); - if (abs (l_start) != abs (l_node)) + if (absu_hwi (l_start) != absu_hwi (l_node)) { error_at (loc, "length mismatch in expression"); return true; @@ -1561,7 +1561,7 @@ build_array_notation_expr (location_t lo HOST_WIDE_INT r_length = int_cst_value (rhs_length[0][0]); /* Length can be negative or positive. As long as the magnitude is OK, then the array notation is valid. */ - if (abs (l_length) != abs (r_length)) + if (absu_hwi (l_length) != absu_hwi (r_length)) { error_at (location, "length mismatch between LHS and RHS"); pop_stmt_list (an_init);
-- ----------------------------------------------------------------------------- Rainer Orth, Center for Biotechnology, Bielefeld University