On 3/7/22 2:23 PM, Alex Waygood wrote:
> I agree with Jelle and Guido. The name isn't perfect, but I haven't seen
> any suggestions that seem better to me (and can't think of any myself).
> The function will be useful; I think it's time to move forward with this
> proposal.
Seems fine to me. (I'm one of the folks who was concerned with the
assert_type() name.)
In my own code, I'll probably opt to always use such an assert_type()
function in qualified form, as `typing.assert_type()` (by using `import
typing` rather than `from typing import assert_type`) since that will be
more likely to be treated as "something that has to do with static
typing" rather than a runtime assertion.
Best,
--
David Foster | Seattle, WA, USA
Contributor to TypedDict support for mypy