PEP 613 TypeAlias annotation

E884132

PEP 613 TypeAlias annotation is a Python typing feature that introduces a dedicated `TypeAlias` marker to clearly distinguish type alias declarations from regular variable assignments.

Try in SPARQL Jump to: Statements Referenced by

Statements (31)

Predicate Object
instanceOf PEP
Python typing feature
affects static analysis tools
appliesTo Python type hints
backwardsCompatibleWith existing type hints
category typing and type system
clarifies when a name is a normal variable
when a name is a type alias
definesConcept explicit type alias
definesName TypeAlias NERFINISHED
encourages explicit type alias declarations in codebases
example Vector = list[float]
exampleWithMarker Vector: TypeAlias = list[float]
hasTitle Explicit Type Aliases NERFINISHED
introducedMarker TypeAlias
language Python NERFINISHED
motivates clear distinction between type aliases and variables
partOf typing module
primaryGoal make type alias declarations explicit
relatedTo PEP 484 NERFINISHED
PEP 585 NERFINISHED
PEP 604 NERFINISHED
relevantFor PyCharm type checker
mypy NERFINISHED
pyright NERFINISHED
static type checkers
solvesProblem ambiguity between type alias declarations and regular assignments
status Accepted
TypeAliasIs special typing marker
TypeAliasLivesIn typing module
usesSyntax TypeAlias = ...

Referenced by (1)

Full triples — surface form annotated when it differs from this entity's canonical label.

Python 3.10 hasTypingFeature PEP 613 TypeAlias annotation