aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Mitchell <mark@markmitchell.com>1998-08-25 11:34:22 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>1998-08-25 11:34:22 +0000
commitb80c4d770ac87e627f75bd758b4d9b9b881fff96 (patch)
tree882f6fbf8d05acc963c3b29b7968c046ec32b85f
parent56a65848be386e259d3af5b099afbe83d078d6db (diff)
downloadgcc-b80c4d770ac87e627f75bd758b4d9b9b881fff96.zip
gcc-b80c4d770ac87e627f75bd758b4d9b9b881fff96.tar.gz
gcc-b80c4d770ac87e627f75bd758b4d9b9b881fff96.tar.bz2
* cp-tree.h (CLASS_TYPE_P): Revise definition.
From-SVN: r21965
-rw-r--r--gcc/cp/ChangeLog4
-rw-r--r--gcc/cp/cp-tree.h11
2 files changed, 10 insertions, 5 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 5a60b49..1fd7317 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,7 @@
+1998-08-25 Mark Mitchell <mark@markmitchell.com>
+
+ * cp-tree.h (CLASS_TYPE_P): Revise definition.
+
1998-08-25 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (duplicate_decls): Don't complain about different
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h
index 993628a..a22a5ad 100644
--- a/gcc/cp/cp-tree.h
+++ b/gcc/cp/cp-tree.h
@@ -499,14 +499,15 @@ enum languages { lang_c, lang_cplusplus, lang_java };
#define TYPE_MAIN_DECL(NODE) (TYPE_STUB_DECL (TYPE_MAIN_VARIANT (NODE)))
/* Nonzero if T is a class (or struct or union) type. Also nonzero
- for template type parameters. Despite its name, this macro has
- nothing to do with the definition of aggregate given in the
- standard. Think of this macro as MAYBE_CLASS_TYPE_P. */
+ for template type parameters and typename types. Despite its name,
+ this macro has nothing to do with the definition of aggregate given
+ in the standard. Think of this macro as MAYBE_CLASS_TYPE_P. */
#define IS_AGGR_TYPE(t) (TYPE_LANG_FLAG_5 (t))
-/* Nonzero if T is a class type. Zero for template type parameters. */
+/* Nonzero if T is a class type. Zero for template type parameters,
+ typename types, and so forth. */
#define CLASS_TYPE_P(t) \
- (IS_AGGR_TYPE (t) && TREE_CODE (t) != TEMPLATE_TYPE_PARM)
+ (IS_AGGR_TYPE (t) && IS_AGGR_TYPE_CODE (TREE_CODE (t)))
#define IS_AGGR_TYPE_CODE(t) (t == RECORD_TYPE || t == UNION_TYPE)
#define IS_AGGR_TYPE_2(TYPE1,TYPE2) \