cxxabi.h (__pbase_type_info): Changed member names to match specifications.
2000-08-04 Jeffrey D. Oldham <oldham@codesourcery.com> * inc/cxxabi.h (__pbase_type_info): Changed member names to match specifications. (__pointer_to_member_type_info): Likewise. (__base_class_info): Likewise. (__class_type_info): Likewise. (__si_class_type_info): Likewise. (__vmi_class_type_info): Likewise. * tinfo.cc (__si_class_type_info::__do_find_public_src): Changed member names to match specifications. (__vmi_class_type_info::__do_find_public_src): Likewise. (__si_class_type_info::__do_dyncast): Likewise. (__vmi_class_type_info::__do_dyncast): Likewise. (__si_class_type_info::__do_upcast): Likewise. (__vmi_class_type_info::__do_upcast): Likewise. * tinfo2.cc (__pbase_type_info::__do_catch): Likewise. (__pbase_type_info::__pointer_catch): Likewise. (__pointer_type_info::__pointer_catch): Likewise. (__pointer_to_member_type_info::__pointer_catch): Likewise. From-SVN: r35503
This commit is contained in:
parent
8cab40f72e
commit
f9fcf62b6a
|
@ -1,3 +1,25 @@
|
||||||
|
2000-08-04 Jeffrey Oldham <oldham@codesourcery.com>
|
||||||
|
|
||||||
|
* inc/cxxabi.h (__pbase_type_info): Changed member names to match
|
||||||
|
specifications.
|
||||||
|
(__pointer_to_member_type_info): Likewise.
|
||||||
|
(__base_class_info): Likewise.
|
||||||
|
(__class_type_info): Likewise.
|
||||||
|
(__si_class_type_info): Likewise.
|
||||||
|
(__vmi_class_type_info): Likewise.
|
||||||
|
* tinfo.cc (__si_class_type_info::__do_find_public_src):
|
||||||
|
Changed member names to match specifications.
|
||||||
|
(__vmi_class_type_info::__do_find_public_src): Likewise.
|
||||||
|
(__si_class_type_info::__do_dyncast): Likewise.
|
||||||
|
(__vmi_class_type_info::__do_dyncast): Likewise.
|
||||||
|
(__si_class_type_info::__do_upcast): Likewise.
|
||||||
|
(__vmi_class_type_info::__do_upcast): Likewise.
|
||||||
|
* tinfo2.cc (__pbase_type_info::__do_catch): Likewise.
|
||||||
|
(__pbase_type_info::__pointer_catch): Likewise.
|
||||||
|
(__pointer_type_info::__pointer_catch): Likewise.
|
||||||
|
(__pointer_to_member_type_info::__pointer_catch): Likewise.
|
||||||
|
|
||||||
|
|
||||||
2000-08-04 Zack Weinberg <zack@wolery.cumb.org>
|
2000-08-04 Zack Weinberg <zack@wolery.cumb.org>
|
||||||
|
|
||||||
* Make-lang.in (cc1plus): Depend on $(BACKEND), not stamp-objlist.
|
* Make-lang.in (cc1plus): Depend on $(BACKEND), not stamp-objlist.
|
||||||
|
|
|
@ -122,8 +122,8 @@ class __pbase_type_info
|
||||||
{
|
{
|
||||||
/* abi defined member variables */
|
/* abi defined member variables */
|
||||||
public:
|
public:
|
||||||
int quals; /* qualification of the target object */
|
unsigned int __qualifier_flags; /* qualification of the target object */
|
||||||
const std::type_info *type; /* type of pointed to object */
|
const std::type_info *__pointee; /* type of pointed to object */
|
||||||
|
|
||||||
/* abi defined member functions */
|
/* abi defined member functions */
|
||||||
public:
|
public:
|
||||||
|
@ -132,17 +132,17 @@ public:
|
||||||
explicit __pbase_type_info (const char *__n,
|
explicit __pbase_type_info (const char *__n,
|
||||||
int __quals,
|
int __quals,
|
||||||
const std::type_info *__type)
|
const std::type_info *__type)
|
||||||
: std::type_info (__n), quals (__quals), type (__type)
|
: std::type_info (__n), __qualifier_flags (__quals), __pointee (__type)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/* implementation defined types */
|
/* implementation defined types */
|
||||||
public:
|
public:
|
||||||
enum quals_masks {
|
enum __qualifier_masks {
|
||||||
const_mask = 0x1,
|
__const_mask = 0x1,
|
||||||
volatile_mask = 0x2,
|
__volatile_mask = 0x2,
|
||||||
restrict_mask = 0x4,
|
__restrict_mask = 0x4,
|
||||||
incomplete_mask = 0x8,
|
__incomplete_mask = 0x8,
|
||||||
incomplete_class_mask = 0x10
|
__incomplete_class_mask = 0x10
|
||||||
};
|
};
|
||||||
|
|
||||||
/* implementation defined member functions */
|
/* implementation defined member functions */
|
||||||
|
@ -186,7 +186,7 @@ class __pointer_to_member_type_info
|
||||||
{
|
{
|
||||||
/* abi defined member variables */
|
/* abi defined member variables */
|
||||||
public:
|
public:
|
||||||
const __class_type_info *klass; /* class of the member */
|
__class_type_info *__context_class; /* class of the member */
|
||||||
|
|
||||||
/* abi defined member functions */
|
/* abi defined member functions */
|
||||||
public:
|
public:
|
||||||
|
@ -195,8 +195,8 @@ public:
|
||||||
explicit __pointer_to_member_type_info (const char *__n,
|
explicit __pointer_to_member_type_info (const char *__n,
|
||||||
int __quals,
|
int __quals,
|
||||||
const std::type_info *__type,
|
const std::type_info *__type,
|
||||||
const __class_type_info *__klass)
|
__class_type_info *__klass)
|
||||||
: __pbase_type_info (__n, __quals, __type), klass (__klass)
|
: __pbase_type_info (__n, __quals, __type), __context_class (__klass)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/* implementation defined member functions */
|
/* implementation defined member functions */
|
||||||
|
@ -213,14 +213,14 @@ class __base_class_info
|
||||||
{
|
{
|
||||||
/* abi defined member variables */
|
/* abi defined member variables */
|
||||||
public:
|
public:
|
||||||
const __class_type_info *base; /* base class type */
|
const __class_type_info *__base; /* base class type */
|
||||||
long vmi_offset_flags; /* offset and info */
|
long __offset_flags; /* offset and info */
|
||||||
|
|
||||||
/* implementation defined types */
|
/* implementation defined types */
|
||||||
public:
|
public:
|
||||||
enum vmi_masks {
|
enum __offset_flags_masks {
|
||||||
virtual_mask = 0x1,
|
__virtual_mask = 0x1,
|
||||||
public_mask = 0x2,
|
__public_mask = 0x2,
|
||||||
hwm_bit = 2,
|
hwm_bit = 2,
|
||||||
offset_shift = 8 /* bits to shift offset by */
|
offset_shift = 8 /* bits to shift offset by */
|
||||||
};
|
};
|
||||||
|
@ -228,14 +228,14 @@ public:
|
||||||
/* implementation defined member functions */
|
/* implementation defined member functions */
|
||||||
public:
|
public:
|
||||||
bool __is_virtual_p () const
|
bool __is_virtual_p () const
|
||||||
{ return vmi_offset_flags & virtual_mask; }
|
{ return __offset_flags & __virtual_mask; }
|
||||||
bool __is_public_p () const
|
bool __is_public_p () const
|
||||||
{ return vmi_offset_flags & public_mask; }
|
{ return __offset_flags & __public_mask; }
|
||||||
__PTRDIFF_TYPE__ __offset () const
|
__PTRDIFF_TYPE__ __offset () const
|
||||||
{
|
{
|
||||||
// This shift, being of a signed type, is implementation defined. GCC
|
// This shift, being of a signed type, is implementation defined. GCC
|
||||||
// implements such shifts as arithmetic, which is what we want.
|
// implements such shifts as arithmetic, which is what we want.
|
||||||
return static_cast<__PTRDIFF_TYPE__> (vmi_offset_flags) >> offset_shift;
|
return static_cast<__PTRDIFF_TYPE__> (__offset_flags) >> offset_shift;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -264,8 +264,8 @@ public:
|
||||||
/* publicly) */
|
/* publicly) */
|
||||||
__contained_ambig, /* contained ambiguously */
|
__contained_ambig, /* contained ambiguously */
|
||||||
|
|
||||||
__contained_virtual_mask = __base_class_info::virtual_mask, /* via a virtual path */
|
__contained_virtual_mask = __base_class_info::__virtual_mask, /* via a virtual path */
|
||||||
__contained_public_mask = __base_class_info::public_mask, /* via a public path */
|
__contained_public_mask = __base_class_info::__public_mask, /* via a public path */
|
||||||
__contained_mask = 1 << __base_class_info::hwm_bit, /* contained within us */
|
__contained_mask = 1 << __base_class_info::hwm_bit, /* contained within us */
|
||||||
|
|
||||||
__contained_private = __contained_mask,
|
__contained_private = __contained_mask,
|
||||||
|
@ -334,8 +334,8 @@ class __si_class_type_info
|
||||||
: public __class_type_info
|
: public __class_type_info
|
||||||
{
|
{
|
||||||
/* abi defined member variables */
|
/* abi defined member variables */
|
||||||
protected:
|
public:
|
||||||
const __class_type_info *base; /* base type */
|
const __class_type_info *__base_type;
|
||||||
|
|
||||||
/* abi defined member functions */
|
/* abi defined member functions */
|
||||||
public:
|
public:
|
||||||
|
@ -343,7 +343,7 @@ public:
|
||||||
public:
|
public:
|
||||||
explicit __si_class_type_info (const char *__n,
|
explicit __si_class_type_info (const char *__n,
|
||||||
const __class_type_info *__base)
|
const __class_type_info *__base)
|
||||||
: __class_type_info (__n), base (__base)
|
: __class_type_info (__n), __base_type (__base)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/* implementation defined member functions */
|
/* implementation defined member functions */
|
||||||
|
@ -368,9 +368,9 @@ protected:
|
||||||
class __vmi_class_type_info : public __class_type_info {
|
class __vmi_class_type_info : public __class_type_info {
|
||||||
/* abi defined member variables */
|
/* abi defined member variables */
|
||||||
public:
|
public:
|
||||||
int vmi_flags; /* details about the class heirarchy */
|
unsigned int __flags; /* details about the class heirarchy */
|
||||||
int vmi_base_count; /* number of direct bases */
|
unsigned int __base_count; /* number of direct bases */
|
||||||
__base_class_info vmi_bases[1]; /* array of bases */
|
__base_class_info const __base_info[1]; /* array of bases */
|
||||||
/* The array of bases uses the trailing array struct hack
|
/* The array of bases uses the trailing array struct hack
|
||||||
so this class is not constructable with a normal constructor. It is
|
so this class is not constructable with a normal constructor. It is
|
||||||
internally generated by the compiler. */
|
internally generated by the compiler. */
|
||||||
|
@ -380,15 +380,15 @@ public:
|
||||||
virtual ~__vmi_class_type_info ();
|
virtual ~__vmi_class_type_info ();
|
||||||
public:
|
public:
|
||||||
explicit __vmi_class_type_info (const char *__n,
|
explicit __vmi_class_type_info (const char *__n,
|
||||||
int __flags)
|
int ___flags)
|
||||||
: __class_type_info (__n), vmi_flags (__flags), vmi_base_count (0)
|
: __class_type_info (__n), __flags (___flags), __base_count (0)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
/* implementation defined types */
|
/* implementation defined types */
|
||||||
public:
|
public:
|
||||||
enum vmi_flags_masks {
|
enum __flags_masks {
|
||||||
non_diamond_repeat_mask = 0x1, /* distinct instance of repeated base */
|
__non_diamond_repeat_mask = 0x1, /* distinct instance of repeated base */
|
||||||
diamond_shaped_mask = 0x2, /* diamond shaped multiple inheritance */
|
__diamond_shaped_mask = 0x2, /* diamond shaped multiple inheritance */
|
||||||
non_public_base_mask = 0x4, /* has non-public direct or indirect base */
|
non_public_base_mask = 0x4, /* has non-public direct or indirect base */
|
||||||
public_base_mask = 0x8, /* has public base (direct) */
|
public_base_mask = 0x8, /* has public base (direct) */
|
||||||
|
|
||||||
|
|
|
@ -755,7 +755,7 @@ __do_find_public_src (ptrdiff_t src2dst,
|
||||||
{
|
{
|
||||||
if (src_ptr == obj_ptr && *this == *src_type)
|
if (src_ptr == obj_ptr && *this == *src_type)
|
||||||
return __contained_public;
|
return __contained_public;
|
||||||
return base->__do_find_public_src (src2dst, obj_ptr, src_type, src_ptr);
|
return __base_type->__do_find_public_src (src2dst, obj_ptr, src_type, src_ptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
__class_type_info::__sub_kind __vmi_class_type_info::
|
__class_type_info::__sub_kind __vmi_class_type_info::
|
||||||
|
@ -767,14 +767,14 @@ __do_find_public_src (ptrdiff_t src2dst,
|
||||||
if (obj_ptr == src_ptr && *this == *src_type)
|
if (obj_ptr == src_ptr && *this == *src_type)
|
||||||
return __contained_public;
|
return __contained_public;
|
||||||
|
|
||||||
for (size_t i = vmi_base_count; i--;)
|
for (size_t i = __base_count; i--;)
|
||||||
{
|
{
|
||||||
if (!vmi_bases[i].__is_public_p ())
|
if (!__base_info[i].__is_public_p ())
|
||||||
continue; // Not public, can't be here.
|
continue; // Not public, can't be here.
|
||||||
|
|
||||||
const void *base = obj_ptr;
|
const void *base = obj_ptr;
|
||||||
ptrdiff_t offset = vmi_bases[i].__offset ();
|
ptrdiff_t offset = __base_info[i].__offset ();
|
||||||
bool is_virtual = vmi_bases[i].__is_virtual_p ();
|
bool is_virtual = __base_info[i].__is_virtual_p ();
|
||||||
|
|
||||||
if (is_virtual)
|
if (is_virtual)
|
||||||
{
|
{
|
||||||
|
@ -783,7 +783,7 @@ __do_find_public_src (ptrdiff_t src2dst,
|
||||||
}
|
}
|
||||||
base = convert_to_base (base, is_virtual, offset);
|
base = convert_to_base (base, is_virtual, offset);
|
||||||
|
|
||||||
__sub_kind base_kind = vmi_bases[i].base->__do_find_public_src
|
__sub_kind base_kind = __base_info[i].__base->__do_find_public_src
|
||||||
(src2dst, base, src_type, src_ptr);
|
(src2dst, base, src_type, src_ptr);
|
||||||
if (contained_p (base_kind))
|
if (contained_p (base_kind))
|
||||||
{
|
{
|
||||||
|
@ -849,7 +849,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
result.whole2src = access_path;
|
result.whole2src = access_path;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return base->__do_dyncast (src2dst, access_path, dst_type, obj_ptr,
|
return __base_type->__do_dyncast (src2dst, access_path, dst_type, obj_ptr,
|
||||||
src_type, src_ptr, result);
|
src_type, src_ptr, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -872,7 +872,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
__dyncast_result &__restrict result) const
|
__dyncast_result &__restrict result) const
|
||||||
{
|
{
|
||||||
if (result.whole_details & __flags_unknown_mask)
|
if (result.whole_details & __flags_unknown_mask)
|
||||||
result.whole_details = vmi_flags;
|
result.whole_details = __flags;
|
||||||
|
|
||||||
if (obj_ptr == src_ptr && *this == *src_type)
|
if (obj_ptr == src_ptr && *this == *src_type)
|
||||||
{
|
{
|
||||||
|
@ -894,23 +894,23 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
}
|
}
|
||||||
|
|
||||||
bool result_ambig = false;
|
bool result_ambig = false;
|
||||||
for (size_t i = vmi_base_count; i--;)
|
for (size_t i = __base_count; i--;)
|
||||||
{
|
{
|
||||||
__dyncast_result result2 (result.whole_details);
|
__dyncast_result result2 (result.whole_details);
|
||||||
void const *base = obj_ptr;
|
void const *base = obj_ptr;
|
||||||
__sub_kind base_access = access_path;
|
__sub_kind base_access = access_path;
|
||||||
ptrdiff_t offset = vmi_bases[i].__offset ();
|
ptrdiff_t offset = __base_info[i].__offset ();
|
||||||
bool is_virtual = vmi_bases[i].__is_virtual_p ();
|
bool is_virtual = __base_info[i].__is_virtual_p ();
|
||||||
|
|
||||||
if (is_virtual)
|
if (is_virtual)
|
||||||
base_access = __sub_kind (base_access | __contained_virtual_mask);
|
base_access = __sub_kind (base_access | __contained_virtual_mask);
|
||||||
base = convert_to_base (base, is_virtual, offset);
|
base = convert_to_base (base, is_virtual, offset);
|
||||||
|
|
||||||
if (!vmi_bases[i].__is_public_p ())
|
if (!__base_info[i].__is_public_p ())
|
||||||
{
|
{
|
||||||
if (src2dst == -2 &&
|
if (src2dst == -2 &&
|
||||||
!(result.whole_details
|
!(result.whole_details
|
||||||
& (non_diamond_repeat_mask | diamond_shaped_mask)))
|
& (__non_diamond_repeat_mask | __diamond_shaped_mask)))
|
||||||
// The hierarchy has no duplicate bases (which might ambiguate
|
// The hierarchy has no duplicate bases (which might ambiguate
|
||||||
// things) and where we started is not a public base of what we
|
// things) and where we started is not a public base of what we
|
||||||
// want (so it cannot be a downcast). There is nothing of interest
|
// want (so it cannot be a downcast). There is nothing of interest
|
||||||
|
@ -920,7 +920,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
}
|
}
|
||||||
|
|
||||||
bool result2_ambig
|
bool result2_ambig
|
||||||
= vmi_bases[i].base->__do_dyncast (src2dst, base_access,
|
= __base_info[i].__base->__do_dyncast (src2dst, base_access,
|
||||||
dst_type, base,
|
dst_type, base,
|
||||||
src_type, src_ptr, result2);
|
src_type, src_ptr, result2);
|
||||||
result.whole2src = __sub_kind (result.whole2src | result2.whole2src);
|
result.whole2src = __sub_kind (result.whole2src | result2.whole2src);
|
||||||
|
@ -942,7 +942,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
result.whole2dst = result2.whole2dst;
|
result.whole2dst = result2.whole2dst;
|
||||||
result_ambig = result2_ambig;
|
result_ambig = result2_ambig;
|
||||||
if (result.dst_ptr && result.whole2src != __unknown
|
if (result.dst_ptr && result.whole2src != __unknown
|
||||||
&& !(vmi_flags & non_diamond_repeat_mask))
|
&& !(__flags & __non_diamond_repeat_mask))
|
||||||
// Found dst and src and we don't have repeated bases.
|
// Found dst and src and we don't have repeated bases.
|
||||||
return result_ambig;
|
return result_ambig;
|
||||||
}
|
}
|
||||||
|
@ -969,7 +969,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
|
|
||||||
if (contained_p (result.whole2src)
|
if (contained_p (result.whole2src)
|
||||||
&& (!virtual_p (result.whole2src)
|
&& (!virtual_p (result.whole2src)
|
||||||
|| !(result.whole_details & diamond_shaped_mask)))
|
|| !(result.whole_details & __diamond_shaped_mask)))
|
||||||
{
|
{
|
||||||
// We already found SRC_PTR as a base of most derived, and
|
// We already found SRC_PTR as a base of most derived, and
|
||||||
// either it was non-virtual, or the whole heirarchy is
|
// either it was non-virtual, or the whole heirarchy is
|
||||||
|
@ -986,7 +986,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
;// already calculated
|
;// already calculated
|
||||||
else if (contained_p (new_sub_kind)
|
else if (contained_p (new_sub_kind)
|
||||||
&& (!virtual_p (new_sub_kind)
|
&& (!virtual_p (new_sub_kind)
|
||||||
|| !(vmi_flags & diamond_shaped_mask)))
|
|| !(__flags & __diamond_shaped_mask)))
|
||||||
// Already found inside the other choice, and it was
|
// Already found inside the other choice, and it was
|
||||||
// non-virtual or we are not diamond shaped.
|
// non-virtual or we are not diamond shaped.
|
||||||
old_sub_kind = __not_contained;
|
old_sub_kind = __not_contained;
|
||||||
|
@ -998,7 +998,7 @@ __do_dyncast (ptrdiff_t src2dst,
|
||||||
;// already calculated
|
;// already calculated
|
||||||
else if (contained_p (old_sub_kind)
|
else if (contained_p (old_sub_kind)
|
||||||
&& (!virtual_p (old_sub_kind)
|
&& (!virtual_p (old_sub_kind)
|
||||||
|| !(vmi_flags & diamond_shaped_mask)))
|
|| !(__flags & __diamond_shaped_mask)))
|
||||||
// Already found inside the other choice, and it was
|
// Already found inside the other choice, and it was
|
||||||
// non-virtual or we are not diamond shaped.
|
// non-virtual or we are not diamond shaped.
|
||||||
new_sub_kind = __not_contained;
|
new_sub_kind = __not_contained;
|
||||||
|
@ -1075,7 +1075,7 @@ __do_upcast (const __class_type_info *dst, const void *obj_ptr,
|
||||||
if (__class_type_info::__do_upcast (dst, obj_ptr, result))
|
if (__class_type_info::__do_upcast (dst, obj_ptr, result))
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
return base->__do_upcast (dst, obj_ptr, result);
|
return __base_type->__do_upcast (dst, obj_ptr, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool __vmi_class_type_info::
|
bool __vmi_class_type_info::
|
||||||
|
@ -1087,27 +1087,27 @@ __do_upcast (const __class_type_info *dst, const void *obj_ptr,
|
||||||
|
|
||||||
int src_details = result.src_details;
|
int src_details = result.src_details;
|
||||||
if (src_details & __flags_unknown_mask)
|
if (src_details & __flags_unknown_mask)
|
||||||
src_details = vmi_flags;
|
src_details = __flags;
|
||||||
|
|
||||||
for (size_t i = vmi_base_count; i--;)
|
for (size_t i = __base_count; i--;)
|
||||||
{
|
{
|
||||||
__upcast_result result2 (src_details);
|
__upcast_result result2 (src_details);
|
||||||
const void *base = obj_ptr;
|
const void *base = obj_ptr;
|
||||||
ptrdiff_t offset = vmi_bases[i].__offset ();
|
ptrdiff_t offset = __base_info[i].__offset ();
|
||||||
bool is_virtual = vmi_bases[i].__is_virtual_p ();
|
bool is_virtual = __base_info[i].__is_virtual_p ();
|
||||||
bool is_public = vmi_bases[i].__is_public_p ();
|
bool is_public = __base_info[i].__is_public_p ();
|
||||||
|
|
||||||
if (!is_public && !(src_details & non_diamond_repeat_mask))
|
if (!is_public && !(src_details & __non_diamond_repeat_mask))
|
||||||
// original cannot have an ambiguous base, so skip private bases
|
// original cannot have an ambiguous base, so skip private bases
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (base)
|
if (base)
|
||||||
base = convert_to_base (base, is_virtual, offset);
|
base = convert_to_base (base, is_virtual, offset);
|
||||||
|
|
||||||
if (vmi_bases[i].base->__do_upcast (dst, base, result2))
|
if (__base_info[i].__base->__do_upcast (dst, base, result2))
|
||||||
{
|
{
|
||||||
if (result2.base_type == nonvirtual_base_type && is_virtual)
|
if (result2.base_type == nonvirtual_base_type && is_virtual)
|
||||||
result2.base_type = vmi_bases[i].base;
|
result2.base_type = __base_info[i].__base;
|
||||||
if (contained_p (result2.part2dst) && !is_public)
|
if (contained_p (result2.part2dst) && !is_public)
|
||||||
result2.part2dst = __sub_kind (result2.part2dst & ~__contained_public_mask);
|
result2.part2dst = __sub_kind (result2.part2dst & ~__contained_public_mask);
|
||||||
|
|
||||||
|
@ -1119,14 +1119,14 @@ __do_upcast (const __class_type_info *dst, const void *obj_ptr,
|
||||||
|
|
||||||
if (result.part2dst & __contained_public_mask)
|
if (result.part2dst & __contained_public_mask)
|
||||||
{
|
{
|
||||||
if (!(vmi_flags & non_diamond_repeat_mask))
|
if (!(__flags & __non_diamond_repeat_mask))
|
||||||
return true; // cannot have an ambiguous other base
|
return true; // cannot have an ambiguous other base
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!virtual_p (result.part2dst))
|
if (!virtual_p (result.part2dst))
|
||||||
return true; // cannot have another path
|
return true; // cannot have another path
|
||||||
if (!(vmi_flags & diamond_shaped_mask))
|
if (!(__flags & __diamond_shaped_mask))
|
||||||
return true; // cannot have a more accessible path
|
return true; // cannot have a more accessible path
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -166,11 +166,11 @@ __do_catch (const type_info *thr_type,
|
||||||
const __pbase_type_info *thrown_type =
|
const __pbase_type_info *thrown_type =
|
||||||
static_cast <const __pbase_type_info *> (thr_type);
|
static_cast <const __pbase_type_info *> (thr_type);
|
||||||
|
|
||||||
if (thrown_type->quals & ~quals)
|
if (thrown_type->__qualifier_flags & ~__qualifier_flags)
|
||||||
// We're less qualified.
|
// We're less qualified.
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (!(quals & const_mask))
|
if (!(__qualifier_flags & __const_mask))
|
||||||
outer &= ~1;
|
outer &= ~1;
|
||||||
|
|
||||||
return __pointer_catch (thrown_type, thr_obj, outer);
|
return __pointer_catch (thrown_type, thr_obj, outer);
|
||||||
|
@ -181,7 +181,7 @@ __pointer_catch (const __pbase_type_info *thrown_type,
|
||||||
void **thr_obj,
|
void **thr_obj,
|
||||||
unsigned outer) const
|
unsigned outer) const
|
||||||
{
|
{
|
||||||
return type->__do_catch (thrown_type->type, thr_obj, outer + 2);
|
return __pointee->__do_catch (thrown_type->__pointee, thr_obj, outer + 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool __pointer_type_info::
|
bool __pointer_type_info::
|
||||||
|
@ -189,10 +189,10 @@ __pointer_catch (const __pbase_type_info *thrown_type,
|
||||||
void **thr_obj,
|
void **thr_obj,
|
||||||
unsigned outer) const
|
unsigned outer) const
|
||||||
{
|
{
|
||||||
if (outer < 2 && *type == typeid (void))
|
if (outer < 2 && *__pointee == typeid (void))
|
||||||
{
|
{
|
||||||
// conversion to void
|
// conversion to void
|
||||||
return !thrown_type->type->__is_function_p ();
|
return !thrown_type->__pointee->__is_function_p ();
|
||||||
}
|
}
|
||||||
|
|
||||||
return __pbase_type_info::__pointer_catch (thrown_type, thr_obj, outer);
|
return __pbase_type_info::__pointer_catch (thrown_type, thr_obj, outer);
|
||||||
|
@ -208,7 +208,7 @@ __pointer_catch (const __pbase_type_info *thr_type,
|
||||||
const __pointer_to_member_type_info *thrown_type =
|
const __pointer_to_member_type_info *thrown_type =
|
||||||
static_cast <const __pointer_to_member_type_info *> (thr_type);
|
static_cast <const __pointer_to_member_type_info *> (thr_type);
|
||||||
|
|
||||||
if (*klass != *thrown_type->klass)
|
if (*__context_class != *thrown_type->__context_class)
|
||||||
return false; // not pointers to member of same class
|
return false; // not pointers to member of same class
|
||||||
|
|
||||||
return __pbase_type_info::__pointer_catch (thrown_type, thr_obj, outer);
|
return __pbase_type_info::__pointer_catch (thrown_type, thr_obj, outer);
|
||||||
|
|
Loading…
Reference in New Issue