From: Martin v. Löwis Date: Thu, 4 Jun 1998 01:35:57 +0000 (-0400) Subject: * decl2.c (arg_assoc_type): Process unknown_type_node and OFFSET_TYPE. X-Git-Tag: prereleases/egcs-1.1-prerelease~938 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1813dd7bdda13acd52ff7856b6a3e200b28836d8;p=thirdparty%2Fgcc.git * decl2.c (arg_assoc_type): Process unknown_type_node and OFFSET_TYPE. From-SVN: r20219 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index d14af5954785..edb5ac75708b 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -4,14 +4,12 @@ 1998-06-04 Martin von Löwis + * decl2.c (arg_assoc_type): Process unknown_type_node and OFFSET_TYPE. + * tree.c (mapcar): Support NEW_EXPR. * error.c (dump_expr): Support NEW_EXPR. -1998-06-04 Jason Merrill - - * decl2.c (arg_assoc_type): Return 0 for LANG_TYPE. - 1998-06-03 Jason Merrill * method.c (make_thunk): Use overload machinery to make name. diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index dc800da4b851..bc49bc345b8b 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -4208,7 +4208,6 @@ arg_assoc_type (k, type) case COMPLEX_TYPE: case CHAR_TYPE: case BOOLEAN_TYPE: - case LANG_TYPE: return 0; case RECORD_TYPE: if (TYPE_PTRMEMFUNC_P (type)) @@ -4221,6 +4220,11 @@ arg_assoc_type (k, type) case UNION_TYPE: case ENUMERAL_TYPE: return arg_assoc_namespace (k, decl_namespace (TYPE_MAIN_DECL (type))); + case OFFSET_TYPE: + /* Pointer to member: associate class type and value type. */ + if (arg_assoc_type (k, TYPE_OFFSET_BASETYPE (type))) + return 1; + return arg_assoc_type (k, TREE_TYPE (type)); case METHOD_TYPE: /* Associate the class of the method. */ if (arg_assoc_type (k, TYPE_METHOD_BASETYPE (type))) @@ -4232,6 +4236,10 @@ arg_assoc_type (k, type) return 1; /* Associate the return type. */ return arg_assoc_type (k, TREE_TYPE (type)); + case LANG_TYPE: + if (type == unknown_type_node) + return 0; + /* else fall through */ default: my_friendly_abort (390); }