Mercurial > hg > Applications > Grep
comparison regexParser/cerium/ppe/Print.cc @ 293:948428caf616
NFA maximum match worked
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 02 Feb 2016 10:38:45 +0900 |
parents | 87a801c14117 |
children | c5a7caa37f61 |
comparison
equal
deleted
inserted
replaced
292:868f01f1ba8e | 293:948428caf616 |
---|---|
35 fwrite(r->begin,r->end - r->begin-1,1,stdout); | 35 fwrite(r->begin,r->end - r->begin-1,1,stdout); |
36 printf(" match %d\n", ((prevBlockEnd->bitState.bitContainer & ~blockBegin->bitState.bitContainer)==0)? 1 : 0 ); | 36 printf(" match %d\n", ((prevBlockEnd->bitState.bitContainer & ~blockBegin->bitState.bitContainer)==0)? 1 : 0 ); |
37 #endif | 37 #endif |
38 if ((prevBlockEnd->bitState.bitContainer & ~blockBegin->bitState.bitContainer)==0) { | 38 if ((prevBlockEnd->bitState.bitContainer & ~blockBegin->bitState.bitContainer)==0) { |
39 // 前のブロックの matchBegin から最初 result の end までがマッチ | 39 // 前のブロックの matchBegin から最初 result の end までがマッチ |
40 fwrite(prev->begin,r->end - prev->begin-1,1,stdout); | 40 fwrite(prev->begin,r->end - prev->begin,1,stdout); |
41 // printf("####"); | 41 // printf("####"); |
42 if (!r->continued) puts(""); | 42 if (!r->continued) puts(""); |
43 } | 43 } |
44 r = r->next; | 44 r = r->next; |
45 // printf("%p\n",r); | 45 // printf("%p\n",r); |