diff options
author | Andrew MacLeod <amacleod@redhat.com> | 2020-11-12 19:25:59 -0500 |
---|---|---|
committer | Andrew MacLeod <amacleod@redhat.com> | 2020-11-12 19:28:45 -0500 |
commit | ee24da1b983a89b05303f2ac8828dd8cbe28d3b4 (patch) | |
tree | abfe913cd3b691b5b7c000d6390103365fb1fa88 /gcc/range-op.cc | |
parent | a5a115258afd6c0bdd8ff4c8071dcffbafb88186 (diff) | |
download | gcc-ee24da1b983a89b05303f2ac8828dd8cbe28d3b4.zip gcc-ee24da1b983a89b05303f2ac8828dd8cbe28d3b4.tar.gz gcc-ee24da1b983a89b05303f2ac8828dd8cbe28d3b4.tar.bz2 |
Change range_handler, was Re: Fix gimple_expr_code?
Adjust the range_handler to not use gimple_expr_code/type.
* gimple-range.h (gimple_range_handler): Use gimple_assign and
gimple_cond routines to get type and code.
* range-op.cc (range_op_handler): Check for integral types.
Diffstat (limited to 'gcc/range-op.cc')
-rw-r--r-- | gcc/range-op.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/range-op.cc b/gcc/range-op.cc index aff9383..86d1af7 100644 --- a/gcc/range-op.cc +++ b/gcc/range-op.cc @@ -3341,10 +3341,12 @@ pointer_table::pointer_table () range_operator * range_op_handler (enum tree_code code, tree type) { - // First check if there is apointer specialization. + // First check if there is a pointer specialization. if (POINTER_TYPE_P (type)) return pointer_tree_table[code]; - return integral_tree_table[code]; + if (INTEGRAL_TYPE_P (type)) + return integral_tree_table[code]; + return NULL; } // Cast the range in R to TYPE. |