Home | History | Annotate | Download | only in common

Lines Matching refs:pos

645     int32_t pos=spanLength, rest=length-pos;
658 // Try to match this string at pos-overlap..pos.
673 if(!offsets.containsOffset(inc) && matches16CPB(s, pos-overlap, length, s16, length16)) {
697 // Try to match this string at pos-overlap..pos.
713 matches16CPB(s, pos-overlap, length, s16, length16)
727 pos+=maxInc;
736 // Finished trying to match all strings at pos.
738 if(spanLength!=0 || pos==0) {
741 // The only position where spanLength==0 after a span is pos==0.
745 return pos; // No strings matched after a span.
753 spanLength=spanSet.span(s+pos, rest, USET_SPAN_CONTAINED);
757 return pos+spanLength;
759 pos+=spanLength;
766 spanLength=spanOne(spanSet, s+pos, rest);
774 pos+=spanLength;
784 pos+=minOffset;
794 int32_t pos=spanSet.spanBack(s, length, USET_SPAN_CONTAINED);
795 if(pos==0) {
798 int32_t spanLength=length-pos;
822 // Try to match this string at pos-(length16-overlap)..pos-length16.
835 if(dec>pos) {
839 if(!offsets.containsOffset(dec) && matches16CPB(s, pos-dec, length, s16, length16)) {
840 if(dec==pos) {
863 // Try to match this string at pos-(length16-overlap)..pos-length16.
874 if(dec>pos || overlap<maxOverlap) {
879 matches16CPB(s, pos-dec, length, s16, length16)
893 pos-=maxDec;
894 if(pos==0) {
901 // Finished trying to match all strings at pos.
903 if(spanLength!=0 || pos==length) {
906 // The only position where spanLength==0 before a span is pos==length.
910 return pos; // No strings matched before a span.
918 int32_t oldPos=pos;
919 pos=spanSet.spanBack(s, oldPos, USET_SPAN_CONTAINED);
920 spanLength=oldPos-pos;
921 if( pos==0 || // Reached the start of the string, or
924 return pos;
931 spanLength=spanOneBack(spanSet, s, pos);
933 if(spanLength==pos) {
939 pos-=spanLength;
947 pos-=offsets.popMinimum();
967 int32_t pos=spanLength, rest=length-pos;
988 // Try to match this string at pos-overlap..pos.
1005 if( !U8_IS_TRAIL(s[pos-overlap]) &&
1007 matches8(s+pos-overlap, s8, length8)
1034 // Try to match this string at pos-overlap..pos.
1051 if( !U8_IS_TRAIL(s[pos-overlap]) &&
1053 matches8(s+pos-overlap, s8, length8)
1069 pos+=maxInc;
1078 // Finished trying to match all strings at pos.
1080 if(spanLength!=0 || pos==0) {
1083 // The only position where spanLength==0 after a span is pos==0.
1087 return pos; // No strings matched after a span.
1095 spanLength=spanSet.spanUTF8((const char *)s+pos, rest, USET_SPAN_CONTAINED);
1099 return pos+spanLength;
1101 pos+=spanLength;
1108 spanLength=spanOneUTF8(spanSet, s+pos, rest);
1116 pos+=spanLength;
1126 pos+=minOffset;
1136 int32_t pos=spanSet.spanBackUTF8((const char *)s, length, USET_SPAN_CONTAINED);
1137 if(pos==0) {
1140 int32_t spanLength=length-pos;
1168 // Try to match this string at pos-(length8-overlap)..pos-length8.
1181 if(dec>pos) {
1187 if( !U8_IS_TRAIL(s[pos-dec]) &&
1189 matches8(s+pos-dec, s8, length8)
1191 if(dec==pos) {
1215 // Try to match this string at pos-(length8-overlap)..pos-length8.
1226 if(dec>pos || overlap<maxOverlap) {
1232 if( !U8_IS_TRAIL(s[pos-dec]) &&
1234 matches8(s+pos-dec, s8, length8)
1249 pos-=maxDec;
1250 if(pos==0) {
1257 // Finished trying to match all strings at pos.
1259 if(spanLength!=0 || pos==length) {
1262 // The only position where spanLength==0 before a span is pos==length.
1266 return pos; // No strings matched before a span.
1274 int32_t oldPos=pos;
1275 pos=spanSet.spanBackUTF8((const char *)s, oldPos, USET_SPAN_CONTAINED);
1276 spanLength=oldPos-pos;
1277 if( pos==0 || // Reached the start of the string, or
1280 return pos;
1287 spanLength=spanOneBackUTF8(spanSet, s, pos);
1289 if(spanLength==pos) {
1295 pos-=spanLength;
1303 pos-=offsets.popMinimum();
1338 int32_t pos=0, rest=length;
1343 i=pSpanNotSet->span(s+pos, rest, USET_SPAN_NOT_CONTAINED);
1347 pos+=i;
1352 int32_t cpLength=spanOne(spanSet, s+pos, rest);
1354 return pos; // There is a set element at pos.
1357 // Try to match the strings at pos.
1365 if(length16<=rest && matches16CPB(s, pos, length, s16, length16)) {
1366 return pos; // There is a set element at pos.
1373 pos-=cpLength;
1380 int32_t pos=length;
1385 pos=pSpanNotSet->spanBack(s, pos, USET_SPAN_NOT_CONTAINED);
1386 if(pos==0) {
1392 int32_t cpLength=spanOneBack(spanSet, s, pos);
1394 return pos; // There is a set element at pos.
1397 // Try to match the strings at pos.
1408 if(length16<=pos && matches16CPB(s, pos-length16, length, s16, length16)) {
1409 return pos; // There is a set element at pos.
1416 pos+=cpLength;
1417 } while(pos!=0);
1422 int32_t pos=0, rest=length;
1431 i=pSpanNotSet->spanUTF8((const char *)s+pos, rest, USET_SPAN_NOT_CONTAINED);
1435 pos+=i;
1440 int32_t cpLength=spanOneUTF8(spanSet, s+pos, rest);
1442 return pos; // There is a set element at pos.
1445 // Try to match the strings at pos.
1451 if(length8!=0 && spanUTF8Lengths[i]!=ALL_CP_CONTAINED && length8<=rest && matches8(s+pos, s8, length8)) {
1452 return pos; // There is a set element at pos.
1460 pos-=cpLength;
1467 int32_t pos=length;
1476 pos=pSpanNotSet->spanBackUTF8((const char *)s, pos, USET_SPAN_NOT_CONTAINED);
1477 if(pos==0) {
1483 int32_t cpLength=spanOneBackUTF8(spanSet, s, pos);
1485 return pos; // There is a set element at pos.
1488 // Try to match the strings at pos.
1494 if(length8!=0 && spanBackUTF8Lengths[i]!=ALL_CP_CONTAINED && length8<=pos && matches8(s+pos-length8, s8, length8)) {
1495 return pos; // There is a set element at pos.
1503 pos+=cpLength;
1504 } while(pos!=0);