mirror of
https://github.com/postgres/postgres.git
synced 2025-10-21 02:52:47 +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:
@@ -204,7 +204,7 @@ extern IndexScanDesc RelationGetIndexScan(Relation indexRelation,
|
||||
int nkeys, int norderbys);
|
||||
extern void IndexScanEnd(IndexScanDesc scan);
|
||||
extern char *BuildIndexValueDescription(Relation indexRelation,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern TransactionId index_compute_xid_horizon_for_tuples(Relation irel,
|
||||
Relation hrel,
|
||||
Buffer ibuf,
|
||||
|
@@ -502,9 +502,9 @@ extern IndexTuple gistgetadjusted(Relation r,
|
||||
IndexTuple addtup,
|
||||
GISTSTATE *giststate);
|
||||
extern IndexTuple gistFormTuple(GISTSTATE *giststate,
|
||||
Relation r, Datum *attdata, bool *isnull, bool isleaf);
|
||||
Relation r, const Datum *attdata, const bool *isnull, bool isleaf);
|
||||
extern void gistCompressValues(GISTSTATE *giststate, Relation r,
|
||||
Datum *attdata, bool *isnull, bool isleaf, Datum *compatt);
|
||||
const Datum *attdata, const bool *isnull, bool isleaf, Datum *compatt);
|
||||
|
||||
extern OffsetNumber gistchoose(Relation r, Page p,
|
||||
IndexTuple it,
|
||||
|
@@ -451,7 +451,7 @@ typedef struct HSpool HSpool; /* opaque struct in hashsort.c */
|
||||
extern HSpool *_h_spoolinit(Relation heap, Relation index, uint32 num_buckets);
|
||||
extern void _h_spooldestroy(HSpool *hspool);
|
||||
extern void _h_spool(HSpool *hspool, ItemPointer self,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern void _h_indexbuild(HSpool *hspool, Relation heapRel);
|
||||
|
||||
/* hashutil.c */
|
||||
|
@@ -696,9 +696,9 @@ struct MinimalTupleData
|
||||
|
||||
/* prototypes for functions in common/heaptuple.c */
|
||||
extern Size heap_compute_data_size(TupleDesc tupleDesc,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern void heap_fill_tuple(TupleDesc tupleDesc,
|
||||
Datum *values, bool *isnull,
|
||||
const Datum *values, const bool *isnull,
|
||||
char *data, Size data_size,
|
||||
uint16 *infomask, bits8 *bit);
|
||||
extern bool heap_attisnull(HeapTuple tup, int attnum, TupleDesc tupleDesc);
|
||||
@@ -712,23 +712,23 @@ extern HeapTuple heap_copytuple(HeapTuple tuple);
|
||||
extern void heap_copytuple_with_tuple(HeapTuple src, HeapTuple dest);
|
||||
extern Datum heap_copy_tuple_as_datum(HeapTuple tuple, TupleDesc tupleDesc);
|
||||
extern HeapTuple heap_form_tuple(TupleDesc tupleDescriptor,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern HeapTuple heap_modify_tuple(HeapTuple tuple,
|
||||
TupleDesc tupleDesc,
|
||||
Datum *replValues,
|
||||
bool *replIsnull,
|
||||
bool *doReplace);
|
||||
const Datum *replValues,
|
||||
const bool *replIsnull,
|
||||
const bool *doReplace);
|
||||
extern HeapTuple heap_modify_tuple_by_cols(HeapTuple tuple,
|
||||
TupleDesc tupleDesc,
|
||||
int nCols,
|
||||
int *replCols,
|
||||
Datum *replValues,
|
||||
bool *replIsnull);
|
||||
const int *replCols,
|
||||
const Datum *replValues,
|
||||
const bool *replIsnull);
|
||||
extern void heap_deform_tuple(HeapTuple tuple, TupleDesc tupleDesc,
|
||||
Datum *values, bool *isnull);
|
||||
extern void heap_freetuple(HeapTuple htup);
|
||||
extern MinimalTuple heap_form_minimal_tuple(TupleDesc tupleDescriptor,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern void heap_free_minimal_tuple(MinimalTuple mtup);
|
||||
extern MinimalTuple heap_copy_minimal_tuple(MinimalTuple mtup);
|
||||
extern HeapTuple heap_tuple_from_minimal_tuple(MinimalTuple mtup);
|
||||
|
@@ -75,9 +75,9 @@ typedef IndexAttributeBitMapData * IndexAttributeBitMap;
|
||||
|
||||
/* routines in indextuple.c */
|
||||
extern IndexTuple index_form_tuple(TupleDesc tupleDescriptor,
|
||||
Datum *values, bool *isnull);
|
||||
const Datum *values, const bool *isnull);
|
||||
extern IndexTuple index_form_tuple_context(TupleDesc tupleDescriptor,
|
||||
Datum *values, bool *isnull,
|
||||
const Datum *values, const bool *isnull,
|
||||
MemoryContext context);
|
||||
extern Datum nocache_index_getattr(IndexTuple tup, int attnum,
|
||||
TupleDesc tupleDesc);
|
||||
|
@@ -506,10 +506,10 @@ extern void SpGistInitBuffer(Buffer b, uint16 f);
|
||||
extern void SpGistInitMetapage(Page page);
|
||||
extern unsigned int SpGistGetInnerTypeSize(SpGistTypeDesc *att, Datum datum);
|
||||
extern Size SpGistGetLeafTupleSize(TupleDesc tupleDescriptor,
|
||||
Datum *datums, bool *isnulls);
|
||||
const Datum *datums, const bool *isnulls);
|
||||
extern SpGistLeafTuple spgFormLeafTuple(SpGistState *state,
|
||||
ItemPointer heapPtr,
|
||||
Datum *datums, bool *isnulls);
|
||||
const Datum *datums, const bool *isnulls);
|
||||
extern SpGistNodeTuple spgFormNodeTuple(SpGistState *state,
|
||||
Datum label, bool isnull);
|
||||
extern SpGistInnerTuple spgFormInnerTuple(SpGistState *state,
|
||||
|
@@ -110,7 +110,7 @@ extern void toast_tuple_externalize(ToastTupleContext *ttc, int attribute,
|
||||
int options);
|
||||
extern void toast_tuple_cleanup(ToastTupleContext *ttc);
|
||||
|
||||
extern void toast_delete_external(Relation rel, Datum *values, bool *isnull,
|
||||
extern void toast_delete_external(Relation rel, const Datum *values, const bool *isnull,
|
||||
bool is_speculative);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user