fix 23312
Richard Henderson
rth@redhat.com
Thu Aug 11 17:14:00 GMT 2005
We use gimplify_one_sizepos for TYPE_MIN/MAX_VALUE as well,
which may have ENUMERAL_TYPE.
r~
* gimplify.c (gimplify_one_sizepos): Check for INTEGER_TYPE
before using TYPE_IS_SIZETYPE.
Index: gimplify.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/gimplify.c,v
retrieving revision 2.144
diff -u -p -d -r2.144 gimplify.c
--- gimplify.c 8 Aug 2005 21:38:24 -0000 2.144
+++ gimplify.c 11 Aug 2005 17:11:32 -0000
@@ -4634,7 +4634,9 @@ gimplify_one_sizepos (tree *expr_p, tree
type-stripping code with this knowledge because it doesn't matter
for the bulk of GENERIC/GIMPLE. It only matters that TYPE_SIZE_UNIT
and friends retain their "sizetype-ness". */
- if (TREE_TYPE (expr) != type && TYPE_IS_SIZETYPE (type))
+ if (TREE_TYPE (expr) != type
+ && TREE_CODE (type) == INTEGER_TYPE
+ && TYPE_IS_SIZETYPE (type))
{
tree tmp;
More information about the Gcc-patches
mailing list