This site describes solve-engine as it is on main: 2.43.0, which npm does not have yet. npm installs 2.40.0, so a page may show an answer that version does not give yet.
LineRerun
Defined in: packages/engine/src/vm/VM.ts:661
A re-run of the lines above a target, opened by LineExecutionContext.rerunLines.
Each run is a fresh pass over the same lines with a different set of
inputs, so a sweep of many values opens one session and runs it once per
value. A name the run overrides keeps its override on every line: a line
that would set it (deposit = 100000) leaves it at the override instead, so
the override is what every line below reads.
Methods
Section titled “Methods”close()
Section titled “close()”close(): void;Defined in: packages/engine/src/vm/VM.ts:676
Release the scratch engine. Call it once, in a finally.
Returns
Section titled “Returns”void
run(overrides): Value;Defined in: packages/engine/src/vm/VM.ts:668
Re-run the lines with overrides in force and return the target line’s
answer: its Value, or an error Value when it has none (the line is prose
or a heading, it holds several inline answers, it failed, or it waits on
live data a re-run cannot fetch).
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
overrides | ReadonlyMap<string, Value> |
Returns
Section titled “Returns”uses()
Section titled “uses()”uses(name): boolean;Defined in: packages/engine/src/vm/VM.ts:674
Whether any line in the span, other than the line asking, mentions
name. Overriding a name no line mentions cannot change the answer, and
is almost always a misspelling, so the forms that override refuse it.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
name | string |
Returns
Section titled “Returns”boolean