summaryrefslogtreecommitdiffstats
path: root/Lib/inspect.py
diff options
context:
space:
mode:
authorAnthony Sottile <asottile@umich.edu>2021-05-22 14:51:43 (GMT)
committerGitHub <noreply@github.com>2021-05-22 14:51:43 (GMT)
commit9e746e3298da36f4e8df0495f91a720f3e54ea33 (patch)
treeb0c7123d7f83d3699456ce2b82c478eb8689ae3f /Lib/inspect.py
parente9f66aedf44ccc3be27975cfb070a44ce6a6bd13 (diff)
downloadcpython-9e746e3298da36f4e8df0495f91a720f3e54ea33.zip
cpython-9e746e3298da36f4e8df0495f91a720f3e54ea33.tar.gz
cpython-9e746e3298da36f4e8df0495f91a720f3e54ea33.tar.bz2
bpo-20684: Remove unused inspect._signature_get_bound_param (GH-21100)
Diffstat (limited to 'Lib/inspect.py')
-rw-r--r--Lib/inspect.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/Lib/inspect.py b/Lib/inspect.py
index 9f8cc01..89b2e72 100644
--- a/Lib/inspect.py
+++ b/Lib/inspect.py
@@ -2020,29 +2020,6 @@ def _signature_is_functionlike(obj):
(isinstance(annotations, (dict)) or annotations is None) )
-def _signature_get_bound_param(spec):
- """ Private helper to get first parameter name from a
- __text_signature__ of a builtin method, which should
- be in the following format: '($param1, ...)'.
- Assumptions are that the first argument won't have
- a default value or an annotation.
- """
-
- assert spec.startswith('($')
-
- pos = spec.find(',')
- if pos == -1:
- pos = spec.find(')')
-
- cpos = spec.find(':')
- assert cpos == -1 or cpos > pos
-
- cpos = spec.find('=')
- assert cpos == -1 or cpos > pos
-
- return spec[2:pos]
-
-
def _signature_strip_non_python_syntax(signature):
"""
Private helper function. Takes a signature in Argument Clinic's