Files
RustPython/Lib/test/typinganndata/ann_module9.py
NakanoMiku39 06b9b4938d Add Lib/test/typinganndata folder
cpython version: 3.12
2023-11-09 15:05:04 +08:00

15 lines
280 B
Python
Vendored

# Test ``inspect.formatannotation``
# https://github.com/python/cpython/issues/96073
from typing import Union, List
ann = Union[List[str], int]
# mock typing._type_repr behaviour
class A: ...
A.__module__ = 'testModule.typing'
A.__qualname__ = 'A'
ann1 = Union[List[A], int]