summaryrefslogtreecommitdiff
path: root/gcc/cp/tinfo.cc
diff options
context:
space:
mode:
authornathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-01-20 11:05:19 +0000
committernathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-01-20 11:05:19 +0000
commit0d79541b78b9d1b1aa331d0529d48ede4582a613 (patch)
treeadda0800d4ed48ea9cf1709bae1b8f19597984ee /gcc/cp/tinfo.cc
parent64103446f6f90ba264639fa3bf63ca8604cfe1fc (diff)
downloadgcc-0d79541b78b9d1b1aa331d0529d48ede4582a613.tar.gz
Remap dynamic cast hint values to be consistent across ABIs.
* search.c (dynamic_cast_base_recurse): Remap generated value. (get_dynamic_cast_base_type): Adjust documentation. * tinfo.h (__user_type_info::dyncast): Likewise. (__user_type_info::find_public_subobj): Remap BOFF meaning. * tinfo.cc (__si_type_info::do_dyncast): Remap BOFF meaning. (__class_type_info::do_dyncast): Likewise. (__class_type_info::do_find_public_subobj): Likewise. * tinfo2.cc (__dynamic_cast): Remap BOFF parameter. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31538 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/tinfo.cc')
-rw-r--r--gcc/cp/tinfo.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/cp/tinfo.cc b/gcc/cp/tinfo.cc
index 18a00b0b19a..1ad584070b7 100644
--- a/gcc/cp/tinfo.cc
+++ b/gcc/cp/tinfo.cc
@@ -243,7 +243,7 @@ do_dyncast (int boff, sub_kind access_path,
if (boff >= 0)
result.target2sub = ((char *)subptr - (char *)objptr) == boff
? contained_public : not_contained;
- else if (boff == -3)
+ else if (boff == -2)
result.target2sub = not_contained;
return false;
}
@@ -361,7 +361,7 @@ do_dyncast (int boff, sub_kind access_path,
if (boff >= 0)
result.target2sub = ((char *)subptr - (char *)objptr) == boff
? contained_public : not_contained;
- else if (boff == -3)
+ else if (boff == -2)
result.target2sub = not_contained;
return false;
}
@@ -519,7 +519,7 @@ do_find_public_subobj (int boff, const type_info &subtype, void *objptr, void *s
continue; // Not public, can't be here.
void *p;
- if (base_list[i].is_virtual && boff == -1)
+ if (base_list[i].is_virtual && boff == -3)
// Not a virtual base, so can't be here.
continue;