MCPcopy Index your code
hub / github.com/python/cpython / get_sort_arg_defs

Method get_sort_arg_defs

Lib/pstats.py:222–237  ·  view source on GitHub ↗

Expand all abbreviations that are unique.

(self)

Source from the content-addressed store, hash-verified

220 }
221
222 def get_sort_arg_defs(self):
223 """Expand all abbreviations that are unique."""
224 if not self.sort_arg_dict:
225 self.sort_arg_dict = dict = {}
226 bad_list = {}
227 for word, tup in self.sort_arg_dict_default.items():
228 fragment = word
229 while fragment:
230 if fragment in dict:
231 bad_list[fragment] = 0
232 break
233 dict[fragment] = tup
234 fragment = fragment[:-1]
235 for word in bad_list:
236 del dict[word]
237 return self.sort_arg_dict
238
239 def sort_stats(self, *field):
240 if not field:

Callers 2

sort_statsMethod · 0.95
do_sortMethod · 0.80

Calls 1

itemsMethod · 0.45

Tested by

no test coverage detected