Primary
''type hint'' ⚬|Definition|1st|20260605182851-00-⌔
Glossary — Python 3 documentation#term-type-hint
type hint
An annotation that specifies the expected type for a variable, a class attribute, or a function parameter or return value.
Type hints are optional and are not enforced by Python but they are useful to static type checkers. They can also aid IDEs with code completion and refactoring.
Type hints of global variables, class attributes, and functions, but not local variables, can be accessed using
typing.get_type_hints().See
typingand PEP 484, which describe this functionality.Printed 2026-06-28.
(echo:: @ ᯤ)
Link to original
Secondary
• • •