aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/method.c
diff options
context:
space:
mode:
authorMark Mitchell <mmitchell@usa.net>1998-05-12 07:27:15 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>1998-05-12 07:27:15 +0000
commit7bc6a9ffaa55bd7593fe04984a46e2dc8f7175b5 (patch)
tree9613899c96d081c84ed98644d28a9d3859a3f9e4 /gcc/cp/method.c
parent07389efeea3381d2a710e0a8e4454a99d0f157cd (diff)
downloadgcc-7bc6a9ffaa55bd7593fe04984a46e2dc8f7175b5.zip
gcc-7bc6a9ffaa55bd7593fe04984a46e2dc8f7175b5.tar.gz
gcc-7bc6a9ffaa55bd7593fe04984a46e2dc8f7175b5.tar.bz2
cp-tree.h (CANONICAL_TYPE_VARIANT): New macro.
* cp-tree.h (CANONICAL_TYPE_VARIANT): New macro. * method.c (build_mangled_name): Use it. (build_decl_overload_real): Likewise. From-SVN: r19695
Diffstat (limited to 'gcc/cp/method.c')
-rw-r--r--gcc/cp/method.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/gcc/cp/method.c b/gcc/cp/method.c
index ef048f3..5ebcac9 100644
--- a/gcc/cp/method.c
+++ b/gcc/cp/method.c
@@ -1004,15 +1004,14 @@ build_mangled_name (parmtypes, begin, end)
{
if (TYPE_PTRMEMFUNC_P (parmtypes))
parmtypes = TYPE_PTRMEMFUNC_FN_TYPE (parmtypes);
+ parmtypes = CANONICAL_TYPE_VARIANT (parmtypes);
process_modifiers (parmtypes);
process_overload_item (parmtypes, FALSE);
}
else {
for ( ; parmtypes!=NULL; parmtypes = TREE_CHAIN (parmtypes))
{
- parmtype = TREE_VALUE (parmtypes);
- parmtype = build_type_variant (TYPE_MAIN_VARIANT (parmtype),
- TYPE_READONLY (parmtype), TYPE_VOLATILE (parmtype));
+ parmtype = CANONICAL_TYPE_VARIANT (TREE_VALUE (parmtypes));
if (flag_do_squangling) /* squangling style repeats */
{
if (parmtype == lasttype)
@@ -1612,8 +1611,7 @@ build_decl_overload_real (dname, parms, ret_type, tparms, targs,
tree temp = TREE_VALUE (t);
TREE_USED (temp) = 0;
/* clear out the type variant in case we used it */
- temp = build_type_variant (TYPE_MAIN_VARIANT (temp),
- TYPE_READONLY (temp), TYPE_VOLATILE (temp));
+ temp = CANONICAL_TYPE_VARIANT (temp);
TREE_USED (temp) = 0;
t = TREE_CHAIN (t);
}