projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use macros from cast.h instead of literal casts
[pspp]
/
src
/
libpspp
/
range-set.c
diff --git
a/src/libpspp/range-set.c
b/src/libpspp/range-set.c
index efa3b4d670e7e06c3c560ebc64ade1bf4d45ae21..cd17fe02a4e2130544d5d37687cf46210ff2de39 100644
(file)
--- a/
src/libpspp/range-set.c
+++ b/
src/libpspp/range-set.c
@@
-287,7
+287,7
@@
range_set_allocate_fully (struct range_set *rs, unsigned long int request,
bool
range_set_contains (const struct range_set *rs_, unsigned long int position)
{
bool
range_set_contains (const struct range_set *rs_, unsigned long int position)
{
- struct range_set *rs =
(struct range_set *) rs_
;
+ struct range_set *rs =
CONST_CAST (struct range_set *, rs_)
;
if (position < rs->cache_end && position >= rs->cache_start)
return rs->cache_value;
else
if (position < rs->cache_end && position >= rs->cache_start)
return rs->cache_value;
else
@@
-328,7
+328,7
@@
range_set_contains (const struct range_set *rs_, unsigned long int position)
unsigned long int
range_set_scan (const struct range_set *rs_, unsigned long int start)
{
unsigned long int
range_set_scan (const struct range_set *rs_, unsigned long int start)
{
- struct range_set *rs =
(struct range_set *) rs_
;
+ struct range_set *rs =
CONST_CAST (struct range_set *, rs_)
;
unsigned long int retval = ULONG_MAX;
struct bt_node *bt_node;
unsigned long int retval = ULONG_MAX;
struct bt_node *bt_node;