From 969df93f1e1d315a119bb8ba3d2e9195e5d322da Mon Sep 17 00:00:00 2001 From: Nathan Sidwell Date: Thu, 6 May 1999 03:09:52 +0000 Subject: [PATCH] * call.c (build_new_method_call): Use TYPE_MAIN_VARIANT of class. From-SVN: r26801 --- gcc/cp/ChangeLog | 4 ++++ gcc/cp/call.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index be5b930e553..5d1c6a3f869 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +1999-05-06 Nathan Sidwell + + * call.c (build_new_method_call): Use TYPE_MAIN_VARIANT of class. + 1999-05-05 Mark Mitchell * decl2.c (start_objects): Don't let static constructors and diff --git a/gcc/cp/call.c b/gcc/cp/call.c index 7a20421e2b2..1dccabcf102 100644 --- a/gcc/cp/call.c +++ b/gcc/cp/call.c @@ -3559,7 +3559,7 @@ build_new_method_call (instance, name, args, basetype_path, flags) instance = resolve_offset_ref (instance); if (TREE_CODE (TREE_TYPE (instance)) == REFERENCE_TYPE) instance = convert_from_reference (instance); - basetype = TREE_TYPE (instance); + basetype = TYPE_MAIN_VARIANT (TREE_TYPE (instance)); /* XXX this should be handled before we get here. */ if (! IS_AGGR_TYPE (basetype) -- 2.30.2