bpo-40181: Remove '/' reminder in IDLE calltips. (GH-22350)

The marker was added to the language in 3.8 and
3.7 only gets security patches.
(cherry picked from commit 40a0625792)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
This commit is contained in:
Miss Islington (bot) 2020-09-21 23:05:07 -07:00 committed by GitHub
parent 4ee30c4244
commit 6b731c4878
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 9 deletions

View file

@ -118,7 +118,6 @@ _INDENT = ' '*4 # for wrapped signatures
_first_param = re.compile(r'(?<=\()\w*\,?\s*')
_default_callable_argspec = "See source or doc"
_invalid_method = "invalid method signature"
_argument_positional = " # '/' marks preceding args as positional-only."
def get_argspec(ob):
'''Return a string describing the signature of a callable object, or ''.
@ -146,9 +145,6 @@ def get_argspec(ob):
else:
argspec = ''
if '/' in argspec and len(argspec) < _MAX_COLS - len(_argument_positional):
# Add explanation TODO remove after 3.7, before 3.9.
argspec += _argument_positional
if isinstance(fob, type) and argspec == '()':
# If fob has no argument, use default callable argspec.
argspec = _default_callable_argspec