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

Function finalValue

test/compute-engine/rule-aggregation.test.ts:104–107  ·  view source on GitHub ↗
(set: BoxedRuleSet, expr: BoxedExpression)

Source from the content-addressed store, hash-verified

102 });
103
104 const finalValue = (set: BoxedRuleSet, expr: BoxedExpression) => {
105 const steps = replace(expr, set, REPLACE_OPTS);
106 return steps.length ? steps[steps.length - 1].value : expr;
107 };
108 const trailingBecause = (set: BoxedRuleSet, expr: BoxedExpression) => {
109 const steps = replace(expr, set, REPLACE_OPTS);
110 return steps.length ? steps[steps.length - 1].because : null;

Callers 1

Calls 1

replaceFunction · 0.90

Tested by

no test coverage detected