From d4bf484274df326c2f01784f3b6beff6796bb1e3 Mon Sep 17 00:00:00 2001 From: Jason Merrill Date: Mon, 31 Jan 2000 12:20:39 -0500 Subject: [PATCH] tinfo.h: Rename USItype to myint32, depend on BITS_PER_UNIT. * tinfo.h: Rename USItype to myint32, depend on BITS_PER_UNIT. * exception.cc (__throw_bad_typeid): Add missing std::. From-SVN: r31718 --- gcc/cp/ChangeLog | 9 +++++++++ gcc/cp/exception.cc | 2 +- gcc/cp/tinfo.h | 13 +++++++++---- 3 files changed, 19 insertions(+), 5 deletions(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 253a60e..2969fe4 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,12 @@ +2000-01-31 Herman A.J. ten Brugge + Jason Merrill + + * tinfo.h: Rename USItype to myint32, depend on BITS_PER_UNIT. + +2000-01-31 Alfred Minarik + + * exception.cc (__throw_bad_typeid): Add missing std::. + 2000-01-31 Kaveh R. Ghazi * cp-tree.h (make_thunk): PROTO -> PARAMS. diff --git a/gcc/cp/exception.cc b/gcc/cp/exception.cc index 0c806e6..82bc5f9 100644 --- a/gcc/cp/exception.cc +++ b/gcc/cp/exception.cc @@ -331,7 +331,7 @@ __throw_bad_cast () return 0; } -extern "C" type_info const & +extern "C" std::type_info const & __throw_bad_typeid () { throw std::bad_typeid (); diff --git a/gcc/cp/tinfo.h b/gcc/cp/tinfo.h index 2894ed6..4753e71 100644 --- a/gcc/cp/tinfo.h +++ b/gcc/cp/tinfo.h @@ -170,14 +170,21 @@ public: // type_info for a general class. -typedef int USItype __attribute__ ((mode (SI))); +// Kludge, kludge, kludge. +#if BITS_PER_UNIT == 8 +typedef int myint32 __attribute__ ((mode (SI))); +#elif BITS_PER_UNIT == 16 +typedef int myint32 __attribute__ ((mode (HI))); +#elif BITS_PER_UNIT == 32 +typedef int myint32 __attribute__ ((mode (QI))); +#endif struct __class_type_info : public __user_type_info { enum access { PUBLIC = 1, PROTECTED = 2, PRIVATE = 3 }; struct base_info { const __user_type_info *base; - USItype offset: 29; + myint32 offset: 29; bool is_virtual: 1; enum access access: 2; }; @@ -203,8 +210,6 @@ struct __class_type_info : public __user_type_info { // new abi #include "stddef.h" -typedef int USItype __attribute__ ((mode (SI))); - namespace std { class __class_type_info; -- 2.7.4