MCPcopy Create free account
hub / github.com/dylan-sutton-chavez/edge-python / is_set_like

Method is_set_like

compiler/src/modules/vm/ops.rs:148–150  ·  view source on GitHub ↗

True for `set` or `frozenset` operands. */

(&self, v: Val)

Source from the content-addressed store, hash-verified

146
147 /* True for `set` or `frozenset` operands. */
148 pub(crate) fn is_set_like(&self, v: Val) -> bool {
149 v.is_heap() && matches!(self.heap.get(v), HeapObj::Set(_) | HeapObj::FrozenSet(_))
150 }
151
152 /* Alloc a set-algebra result; frozen picks frozenset (left-operand type rule). */
153 pub(crate) fn alloc_set_result(&mut self, items: Vec<Val>, frozen: bool) -> Result<Val, VmErr> {

Callers 2

handle_bitwiseMethod · 0.80
handle_compareMethod · 0.80

Calls 1

is_heapMethod · 0.80

Tested by

no test coverage detected