Skip to content

Commit

Permalink
Update tokenizer comparison script
Browse files Browse the repository at this point in the history
  • Loading branch information
gbenson committed May 29, 2024
1 parent ea7f84d commit ba96074
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/dom_tokenizers/diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,12 @@ def _compare(self):
match tag:
case "equal":
pass # reset?
case "insert":
case c if c in {"insert", "replace", "delete"}:
for line in self._evaluate_change(
self.a, alo, ahi,
self.b, blo, bhi):
yield line
case "replace":
for line in self._evaluate_change(
self.a, alo, ahi,
self.b, blo, bhi):
yield line
case other: # noqa: F841
case _:
raise NotImplementedError((tag, alo, ahi, blo, bhi))

@staticmethod
Expand Down

0 comments on commit ba96074

Please sign in to comment.