Typing extensions extensions
Project description
tee -- typing extensions extensions
Package which provides useful types.
Documentation
Examples
Constraint types without runtime overhead
These types are most useful in conjunction with static type checkers like mypy.
from tee import PositiveInt
a = PositiveInt(5) # OK
def f(x: PositiveInt) -> None:
print(x)
f(a) # OK
f(7) # works at runtime but mypy gives error
b = PositiveInt(-3) # AssertionError
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
teext-0.1.0.tar.gz
(2.3 kB
view hashes)
Built Distribution
teext-0.1.0-py3-none-any.whl
(14.8 kB
view hashes)