38 for (
i = n - 1;
i >= 0;
i--)
75 for (
i = 0;
i < ndim;
i++)
83 errmsg(
"array size exceeds the maximum allowed (%d)",
89 if ((
int64) ret != prod)
92 errmsg(
"array size exceeds the maximum allowed (%d)",
99 errmsg(
"array size exceeds the maximum allowed (%d)",
128 struct Node *escontext)
132 for (
i = 0;
i < ndim;
i++)
140 errmsg(
"array lower bound is too large: %d",
157 for (
i = 0;
i < n;
i++)
172 for (
i = n - 2;
i >= 0;
i--)
173 prod[
i] = prod[
i + 1] *
range[
i + 1];
189 for (
j = n - 2;
j >= 0;
j--)
192 for (
i =
j + 1;
i < n;
i++)
216 for (
i = n - 1;
i &&
curr[
i] == 0;
i--)
242 errmsg(
"typmod array must be type cstring[]")));
247 errmsg(
"typmod array must be one-dimensional")));
252 errmsg(
"typmod array must not contain nulls")));
258 for (
i = 0;
i < *n;
i++)
bool array_contains_nulls(const ArrayType *array)
void deconstruct_array_builtin(const ArrayType *array, Oid elmtype, Datum **elemsp, bool **nullsp, int *nelemsp)
void mda_get_offset_values(int n, int *dist, const int *prod, const int *span)
int ArrayGetNItemsSafe(int ndim, const int *dims, struct Node *escontext)
bool ArrayCheckBoundsSafe(int ndim, const int *dims, const int *lb, struct Node *escontext)
int ArrayGetOffset(int n, const int *dim, const int *lb, const int *indx)
void mda_get_range(int n, int *span, const int *st, const int *endp)
int ArrayGetNItems(int ndim, const int *dims)
void mda_get_prod(int n, const int *range, int *prod)
void ArrayCheckBounds(int ndim, const int *dims, const int *lb)
int mda_next_tuple(int n, int *curr, const int *span)
int32 * ArrayGetIntegerTypmods(ArrayType *arr, int *n)
#define PG_USED_FOR_ASSERTS_ONLY
#define Assert(condition)
int errcode(int sqlerrcode)
int errmsg(const char *fmt,...)
#define ereturn(context, dummy_value,...)
#define ereport(elevel,...)
static bool pg_add_s32_overflow(int32 a, int32 b, int32 *result)
void pfree(void *pointer)
int32 pg_strtoint32(const char *s)
static char * DatumGetCString(Datum X)
static struct cvec * range(struct vars *v, chr a, chr b, int cases)