From d4ca048f016f54d5cc8ed502f948a5cb07348e8c Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Wed, 19 Jun 2024 21:46:28 -0700 Subject: [PATCH 1/3] gh-119698: symtable: Fix merge race --- Lib/symtable.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/symtable.py b/Lib/symtable.py index fee3c43163f6c2..221aaf88d41670 100644 --- a/Lib/symtable.py +++ b/Lib/symtable.py @@ -250,7 +250,7 @@ def is_local_symbol(ident): match st.type: case _symtable.TYPE_FUNCTION: d[st.name] = 1 - case _symtable.TYPE_TYPE_PARAM: + case _symtable.TYPE_TYPE_PARAMETERS: # Get the function-def block in the annotation # scope 'st' with the same identifier, if any. scope_name = st.name From 35f8855402a50bbc695842a2001a4641554ec86b Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Wed, 19 Jun 2024 21:56:15 -0700 Subject: [PATCH 2/3] fix doctest --- Doc/library/symtable.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/symtable.rst b/Doc/library/symtable.rst index aa5f8d95925ada..40f5fa775ed5b9 100644 --- a/Doc/library/symtable.rst +++ b/Doc/library/symtable.rst @@ -207,7 +207,7 @@ Examining Symbol Tables ... global outer ... def outer(self): pass ... ''', 'test', 'exec') - >>> class_A = st.get_children()[2] + >>> class_A = st.get_children()[1] >>> class_A.get_methods() ('f', 'g', 'h') From 0511bd158d8a15aff960575d1edc20451482fa24 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Wed, 19 Jun 2024 22:19:41 -0700 Subject: [PATCH 3/3] not in 3.14 --- Doc/library/symtable.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/symtable.rst b/Doc/library/symtable.rst index 40f5fa775ed5b9..aa5f8d95925ada 100644 --- a/Doc/library/symtable.rst +++ b/Doc/library/symtable.rst @@ -207,7 +207,7 @@ Examining Symbol Tables ... global outer ... def outer(self): pass ... ''', 'test', 'exec') - >>> class_A = st.get_children()[1] + >>> class_A = st.get_children()[2] >>> class_A.get_methods() ('f', 'g', 'h')