SF bug #769142:  CallTip trimming may loop forever.
SF bug #769142:  CallTip trimming may loop forever.

Needs to be backported to both IDLE and IDLEFORK.

sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator