diff options
author | Heikki Linnakangas <heikki.linnakangas@iki.fi> | 2024-08-06 23:04:22 +0300 |
---|---|---|
committer | Heikki Linnakangas <heikki.linnakangas@iki.fi> | 2024-08-06 23:04:22 +0300 |
commit | 85829c973cb33592dbc0b0f3aaf9132f5dea6953 (patch) | |
tree | 649b55143d540c8f7a17dc6fbc76743ad2276a9e /src/include/common | |
parent | 1e35951e71d37ab6716fa55ba399fbe6df4a7417 (diff) | |
download | postgresql-85829c973cb33592dbc0b0f3aaf9132f5dea6953.tar.gz postgresql-85829c973cb33592dbc0b0f3aaf9132f5dea6953.zip |
Make nullSemAction const, add 'const' decorators to related functions
To make it more clear that these should never be modified.
Reviewed-by: Andres Freund
Discussion: https://www.postgresql.org/message-id/54c29fb0-edf2-48ea-9814-44e918bbd6e8@iki.fi
Diffstat (limited to 'src/include/common')
-rw-r--r-- | src/include/common/jsonapi.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/include/common/jsonapi.h b/src/include/common/jsonapi.h index 71a491d72dc..a995fdbe081 100644 --- a/src/include/common/jsonapi.h +++ b/src/include/common/jsonapi.h @@ -153,16 +153,16 @@ typedef struct JsonSemAction * does nothing and just continues. */ extern JsonParseErrorType pg_parse_json(JsonLexContext *lex, - JsonSemAction *sem); + const JsonSemAction *sem); extern JsonParseErrorType pg_parse_json_incremental(JsonLexContext *lex, - JsonSemAction *sem, + const JsonSemAction *sem, const char *json, size_t len, bool is_last); /* the null action object used for pure validation */ -extern PGDLLIMPORT JsonSemAction nullSemAction; +extern PGDLLIMPORT const JsonSemAction nullSemAction; /* * json_count_array_elements performs a fast secondary parse to determine the |