mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
pgindent run.
This commit is contained in:
@ -12,23 +12,27 @@
|
||||
#include "utils/builtins.h"
|
||||
#include "storage/bufpage.h"
|
||||
|
||||
typedef struct {
|
||||
typedef struct
|
||||
{
|
||||
uint32
|
||||
haspos:1,
|
||||
len:11, /* MAX 2Kb */
|
||||
pos:20; /* MAX 1Mb */
|
||||
haspos:1,
|
||||
len:11, /* MAX 2Kb */
|
||||
pos:20; /* MAX 1Mb */
|
||||
} WordEntry;
|
||||
|
||||
#define MAXSTRLEN ( 1<<11 )
|
||||
#define MAXSTRPOS ( 1<<20 )
|
||||
|
||||
typedef struct {
|
||||
typedef struct
|
||||
{
|
||||
uint16
|
||||
weight:2,
|
||||
pos:14;
|
||||
} WordEntryPos;
|
||||
#define MAXENTRYPOS (1<<14)
|
||||
weight:2,
|
||||
pos:14;
|
||||
} WordEntryPos;
|
||||
|
||||
#define MAXENTRYPOS (1<<14)
|
||||
#define MAXNUMPOS 256
|
||||
#define LIMITPOS(x) ( ( (x) >= MAXENTRYPOS ) ? (MAXENTRYPOS-1) : (x) )
|
||||
#define LIMITPOS(x) ( ( (x) >= MAXENTRYPOS ) ? (MAXENTRYPOS-1) : (x) )
|
||||
|
||||
typedef struct
|
||||
{
|
||||
@ -43,13 +47,14 @@ typedef struct
|
||||
#define STRPTR(x) ( (char*)x + DATAHDRSIZE + ( sizeof(WordEntry) * ((tsvector*)x)->size ) )
|
||||
#define STRSIZE(x) ( ((tsvector*)x)->len - DATAHDRSIZE - ( sizeof(WordEntry) * ((tsvector*)x)->size ) )
|
||||
#define _POSDATAPTR(x,e) (STRPTR(x)+((WordEntry*)(e))->pos+SHORTALIGN(((WordEntry*)(e))->len))
|
||||
#define POSDATALEN(x,e) ( ( ((WordEntry*)(e))->haspos ) ? (*(uint16*)_POSDATAPTR(x,e)) : 0 )
|
||||
#define POSDATAPTR(x,e) ( (WordEntryPos*)( _POSDATAPTR(x,e)+sizeof(uint16) ) )
|
||||
#define POSDATALEN(x,e) ( ( ((WordEntry*)(e))->haspos ) ? (*(uint16*)_POSDATAPTR(x,e)) : 0 )
|
||||
#define POSDATAPTR(x,e) ( (WordEntryPos*)( _POSDATAPTR(x,e)+sizeof(uint16) ) )
|
||||
|
||||
|
||||
typedef struct {
|
||||
WordEntry entry;
|
||||
WordEntryPos *pos;
|
||||
typedef struct
|
||||
{
|
||||
WordEntry entry;
|
||||
WordEntryPos *pos;
|
||||
} WordEntryIN;
|
||||
|
||||
typedef struct
|
||||
@ -60,7 +65,7 @@ typedef struct
|
||||
int4 len;
|
||||
int4 state;
|
||||
int4 alen;
|
||||
WordEntryPos *pos;
|
||||
WordEntryPos *pos;
|
||||
bool oprisdelim;
|
||||
} TI_IN_STATE;
|
||||
|
||||
|
Reference in New Issue
Block a user