/tsimapiak/parse.py |
---|
76,19 → 76,29 |
foundit = False |
break |
pref, posf = temp |
for pre in prefixes: |
if pref != u"": |
if pref.endswith(pre): |
foundprefs[wor].append(pre) |
pref = pref[:-len(pre)] |
last = u"" |
while last != pref: |
last = pref |
for pre in prefixes: |
if pref != u"": |
if pref.endswith(pre): |
if pre in foundprefs[wor]: |
break |
foundprefs[wor].append(pre) |
pref = pref[:-len(pre)] |
if pref != u"": |
foundit = False |
break |
for pos in postfixes: |
if posf != u"": |
if posf.startswith(pos): |
foundposts[wor].append(pos) |
posf = posf[len(pos):] |
last = u"" |
while last != posf: |
last = posf |
for pos in postfixes: |
if posf != u"": |
if posf.startswith(pos): |
if pos in foundposts[wor]: |
break |
foundposts[wor].append(pos) |
posf = posf[len(pos):] |
if posf != u"": |
foundit = False |
break |