mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-03-31 20:20:44 +08:00
Support functions for index opclasses should be immutable.
Found by running opr_sanity on contrib modules.
This commit is contained in:
parent
92266303e8
commit
d80d8acbce
@ -186,37 +186,37 @@ CREATE TYPE ghstore (
|
||||
CREATE FUNCTION ghstore_compress(internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION ghstore_decompress(internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION ghstore_penalty(internal,internal,internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C STRICT;
|
||||
LANGUAGE C IMMUTABLE STRICT;
|
||||
|
||||
CREATE FUNCTION ghstore_picksplit(internal, internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION ghstore_union(internal, internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION ghstore_same(internal, internal, internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION ghstore_consistent(internal,internal,int4)
|
||||
RETURNS bool
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
-- register the opclass for indexing (not as default)
|
||||
CREATE OPERATOR CLASS gist_hstore_ops
|
||||
@ -241,23 +241,23 @@ AS
|
||||
CREATE FUNCTION gin_extract_hstore(internal, internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION gin_extract_hstore_query(internal, internal, int2)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE FUNCTION gin_consistent_hstore(internal, int2, internal)
|
||||
RETURNS internal
|
||||
AS 'MODULE_PATHNAME'
|
||||
LANGUAGE C;
|
||||
LANGUAGE C IMMUTABLE;
|
||||
|
||||
CREATE OPERATOR CLASS gin_hstore_ops
|
||||
DEFAULT FOR TYPE hstore USING gin
|
||||
AS
|
||||
OPERATOR 7 @> RECHECK,
|
||||
OPERATOR 9 ?(hstore,text),
|
||||
OPERATOR 9 ?(hstore,text),
|
||||
FUNCTION 1 bttextcmp(text,text),
|
||||
FUNCTION 2 gin_extract_hstore(internal, internal),
|
||||
FUNCTION 3 gin_extract_hstore_query(internal, internal, int2),
|
||||
|
Loading…
x
Reference in New Issue
Block a user