mirror of
https://github.com/postgres/postgres.git
synced 2025-11-22 12:22:45 +03:00
Add const to values and nulls arguments
This excludes any changes that would change the external AM APIs. Reviewed-by: Aleksander Alekseev <aleksander@timescale.com> Discussion: https://www.postgresql.org/message-id/flat/14c31f4a-0347-0805-dce8-93a9072c05a5%40eisentraut.org
This commit is contained in:
@@ -42,8 +42,8 @@
|
||||
*/
|
||||
IndexTuple
|
||||
index_form_tuple(TupleDesc tupleDescriptor,
|
||||
Datum *values,
|
||||
bool *isnull)
|
||||
const Datum *values,
|
||||
const bool *isnull)
|
||||
{
|
||||
return index_form_tuple_context(tupleDescriptor, values, isnull,
|
||||
CurrentMemoryContext);
|
||||
@@ -63,8 +63,8 @@ index_form_tuple(TupleDesc tupleDescriptor,
|
||||
*/
|
||||
IndexTuple
|
||||
index_form_tuple_context(TupleDesc tupleDescriptor,
|
||||
Datum *values,
|
||||
bool *isnull,
|
||||
const Datum *values,
|
||||
const bool *isnull,
|
||||
MemoryContext context)
|
||||
{
|
||||
char *tp; /* tuple pointer */
|
||||
@@ -79,8 +79,8 @@ index_form_tuple_context(TupleDesc tupleDescriptor,
|
||||
int numberOfAttributes = tupleDescriptor->natts;
|
||||
|
||||
#ifdef TOAST_INDEX_HACK
|
||||
Datum untoasted_values[INDEX_MAX_KEYS];
|
||||
bool untoasted_free[INDEX_MAX_KEYS];
|
||||
Datum untoasted_values[INDEX_MAX_KEYS] = {0};
|
||||
bool untoasted_free[INDEX_MAX_KEYS] = {0};
|
||||
#endif
|
||||
|
||||
if (numberOfAttributes > INDEX_MAX_KEYS)
|
||||
|
||||
Reference in New Issue
Block a user