4 ms·
a) do Optional[Union[foo, bar]] b) why do you expect this from a duck typed language? None of options you listed or the library is offering saves you from misma
by impoppy 5y ago
a) do Optional[Union[foo, bar]]
b) why do you expect this from a duck typed language? None of options you listed or the library is offering saves you from mismatched types. Mypy is still as good as it can possibly be using only vanilla type hints
- dragonwriter 5y ago> None of options you listed or the library is offering saves you from mismatched types. Even if true, so what? The utility of Maybe/Result datastructures isn't limited to their use in typechecking, though with a proper static typechecker, that is part of their use.