MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / lessEqual

Function lessEqual

src/compute-engine/interval/comparison.ts:39–49  ·  view source on GitHub ↗
(
  a: Interval | IntervalResult,
  b: Interval | IntervalResult
)

Source from the content-addressed store, hash-verified

37 Interval | IntervalResult | BoolInterval | IntervalModelValue[];
38
39/**
40 * `asResult` over any value of this target's value model: an interval is
41 * wrapped, while an ARRAY (a collection value at a consuming position) and a
42 * VERDICT pass through unchanged — wrapping either would hand a consumer a
43 * result whose `value` is not an enclosure. The compiled conditional
44 * lowering spells `_IA.res(…)` around an arm it did not build itself.
45 */
46export function asValueResult(x: unknown): unknown {
47 if (Array.isArray(x) || isVerdict(x) || x === null || typeof x !== 'object')
48 return x;
49 return asResult(x as Interval | IntervalResult);
50}
51
52/** Each element of a list marked as present over part of the cell only — the

Callers 1

Calls 1

unwrapOrPropagateFunction · 0.90

Tested by

no test coverage detected