equal
deleted
inserted
replaced
66 if len(line) == 0: |
66 if len(line) == 0: |
67 break |
67 break |
68 self.lineno += 1 |
68 self.lineno += 1 |
69 m = self.FREQ_RE.match(line) |
69 m = self.FREQ_RE.match(line) |
70 if not m: |
70 if not m: |
71 raise Exception("Line {:d} is not in NUM WORD format\n".format(self.lineno, line)) |
71 raise Exception("Line '{:s}' #{:d} is not in NUM WORD format\n".format(line, self.lineno)) |
72 headword = m.group(2).strip().lower() |
72 headword = m.group(2).strip().lower() |
73 wlist.append(headword) |
73 wlist.append(headword) |
74 return wlist |
74 return wlist |
75 |
75 |
76 if __name__ == '__main__': |
76 if __name__ == '__main__': |