This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[C++ PATCH] newabi rtti tweak
- To: gcc-patches at gcc dot gnu dot org
- Subject: [C++ PATCH] newabi rtti tweak
- From: Nathan Sidwell <nathan at codesourcery dot com>
- Date: Wed, 15 Mar 2000 17:17:17 +0000
- Organization: CodeSourcery, LLC
I've installed this one which renames __ptr_to_member_data
to __pointer_to_member_data
nathan
--
Dr Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
'But that's a lie.' - 'Yes it is. What's your point?'
nathan@codesourcery.com : http://www.cs.bris.ac.uk/~nathan/ : nathan@acm.org
2000-03-15 Nathan Sidwell <nathan@codesourcery.com>
* tinfo2.cc (__ptr_to_member_data): Rename to ...
(__pointer_to_member_data): ... here. Adjust.
* rtti.c (create_tinfo_types): Adjust.
Index: cp/rtti.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cp/rtti.c,v
retrieving revision 1.68
diff -c -3 -p -r1.68 rtti.c
*** rtti.c 2000/03/15 10:40:27 1.68
--- rtti.c 2000/03/15 17:15:22
*************** create_tinfo_types ()
*** 1752,1758 ****
/* Pointer to member data type_info. Add pointer to the class, pointer
to the member's type info and qualifications flags. */
ptmd_desc_type_node = create_pseudo_type_info
! ("__ptr_to_member_type_info", 0,
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
build_lang_decl (FIELD_DECL, NULL_TREE, integer_type_node),
--- 1752,1758 ----
/* Pointer to member data type_info. Add pointer to the class, pointer
to the member's type info and qualifications flags. */
ptmd_desc_type_node = create_pseudo_type_info
! ("__pointer_to_member_type_info", 0,
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
build_lang_decl (FIELD_DECL, NULL_TREE, ptr_type_info),
build_lang_decl (FIELD_DECL, NULL_TREE, integer_type_node),
Index: cp/tinfo2.cc
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cp/tinfo2.cc,v
retrieving revision 1.16
diff -c -3 -p -r1.16 tinfo2.cc
*** tinfo2.cc 2000/03/15 10:40:27 1.16
--- tinfo2.cc 2000/03/15 17:15:23
*************** public:
*** 163,171 ****
};
// type information for a pointer to member variable (not function)
! class __ptr_to_member_type_info : public type_info {
public:
! virtual ~__ptr_to_member_type_info ();
// external parts
const __class_type_info *klass; // class of the member
const type_info *type; // type of the member
--- 163,171 ----
};
// type information for a pointer to member variable (not function)
! class __pointer_to_member_type_info : public type_info {
public:
! virtual ~__pointer_to_member_type_info ();
// external parts
const __class_type_info *klass; // class of the member
const type_info *type; // type of the member
*************** public:
*** 178,187 ****
};
public:
! explicit __ptr_to_member_type_info (const char *n,
! const __class_type_info *klass_,
! const type_info *type_,
! int quals_)
: type_info (n), klass (klass_), type (type_), quals (quals_)
{ }
--- 178,187 ----
};
public:
! explicit __pointer_to_member_type_info (const char *n,
! const __class_type_info *klass_,
! const type_info *type_,
! int quals_)
: type_info (n), klass (klass_), type (type_), quals (quals_)
{ }
*************** __enum_type_info::
*** 220,227 ****
~__enum_type_info ()
{}
! __ptr_to_member_type_info::
! ~__ptr_to_member_type_info ()
{}
bool __pointer_type_info::
--- 220,227 ----
~__enum_type_info ()
{}
! __pointer_to_member_type_info::
! ~__pointer_to_member_type_info ()
{}
bool __pointer_type_info::
*************** do_catch (const type_info *thr_type,
*** 271,277 ****
return target->do_catch (thrown_type->target, thr_obj, outer + 2);
}
! bool __ptr_to_member_type_info::
do_catch (const type_info *thr_type,
void **thr_obj,
unsigned outer) const
--- 271,277 ----
return target->do_catch (thrown_type->target, thr_obj, outer + 2);
}
! bool __pointer_to_member_type_info::
do_catch (const type_info *thr_type,
void **thr_obj,
unsigned outer) const
*************** do_catch (const type_info *thr_type,
*** 287,294 ****
// But for that to be valid, our outer pointers must be const qualified.
return false;
! const __ptr_to_member_type_info *thrown_type =
! static_cast <const __ptr_to_member_type_info *> (thr_type);
if (thrown_type->quals & ~quals)
// We're less qualified.
--- 287,294 ----
// But for that to be valid, our outer pointers must be const qualified.
return false;
! const __pointer_to_member_type_info *thrown_type =
! static_cast <const __pointer_to_member_type_info *> (thr_type);
if (thrown_type->quals & ~quals)
// We're less qualified.