From 174bcdb9152cb55d3eb7855e789b14cd1031c440 Mon Sep 17 00:00:00 2001 From: Mark Mitchell Date: Wed, 4 Nov 1998 21:54:29 +0000 Subject: cp-tree.h (CP_TYPE_CONST_P): Make {0,1}-valued. * cp-tree.h (CP_TYPE_CONST_P): Make {0,1}-valued. (CP_TYPE_VOLATILE_P): Likewise. (CP_TYPE_RESTRICT_P): Likewise. From-SVN: r23530 --- gcc/cp/ChangeLog | 6 ++++++ gcc/cp/cp-tree.h | 9 ++++----- 2 files changed, 10 insertions(+), 5 deletions(-) (limited to 'gcc') diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 7228607..9bc821c 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,9 @@ +1998-11-04 Mark Mitchell + + * cp-tree.h (CP_TYPE_CONST_P): Make {0,1}-valued. + (CP_TYPE_VOLATILE_P): Likewise. + (CP_TYPE_RESTRICT_P): Likewise. + 1998-11-03 Mark Mitchell * pt.c (tsubst): Use build_index_type, not build_index_2_type. diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h index 3f24653..e55766f 100644 --- a/gcc/cp/cp-tree.h +++ b/gcc/cp/cp-tree.h @@ -546,16 +546,15 @@ enum languages { lang_c, lang_cplusplus, lang_java }; /* Nonzero if this type is const-qualified. */ #define CP_TYPE_CONST_P(NODE) \ - (CP_TYPE_QUALS (NODE) & TYPE_QUAL_CONST) + ((CP_TYPE_QUALS (NODE) & TYPE_QUAL_CONST) != 0) /* Nonzero if this type is volatile-qualified. */ #define CP_TYPE_VOLATILE_P(NODE) \ - (CP_TYPE_QUALS (NODE) & TYPE_QUAL_VOLATILE) + ((CP_TYPE_QUALS (NODE) & TYPE_QUAL_VOLATILE) != 0) -/* Nonzero if this type is restrict-qualified. - FIXME: Does this make sense? */ +/* Nonzero if this type is restrict-qualified. */ #define CP_TYPE_RESTRICT_P(NODE) \ - (CP_TYPE_QUALS (NODE) & TYPE_QUAL_RESTRICT) + ((CP_TYPE_QUALS (NODE) & TYPE_QUAL_RESTRICT) != 0) /* Nonzero if this type is const-qualified, but not volatile-qualified. Other qualifiers are ignored. This macro is -- cgit v1.1