summaryrefslogtreecommitdiff
path: root/gcc/go/go-gcc.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/go/go-gcc.cc')
-rw-r--r--gcc/go/go-gcc.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/go/go-gcc.cc b/gcc/go/go-gcc.cc
index 376e4dc5b49..50403e159ef 100644
--- a/gcc/go/go-gcc.cc
+++ b/gcc/go/go-gcc.cc
@@ -876,8 +876,7 @@ Gcc_backend::type_size(Btype* btype)
if (t == error_mark_node)
return 1;
t = TYPE_SIZE_UNIT(t);
- gcc_assert(TREE_CODE(t) == INTEGER_CST);
- gcc_assert(TREE_INT_CST_HIGH(t) == 0);
+ gcc_assert(tree_fits_uhwi_p (t));
unsigned HOST_WIDE_INT val_wide = TREE_INT_CST_LOW(t);
size_t ret = static_cast<size_t>(val_wide);
gcc_assert(ret == val_wide);