Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6456b17

Browse files
committed
Rename oid8 -> oidvector and int28 -> int2vector. Cleanup of *out functions.
1 parent3f03f74 commit6456b17

File tree

27 files changed

+119
-120
lines changed

27 files changed

+119
-120
lines changed

‎src/backend/access/hash/hashfunc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashfunc.c,v 1.20 1999/11/07 23:07:49 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashfunc.c,v 1.21 2000/01/10 16:13:10 momjian Exp $
1111
*
1212
* NOTES
1313
* These functions are stored in pg_amproc.For each operator class
@@ -140,7 +140,7 @@ hashoid(Oid key)
140140
}
141141

142142
uint32
143-
hashoid8(Oid*key)
143+
hashoidvector(Oid*key)
144144
{
145145
inti;
146146
uint32result=0;

‎src/backend/access/nbtree/nbtcompare.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.28 1999/11/07 23:07:56 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.29 2000/01/10 16:13:10 momjian Exp $
1111
*
1212
*NOTES
1313
*These functions are stored in pg_amproc. For each operator class
@@ -94,7 +94,7 @@ btoidcmp(Oid a, Oid b)
9494
}
9595

9696
int32
97-
btoid8cmp(Oid*a,Oid*b)
97+
btoidvectorcmp(Oid*a,Oid*b)
9898
{
9999
inti;
100100

‎src/backend/bootstrap/bootstrap.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Copyright (c) 1994, Regents of the University of California
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.74 1999/12/20 10:40:39 wieck Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.75 2000/01/10 16:13:11 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -109,15 +109,15 @@ static struct typinfo Procid[] = {
109109
{"dummy",20,0,16,0,0},
110110
/* { "dt", 20, 0, 4, F_DTIN,F_DTOUT}, */
111111
{"int2",21,0,2,F_INT2IN,F_INT2OUT},
112-
{"int28",22,0,16,F_INT28IN,F_INT28OUT},
112+
{"int2vector",22,0,16,F_INT2VECTORIN,F_INT2VECTOROUT},
113113
{"int4",23,0,4,F_INT4IN,F_INT4OUT},
114114
{"regproc",24,0,4,F_REGPROCIN,F_REGPROCOUT},
115115
{"text",25,0,-1,F_TEXTIN,F_TEXTOUT},
116116
{"oid",26,0,4,F_INT4IN,F_INT4OUT},
117117
{"tid",27,0,6,F_TIDIN,F_TIDOUT},
118118
{"xid",28,0,5,F_XIDIN,F_XIDOUT},
119119
{"iid",29,0,1,F_CIDIN,F_CIDOUT},
120-
{"oid8",30,0,32,F_OID8IN,F_OID8OUT},
120+
{"oidvector",30,0,32,F_OIDVECTORIN,F_OIDVECTOROUT},
121121
{"smgr",210,0,2,F_SMGRIN,F_SMGROUT},
122122
{"_int4",1007,23,-1,F_ARRAY_IN,F_ARRAY_OUT},
123123
{"_aclitem",1034,1033,-1,F_ARRAY_IN,F_ARRAY_OUT}

‎src/backend/catalog/indexing.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/catalog/indexing.c,v 1.55 1999/12/30 05:04:55 tgl Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/catalog/indexing.c,v 1.56 2000/01/10 16:13:12 momjian Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -763,7 +763,7 @@ ProcedureNameIndexScan(Relation heapRelation,
763763
ScanKeyEntryInitialize(&skey[2],
764764
(bits16)0x0,
765765
(AttrNumber)3,
766-
(RegProcedure)F_OID8EQ,
766+
(RegProcedure)F_OIDVECTOREQ,
767767
PointerGetDatum(argTypes));
768768

769769
idesc=index_openr(ProcedureNameIndex);

‎src/backend/tcop/fastpath.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.31 1999/11/22 17:56:26 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.32 2000/01/10 16:13:13 momjian Exp $
1111
*
1212
* NOTES
1313
* This cruft is the server side of PQfn.
@@ -181,7 +181,7 @@ valid_fp_info(Oid func_id, struct fp_info * fip)
181181
staticvoid
182182
update_fp_info(Oidfunc_id,structfp_info*fip)
183183
{
184-
Oid*argtypes;/* anoid8 */
184+
Oid*argtypes;/* anoidvector */
185185
Oidrettype;
186186
HeapTuplefunc_htp,
187187
type_htp;

‎src/backend/utils/adt/int.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.30 2000/01/1015:41:26 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.31 2000/01/1016:13:14 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
1414
/*
1515
* OLD COMMENTS
1616
*I/O routines:
17-
* int2in, int2out,int28in, int28out, int4in, int4out
17+
* int2in, int2out,int2vectorin, int2vectorout, int4in, int4out
1818
*Conversion routines:
1919
* itoi, int2_text, int4_text
2020
*Boolean operators:
@@ -71,13 +71,13 @@ int2out(int16 sh)
7171
}
7272

7373
/*
74-
*int28in- converts "num num ..." to internal form
74+
*int2vectorin- converts "num num ..." to internal form
7575
*
7676
*Note:
7777
*Fills any nonexistent digits with NULLs.
7878
*/
7979
int16*
80-
int28in(char*intString)
80+
int2vectorin(char*intString)
8181
{
8282
int16*result;
8383
intslot;
@@ -99,18 +99,18 @@ int28in(char *intString)
9999
while (*intString&&isspace(*intString))
100100
intString++;
101101
if (*intString)
102-
elog(ERROR,"int28 value has too many values");
102+
elog(ERROR,"int2vector value has too many values");
103103
while (slot<INDEX_MAX_KEYS)
104104
result[slot++]=0;
105105

106106
returnresult;
107107
}
108108

109109
/*
110-
*int28out- converts internal form to "num num ..."
110+
*int2vectorout- converts internal form to "num num ..."
111111
*/
112112
char*
113-
int28out(int16*int2Array)
113+
int2vectorout(int16*int2Array)
114114
{
115115
intnum,maxnum;
116116
char*rp;
@@ -130,7 +130,7 @@ int28out(int16 *int2Array)
130130
break;
131131

132132
/* assumes sign, 5 digits, ' ' */
133-
rp=result= (char*)palloc(maxnum*7+1);
133+
rp=result= (char*)palloc((maxnum+1)*7+1);
134134
for (num=0;num <=maxnum;num++)
135135
{
136136
if (num!=0)
@@ -168,7 +168,7 @@ int44in(char *input_string)
168168
}
169169

170170
/*
171-
*int28out- converts internal form to "num num ..."
171+
*int2vectorout- converts internal form to "num num ..."
172172
*/
173173
char*
174174
int44out(int32*an_array)

‎src/backend/utils/adt/int8.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -519,7 +519,7 @@ int84(int64 *val)
519519

520520
#ifNOT_USED
521521
int64*
522-
int28(int16val)
522+
int2vector(int16val)
523523
{
524524
int64*result;
525525

@@ -528,7 +528,7 @@ int28(int16 val)
528528
*result=val;
529529

530530
returnresult;
531-
}/*int28() */
531+
}/*int2vector() */
532532

533533
int16
534534
int82(int64*val)

‎src/backend/utils/adt/oid.c

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.31 2000/01/1015:41:26 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.32 2000/01/1016:13:14 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -22,13 +22,13 @@
2222
*****************************************************************************/
2323

2424
/*
25-
*oid8in- converts "num num ..." to internal form
25+
*oidvectorin- converts "num num ..." to internal form
2626
*
2727
*Note:
2828
*Fills any nonexistent digits with NULL oids.
2929
*/
3030
Oid*
31-
oid8in(char*oidString)
31+
oidvectorin(char*oidString)
3232
{
3333
Oid*result;
3434
intslot;
@@ -50,18 +50,18 @@ oid8in(char *oidString)
5050
while (*oidString&&isspace(*oidString))
5151
oidString++;
5252
if (*oidString)
53-
elog(ERROR,"oid8 value has too many values");
53+
elog(ERROR,"oidvector value has too many values");
5454
while (slot<INDEX_MAX_KEYS)
5555
result[slot++]=0;
5656

5757
returnresult;
5858
}
5959

6060
/*
61-
*oid8out - converts internal form to "num num ..."
61+
*oidvectorout - converts internal form to "num num ..."
6262
*/
6363
char*
64-
oid8out(Oid*oidArray)
64+
oidvectorout(Oid*oidArray)
6565
{
6666
intnum,maxnum;
6767
char*rp;
@@ -81,7 +81,7 @@ oid8out(Oid *oidArray)
8181
break;
8282

8383
/* assumes sign, 10 digits, ' ' */
84-
rp=result= (char*)palloc(maxnum*12+1);
84+
rp=result= (char*)palloc((maxnum+1)*12+1);
8585
for (num=0;num <=maxnum;num++)
8686
{
8787
if (num!=0)
@@ -127,19 +127,19 @@ oidne(Oid arg1, Oid arg2)
127127
}
128128

129129
bool
130-
oid8eq(Oid*arg1,Oid*arg2)
130+
oidvectoreq(Oid*arg1,Oid*arg2)
131131
{
132132
return (bool) (memcmp(arg1,arg2,INDEX_MAX_KEYS*sizeof(Oid))==0);
133133
}
134134

135135
bool
136-
oid8ne(Oid*arg1,Oid*arg2)
136+
oidvectorne(Oid*arg1,Oid*arg2)
137137
{
138138
return (bool) (memcmp(arg1,arg2,INDEX_MAX_KEYS*sizeof(Oid))!=0);
139139
}
140140

141141
bool
142-
oid8lt(Oid*arg1,Oid*arg2)
142+
oidvectorlt(Oid*arg1,Oid*arg2)
143143
{
144144
inti;
145145

@@ -150,7 +150,7 @@ oid8lt(Oid *arg1, Oid *arg2)
150150
}
151151

152152
bool
153-
oid8le(Oid*arg1,Oid*arg2)
153+
oidvectorle(Oid*arg1,Oid*arg2)
154154
{
155155
inti;
156156

@@ -161,7 +161,7 @@ oid8le(Oid *arg1, Oid *arg2)
161161
}
162162

163163
bool
164-
oid8ge(Oid*arg1,Oid*arg2)
164+
oidvectorge(Oid*arg1,Oid*arg2)
165165
{
166166
inti;
167167

@@ -172,7 +172,7 @@ oid8ge(Oid *arg1, Oid *arg2)
172172
}
173173

174174
bool
175-
oid8gt(Oid*arg1,Oid*arg2)
175+
oidvectorgt(Oid*arg1,Oid*arg2)
176176
{
177177
inti;
178178

‎src/backend/utils/adt/regproc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.47 1999/12/30 05:05:07 tgl Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.48 2000/01/10 16:13:14 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -233,7 +233,7 @@ regprocout(RegProcedure proid)
233233
*int8typeout- converts int8 type oids to "typname" list
234234
*/
235235
text*
236-
oid8types(Oid*oidArray)
236+
oidvectortypes(Oid*oidArray)
237237
{
238238
HeapTupletypetup;
239239
text*result;

‎src/backend/utils/cache/catcache.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.55 1999/12/16 22:19:54 wieck Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.56 2000/01/10 16:13:15 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -70,7 +70,7 @@ GlobalMemory CacheCxt;/* context in which caches are allocated */
7070
staticlongeqproc[]= {
7171
F_BOOLEQ,0l,F_CHAREQ,F_NAMEEQ,0l,
7272
F_INT2EQ,F_KEYFIRSTEQ,F_INT4EQ,0l,F_TEXTEQ,
73-
F_OIDEQ,0l,0l,0l,F_OID8EQ
73+
F_OIDEQ,0l,0l,0l,F_OIDVECTOREQ
7474
};
7575

7676
#defineEQPROC(SYSTEMTYPEOID)eqproc[(SYSTEMTYPEOID)-16]
@@ -191,14 +191,14 @@ CatalogCacheInitializeCache(struct catcache * cache,
191191

192192
/*
193193
* Yoiks. The implementation of the hashing code and the
194-
* implementation ofint28's are at loggerheads. The right
195-
* thing to do is to throw out the implementation ofint28's
194+
* implementation ofint2vector's are at loggerheads. The right
195+
* thing to do is to throw out the implementation ofint2vector's
196196
* altogether; until that happens, we do the right thing here
197197
* to guarantee that the hash key generator doesn't try to
198198
* dereference an int2 by mistake.
199199
*/
200200

201-
if (tupdesc->attrs[cache->cc_key[i]-1]->atttypid==INT28OID)
201+
if (tupdesc->attrs[cache->cc_key[i]-1]->atttypid==INT2VECTOROID)
202202
cache->cc_klen[i]=sizeof(short);
203203
else
204204
cache->cc_klen[i]=tupdesc->attrs[cache->cc_key[i]-1]->attlen;
@@ -851,7 +851,7 @@ SearchSelfReferences(struct catcache * cache)
851851
{
852852
HeapScanDescsd;
853853
MemoryContextoldcxt;
854-
854+
855855
if (!CacheCxt)
856856
CacheCxt=CreateGlobalMemory("Cache");
857857
rel=heap_open(cache->relationId,AccessShareLock);
@@ -872,15 +872,15 @@ SearchSelfReferences(struct catcache * cache)
872872
/* bootstrapping this requires preloading a range of rows. bjm */
873873
staticHeapTupleoperatorSelfTuple[MAX_OIDCMP-MIN_OIDCMP+1];
874874
Oidlookup_oid= (Oid)cache->cc_skey[0].sk_argument;
875-
875+
876876
if (lookup_oid<MIN_OIDCMP||lookup_oid>MAX_OIDCMP)
877877
return (HeapTuple)0;
878878

879879
if (!HeapTupleIsValid(operatorSelfTuple[lookup_oid-MIN_OIDCMP]))
880880
{
881881
HeapScanDescsd;
882882
MemoryContextoldcxt;
883-
883+
884884
if (!CacheCxt)
885885
CacheCxt=CreateGlobalMemory("Cache");
886886
rel=heap_open(cache->relationId,AccessShareLock);

‎src/bin/pg_dump/pg_dump.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
*
2222
*
2323
* IDENTIFICATION
24-
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.129 1999/12/27 18:21:07 momjian Exp $
24+
* $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.130 2000/01/10 16:13:16 momjian Exp $
2525
*
2626
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
2727
*
@@ -1770,7 +1770,6 @@ getTables(int *numTables, FuncInfo *finfo, int numFuncs)
17701770
for (findx=0;findx<tgnargs;findx++)
17711771
{
17721772
constchar*s;
1773-
char*d;
17741773

17751774
for (p=tgargs;;)
17761775
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp