{
fprintf (out, "%3d: ", i);
if (r[i])
- for (j = 0; r[i][j] != -1; ++j)
+ for (j = 0; r[i][j] != END_NODE; ++j)
fprintf (out, "%3d ", r[i][j]);
fputc ('\n', out);
}
INDEX[i] = height = top;
if (R[i])
- for (j = 0; R[i][j] >= 0; ++j)
+ for (j = 0; R[i][j] != END_NODE; ++j)
{
if (INDEX[R[i][j]] == 0)
traverse (R[i][j]);
/* Count. */
for (i = 0; i < n; i++)
if ((*R_arg)[i])
- for (j = 0; (*R_arg)[i][j] >= 0; ++j)
+ for (j = 0; (*R_arg)[i][j] != END_NODE; ++j)
++nedges[(*R_arg)[i][j]];
/* Allocate. */
if (nedges[i] > 0)
{
relation_node *sp = CALLOC (sp, nedges[i] + 1);
- sp[nedges[i]] = -1;
+ sp[nedges[i]] = END_NODE;
new_R[i] = sp;
end_R[i] = sp;
}
/* Store. */
for (i = 0; i < n; i++)
if ((*R_arg)[i])
- for (j = 0; (*R_arg)[i][j] >= 0; ++j)
+ for (j = 0; (*R_arg)[i][j] != END_NODE; ++j)
{
*end_R[(*R_arg)[i][j]] = i;
++end_R[(*R_arg)[i][j]];