Skip to content

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.

MAPREDUCE_PACKAGE

const MAPREDUCE_PACKAGE: IEnginePackage;

Defined in: packages/engine/src/packages/mapreduce/MapReducePackage.ts:19

map/reduce/sum/prod, Calca-parity collection transforms over a Matrix or a bare Range. See MapReduceShared.ts for the shared transform-disambiguation/collection-parsing logic, and vm/VM.ts’s MAP_INVOKE/REDUCE_INVOKE opcode handlers for the runtime semantics.

map/reduce/sum/prod are NOT bare keywordMap entries. See MapReduceCallNormalizerRule.ts, which fuses them into their own token types only when immediately followed by (, so :map = [...] etc. keep working as ordinary variable names.