aboutsummaryrefslogtreecommitdiff
path: root/gcc/gimplify.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2005-08-11 17:12:30 +0000
committerRichard Henderson <rth@redhat.com>2005-08-11 17:12:30 +0000
commit4229d162c68bef334ccb9b0d5399defe3d407122 (patch)
treedc9d60066985f3f8081645e39f4558791fff0a50 /gcc/gimplify.c
parent7bbe1c2452684ad05965bfbab4f02d6af26d3c12 (diff)
PR middle-end/23312
* gimplify.c (gimplify_one_sizepos): Check for INTEGER_TYPE before using TYPE_IS_SIZETYPE. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@102997 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r--gcc/gimplify.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index d207e7c5546..a1ef22e0d2b 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -4634,7 +4634,9 @@ gimplify_one_sizepos (tree *expr_p, tree *stmt_p)
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;