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

Function pretty_flags

Lib/dis.py:170–182  ·  view source on GitHub ↗

Return pretty representation of code flags.

(flags)

Source from the content-addressed store, hash-verified

168}
169
170def pretty_flags(flags):
171 """Return pretty representation of code flags."""
172 names = []
173 for i in range(32):
174 flag = 1<<i
175 if flags & flag:
176 names.append(COMPILER_FLAG_NAMES.get(flag, hex(flag)))
177 flags ^= flag
178 if not flags:
179 break
180 else:
181 names.append(hex(flags))
182 return ", ".join(names)
183
184class _Unknown:
185 def __repr__(self):

Callers 1

_format_code_infoFunction · 0.85

Calls 4

hexFunction · 0.85
appendMethod · 0.45
getMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected