diff options
author | Bruce Momjian <bruce@momjian.us> | 1997-08-19 21:40:56 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 1997-08-19 21:40:56 +0000 |
commit | 1d8bbfd2e7cfb72cbe4d5c5d4fa650a28dedac0b (patch) | |
tree | 8d3a5dac9207f22c3afb8afb563d54f88774deb3 /src/backend/access/gist | |
parent | b992e200b8872ecb6652ec85111995f8d4c5aee0 (diff) | |
download | postgresql-1d8bbfd2e7cfb72cbe4d5c5d4fa650a28dedac0b.tar.gz postgresql-1d8bbfd2e7cfb72cbe4d5c5d4fa650a28dedac0b.zip |
Make functions static where possible, enclose unused functions in #ifdef NOT_USED.
Diffstat (limited to 'src/backend/access/gist')
-rw-r--r-- | src/backend/access/gist/gist.c | 12 | ||||
-rw-r--r-- | src/backend/access/gist/gistget.c | 5 | ||||
-rw-r--r-- | src/backend/access/gist/giststrat.c | 3 |
3 files changed, 14 insertions, 6 deletions
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c index 15be274b001..1d36f340ed6 100644 --- a/src/backend/access/gist/gist.c +++ b/src/backend/access/gist/gist.c @@ -57,7 +57,9 @@ static OffsetNumber gistchoose(Relation r, Page p, IndexTuple it, static int gistnospace(Page p, IndexTuple it); void gistdelete(Relation r, ItemPointer tid); static IndexTuple gist_tuple_replacekey(Relation r, GISTENTRY entry, IndexTuple t); - +static void gistcentryinit(GISTSTATE *giststate, GISTENTRY *e, char *pr, + Relation r, Page pg, OffsetNumber o, int b, bool l) ; +static char *int_range_out(INTRANGE *r); /* ** routine to build an index. Basically calls insert over and over @@ -1172,7 +1174,7 @@ gistdentryinit(GISTSTATE *giststate, GISTENTRY *e, char *pr, Relation r, /* ** initialize a GiST entry with a compressed version of pred */ -void +static void gistcentryinit(GISTSTATE *giststate, GISTENTRY *e, char *pr, Relation r, Page pg, OffsetNumber o, int b, bool l) { @@ -1244,7 +1246,8 @@ _gistdump(Relation r) } } -char *text_range_out(TXTRANGE *r) +#ifdef NOT_USED +static char *text_range_out(TXTRANGE *r) { char *result; char *lower, *upper; @@ -1266,8 +1269,9 @@ char *text_range_out(TXTRANGE *r) pfree(upper); return(result); } +#endif -char * +static char * int_range_out(INTRANGE *r) { char *result; diff --git a/src/backend/access/gist/gistget.c b/src/backend/access/gist/gistget.c index 1b424f9d28f..ac1697e5ed2 100644 --- a/src/backend/access/gist/gistget.c +++ b/src/backend/access/gist/gistget.c @@ -34,6 +34,9 @@ static RetrieveIndexResult gistscancache(IndexScanDesc s, ScanDirection dir); static RetrieveIndexResult gistfirst(IndexScanDesc s, ScanDirection dir); static RetrieveIndexResult gistnext(IndexScanDesc s, ScanDirection dir); static ItemPointer gistheapptr(Relation r, ItemPointer itemp); +static bool gistindex_keytest(IndexTuple tuple, TupleDesc tupdesc, + int scanKeySize, ScanKey key, GISTSTATE *giststate, + Relation r, Page p, OffsetNumber offset); RetrieveIndexResult @@ -217,7 +220,7 @@ gistnext(IndexScanDesc s, ScanDirection dir) } /* Similar to index_keytest, but decompresses the key in the IndexTuple */ -bool +static bool gistindex_keytest(IndexTuple tuple, TupleDesc tupdesc, int scanKeySize, diff --git a/src/backend/access/gist/giststrat.c b/src/backend/access/gist/giststrat.c index fd9ab849cbe..8c78ccec3ae 100644 --- a/src/backend/access/gist/giststrat.c +++ b/src/backend/access/gist/giststrat.c @@ -102,6 +102,7 @@ RelationGetGISTStrategy(Relation r, return (RelationGetStrategy(r, attnum, &GISTEvaluationData, proc)); } +#ifdef NOT_USED bool RelationInvokeGISTStrategy(Relation r, AttrNumber attnum, @@ -112,4 +113,4 @@ RelationInvokeGISTStrategy(Relation r, return (RelationInvokeStrategy(r, &GISTEvaluationData, attnum, s, left, right)); } - +#endif |