aboutsummaryrefslogtreecommitdiff
path: root/contrib/intarray
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/intarray')
-rw-r--r--contrib/intarray/_int_gist.c4
-rw-r--r--contrib/intarray/_int_tool.c8
2 files changed, 6 insertions, 6 deletions
diff --git a/contrib/intarray/_int_gist.c b/contrib/intarray/_int_gist.c
index 0a173bfcb66..0123906be88 100644
--- a/contrib/intarray/_int_gist.c
+++ b/contrib/intarray/_int_gist.c
@@ -357,10 +357,10 @@ typedef struct
static int
comparecost(const void *a, const void *b)
{
- if (((SPLITCOST *) a)->cost == ((SPLITCOST *) b)->cost)
+ if (((const SPLITCOST *) a)->cost == ((const SPLITCOST *) b)->cost)
return 0;
else
- return (((SPLITCOST *) a)->cost > ((SPLITCOST *) b)->cost) ? 1 : -1;
+ return (((const SPLITCOST *) a)->cost > ((const SPLITCOST *) b)->cost) ? 1 : -1;
}
/*
diff --git a/contrib/intarray/_int_tool.c b/contrib/intarray/_int_tool.c
index bfc55501dbc..79f018d333b 100644
--- a/contrib/intarray/_int_tool.c
+++ b/contrib/intarray/_int_tool.c
@@ -388,15 +388,15 @@ int_to_intset(int32 n)
int
compASC(const void *a, const void *b)
{
- if (*(int4 *) a == *(int4 *) b)
+ if (*(const int4 *) a == *(const int4 *) b)
return 0;
- return (*(int4 *) a > *(int4 *) b) ? 1 : -1;
+ return (*(const int4 *) a > *(const int4 *) b) ? 1 : -1;
}
int
compDESC(const void *a, const void *b)
{
- if (*(int4 *) a == *(int4 *) b)
+ if (*(const int4 *) a == *(const int4 *) b)
return 0;
- return (*(int4 *) a < *(int4 *) b) ? 1 : -1;
+ return (*(const int4 *) a < *(const int4 *) b) ? 1 : -1;
}