[PATCH][RFC] Replace assignment in gcc_assert with comparison

Simon Baldwin simonb@google.com
Thu Jun 7 23:02:00 GMT 2007


Replaced erroneous '=' assignment in gcc_assert() with '==' comparison.

Regression tested on i386 against the full testsuite for default languages.


gcc/ChangeLog
2007-06-07  Simon Baldwin  <simonb@google.com>

	* tree-flow-inline.h (var_ann): Replaced erroneous '=' assignment
	in gcc_assert() with '==' comparison.


diff -Nrcp3 orig/gcc/gcc/tree-flow-inline.h gcc/gcc/tree-flow-inline.h
*** orig/gcc/gcc/tree-flow-inline.h	Mon Jun  4 09:49:07 2007
--- gcc/gcc/tree-flow-inline.h	Thu Jun  7 13:24:31 2007
*************** var_ann (tree t)
*** 210,216 ****
  	   htab_find_with_hash (gimple_var_anns (cfun), t, DECL_UID (t)));
        if (!sann)
  	return NULL;
!       gcc_assert (sann->ann.common.type = VAR_ANN);
        return &sann->ann;
      }
    gcc_assert (!t->base.ann
--- 210,216 ----
  	   htab_find_with_hash (gimple_var_anns (cfun), t, DECL_UID (t)));
        if (!sann)
  	return NULL;
!       gcc_assert (sann->ann.common.type == VAR_ANN);
        return &sann->ann;
      }
    gcc_assert (!t->base.ann



More information about the Gcc-patches mailing list