📅  最后修改于: 2022-03-11 14:47:09.401000             🧑  作者: Mango
from typing import cast, List
o: object = [1]
x = cast(List[int], o) # OK
y = cast(List[str], o) # OK (cast performs no actual runtime check)