aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/rtti.c
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@codesourcery.com>2000-06-20 15:42:55 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2000-06-20 15:42:55 +0000
commitb72801e28a38c16cfc83c49af2ce54e8aa4b9e6f (patch)
tree1a84c7dc8a7a8ad8d466243edf26fc63e7d0d63c /gcc/cp/rtti.c
parent5ea634c774afe595d5933b61312e357bbf4d50a0 (diff)
downloadgcc-b72801e28a38c16cfc83c49af2ce54e8aa4b9e6f.zip
gcc-b72801e28a38c16cfc83c49af2ce54e8aa4b9e6f.tar.gz
gcc-b72801e28a38c16cfc83c49af2ce54e8aa4b9e6f.tar.bz2
call.c (build_conditional_expr): Use VOID_TYPE_P.
* call.c (build_conditional_expr): Use VOID_TYPE_P. * cvt.c (cp_convert_to_pointer): Likewise. (convert_to_void): Likewise. * error.c (dump_expr): Likewise. * except.c (complete_ptr_ref_or_void_ptr_p): Likewise. * init.c (build_delete): Likewise. * method.c (emit_thunk): Likewise. * optmize.c (declare_return_variable): Likewise. * rtti.c (get_tinfo_decl_dynamic): Likewise. (get_typeid): Likewise. (build_dynamic_cast_1): Likewise. * typeck.c (composite_pointer_type): Likewise. (common_type): Likewise. (build_indirect_ref): Likewise. (build_binary_op): Likewise. (build_x_compound_expr): Likewise. (check_return_expr): Likewise. * typeck2.c (add_exception_specifier): Likewise. * mangle.c (write_method_parms): Use direct comparison for end of parmlist. From-SVN: r34617
Diffstat (limited to 'gcc/cp/rtti.c')
-rw-r--r--gcc/cp/rtti.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/gcc/cp/rtti.c b/gcc/cp/rtti.c
index 3dd1845..8bf17d9 100644
--- a/gcc/cp/rtti.c
+++ b/gcc/cp/rtti.c
@@ -233,7 +233,7 @@ get_tinfo_decl_dynamic (exp)
/* Peel off cv qualifiers. */
type = TYPE_MAIN_VARIANT (type);
- if (type != void_type_node)
+ if (!VOID_TYPE_P (type))
type = complete_type_or_else (type, exp);
if (!type)
@@ -513,7 +513,7 @@ get_typeid (type)
that is the operand of typeid are always ignored. */
type = TYPE_MAIN_VARIANT (type);
- if (type != void_type_node)
+ if (!VOID_TYPE_P (type))
type = complete_type_or_else (type, NULL_TREE);
if (!type)
@@ -702,8 +702,7 @@ build_dynamic_cast_1 (type, expr)
{
tree expr1;
/* if TYPE is `void *', return pointer to complete object. */
- if (tc == POINTER_TYPE
- && TYPE_MAIN_VARIANT (TREE_TYPE (type)) == void_type_node)
+ if (tc == POINTER_TYPE && VOID_TYPE_P (TREE_TYPE (type)))
{
/* if b is an object, dynamic_cast<void *>(&b) == (void *)&b. */
if (TREE_CODE (expr) == ADDR_EXPR