[3.7] bpo-28556: Clarify that Type[SomeTypeVar] is legal (GH-9585) by miss-islington · Pull Request #9590 · python/cpython (original) (raw)

Currently, the docs state that when doing Type[X], X is only allowed to be a class, a union of classes, and Any. This pull request amends that sentence to clarify X may also be a typevar (or a union involving classes, Any, and TypeVars). (cherry picked from commit 130717f)

Co-authored-by: Michael Lee michael.lee.0x2a@gmail.com