On Sat, Nov 4, 2017 at 1:49 AM, Guido van Rossum <gu...@python.org> wrote: > On Fri, Nov 3, 2017 at 7:45 AM, Chris Angelico <ros...@gmail.com> wrote: >> >> On Sat, Nov 4, 2017 at 1:35 AM, Guido van Rossum <gu...@python.org> wrote: >> > [A copy from https://github.com/python/typing/issues/495 to get more >> > people's attention to this issue.] >> > >> > I'm wondering if we should remove typing from the stdlib. Now's the time >> > to >> > think about this, as the feature freeze for 3.7 is about 12 weeks away. >> > >> > Cons: >> > >> > People have to depend on a PyPI package to use typing (but they do >> > anyway >> > for typing_extensions) >> >> If the lazy evaluation of annotations (PEP 563) also lands in 3.7, >> then this would be a very minor downside. You'd need to pip-install >> typing as well as mypy *for the actual type checking*, but at run >> time, you could ignore both (all those List[...] annotations would be >> stored unevaluated). Otherwise, it'd mean that any project that makes >> use of type hints would require typing as a run-time dependency. > > > This would not work if you use TypeVar, NewType, or any kind of type alias > involving things imported from typing (e.g. Union or TypedDict). Also > cast().
Ah, I forgot about those - they're not just used in the annotations. Oh well, was a nice idea. ChrisA _______________________________________________ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/