diff --git a/natto/mecab.py b/natto/mecab.py index e9d7c90..e70b4a4 100644 --- a/natto/mecab.py +++ b/natto/mecab.py @@ -350,6 +350,8 @@ def __parse_tonodes(self, text, **kwargs): self.lattice, bpos, self.MECAB_TOKEN_BOUNDARY) for (token, match) in tokens: + if token == '': + continue bpos += 1 if match: mark = self.MECAB_INSIDE_TOKEN