Lines Matching refs:pReader
224 static int readerAtEnd(DocListReader *pReader){
225 return pReader->p >= docListEnd(pReader->pDoclist);
229 static sqlite_int64 peekDocid(DocListReader *pReader){
231 assert( !readerAtEnd(pReader) );
232 getVarint(pReader->p, &ret);
237 static sqlite_int64 readDocid(DocListReader *pReader){
239 assert( !readerAtEnd(pReader) );
240 pReader->p += getVarint(pReader->p, &ret);
241 pReader->iLastPos = 0;
247 static int readPosition(DocListReader *pReader){
249 int iType = pReader->pDoclist->iType;
251 assert( !readerAtEnd(pReader) );
253 pReader->p += getVarint32(pReader->p, &i);
255 pReader->iLastPos = -1;
258 pReader->iLastPos += ((int) i)-1;
262 pReader->p += getVarint32(pReader->p, &iStart);
263 pReader->p += getVarint32(pReader->p, &iEnd);
265 return pReader->iLastPos;
269 static void skipPositionList(DocListReader *pReader){
270 while( readPosition(pReader)!=-1 )
276 static void skipDocument(DocListReader *pReader){
277 readDocid(pReader);
278 if( pReader->pDoclist->iType >= DL_POSITIONS ){
279 skipPositionList(pReader);