cp-tree.h (CPTI_REF_DESC_TYPE, [...]): Remove.

* cp-tree.h (CPTI_REF_DESC_TYPE, ref_desc_type_node): Remove.
	* decl.c (ref_desc_type_node): Undocument.
	* rtti.c (ptr_ref_initializer): Rename to ...
	(ptr_initializer): ... here. Adjust comments.
	(ptmd_initializer): Fix comment thinko.
	(synthesize_tinfo_var): Remove REFERENCE_TYPE case.
	(create_tinfo_types): Remove ref_desc_type_node init.
	* tinfo2.cc (__reference_type_info): Remove.

From-SVN: r32558
This commit is contained in:
Nathan Sidwell 2000-03-15 10:40:27 +00:00 committed by Nathan Sidwell
parent f78c7bc628
commit 1f4cb92b42
5 changed files with 19 additions and 44 deletions

View File

@ -1,3 +1,14 @@
2000-03-15 Nathan Sidwell <nathan@codesourcery.com>
* cp-tree.h (CPTI_REF_DESC_TYPE, ref_desc_type_node): Remove.
* decl.c (ref_desc_type_node): Undocument.
* rtti.c (ptr_ref_initializer): Rename to ...
(ptr_initializer): ... here. Adjust comments.
(ptmd_initializer): Fix comment thinko.
(synthesize_tinfo_var): Remove REFERENCE_TYPE case.
(create_tinfo_types): Remove ref_desc_type_node init.
* tinfo2.cc (__reference_type_info): Remove.
2000-03-15 Nathan Sidwell <nathan@codesourcery.com>
* decl.c (cp_finish_decl): Remove obsolete comment.

View File

@ -520,7 +520,6 @@ enum cp_tree_index
CPTI_TI_DESC_TYPE,
CPTI_BLTN_DESC_TYPE,
CPTI_PTR_DESC_TYPE,
CPTI_REF_DESC_TYPE,
CPTI_ARY_DESC_TYPE,
CPTI_FUNC_DESC_TYPE,
CPTI_ENUM_DESC_TYPE,
@ -606,7 +605,6 @@ extern tree cp_global_trees[CPTI_MAX];
#define ti_desc_type_node cp_global_trees[CPTI_TI_DESC_TYPE]
#define bltn_desc_type_node cp_global_trees[CPTI_BLTN_DESC_TYPE]
#define ptr_desc_type_node cp_global_trees[CPTI_PTR_DESC_TYPE]
#define ref_desc_type_node cp_global_trees[CPTI_REF_DESC_TYPE]
#define ary_desc_type_node cp_global_trees[CPTI_ARY_DESC_TYPE]
#define func_desc_type_node cp_global_trees[CPTI_FUNC_DESC_TYPE]
#define enum_desc_type_node cp_global_trees[CPTI_ENUM_DESC_TYPE]

View File

@ -211,7 +211,7 @@ tree error_mark_list;
tree __tp_desc_type_node;
#endif
tree ti_desc_type_node;
tree bltn_desc_type_node, ptr_desc_type_node, ref_desc_type_node;
tree bltn_desc_type_node, ptr_desc_type_node;
tree ary_desc_type_node, func_desc_type_node, enum_desc_type_node;
tree class_desc_type_node, si_class_desc_type_node, vmi_class_desc_type_node;
tree ptmd_desc_type_node;

View File

@ -64,7 +64,7 @@ static tree tinfo_from_decl PARAMS((tree));
static int qualifier_flags PARAMS((tree));
static tree tinfo_base_init PARAMS((tree, tree));
static tree generic_initializer PARAMS((tree, tree));
static tree ptr_ref_initializer PARAMS((tree, tree));
static tree ptr_initializer PARAMS((tree, tree));
static tree ptmd_initializer PARAMS((tree, tree));
static int class_hint_flags PARAMS((tree));
static tree class_initializer PARAMS((tree, tree, tree));
@ -1298,12 +1298,12 @@ generic_initializer (desc, target)
return init;
}
/* Return the CONSTRUCTOR expr for a type_info of pointer or reference TYPE.
/* Return the CONSTRUCTOR expr for a type_info of pointer TYPE.
DESC provides information about the particular type_info derivation,
which adds target type and qualifier flags members to the type_info base. */
static tree
ptr_ref_initializer (desc, target)
ptr_initializer (desc, target)
tree desc;
tree target;
{
@ -1322,7 +1322,7 @@ ptr_ref_initializer (desc, target)
return init;
}
/* Return the CONSTRUCTOR expr for a type_info of pointer or reference TYPE.
/* Return the CONSTRUCTOR expr for a type_info of pointer to member data TYPE.
DESC provides information about the particular type_info derivation,
which adds target type and qualifier flags members to the type_info base. */
@ -1427,13 +1427,9 @@ synthesize_tinfo_var (target_type, real_name)
/* These are in the runtime. */
return NULL_TREE;
var_type = ptr_desc_type_node;
var_init = ptr_ref_initializer (var_type, target_type);
var_init = ptr_initializer (var_type, target_type);
}
break;
case REFERENCE_TYPE:
var_type = ref_desc_type_node;
var_init = ptr_ref_initializer (var_type, target_type);
break;
case ENUMERAL_TYPE:
var_type = enum_desc_type_node;
var_init = generic_initializer (var_type, target_type);
@ -1704,18 +1700,13 @@ create_tinfo_types ()
("__fundamental_type_info", 0,
NULL);
/* Pointer and reference type_info. These two fields, qualification mask
and pointer to the pointed to (referenced) type. */
/* Pointer type_info. Adds two fields, qualification mask
and pointer to the pointed to type. */
ptr_desc_type_node = create_pseudo_type_info
("__pointer_type_info", 0,
build_lang_decl (FIELD_DECL, NULL_TREE, integer_type_node),
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
NULL);
ref_desc_type_node = create_pseudo_type_info
("__reference_type_info", 0,
build_lang_decl (FIELD_DECL, NULL_TREE, integer_type_node),
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
NULL);
/* Array, function and enum type_info. No additional fields. */
ary_desc_type_node = create_pseudo_type_info

View File

@ -130,27 +130,6 @@ protected:
unsigned outer) const;
};
// type information for reference to data
class __reference_type_info : public type_info {
public:
virtual ~__reference_type_info ();
int quals; // qualification of the target object
const type_info *target; // type of object being referenced
// internal parts
enum quals_masks {
const_mask = 0x1,
volatile_mask = 0x2
};
public:
explicit __reference_type_info (const char *n,
int quals_,
const type_info *target_)
: type_info (n), quals (quals_), target (target_)
{ }
};
// type information for array objects
class __array_type_info : public type_info {
public:
@ -229,10 +208,6 @@ __pointer_type_info::
~__pointer_type_info ()
{}
__reference_type_info::
~__reference_type_info ()
{}
__array_type_info::
~__array_type_info ()
{}