diff options
author | Kenneth Graunke <[email protected]> | 2019-04-05 11:52:59 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2019-04-07 00:21:12 -0700 |
commit | 4e802089bcfa278f414fb3a0ce5879d840526691 (patch) | |
tree | 086eecad02db0447a549b2c1acc656d2d5f51ceb | |
parent | c5a6e72e15b67b37e5b2e35721261ec3da60c045 (diff) |
gallium/util: Add const to u_range_intersect
This doesn't modify the range, so it can accept a const pointer.
Reviewed-by: Eric Engestrom <[email protected]>
-rw-r--r-- | src/gallium/auxiliary/util/u_range.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_range.h b/src/gallium/auxiliary/util/u_range.h index 7d3fc61aa32..cbf855a2c57 100644 --- a/src/gallium/auxiliary/util/u_range.h +++ b/src/gallium/auxiliary/util/u_range.h @@ -67,7 +67,8 @@ util_range_add(struct util_range *range, unsigned start, unsigned end) } static inline boolean -util_ranges_intersect(struct util_range *range, unsigned start, unsigned end) +util_ranges_intersect(const struct util_range *range, + unsigned start, unsigned end) { return MAX2(start, range->start) < MIN2(end, range->end); } |