1
0
mirror of https://github.com/postgres/postgres.git synced 2026-01-26 09:41:40 +03:00

Change some Datum to void * for opaque pass-through pointer

Here, Datum was used to pass around an opaque pointer between a group
of functions.  But one might as well use void * for that; the use of
Datum doesn't achieve anything here and is just distracting.

Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://www.postgresql.org/message-id/flat/1c5d23cb-288b-4154-b1cd-191fe2301707%40eisentraut.org
This commit is contained in:
Peter Eisentraut
2025-12-28 14:34:12 +01:00
parent 9adf32da6b
commit b7057e4346
3 changed files with 12 additions and 12 deletions

View File

@@ -54,7 +54,7 @@ extern void close_tsvector_parser(TSVectorParseState state);
struct TSQueryParserStateData; /* private in backend/utils/adt/tsquery.c */
typedef struct TSQueryParserStateData *TSQueryParserState;
typedef void (*PushFunction) (Datum opaque, TSQueryParserState state,
typedef void (*PushFunction) (void *opaque, TSQueryParserState state,
char *token, int tokenlen,
int16 tokenweights, /* bitmap as described in
* QueryOperand struct */
@@ -66,7 +66,7 @@ typedef void (*PushFunction) (Datum opaque, TSQueryParserState state,
extern TSQuery parse_tsquery(char *buf,
PushFunction pushval,
Datum opaque,
void *opaque,
int flags,
Node *escontext);