From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Tue, 22 Jul 2025 16:15:27 +0000 (+0200) Subject: [3.14] Fix code example in `annotationlib` documentation (GH-136972) (#137002) X-Git-Tag: v3.14.0rc1~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c328d140eb85df760a40ca58ab0b27195c550560;p=thirdparty%2FPython%2Fcpython.git [3.14] Fix code example in `annotationlib` documentation (GH-136972) (#137002) Co-authored-by: Victorien <65306057+Viicos@users.noreply.github.com> --- diff --git a/Doc/library/annotationlib.rst b/Doc/library/annotationlib.rst index 7dfc11449a6c..981d89be7d58 100644 --- a/Doc/library/annotationlib.rst +++ b/Doc/library/annotationlib.rst @@ -511,7 +511,7 @@ code execution even with no access to any globals or builtins. For example: >>> def f(x: (1).__class__.__base__.__subclasses__()[-1].__init__.__builtins__["print"]("Hello world")): pass ... - >>> annotationlib.get_annotations(f, format=annotationlib.Format.SOURCE) + >>> annotationlib.get_annotations(f, format=annotationlib.Format.STRING) Hello world {'x': 'None'}