summaryrefslogtreecommitdiff
path: root/gcc/tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree.c')
-rw-r--r--gcc/tree.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree.c b/gcc/tree.c
index ce4ee5d263f..95aa1b9e040 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -4936,7 +4936,8 @@ host_integerp (const_tree t, int pos)
&& (HOST_WIDE_INT) TREE_INT_CST_LOW (t) >= 0)
|| (! pos && TREE_INT_CST_HIGH (t) == -1
&& (HOST_WIDE_INT) TREE_INT_CST_LOW (t) < 0
- && !TYPE_UNSIGNED (TREE_TYPE (t)))
+ && (!TYPE_UNSIGNED (TREE_TYPE (t))
+ || TYPE_IS_SIZETYPE (TREE_TYPE (t))))
|| (pos && TREE_INT_CST_HIGH (t) == 0)));
}