diff options
author | Nikita Sobolev <mail@sobolevn.me> | 2021-09-25 08:56:22 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-25 08:56:22 (GMT) |
commit | 784905dbeff68cf788bbeefe0a675af1af04affc (patch) | |
tree | ea65406abec0964e637a33da355e6edc33a9e94a /Lib/test/ann_module5.py | |
parent | 4c0fc65cd8a6d4c18330505576ccd4b46abeec1c (diff) | |
download | cpython-784905dbeff68cf788bbeefe0a675af1af04affc.zip cpython-784905dbeff68cf788bbeefe0a675af1af04affc.tar.gz cpython-784905dbeff68cf788bbeefe0a675af1af04affc.tar.bz2 |
bpo-45166: fixes `get_type_hints` failure on `Final` (GH-28279)
Co-authored-by: Ćukasz Langa <lukasz@langa.pl>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Diffstat (limited to 'Lib/test/ann_module5.py')
-rw-r--r-- | Lib/test/ann_module5.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Lib/test/ann_module5.py b/Lib/test/ann_module5.py new file mode 100644 index 0000000..837041e --- /dev/null +++ b/Lib/test/ann_module5.py @@ -0,0 +1,10 @@ +# Used by test_typing to verify that Final wrapped in ForwardRef works. + +from __future__ import annotations + +from typing import Final + +name: Final[str] = "final" + +class MyClass: + value: Final = 3000 |