Commit 00a17e31 by Kazu Hirata Committed by Kazu Hirata

call.c: Fix comment formatting.

	* call.c: Fix comment formatting.
	* class.c: Likewise.
	* cp-lang.c: Likewise.
	* cp-tree.h: Likewise.
	* cvt.c: Likewise.

From-SVN: r57083
parent 714e9334
2002-09-12 Kazu Hirata <kazu@cs.umass.edu>
* call.c: Fix comment formatting.
* class.c: Likewise.
* cp-lang.c: Likewise.
* cp-tree.h: Likewise.
* cvt.c: Likewise.
2002-09-11 Zack Weinberg <zack@codesourcery.com> 2002-09-11 Zack Weinberg <zack@codesourcery.com>
* Make-lang.in: Build cp/cxxfilt.o from $(srcdir)/cp/cxxfilt.c, * Make-lang.in: Build cp/cxxfilt.o from $(srcdir)/cp/cxxfilt.c,
......
...@@ -648,7 +648,7 @@ null_ptr_cst_p (t) ...@@ -648,7 +648,7 @@ null_ptr_cst_p (t)
/* Returns non-zero if PARMLIST consists of only default parms and/or /* Returns non-zero if PARMLIST consists of only default parms and/or
ellipsis. */ ellipsis. */
int int
sufficient_parms_p (parmlist) sufficient_parms_p (parmlist)
...@@ -2764,7 +2764,7 @@ build_new_function_call (fn, args) ...@@ -2764,7 +2764,7 @@ build_new_function_call (fn, args)
return build_over_call (cand, args, LOOKUP_NORMAL); return build_over_call (cand, args, LOOKUP_NORMAL);
} }
/* This is not really overloaded. */ /* This is not really overloaded. */
fn = OVL_CURRENT (fn); fn = OVL_CURRENT (fn);
return build_function_call (fn, args); return build_function_call (fn, args);
...@@ -3053,7 +3053,7 @@ build_conditional_expr (arg1, arg2, arg3) ...@@ -3053,7 +3053,7 @@ build_conditional_expr (arg1, arg2, arg3)
type of the other and is an rvalue. type of the other and is an rvalue.
--Both the second and the third operands have type void; the --Both the second and the third operands have type void; the
result is of type void and is an rvalue. */ result is of type void and is an rvalue. */
if ((TREE_CODE (arg2) == THROW_EXPR) if ((TREE_CODE (arg2) == THROW_EXPR)
^ (TREE_CODE (arg3) == THROW_EXPR)) ^ (TREE_CODE (arg3) == THROW_EXPR))
result_type = ((TREE_CODE (arg2) == THROW_EXPR) result_type = ((TREE_CODE (arg2) == THROW_EXPR)
...@@ -3275,7 +3275,7 @@ build_conditional_expr (arg1, arg2, arg3) ...@@ -3275,7 +3275,7 @@ build_conditional_expr (arg1, arg2, arg3)
qualification conversions (_conv.qual_) are performed to bring qualification conversions (_conv.qual_) are performed to bring
them to a common type, whose cv-qualification shall match the them to a common type, whose cv-qualification shall match the
cv-qualification of either the second or the third operand. cv-qualification of either the second or the third operand.
The result is of the common type. */ The result is of the common type. */
else if ((null_ptr_cst_p (arg2) else if ((null_ptr_cst_p (arg2)
&& (TYPE_PTR_P (arg3_type) || TYPE_PTRMEM_P (arg3_type) && (TYPE_PTR_P (arg3_type) || TYPE_PTRMEM_P (arg3_type)
|| TYPE_PTRMEMFUNC_P (arg3_type))) || TYPE_PTRMEMFUNC_P (arg3_type)))
...@@ -3360,7 +3360,7 @@ build_new_op (code, flags, arg1, arg2, arg3) ...@@ -3360,7 +3360,7 @@ build_new_op (code, flags, arg1, arg2, arg3)
case VEC_NEW_EXPR: case VEC_NEW_EXPR:
case VEC_DELETE_EXPR: case VEC_DELETE_EXPR:
case DELETE_EXPR: case DELETE_EXPR:
/* Use build_op_new_call and build_op_delete_call instead. */ /* Use build_op_new_call and build_op_delete_call instead. */
abort (); abort ();
case CALL_EXPR: case CALL_EXPR:
...@@ -3458,7 +3458,7 @@ build_new_op (code, flags, arg1, arg2, arg3) ...@@ -3458,7 +3458,7 @@ build_new_op (code, flags, arg1, arg2, arg3)
if (TREE_CODE (fn) == TEMPLATE_DECL) if (TREE_CODE (fn) == TEMPLATE_DECL)
{ {
/* A member template. */ /* A member template. */
templates = tree_cons (NULL_TREE, fn, templates); templates = tree_cons (NULL_TREE, fn, templates);
candidates candidates
= add_template_candidate (candidates, fn, = add_template_candidate (candidates, fn,
...@@ -3752,10 +3752,10 @@ build_op_delete_call (code, addr, size, flags, placement) ...@@ -3752,10 +3752,10 @@ build_op_delete_call (code, addr, size, flags, placement)
tree alloc_fn; tree alloc_fn;
tree call_expr; tree call_expr;
/* Find the allocation function that is being called. */ /* Find the allocation function that is being called. */
call_expr = placement; call_expr = placement;
/* Sometimes we have a COMPOUND_EXPR, rather than a simple /* Sometimes we have a COMPOUND_EXPR, rather than a simple
CALL_EXPR. */ CALL_EXPR. */
while (TREE_CODE (call_expr) == COMPOUND_EXPR) while (TREE_CODE (call_expr) == COMPOUND_EXPR)
call_expr = TREE_OPERAND (call_expr, 1); call_expr = TREE_OPERAND (call_expr, 1);
/* Extract the function. */ /* Extract the function. */
...@@ -3876,7 +3876,7 @@ enforce_access (basetype_path, decl) ...@@ -3876,7 +3876,7 @@ enforce_access (basetype_path, decl)
FN and ARGNUM are used for diagnostics. ARGNUM is zero based, -1 FN and ARGNUM are used for diagnostics. ARGNUM is zero based, -1
indicates the `this' argument of a method. INNER is non-zero when indicates the `this' argument of a method. INNER is non-zero when
being called to continue a conversion chain. It is negative when a being called to continue a conversion chain. It is negative when a
reference binding will be applied, positive otherwise. */ reference binding will be applied, positive otherwise. */
static tree static tree
convert_like_real (convs, expr, fn, argnum, inner) convert_like_real (convs, expr, fn, argnum, inner)
...@@ -4553,11 +4553,11 @@ build_java_interface_fn_ref (fn, instance) ...@@ -4553,11 +4553,11 @@ build_java_interface_fn_ref (fn, instance)
} }
/* Look up the pointer to the runtime java.lang.Class object for `instance'. /* Look up the pointer to the runtime java.lang.Class object for `instance'.
This is the first entry in the vtable. */ This is the first entry in the vtable. */
klass_ref = build_vtbl_ref (build_indirect_ref (instance, 0), klass_ref = build_vtbl_ref (build_indirect_ref (instance, 0),
integer_zero_node); integer_zero_node);
/* Get the java.lang.Class pointer for the interface being called. */ /* Get the java.lang.Class pointer for the interface being called. */
iface = DECL_CONTEXT (fn); iface = DECL_CONTEXT (fn);
iface_ref = lookup_field (iface, get_identifier ("class$"), 0, 0); iface_ref = lookup_field (iface, get_identifier ("class$"), 0, 0);
if (!iface_ref || TREE_CODE (iface_ref) != VAR_DECL if (!iface_ref || TREE_CODE (iface_ref) != VAR_DECL
...@@ -4569,7 +4569,7 @@ build_java_interface_fn_ref (fn, instance) ...@@ -4569,7 +4569,7 @@ build_java_interface_fn_ref (fn, instance)
} }
iface_ref = build1 (ADDR_EXPR, build_pointer_type (iface), iface_ref); iface_ref = build1 (ADDR_EXPR, build_pointer_type (iface), iface_ref);
/* Determine the itable index of FN. */ /* Determine the itable index of FN. */
i = 1; i = 1;
for (method = TYPE_METHODS (iface); method; method = TREE_CHAIN (method)) for (method = TYPE_METHODS (iface); method; method = TREE_CHAIN (method))
{ {
...@@ -4814,7 +4814,7 @@ build_new_method_call (tree instance, tree fns, tree args, ...@@ -4814,7 +4814,7 @@ build_new_method_call (tree instance, tree fns, tree args,
if (TREE_CODE (t) == TEMPLATE_DECL) if (TREE_CODE (t) == TEMPLATE_DECL)
{ {
/* A member template. */ /* A member template. */
templates = tree_cons (NULL_TREE, t, templates); templates = tree_cons (NULL_TREE, t, templates);
candidates = candidates =
add_template_candidate (candidates, t, add_template_candidate (candidates, t,
......
...@@ -828,7 +828,7 @@ add_method (type, method, error_p) ...@@ -828,7 +828,7 @@ add_method (type, method, error_p)
&& DECL_TEMPLATE_CONV_FN_P (m)); && DECL_TEMPLATE_CONV_FN_P (m));
/* If we need to move things up, see if there's /* If we need to move things up, see if there's
space. */ space. */
if (!have_template_convs_p) if (!have_template_convs_p)
{ {
slot = len - 1; slot = len - 1;
...@@ -1181,7 +1181,7 @@ handle_using_decl (using_decl, t) ...@@ -1181,7 +1181,7 @@ handle_using_decl (using_decl, t)
} }
if (BASELINK_P (fdecl)) if (BASELINK_P (fdecl))
/* Ignore base type this came from. */ /* Ignore base type this came from. */
fdecl = BASELINK_FUNCTIONS (fdecl); fdecl = BASELINK_FUNCTIONS (fdecl);
old_value = IDENTIFIER_CLASS_VALUE (name); old_value = IDENTIFIER_CLASS_VALUE (name);
...@@ -1314,7 +1314,7 @@ check_bases (t, cant_have_default_ctor_p, cant_have_const_ctor_p, ...@@ -1314,7 +1314,7 @@ check_bases (t, cant_have_default_ctor_p, cant_have_const_ctor_p,
} }
if (TREE_VIA_VIRTUAL (base_binfo)) if (TREE_VIA_VIRTUAL (base_binfo))
/* A virtual base does not effect nearly emptiness. */ /* A virtual base does not effect nearly emptiness. */
; ;
else if (CLASSTYPE_NEARLY_EMPTY_P (basetype)) else if (CLASSTYPE_NEARLY_EMPTY_P (basetype))
{ {
...@@ -1323,7 +1323,7 @@ check_bases (t, cant_have_default_ctor_p, cant_have_const_ctor_p, ...@@ -1323,7 +1323,7 @@ check_bases (t, cant_have_default_ctor_p, cant_have_const_ctor_p,
derived class is not nearly empty either. */ derived class is not nearly empty either. */
CLASSTYPE_NEARLY_EMPTY_P (t) = 0; CLASSTYPE_NEARLY_EMPTY_P (t) = 0;
else else
/* Remember we've seen one. */ /* Remember we've seen one. */
seen_non_virtual_nearly_empty_base_p = 1; seen_non_virtual_nearly_empty_base_p = 1;
} }
else if (!is_empty_class (basetype)) else if (!is_empty_class (basetype))
...@@ -1470,7 +1470,7 @@ mark_primary_virtual_base (base_binfo, type) ...@@ -1470,7 +1470,7 @@ mark_primary_virtual_base (base_binfo, type)
/* If BINFO is an unmarked virtual binfo for a class with a primary virtual /* If BINFO is an unmarked virtual binfo for a class with a primary virtual
base, then BINFO has no primary base in this graph. Called from base, then BINFO has no primary base in this graph. Called from
mark_primary_bases. DATA is the most derived type. */ mark_primary_bases. DATA is the most derived type. */
static tree dfs_unshared_virtual_bases (binfo, data) static tree dfs_unshared_virtual_bases (binfo, data)
tree binfo; tree binfo;
...@@ -1503,11 +1503,11 @@ static tree dfs_unshared_virtual_bases (binfo, data) ...@@ -1503,11 +1503,11 @@ static tree dfs_unshared_virtual_bases (binfo, data)
if (binfo != TYPE_BINFO (t)) if (binfo != TYPE_BINFO (t))
/* The vtable fields will have been copied when duplicating the /* The vtable fields will have been copied when duplicating the
base binfos. That information is bogus, make sure we don't try base binfos. That information is bogus, make sure we don't try
and use it. */ and use it. */
BINFO_VTABLE (binfo) = NULL_TREE; BINFO_VTABLE (binfo) = NULL_TREE;
/* If this is a virtual primary base, make sure its offset matches /* If this is a virtual primary base, make sure its offset matches
that which it is primary for. */ that which it is primary for. */
if (BINFO_PRIMARY_P (binfo) && TREE_VIA_VIRTUAL (binfo) && if (BINFO_PRIMARY_P (binfo) && TREE_VIA_VIRTUAL (binfo) &&
binfo_for_vbase (BINFO_TYPE (binfo), t) == binfo) binfo_for_vbase (BINFO_TYPE (binfo), t) == binfo)
{ {
...@@ -1536,7 +1536,7 @@ mark_primary_bases (type) ...@@ -1536,7 +1536,7 @@ mark_primary_bases (type)
tree base_binfo; tree base_binfo;
if (!CLASSTYPE_HAS_PRIMARY_BASE_P (BINFO_TYPE (binfo))) if (!CLASSTYPE_HAS_PRIMARY_BASE_P (BINFO_TYPE (binfo)))
/* Not a dynamic base. */ /* Not a dynamic base. */
continue; continue;
base_binfo = get_primary_binfo (binfo); base_binfo = get_primary_binfo (binfo);
...@@ -2253,7 +2253,7 @@ dfs_find_final_overrider (binfo, data) ...@@ -2253,7 +2253,7 @@ dfs_find_final_overrider (binfo, data)
/* Assume the path is non-virtual. See if there are any /* Assume the path is non-virtual. See if there are any
virtual bases from (but not including) the overrider up virtual bases from (but not including) the overrider up
to and including the base where the function is to and including the base where the function is
defined. */ defined. */
for (base = TREE_CHAIN (path); base; base = TREE_CHAIN (base)) for (base = TREE_CHAIN (path); base; base = TREE_CHAIN (base))
if (TREE_VIA_VIRTUAL (TREE_VALUE (base))) if (TREE_VIA_VIRTUAL (TREE_VALUE (base)))
{ {
...@@ -2756,11 +2756,11 @@ warn_hidden (t) ...@@ -2756,11 +2756,11 @@ warn_hidden (t)
base_fndecls); base_fndecls);
} }
/* If there are no functions to hide, continue. */ /* If there are no functions to hide, continue. */
if (!base_fndecls) if (!base_fndecls)
continue; continue;
/* Remove any overridden functions. */ /* Remove any overridden functions. */
for (fns = TREE_VEC_ELT (method_vec, i); fns; fns = OVL_NEXT (fns)) for (fns = TREE_VEC_ELT (method_vec, i); fns; fns = OVL_NEXT (fns))
{ {
fndecl = OVL_CURRENT (fns); fndecl = OVL_CURRENT (fns);
...@@ -3708,7 +3708,7 @@ layout_nonempty_base_or_field (rli, decl, binfo, offsets, t) ...@@ -3708,7 +3708,7 @@ layout_nonempty_base_or_field (rli, decl, binfo, offsets, t)
past the end of the class, and should be correctly aligned for a past the end of the class, and should be correctly aligned for a
class of the type indicated by BINFO; OFFSETS gives the offsets of class of the type indicated by BINFO; OFFSETS gives the offsets of
the empty bases allocated so far. T is the most derived the empty bases allocated so far. T is the most derived
type. Return non-zero iff we added it at the end. */ type. Return non-zero iff we added it at the end. */
static bool static bool
layout_empty_base (binfo, eoc, offsets, t) layout_empty_base (binfo, eoc, offsets, t)
...@@ -3757,7 +3757,7 @@ layout_empty_base (binfo, eoc, offsets, t) ...@@ -3757,7 +3757,7 @@ layout_empty_base (binfo, eoc, offsets, t)
*BASE_ALIGN is a running maximum of the alignments of any base *BASE_ALIGN is a running maximum of the alignments of any base
class. OFFSETS gives the location of empty base subobjects. T is class. OFFSETS gives the location of empty base subobjects. T is
the most derived type. Return non-zero if the new object cannot be the most derived type. Return non-zero if the new object cannot be
nearly-empty. */ nearly-empty. */
static bool static bool
build_base_field (rli, binfo, empty_p, offsets, t) build_base_field (rli, binfo, empty_p, offsets, t)
...@@ -4080,7 +4080,7 @@ clone_function_decl (fn, update_method_vec_p) ...@@ -4080,7 +4080,7 @@ clone_function_decl (fn, update_method_vec_p)
declared. An out-of-class definition can specify additional default declared. An out-of-class definition can specify additional default
arguments. As it is the clones that are involved in overload arguments. As it is the clones that are involved in overload
resolution, we must propagate the information from the DECL to its resolution, we must propagate the information from the DECL to its
clones. */ clones. */
void void
adjust_clone_args (decl) adjust_clone_args (decl)
...@@ -4097,7 +4097,7 @@ adjust_clone_args (decl) ...@@ -4097,7 +4097,7 @@ adjust_clone_args (decl)
clone_parms = orig_clone_parms; clone_parms = orig_clone_parms;
/* Skip the 'this' parameter. */ /* Skip the 'this' parameter. */
orig_clone_parms = TREE_CHAIN (orig_clone_parms); orig_clone_parms = TREE_CHAIN (orig_clone_parms);
orig_decl_parms = TREE_CHAIN (orig_decl_parms); orig_decl_parms = TREE_CHAIN (orig_decl_parms);
...@@ -4120,7 +4120,7 @@ adjust_clone_args (decl) ...@@ -4120,7 +4120,7 @@ adjust_clone_args (decl)
if (TREE_PURPOSE (decl_parms) && !TREE_PURPOSE (clone_parms)) if (TREE_PURPOSE (decl_parms) && !TREE_PURPOSE (clone_parms))
{ {
/* A default parameter has been added. Adjust the /* A default parameter has been added. Adjust the
clone's parameters. */ clone's parameters. */
tree exceptions = TYPE_RAISES_EXCEPTIONS (TREE_TYPE (clone)); tree exceptions = TYPE_RAISES_EXCEPTIONS (TREE_TYPE (clone));
tree basetype = TYPE_METHOD_BASETYPE (TREE_TYPE (clone)); tree basetype = TYPE_METHOD_BASETYPE (TREE_TYPE (clone));
tree type; tree type;
...@@ -4274,7 +4274,7 @@ check_bases_and_members (t, empty_p) ...@@ -4274,7 +4274,7 @@ check_bases_and_members (t, empty_p)
it turns out not to be nearly empty. */ it turns out not to be nearly empty. */
CLASSTYPE_NEARLY_EMPTY_P (t) = 1; CLASSTYPE_NEARLY_EMPTY_P (t) = 1;
/* Check all the base-classes. */ /* Check all the base-classes. */
check_bases (t, &cant_have_default_ctor, &cant_have_const_ctor, check_bases (t, &cant_have_default_ctor, &cant_have_const_ctor,
&no_const_asn_ref); &no_const_asn_ref);
...@@ -4779,7 +4779,7 @@ splay_tree_compare_integer_csts (k1, k2) ...@@ -4779,7 +4779,7 @@ splay_tree_compare_integer_csts (k1, k2)
/* Calculate the TYPE_SIZE, TYPE_ALIGN, etc for T. Calculate /* Calculate the TYPE_SIZE, TYPE_ALIGN, etc for T. Calculate
BINFO_OFFSETs for all of the base-classes. Position the vtable BINFO_OFFSETs for all of the base-classes. Position the vtable
pointer. Accumulate declared virtual functions on VIRTUALS_P. */ pointer. Accumulate declared virtual functions on VIRTUALS_P. */
static void static void
layout_class_type (t, empty_p, vfuns_p, virtuals_p) layout_class_type (t, empty_p, vfuns_p, virtuals_p)
...@@ -5031,7 +5031,7 @@ finish_struct_1 (t) ...@@ -5031,7 +5031,7 @@ finish_struct_1 (t)
{ {
tree x; tree x;
int vfuns; int vfuns;
/* A TREE_LIST. The TREE_VALUE of each node is a FUNCTION_DECL. */ /* A TREE_LIST. The TREE_VALUE of each node is a FUNCTION_DECL. */
tree virtuals = NULL_TREE; tree virtuals = NULL_TREE;
int n_fields = 0; int n_fields = 0;
tree vfield; tree vfield;
...@@ -5073,7 +5073,7 @@ finish_struct_1 (t) ...@@ -5073,7 +5073,7 @@ finish_struct_1 (t)
my_friendly_assert (same_type_p (DECL_FIELD_CONTEXT (vfield), my_friendly_assert (same_type_p (DECL_FIELD_CONTEXT (vfield),
BINFO_TYPE (primary)), BINFO_TYPE (primary)),
20010726); 20010726);
/* The vtable better be at the start. */ /* The vtable better be at the start. */
my_friendly_assert (integer_zerop (DECL_FIELD_OFFSET (vfield)), my_friendly_assert (integer_zerop (DECL_FIELD_OFFSET (vfield)),
20010726); 20010726);
my_friendly_assert (integer_zerop (BINFO_OFFSET (primary)), my_friendly_assert (integer_zerop (BINFO_OFFSET (primary)),
...@@ -5372,7 +5372,7 @@ fixed_type_or_null (instance, nonnull, cdtorp) ...@@ -5372,7 +5372,7 @@ fixed_type_or_null (instance, nonnull, cdtorp)
if (nonnull) if (nonnull)
*nonnull = 1; *nonnull = 1;
/* if we're in a ctor or dtor, we know our type. */ /* if we're in a ctor or dtor, we know our type. */
if (DECL_LANG_SPECIFIC (current_function_decl) if (DECL_LANG_SPECIFIC (current_function_decl)
&& (DECL_CONSTRUCTOR_P (current_function_decl) && (DECL_CONSTRUCTOR_P (current_function_decl)
|| DECL_DESTRUCTOR_P (current_function_decl))) || DECL_DESTRUCTOR_P (current_function_decl)))
...@@ -5714,7 +5714,7 @@ push_lang_context (name) ...@@ -5714,7 +5714,7 @@ push_lang_context (name)
/* DECL_IGNORED_P is initially set for these types, to avoid clutter. /* DECL_IGNORED_P is initially set for these types, to avoid clutter.
(See record_builtin_java_type in decl.c.) However, that causes (See record_builtin_java_type in decl.c.) However, that causes
incorrect debug entries if these types are actually used. incorrect debug entries if these types are actually used.
So we re-enable debug output after extern "Java". */ So we re-enable debug output after extern "Java". */
DECL_IGNORED_P (TYPE_NAME (java_byte_type_node)) = 0; DECL_IGNORED_P (TYPE_NAME (java_byte_type_node)) = 0;
DECL_IGNORED_P (TYPE_NAME (java_short_type_node)) = 0; DECL_IGNORED_P (TYPE_NAME (java_short_type_node)) = 0;
DECL_IGNORED_P (TYPE_NAME (java_int_type_node)) = 0; DECL_IGNORED_P (TYPE_NAME (java_int_type_node)) = 0;
...@@ -6138,7 +6138,7 @@ instantiate_type (lhstype, rhs, flags) ...@@ -6138,7 +6138,7 @@ instantiate_type (lhstype, rhs, flags)
/*explicit_targs=*/NULL_TREE); /*explicit_targs=*/NULL_TREE);
case TREE_LIST: case TREE_LIST:
/* Now we should have a baselink. */ /* Now we should have a baselink. */
my_friendly_assert (BASELINK_P (rhs), 990412); my_friendly_assert (BASELINK_P (rhs), 990412);
return instantiate_type (lhstype, BASELINK_FUNCTIONS (rhs), flags); return instantiate_type (lhstype, BASELINK_FUNCTIONS (rhs), flags);
...@@ -6480,7 +6480,7 @@ get_vtbl_decl_for_binfo (binfo) ...@@ -6480,7 +6480,7 @@ get_vtbl_decl_for_binfo (binfo)
/* Called from get_primary_binfo via dfs_walk. DATA is a TREE_LIST /* Called from get_primary_binfo via dfs_walk. DATA is a TREE_LIST
who's TREE_PURPOSE is the TYPE of the required primary base and who's TREE_PURPOSE is the TYPE of the required primary base and
who's TREE_VALUE is a list of candidate binfos that we fill in. */ who's TREE_VALUE is a list of candidate binfos that we fill in. */
static tree static tree
dfs_get_primary_binfo (binfo, data) dfs_get_primary_binfo (binfo, data)
...@@ -6587,7 +6587,7 @@ get_primary_binfo (binfo) ...@@ -6587,7 +6587,7 @@ get_primary_binfo (binfo)
return result; return result;
} }
/* If INDENTED_P is zero, indent to INDENT. Return non-zero. */ /* If INDENTED_P is zero, indent to INDENT. Return non-zero. */
static int static int
maybe_indent_hierarchy (stream, indent, indented_p) maybe_indent_hierarchy (stream, indent, indented_p)
...@@ -6954,7 +6954,7 @@ get_original_base (base_binfo, binfo) ...@@ -6954,7 +6954,7 @@ get_original_base (base_binfo, binfo)
/* When building a secondary VTT, BINFO_VTABLE is set to a TREE_LIST with /* When building a secondary VTT, BINFO_VTABLE is set to a TREE_LIST with
PURPOSE the RTTI_BINFO, VALUE the real vtable pointer for this binfo, PURPOSE the RTTI_BINFO, VALUE the real vtable pointer for this binfo,
and CHAIN the vtable pointer for this binfo after construction is and CHAIN the vtable pointer for this binfo after construction is
complete. VALUE can also be another BINFO, in which case we recurse. */ complete. VALUE can also be another BINFO, in which case we recurse. */
static tree static tree
binfo_ctor_vtable (binfo) binfo_ctor_vtable (binfo)
...@@ -7145,7 +7145,7 @@ dfs_build_secondary_vptr_vtt_inits (binfo, data) ...@@ -7145,7 +7145,7 @@ dfs_build_secondary_vptr_vtt_inits (binfo, data)
{ {
/* It's a primary virtual base, and this is not the construction /* It's a primary virtual base, and this is not the construction
vtable. Find the base this is primary of in the inheritance graph, vtable. Find the base this is primary of in the inheritance graph,
and use that base's vtable now. */ and use that base's vtable now. */
while (BINFO_PRIMARY_BASE_OF (binfo)) while (BINFO_PRIMARY_BASE_OF (binfo))
binfo = BINFO_PRIMARY_BASE_OF (binfo); binfo = BINFO_PRIMARY_BASE_OF (binfo);
} }
...@@ -7284,7 +7284,7 @@ accumulate_vtbl_inits (binfo, orig_binfo, rtti_binfo, t, inits) ...@@ -7284,7 +7284,7 @@ accumulate_vtbl_inits (binfo, orig_binfo, rtti_binfo, t, inits)
BINFO_TYPE (orig_binfo)), BINFO_TYPE (orig_binfo)),
20000517); 20000517);
/* If it doesn't have a vptr, we don't do anything. */ /* If it doesn't have a vptr, we don't do anything. */
if (!TYPE_CONTAINS_VPTR_P (BINFO_TYPE (binfo))) if (!TYPE_CONTAINS_VPTR_P (BINFO_TYPE (binfo)))
return; return;
......
...@@ -157,7 +157,7 @@ static tree cp_expr_size PARAMS ((tree)); ...@@ -157,7 +157,7 @@ static tree cp_expr_size PARAMS ((tree));
/* Each front end provides its own hooks, for toplev.c. */ /* Each front end provides its own hooks, for toplev.c. */
const struct lang_hooks lang_hooks = LANG_HOOKS_INITIALIZER; const struct lang_hooks lang_hooks = LANG_HOOKS_INITIALIZER;
/* Tree code classes. */ /* Tree code classes. */
#define DEFTREECODE(SYM, NAME, TYPE, LENGTH) TYPE, #define DEFTREECODE(SYM, NAME, TYPE, LENGTH) TYPE,
......
...@@ -153,7 +153,7 @@ struct diagnostic_context; ...@@ -153,7 +153,7 @@ struct diagnostic_context;
the virtual function this one overrides, and whose TREE_CHAIN is the virtual function this one overrides, and whose TREE_CHAIN is
the old DECL_VINDEX. */ the old DECL_VINDEX. */
/* Language-specific tree checkers. */ /* Language-specific tree checkers. */
#if defined ENABLE_TREE_CHECKING && (GCC_VERSION >= 2007) #if defined ENABLE_TREE_CHECKING && (GCC_VERSION >= 2007)
...@@ -340,18 +340,18 @@ struct tree_binding GTY(()) ...@@ -340,18 +340,18 @@ struct tree_binding GTY(())
tree value; tree value;
}; };
/* The overloaded FUNCTION_DECL. */ /* The overloaded FUNCTION_DECL. */
#define OVL_FUNCTION(NODE) \ #define OVL_FUNCTION(NODE) \
(((struct tree_overload*)OVERLOAD_CHECK (NODE))->function) (((struct tree_overload*)OVERLOAD_CHECK (NODE))->function)
#define OVL_CHAIN(NODE) TREE_CHAIN (NODE) #define OVL_CHAIN(NODE) TREE_CHAIN (NODE)
/* Polymorphic access to FUNCTION and CHAIN. */ /* Polymorphic access to FUNCTION and CHAIN. */
#define OVL_CURRENT(NODE) \ #define OVL_CURRENT(NODE) \
((TREE_CODE (NODE) == OVERLOAD) ? OVL_FUNCTION (NODE) : (NODE)) ((TREE_CODE (NODE) == OVERLOAD) ? OVL_FUNCTION (NODE) : (NODE))
#define OVL_NEXT(NODE) \ #define OVL_NEXT(NODE) \
((TREE_CODE (NODE) == OVERLOAD) ? TREE_CHAIN (NODE) : NULL_TREE) ((TREE_CODE (NODE) == OVERLOAD) ? TREE_CHAIN (NODE) : NULL_TREE)
/* If set, this was imported in a using declaration. /* If set, this was imported in a using declaration.
This is not to confuse with being used somewhere, which This is not to confuse with being used somewhere, which
is not important for this node. */ is not important for this node. */
#define OVL_USED(NODE) TREE_USED (NODE) #define OVL_USED(NODE) TREE_USED (NODE)
struct tree_overload GTY(()) struct tree_overload GTY(())
...@@ -435,7 +435,7 @@ struct tree_srcloc GTY(()) ...@@ -435,7 +435,7 @@ struct tree_srcloc GTY(())
/* TREE_TYPE only indicates on local and class scope the current /* TREE_TYPE only indicates on local and class scope the current
type. For namespace scope, the presence of a type in any namespace type. For namespace scope, the presence of a type in any namespace
is indicated with global_type_node, and the real type behind must is indicated with global_type_node, and the real type behind must
be found through lookup. */ be found through lookup. */
#define IDENTIFIER_TYPE_VALUE(NODE) identifier_type_value (NODE) #define IDENTIFIER_TYPE_VALUE(NODE) identifier_type_value (NODE)
#define REAL_IDENTIFIER_TYPE_VALUE(NODE) TREE_TYPE (NODE) #define REAL_IDENTIFIER_TYPE_VALUE(NODE) TREE_TYPE (NODE)
#define SET_IDENTIFIER_TYPE_VALUE(NODE,TYPE) (TREE_TYPE (NODE) = (TYPE)) #define SET_IDENTIFIER_TYPE_VALUE(NODE,TYPE) (TREE_TYPE (NODE) = (TYPE))
...@@ -708,7 +708,7 @@ extern GTY(()) tree cp_global_trees[CPTI_MAX]; ...@@ -708,7 +708,7 @@ extern GTY(()) tree cp_global_trees[CPTI_MAX];
/* The node for `__null'. */ /* The node for `__null'. */
#define null_node cp_global_trees[CPTI_NULL] #define null_node cp_global_trees[CPTI_NULL]
/* If non-NULL, a POINTER_TYPE equivalent to (java::lang::Class*). */ /* If non-NULL, a POINTER_TYPE equivalent to (java::lang::Class*). */
#define jclass_node cp_global_trees[CPTI_JCLASS] #define jclass_node cp_global_trees[CPTI_JCLASS]
/* The declaration for `std::terminate'. */ /* The declaration for `std::terminate'. */
...@@ -770,7 +770,7 @@ struct saved_scope GTY(()) ...@@ -770,7 +770,7 @@ struct saved_scope GTY(())
#define current_namespace scope_chain->old_namespace #define current_namespace scope_chain->old_namespace
/* The stack for namespaces of current declarations. */ /* The stack for namespaces of current declarations. */
#define decl_namespace_list scope_chain->decl_ns_list #define decl_namespace_list scope_chain->decl_ns_list
...@@ -996,7 +996,7 @@ enum languages { lang_c, lang_cplusplus, lang_java }; ...@@ -996,7 +996,7 @@ enum languages { lang_c, lang_cplusplus, lang_java };
/* In a *_TYPE, nonzero means a built-in type. */ /* In a *_TYPE, nonzero means a built-in type. */
#define TYPE_BUILT_IN(NODE) TYPE_LANG_FLAG_6 (NODE) #define TYPE_BUILT_IN(NODE) TYPE_LANG_FLAG_6 (NODE)
/* True if this a "Java" type, defined in 'extern "Java"'. */ /* True if this a "Java" type, defined in 'extern "Java"'. */
#define TYPE_FOR_JAVA(NODE) TYPE_LANG_FLAG_3 (NODE) #define TYPE_FOR_JAVA(NODE) TYPE_LANG_FLAG_3 (NODE)
/* Nonzero if this type is const-qualified. */ /* Nonzero if this type is const-qualified. */
...@@ -1401,7 +1401,7 @@ struct lang_type GTY(()) ...@@ -1401,7 +1401,7 @@ struct lang_type GTY(())
(CLASSTYPE_ALIGN (NODE) / BITS_PER_UNIT) (CLASSTYPE_ALIGN (NODE) / BITS_PER_UNIT)
/* True if this a Java interface type, declared with /* True if this a Java interface type, declared with
'__attribute__ ((java_interface))'. */ '__attribute__ ((java_interface))'. */
#define TYPE_JAVA_INTERFACE(NODE) (LANG_TYPE_CLASS_CHECK (NODE)->java_interface) #define TYPE_JAVA_INTERFACE(NODE) (LANG_TYPE_CLASS_CHECK (NODE)->java_interface)
/* A cons list of virtual functions which cannot be inherited by /* A cons list of virtual functions which cannot be inherited by
...@@ -1614,11 +1614,11 @@ struct lang_type GTY(()) ...@@ -1614,11 +1614,11 @@ struct lang_type GTY(())
non-NULL). */ non-NULL). */
#define VF_BASETYPE_VALUE(NODE) TREE_VALUE (NODE) #define VF_BASETYPE_VALUE(NODE) TREE_VALUE (NODE)
/* Accessor macros for the BINFO_VIRTUALS list. */ /* Accessor macros for the BINFO_VIRTUALS list. */
/* The number of bytes by which to adjust the `this' pointer when /* The number of bytes by which to adjust the `this' pointer when
calling this virtual function. Subtract this value from the this calling this virtual function. Subtract this value from the this
pointer. Always non-NULL, might be constant zero though. */ pointer. Always non-NULL, might be constant zero though. */
#define BV_DELTA(NODE) (TREE_PURPOSE (NODE)) #define BV_DELTA(NODE) (TREE_PURPOSE (NODE))
/* If non-NULL, the vtable index at which to find the vcall offset /* If non-NULL, the vtable index at which to find the vcall offset
...@@ -2043,7 +2043,7 @@ struct lang_decl GTY(()) ...@@ -2043,7 +2043,7 @@ struct lang_decl GTY(())
(TREE_LANG_FLAG_0 (NODE)) (TREE_LANG_FLAG_0 (NODE))
/* The _TYPE context in which this _DECL appears. This field holds the /* The _TYPE context in which this _DECL appears. This field holds the
class where a virtual function instance is actually defined. */ class where a virtual function instance is actually defined. */
#define DECL_CLASS_CONTEXT(NODE) \ #define DECL_CLASS_CONTEXT(NODE) \
(DECL_CLASS_SCOPE_P (NODE) ? DECL_CONTEXT (NODE) : NULL_TREE) (DECL_CLASS_SCOPE_P (NODE) ? DECL_CONTEXT (NODE) : NULL_TREE)
...@@ -2062,7 +2062,7 @@ struct lang_decl GTY(()) ...@@ -2062,7 +2062,7 @@ struct lang_decl GTY(())
#define SET_DECL_FRIEND_CONTEXT(NODE, CONTEXT) \ #define SET_DECL_FRIEND_CONTEXT(NODE, CONTEXT) \
(DECL_LANG_SPECIFIC (NODE)->u.f.context = (CONTEXT)) (DECL_LANG_SPECIFIC (NODE)->u.f.context = (CONTEXT))
/* NULL_TREE in DECL_CONTEXT represents the global namespace. */ /* NULL_TREE in DECL_CONTEXT represents the global namespace. */
#define CP_DECL_CONTEXT(NODE) \ #define CP_DECL_CONTEXT(NODE) \
(DECL_CONTEXT (NODE) ? DECL_CONTEXT (NODE) : global_namespace) (DECL_CONTEXT (NODE) ? DECL_CONTEXT (NODE) : global_namespace)
#define FROB_CONTEXT(NODE) ((NODE) == global_namespace ? NULL_TREE : (NODE)) #define FROB_CONTEXT(NODE) ((NODE) == global_namespace ? NULL_TREE : (NODE))
...@@ -2092,11 +2092,11 @@ struct lang_decl GTY(()) ...@@ -2092,11 +2092,11 @@ struct lang_decl GTY(())
/* For a NAMESPACE_DECL: the list of using namespace directives /* For a NAMESPACE_DECL: the list of using namespace directives
The PURPOSE is the used namespace, the value is the namespace The PURPOSE is the used namespace, the value is the namespace
that is the common ancestor. */ that is the common ancestor. */
#define DECL_NAMESPACE_USING(NODE) DECL_VINDEX (NAMESPACE_DECL_CHECK (NODE)) #define DECL_NAMESPACE_USING(NODE) DECL_VINDEX (NAMESPACE_DECL_CHECK (NODE))
/* In a NAMESPACE_DECL, the DECL_INITIAL is used to record all users /* In a NAMESPACE_DECL, the DECL_INITIAL is used to record all users
of a namespace, to record the transitive closure of using namespace. */ of a namespace, to record the transitive closure of using namespace. */
#define DECL_NAMESPACE_USERS(NODE) DECL_INITIAL (NAMESPACE_DECL_CHECK (NODE)) #define DECL_NAMESPACE_USERS(NODE) DECL_INITIAL (NAMESPACE_DECL_CHECK (NODE))
/* In a NAMESPACE_DECL, points to the original namespace if this is /* In a NAMESPACE_DECL, points to the original namespace if this is
...@@ -2137,7 +2137,7 @@ struct lang_decl GTY(()) ...@@ -2137,7 +2137,7 @@ struct lang_decl GTY(())
(DECL_LANG_SPECIFIC (NODE)->u.f.u.pending_inline_info) (DECL_LANG_SPECIFIC (NODE)->u.f.u.pending_inline_info)
/* For a TYPE_DECL: if this function has many fields, we'll sort them /* For a TYPE_DECL: if this function has many fields, we'll sort them
and put them into a TREE_VEC. */ and put them into a TREE_VEC. */
#define DECL_SORTED_FIELDS(NODE) \ #define DECL_SORTED_FIELDS(NODE) \
(DECL_LANG_SPECIFIC (TYPE_DECL_CHECK (NODE))->u.f.u.sorted_fields) (DECL_LANG_SPECIFIC (TYPE_DECL_CHECK (NODE))->u.f.u.sorted_fields)
...@@ -3053,19 +3053,19 @@ typedef enum tsubst_flags_t { ...@@ -3053,19 +3053,19 @@ typedef enum tsubst_flags_t {
(make_typename_type use) */ (make_typename_type use) */
} tsubst_flags_t; } tsubst_flags_t;
/* The kind of checking we can do looking in a class hierarchy. */ /* The kind of checking we can do looking in a class hierarchy. */
typedef enum base_access { typedef enum base_access {
ba_any = 0, /* Do not check access, allow an ambiguous base, ba_any = 0, /* Do not check access, allow an ambiguous base,
prefer a non-virtual base */ prefer a non-virtual base */
ba_ignore = 1, /* Do not check access */ ba_ignore = 1, /* Do not check access */
ba_check = 2, /* Check access */ ba_check = 2, /* Check access */
ba_not_special = 3, /* Do not consider special privilege ba_not_special = 3, /* Do not consider special privilege
current_class_type might give. */ current_class_type might give. */
ba_quiet = 4, /* Do not issue error messages (bit mask). */ ba_quiet = 4, /* Do not issue error messages (bit mask). */
} base_access; } base_access;
/* The kind of base we can find, looking in a class hierarchy. /* The kind of base we can find, looking in a class hierarchy.
Values <0 indicate we failed. */ Values <0 indicate we failed. */
typedef enum base_kind { typedef enum base_kind {
bk_inaccessible = -3, /* The base is inaccessible */ bk_inaccessible = -3, /* The base is inaccessible */
bk_ambig = -2, /* The base is ambiguous */ bk_ambig = -2, /* The base is ambiguous */
...@@ -3074,7 +3074,7 @@ typedef enum base_kind { ...@@ -3074,7 +3074,7 @@ typedef enum base_kind {
bk_proper_base = 1, /* It is a proper base */ bk_proper_base = 1, /* It is a proper base */
bk_via_virtual = 2 /* It is a proper base, but via a virtual bk_via_virtual = 2 /* It is a proper base, but via a virtual
path. This might not be the canonical path. This might not be the canonical
binfo. */ binfo. */
} base_kind; } base_kind;
/* Set by add_implicitly_declared_members() to keep those members from /* Set by add_implicitly_declared_members() to keep those members from
......
...@@ -149,12 +149,12 @@ cp_convert_to_pointer (type, expr, force) ...@@ -149,12 +149,12 @@ cp_convert_to_pointer (type, expr, force)
enum tree_code code = PLUS_EXPR; enum tree_code code = PLUS_EXPR;
tree binfo; tree binfo;
/* Try derived to base conversion. */ /* Try derived to base conversion. */
binfo = lookup_base (TREE_TYPE (intype), TREE_TYPE (type), binfo = lookup_base (TREE_TYPE (intype), TREE_TYPE (type),
ba_check, NULL); ba_check, NULL);
if (!binfo) if (!binfo)
{ {
/* Try base to derived conversion. */ /* Try base to derived conversion. */
binfo = lookup_base (TREE_TYPE (type), TREE_TYPE (intype), binfo = lookup_base (TREE_TYPE (type), TREE_TYPE (intype),
ba_check, NULL); ba_check, NULL);
code = MINUS_EXPR; code = MINUS_EXPR;
...@@ -164,7 +164,7 @@ cp_convert_to_pointer (type, expr, force) ...@@ -164,7 +164,7 @@ cp_convert_to_pointer (type, expr, force)
if (binfo) if (binfo)
{ {
expr = build_base_path (code, expr, binfo, 0); expr = build_base_path (code, expr, binfo, 0);
/* Add any qualifier conversions. */ /* Add any qualifier conversions. */
if (!same_type_p (TREE_TYPE (TREE_TYPE (expr)), if (!same_type_p (TREE_TYPE (TREE_TYPE (expr)),
TREE_TYPE (type))) TREE_TYPE (type)))
{ {
...@@ -322,7 +322,7 @@ convert_to_pointer_force (type, expr) ...@@ -322,7 +322,7 @@ convert_to_pointer_force (type, expr)
if (binfo) if (binfo)
{ {
expr = build_base_path (code, expr, binfo, 0); expr = build_base_path (code, expr, binfo, 0);
/* Add any qualifier conversions. */ /* Add any qualifier conversions. */
if (!same_type_p (TREE_TYPE (TREE_TYPE (expr)), if (!same_type_p (TREE_TYPE (TREE_TYPE (expr)),
TREE_TYPE (type))) TREE_TYPE (type)))
{ {
...@@ -857,7 +857,7 @@ convert_to_void (expr, implicit) ...@@ -857,7 +857,7 @@ convert_to_void (expr, implicit)
case NON_LVALUE_EXPR: case NON_LVALUE_EXPR:
case NOP_EXPR: case NOP_EXPR:
/* These have already decayed to rvalue. */ /* These have already decayed to rvalue. */
break; break;
case CALL_EXPR: /* we have a special meaning for volatile void fn() */ case CALL_EXPR: /* we have a special meaning for volatile void fn() */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment