http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55874

--- Comment #2 from Manuel López-Ibáñez <manu at gcc dot gnu.org> 2013-01-04 
12:46:17 UTC ---

> Not sure if we want to warn about the other location (or how well that
> would play out).

I think we definitely want to warn about the location of the operator that
triggers the warning, not about the statement at all. If that location is
available, we should *always* use it. Would it be also available if there is no
PHI node here (that is if r was completely replaced by res)?

Like in:

{
  int res, r = 0;
  r = res;
  return r;
}

Reply via email to