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

Method from_list

Tools/cases_generator/analyzer.py:58–88  ·  view source on GitHub ↗
(properties: list["Properties"])

Source from the content-addressed store, hash-verified

56
57 @staticmethod
58 def from_list(properties: list["Properties"]) -> "Properties":
59 escaping_calls: dict[SimpleStmt, EscapingCall] = {}
60 for p in properties:
61 escaping_calls.update(p.escaping_calls)
62 return Properties(
63 escaping_calls=escaping_calls,
64 escapes = any(p.escapes for p in properties),
65 error_with_pop=any(p.error_with_pop for p in properties),
66 error_without_pop=any(p.error_without_pop for p in properties),
67 deopts=any(p.deopts for p in properties),
68 deopts_periodic=any(p.deopts_periodic for p in properties),
69 oparg=any(p.oparg for p in properties),
70 jumps=any(p.jumps for p in properties),
71 eval_breaker=any(p.eval_breaker for p in properties),
72 needs_this=any(p.needs_this for p in properties),
73 always_exits=any(p.always_exits for p in properties),
74 sync_sp=any(p.sync_sp for p in properties),
75 uses_co_consts=any(p.uses_co_consts for p in properties),
76 uses_co_names=any(p.uses_co_names for p in properties),
77 uses_locals=any(p.uses_locals for p in properties),
78 uses_opcode=any(p.uses_opcode for p in properties),
79 has_free=any(p.has_free for p in properties),
80 side_exit=any(p.side_exit for p in properties),
81 side_exit_at_end=any(p.side_exit_at_end for p in properties),
82 pure=all(p.pure for p in properties),
83 needs_prev=any(p.needs_prev for p in properties),
84 no_save_ip=all(p.no_save_ip for p in properties),
85 needs_guard_ip=any(p.needs_guard_ip for p in properties),
86 unpredictable_jump=any(p.unpredictable_jump for p in properties),
87 records_value=any(p.records_value for p in properties),
88 )
89
90 @property
91 def infallible(self) -> bool:

Callers 2

_compute_propertiesMethod · 0.45
propertiesMethod · 0.45

Calls 3

PropertiesClass · 0.85
anyFunction · 0.50
updateMethod · 0.45

Tested by

no test coverage detected