diff options
Diffstat (limited to 'gcc/java')
-rw-r--r-- | gcc/java/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/java/class.c | 2 | ||||
-rw-r--r-- | gcc/java/expr.c | 4 |
3 files changed, 8 insertions, 3 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index a474ccc..01d50f2 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,8 @@ +2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> + + * class.c, expr.c: Replace host_integerp (..., 0) with + tree_fits_shwi_p throughout. + 2013-11-14 Andrew MacLeod <amacleod@redhat.com> * java-gimplify.c: Include only gimplify.h and gimple.h as needed. diff --git a/gcc/java/class.c b/gcc/java/class.c index cb67896..5eb245e 100644 --- a/gcc/java/class.c +++ b/gcc/java/class.c @@ -1592,7 +1592,7 @@ get_dispatch_vector (tree type) { tree method_index = get_method_index (method); if (method_index != NULL_TREE - && host_integerp (method_index, 0)) + && tree_fits_shwi_p (method_index)) TREE_VEC_ELT (vtable, tree_low_cst (method_index, 0)) = method; } } diff --git a/gcc/java/expr.c b/gcc/java/expr.c index a434913..0720065 100644 --- a/gcc/java/expr.c +++ b/gcc/java/expr.c @@ -1049,7 +1049,7 @@ build_newarray (int atype_value, tree length) tree prim_type = decode_newarray_type (atype_value); tree type = build_java_array_type (prim_type, - host_integerp (length, 0) == INTEGER_CST + tree_fits_shwi_p (length) == INTEGER_CST ? tree_low_cst (length, 0) : -1); /* Pass a reference to the primitive type class and save the runtime @@ -1069,7 +1069,7 @@ build_anewarray (tree class_type, tree length) { tree type = build_java_array_type (class_type, - host_integerp (length, 0) + tree_fits_shwi_p (length) ? tree_low_cst (length, 0) : -1); return build_call_nary (promote_type (type), |