Skip to content

Commit

Permalink
Fix Typing
Browse files Browse the repository at this point in the history
  • Loading branch information
graphemecluster committed Jul 19, 2024
1 parent 7b44fed commit cdc13d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ToJyutping/Jyutping.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
from typing import List, Literal, Tuple, Union, overload
from typing import Iterable, List, Literal, Tuple, Union, overload
from itertools import starmap
from dataclasses import dataclass
from functools import cached_property
from operator import attrgetter
import re
import warnings

def to_id(s: str) -> List[int]:
def to_id(s: str) -> Iterable[int]:
it = iter(s)
return starmap(lambda x, y: (ord(x) - 33) * 90 + (ord(y) - 33), zip(it, it))

Expand Down

0 comments on commit cdc13d2

Please sign in to comment.