projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c5a6e72
)
gallium/util: Add const to u_range_intersect
author
Kenneth Graunke
<kenneth@whitecape.org>
Fri, 5 Apr 2019 18:52:59 +0000
(11:52 -0700)
committer
Kenneth Graunke
<kenneth@whitecape.org>
Sun, 7 Apr 2019 07:21:12 +0000
(
00:21
-0700)
This doesn't modify the range, so it can accept a const pointer.
Reviewed-by: Eric Engestrom <eric.engestrom@intel.com>
src/gallium/auxiliary/util/u_range.h
patch
|
blob
|
history
diff --git
a/src/gallium/auxiliary/util/u_range.h
b/src/gallium/auxiliary/util/u_range.h
index 7d3fc61aa328e2c2c44dc63f9c647d5de67fe30f..cbf855a2c573546b6d99deb69ad0d6e0233bf1a9 100644
(file)
--- 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);
}