FreeBSD/contrib/gcc/cp/class.c
/* Dump the offsets of all the bases rooted at BINFO to STREAM.
   INDENT should be zero when called from the top level; it is
   incremented recursively.  IGO indicates the next expected BINFO in
   inheritance graph ordering.  */
Dump the offsets of all the bases rooted at BINFO to STREAM.
INDENT should be zero when called from the top level; it is
incremented recursively.  IGO indicates the next expected BINFO in
inheritance graph ordering.
Dump the offsets of all the bases rooted at BINFO to STREAM . INDENT should be zero when called from the top level ; it is incremented recursively . IGO indicates the next expected BINFO in inheritance graph ordering .
static tree
dump_class_hierarchy_r (FILE *stream,
			int flags,
			tree binfo,
			tree igo,
			int indent)
{
  int indented = 0;
  tree base_binfo;
  int i;
  indented = maybe_indent_hierarchy (stream, indent, 0);
  fprintf (stream, "%s (0x%lx) ",
	   type_as_string (BINFO_TYPE (binfo), TFF_PLAIN_IDENTIFIER),
	   (unsigned long) binfo);
  if (binfo != igo)
    {
      fprintf (stream, "alternative-path\n");
      return igo;
    }
  igo = TREE_CHAIN (binfo);
  fprintf (stream, HOST_WIDE_INT_PRINT_DEC,
	   tree_low_cst (BINFO_OFFSET (binfo), 0));
  if (is_empty_class (BINFO_TYPE (binfo)))
    fprintf (stream, " empty");
  else if (CLASSTYPE_NEARLY_EMPTY_P (BINFO_TYPE (binfo)))
    fprintf (stream, " nearly-empty");
  if (BINFO_VIRTUAL_P (binfo))
    fprintf (stream, " virtual");
  fprintf (stream, "\n");
  indented = 0;
  if (BINFO_PRIMARY_P (binfo))
    {
      indented = maybe_indent_hierarchy (stream, indent + 3, indented);
      fprintf (stream, " primary-for %s (0x%lx)",
	       type_as_string (BINFO_TYPE (BINFO_INHERITANCE_CHAIN (binfo)),
			       TFF_PLAIN_IDENTIFIER),
	       (unsigned long)BINFO_INHERITANCE_CHAIN (binfo));
    }
  if (BINFO_LOST_PRIMARY_P (binfo))
    {
      indented = maybe_indent_hierarchy (stream, indent + 3, indented);
      fprintf (stream, " lost-primary");
    }
  if (indented)
    fprintf (stream, "\n");
  if (!(flags & TDF_SLIM))
    {
      int indented = 0;
      if (BINFO_SUBVTT_INDEX (binfo))
	{
	  indented = maybe_indent_hierarchy (stream, indent + 3, indented);
	  fprintf (stream, " subvttidx=%s",
		   expr_as_string (BINFO_SUBVTT_INDEX (binfo),
				   TFF_PLAIN_IDENTIFIER));
	}
      if (BINFO_VPTR_INDEX (binfo))
	{
	  indented = maybe_indent_hierarchy (stream, indent + 3, indented);
	  fprintf (stream, " vptridx=%s",
		   expr_as_string (BINFO_VPTR_INDEX (binfo),
				   TFF_PLAIN_IDENTIFIER));
	}
      if (BINFO_VPTR_FIELD (binfo))
	{
	  indented = maybe_indent_hierarchy (stream, indent + 3, indented);
	  fprintf (stream, " vbaseoffset=%s",
		   expr_as_string (BINFO_VPTR_FIELD (binfo),
				   TFF_PLAIN_IDENTIFIER));
	}
      if (BINFO_VTABLE (binfo))
	{
	  indented = maybe_indent_hierarchy (stream, indent + 3, indented);
	  fprintf (stream, " vptr=%s",
		   expr_as_string (BINFO_VTABLE (binfo),
				   TFF_PLAIN_IDENTIFIER));
	}
      if (indented)
	fprintf (stream, "\n");
    }
  for (i = 0; BINFO_BASE_ITERATE (binfo, i, base_binfo); i++)
    igo = dump_class_hierarchy_r (stream, flags, base_binfo, igo, indent + 2);
  return igo;
}
static tree dump_class_hierarchy_r ( FILE * stream , int flags , tree binfo , tree igo , int indent ) { int indented = 0 ; tree base_binfo ; int i ; indented = maybe_indent_hierarchy ( stream , indent , 0 ) ; fprintf ( stream , " " , type_as_string ( BINFO_TYPE ( binfo ) , TFF_PLAIN_IDENTIFIER ) , ( unsigned long ) binfo ) ; if ( binfo != igo ) { fprintf ( stream , " \n " ) ; return igo ; } igo = TREE_CHAIN ( binfo ) ; fprintf ( stream , HOST_WIDE_INT_PRINT_DEC , tree_low_cst ( BINFO_OFFSET ( binfo ) , 0 ) ) ; if ( is_empty_class ( BINFO_TYPE ( binfo ) ) ) fprintf ( stream , " " ) ; else if ( CLASSTYPE_NEARLY_EMPTY_P ( BINFO_TYPE ( binfo ) ) ) fprintf ( stream , " " ) ; if ( BINFO_VIRTUAL_P ( binfo ) ) fprintf ( stream , " " ) ; fprintf ( stream , " \n " ) ; indented = 0 ; if ( BINFO_PRIMARY_P ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " , type_as_string ( BINFO_TYPE ( BINFO_INHERITANCE_CHAIN ( binfo ) ) , TFF_PLAIN_IDENTIFIER ) , ( unsigned long ) BINFO_INHERITANCE_CHAIN ( binfo ) ) ; } if ( BINFO_LOST_PRIMARY_P ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " ) ; } if ( indented ) fprintf ( stream , " \n " ) ; if ( ! ( flags & TDF_SLIM ) ) { int indented = 0 ; if ( BINFO_SUBVTT_INDEX ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " , expr_as_string ( BINFO_SUBVTT_INDEX ( binfo ) , TFF_PLAIN_IDENTIFIER ) ) ; } if ( BINFO_VPTR_INDEX ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " , expr_as_string ( BINFO_VPTR_INDEX ( binfo ) , TFF_PLAIN_IDENTIFIER ) ) ; } if ( BINFO_VPTR_FIELD ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " , expr_as_string ( BINFO_VPTR_FIELD ( binfo ) , TFF_PLAIN_IDENTIFIER ) ) ; } if ( BINFO_VTABLE ( binfo ) ) { indented = maybe_indent_hierarchy ( stream , indent + 3 , indented ) ; fprintf ( stream , " " , expr_as_string ( BINFO_VTABLE ( binfo ) , TFF_PLAIN_IDENTIFIER ) ) ; } if ( indented ) fprintf ( stream , " \n " ) ; } for ( i = 0 ; BINFO_BASE_ITERATE ( binfo , i , base_binfo ) ; i ++ ) igo = dump_class_hierarchy_r ( stream , flags , base_binfo , igo , indent + 2 ) ; return igo ; }
Dump the offsets of all the bases rooted at BINFO to STREAM.
Dump the offsets of all the bases rooted at BINFO to STREAM .