/* Binary relations.
- Copyright (C) 2002 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2004 Free Software Foundation, Inc.
This file is part of Bison, the GNU Compiler Compiler.
void
relation_print (relation r, size_t size, FILE *out)
{
- unsigned i, j;
+ unsigned int i;
+ unsigned int j;
for (i = 0; i < size; ++i)
{
void
relation_digraph (relation r, size_t size, bitsetv *function)
{
- unsigned i;
+ unsigned int i;
infinity = size + 2;
- INDEX = XCALLOC (relation_node, size + 1);
- VERTICES = XCALLOC (relation_node, size + 1);
+ CALLOC (INDEX, size + 1);
+ CALLOC (VERTICES, size + 1);
top = 0;
R = r;
relation_transpose (relation *R_arg, int n)
{
/* The result. */
- relation new_R = XCALLOC (relation_nodes, n);
+ relation new_R = CALLOC (new_R, n);
/* END_R[I] -- next entry of NEW_R[I]. */
- relation end_R = XCALLOC (relation_nodes, n);
+ relation end_R = CALLOC (end_R, n);
/* NEDGES[I] -- total size of NEW_R[I]. */
- int *nedges = XCALLOC (int, n);
+ int *nedges = CALLOC (nedges, n);
int i, j;
if (trace_flag & trace_sets)
for (i = 0; i < n; i++)
if (nedges[i] > 0)
{
- relation_node *sp = XCALLOC (relation_node, nedges[i] + 1);
+ relation_node *sp = CALLOC (sp, nedges[i] + 1);
sp[nedges[i]] = -1;
new_R[i] = sp;
end_R[i] = sp;