TRUTH_OR_EXPR vs. TRUTH_ORIF_EXPR

Morten Welinder terra@diku.dk
Wed Feb 12 18:07:00 GMT 2003


The code
-----------------------------------------------------------------------------
foo (int x, int y)
{
  if (x <= 0 || y <= 0)
    return;

  foo (x + 1, y - 1);
  return;
}
-----------------------------------------------------------------------------

when compiled on sparc-solaris gcc 3.1.1 using -O2 produces a syntax tree
that uses "TRUTH_OR_EXPR" rather than "TRUTH_ORIF_EXPR".  Any idea why?
It feels strange.

In any case, tree-dump.c's dequeue_and_dump does not handle TRUTH_OR_EXPR
right.  Around line 666, cases for TRUTH_AND_EXPR and TRUTH_OR_EXPR need
to be added.

Morten



More information about the Gcc mailing list