MCPcopy Index your code
hub / github.com/RustPython/RustPython / _get_name_info

Function _get_name_info

Lib/dis.py:710–722  ·  view source on GitHub ↗

Helper to get optional details about named references Returns the dereferenced name as both value and repr if the name list is defined. Otherwise returns the sentinel value dis.UNKNOWN for the value and an empty string for its repr.

(name_index, get_name, **extrainfo)

Source from the content-addressed store, hash-verified

708 return argval, argrepr
709
710def _get_name_info(name_index, get_name, **extrainfo):
711 """Helper to get optional details about named references
712
713 Returns the dereferenced name as both value and repr if the name
714 list is defined.
715 Otherwise returns the sentinel value dis.UNKNOWN for the value
716 and an empty string for its repr.
717 """
718 if get_name is not None:
719 argval = get_name(name_index, **extrainfo)
720 return argval, argval
721 else:
722 return UNKNOWN, ''
723
724def _parse_varint(iterator):
725 b = next(iterator)

Callers 1

get_argval_argreprMethod · 0.85

Calls 1

get_nameFunction · 0.50

Tested by

no test coverage detected